/* ============================================================================
   Devalo cinematic template , styles.css
   ----------------------------------------------------------------------------
   WHY this file is structured token-first: brand-tokens.json is the single
   source of truth. Every colour / type / radius / space value below is a CSS
   custom property seeded from that file. A client fork re-skins the whole
   property by swapping the token values in this :root block , nothing else.
   No raw hex / px is written in component rules where a token exists (the
   token-or-die discipline); the only bare literals are 0, 1px hairlines,
   %/vw geometry, and effect-specific rgba() glow alpha.

   Concept: "considered craft, layer by layer" , a dark, engineered stage.
   Surfaces are thin translucent panels with cyan hairlines (engineered, NOT
   frosted glassmorphism , no decorative backdrop-blur), flat by default,
   depth expressed through parallax planes and hairline precision.
   ============================================================================ */

/* ---------------------------------------------------------------------------
   1. TOKEN LAYER , the re-skin seam (seeded from brand-tokens.json)
   --------------------------------------------------------------------------- */
:root {
  /* --- Palette: primitives (from brand-tokens.json color.primitive) --- */
  --cyan-50:   #ECFEFF;
  --cyan-700:  #0E7490;
  --cyan-bright: #22D3EE; /* semantic.accent-on-dark , the accent on dark */
  --zinc-50:   #FAFAFA;
  --zinc-400:  #A1A1AA;
  --zinc-500:  #71717A;
  --zinc-600:  #52525B;
  --zinc-800:  #27272A;
  --zinc-900:  #18181B;
  --near-black:#0A0A0A;

  /* --- Palette: semantic dark-mode roles (this page is a dark stage) --- */
  --stage:        var(--near-black);          /* page background */
  --stage-deep:   #060606;                    /* deepest well (tinted-neutral, not pure #000) */
  --panel:        rgba(255, 255, 255, 0.028); /* engineered surface fill */
  --panel-solid:  var(--zinc-900);            /* opaque panel where needed */
  --panel-2:      var(--zinc-800);            /* raised panel */
  --hairline:     rgba(255, 255, 255, 0.09);  /* neutral divider */
  --hairline-cyan:rgba(34, 211, 238, 0.24);   /* cyan precision hairline */
  --accent:       var(--cyan-bright);         /* accent on dark */
  --accent-deep:  var(--cyan-700);            /* deep cyan (fills, wordmark mark) */
  --accent-wash:  rgba(34, 211, 238, 0.08);   /* faint accent field */
  --scrim-header: rgba(10, 10, 10, 0.82);      /* scrolled header scrim */
  --scrim-nav:    rgba(6, 6, 6, 0.97);         /* mobile nav overlay scrim */

  /* Text tiers , all verified >= 4.5:1 on --stage for their size role */
  --text:      var(--zinc-50);   /* headings / high emphasis (~18:1) */
  --text-body: var(--zinc-400);  /* body copy (~7.3:1) */
  --text-muted:#8B8B93;          /* secondary (~5.86:1 stage / 5.59:1 panel) */
  --text-faint:#808088;          /* faintest tier, AA-safe on small text: 5.05:1 stage / 4.82:1 panel; sits below --text-muted so the tier order holds */

  /* --- Typography (from brand-tokens.json typography) --- */
  --font-body:    "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  /* "Geist Fallback" is a metric-matched local face (see @font-face below) so
     the display-font swap shifts no layout (CLS from the hero wordmark -> ~0). */
  --font-display: "Geist", "Geist Fallback", "DM Sans", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --fw-regular: 400;
  --fw-medium:  500;
  --fw-semibold:600;
  --fw-bold:    700;

  /* Type scale (typography.scale) */
  --fs-2xs: 11px; /* micro mono labels only (scroll cue) */
  --fs-xs:  13px;
  --fs-sm:  15px;
  --fs-base:17px;
  --fs-lg:  19px;
  --fs-xl:  21px;
  --fs-2xl: 26px;
  --fs-3xl: 32px;
  --fs-4xl: 38px;
  --fs-5xl: 51px;
  --fs-6xl: 77px;
  /* Fluid display sizes for the cinematic set-pieces (clamp = intentional, not drift) */
  --fs-hero:      clamp(3.25rem, 13vw, 11rem);   /* the DEVALO wordmark */
  --fs-statement: clamp(1.75rem, 4.6vw, 3.6rem); /* the statement line */
  --fs-section:   clamp(1.9rem, 4.4vw, var(--fs-5xl)); /* section headings */
  --fs-page-title:clamp(2.5rem, 6.5vw, 4.75rem); /* inner-page hero titles */

  --track-tight:  -0.02em;
  --track-normal: 0;
  --track-wide:   0.08em;
  --track-mono:   0.18em; /* mono eyebrow labels */

  --lh-tight: 1.05;
  --lh-snug:  1.2;
  --lh-body:  1.65;

  /* --- Radius (brand-tokens.json radius) --- */
  --radius-xs:  4px;
  --radius-sm:  6px;
  --radius-md:  9px;
  --radius-lg:  13px;
  --radius-xl:  17px;
  --radius-2xl: 24px;
  --radius-3xl: 30px;
  --radius-full:9999px;

  /* --- Space , mandated 4pt scale (--space-1: 4px ... --space-16: 64px) --- */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  20px;
  --space-6:  24px;
  --space-7:  28px;
  --space-8:  32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-14: 56px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;
  --space-32: 128px;

  /* Section vertical rhythm , ONE token drives every non-hero section */
  --section-y: clamp(5rem, 11vw, 9.5rem);

  /* Layout */
  --container:      1200px;
  --container-wide: 1360px;
  --gutter:         clamp(var(--space-5), 5vw, var(--space-16));

  /* Motion timing (design-standards duration bands) */
  --dur-fast:   0.16s;
  --dur-base:   0.28s;
  --dur-slow:   0.6s;
  --ease-out:   cubic-bezier(0.22, 1, 0.36, 1);
  --ease-inout: cubic-bezier(0.65, 0, 0.35, 1);

  --focus-ring: 2px solid var(--accent);
}

