/* ============================================================
   RS LABS · main.css
   Dark lab instrument system. See DESIGN.md for the contract.
   ============================================================ */

/* ---------- tokens ---------- */
:root {
  --bg:         oklch(0.09 0 0);
  --bg-deep:    oklch(0.06 0 0);
  --surface:    oklch(0.13 0.004 210);
  --surface-2:  oklch(0.16 0.005 210);
  --line:       oklch(0.24 0.006 210);
  --line-soft:  oklch(0.18 0.004 210);
  --ink:        oklch(0.96 0.005 210);
  --muted:      oklch(0.71 0.012 215);
  --faint:      oklch(0.48 0.01 215);
  --signal:     oklch(0.86 0.06 208);  /* glacial trace: pale frost, chroma ceiling 0.07 */
  --signal-dim: oklch(0.60 0.05 208);
  --signal-ink: oklch(0.15 0.02 208);
  --steel:      oklch(0.74 0.10 240);  /* focus ring + the cool data series in plates */
  --amber:      oklch(0.82 0.17 86);   /* warm data series, INSIDE chart plates only */
  --alert:      oklch(0.62 0.19 25);   /* errors only */

  --font-sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Spline Sans Mono", "SF Mono", Menlo, monospace;

  --wdth-disp: 125;
  --wdth-body: 100;

  --s-1: 0.5rem;
  --s0: 0.75rem;
  --s1: 1rem;
  --s2: 1.5rem;
  --s3: clamp(2rem, 3vw, 3rem);
  --s4: clamp(3rem, 5vw, 5rem);
  --s5: clamp(4.5rem, 8vw, 8rem);
  --s6: clamp(6rem, 12vw, 12rem);

  --pad-x: clamp(1.25rem, 4vw, 4rem);
  --nav-h: 4rem;

  --z-hud: 40;
  --z-nav: 50;
  --z-noise: 60;
  --z-cursor: 70;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 0.55s;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; }
html.anim { scroll-behavior: auto; } /* Lenis (or QA static mode) owns scrolling */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-variation-settings: "wdth" var(--wdth-body);
  font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img, canvas, svg, video { display: block; max-width: 100%; }
button, input, textarea { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }

::selection { background: var(--signal); color: var(--signal-ink); }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 5px; border: 2px solid var(--bg-deep); }

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

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1, h2, h3 { text-wrap: balance; line-height: 1.04; }
p { text-wrap: pretty; }

/* ---------- chrome: noise, cursor, hud ---------- */
.noise {
  position: fixed; inset: 0; z-index: var(--z-noise);
  pointer-events: none;
  /* texture tile injected at runtime (js/main.js initNoise) */
}

.cursor { position: fixed; inset: 0; z-index: var(--z-cursor); pointer-events: none; display: none; }
.cursor-dot, .cursor-ring {
  position: absolute; top: 0; left: 0;
  border-radius: 50%; will-change: transform;
}
.cursor-dot { width: 6px; height: 6px; background: var(--signal); margin: -3px 0 0 -3px; }
.cursor-ring {
  width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border: 1px solid var(--signal-dim);
  transition: border-color 0.25s, opacity 0.25s;
}
body.has-cursor { cursor: none; }
body.has-cursor a, body.has-cursor button, body.has-cursor input,
body.has-cursor textarea, body.has-cursor [data-cursor] { cursor: none; }

.hud { position: fixed; inset: 0; z-index: var(--z-hud); pointer-events: none; opacity: 0; }
.hud-item {
  position: absolute; display: flex; gap: 0.75em;
  font-family: var(--font-mono); font-size: 0.66rem; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint);
}
.hud-item span:last-child { color: var(--muted); font-variant-numeric: tabular-nums; }
.hud-bl { left: var(--pad-x); bottom: 1.1rem; }
.hud-br { right: var(--pad-x); bottom: 1.1rem; }
.hud-tr { right: var(--pad-x); top: calc(var(--nav-h) + 0.6rem); }

