/* ==========================================================================
   Layout: header + navigation, mobile menu, hero, sections, footer.
   ========================================================================== */

/* ---------- header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100; height: var(--hdr);
  background: rgba(255, 255, 255, .97); border-bottom: 1px solid var(--line);
  transition: background .35s, box-shadow .35s, border-color .35s;
}
.has-hero .site-header:not(.is-scrolled):not(.is-open) { background: transparent; border-bottom-color: transparent; }
.site-header.is-scrolled, .site-header.is-open {
  background: rgba(255, 255, 255, .97); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px -24px rgba(10, 42, 94, .55);
}
.header-in { display: flex; align-items: center; gap: 28px; height: 100%; }
.brand { display: inline-flex; flex: none; }
.brand { align-items: center; }
.brand img { height: 64px; width: auto; }
.brand .logo-w { display: none; }

.nav { margin-left: auto; }
.nav-list { display: flex; align-items: center; gap: clamp(10px, 1.05vw, 22px); }
.nav-item { position: relative; display: flex; align-items: center; }
.nav-link {
  position: relative; padding: 10px 0; white-space: nowrap; text-decoration: none;
  font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink); transition: color .2s;
}
.nav-link::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 3px; height: 2px; background: var(--sky);
  transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease);
}
.nav-link:hover, .nav-link[aria-current] { color: var(--navy); }
.nav-link:hover::after, .nav-link[aria-current]::after, .has-menu.open > .nav-link::after { transform: scaleX(1); }
.menu-btn { width: 22px; height: 32px; display: grid; place-items: center; color: var(--muted); }
.menu-btn .ic { width: 15px; height: 15px; transition: transform .3s var(--ease); }
.has-menu.open .menu-btn .ic { transform: rotate(180deg); }
.nav-toggle {
  display: none; place-items: center; width: 46px; height: 46px; margin-left: 12px; flex: none;
  border: 1px solid var(--line); border-radius: var(--r); background: #fff; color: var(--navy);
}

/* header over the dark heroes */
.hero-dark .site-header:not(.is-scrolled):not(.is-open) .nav-link,
.hero-dark .site-header:not(.is-scrolled):not(.is-open) .menu-btn { color: #fff; }
.hero-dark .site-header:not(.is-scrolled):not(.is-open) .logo-c { display: none; }
.hero-dark .site-header:not(.is-scrolled):not(.is-open) .logo-w { display: block; }
.hero-dark .site-header:not(.is-scrolled):not(.is-open) .nav-toggle { background: transparent; border-color: rgba(255, 255, 255, .4); color: #fff; }

/* ---------- mega menus ---------- */
.mega {
  position: absolute; top: 100%; left: 50%; padding-top: 16px;
  opacity: 0; visibility: hidden; transform: translate(-50%, 8px);
  transition: opacity .25s var(--ease), transform .3s var(--ease), visibility .25s;
}
.has-menu:hover > .mega, .has-menu.open > .mega { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.mega-in { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-2); overflow: hidden; }

.mega-sol { display: grid; grid-template-columns: 1.35fr 1fr; width: min(800px, calc(100vw - 48px)); }
.mega-list { padding: 14px; }
.mega-list a { display: flex; gap: 14px; align-items: flex-start; padding: 12px; border-radius: var(--r); text-decoration: none; transition: background .2s; }
.mega-list a:hover, .mega-list a:focus-visible { background: var(--lighter); }
.mega-ic { width: 44px; height: 44px; border-radius: var(--r); background: var(--light); display: grid; place-items: center; flex: none; transition: background .2s, color .2s; }
.mega-ic .ci { width: 24px; height: 24px; }
.mega-list a:hover .mega-ic { background: var(--navy); }
.mega-list a:hover .mega-ic .ci { color: #fff; }
.mega-list small { display: block; font-size: 11px; font-weight: 700; letter-spacing: .14em; color: var(--blue-m); }
.mega-list strong { display: block; font-size: 15px; line-height: 1.3; color: var(--navy); }
.mega-list em { display: block; font-style: normal; font-size: 13px; color: var(--muted); margin-top: 2px; }
.mega-feature {
  padding: 30px 28px; color: #fff; display: flex; flex-direction: column;
  background: linear-gradient(160deg, var(--navy), var(--navy-d));
  background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(160deg, var(--navy), var(--navy-d));
  background-size: 32px 32px, 32px 32px, auto;
}
.mega-feature-h { font-size: 20px; font-weight: 300; line-height: 1.35; margin-bottom: 18px; }
.mega-phases { margin-bottom: 24px; }
.mega-phases li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line-d); font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
.mega-phases li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--sky); }
.mega-feature .link-arrow { margin-top: auto; align-self: flex-start; }