/* ---------------------------------------------------------------------------
   1b. SELF-HOSTED FONTS (woff2, font-display: swap , no render-blocking link)
   All three families are licence-clean for self-hosting: DM Sans (OFL),
   Geist (OFL, Vercel), JetBrains Mono (OFL/Apache-2.0). See asset-licensing.
   --------------------------------------------------------------------------- */
@font-face {
  font-family: "DM Sans"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("assets/fonts/dm-sans-400.woff2") format("woff2");
}
@font-face {
  font-family: "DM Sans"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("assets/fonts/dm-sans-500.woff2") format("woff2");
}
@font-face {
  font-family: "DM Sans"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("assets/fonts/dm-sans-700.woff2") format("woff2");
}
@font-face {
  font-family: "Geist"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("assets/fonts/geist-500.woff2") format("woff2");
}
@font-face {
  font-family: "Geist"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("assets/fonts/geist-600.woff2") format("woff2");
}
@font-face {
  font-family: "Geist"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("assets/fonts/geist-700.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("assets/fonts/jetbrains-mono-500.woff2") format("woff2");
}
/* Zero-CLS fallback for the display face. A local system sans (Arial / Helvetica
   Neue, available instantly with no network) is remapped to Geist's metrics so
   the swap shifts no layout:
     - size-adjust 101.8% makes local Arial's advance width match Geist's
       (measured advance ratio Geist/Arial = 2636.8/2589.6), so multi-line
       display headings do not re-wrap when Geist arrives (the real CLS vector,
       since every display element uses a unitless line-height and is therefore
       already height-stable across the swap).
     - ascent/descent overrides carry Geist's vertical metrics (read from
       geist-700.woff2: upm 1000 / ascent 1005 / descent -295 / lineGap 0),
       pre-divided by the size-adjust so the effective box matches Geist exactly.
     - font-weight 100 900 so the bold (700) wordmark actually matches this face
       rather than falling through to a mismatched default. */
@font-face {
  font-family: "Geist Fallback";
  src: local("Arial"), local("Helvetica Neue"), local("Segoe UI");
  font-weight: 100 900;
  size-adjust: 101.8%;
  ascent-override: 98.7%;
  descent-override: 29%;
  line-gap-override: 0%;
}

/* ---------------------------------------------------------------------------
   2. RESET + BASE
   --------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  color-scheme: dark;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--stage);
  color: var(--text-body);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  font-weight: var(--fw-regular);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden; /* guard against any transform overshoot */
}