.tick {
  display: inline-block; width: 7px; height: 7px; margin-right: 0.7em;
  background: var(--signal); border-radius: 1px;
  animation: tick-blink 2.4s steps(1) infinite;
}
.tick-live { animation-duration: 1.2s; }
@keyframes tick-blink { 0%, 70% { opacity: 1; } 71%, 100% { opacity: 0.25; } }

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: var(--z-nav);
  height: var(--nav-h);
  display: flex; align-items: center; gap: var(--s2);
  padding-inline: var(--pad-x);
  border-bottom: 1px solid transparent;
  transition: border-color 0.4s, background-color 0.4s, backdrop-filter 0.4s;
}
.nav.is-scrolled {
  background: color-mix(in oklab, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line-soft);
}
.nav-brand {
  display: flex; align-items: center; gap: 0.6rem;
  font-variation-settings: "wdth" var(--wdth-disp);
  font-weight: 740; font-size: 1.02rem; letter-spacing: -0.01em;
  margin-right: auto;
}
.brand-glyph { width: 34px; height: 20px; color: var(--signal); flex: none; }
.nav-links { display: flex; gap: var(--s2); }
.nav-links a {
  font-size: 0.86rem; font-weight: 500; color: var(--muted);
  transition: color 0.25s;
}
.nav-links a:hover { color: var(--ink); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0.6em; padding: 0.72em 1.5em;
  font-size: 0.9rem; font-weight: 600; letter-spacing: 0.01em;
  border: 1px solid transparent; border-radius: 3px;
  transition: transform 0.25s var(--ease-out), background-color 0.25s,
              border-color 0.25s, color 0.25s, box-shadow 0.25s;
  user-select: none;
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn-signal {
  background: var(--signal); color: var(--signal-ink);
  box-shadow: 0 0 0 0 oklch(0.86 0.06 208 / 0);
}
.btn-signal:hover {
  background: oklch(0.91 0.06 208);
  box-shadow: 0 0 32px -6px oklch(0.86 0.06 208 / 0.4);
}
.btn-ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--signal-dim); color: var(--signal); }
.btn-lg { padding: 0.9em 2.1em; font-size: 1rem; }
.nav-cta { padding: 0.55em 1.15em; font-size: 0.82rem; }

.inline-link {
  color: var(--signal);
  border-bottom: 1px solid var(--signal-dim);
  transition: border-color 0.25s, color 0.25s;
}
.inline-link:hover { color: oklch(0.92 0.055 208); border-bottom-color: var(--signal); }

/* ---------- shared section furniture ---------- */
section { position: relative; }

.section-head {
  padding: var(--s5) var(--pad-x) var(--s3);
  max-width: 72rem;
}
.section-title {
  font-variation-settings: "wdth" var(--wdth-disp);
  font-weight: 780;
  font-size: clamp(2.5rem, 6vw, 5rem);
  letter-spacing: -0.025em;
  text-transform: none;
}
.section-intro {
  margin-top: var(--s2);
  max-width: 46ch;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.2vw, 1.2rem);
}

/* ============================================================
   01 · HERO
   ============================================================ */
.hero {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: calc(var(--nav-h) + var(--s3)) var(--pad-x) var(--s4);
  overflow: clip;
}
.hero-wave {
  position: absolute; inset: 0; width: 100%; height: 100%;
  z-index: 0; opacity: 0.9;
}
.hero-artifact {
  position: absolute; z-index: 1;
  right: clamp(-6rem, 2vw, 6rem);
  inset-block: 0; margin-block: auto; height: fit-content;
  width: clamp(300px, 34vw, 520px);
  pointer-events: none;
}
/* the glow is a light source centered on the seam, never a border around the photo
   (drop-shadow on the figure traced the image rectangle and outlined it) */
