/*
  Site header / primary nav.
  Source: Figma nodes 3:653 (desktop 1600px), 18:1302 (mobile 360px).
*/

.site-header {
  background-color: var(--color-background-dark);
  color: var(--color-text-on-dark);
  position: sticky;
  top: 0;
  z-index: 100;
  /* Transform drives the hide/show; bg-color fades in once the user
     has left the hero overlay. JS toggles .is-hidden / .is-scrolled. */
  transition: transform 0.3s ease, background-color 0.3s ease;
}

/* When the page has a hero section, float the nav over it.
   Add class="has-hero" to <body> on pages where the first section
   is a dark hero. The hero handles its own background; the nav stays
   fixed (rather than sticky-in-flow) so it overlays the hero. */
.has-hero .site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background-color: transparent;
}

/* Logged-in admin quick-edit link -> Appearance > Menus (see
   infleqtion_render_nav_edit_link()). Hangs just below the header bar on
   the right so it never overlaps the logo, links, CTA, or hamburger at
   any width. */
.site-header__section-edit {
  position: absolute;
  top: 100%;
  right: var(--space-inline);
  margin-top: 6px;
}

/* Past the top of the page (~50px), the nav gets a solid bg so links
   stay readable over scrolled content. On the homepage this fades in
   once you've left the hero overlay. */
.has-hero .site-header.is-scrolled {
  background-color: var(--color-background-dark);
}

/* JS adds .is-hidden when the user scrolls down past the hide threshold
   and removes it on scroll-up. The header slides off the top edge. */
.site-header.is-hidden {
  transform: translateY(-100%);
}

/* Reduced motion: snap rather than slide (still hides/shows). */
@media (prefers-reduced-motion: reduce) {
  .site-header {
    transition: none;
  }
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) var(--space-inline);
  max-width: var(--container-max);
  margin-inline: auto;
}

/* Logo */
.site-header__logo {
  display: inline-flex;
  flex-shrink: 0;
}

.site-header__logo img {
  /* Mobile-first sizing — desktop scales up in media query below */
  height: 26px;
  width: 90px;
}

/* Primary nav links — hidden on mobile, shown on desktop */
.site-nav {
  display: none;
}

.site-nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-9);
}

.site-nav__link {
  display: inline-block;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-tight);
  color: var(--color-text-on-dark);
  white-space: nowrap;
  transition: color 0.2s ease;
}

.site-nav__link:hover,
.site-nav__link:focus-visible {
  color: var(--color-green-2);
}

/* CTA — hidden on mobile, shown on desktop */
.site-header__cta {
  display: none;
}

/* Mirror CTA rendered inside the drawer at <937px. The header CTA sits
   outside .site-nav, so CSS alone can't relocate it into the drawer —
   each page carries a second copy that only shows below the desktop
   breakpoint. */
.site-nav__cta {
  display: none;
}

/* Mobile hamburger — shown on mobile, hidden on desktop.
   Six dots in a 2-col × 3-row grid. */
.site-header__menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  width: 34px;
  height: 34px;
  background: transparent;
  border: 0;
  color: var(--color-text-on-dark);
  cursor: pointer;
}

.site-header__dots {
  display: grid;
  grid-template-columns: repeat(3, 8px);
  grid-template-rows: repeat(3, 8px);
  gap: 5px;
}

.site-header__dots > span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: currentColor;
}

/* ---------------------------------------------------------------
   Desktop nav (≥937px). Overrides the project's default 768px breakpoint
   because the logo + 6 links + CTA only fit comfortably above ~937px.
   Horizontal padding stays fluid via --space-inline (no override needed).
   --------------------------------------------------------------- */