img, svg, canvas { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text);
  font-weight: var(--fw-semibold);
  line-height: var(--lh-snug);
  letter-spacing: var(--track-tight);
  text-wrap: balance;
  margin: 0;
}
p { text-wrap: pretty; margin: 0; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--cyan-50); }

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

/* Focus , visible ring on every interactive element (a11y floor) */
:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}

/* Zero-height header-state sentinel (watched by IntersectionObserver) */
.scroll-sentinel { position: absolute; top: 0; left: 0; width: 1px; height: 1px; pointer-events: none; }

/* Skip link */
.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -100%;
  z-index: 1000;
  padding: var(--space-3) var(--space-5);
  background: var(--accent);
  color: var(--near-black);
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  border-radius: var(--radius-sm);
  transition: top var(--dur-fast) var(--ease-out);
}
.skip-link:focus { top: var(--space-4); color: var(--near-black); }

/* ---------------------------------------------------------------------------
   3. LAYOUT PRIMITIVES
   --------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--wide { max-width: var(--container-wide); }

.section { padding-block: var(--section-y); position: relative; }
.section + .section { border-top: 1px solid var(--hairline); }
/* Fixed header clearance for in-page anchor jumps (~84px header + breathing). */
section[id] { scroll-margin-top: var(--space-24); }

/* Mono eyebrow label , the recurring "engineered" motif (section markers) */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-6);
}
.eyebrow::before {
  content: "";
  width: var(--space-6);
  height: 1px;
  background: var(--hairline-cyan);
}

.section-head { max-width: 46ch; margin-bottom: var(--space-16); }
.section-head h2 { font-size: var(--fs-section); }
.section-head p {
  margin-top: var(--space-5);
  color: var(--text-muted);
  font-size: var(--fs-lg);
  max-width: 52ch;
}

/* ---------------------------------------------------------------------------
   4. HEADER + NAV
   --------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  padding: var(--space-5) var(--gutter);
  transition: background var(--dur-base) var(--ease-out),
              border-color var(--dur-base) var(--ease-out);
  border-bottom: 1px solid transparent;
}
/* Solidifies once scrolled (JS toggles .is-scrolled) , engineered, not frosted */
.site-header.is-scrolled {
  background: var(--scrim-header);
  border-bottom-color: var(--hairline);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-body);
  font-weight: var(--fw-bold);
  font-size: var(--fs-lg);
  letter-spacing: var(--track-tight);
  color: var(--text);
  min-height: 44px;
}
.brand:hover { color: var(--text); }
.brand__mark {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
  flex: none;
}

.site-nav { display: flex; align-items: center; gap: var(--space-2); }
.site-nav__links { display: flex; align-items: center; gap: var(--space-1); }
.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: var(--space-2) var(--space-4);
  color: var(--text-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  border-radius: var(--radius-sm);
  transition: color var(--dur-fast) var(--ease-out);
}
.nav-link:hover { color: var(--text); }
/* Current-page marker , a cyan precision hairline under the active link */
.nav-link[aria-current="page"] { color: var(--text); }
.nav-link[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: var(--space-4);
  right: var(--space-4);
  bottom: var(--space-2);
  height: 1px;
  background: var(--accent);
}

/* CTA button (shared) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--track-tight);
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out),
              background var(--dur-fast) var(--ease-out),
              color var(--dur-fast) var(--ease-out),
              border-color var(--dur-fast) var(--ease-out);
}
.btn:active { transform: scale(0.96); }
.btn--primary {
  background: var(--accent);
  color: var(--near-black);
}
.btn--primary:hover { background: var(--cyan-50); color: var(--near-black); }
.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--hairline);
}
.btn--ghost:hover { border-color: var(--accent); color: var(--text); }
.btn--lg {
  min-height: 56px;
  padding: var(--space-5) var(--space-10);
  font-size: var(--fs-base);
}

/* Mobile nav toggle , hidden on desktop */
.nav-toggle { display: none; }