.hero-artifact::before {
  content: ""; position: absolute; inset: -18% -30%;
  background: radial-gradient(ellipse 42% 46% at 50% 50%, oklch(0.86 0.06 208 / 0.11), transparent 72%);
}
.hero-artifact img {
  position: relative;
  width: 100%; height: auto;
  /* photo bounds dissolve into the page: fade the outer 12% x / 7% y */
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 12%, #000 88%, transparent 100%),
    linear-gradient(180deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, transparent 0, #000 12%, #000 88%, transparent 100%),
    linear-gradient(180deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  mask-composite: intersect;
}

.hero-inner { position: relative; z-index: 2; max-width: 64rem; }
.hero-id { color: var(--muted); margin-bottom: var(--s2); }
.hero-title {
  font-variation-settings: "wdth" var(--wdth-disp);
  font-weight: 800;
  font-size: clamp(2.85rem, 7vw, 6rem);
  letter-spacing: -0.03em;
  line-height: 0.99;
}
.hero-title em {
  font-style: italic;
  color: var(--signal);
  letter-spacing: -0.02em;
}
.line-mask { display: block; overflow: clip; padding-block: 0.04em; }
.line { display: block; will-change: transform; }

.hero-sub {
  margin-top: var(--s2);
  max-width: 44ch;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.3vw, 1.25rem);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--s1); margin-top: var(--s3); }

.hero-scrollcue {
  position: absolute; z-index: 2;
  left: 50%; transform: translateX(-50%);
  bottom: 1.1rem;
  display: flex; align-items: center; gap: 1rem;
  color: var(--faint); font-size: 0.66rem;
}
@media (max-height: 720px) { .hero-scrollcue { display: none; } }
.scrollcue-track {
  position: relative; width: 1px; height: 44px;
  background: var(--line); overflow: hidden;
}
.scrollcue-dot {
  position: absolute; left: -1px; top: -10px;
  width: 3px; height: 10px; background: var(--signal);
  animation: cue-fall 2s var(--ease-out) infinite;
}
@keyframes cue-fall { 0% { top: -12px; } 70%, 100% { top: 48px; } }

/* ============================================================
   02 · MANIFESTO
   ============================================================ */
.manifesto { background: var(--bg); }
.manifesto-pin {
  min-height: 100svh;
  display: flex; align-items: center;
  padding-inline: var(--pad-x);
}
.manifesto-text {
  max-width: 22ch;
  font-variation-settings: "wdth" 112;
  font-weight: 680;
  font-size: clamp(1.7rem, 4.6vw, 3.9rem);
  letter-spacing: -0.02em;
  line-height: 1.14;
}
.manifesto-text .w { color: var(--ink); }

/* ============================================================
   03 · THE CORE
   ============================================================ */
/* static default: stacked, everything visible (no-JS / reduced motion) */
.core { background: var(--bg-deep); }
.core-pin { position: relative; padding: var(--s4) 0; }
.core-canvas { width: 100%; aspect-ratio: 16 / 9; } /* frames are natively glacial */
.core-captions { display: grid; gap: var(--s3); padding: var(--s3) var(--pad-x) 0; }
.core-caption { max-width: 30rem; }

/* choreographed: fullscreen pin + overlaid captions */
html.anim .core-pin {
  height: 100svh; padding: 0; overflow: clip;
  display: grid; place-items: center;
}
html.anim .core-canvas { position: absolute; inset: 0; width: 100%; height: 100%; aspect-ratio: auto; }
html.anim .core-captions { position: absolute; inset: 0; z-index: 2; pointer-events: none; display: block; padding: 0; }
html.anim .core-caption {
  position: absolute;
  left: var(--pad-x); bottom: 16vh;
}
.core-caption h2 {
  font-variation-settings: "wdth" var(--wdth-disp);
  font-weight: 760;
  font-size: clamp(1.9rem, 3.6vw, 3.1rem);
  letter-spacing: -0.02em;
}
.core-caption p { margin-top: var(--s1); color: var(--muted); max-width: 34ch; }
.core-progress {
  position: absolute; right: var(--pad-x); bottom: 6vh; z-index: 2;
  color: var(--faint); font-variant-numeric: tabular-nums;
}
.core-progress span { color: var(--signal); }
.core-progress #core-total { color: var(--faint); }

/* ============================================================
   04 · CAPABILITIES (ledger)
   ============================================================ */
