/* TRAMMEL front introduction — concept candidate.
   Modes: html.no-js (static, complete), html.js[data-motion="full"],
   html.js[data-motion="reduce"] (no travel, no tweening; instant states). */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-latin-var.woff2") format("woff2-variations"), url("../fonts/archivo-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Plex Mono";
  src: url("../fonts/plex-mono-latin-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Plex Mono";
  src: url("../fonts/plex-mono-latin-500.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

:root {
  --bg: #0d0f11;
  --bg-2: #121518;
  --bg-3: #181c20;
  --panel: #14171b;
  --line: rgba(214, 222, 230, 0.12);
  --line-2: rgba(214, 222, 230, 0.22);
  --text: #e8ecef;
  --text-2: #b6bec6;
  --text-3: #8f99a3;
  --steel: #cfd6dc;
  --orange: #e8722a;
  --orange-hi: #ff8f45;
  --orange-ink: #0d0f11;
  --sans: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
  --header-h: 64px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --maxw: 1320px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
  color-scheme: dark;
}
@media (max-width: 719px) {
  :root { --header-h: 56px; }
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 12px);
  background: var(--bg);
}
html.js[data-motion="full"] { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: clamp(1rem, 0.96rem + 0.18vw, 1.0625rem);
  line-height: 1.6;
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg, picture { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 600; text-wrap: balance; }
abbr[title] { text-decoration: none; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; border-radius: 2px; }
main:focus { outline: none; }
::selection { background: rgba(232, 114, 42, 0.35); color: #fff; }

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.nowrap { white-space: nowrap; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed; left: 1rem; top: -4rem; z-index: 100;
  background: var(--orange); color: var(--orange-ink); font-weight: 600;
  padding: 0.7rem 1rem; text-decoration: none; transition: top 0.15s;
}
.skip-link:focus { top: 0.75rem; }

.eyebrow {
  display: flex; align-items: center; gap: 0.75rem;
  font-family: var(--mono); font-size: 0.75rem; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-2);
}
.eyebrow::before {
  content: ""; width: 1.75rem; height: 1px; flex: none;
  background: linear-gradient(90deg, var(--orange) 0 0.5rem, var(--line-2) 0.5rem);
}
.concept-tag {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--text-3);
}

/* ---------- wordmark ---------- */
.wordmark { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; color: var(--text); padding-block: 0.4rem; }
.wordmark__text {
  position: relative; display: inline-block;
  font-family: var(--sans); font-weight: 600; font-stretch: 125%;
  font-size: 1.0625rem; letter-spacing: 0.22em; line-height: 1;
  margin-right: -0.22em; /* optical: cancel trailing tracking */
  padding-bottom: 0.5rem;
}
.wordmark__text::after { /* the short orange rule from the product faceplate */
  content: ""; position: absolute; left: 50%; bottom: 0; width: 1.25rem; height: 2px;
  transform: translateX(calc(-50% - 0.11em)); background: var(--orange);
}
.wordmark--small .wordmark__text { font-size: 0.875rem; }

/* ---------- header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: rgba(13, 15, 17, 0.88); /* >= 5.4:1 for header text even over the bright head image */
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header__inner { height: 100%; display: flex; align-items: center; gap: 1.25rem; }
.site-header__status {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-3); padding-left: 1.25rem; border-left: 1px solid var(--line-2); white-space: nowrap;
}
.nav { margin-left: auto; }
.nav__list { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 0.25rem; }
.nav__link {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 0.8rem;
  font-size: 0.9375rem; color: var(--text-2); text-decoration: none; position: relative;
  transition: color 0.2s;
}
.nav__link:hover { color: var(--text); }
.nav__link[aria-current="true"] { color: var(--text); }
.nav__link[aria-current="true"]::after {
  content: ""; position: absolute; left: 0.8rem; right: 0.8rem; bottom: 8px; height: 1px; background: var(--orange);
}
.nav__link--dev { color: var(--text); }
.nav__link--dev::before {
  content: ""; width: 6px; height: 6px; margin-right: 0.5rem; background: var(--orange); border-radius: 50%;
}
.nav__motion { margin-left: 0.5rem; padding-left: 0.75rem; border-left: 1px solid var(--line-2); }
.motion-toggle {
  display: inline-flex; align-items: center; gap: 0.55rem; min-height: 44px; padding: 0 0.5rem;
  background: none; border: 0; color: var(--text-2); font: 500 0.75rem/1 var(--mono);
  letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer;
}
.motion-toggle:hover { color: var(--text); }
.motion-toggle__switch {
  position: relative; width: 26px; height: 14px; border-radius: 7px; border: 1px solid var(--line-2);
  background: var(--bg-3); transition: background 0.2s, border-color 0.2s;
}
.motion-toggle__switch::after {
  content: ""; position: absolute; top: 2px; left: 2px; width: 8px; height: 8px; border-radius: 50%;
  background: var(--text-3); transition: transform 0.2s var(--ease), background 0.2s;
}
.motion-toggle[aria-pressed="true"] .motion-toggle__switch { background: rgba(232, 114, 42, 0.18); border-color: var(--orange); }
.motion-toggle[aria-pressed="true"] .motion-toggle__switch::after { transform: translateX(12px); background: var(--orange); }
.no-js .nav__motion { display: none; }
.nav-toggle { display: none; }

