/* ==========================================================================
   ADNAN KABIR — GROWTH ARCHITECT
   base.css — tokens, themes, reset, type scale, shared components
   --------------------------------------------------------------------------
   00. Tokens & themes
   01. Reset
   02. Layout shell + blueprint rules
   03. Typography
   04. Buttons / links / chips
   05. Decorative primitives (brackets, ghost text, redaction)
   06. Nav + mobile menu
   07. Forms
   08. Reveal / motion scaffolding
   ========================================================================== */

/* ---------- 00. TOKENS & THEMES ----------------------------------------- */

:root {
  /* Brand accent — identical hue across both themes */
  --accent:        #29D8F5;
  --accent-2:      #0FB6D8;
  --on-accent:     #04121A;

  /* Type */
  --font-display: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --font-body:    'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --font-serif:   'Instrument Serif', Georgia, 'Times New Roman', serif;
  --font-mono:    'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  /* Spacing scale (4/8 rhythm) */
  --sp-1: .25rem;  --sp-2: .5rem;   --sp-3: .75rem;  --sp-4: 1rem;
  --sp-5: 1.5rem;  --sp-6: 2rem;    --sp-7: 3rem;    --sp-8: 4rem;
  --sp-9: 6rem;    --sp-10: 8rem;

  /* Section rhythm — fluid */
  --section-y: clamp(3rem, 6vw, 6rem);

  /* Shell */
  --shell-max: 82.5rem;      /* 1320px */
  --gutter: clamp(1.25rem, 5vw, 4.5rem);

  /* Radii */
  --r-sm: 3px;  --r-md: 6px;  --r-lg: 10px;  --r-pill: 999px;

  /* Motion */
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-io:  cubic-bezier(.65, 0, .35, 1);
  --t-fast: 160ms;
  --t-med:  280ms;
  --t-slow: 620ms;

  /* Layering */
  /* Menu sits BELOW the nav so the burger + theme toggle stay reachable. */
  --z-rules: 0;
  --z-menu: 85;
  --z-nav: 90;
  --z-progress: 100;

  color-scheme: light;
}

/* --- Dark --- */
[data-theme='dark'] {
  --bg:        #050A12;
  --bg-2:      #08111D;
  --elev:      #0B1524;
  --elev-2:    #0F1D2E;
  --glass:     rgba(7, 14, 24, .72);

  --ink:       #EAF2F8;
  --ink-2:     #9DB2C4;
  --ink-3:     #6E8599;

  --rule:      rgba(150, 185, 210, .1);
  --rule-2:    rgba(150, 185, 210, .26);
  --rule-art:  rgba(150, 185, 210, .10);

  --accent-text: var(--accent);
  --accent-soft: rgba(41, 216, 245, .12);
  --accent-line: rgba(41, 216, 245, .38);
  --glow:        rgba(41, 216, 245, .28);

  --shadow-sm: 0 1px 2px rgba(0,0,0,.5);
  --shadow-md: 0 18px 44px -22px rgba(0,0,0,.9);
  --shadow-lg: 0 40px 90px -40px rgba(0,0,0,1);

  --stroke-w: 1px;
  color-scheme: dark;
}

/* --- Light (paper) — default theme; same brand, opposite ground --- */
[data-theme='light'] {
  --bg:        #F2F5F7;
  --bg-2:      #EAEFF2;
  --elev:      #FFFFFF;
  --elev-2:    #E9EEF2;
  --glass:     rgba(246, 249, 250, .78);

  --ink:       #06101C;
  --ink-2:     #3A4C5C;
  --ink-3:     #5A6E7E;

  --rule:      rgba(6, 16, 28, .1);
  --rule-2:    rgba(6, 16, 28, .24);
  --rule-art:  rgba(6, 16, 28, .09);

  /* Bright cyan stays for fills, rules and shapes.
     Text-on-paper uses the deepened cyan so it clears WCAG AA. */
  --accent-text: #06788F;
  --accent-soft: rgba(41, 216, 245, .16);
  --accent-line: rgba(6, 120, 143, .42);
  --glow:        rgba(41, 216, 245, .30);

  --shadow-sm: 0 1px 2px rgba(6,16,28,.06);
  --shadow-md: 0 18px 44px -24px rgba(6,16,28,.30);
  --shadow-lg: 0 44px 90px -44px rgba(6,16,28,.36);

  --stroke-w: 1.25px;
  color-scheme: light;
}