@media (min-width: 937px) {
  .site-header__logo img {
    height: 39px;
    width: 132px;
  }

  .site-nav {
    display: block;
  }

  /* The +/- indicators (Figma 910:110) add ~80px to the link row, which
     no longer fits at this breakpoint's 937px floor. Easing the gap
     20 -> 36 over 937 -> 1600 buys that width back, so the nav still
     fits at 937 and lands on Figma's designed 36px at the 1600 frame.
     Preferred over raising the breakpoint: that would hand 937-1000px
     to the hamburger, which has no mobile menu behind it yet.
     slope = (36-20)/663 = 0.024133/px; intercept = 20 - 0.024133 x 937 */
  .site-nav__list {
    gap: clamp(20px, -2.613px + 2.4133vw, 36px);
  }

  .site-header__cta {
    display: inline-flex;
  }

  .site-header__menu-toggle {
    display: none;
  }
}

/* ---------------------------------------------------------------
   Wide-screen pass (≥1600px).

   The nav inherits its outer padding + max-width from --space-inline
   and --container-max, which handle the 260px gutters + 2500 frame at
   viewport=2500 (see tokens.css wide-screen block). Per Figma, top-level
   link + toggle text stays at 14px across the whole range — no font
   scaling here. (Earlier revisions tried a 14 → 16 clamp; QA flagged
   it because .site-nav__link scaled while .site-nav__toggle didn't,
   since the toggle's un-media-queried rule sits later in the file.)
   --------------------------------------------------------------- */

/* ===============================================================
   Products sub-navigation (mega menu)
   Source: Figma node 910:110 "Nav - Products" (desktop 1600px).

   No mobile design exists for this panel — the nav already collapses
   to the hamburger below 937px, so the panel is desktop-only and
   matches that same breakpoint override.

   The four "icons" in the Figma node (+, −, the active underline and
   the column dividers) are all 1px/2px straight strokes, so they're
   drawn in CSS rather than shipped as SVG assets.
   =============================================================== */

/* --- Nav-bar link that owns a panel -------------------------------
   Rendered as a <button> (it's a disclosure, not a destination) but
   styled identically to .site-nav__link. */
.site-nav__toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0;
  background: none;
  border: 0;
  font-family: inherit;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-tight);
  color: var(--color-text-on-dark);
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.2s ease;
}

.site-nav__toggle:hover,
.site-nav__toggle:focus-visible {
  color: var(--color-green-2);
}

/* Green 2px rule under the whole group (label + indicator), 8px below
   the text. Figma: 78px wide = 62 label + 8 gap + 8 indicator. */
.site-nav__toggle::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + var(--space-2));
  height: 2px;
  background-color: var(--color-green-2);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.site-nav__toggle[aria-expanded="true"]::after {
  opacity: 1;
}

.site-nav__toggle[aria-expanded="true"] {
  color: var(--color-text-on-dark);
}

/* --- +/− indicator ------------------------------------------------
   8×8, two 1px strokes in currentColor. Open state drops the vertical
   stroke, leaving the minus. */
.site-nav__indicator {
  position: relative;
  display: block;
  flex-shrink: 0;
  width: 8px;
  height: 8px;
}

.site-nav__indicator::before,
.site-nav__indicator::after {
  content: "";
  position: absolute;
  background-color: currentColor;
}

/* horizontal stroke */
.site-nav__indicator::before {
  top: 50%;
  left: 0;
  width: 100%;
  height: 1px;
  transform: translateY(-50%);
}

/* vertical stroke — collapses to make the minus when the panel is open */
.site-nav__indicator::after {
  left: 50%;
  top: 0;
  width: 1px;
  height: 100%;
  transform: translateX(-50%);
  transition: opacity 0.2s ease, transform 0.2s ease;
  transform-origin: center;
}

.site-nav__toggle[aria-expanded="true"] .site-nav__indicator::after {
  opacity: 0;
  transform: translateX(-50%) scaleY(0);
}

/* --- The panel ----------------------------------------------------
   952px wide, centred on the viewport, 66px down from the top of the
   header. Absolute inside .site-header so it inherits the header's
   fixed/sticky positioning and travels with the hide-on-scroll. */