/* ---------------------------------------------------------------------------
   5. HERO
   --------------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: var(--space-24) var(--gutter) var(--space-16);
  overflow: hidden;
}
/* Poster / ambient stage , the static fallback for the WebGL field.
   Atmospheric cyan wash on near-black (the approved "slow light" concept),
   deliberately low alpha, cyan not the banned purple/blue candy gradient. */
.hero__stage {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(120% 90% at 50% 8%, rgba(34, 211, 238, 0.10), transparent 60%),
    radial-gradient(90% 70% at 82% 78%, rgba(14, 116, 144, 0.14), transparent 62%),
    radial-gradient(140% 120% at 50% 120%, var(--stage-deep), var(--stage) 55%);
}
/* The WebGL canvas mounts here when the gate passes; else it stays empty and
   the CSS stage above is the whole picture. */
.hero__canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity var(--dur-slow) var(--ease-out);
  pointer-events: none;
}
html.webgl-live .hero__canvas.is-mounted { opacity: 1; }

.hero__inner { position: relative; z-index: 2; max-width: 22ch; }
.hero__wordmark {
  font-family: var(--font-display);
  font-weight: var(--fw-bold);
  font-size: var(--fs-hero);
  line-height: 0.9;
  letter-spacing: -0.04em;
  color: var(--text);
  margin: 0;
}
.hero__tagline {
  margin: var(--space-8) auto 0;
  max-width: 30ch;
  font-size: clamp(var(--fs-lg), 2.4vw, var(--fs-2xl));
  color: var(--text-body);
  text-wrap: balance;
}
.hero__meta {
  margin-top: var(--space-6);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--text-muted);
}
.hero__cta { margin-top: var(--space-10); display: inline-flex; gap: var(--space-4); flex-wrap: wrap; justify-content: center; }

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: var(--space-8);
  transform: translateX(-50%);
  z-index: 2;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-mono);
  font-size: var(--fs-2xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--text-muted);
}
.scroll-cue__rail {
  width: 1px;
  height: var(--space-10);
  background: linear-gradient(var(--accent), transparent);
}

/* ---------------------------------------------------------------------------
   6. STATEMENT
   --------------------------------------------------------------------------- */
.statement { text-align: center; }
.statement__line {
  font-family: var(--font-display);
  font-weight: var(--fw-medium);
  font-size: var(--fs-statement);
  line-height: 1.25;
  letter-spacing: var(--track-tight);
  color: var(--text);
  max-width: 20ch;
  margin-inline: auto;
  text-wrap: balance;
}
.statement__line .accent { color: var(--accent); }
.statement__sub {
  margin: var(--space-8) auto 0;
  max-width: 54ch;
  color: var(--text-muted);
  font-size: var(--fs-lg);
}

/* ---------------------------------------------------------------------------
   7. CRAFT , the pinned depth scene (planes: Design / Build / Motion / Ship)
   --------------------------------------------------------------------------- */
.craft { position: relative; }
.craft__planes {
  margin-top: var(--space-16);
  display: grid;
  gap: var(--space-5);
}
.plane {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: var(--space-6);
  padding: var(--space-10) var(--space-8);
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-xl);
}
.plane__index {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  color: var(--accent);
  letter-spacing: var(--track-mono);
}
.plane__title {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: clamp(var(--fs-2xl), 4vw, var(--fs-4xl));
  color: var(--text);
  letter-spacing: var(--track-tight);
}
.plane__desc { color: var(--text-muted); font-size: var(--fs-base); max-width: 42ch; }
.plane__tag {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--text-faint);
  white-space: nowrap;
}

/* ---------------------------------------------------------------------------
   8. PROOF , honest floors as stats on engineered panels
   --------------------------------------------------------------------------- */
.proof__grid {
  margin-top: var(--space-16);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-5);
}
.stat {
  padding: var(--space-10) var(--space-8);
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-xl);
  position: relative;
  overflow: hidden;
}
.stat::after { /* single cyan precision hairline top-edge */
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--hairline-cyan), transparent);
}
.stat__value {
  font-family: var(--font-display);
  font-weight: var(--fw-bold);
  font-size: clamp(var(--fs-4xl), 6vw, var(--fs-6xl));
  line-height: 1;
  letter-spacing: var(--track-tight);
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.stat__value .unit { color: var(--accent); font-size: 0.5em; margin-left: var(--space-1); }
.stat__label {
  margin-top: var(--space-4);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-wide);
  text-transform: uppercase;
  color: var(--text-muted);
}
.stat__note { margin-top: var(--space-2); color: var(--text-faint); font-size: var(--fs-sm); }