/* ---------- 01. RESET ---------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  font-synthesis-weight: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  transition: background-color var(--t-med) var(--ease-io),
              color var(--t-med) var(--ease-io);
}

body.is-locked { overflow: hidden; }

img, svg, video { display: block; max-width: 100%; }
svg { fill: none; }
button, input { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
p, h1, h2, h3, h4, figure, blockquote, dl, dd { margin: 0; }

::selection { background: var(--accent); color: var(--on-accent); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip-link {
  position: fixed; top: .5rem; left: .5rem; z-index: 200;
  padding: .7rem 1.1rem; border-radius: var(--r-sm);
  background: var(--accent); color: var(--on-accent);
  font-family: var(--font-mono); font-size: .78rem; letter-spacing: .06em;
  transform: translateY(-160%);
  transition: transform var(--t-fast) var(--ease-out);
}
.skip-link:focus-visible { transform: translateY(0); }

/* ---------- 02. SHELL + BLUEPRINT RULES ---------------------------------- */

.shell {
  width: 100%;
  max-width: var(--shell-max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Fixed vertical rules — the blueprint spine of the whole page */
.grid-rules {
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: var(--z-rules);
}
.grid-rules__shell { position: relative; height: 100%; }
.grid-rules i {
  position: absolute;
  top: 0; bottom: 0;
  left: calc(var(--gutter) + (100% - var(--gutter) * 2) * var(--x));
  width: 1px;
  background: linear-gradient(
    to bottom,
    transparent 0,
    var(--rule) 8%,
    var(--rule) 92%,
    transparent 100%
  );
}
.grid-rules i:nth-child(2), .grid-rules i:nth-child(5) { opacity: .75; }
@media (max-width: 900px) {
  .grid-rules i:nth-child(2), .grid-rules i:nth-child(5) { display: none; }
}
@media (max-width: 600px) {
  .grid-rules i:nth-child(3), .grid-rules i:nth-child(4) { display: none; }
}

/* Scroll progress hairline */
.scroll-progress {
  position: fixed; inset: 0 0 auto; height: 2px;
  z-index: var(--z-progress);
  background: transparent;
}
.scroll-progress span {
  display: block; height: 100%; width: 100%;
  transform: scaleX(0); transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
  box-shadow: 0 0 12px var(--glow);
}

/* Hairline section separators */
.rule-top { border-top: 1px solid var(--rule); }

/* ---------- 03. TYPOGRAPHY ----------------------------------------------- */

.display {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 92%;
  line-height: .96;
  letter-spacing: -.025em;
  text-wrap: balance;
}

.mono {
  font-family: var(--font-mono);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}

.ital {
  font-family: var(--font-serif);
  font-weight: 400;
  font-style: italic;
  font-stretch: 100%;
  letter-spacing: -.01em;
  color: var(--accent-text);
}

.tnum { font-variant-numeric: tabular-nums; }

.h2 {
  font-size: clamp(2.1rem, 5.2vw, 4.25rem);
  margin-bottom: .35em;
}

.lede {
  font-size: clamp(1.0625rem, 1.55vw, 1.3125rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 34ch;
  text-wrap: pretty;
}

.kicker {
  color: var(--accent-text);
  margin-bottom: var(--sp-4);
}

/* Section label: § 01 · Observation ——— The Free Audit */
.sec-label {
  display: flex;
  align-items: center;
  gap: clamp(.75rem, 2vw, 1.5rem);
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
  color: var(--ink-3);
}
.sec-label > .mono:first-child { color: var(--accent-text); flex: none; }
.sec-label > .mono:last-child { flex: none; }
.sec-label__rule {
  flex: 1 1 auto;
  height: 1px;
  min-width: 1.5rem;
  background: var(--rule-2);
}
.sec-label--center { justify-content: center; }
.sec-label--center .sec-label__rule { flex: 0 1 6rem; }

@media (max-width: 560px) {
  .sec-label > .mono { font-size: .625rem; }
}

/* Outline / stroke display word — Inspiration 2's signature move.
   A band of solid accent sweeps through the glyphs and exits, so the word
   ends the animation outlined, not filled. The band is 2 element-widths of
   accent inside a 4-wide gradient, which holds the word fully filled for
   roughly the middle third of the sweep before it clears. */
.stroke-word {
  font-style: normal;
  color: transparent;
  -webkit-text-stroke: var(--stroke-w) var(--accent-text);
  background-image: linear-gradient(90deg,
      transparent 0 25%,
      var(--accent-text) 30% 70%,
      transparent 75% 100%);
  background-size: 400% 100%;
  background-position: 100% 0;
  -webkit-background-clip: text;
  background-clip: text;
  transition: background-position 2.4s var(--ease-io) .3s;
  padding-right: .04em;
}
/* 0% parks the band fully past the word — outline only. */
.is-filled .stroke-word { background-position: 0 0; }
@supports not ((-webkit-text-stroke: 1px red) and (background-clip: text)) {
  .stroke-word { color: var(--accent-text); background: none; }
}

/* ---------- 04. BUTTONS / LINKS / CHIPS ---------------------------------- */

.btn {
  --btn-py: .95rem;
  --btn-px: 1.6rem;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .7rem;
  min-height: 3rem;
  padding: var(--btn-py) var(--btn-px);
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font-size: .9375rem;
  font-weight: 600;
  letter-spacing: -.005em;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color var(--t-med) var(--ease-out),
              color var(--t-med) var(--ease-out),
              border-color var(--t-med) var(--ease-out),
              box-shadow var(--t-med) var(--ease-out),
              transform var(--t-fast) var(--ease-out);
}
.btn:active { transform: scale(.975); }

.btn__icon {
  width: 1.0625rem; height: 1.0625rem; flex: none;
  stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform var(--t-med) var(--ease-out);
}
.btn:hover .btn__icon { transform: translateX(4px); }

.btn--primary {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: 0 0 0 0 var(--glow), var(--shadow-sm);
}
.btn--primary:hover {
  background: #4FE3FA;
  box-shadow: 0 0 34px -4px var(--glow), var(--shadow-md);
}

.btn--ghost {
  color: var(--ink-2);
  border-color: var(--rule-2);
  background: transparent;
}
.btn--ghost:hover {
  color: var(--ink);
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

.btn--sm { --btn-py: .65rem; --btn-px: 1.15rem; min-height: 2.5rem; font-size: .875rem; }
.btn--lg { --btn-py: 1.15rem; --btn-px: 2.1rem; min-height: 3.5rem; font-size: 1.0625rem; }
.btn--block { display: flex; width: 100%; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  min-height: 2.75rem;
  color: var(--accent-text);
  font-size: .9375rem;
  font-weight: 600;
  transition: gap var(--t-med) var(--ease-out), opacity var(--t-fast) linear;
}
.link-arrow svg {
  width: 1.05rem; height: 1.05rem; flex: none;
  stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform var(--t-med) var(--ease-out);
}
.link-arrow:hover { gap: .85rem; }
.link-arrow:hover svg { transform: translateX(2px); }
.link-arrow--lg {
  font-size: clamp(1rem, 1.6vw, 1.125rem);
  padding-bottom: .35rem;
  border-bottom: 1px solid var(--accent-line);
}
.link-arrow.is-muted { color: var(--ink-3); pointer-events: none; opacity: .55; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .3rem .65rem;
  border: 1px solid var(--rule-2);
  border-radius: var(--r-pill);
  font-family: var(--font-mono);
  font-size: .625rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}
.chip i {
  width: 5px; height: 5px; border-radius: 50%;
  background: currentColor; flex: none;
}
.chip--ok { color: var(--accent-text); border-color: var(--accent-line); background: var(--accent-soft); }
.chip--ok i { box-shadow: 0 0 0 3px var(--accent-soft); }
.chip--soon { border-style: dashed; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 2.75rem; height: 2.75rem;
  border-radius: 50%;
  color: var(--ink-2);
  border: 1px solid transparent;
  transition: color var(--t-fast) linear,
              background-color var(--t-fast) linear,
              border-color var(--t-fast) linear;
}
.icon-btn:hover { color: var(--ink); background: var(--elev-2); border-color: var(--rule); }
.icon-btn .icon { width: 1.15rem; height: 1.15rem; }

.icon-inline { width: 1rem; height: 1rem; display: inline-block; vertical-align: -2px; margin-right: .45rem; }

/* Theme toggle icon swap */
.theme-toggle .icon--sun  { display: none; }
.theme-toggle .icon--moon { display: block; }
[data-theme='light'] .theme-toggle .icon--sun  { display: block; }
[data-theme='light'] .theme-toggle .icon--moon { display: none; }

/* ---------- 05. DECORATIVE PRIMITIVES ------------------------------------ */

/* Drafting corner brackets */
.brackets { position: absolute; inset: 0; pointer-events: none; }
.brackets i {
  position: absolute;
  width: 14px; height: 14px;
  border: 1px solid var(--accent-line);
  transition: width var(--t-med) var(--ease-out), height var(--t-med) var(--ease-out);
}
.brackets i:nth-child(1) { top: -1px; left: -1px;  border-right: 0; border-bottom: 0; }
.brackets i:nth-child(2) { top: -1px; right: -1px; border-left: 0;  border-bottom: 0; }
.brackets i:nth-child(3) { bottom: -1px; left: -1px;  border-right: 0; border-top: 0; }
.brackets i:nth-child(4) { bottom: -1px; right: -1px; border-left: 0;  border-top: 0; }

/* Giant ghost word behind manifesto sections */
.ghost {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  font-size: clamp(5rem, 21vw, 19rem);
  font-weight: 900;
  font-stretch: 78%;
  letter-spacing: -.03em;
  color: transparent;
  -webkit-text-stroke: 1px var(--rule-2);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

/* Redaction bars for unpublished case data */
.redact {
  display: inline-block;
  width: 4.5rem; height: .85em;
  vertical-align: -.1em;
  border-radius: 2px;
  background: repeating-linear-gradient(
    -45deg, var(--rule-2) 0 4px, transparent 4px 8px
  );
  outline: 1px solid var(--rule);
}
.redact-lines { display: grid; gap: .45rem; }
.redact-lines i {
  height: .6rem;
  border-radius: 2px;
  background: var(--rule);
}
.redact-lines i:nth-child(1) { width: 100%; }
.redact-lines i:nth-child(2) { width: 82%; }
.redact-lines i:nth-child(3) { width: 61%; }

/* Eyebrow with live dot */
.eyebrow { display: inline-flex; align-items: center; gap: .6rem; color: var(--accent-text); }
.eyebrow__dot {
  position: relative;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); flex: none;
}
.eyebrow__dot::after {
  content: ''; position: absolute; inset: -3px;
  border-radius: 50%; border: 1px solid var(--accent);
  opacity: .5;
  animation: pulse-ring 2.6s var(--ease-io) infinite;
}
@keyframes pulse-ring {
  0%   { transform: scale(.6); opacity: .7; }
  70%  { transform: scale(1.8); opacity: 0; }
  100% { transform: scale(1.8); opacity: 0; }
}

/* ---------- 06. NAV ------------------------------------------------------ */

.nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: var(--z-nav);
  padding-top: env(safe-area-inset-top);
  transition: background-color var(--t-med) var(--ease-io),
              border-color var(--t-med) var(--ease-io),
              transform var(--t-med) var(--ease-out);
  border-bottom: 1px solid transparent;
}
.nav.is-stuck {
  background: var(--glass);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  border-bottom-color: var(--rule);
}
.nav.is-hidden { transform: translateY(-102%); }

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-5);
  height: 4.75rem;
}
@media (min-width: 900px) { .nav__inner { height: 5.5rem; } }

.brand { display: inline-flex; align-items: center; gap: .7rem; min-height: 2.75rem; }
.brand__mark {
  display: grid; place-items: center;
  width: 2.25rem; height: 2.25rem;
  border: 1px solid var(--rule-2);
  border-radius: var(--r-sm);
  color: var(--ink-2);
  transition: border-color var(--t-med) var(--ease-out),
              background-color var(--t-med) var(--ease-out);
}
.brand__mark svg { width: 1.15rem; height: 1.15rem; }
.brand:hover .brand__mark { border-color: var(--accent-line); background: var(--accent-soft); }
.brand__text { display: grid; line-height: 1.15; }
.brand__text strong {
  font-family: var(--font-display);
  font-size: .875rem; font-weight: 700;
  font-stretch: 88%; letter-spacing: .10em;
}
.brand__text em {
  font-family: var(--font-mono);
  font-style: normal;
  font-size: .5625rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
@media (max-width: 420px) { .brand__text em { display: none; } }

.nav__links { display: none; gap: .25rem; }
@media (min-width: 1100px) { .nav__links { display: flex; } }
.nav__links a {
  position: relative;
  padding: .55rem .8rem;
  font-size: .875rem;
  font-weight: 500;
  color: var(--ink-2);
  border-radius: var(--r-sm);
  transition: color var(--t-fast) linear;
}
.nav__links a::after {
  content: '';
  position: absolute;
  left: .8rem; right: .8rem; bottom: .3rem;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0); transform-origin: 0 50%;
  transition: transform var(--t-med) var(--ease-out);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { transform: scaleX(1); }
.nav__links a.is-active { color: var(--ink); }
.nav__links a.is-active::after { transform: scaleX(1); background: var(--accent-line); }

/* Nav dropdown ("Work", "Learn") — CSS hover/focus reveal, JS click-toggle for touch */
.nav__links .dd { position: relative; }
.nav__links .dd-trigger {
  display: inline-flex; align-items: center; gap: .35rem;
  position: relative;
  padding: .55rem .8rem;
  font: inherit;
  font-size: .875rem;
  font-weight: 500;
  color: var(--ink-2);
  background: none;
  border: 0;
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: color var(--t-fast) linear;
}
.nav__links .dd-trigger::after {
  content: '';
  position: absolute;
  left: .8rem; right: .8rem; bottom: .3rem;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0); transform-origin: 0 50%;
  transition: transform var(--t-med) var(--ease-out);
}
.nav__links .dd-trigger:hover,
.nav__links .dd-trigger[aria-expanded='true'] { color: var(--ink); }
.nav__links .dd-trigger:hover::after,
.nav__links .dd-trigger[aria-expanded='true']::after { transform: scaleX(1); }
.nav__links .dd-trigger.is-active { color: var(--ink); }
.nav__links .dd-trigger.is-active::after { transform: scaleX(1); background: var(--accent-line); }

.dd-caret {
  width: .7rem; height: .7rem; flex: none;
  stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform var(--t-med) var(--ease-out);
}
.dd-trigger[aria-expanded='true'] .dd-caret { transform: rotate(180deg); }

.dd-menu {
  position: absolute; top: calc(100% + .125rem); left: 50%;
  transform: translateX(-50%) translateY(4px);
  width: max-content;
  min-width: 14rem;
  padding: .5rem;
  background: var(--elev);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-fast) linear,
              transform var(--t-med) var(--ease-out),
              visibility 0s linear var(--t-fast);
  z-index: 10;
}
.dd:hover .dd-menu,
.dd:focus-within .dd-menu,
.dd-menu.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  transition: opacity var(--t-fast) linear, transform var(--t-med) var(--ease-out), visibility 0s;
}
.dd-menu a {
  display: flex; flex-direction: column; gap: .15rem;
  min-height: 44px;
  justify-content: center;
  padding: .6rem .75rem;
  border-radius: var(--r-sm);
  transition: background-color var(--t-fast) linear;
}
.dd-menu a span { color: var(--ink); font-size: .9375rem; font-weight: 600; }
.dd-menu a small { color: var(--ink-3); font-size: .75rem; font-weight: 400; }
.dd-menu a:hover { background: var(--elev-2); }
.dd-menu a:hover span { color: var(--accent-text); }
.dd-menu a[aria-current='page'] { background: var(--accent-soft); }
.dd-menu a[aria-current='page'] span { color: var(--accent-text); }