.site-nav__panel {
  position: absolute;
  top: 66px;
  left: 50%;
  z-index: 1;
  width: var(--panel-width, 952px);
  /* Below the 1600px design frame the panel would overflow the
     viewport, so cap it at the content width and let the columns
     (1fr) absorb the difference. */
  max-width: calc(100vw - 2 * var(--space-inline));
  background-color: var(--color-white);
  border: 1px solid var(--color-card-border);
  border-radius: 8px;
  box-shadow: var(--shadow-image-glow);
  /* Clips the dark header strip's top corners to the panel radius. */
  overflow: hidden;
  /* Closed state */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(-50%) translateY(-8px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s linear 0.22s;
}

.site-nav__panel.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s;
}

/* --- Panel header strip (navy, 148px) ----------------------------- */
.site-nav__panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  padding: var(--space-7);
  background-color: var(--color-background-dark);
}

.site-nav__panel-heading {
  font-family: var(--font-family-display);
  font-weight: var(--font-weight-medium);
  font-size: 30px;
  line-height: 32px;
  letter-spacing: 0.2px;
  color: var(--color-text-on-dark);
}

.site-nav__panel-intro {
  max-width: 535px;
  margin-top: var(--space-2);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-loose);
  letter-spacing: 0.3px;
  color: var(--color-text-on-dark);
}

/* Figma gives this CTA 16px block padding vs the 14px .btn default.

   Deliberately plain .btn--filled, NOT .btn--filled.btn--on-light: the
   strip behind it is navy, so once the teal pill sweeps out on hover
   the label needs to go white to stay readable. --on-light pins it
   navy, which is right on a light page and wrong here. */
.site-nav__panel-cta {
  flex-shrink: 0;
  padding-block: var(--space-4_5);
}

/* --- Panel body: 3 columns + full-height dividers ----------------- */
.site-nav__panel-body {
  /* Gap eases down from the designed 96px as the panel narrows, so
     the columns keep a usable measure between 937px and 1600px. */
  --menu-col-gap: clamp(40px, 6vw, 96px);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: var(--menu-col-gap);
  padding-inline: var(--space-7);
}

/* Block padding lives on the columns (not the body) so the grid items
   stretch the full height of the body — that's what lets the divider
   pseudo-element run edge to edge, past the shorter columns. */
.site-nav__group {
  position: relative;
  padding-block: var(--space-7);
}

.site-nav__group + .site-nav__group::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--menu-col-gap) / -2);
  width: 1px;
  background-color: var(--color-card-border);
}

.site-nav__group-title {
  font-family: var(--font-family-display);
  font-weight: var(--font-weight-semibold);
  font-size: 20px;
  /* 25px box in Figma — New Science at 20px needs 1.25 to match. */
  line-height: 1.25;
  letter-spacing: 0.1px;
  color: var(--color-text-heading);
}

.site-nav__group-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-4_5);
  margin-top: var(--space-4_5);
}

.site-nav__item {
  display: block;
  text-decoration: none;
}

.site-nav__item-title {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  /* Figma rows are 18px tall — set by the hover arrow, so rows without
     one still reserve the same height. */
  min-height: 18px;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
  letter-spacing: 0.1px;
  color: var(--color-text-heading);
  transition: color 0.2s ease;
}

.site-nav__item-arrow {
  flex-shrink: 0;
  font-size: 18px;
  font-weight: var(--font-weight-medium);
  line-height: var(--line-height-tight);
  letter-spacing: 0.18px;
  color: var(--color-teal);
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.site-nav__item:hover .site-nav__item-arrow,
.site-nav__item:focus-visible .site-nav__item-arrow {
  opacity: 1;
  transform: translateX(0);
}

.site-nav__item-desc {
  display: block;
  margin-top: var(--space-1);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-regular);
  line-height: 1.2;
  letter-spacing: 0.1px;
  color: var(--color-text-muted);
}

/* ---------------------------------------------------------------
   Industries panel — variant of the same mega menu.
   Source: Figma node 910:480 "Nav - Industries" (desktop 1600px).

   Differences from the Products panel: 708px wide instead of 952,
   no CTA in the dark strip, and the body is a plain two-column link
   list — no group headings and no per-item descriptions, so the rows
   sit 32px apart instead of 16px.
   --------------------------------------------------------------- */