@media (max-width: 959px) {
  .site-header { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(13, 15, 17, 0.96); }
  .site-header__status { display: none; }
  .nav-toggle {
    display: inline-flex; align-items: center; gap: 0.6rem; margin-left: auto; min-height: 44px; padding: 0 0.25rem 0 0.75rem;
    background: none; border: 0; color: var(--text); font: 500 0.75rem/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; cursor: pointer;
  }
  .nav-toggle__bars { position: relative; width: 18px; height: 10px; }
  .nav-toggle__bars::before, .nav-toggle__bars::after {
    content: ""; position: absolute; left: 0; right: 0; height: 1.5px; background: currentColor; transition: transform 0.25s var(--ease), top 0.25s var(--ease);
  }
  .nav-toggle__bars::before { top: 0; }
  .nav-toggle__bars::after { top: 8px; }
  .nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { top: 4px; transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { top: 4px; transform: rotate(-45deg); }
  .js .nav {
    position: absolute; left: 0; right: 0; top: var(--header-h); margin: 0;
    background: rgba(13, 15, 17, 0.97); border-bottom: 1px solid var(--line);
    padding: 0.5rem var(--gutter) 1rem;
    visibility: hidden; opacity: 0; transform: translateY(-6px);
    transition: opacity 0.2s, transform 0.2s var(--ease), visibility 0s linear 0.2s;
  }
  .js .nav[data-open="true"] { visibility: visible; opacity: 1; transform: none; transition: opacity 0.2s, transform 0.2s var(--ease); }
  .js .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .js .nav__link { width: 100%; font-size: 1.0625rem; padding: 0; border-bottom: 1px solid var(--line); min-height: 52px; }
  .js .nav__link[aria-current="true"]::after { display: none; }
  .js .nav__motion { margin: 0.5rem 0 0; padding: 0; border: 0; }
  .js .nav__motion .motion-toggle { padding: 0; }
  /* Without JS the menu stays a simple visible row */
  .no-js .site-header { height: auto; }
  .no-js .site-header__inner { flex-wrap: wrap; padding-block: 0.5rem; }
  .no-js .nav-toggle { display: none; }
  .no-js .nav { margin-left: 0; width: 100%; }
  .no-js .nav__list { flex-wrap: wrap; }
  .no-js .nav__link { padding: 0 0.6rem 0 0; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.75rem;
  min-height: 52px; padding: 0 1.4rem; border-radius: 2px;
  font: 600 0.9375rem/1 var(--sans); letter-spacing: 0.01em; text-decoration: none;
  border: 1px solid transparent; cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s var(--ease);
}
.btn__arrow { font-family: var(--mono); font-weight: 500; transition: transform 0.25s var(--ease); }
.btn--primary { background: var(--orange); color: var(--orange-ink); }
.btn--primary:hover { background: var(--orange-hi); }
.btn--primary:hover .btn__arrow { transform: translateX(3px); }
.btn--ghost { color: var(--text); border-color: var(--line-2); background: rgba(255, 255, 255, 0.02); }
.btn--ghost:hover { border-color: var(--steel); background: rgba(255, 255, 255, 0.05); }
.btn--ghost:hover .btn__arrow { transform: translateY(2px); }
.btn--small { min-height: 44px; padding: 0 1rem; font-size: 0.8125rem; }

/* =================================================================== */
/* 1 · INTRO                                                            */
/* =================================================================== */
.intro {
  position: relative; overflow: clip;
  min-height: calc(100svh - var(--header-h));
  display: grid; align-items: center;
  padding-block: clamp(2.5rem, 7vh, 5.5rem) clamp(4.5rem, 11vh, 7.5rem);
  isolation: isolate;
}
.intro__bg {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 70% at 72% 46%, rgba(207, 214, 220, 0.09), transparent 70%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.014) 0 1px, transparent 1px 3px),
    linear-gradient(180deg, #111417 0%, var(--bg) 100%);
}
.intro__bg::after { /* fine measurement grid */
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(214, 222, 230, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(214, 222, 230, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(70% 80% at 65% 45%, #000 20%, transparent 75%);
  mask-image: radial-gradient(70% 80% at 65% 45%, #000 20%, transparent 75%);
}
.intro__grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center; gap: clamp(2rem, 5vw, 5rem);
}
.intro__text { position: relative; z-index: 2; display: grid; gap: 1.6rem; max-width: 36rem; }
.intro__title {
  font-size: clamp(2.9rem, 1.6rem + 4vw, 5.2rem);
  font-weight: 620; font-stretch: 108%;
  line-height: 0.98; letter-spacing: -0.028em;
}
.intro__title .nowrap { display: inline-block; font-stretch: 118%; letter-spacing: 0.015em; font-weight: 600; }
.intro__lede { font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem); color: var(--text-2); max-width: 34rem; line-height: 1.55; }
.intro__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 0.25rem; }
.spec-line {
  margin: 0.75rem 0 0; display: grid; grid-template-columns: repeat(3, auto); justify-content: start;
  border-top: 1px solid var(--line);
}
.spec-line > div { padding: 0.9rem 1.5rem 0 0; margin-right: 1.5rem; border-right: 1px solid var(--line); }
.spec-line > div:last-child { border-right: 0; margin-right: 0; }
.spec-line dt { font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3); }
.spec-line dd { margin: 0.3rem 0 0; font-size: 0.875rem; color: var(--text); }

.intro__figure { position: relative; margin: 0; display: grid; justify-items: center; gap: 1.25rem; z-index: 1; }
.head { position: relative; width: min(100%, 600px); margin-right: 8%; }
.head__picture, .head__img { width: 100%; }
.head__img { position: relative; z-index: 1; filter: drop-shadow(0 30px 40px rgba(0, 0, 0, 0.55)); }
.head__rings { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; z-index: 0; pointer-events: none; }
.head__cross { stroke: rgba(214, 222, 230, 0.16); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 2 6; }
.head__ring { fill: none; transform-box: view-box; transform-origin: 717px 640px; }
.head__ring--outer { stroke: rgba(214, 222, 230, 0.22); stroke-width: 1; vector-effect: non-scaling-stroke; }
.head__ring--ticks { stroke: rgba(214, 222, 230, 0.35); stroke-width: 14; stroke-dasharray: 0.22 2.78; }
.head__ring--major { stroke: rgba(214, 222, 230, 0.55); stroke-width: 26; stroke-dasharray: 0.35 29.65; }
.head__index { stroke: var(--orange); stroke-width: 7; stroke-linecap: square; }
.head__sweep { display: none; }
.intro__figure .concept-tag { text-align: center; margin-right: 8%; margin-top: clamp(1.5rem, 7vw, 6.5rem); position: relative; z-index: 2; }

.intro__ruler {
  position: absolute; left: 0; right: 0; bottom: 0; height: 14px; pointer-events: none;
  background:
    repeating-linear-gradient(90deg, rgba(214, 222, 230, 0.28) 0 1px, transparent 1px 80px) bottom / 100% 14px no-repeat,
    repeating-linear-gradient(90deg, rgba(214, 222, 230, 0.14) 0 1px, transparent 1px 8px) bottom / 100% 6px no-repeat;
  border-bottom: 1px solid var(--line);
}

/* Load choreography (full motion only) */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes spin-in { from { opacity: 0; transform: rotate(-24deg); } to { opacity: 1; transform: none; } }
@keyframes head-in { from { opacity: 0; transform: scale(0.965); } to { opacity: 1; transform: none; } }
@keyframes sweep { from { background-position: 130% 0; } to { background-position: -30% 0; } }
html.js[data-motion="full"] .intro__text > * { animation: rise 0.9s var(--ease) both; }
html.js[data-motion="full"] .intro__text > :nth-child(2) { animation-delay: 0.08s; }
html.js[data-motion="full"] .intro__text > :nth-child(3) { animation-delay: 0.16s; }
html.js[data-motion="full"] .intro__text > :nth-child(4) { animation-delay: 0.24s; }
html.js[data-motion="full"] .intro__text > :nth-child(5) { animation-delay: 0.32s; }
html.js[data-motion="full"] .head__picture { animation: head-in 1.2s var(--ease) 0.1s both; }
html.js[data-motion="full"] .head__ring--outer { stroke-dasharray: 1; animation: draw 1.8s var(--ease) 0.2s both; }
html.js[data-motion="full"] .head__ring--ticks,
html.js[data-motion="full"] .head__ring--major { animation: spin-in 1.6s var(--ease) 0.25s both; }
html.js[data-motion="full"] .head__sweep {
  display: block; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: linear-gradient(105deg, transparent 38%, rgba(255, 255, 255, 0.34) 50%, transparent 62%) 130% 0 / 260% 100% no-repeat;
  -webkit-mask: url("../img/head-800.webp") center / 100% 100% no-repeat;
  mask: url("../img/head-800.webp") center / 100% 100% no-repeat;
  mix-blend-mode: overlay;
  animation: sweep 2.4s var(--ease-io) 1s both;
}
.head.is-docking .head__picture, .head.is-docking .head__sweep { visibility: hidden; }

/* Flyer: the shared element that travels from the hero into the spool scene */
.flyer {
  position: fixed; left: 0; top: 0; z-index: 40; pointer-events: none;
  transform-origin: 0 0; will-change: transform, opacity;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.5));
  visibility: hidden;
}
.flyer.is-on { visibility: visible; }