.capabilities { background: var(--bg); padding-bottom: var(--s5); }
.ledger { list-style: none; padding: 0 var(--pad-x); }
.ledger-row {
  position: relative;
  display: grid;
  grid-template-columns: 7rem 1fr minmax(12rem, 20rem);
  gap: var(--s2);
  align-items: start;
  padding-block: var(--s3);
  border-top: 1px solid var(--line-soft);
}
.ledger-row:last-child { border-bottom: 1px solid var(--line-soft); }
.ledger-row::after {
  content: ""; position: absolute; left: 0; bottom: -1px;
  width: 100%; height: 1px; background: var(--signal);
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.7s var(--ease-out);
}
.ledger-row:hover::after { transform: scaleX(1); }
.ledger-idx { color: var(--faint); padding-top: 0.55rem; transition: color 0.3s; }
.ledger-row:hover .ledger-idx { color: var(--signal); }
.ledger-body h3 {
  font-variation-settings: "wdth" 116;
  font-weight: 700;
  font-size: clamp(1.5rem, 2.6vw, 2.2rem);
  letter-spacing: -0.015em;
  transition: transform 0.5s var(--ease-out);
}
.ledger-row:hover .ledger-body h3 { transform: translateX(0.35rem); }
.ledger-body p { margin-top: 0.7rem; color: var(--muted); max-width: 52ch; }
.ledger-tags {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  justify-content: flex-end; padding-top: 0.55rem;
}
.ledger-tags span {
  color: var(--muted);
  border: 1px solid var(--line-soft);
  padding: 0.34em 0.75em; border-radius: 2px;
  transition: border-color 0.3s, color 0.3s;
}
.ledger-row:hover .ledger-tags span { border-color: var(--line); color: var(--ink); }

/* ============================================================
   05 · FIELD WORK (horizontal)
   ============================================================ */
/* static default: vertical stack (no-JS / reduced motion / mobile) */
.fieldwork { background: var(--bg-deep); }
.fieldwork-pin { position: relative; padding-block: var(--s3); }
.fieldwork-track {
  display: flex; flex-direction: column; align-items: stretch;
  gap: var(--s2);
  padding-inline: var(--pad-x);
  max-width: 76rem; margin-inline: auto; /* stacked mode: cap plates so they never outweigh the copy */
}
.fw-panel {
  position: relative;
  width: 100%;
  padding: var(--s3);
  border: 1px solid var(--line-soft);
  background: color-mix(in oklab, var(--surface) 55%, transparent);
}

/* choreographed desktop: pinned horizontal filmstrip */
@media (min-width: 761px) {
  html.anim .fieldwork-pin {
    height: 100svh; overflow: clip; padding-block: 0;
    display: flex; align-items: center;
  }
  html.anim .fieldwork-track {
    flex-direction: row; align-items: center;
    gap: clamp(1.5rem, 3vw, 3rem);
    will-change: transform;
    max-width: none; margin-inline: 0; /* filmstrip needs its full run */
  }
  html.anim .fw-panel { flex: none; width: min(74vw, 34rem); }
  html.anim .fw-panel:nth-child(even) { transform: translateY(clamp(0.8rem, 2.5vh, 2rem)); }
  html.anim .fw-panel:nth-child(odd) { transform: translateY(calc(clamp(0.8rem, 2.5vh, 2rem) * -1)); }
  html.anim .fw-intro, html.anim .fw-outro { width: min(80vw, 30rem); }
}
/* corner reticle ticks */
.fw-panel::before, .fw-panel::after {
  content: ""; position: absolute; width: 10px; height: 10px;
  border: 0 solid var(--signal-dim);
}
.fw-panel::before { top: -1px; left: -1px; border-top-width: 2px; border-left-width: 2px; }
.fw-panel::after { bottom: -1px; right: -1px; border-bottom-width: 2px; border-right-width: 2px; }

.fw-intro, .fw-outro { border: none; background: none; }
.fw-intro::before, .fw-intro::after,
.fw-outro::before, .fw-outro::after { display: none; }
.fw-intro .section-title { font-size: clamp(3rem, 7vw, 5.5rem); line-height: 0.95; }
.fw-intro .section-intro { margin-top: var(--s2); }
.fw-drag { display: none; margin-top: var(--s3); color: var(--faint); }