.site-nav__panel--industries {
  --panel-width: 708px;
}

/* No CTA sharing the strip, so the copy runs the full content width
   rather than the 535px column the Products panel leaves for it. */
.site-nav__panel-header--wide .site-nav__panel-intro {
  max-width: none;
}

/* Columns are sized by their content and packed left, not the equal
   thirds the Products panel uses (Figma: 219/170 for Industries,
   116/201/184/102 for Company). Auto-flow rather than a fixed track
   list so the same rule serves any column count. */
.site-nav__panel-body--plain {
  grid-template-columns: none;
  grid-auto-flow: column;
  grid-auto-columns: max-content;
  justify-content: start;
}

/* A description's max-content width (~520px on one line) would blow the
   track out and overflow the panel, so cap it at the width Figma gives
   the one column that has one. */
.site-nav__panel-body--plain .site-nav__item-desc {
  max-width: 201px;
}

.site-nav__panel-body--plain .site-nav__group-list {
  /* No group heading above the list, and no descriptions between the
     rows — Figma spaces these 32px apart. */
  gap: var(--space-7);
  margin-top: 0;
}

/* These columns are max-content sized, so a hover arrow sitting in the
   flow would pad every track by its own width (~22px) and shove the
   divider off Figma's 745px. Lift it out of flow instead: the track
   measures the label alone (219px / 170px, per Figma) and the arrow
   overhangs to the right on hover. The Products panel keeps its
   in-flow arrow — its tracks are 1fr, so reserving the space there
   costs nothing. */
.site-nav__panel-body--plain .site-nav__item-title {
  position: relative;
  /* max-content, not inline-flex — an inline-level box would pick up the
     parent's line-box leading and grow every row past Figma's 18px. */
  width: max-content;
}

.site-nav__panel-body--plain .site-nav__item-arrow {
  position: absolute;
  left: 100%;
  margin-left: var(--space-1);
}

/* ---------------------------------------------------------------
   Resources panel — variant of the same mega menu.
   Source: Figma node 910:302 "Nav - Resources Alt" (desktop 1600px).

   708px wide like Industries, but the body pairs a six-link column
   with a featured card (image + copy + text CTA).
   --------------------------------------------------------------- */
.site-nav__panel--resources {
  --panel-width: 708px;
}

/* This strip's copy block flexes to fill instead of sitting at the
   fixed 535px the Products/Company panels use — Figma gives it a 48px
   gap to a wider CTA, leaving the text 395px. */
.site-nav__panel-header--fill {
  gap: 48px;
}

.site-nav__panel-header--fill .site-nav__panel-header-text {
  flex: 1;
  min-width: 0;
}

.site-nav__panel-header--fill .site-nav__panel-intro {
  max-width: none;
}

/* Figma sets this body's top padding to 24 while the bottom stays 32
   (148 + 24 + 303 + 32 = the panel's designed 507px). Every other
   panel is a symmetric 32 — flagged to the designer as a possible
   slip; drop this rule if it was unintentional. */
.site-nav__panel--resources .site-nav__group {
  padding-top: var(--space-6);
}

/* --- Featured card ------------------------------------------------ */
.site-nav__feature {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
  width: 350px;
  text-decoration: none;
}

.site-nav__feature-media {
  width: 100%;
  /* Figma: 350x165 */
  aspect-ratio: 350 / 165;
  border-radius: 8px;
  overflow: hidden;
}

.site-nav__feature-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Title + copy + CTA share one child so the card's flex gap sets only
   the media → text step. The steps *inside* the text block are margins
   (8 below the title, 24 above the CTA), which is what lets a variant
   retune the media gap on its own — see the News panel below. */
.site-nav__feature-body {
  display: flex;
  flex-direction: column;
}

.site-nav__feature-title {
  display: block;
  font-size: var(--font-size-body);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
  letter-spacing: 0.2px;
  color: var(--color-text-heading);
}