/* ---------------------------------------------------------------------------
   9. WORK , capability strip
   --------------------------------------------------------------------------- */
.work__grid {
  margin-top: var(--space-16);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-5);
}
.capability {
  padding: var(--space-10) var(--space-8);
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-xl);
  display: grid;
  gap: var(--space-4);
  align-content: start;
}
.capability__num {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  color: var(--accent);
}
.capability__title {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-xl);
  color: var(--text);
}
.capability__desc { color: var(--text-muted); font-size: var(--fs-base); }

/* ---------------------------------------------------------------------------
   10. PACKAGES , the swappable pricing module (first thing a fork replaces)
   --------------------------------------------------------------------------- */
.packages__grid {
  margin-top: var(--space-16);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-5);
}
.package {
  padding: var(--space-10) var(--space-8);
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-2xl);
  display: grid;
  gap: var(--space-4);
  align-content: start;
}
.package--feature {
  border-color: var(--hairline-cyan);
  background: var(--accent-wash);
}
.package__name {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-xl);
  color: var(--text);
}
.package__price {
  font-family: var(--font-display);
  font-weight: var(--fw-bold);
  font-size: var(--fs-3xl);
  color: var(--text);
  font-variant-numeric: tabular-nums;
  letter-spacing: var(--track-tight);
}
.package__price .from {
  display: block;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-regular);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--space-1);
}
.package__pitch { color: var(--text-muted); font-size: var(--fs-base); }
.package__includes {
  list-style: none;
  margin: var(--space-2) 0 0;
  padding: 0;
  display: grid;
  gap: var(--space-2);
}
.package__includes li {
  position: relative;
  padding-left: var(--space-6);
  color: var(--text-body);
  font-size: var(--fs-sm);
}
.package__includes li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: var(--space-3);
  height: 1px;
  background: var(--accent);
}
.packages__note {
  margin-top: var(--space-10);
  text-align: center;
  color: var(--text-muted);
  font-size: var(--fs-base);
}
.packages__note strong { color: var(--text); font-weight: var(--fw-semibold); }

/* ---------------------------------------------------------------------------
   11. CLOSE / CTA
   --------------------------------------------------------------------------- */
.close { text-align: center; }
.close__title {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-section);
  color: var(--text);
  max-width: 18ch;
  margin-inline: auto;
  text-wrap: balance;
}
.close__sub {
  margin: var(--space-6) auto 0;
  max-width: 46ch;
  color: var(--text-muted);
  font-size: var(--fs-lg);
}
.close__actions {
  margin-top: var(--space-12);
  display: inline-flex;
  gap: var(--space-4);
  flex-wrap: wrap;
  justify-content: center;
}
/* Magnetic button wrapper , transform driven by JS, static at rest */
.magnetic { display: inline-flex; will-change: auto; }

/* ---------------------------------------------------------------------------
   12. FOOTER (Devalo, no Site-by-Devalo credit on Devalo's own page)
   --------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--hairline);
  padding: var(--space-16) var(--gutter) var(--space-12);
}
.site-footer__inner {
  max-width: var(--container);
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-8);
}
.site-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-weight: var(--fw-bold);
  font-size: var(--fs-lg);
  color: var(--text);
}
.site-footer__links { display: flex; flex-wrap: wrap; gap: var(--space-6); }
.site-footer__links a { color: var(--text-muted); font-size: var(--fs-sm); }
.site-footer__links a:hover { color: var(--text); }
.site-footer__legal {
  width: 100%;
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: 1px solid var(--hairline);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  color: var(--text-faint);
  font-size: var(--fs-xs);
  font-family: var(--font-mono);
  letter-spacing: var(--track-wide);
}

/* ===========================================================================
   12b. INNER PAGES , shared components (services / work / about / contact)
   ---------------------------------------------------------------------------
   Inner pages inherit the whole token + motion system. They are deliberately
   LIGHTER than the home: no WebGL hero, no pinned set-piece. A compact
   page-hero replaces the full-viewport wordmark stage; content sections reuse
   the home primitives (.section, .section-head, .eyebrow, .stat, .capability,
   .plane, .close) so the visual language stays identical across the site.
   =========================================================================== */