.nav__actions { display: flex; align-items: center; gap: .4rem; }
.nav__cta { display: none; }
@media (min-width: 640px) { .nav__cta { display: inline-flex; } }
.nav__burger { display: inline-grid; }
@media (min-width: 1100px) { .nav__burger { display: none; } }

.nav__burger span { display: grid; gap: 5px; width: 18px; }
.nav__burger i {
  display: block; height: 1.5px; width: 100%;
  background: currentColor;
  transition: transform var(--t-med) var(--ease-out), opacity var(--t-fast) linear;
}
.nav__burger[aria-expanded='true'] i:nth-child(1) { transform: translateY(3.25px) rotate(45deg); }
.nav__burger[aria-expanded='true'] i:nth-child(2) { transform: translateY(-3.25px) rotate(-45deg); }

/* Mobile menu overlay */
.menu {
  position: fixed; inset: 0;
  z-index: var(--z-menu);
  background: var(--bg);
  display: grid;
  align-content: center;
  opacity: 0;
  transition: opacity var(--t-med) var(--ease-io);
}
.menu[hidden] { display: none; }
.menu.is-open { opacity: 1; }
.menu__inner {
  width: 100%; max-width: var(--shell-max);
  margin-inline: auto;
  padding: 6rem var(--gutter) 3rem;
}
.menu__eyebrow { color: var(--ink-3); margin-bottom: var(--sp-5); }
.menu__links { display: grid; border-top: 1px solid var(--rule); }
.menu__links a {
  display: flex; align-items: baseline; gap: 1rem;
  padding: clamp(.85rem, 3vw, 1.25rem) 0;
  border-bottom: 1px solid var(--rule);
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 8vw, 2.75rem);
  font-weight: 700; font-stretch: 90%;
  letter-spacing: -.02em; line-height: 1;
  opacity: 0; transform: translateY(14px);
  transition: color var(--t-fast) linear;
}
.menu.is-open .menu__links a { opacity: 1; transform: none; transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
.menu.is-open .menu__links a:nth-child(1) { transition-delay: .05s; }
.menu.is-open .menu__links a:nth-child(2) { transition-delay: .10s; }
.menu.is-open .menu__links a:nth-child(3) { transition-delay: .15s; }
.menu.is-open .menu__links a:nth-child(4) { transition-delay: .20s; }
.menu.is-open .menu__links a:nth-child(5) { transition-delay: .25s; }
.menu__links a:hover { color: var(--accent-text); }
.menu__links .mono { font-size: .6875rem; color: var(--ink-3); }

/* Mobile "Work" / "Learn" dropdown — native <details>/<summary>, same
   keyboard-operable, zero-JS disclosure pattern as .faq-item elsewhere. */
.menu__group {
  border-bottom: 1px solid var(--rule);
  opacity: 0; transform: translateY(14px);
}
.menu.is-open .menu__links .menu__group { opacity: 1; transform: none; transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
.menu.is-open .menu__links .menu__group:nth-child(1) { transition-delay: .05s; }
.menu.is-open .menu__links .menu__group:nth-child(2) { transition-delay: .10s; }
.menu.is-open .menu__links .menu__group:nth-child(3) { transition-delay: .15s; }
.menu.is-open .menu__links .menu__group:nth-child(4) { transition-delay: .20s; }
.menu.is-open .menu__links .menu__group:nth-child(5) { transition-delay: .25s; }

.menu__group summary {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  padding: clamp(.85rem, 3vw, 1.25rem) 0;
  cursor: pointer;
  list-style: none;
  color: var(--ink);
  transition: color var(--t-fast) linear;
}
.menu__group summary::-webkit-details-marker { display: none; }
.menu__group summary::marker { content: ''; }
.menu__group summary:hover { color: var(--accent-text); }
.menu__group summary.is-active { color: var(--accent-text); }

.menu__group__label {
  display: flex; align-items: baseline; gap: 1rem;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 8vw, 2.75rem);
  font-weight: 700; font-stretch: 90%;
  letter-spacing: -.02em; line-height: 1;
}
.menu__group summary .dd-caret { width: 1rem; height: 1rem; }
.menu__group[open] summary .dd-caret { transform: rotate(180deg); }

.menu__sub { display: grid; gap: .1rem; padding-bottom: .5rem; }
.menu__sub a {
  display: block;
  min-height: 44px;
  padding: .6rem 0 .6rem 1.5rem;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--ink-2);
  transition: color var(--t-fast) linear;
}
.menu__sub a:hover { color: var(--accent-text); }
.menu__sub a[aria-current='page'] { color: var(--accent-text); }
.menu.is-open .menu__links a:last-child {
    border-bottom: none;
}
.menu__foot { display: grid; gap: var(--sp-4); justify-items: start; margin-top: var(--sp-7); }
.menu__foot .link-arrow { font-size: .875rem; }