.site-nav__feature-desc {
  display: block;
  margin-top: var(--space-2);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-loose);
  letter-spacing: 0.3px;
  color: var(--color-text-muted);
}

/* The card is one big link, so the "Read More" affordance is a span
   styled as .cta-link rather than a nested anchor. */
.site-nav__feature .cta-link {
  margin-top: var(--space-6);
}

/* The card column is a fixed 350px rather than max-content. */
.site-nav__group--feature {
  width: 350px;
}

/* ---------------------------------------------------------------
   News panel — variant of the same mega menu.
   Source: Figma node 910:388 "Nav - News Alt" (desktop 1600px).

   952px wide with the same navy strip + CTA as Products. The body
   swaps the text-link columns for three image cards, so it reuses the
   Resources featured card (.site-nav__feature) inside the standard
   three-column body — dividers and 32px block padding come along
   unchanged.
   --------------------------------------------------------------- */

/* Figma: 888px of content = 3 cards of 242.34 + 2 gutters of 80,
   narrower than the 96px Products uses. Same clamp shape so the
   columns keep a usable measure as the panel narrows toward 937px. */
.site-nav__panel--news .site-nav__panel-body {
  --menu-col-gap: clamp(40px, 5vw, 80px);
}

/* The Resources card is a fixed 350px sitting beside a link column;
   here the three cards ride the body's 1fr tracks, so the card fills
   whatever width its column gets. */
.site-nav__panel--news .site-nav__feature {
  width: auto;
  /* Figma stacks these 16 / 8 / 24 vs the Resources card's 24 / 8 / 24.
     Only the media → text step differs, and that's the one the card's
     flex gap owns, so this single override covers it. */
  gap: var(--space-4_5);
}

/* Figma: 242.34 x 132 */
.site-nav__panel--news .site-nav__feature-media {
  aspect-ratio: 242 / 132;
}

/* ===============================================================
   Mobile navigation (<937px) — the hamburger drawer.

   NO Figma design exists for the OPEN menu. Node 18:1302 covers the
   CLOSED 360px header only (logo + hamburger), which the base styles
   above already build. Everything in this block is adapted from
   patterns already in this codebase — chiefly `latest-updates`, whose
   desktop tabs collapse into a vertical accordion off the same DOM.
   >>> FLAGGED FOR DESIGNER REVIEW. <<<

   Deliberately the LAST block in this file: it has to win over the
   panel variants above it (--panel-width, the 350px feature card, the
   max-content link tracks), which all sit at equal specificity.
   =============================================================== */