/* --- Compact page hero (all inner pages) --- */
.page-hero {
  position: relative;
  padding-block: calc(var(--space-32) + var(--space-6)) var(--section-y);
  text-align: center;
  overflow: hidden;
}
.page-hero__stage { /* the same atmospheric cyan wash, calmer than the home hero */
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(110% 80% at 50% 0%, rgba(34, 211, 238, 0.08), transparent 58%),
    radial-gradient(120% 120% at 50% 120%, var(--stage-deep), var(--stage) 60%);
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero__title {
  font-family: var(--font-display);
  font-weight: var(--fw-bold);
  font-size: var(--fs-page-title);
  line-height: var(--lh-tight);
  letter-spacing: -0.03em;
  color: var(--text);
  max-width: 16ch;
  margin-inline: auto;
  text-wrap: balance;
}
.page-hero__lead {
  margin: var(--space-8) auto 0;
  max-width: 56ch;
  color: var(--text-muted);
  font-size: clamp(var(--fs-lg), 2vw, var(--fs-xl));
  text-wrap: pretty;
}
.page-hero__cta {
  margin-top: var(--space-10);
  display: inline-flex;
  gap: var(--space-4);
  flex-wrap: wrap;
  justify-content: center;
}

/* --- Services , the detailed, indexed service list --- */
.service-list {
  margin-top: var(--space-16);
  display: grid;
  gap: var(--space-5);
}
.service {
  display: grid;
  grid-template-columns: 0.85fr 1.25fr;
  gap: var(--space-10);
  padding: var(--space-12) var(--space-10);
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-2xl);
}
.service__lead { display: grid; gap: var(--space-3); align-content: start; }
.service__index {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  letter-spacing: var(--track-mono);
  color: var(--accent);
}
.service__title {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: clamp(var(--fs-2xl), 3.4vw, var(--fs-4xl));
  color: var(--text);
  letter-spacing: var(--track-tight);
}
.service__tag {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--text-faint);
}
.service__body { display: grid; gap: var(--space-6); align-content: start; }
.service__desc { color: var(--text-body); font-size: var(--fs-lg); max-width: 54ch; }
.service__who {
  padding-top: var(--space-6);
  border-top: 1px solid var(--hairline);
  display: grid;
  gap: var(--space-2);
}
.service__who-label {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--accent);
}
.service__who-text { color: var(--text-muted); font-size: var(--fs-base); max-width: 54ch; }

/* --- Callout panel , a highlighted worked-example / note surface (work, about) --- */
.callout {
  margin-top: var(--space-16);
  padding: var(--space-12) var(--space-10);
  background: var(--accent-wash);
  border: 1px solid var(--hairline-cyan);
  border-radius: var(--radius-2xl);
  display: grid;
  gap: var(--space-6);
}
.callout__eyebrow {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--accent);
}
.callout__title {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: clamp(var(--fs-xl), 3vw, var(--fs-3xl));
  color: var(--text);
  max-width: 30ch;
}
.callout__body { color: var(--text-muted); font-size: var(--fs-lg); max-width: 60ch; }
/* In-prose links carry an underline so they are distinguishable by more than
   colour alone (WCAG 1.4.1). Standalone links (nav, footer, contact methods)
   are not in a text block and stay underline-free. */
.callout__body a { color: var(--accent); text-decoration: underline; text-underline-offset: 0.15em; }
.callout__body a:hover { color: var(--cyan-50); }

/* --- Contact , methods list + progressive-enhancement form --- */
.contact-layout {
  margin-top: var(--space-16);
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: var(--space-12);
  align-items: start;
}
.contact-methods { display: grid; gap: var(--space-8); align-content: start; }
.contact-method { display: grid; gap: var(--space-2); }
.contact-method__label {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-mono);
  text-transform: uppercase;
  color: var(--accent);
}
.contact-method__value {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-xl);
  color: var(--text);
  letter-spacing: var(--track-tight);
}
a.contact-method__value:hover { color: var(--accent); }
.contact-method__note { color: var(--text-muted); font-size: var(--fs-base); max-width: 40ch; }