/* =================================================================== */
/* 2 · HOW IT WORKS                                                     */
/* =================================================================== */
.how {
  position: relative; padding-block: clamp(3rem, 8vh, 6rem) 0;
  background: linear-gradient(180deg, var(--bg) 0%, #0f1214 50%, var(--bg) 100%);
}
.how__grid {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  grid-template-areas: "head stage" "steps stage";
  grid-template-rows: auto 1fr;
  column-gap: clamp(2rem, 4.5vw, 5rem);
}
.how__head { grid-area: head; display: grid; gap: 1.25rem; align-content: start; padding-top: clamp(1rem, 8vh, 5rem); }
.how__title { font-size: clamp(2rem, 1.3rem + 2.4vw, 3.4rem); line-height: 1.04; letter-spacing: -0.02em; font-stretch: 104%; font-weight: 600; }
.how__intro { color: var(--text-2); max-width: 32rem; }

.how__stage {
  grid-area: stage; align-self: start;
  position: sticky; top: var(--header-h);
  height: calc(100svh - var(--header-h));
  display: flex; align-items: center; justify-content: center;
}
.stage {
  margin: 0; position: relative;
  width: min(100%, calc((100svh - var(--header-h) - 8.5rem) * 1.25));
  display: grid; grid-template-columns: 1fr auto; gap: 0.75rem 1rem;
}
.stage__bar {
  grid-column: 1 / -1; display: flex; justify-content: space-between; gap: 1rem;
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3);
}
.stage__fig { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stage__count { color: var(--text-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.stage__count [data-stage-count] { color: var(--orange); }
.stage__frame {
  grid-column: 1 / -1; position: relative; aspect-ratio: 5 / 4; overflow: hidden;
  background: #0a0c0e; outline: 1px solid var(--line); outline-offset: 6px;
  contain: layout paint;
}
.stage__photo, .stage__photo img {
  position: absolute; left: 0; top: 0; width: 100%; height: 100%;
}
.stage__photo img { object-fit: cover; transform-origin: 0 0; will-change: transform, opacity; }
.stage__static { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.stage__veil { position: absolute; inset: 0; background: #0a0c0e; opacity: 0; pointer-events: none; will-change: opacity; }
.stage__overlay { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.stage__corner { position: absolute; width: 14px; height: 14px; border-color: var(--steel); border-style: solid; border-width: 0; pointer-events: none; opacity: 0.8; }
.stage__corner--tl { left: 8px; top: 8px; border-left-width: 1px; border-top-width: 1px; }
.stage__corner--tr { right: 8px; top: 8px; border-right-width: 1px; border-top-width: 1px; }
.stage__corner--bl { left: 8px; bottom: 8px; border-left-width: 1px; border-bottom-width: 1px; }
.stage__corner--br { right: 8px; bottom: 8px; border-right-width: 1px; border-bottom-width: 1px; }
.stage__legend {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 1.25rem; padding-top: 0.6rem;
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-2);
}
.legend { display: inline-flex; align-items: center; gap: 0.5rem; }
.legend::before { content: ""; width: 22px; height: 0; border-top: 1.5px dashed var(--steel); }
.legend--meas::before { border-top: 2px solid var(--orange); }
.stage__note { color: var(--text-3); }
.stage__steps { padding-top: 0.45rem; }
.stage__steps ol { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.stage__steps a {
  display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px;
  font: 500 0.75rem/1 var(--mono); color: var(--text-3); text-decoration: none; position: relative;
  transition: color 0.2s;
}
.stage__steps a::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: 9px; height: 1px; background: var(--line-2); transition: background 0.2s; }
.stage__steps a:hover { color: var(--text); }
.stage__steps a[aria-current="step"] { color: var(--text); }
.stage__steps a[aria-current="step"]::after { background: var(--orange); height: 2px; }
.no-js .stage__steps, .no-js .stage__count { display: none; }

/* overlay drawing (SVG built by site.js) */
.ov-text { font: 500 12px/1 var(--mono); fill: var(--text); letter-spacing: 0.04em; paint-order: stroke; stroke: rgba(10, 12, 14, 0.9); stroke-width: 4px; stroke-linejoin: round; }
.ov-text--dim { fill: var(--text-2); }
.ov-text--orange { fill: var(--orange-hi); }
.ov-text--big { font-size: 13px; font-weight: 500; }
.ov-halo { fill: none; stroke: rgba(10, 12, 14, 0.55); stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }
.ov-ref { fill: none; stroke: var(--steel); stroke-width: 1.6; stroke-dasharray: 7 5; stroke-linecap: butt; stroke-linejoin: round; }
.ov-leg { fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.ov-grid line { stroke: rgba(207, 214, 220, 0.075); stroke-width: 1; }
.ov-end circle { fill: #0a0c0e; stroke: var(--steel); stroke-width: 1.5; }
.ov-end line { stroke: var(--steel); stroke-width: 1; }
.ov-chip rect { fill: rgba(10, 12, 14, 0.86); stroke: var(--line-2); stroke-width: 1; }
.ov-chip--orange rect { stroke: rgba(232, 114, 42, 0.7); }
.ov-pulse circle { fill: none; stroke: var(--orange); stroke-width: 1.5; }
.ov-pulse .ov-pulse__wave { transform-box: fill-box; transform-origin: center; animation: pulse 2.2s var(--ease) infinite; }
@keyframes pulse { 0% { transform: scale(0.85); opacity: 0.9; } 100% { transform: scale(1.5); opacity: 0; } }
html[data-motion="reduce"] .ov-pulse .ov-pulse__wave { animation: none; opacity: 0; }
.ov-axes line, .ov-axes path { stroke: var(--text-2); stroke-width: 1.2; fill: none; }
.ov-axes .ov-arrowhead { fill: var(--text-2); stroke: none; }
.ov-delta .ov-refpt { fill: none; stroke: var(--steel); stroke-width: 1.4; stroke-dasharray: 3 3; }
.ov-delta .ov-refx { stroke: var(--steel); stroke-width: 1; }
.ov-delta .ov-comp { stroke: var(--orange); stroke-width: 2; fill: none; stroke-linecap: round; }
.ov-delta .ov-arrowhead { fill: var(--orange); }
.ov-delta .ov-measpt { fill: var(--orange); stroke: #0a0c0e; stroke-width: 2; }
.ov-delta .ov-measring { fill: none; stroke: var(--orange); stroke-width: 1.2; }
.ov-delta .ov-construct { stroke: rgba(207, 214, 220, 0.35); stroke-width: 1; stroke-dasharray: 2 3; fill: none; }

/* steps */
.steps { grid-area: steps; list-style: none; margin: 0; padding: 0 0 clamp(4rem, 30vh, 18rem); counter-reset: step; }
.step {
  position: relative; padding: clamp(5rem, 24vh, 14rem) 0 0;
  display: grid; gap: 1rem; max-width: 34rem;
}
.step:first-child { padding-top: clamp(4rem, 18vh, 10rem); }
.step__num {
  font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.14em; color: var(--orange);
  display: flex; align-items: center; gap: 0.75rem;
}
.step__num::after { content: ""; flex: 0 0 3rem; height: 1px; background: var(--line-2); }
.step__title { font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); letter-spacing: -0.01em; line-height: 1.15; font-stretch: 104%; }
.step p { color: var(--text-2); }
.js .step__title, .js .step p { transition: color 0.45s var(--ease); }
.js .steps[data-has-active] .step:not(.is-active) .step__title { color: var(--text-2); }
.js .steps[data-has-active] .step:not(.is-active) p { color: var(--text-3); }
.js .steps[data-has-active] .step:not(.is-active) .coord { color: var(--text-2) !important; }
.coord {
  display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; padding: 0.8rem 1rem;
  font-family: var(--mono); font-size: 0.9375rem; color: var(--text) !important; font-variant-numeric: tabular-nums;
  background: var(--panel); border-left: 2px solid var(--steel);
}
.coord abbr { color: var(--text-2); margin-right: 0.35rem; }
.step__math { font-family: var(--mono); font-size: 0.8125rem; color: var(--text-3) !important; letter-spacing: 0.02em; }
.static-fig { margin: 0.5rem 0 0; display: grid; gap: 0.5rem; }
.static-fig img { width: 100%; max-width: 30rem; background: var(--panel); border: 1px solid var(--line); }
.static-fig figcaption { font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-3); }
.js .static-fig { display: none; }
.js .stage__static { display: none; }

/* delta instrument */
.delta {
  margin-top: 0.75rem; position: relative; padding: 1.25rem 1.25rem 1.1rem;
  background: linear-gradient(180deg, #15191d, #111417); border: 1px solid var(--line-2);
}
.delta::before, .delta::after { content: ""; position: absolute; width: 10px; height: 10px; border: 0 solid var(--orange); }
.delta::before { left: -1px; top: -1px; border-left-width: 2px; border-top-width: 2px; }
.delta::after { right: -1px; bottom: -1px; border-right-width: 2px; border-bottom-width: 2px; }
.delta__table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.delta__table caption { caption-side: top; text-align: left; padding-bottom: 0.9rem; }
.delta__title { display: block; font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text); }
.delta__tag {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--orange-hi); border: 1px solid rgba(232, 114, 42, 0.55); padding: 0.15rem 0.45rem;
  display: inline-block; margin-top: 0.5rem;
}
.delta__table th, .delta__table td { padding: 0.65rem 0.5rem; border-top: 1px solid var(--line); text-align: right; white-space: nowrap; }
.delta__table thead th {
  border-top: 0; padding-top: 0; font-family: var(--mono); font-size: 0.6875rem; font-weight: 500; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--text-3); vertical-align: bottom; line-height: 1.3; white-space: normal;
}
.delta__table th:first-child { text-align: left; padding-left: 0; }
.delta__table td:last-child, .delta__table th:last-child { padding-right: 0; }
.delta__sub { display: block; text-transform: none; letter-spacing: 0.02em; color: var(--text-3); font-size: 0.6875rem; }
.delta__axis { font-family: var(--mono); font-weight: 500; font-size: 0.9375rem; color: var(--text); display: inline-block; min-width: 2.2ch; }
.delta__name { display: block; font-size: 0.75rem; font-weight: 400; color: var(--text-3); }
.delta__table td { font-family: var(--mono); font-size: 0.9375rem; color: var(--text-2); }
.delta__table td[data-col="meas"] { color: var(--text); }
.delta__table td[data-col="diff"] { color: var(--orange-hi); font-weight: 500; }
.delta__diff { display: inline-block; min-width: 4.2ch; }
.gauge {
  display: inline-block; vertical-align: middle; margin-left: 0.6rem; position: relative; width: 58px; height: 14px;
  background:
    linear-gradient(var(--text-2), var(--text-2)) 50% 100% / 1px 14px no-repeat,
    repeating-linear-gradient(90deg, rgba(214, 222, 230, 0.35) 0 1px, transparent 1px 5.7px) 0 100% / 100% 5px no-repeat;
  border-bottom: 1px solid var(--line-2);
}
.gauge__mark {
  position: absolute; bottom: 1px; width: 0; height: 0;
  left: calc(50% + (var(--v, 0) / 5) * 50%);
  border-left: 5px solid transparent; border-right: 5px solid transparent; border-bottom: 8px solid var(--orange);
  transform: translateX(-50%);
}
.gauge__mark::before { content: ""; position: absolute; left: -0.5px; bottom: -8px; width: 1px; height: 0; }
.no-js .gauge { display: none; }
.delta__convention, .delta__honesty { margin-top: 0.9rem; font-size: 0.8125rem; line-height: 1.5; color: var(--text-2) !important; }
.delta__convention strong { color: var(--text); font-weight: 600; }
.delta__honesty { color: var(--text-3) !important; padding-top: 0.75rem; border-top: 1px dashed var(--line-2); }

/* progressive reveal of the delta columns when step 4 activates (full motion) */
html.js[data-motion="full"] .delta [data-col] { transition: opacity 0.5s var(--ease), transform 0.5s var(--ease); }
html.js[data-motion="full"] .step--delta:not(.has-shown) [data-col] { opacity: 0.18; }
html.js[data-motion="full"] .step--delta:not(.has-shown) [data-col="diff"] { transform: translateX(-6px); }
html.js[data-motion="full"] .step--delta.has-shown [data-col="ref"] { transition-delay: 0.05s; }
html.js[data-motion="full"] .step--delta.has-shown [data-col="meas"] { transition-delay: 0.35s; }
html.js[data-motion="full"] .step--delta.has-shown [data-col="diff"] { transition-delay: 0.7s; }

/* =================================================================== */
/* 3 · NOTES                                                            */
/* =================================================================== */
.notes { padding-block: clamp(5rem, 14vh, 9rem); border-top: 1px solid var(--line); background: var(--bg-2); }
.notes__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2.5rem, 6vw, 6rem); }
.notes__col { display: grid; gap: 1.25rem; align-content: start; }
.notes__title { font-size: clamp(1.6rem, 1.2rem + 1.3vw, 2.3rem); letter-spacing: -0.015em; line-height: 1.1; font-stretch: 104%; }
.ruled { margin: 0.5rem 0 0; border-top: 1px solid var(--line-2); }
.ruled > div { display: grid; grid-template-columns: minmax(8.5rem, 0.36fr) 1fr; gap: 1rem; padding: 0.95rem 0; border-bottom: 1px solid var(--line); }
.ruled dt { font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text); padding-top: 0.2rem; }
.ruled dd { margin: 0; color: var(--text-2); }
.ruled--status dt { color: var(--orange-hi); }
.ruled a { color: var(--text); text-decoration-color: var(--orange); text-underline-offset: 3px; }

/* =================================================================== */
/* 4 · DEVELOPMENT                                                      */
/* =================================================================== */
.dev {
  position: relative; overflow: clip; padding-block: clamp(5rem, 16vh, 10rem);
  background:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.014) 0 1px, transparent 1px 3px),
    radial-gradient(80% 120% at 85% 0%, rgba(232, 114, 42, 0.10), transparent 60%),
    linear-gradient(180deg, #14171a, #0f1113);
  border-top: 1px solid var(--line);
}
.dev__inner { display: grid; gap: 1.25rem; }
.dev__title { font-size: clamp(2.4rem, 1.4rem + 4vw, 5rem); line-height: 1; letter-spacing: -0.03em; font-stretch: 112%; font-weight: 620; }
.dev__text { color: var(--text-2); max-width: 36rem; font-size: 1.0625rem; }
.dev__link {
  margin-top: 1.5rem; display: grid; grid-template-columns: 1fr auto; grid-template-areas: "label arrow" "path arrow";
  align-items: center; gap: 0.35rem 1.5rem; padding: 1.6rem 0;
  border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2);
  text-decoration: none; color: var(--text); position: relative;
}
.dev__link::before {
  content: ""; position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%; background: var(--orange);
  transform: scaleX(0.08); transform-origin: left; transition: transform 0.6s var(--ease);
}
.dev__link:hover::before, .dev__link:focus-visible::before { transform: scaleX(1); }
.dev__link-label { grid-area: label; font-size: clamp(1.4rem, 1rem + 1.8vw, 2.4rem); font-weight: 600; letter-spacing: -0.01em; font-stretch: 106%; }
.dev__link-path { grid-area: path; font-family: var(--mono); font-size: 0.8125rem; color: var(--text-3); letter-spacing: 0.04em; }
.dev__link-arrow {
  grid-area: arrow; font-family: var(--mono); font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.6rem); color: var(--orange);
  transition: transform 0.35s var(--ease);
}
.dev__link:hover .dev__link-arrow { transform: translateX(8px); }