.mega-prod { width: min(660px, calc(100vw - 48px)); padding: 14px; }
.mega-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2px 8px; }
.mega-grid a { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: var(--r); text-decoration: none; font-size: 14px; font-weight: 600; color: var(--navy); transition: background .2s; }
.mega-grid a:hover, .mega-grid a:focus-visible { background: var(--lighter); }
.mega-grid img { width: 64px; height: 44px; object-fit: cover; border-radius: 4px; flex: none; }
.mega-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; border-top: 1px solid var(--line); margin-top: 12px; padding: 14px 8px 4px; font-size: 13px; color: var(--muted); }

/* ---------- mobile menu ---------- */
.mnav {
  position: fixed; inset: 0; z-index: 150; background: #fff; display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
  opacity: 0; transform: translateY(-14px); transition: opacity .3s var(--ease), transform .4s var(--ease);
}
.mnav[hidden] { display: none; }
.mnav.open { opacity: 1; transform: none; }
.mnav-head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; min-height: var(--hdr); padding: 0 var(--gutter); background: #fff; border-bottom: 1px solid var(--line); }
.mnav-head .brand img { height: 48px; }
.mnav-close { width: 46px; height: 46px; border: 1px solid var(--line); border-radius: var(--r); display: grid; place-items: center; color: var(--navy); }
.mnav-body { flex: 1; display: flex; flex-direction: column; padding: 8px var(--gutter) 32px; }
.mnav-list > li { border-bottom: 1px solid var(--line); opacity: 0; transform: translateY(8px); transition: opacity .4s var(--ease), transform .4s var(--ease); transition-delay: calc(var(--i) * 35ms + 80ms); }
.mnav.open .mnav-list > li { opacity: 1; transform: none; }
.mnav-list a { display: block; padding: 14px 0; font-size: 18px; font-weight: 600; color: var(--navy); text-decoration: none; }
.mnav-list > li > a, .mnav-row a { font-size: 15px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.mnav-list a[aria-current] { color: var(--blue); }
.mnav-row { display: flex; align-items: center; }
.mnav-row a { flex: 1; }
.mnav-row button { width: 46px; height: 46px; display: grid; place-items: center; color: var(--blue); }
.mnav-row button .ic { transition: transform .3s var(--ease); }
.mnav-row button[aria-expanded="true"] .ic { transform: rotate(180deg); }
.mnav-sub { padding: 0 0 12px 16px; margin-bottom: 10px; border-left: 2px solid var(--sky); }
.mnav-sub a { font-size: 15px; font-weight: 500; padding: 9px 0; color: var(--muted); }
.mnav-foot { margin-top: auto; padding-top: 28px; display: grid; gap: 14px; }
.mnav-contact { display: flex; gap: 10px; align-items: center; color: var(--navy); text-decoration: none; font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.mnav-contact .ic { color: var(--blue); }
body.menu-open { overflow: hidden; }

/* ---------- hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden; padding-top: var(--hdr);
  background: linear-gradient(120deg, #fff 0%, var(--lighter) 55%, var(--light) 100%);
}
.hero-grid {
  position: absolute; inset: 0; z-index: -2; opacity: .5;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: linear-gradient(90deg, #000 0, transparent 65%); mask-image: linear-gradient(90deg, #000 0, transparent 65%);
  animation: grid 40s linear infinite;
}
.hero-visual { position: absolute; top: var(--hdr); right: 0; bottom: 0; width: 50%; z-index: -1; clip-path: polygon(22% 0, 100% 0, 100% 100%, 0 100%); }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-visual::after { content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, rgba(10, 42, 94, .05), rgba(10, 42, 94, .55)); }
.airflow, .hero-waves, .cta-waves { position: absolute; width: 100%; height: 100%; inset: 0; z-index: 1; pointer-events: none; }
.flow { stroke-width: 2; opacity: .55; stroke-dasharray: 60 340; animation: flow 7s linear infinite; }
.f2 { opacity: .35; animation-duration: 9s; animation-delay: -3s; stroke-width: 1.5; }
.f3 { opacity: .4; animation-duration: 8s; animation-delay: -5s; }
.f4 { opacity: .25; animation-duration: 11s; animation-delay: -2s; stroke-width: 1.5; }

.hero-in { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); align-items: center; min-height: clamp(520px, 74vh, 720px); padding-block: 48px 72px; }
.hero-copy { max-width: 600px; position: relative; z-index: 2; }
.hero h1 { margin-top: 22px; }
.hero:not(.hero--home) h1 { font-size: var(--fs-h1-in); }
.hero .lead { margin-top: 24px; }
.hero-tag { position: absolute; right: var(--gutter); bottom: 56px; display: flex; flex-direction: column; gap: 2px; font-size: clamp(18px, 2vw, 28px); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #fff; text-align: right; line-height: 1.2; }

.hero--home .hero-in { min-height: calc(100svh - var(--hdr) - 76px); }
.hero--home .hero-visual { width: 56%; clip-path: polygon(24% 0, 100% 0, 100% 100%, 0 100%); }
.hero--home h1 { font-size: clamp(40px, 6.2vw, 84px); }

.hero--visual .hero-in, .hero--dark .hero-in { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(32px, 5vw, 72px); }
.hero-aside { position: relative; z-index: 1; }

.hero--dark { background: linear-gradient(135deg, var(--navy-d), var(--navy) 60%, #0f3a80); color: #fff; }
.hero--dark .hero-grid {
  opacity: 1; background-image: linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px);
  -webkit-mask-image: radial-gradient(ellipse at 30% 40%, #000 10%, transparent 70%); mask-image: radial-gradient(ellipse at 30% 40%, #000 10%, transparent 70%);
}
.hero--dark h1, .hero--dark h1 b { color: #fff; }
.hero--dark h1 em { color: var(--sky); }
.hero--dark .lead { color: var(--muted-d); }
.hero--dark .eyebrow { color: var(--sky); }
.hero--dark .crumbs, .hero--dark .crumbs a { color: var(--muted-d); }
.hero-waves { inset: auto 0 0 0; height: 70%; color: var(--sky); z-index: -1; }
.hero--compact .hero-in { min-height: 0; padding-block: 72px 88px; }

.crumbs { margin-bottom: 26px; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 8px; opacity: .6; }
.crumbs a { color: var(--blue); font-weight: 600; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }

.hero-strip { position: relative; z-index: 2; background: #fff; border-top: 1px solid var(--line); }
.hero-strip ul { display: grid; grid-template-columns: repeat(4, 1fr); }
.hero-strip li { display: flex; align-items: center; gap: 14px; min-height: 76px; padding: 14px 20px; font-size: 14px; font-weight: 700; color: var(--navy); }
.hero-strip li:first-child { padding-left: 0; }
.hero-strip li + li { border-left: 1px solid var(--line); }
.hero-strip .ci { width: 28px; height: 28px; }

/* ---------- sections ---------- */
section { position: relative; }
.sec { padding-block: var(--sec); }
.sec--tint { background: var(--lighter); }
.sec--light { background: var(--light); }
.sec--navy { background: linear-gradient(135deg, var(--navy-d), var(--navy) 60%, #0f3a80); color: #fff; overflow: hidden; }
.sec-head { max-width: 780px; margin-bottom: 52px; }
.sec-head--center { text-align: center; margin-inline: auto; }
.sec-head--center .kicker { justify-content: center; }
.sec-head--split { max-width: none; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 32px 64px; align-items: end; }
.sec-intro { margin-top: 18px; max-width: 620px; font-size: 17px; color: var(--muted); }
.sec-head--split .sec-intro { margin-top: 0; }
.sec-head--center .sec-intro { margin-inline: auto; }
.sec-head--light h2 { color: #fff; }
.sec-head--light h2 em { color: var(--sky); }
.sec-head--light .sec-intro { color: var(--muted-d); }
.sec-foot { margin-top: 44px; }
.sec-foot--center { text-align: center; }

/* ---------- footer ---------- */
.site-footer { position: relative; overflow: hidden; background: var(--navy-d); color: var(--muted-d); padding-top: 88px; font-size: 14.5px; }
.foot-wave { position: absolute; inset: 0 0 auto 0; height: 120px; color: rgba(47, 182, 240, .06); }
.foot-wave svg { width: 100%; height: 100%; transform: scaleY(-1); }
/* Five columns on one baseline: every list uses the same 14.5px text, 1.4 line height and 12px row gap. */
.foot-grid { position: relative; display: grid; grid-template-columns: 1.25fr .75fr 1fr 1.3fr 1.45fr; gap: 36px; padding-bottom: 56px; }
.foot-logo { display: inline-block; }
.foot-logo img { height: 72px; width: auto; }
.foot-tag { margin: 24px 0 12px; color: #fff; font-size: 20px; font-weight: 300; line-height: 1.3; }
.foot-tag b { font-weight: 800; }
.foot-brand > p:not(.foot-tag) { max-width: 300px; line-height: 1.6; }
.foot-brand .btn { margin-top: 24px; }
.foot-h { margin: 6px 0 22px; padding-bottom: 14px; border-bottom: 1px solid var(--line-d); font-size: 12px; line-height: 1; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--sky); }
.foot-col ul { display: grid; gap: 12px; }
.foot-col li { line-height: 1.4; }
.foot-col a { color: var(--muted-d); text-decoration: none; transition: color .2s; }
.foot-col a:hover { color: #fff; }
.foot-2col { grid-template-columns: auto auto; justify-content: start; column-gap: 28px; }
.foot-2col li { white-space: nowrap; }
.foot-contact ul { gap: 14px; }
.foot-contact li { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 12px; align-items: start; }
.foot-contact .ic { width: 18px; height: 18px; margin-top: 1px; color: var(--sky); }
.foot-contact a, .foot-contact span { overflow-wrap: anywhere; }
.foot-contact small { display: block; margin-top: 2px; font-size: 12.5px; opacity: .75; }
.foot-bottom { display: flex; justify-content: space-between; align-items: center; gap: 12px 24px; flex-wrap: wrap; padding-block: 22px 26px; border-top: 1px solid var(--line-d); font-size: 13px; }
@media (min-width: 1025px) { .foot-copy, .foot-credit { white-space: nowrap; } }
.foot-bottom-tag { color: #fff; font-weight: 600; letter-spacing: .02em; }
.foot-bottom-tag::before { content: ""; display: inline-block; width: 1px; height: 12px; margin: 0 12px; vertical-align: -1px; background: var(--line-d); }
.foot-bottom-r { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 24px; margin-right: 60px; /* clear of the back-to-top button */ }
.foot-bottom .foot-credit a { display: inline; color: #fff; font-weight: 600; text-decoration: underline; text-decoration-color: rgba(47, 182, 240, .6); text-underline-offset: 3px; }
.foot-bottom .foot-credit a:hover { color: var(--sky); }
.foot-bottom a { display: inline-flex; gap: 8px; align-items: center; color: var(--muted-d); text-decoration: none; }
.foot-bottom a:hover { color: #fff; }
.foot-bottom .ic { width: 18px; height: 18px; color: var(--sky); }

.to-top {
  position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; background: var(--navy); color: #fff; box-shadow: var(--shadow-2);
  opacity: 0; visibility: hidden; transform: translateY(10px); transition: opacity .3s, transform .3s var(--ease), visibility .3s, background .2s;
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--blue); }

/* ---------- responsive ---------- */
@media (max-width: 1199px) {
  .nav { display: none; }
  .nav-toggle { display: grid; margin-left: auto; }
  /* brand becomes a full-width row (logo + tagline | text + button), link columns below */
  .foot-grid { grid-template-columns: .8fr 1fr 1.3fr 1.4fr; row-gap: 44px; }
  .foot-brand { grid-column: 1 / -1; display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "logo desc" "tag btn"; column-gap: 56px; align-items: center; padding-bottom: 36px; border-bottom: 1px solid var(--line-d); }
  .foot-logo { grid-area: logo; }
  .foot-tag { grid-area: tag; margin: 16px 0 0; }
  .foot-brand > p:not(.foot-tag) { grid-area: desc; max-width: 460px; }
  .foot-brand .btn { grid-area: btn; justify-self: start; margin-top: 16px; }
}
@media (max-width: 1024px) {
  .foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1024px) {
  /* photo heroes stack: image band on top, copy below */
  .hero-visual, .hero--home .hero-visual { width: 100%; height: 340px; bottom: auto; clip-path: none; }
  .hero-visual::after { background: linear-gradient(180deg, rgba(10, 42, 94, .05) 40%, rgba(244, 248, 253, 1) 99%); }
  .hero--home .hero-in, .hero--split .hero-in { min-height: 0; padding-top: 340px; }
  .hero-tag { display: none; }
  .hero--visual .hero-in, .hero--dark .hero-in { grid-template-columns: minmax(0, 1fr); }
  .hero-aside { max-width: 620px; }
  .sec-head--split { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .hero-strip ul { grid-template-columns: repeat(2, 1fr); }
  .hero-strip li:nth-child(3) { border-left: 0; padding-left: 0; }
  .hero-strip li:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (max-width: 760px) {
  .brand img { height: 48px; }
  .hero-in { min-height: 0; padding-block: 28px 56px; }
  .hero--home .hero-in { padding-top: 250px; }
  .hero--split .hero-in { padding-top: 236px; }
  .hero-visual, .hero--home .hero-visual { height: 230px; }
  .hero h1 { margin-top: 16px; }
  .crumbs { margin-bottom: 18px; }
  .hero-strip li { min-height: 64px; padding: 12px; font-size: 13px; gap: 10px; }
  .hero-strip li:nth-child(odd) { padding-left: 0; }
  .hero-strip .ci { width: 24px; height: 24px; }
  .sec-head { margin-bottom: 34px; }
  .sec-intro { font-size: 16px; }
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 36px 20px; }
  .foot-brand, .foot-contact, .foot-col:has(.foot-2col) { grid-column: 1 / -1; }
  .foot-brand { display: block; padding-bottom: 32px; }
  .foot-tag { margin: 20px 0 10px; }
  .foot-bottom { flex-direction: column; align-items: flex-start; padding-bottom: 78px; /* room for the back-to-top button */ }
  .foot-bottom-r { flex-direction: column; align-items: flex-start; margin-right: 0; }
  .foot-credit { padding-left: 0; border-left: 0; }
  .foot-bottom-tag { display: block; margin-top: 4px; }
  .foot-bottom-tag::before { display: none; }
  .to-top { right: 14px; bottom: 14px; }
}
@media (max-width: 400px) {
  .hero-strip ul { grid-template-columns: 1fr; }
  .hero-strip li, .hero-strip li:nth-child(3) { border-left: 0 !important; padding-left: 0; }
  .hero-strip li + li { border-top: 1px solid var(--line); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-grid, .flow { animation: none; }
}