.contact-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
  padding: var(--space-10) var(--space-8);
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-2xl);
}
.field { display: grid; gap: var(--space-2); }
.field--full { grid-column: 1 / -1; }
.field label {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: var(--track-wide);
  text-transform: uppercase;
  color: var(--text-muted);
}
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 52px;
  padding: var(--space-3) var(--space-4);
  background: var(--panel-solid);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-md);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  transition: border-color var(--dur-fast) var(--ease-out);
}
.field textarea { min-height: 148px; padding-top: var(--space-3); resize: vertical; line-height: var(--lh-body); }
.field input::placeholder,
.field textarea::placeholder { color: var(--text-faint); }
.field input:hover,
.field select:hover,
.field textarea:hover { border-color: var(--zinc-600); }
.contact-form .btn { grid-column: 1 / -1; }
.contact-form__note {
  grid-column: 1 / -1;
  color: var(--text-faint);
  font-size: var(--fs-sm);
}
.contact-form__note a { color: var(--accent); text-decoration: underline; text-underline-offset: 0.15em; }

/* ---------------------------------------------------------------------------
   13. MOTION TIER-2 STATES
   ----------------------------------------------------------------------------
   Pre-reveal hidden states apply ONLY when JS is on AND motion is permitted
   (html.js.motion). With JS off, or under reduced-motion (no .motion class),
   every element is at its natural resting state , the full document is
   readable. Motion reveals content; it never gates it.
   --------------------------------------------------------------------------- */
html.js.motion [data-reveal] { opacity: 0; transform: translateY(24px); will-change: transform, opacity; }
html.js.motion [data-reveal].is-in { opacity: 1; transform: none; }

/* Parallax planes get their transform from JS; reserve nothing extra (no CLS). */
html.js.motion [data-parallax] { will-change: transform; }

/* The craft pin stage , height reserved by JS so promotion to fixed shifts
   nothing. No hardcoded pin height here (JS measures it). */

/* will-change is stripped by JS (.motion-done) after a reveal completes. */
.motion-done { will-change: auto !important; }

/* ---------------------------------------------------------------------------
   14. REDUCED MOTION , complete, dignified static document
   --------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .scroll-cue__rail { background: var(--hairline-cyan); }
}

/* ---------------------------------------------------------------------------
   15. RESPONSIVE
   --------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .plane { grid-template-columns: auto 1fr; }
  .plane__tag { grid-column: 2; }
}

@media (max-width: 768px) {
  .site-nav__links { display: none; }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 1px solid var(--hairline);
    border-radius: var(--radius-sm);
    color: var(--text);
    cursor: pointer;
  }
  .nav-toggle svg { width: 20px; height: 20px; }

  /* Mobile nav panel (details-driven, no JS dependency) */
  .site-nav[open] .site-nav__links,
  .mobile-nav.is-open { display: flex; }
  .mobile-nav {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    background: var(--scrim-nav);
    padding: var(--space-16);
  }
  .mobile-nav a {
    color: var(--text);
    font-family: var(--font-display);
    font-size: var(--fs-3xl);
    font-weight: var(--fw-semibold);
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
  .mobile-nav a[aria-current="page"] { color: var(--accent); }
  .mobile-nav .btn { margin-top: var(--space-4); }

  .plane {
    grid-template-columns: auto 1fr;
    padding: var(--space-8) var(--space-6);
  }
  .section-head { margin-bottom: var(--space-12); }
  .site-footer__inner { flex-direction: column; align-items: flex-start; }

  /* Inner-page components collapse to one column */
  .page-hero { padding-block: calc(var(--space-24) + var(--space-8)) var(--section-y); }
  .service {
    grid-template-columns: 1fr;
    gap: var(--space-6);
    padding: var(--space-8) var(--space-6);
  }
  .callout { padding: var(--space-8) var(--space-6); }
  .contact-layout { grid-template-columns: 1fr; gap: var(--space-10); }
  .contact-form { grid-template-columns: 1fr; padding: var(--space-8) var(--space-6); }
}

@media (max-width: 400px) {
  .hero__cta { flex-direction: column; width: 100%; }
  .hero__cta .btn { width: 100%; }
}