/* =================================================================== */
/* 5 · CONTACT                                                          */
/* =================================================================== */
.contact { padding-block: clamp(5rem, 14vh, 9rem); border-top: 1px solid var(--line); }
.contact__inner { display: grid; gap: 1.25rem; }
.contact__title { font-size: clamp(1.6rem, 1.2rem + 1.3vw, 2.3rem); letter-spacing: -0.015em; }
.contact__text { color: var(--text-2); max-width: 34rem; }
.contact__row { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.25rem; margin-top: 0.5rem; }
.contact__mail {
  font-size: clamp(1.5rem, 1rem + 2.6vw, 3rem); font-weight: 560; font-stretch: 110%; letter-spacing: -0.01em;
  color: var(--text); text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 2px; text-underline-offset: 0.2em;
  overflow-wrap: anywhere;
}
.contact__mail:hover { color: #fff; text-decoration-color: var(--orange-hi); }
.contact__copied { font-family: var(--mono); font-size: 0.75rem; color: var(--orange-hi); letter-spacing: 0.06em; text-transform: uppercase; }

/* footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 2.5rem 3rem; background: #0b0d0f; }
.site-footer__inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1.25rem 2.5rem; }
.site-footer__note { color: var(--text-3); font-size: 0.8125rem; max-width: 34rem; }
.site-footer__links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; font-size: 0.875rem; }
.site-footer__links a { color: var(--text-2); text-decoration: none; display: inline-flex; min-height: 44px; align-items: center; }
.site-footer__links a:hover { color: var(--text); text-decoration: underline; text-decoration-color: var(--orange); }

/* =================================================================== */
/* RESPONSIVE                                                           */
/* =================================================================== */
@media (max-width: 1023px) {
  .intro { min-height: 0; }
  .intro__grid { grid-template-columns: 1fr; }
  .intro__text { max-width: 40rem; }
  .intro__figure { order: 2; padding-block: 1.5rem 0; }
  .head { width: min(78vw, 520px); margin-right: 6%; }
  .intro__figure .concept-tag { margin-right: 0; }

  .notes__grid { grid-template-columns: 1fr; }
}
/* Stacked "How it works" (stage above the steps). Short landscape phones keep the
   two-column layout instead, so the sticky stage never eats the reading area.
   Keep in sync with STACKED in site.js. */
@media (max-width: 1023px) and (orientation: portrait), (max-width: 1023px) and (min-height: 561px) {
  .how__grid { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "stage" "steps"; grid-template-rows: auto; }
  .how__head { padding-top: 0; padding-bottom: 1.5rem; }
  .how__stage {
    top: var(--header-h); height: auto; z-index: 5; display: block;
    margin-inline: calc(var(--gutter) * -1); padding: 0.75rem var(--gutter) 0.6rem;
    background: var(--bg);
  }
  .js .how__stage::after { /* soft edge below the stuck stage; text fades under it */
    content: ""; position: absolute; left: 0; right: 0; top: 100%; height: 28px; pointer-events: none;
    background: linear-gradient(180deg, var(--bg), rgba(13, 15, 17, 0));
  }
  .stage { width: min(100%, calc((46svh) * 1.25)); margin-inline: auto; gap: 0.4rem 0.75rem; }
  .stage__bar { font-size: 0.625rem; }
  .stage__legend { font-size: 0.625rem; gap: 0.3rem 0.9rem; padding-top: 0.45rem; }
  .stage__note { display: none; }
  .stage__steps { padding-top: 0.15rem; }
  .stage__steps a { min-width: 40px; min-height: 40px; }
  .steps { padding-bottom: 6rem; }
  .step { padding-top: clamp(3rem, 22svh, 10rem); max-width: 40rem; margin-inline: auto; }
  .js .step:first-child { padding-top: 38svh; } /* the docked close-up lingers before step 1 pulls back */
  .no-js .step:first-child { padding-top: 2rem; }
  .no-js .how__stage { position: static; }
}
@media (max-width: 1023px) and (orientation: landscape) and (max-height: 560px) {
  .how__grid { grid-template-columns: minmax(0, 1fr) auto; column-gap: 1.5rem; }
  .how__head { padding-top: 1rem; }
  .stage { width: calc((100svh - var(--header-h) - 7rem) * 1.25); gap: 0.3rem 0.75rem; }
  .stage__bar, .stage__legend { font-size: 0.625rem; }
  .stage__note { display: none; }
  .stage__steps a { min-width: 40px; min-height: 40px; }
  .step { padding-top: 45svh; }
  .step:first-child { padding-top: 30svh; }
}
@media (max-width: 719px) {
  .intro { padding-top: 2rem; }
  /* On phones the head follows the title, so it is on the first screen */
  .intro__grid { row-gap: 1.4rem; }
  .intro__text { display: contents; }
  .intro__text > :nth-child(1) { order: 1; }
  .intro__text > :nth-child(2) { order: 2; }
  .intro__figure { order: 3; padding-block: 0.5rem 0.25rem; gap: 0.5rem; }
  .intro__text > :nth-child(3) { order: 4; }
  .intro__text > :nth-child(4) { order: 5; }
  .intro__text > :nth-child(5) { order: 6; }
  .intro__figure .concept-tag { margin-top: clamp(1rem, 8vw, 2.5rem); }
  .intro__title { font-size: clamp(2.6rem, 1.2rem + 7vw, 3.6rem); }
  .spec-line { grid-template-columns: 1fr; }
  .spec-line > div { border-right: 0; margin-right: 0; padding: 0.7rem 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 1rem; }
  .spec-line dd { margin: 0; text-align: right; }
  .intro__actions .btn { flex: 1 1 100%; }
  .head { width: min(70vw, 330px); margin-right: 4%; }
  .stage__legend .legend::before { width: 16px; }
  .delta { padding: 1rem 0.85rem 0.9rem; margin-inline: calc(var(--gutter) * -0.4); }
  .delta__table th, .delta__table td { padding: 0.6rem 0.3rem; font-size: 0.8125rem; }
  .delta__axis { font-size: 0.875rem; }
  .delta__name { display: none; }
  .gauge { display: block; margin: 0.35rem 0 0 auto; width: 52px; }
  .ruled > div { grid-template-columns: 1fr; gap: 0.25rem; }
  .site-footer__inner { grid-template-columns: 1fr; }
  .dev__link { grid-template-columns: 1fr auto; }
}
@media (max-width: 359px) {
  .delta__table thead th { font-size: 0.625rem; }
  .delta__table td { font-size: 0.75rem; }
}

/* Reduced motion: nothing travels, nothing tweens; states switch instantly */
html[data-motion="reduce"] *, html[data-motion="reduce"] *::before, html[data-motion="reduce"] *::after {
  animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important;
  scroll-behavior: auto !important;
}
@media (prefers-reduced-motion: reduce) {
  html.no-js *, html.no-js *::before, html.no-js *::after { animation: none !important; transition: none !important; }
}

/* Without JS: the How section is a plain, complete document */
.no-js .how__grid { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "stage" "steps"; }
.no-js .how__stage { position: static; height: auto; display: block; }
.no-js .stage { width: min(100%, 860px); margin-inline: auto; }
.no-js .step { padding-top: 3.5rem; }
.no-js .steps { padding-bottom: 5rem; }

@media print {
  .site-header, .stage__steps, .motion-toggle, .flyer, .intro__ruler, .head__rings, [data-copy] { display: none !important; }
  body { background: #fff; color: #000; }
  .how__stage { position: static !important; height: auto !important; }
  .js .static-fig { display: grid; }
  .step { opacity: 1 !important; padding-top: 1.5rem !important; }
}