.fw-head {
  display: flex; justify-content: space-between;
  color: var(--faint); margin-bottom: var(--s2);
}
.fw-head .fw-domain { color: var(--signal); }
.fw-viz {
  width: 100%; aspect-ratio: 16 / 9;
  border: 1px solid var(--line-soft);
  background: var(--bg-deep);
  margin-bottom: var(--s2);
}
.fw-panel h3 {
  font-variation-settings: "wdth" 116;
  font-weight: 720;
  font-size: clamp(1.45rem, 2.4vw, 2rem);
  letter-spacing: -0.015em;
}
.fw-panel p { margin-top: 0.7rem; color: var(--muted); font-size: 0.98rem; max-width: 44ch; }
.fw-tags { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: var(--s2); color: var(--faint); }
.fw-tags span { border: 1px solid var(--line-soft); padding: 0.3em 0.7em; border-radius: 2px; }

.fw-outro h3 {
  font-variation-settings: "wdth" var(--wdth-disp);
  font-size: clamp(2rem, 4vw, 3.2rem);
  margin-bottom: var(--s3);
}
.fw-progress {
  position: absolute; left: var(--pad-x); bottom: 5vh;
  display: none; align-items: center; gap: 1rem;
  color: var(--faint); font-variant-numeric: tabular-nums;
}
@media (min-width: 761px) {
  html.anim .fw-progress { display: flex; }
  html.anim .fw-drag { display: block; }
}
.fw-bar { position: relative; width: 9rem; height: 1px; background: var(--line-soft); }
#fw-bar-fill {
  position: absolute; inset: 0;
  background: var(--signal);
  transform: scaleX(0); transform-origin: left;
}

/* ---- faithful mini-recreations (real surfaces, redrawn in site tokens) ----
   All lengths in cqw so each recreation scales like a plate/screenshot. */
.fw-viz--ui {
  container-type: inline-size;
  overflow: clip;
  pointer-events: none;
  user-select: none;
  display: flex; flex-direction: column;
  padding: 3%; /* NOT cqw: on the container itself cqw resolves against the viewport */
  color: var(--ink);
  line-height: 1.35;
}

/* LabPilot client portal · results view
   (type steps 1.7-2.9cqw transcribe the real portal's 11/12/13/14px scale) */