/* ---------- 07. FORMS ---------------------------------------------------- */

.field { display: grid; gap: .6rem; }
.field__label { color: var(--ink-3); }
.field__row {
  display: flex; flex-wrap: wrap; gap: .6rem;
  align-items: stretch;
}
.field__input {
  flex: 1 1 15rem;
  min-height: 3.25rem;
  padding: .9rem 1.15rem;
  background: var(--elev);
  border: 1px solid var(--rule-2);
  border-radius: var(--r-pill);
  font-size: 1rem;
  color: var(--ink);
  transition: border-color var(--t-fast) linear, box-shadow var(--t-fast) linear;
}
.field__input::placeholder { color: var(--ink-3); }
.field__input:hover { border-color: var(--rule-2); }
.field__input:focus {
  outline: 0;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field__input[aria-invalid='true'] { border-color: #FF6B6B; }
.field__row .btn { flex: 0 0 auto; min-height: 3.25rem; }
.field__msg { color: var(--ink-3); }
.field__msg.is-error { color: #FF8B8B; }
.field__msg.is-ok { color: var(--accent-text); }
.field__note { color: var(--ink-3); margin-top: 0.5rem; }

@media (max-width: 480px) {
  .field__row { flex-direction: column; }
  /* flex-grow would stretch the input along the new (vertical) main axis */
  .field__row .field__input { flex: 0 0 auto; width: 100%; }
  .field__row .btn { width: 100%; }
}

/* ---------- 08. REVEAL / MOTION SCAFFOLDING ------------------------------ */

/* Elements are hidden ONLY once GSAP has confirmed it loaded, so a failed
   CDN or a no-JS visitor still gets the full page. */
.gsap-ready [data-reveal] { opacity: 0; }
.gsap-ready [data-split] .char { display: inline-block; will-change: transform; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .gsap-ready [data-reveal] { opacity: 1 !important; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .stroke-word { background-position: 0 0; }
}