@media (max-width: 936px) {
  /* --- The drawer ------------------------------------------------
     Hangs off the bottom edge of the header bar. .site-header is the
     nearest positioned ancestor in BOTH modes (sticky normally, fixed
     under .has-hero) and never clips, so `top: 100%` lands the drawer
     directly under the bar either way.
     Bar height = the 34px hamburger + the header's 2 x --space-5. */
  .site-nav {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: calc(100vh - (34px + 2 * var(--space-5)));
    max-height: calc(100dvh - (34px + 2 * var(--space-5)));
    overflow-y: auto;
    /* Don't hand the scroll chain back to the locked page behind. */
    overscroll-behavior: contain;
    background-color: var(--color-background-dark);
    /* Closed state — same choreography as the desktop panels. */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s linear 0.22s;
  }

  .site-header.is-menu-open .site-nav {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s;
  }

  /* Page behind the open drawer must not scroll. JS sets the attribute
     on <html>; this mirrors the leadership modal's scroll lock
     (:root[data-leadership-modal-open]) so the two behave alike. */
  :root[data-site-nav-open] {
    overflow: hidden;
  }

  /* --- Top-level rows -------------------------------------------- */
  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    /* Drops the bottom padding — the CTA below carries its own bottom
       margin so the drawer isn't over-padded when the CTA is present. */
    padding: var(--space-2) var(--space-inline) 0;
  }

  /* --- Mobile Let's Talk CTA -------------------------------------- */
  .site-nav__cta {
    display: inline-flex;
    margin: var(--space-4_5) var(--space-inline) var(--space-7);
  }

  .site-nav__toggle,
  .site-nav__link {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    padding-block: var(--space-4_5);
    font-size: var(--font-size-body);
    text-align: left;
  }

  /* The desktop green rule is anchored to the row's full width, which
     stretched edge-to-edge would read as a divider rather than an
     active marker. The +/- carries the open state on its own here. */
  .site-nav__toggle::after {
    content: none;
  }

  /* --- Panels become accordion bodies ---------------------------- */
  .site-nav__panel {
    position: static;
    width: auto;
    max-width: none;
    /* The glow is an overlay affordance — it reads as a smudge when
       the panel is an in-flow block. Border + radius stay: a white
       card inside the navy drawer wants both. */
    box-shadow: none;
    /* Collapsed. The desktop opacity/visibility choreography can't be
       reused — a hidden-but-laid-out panel still occupies its full
       height in the drawer's scroll, so this one has to be display. */
    display: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    transition: none;
  }

  .site-nav__panel.is-open {
    display: block;
    margin-bottom: var(--space-4_5);
    /* .site-nav__panel.is-open re-applies the desktop centring
       translate at higher specificity than the reset above, which
       drags the open accordion half its width off the left edge. */
    transform: none;
    transition: none;
  }

  .site-nav__panel-header,
  .site-nav__panel-header--wide,
  .site-nav__panel-header--fill {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-4_5);
    padding: var(--space-6);
  }

  /* The accordion row immediately above already names the section. */
  .site-nav__panel-heading {
    display: none;
  }

  .site-nav__panel-intro {
    max-width: none;
  }

  /* --- Panel body: every variant collapses to one column ---------- */
  .site-nav__panel-body {
    display: block;
    padding: var(--space-5) var(--space-6);
  }

  .site-nav__group,
  .site-nav__panel--resources .site-nav__group {
    padding-block: var(--space-4_5);
  }

  /* Column dividers are a multi-column artefact. */
  .site-nav__group + .site-nav__group::before {
    display: none;
  }

  /* --plain panels (Company / Industries / Resources) carry no group
     headings, so their groups are purely a desktop-column artefact.
     Collapsed on mobile, the group padding + group-list gap add up to
     an oversized break between what look like adjacent links. Flatten
     the groups and drive a single uniform rhythm from the parent's
     flex gap. Must sit AFTER the .site-nav__panel--resources group
     rule above — Resources panels carry both classes at equal
     specificity, so source order picks the winner.
     Products and News keep group padding because they carry real
     group headings ("Quantum Computing", "Newsroom", etc.). */
  .site-nav__panel-body--plain {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
    padding-inline: var(--space-6);
  }

  .site-nav__panel-body--plain .site-nav__group {
    padding-block: 0;
  }

  .site-nav__panel-body--plain .site-nav__group-list {
    gap: var(--space-5);
  }

  /* Both cards go full width instead of their fixed desktop tracks. */
  .site-nav__feature,
  .site-nav__group--feature {
    width: auto;
  }

  /* The plain body lifts its hover arrow out of flow so max-content
     tracks measure the label alone. Stacked, the tracks are gone and
     an out-of-flow arrow would sit off the right edge. */
  .site-nav__panel-body--plain .site-nav__item-title {
    width: auto;
  }

  .site-nav__panel-body--plain .site-nav__item-arrow {
    position: static;
    margin-left: 0;
  }

  .site-nav__panel-body--plain .site-nav__item-desc {
    max-width: none;
  }

  /* --- Hamburger -> X --------------------------------------------
     The 3x3 dot grid already contains both diagonals; dropping the
     four edge-centre dots (2, 4, 6, 8) leaves an X. No extra markup. */
  .site-header__dots > span {
    transition: opacity 0.22s ease;
  }

  .site-header.is-menu-open .site-header__dots > span:nth-child(2n) {
    opacity: 0;
  }
}