.pv-top { display: flex; align-items: baseline; gap: 2.6cqw; border-bottom: 1px solid var(--line-soft); padding-bottom: 2cqw; }
.pv-brand { font-size: 3.2cqw; font-weight: 700; letter-spacing: -0.01em; }
.pv-brand b { color: var(--signal); font-weight: 700; }
.pv-tag { font-size: 1.7cqw; color: var(--faint); }
.pv-nav { display: flex; gap: 2.4cqw; margin-left: auto; font-size: 2.2cqw; color: var(--faint); }
.pv-nav .on { color: var(--ink); box-shadow: 0 2px 0 -1px var(--signal); }
.pv-kbd { font-size: 1.8cqw; color: var(--faint); border: 1px solid var(--line-soft); border-radius: 0.8cqw; padding: 0.2cqw 1cqw; }
.pv-mrow { display: flex; align-items: center; gap: 2.2cqw; margin-top: 2.6cqw; }
.pv-mid { font-size: 2.9cqw; font-weight: 600; }
.pv-chip { font-size: 1.7cqw; color: var(--signal); border: 1px solid var(--signal-dim); border-radius: 99cqw; padding: 0.4cqw 1.6cqw; }
.pv-dl { margin-left: auto; font-size: 1.9cqw; color: var(--signal); border: 1px solid var(--line); border-radius: 1cqw; padding: 0.7cqw 1.8cqw; }
.pv-meta { font-size: 1.8cqw; color: var(--faint); margin-top: 1.2cqw; }
.pv-table { width: 100%; border-collapse: collapse; margin-top: 2.2cqw; }
.pv-table th {
  font-family: var(--font-mono); font-weight: 500; text-align: left;
  font-size: 1.7cqw; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--faint); padding: 0 1cqw 1.2cqw 0; border-bottom: 1px solid var(--line-soft);
}
.pv-table td { font-size: 2.2cqw; color: var(--muted); padding: 1.5cqw 1cqw 1.5cqw 0; border-bottom: 1px solid var(--line-soft); }
.pv-table tr:last-child td { border-bottom: none; }
.pv-table td:nth-child(1), .pv-table td:nth-child(3) { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.pv-table td:nth-child(2) { color: var(--ink); }
.pv-pass { color: var(--signal); }
.pv-prelim { font-style: italic; text-decoration: underline dashed; text-underline-offset: 0.3em; }
.pv-testing { color: var(--faint); }
.pv-pdf { font-family: var(--font-mono); color: var(--signal); }
.pv-none { color: var(--faint); text-align: left; }

/* Slate · week board (day/week/month work orders) */
.sv-head { display: flex; align-items: center; gap: 2cqw; }
.sv-pill { font-size: 2cqw; color: var(--muted); border: 1px solid var(--line); border-radius: 99cqw; padding: 0.6cqw 2cqw; }
.sv-period { margin-inline: auto; font-size: 2.6cqw; font-weight: 600; display: flex; gap: 1.6cqw; align-items: center; }
.sv-period i { font-style: normal; color: var(--faint); font-size: 2.8cqw; }
.sv-add { width: 4.6cqw; height: 4.6cqw; border: 1px solid var(--line); border-radius: 50%; color: var(--signal); display: grid; place-items: center; font-size: 3cqw; line-height: 1; }
.sv-seg { display: flex; margin-top: 2.2cqw; border: 1px solid var(--line-soft); border-radius: 1.6cqw; overflow: hidden; }
.sv-seg span { flex: 1; text-align: center; font-size: 2cqw; color: var(--faint); padding: 1cqw 0; }
.sv-seg .on { background: var(--surface-2); color: var(--ink); border-radius: 1.4cqw; }
.sv-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1cqw; margin-top: 2.4cqw; }
.sv-day {
  border: 1px solid var(--line-soft); border-radius: 3.1cqw; /* real tile: radius 28 at 72pt height */
  background: color-mix(in oklab, var(--surface) 55%, transparent);
  text-align: center; padding: 1cqw 0 1.2cqw;
}
.sv-day em { display: block; font-style: normal; font-size: 1.7cqw; color: var(--faint); }
.sv-day b { font-size: 2.5cqw; font-weight: 600; color: var(--muted); }
.sv-now { background: color-mix(in oklab, var(--signal) 13%, transparent); border-color: var(--signal-dim); }
.sv-now b { color: var(--ink); }
.sv-lanes { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1.2cqw 1cqw; margin-top: 2cqw; }
.sv-bar {
  --wo: var(--signal);
  display: flex; align-items: center; gap: 1.4cqw;
  height: 5.4cqw; border-radius: 2cqw; padding-inline: 1cqw;
  background: color-mix(in oklab, var(--wo) 12%, transparent);
  border: 1px solid color-mix(in oklab, var(--wo) 18%, transparent);
  font-size: 1.9cqw; font-weight: 600; color: var(--wo);
  white-space: nowrap; overflow: hidden;
}
.sv-bar b { flex: none; width: 3.4cqw; height: 3.4cqw; border-radius: 50%; background: var(--wo); color: var(--signal-ink); display: grid; place-items: center; font-size: 1.4cqw; font-weight: 700; letter-spacing: 0.02em; }
.sv-bar-b { --wo: var(--muted); }
.sv-bar-c { --wo: var(--signal-dim); }
.sv-bar-c b, .sv-bar-b b { color: var(--bg-deep); }
.sv-b1 { grid-column: 2 / 5; }
.sv-b2 { grid-column: 3 / 7; grid-row: 2; }
.sv-b3 { grid-column: 1 / 3; grid-row: 3; }
.sv-foot { margin-top: auto; font-size: 1.7cqw; color: var(--faint); border-top: 1px solid var(--line-soft); padding-top: 1.8cqw; }

/* ============================================================
   06 · METHOD
   ============================================================ */
.method { background: var(--bg); padding-bottom: var(--s4); }
.method-rail {
  position: relative;
  display: grid; grid-template-columns: 4rem 1fr;
  padding-inline: var(--pad-x);
  max-width: 76rem;
}
.method-line {
  width: 2px; height: 100%;
  justify-self: center;
  color: var(--line-soft);
  overflow: visible;
}
#method-trace { color: var(--signal); }
.method-steps { list-style: none; padding: 0; display: grid; gap: var(--s4); }
.method-step { max-width: 40rem; }
.method-meta {
  display: flex; gap: 1.5rem;
  color: var(--faint); margin-bottom: 0.8rem;
}
.method-meta .method-phase { color: var(--signal); }
.method-step h3 {
  font-variation-settings: "wdth" var(--wdth-disp);
  font-weight: 750;
  font-size: clamp(1.7rem, 3vw, 2.6rem);
  letter-spacing: -0.02em;
}
.method-step p { margin-top: 0.6rem; color: var(--muted); max-width: 46ch; }
.method-foot {
  margin-top: var(--s4);
  padding-inline: var(--pad-x);
  color: var(--faint);
}

/* ============================================================
   07 · TRANSMISSION (form)
   ============================================================ */
.transmission {
  background: var(--bg-deep);
  padding-bottom: var(--s5);
  border-top: 1px solid var(--line-soft);
}
.tx {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(20rem, 0.85fr);
  gap: var(--s4);
  padding-inline: var(--pad-x);
  align-items: start;
}
.tx-steps { display: grid; gap: var(--s3); }
.tx-group { border: none; padding: 0; }
.tx-q {
  display: flex; align-items: baseline; gap: 1rem;
  font-variation-settings: "wdth" 112;
  font-weight: 650;
  font-size: clamp(1.15rem, 1.6vw, 1.45rem);
  letter-spacing: -0.01em;
  margin-bottom: var(--s2);
}
.tx-qnum { color: var(--signal); }

.chip-row { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.chip {
  padding: 0.6em 1.2em;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.92rem; font-weight: 500;
  transition: border-color 0.25s, color 0.25s, background-color 0.25s, transform 0.25s var(--ease-out);
}
.chip:hover { border-color: var(--signal-dim); color: var(--ink); transform: translateY(-1px); }
.chip[aria-pressed="true"] {
  background: var(--signal); border-color: var(--signal);
  color: var(--signal-ink); font-weight: 600;
}

.dial { max-width: 30rem; }
.dial input[type="range"] {
  width: 100%; appearance: none; -webkit-appearance: none;
  height: 26px; background: transparent; cursor: pointer;
}
.dial input[type="range"]::-webkit-slider-runnable-track {
  height: 2px; background: var(--line);
}
.dial input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 14px; height: 22px; margin-top: -10px;
  background: var(--signal); border-radius: 2px;
  box-shadow: 0 0 18px -2px oklch(0.86 0.06 208 / 0.55);
}
.dial input[type="range"]::-moz-range-track { height: 2px; background: var(--line); }
.dial input[type="range"]::-moz-range-thumb {
  width: 14px; height: 22px; border: none;
  background: var(--signal); border-radius: 2px;
}
.dial-scale {
  display: flex; justify-content: space-between;
  margin-top: 0.7rem; color: var(--faint);
}
.dial-scale span.is-active { color: var(--signal); }

.tx-fields { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s2); }
.field { display: grid; gap: 0.5rem; }
.field-wide { grid-column: 1 / -1; }
.field-label { color: var(--faint); }
.field input, .field textarea {
  background: transparent;
  border: none; border-bottom: 1px solid var(--line);
  padding: 0.55em 0.1em;
  border-radius: 0;
  color: var(--ink);
  transition: border-color 0.3s;
}
.field textarea { resize: vertical; min-height: 6.5rem; line-height: 1.55; }
.field input::placeholder, .field textarea::placeholder { color: var(--faint); opacity: 1; }
.field input:focus, .field textarea:focus { outline: none; border-bottom-color: var(--steel); }
.field input.is-invalid, .field textarea.is-invalid { border-bottom-color: var(--alert); }

.tx-actions { display: flex; align-items: center; flex-wrap: wrap; gap: var(--s1); margin-top: var(--s1); }
.tx-note { width: 100%; margin-top: 0.6rem; color: var(--faint); text-transform: none; letter-spacing: 0.04em; }
.tx-note.is-ok { color: var(--signal); }
.tx-note.is-err { color: var(--alert); }

.tx-console {
  position: sticky; top: calc(var(--nav-h) + var(--s2));
  border: 1px solid var(--line-soft);
  background: color-mix(in oklab, var(--surface) 70%, transparent);
  min-height: 24rem;
  display: flex; flex-direction: column;
}
.tx-console-head {
  display: flex; align-items: center;
  padding: 0.8rem 1.1rem;
  border-bottom: 1px solid var(--line-soft);
  color: var(--faint);
}
.tx-console-body {
  flex: 1;
  padding: 1.1rem;
  font-size: 0.78rem; line-height: 1.9;
  letter-spacing: 0.02em; text-transform: none;
  color: var(--muted);
  white-space: pre-wrap; word-break: break-word;
  overflow: auto;
}
.tx-console-body .c-key { color: var(--faint); }
.tx-console-body .c-val { color: var(--signal); }
.tx-console-body .c-rule { color: var(--line); }
.tx-console-body .c-ok { color: var(--signal); }
.tx-console-body::after {
  content: "▌"; color: var(--signal);
  animation: caret 1.1s steps(1) infinite;
}
@keyframes caret { 50% { opacity: 0; } }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--bg-deep);
  border-top: 1px solid var(--line-soft);
  padding: var(--s4) var(--pad-x) var(--s2);
  overflow: clip;
}
.footer-mark {
  font-variation-settings: "wdth" var(--wdth-disp);
  font-weight: 800;
  font-size: clamp(4.5rem, 16vw, 15rem);
  line-height: 0.9;
  letter-spacing: -0.03em;
  color: transparent;
  -webkit-text-stroke: 1px var(--line);
  user-select: none;
}
.footer-grid {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: var(--s3); flex-wrap: wrap;
  margin-top: var(--s3);
}
.footer-line { max-width: 34ch; color: var(--muted); }
.footer-contact { display: grid; gap: 0.6rem; justify-items: end; }
.footer-contact .inline-link { font-size: clamp(1.2rem, 2vw, 1.6rem); font-weight: 600; }
.footer-sla { color: var(--faint); }
.footer-base {
  display: flex; justify-content: space-between; gap: var(--s2); flex-wrap: wrap;
  margin-top: var(--s4);
  padding-top: var(--s2);
  border-top: 1px solid var(--line-soft);
  color: var(--faint);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .hud { display: none; }
  .ledger-row { grid-template-columns: 4.5rem 1fr; }
  .ledger-tags { grid-column: 2; justify-content: flex-start; padding-top: var(--s1); }
  .tx { grid-template-columns: 1fr; }
  .tx-console { position: static; min-height: 18rem; order: 2; }
}

@media (max-width: 760px) {
  .nav-links { display: none; }
  .hero-artifact {
    right: -22%; width: min(72vw, 380px); opacity: 0.5;
    filter: drop-shadow(0 0 60px oklch(0.7 0.12 188 / 0.1));
  }
  .hero-inner { max-width: 100%; }
  .hero-scrollcue { display: none; }
  .core-caption { bottom: 10vh; right: var(--pad-x); }
  .tx-fields { grid-template-columns: 1fr; }
  .footer-grid { align-items: flex-start; }
  .footer-contact { justify-items: start; }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scrollcue-dot, .tick, .tx-console-body::after { animation: none; }
  .ledger-row::after { transition: none; }
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}
