/* ================================================================
   ARTIFICE — Switzer (body/UI) + Fragment Mono (apparatus);
   Instrument Serif reserved for headlines. #050505 / #EAEAEA.
   Landing is a single fixed view; the report scrolls.
   ================================================================ */

:root {
  --bg: #050505;
  --ink: #eaeaea;
  --ink-2: rgba(234, 234, 234, 0.72);
  --ink-3: rgba(234, 234, 234, 0.5);
  --ink-4: rgba(234, 234, 234, 0.26);
  --hair: rgba(234, 234, 234, 0.14);
  --hair-2: rgba(234, 234, 234, 0.07);
  --sans: "Switzer", -apple-system, "Helvetica Neue", sans-serif;
  --serif: "Instrument Serif", "Times New Roman", Georgia, serif; /* headlines only */
  --mono: "Fragment Mono", "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(0.19, 1, 0.22, 1);
  --gutter: clamp(20px, 4.5vw, 64px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body[data-page="landing"] { height: 100vh; overflow: hidden; }

::selection { background: var(--ink); color: var(--bg); }
a { color: inherit; }
:focus-visible { outline: 1px solid var(--ink); outline-offset: 3px; }

/* apparatus label */
.mono {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 400;
}

/* brand lockup */
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; }
.brand-mark { width: 24px; height: 24px; color: var(--ink); transition: transform 0.8s var(--ease); }
.brand:hover .brand-mark { transform: rotate(90deg); }
.brand-word { font-family: var(--sans); font-size: 17px; font-weight: 500; letter-spacing: 0.01em; }

/* reveal */
.rv { opacity: 0; transform: translateY(20px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); transition-delay: var(--d, 0s); }
.rv.in { opacity: 1; transform: none; }

/* ================================================================
   LANDING
   ================================================================ */
.landing {
  position: relative;
  height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px var(--gutter);
}
.landing #field { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.landing-inner { position: relative; max-width: 600px; width: 100%; }
.landing-lockup { display: flex; align-items: center; gap: 16px; margin-bottom: 34px; }
.landing-mark { width: 40px; height: 40px; color: var(--ink); transition: transform 0.9s var(--ease); }
.landing-lockup:hover .landing-mark { transform: rotate(90deg); }
.landing-word { font-family: var(--sans); font-size: 34px; font-weight: 500; letter-spacing: -0.02em; line-height: 1; }
.landing-para {
  font-family: var(--serif);
  font-size: clamp(25px, 3vw, 33px);
  line-height: 1.32;
  color: var(--ink);
  margin-bottom: 30px;
}
.landing-para em { font-style: italic; }
.landing-para a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--ink-3);
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
  transition: text-decoration-color 0.35s var(--ease);
}
.landing-para a:hover { text-decoration-color: var(--ink); }
.landing-by { font-family: var(--sans); font-size: 15px; color: var(--ink-3); }
.landing-by a {
  color: var(--ink-2);
  text-decoration: underline;
  text-decoration-color: var(--ink-4);
  text-underline-offset: 3px;
  transition: color 0.35s var(--ease), text-decoration-color 0.35s var(--ease);
}
.landing-by a:hover { color: var(--ink); text-decoration-color: var(--ink); }

/* ================================================================
   REPORT — scrolling
   ================================================================ */
.progress { position: fixed; inset: 0 0 auto 0; height: 1px; z-index: 60; background: transparent; }
.progress span { display: block; height: 100%; width: 100%; background: var(--ink); transform-origin: 0 0; transform: scaleX(0); }

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px var(--gutter);
  border-bottom: 1px solid transparent;
  transition: border-color 0.5s var(--ease), background 0.5s var(--ease);
}
.nav.is-scrolled {
  border-bottom-color: var(--hair);
  background: rgba(5, 5, 5, 0.82);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.nav-links { display: flex; gap: 24px; }
.nav-links a {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  text-decoration: none; color: var(--ink-3); padding-bottom: 2px;
  background-image: linear-gradient(var(--ink), var(--ink));
  background-repeat: no-repeat; background-size: 0% 1px; background-position: 0 100%;
  transition: color 0.35s var(--ease), background-size 0.45s var(--ease);
}
.nav-links a:hover, .nav-links a.is-active { color: var(--ink); background-size: 100% 1px; }
.nav-meta { color: var(--ink-3); white-space: nowrap; }

/* sections */
.sec {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(0, 3.4fr);
  gap: 40px;
  padding: 108px var(--gutter);
  border-top: 1px solid var(--hair-2);
  scroll-margin-top: 76px;
}
/* first section clears the fixed nav (no hero) */
main > .sec:first-child { border-top: none; padding-top: 132px; }
.sec-rail { display: flex; flex-direction: column; gap: 8px; color: var(--ink-3); }
.sec-rail .sec-no { font-size: 12px; }
.sec-rail .sec-name { color: var(--ink-2); }
.sec-rail > span { position: sticky; top: 96px; }
.sec-rail .sec-name { top: 116px; }
.sec-body { max-width: 900px; }

/* shared typography */
.lede {
  font-family: var(--serif);
  font-size: clamp(28px, 3.6vw, 44px);
  line-height: 1.14;
  letter-spacing: -0.005em;
  margin-bottom: 34px;
  max-width: 20em;
}
.lede em { font-style: italic; }
.body { color: var(--ink-2); font-size: 18px; line-height: 1.6; max-width: 34em; margin-bottom: 20px; }
.body:last-child { margin-bottom: 0; }
.body em { font-style: italic; color: var(--ink); }
.body strong { font-weight: 500; color: var(--ink); }
.body code, .engine-body code { font-family: var(--mono); font-size: 0.82em; border: 1px solid var(--hair); padding: 1px 5px; border-radius: 3px; color: var(--ink); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 46px; }
.fig-caption { font-family: var(--mono); color: var(--ink-3); text-transform: none; letter-spacing: 0.02em; font-size: 11px; line-height: 1.65; margin-top: 14px; max-width: 54em; }
.fig-caption em { font-style: italic; }

/* two engines */
.engines { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--hair); border: 1px solid var(--hair); margin: 0 0 34px; }
.engine { background: var(--bg); padding: 26px 28px; }
.engine-tag { color: var(--ink-3); margin-bottom: 14px; }
.engine-name { font-family: var(--serif); font-weight: 400; font-size: 30px; line-height: 1; margin-bottom: 14px; color: var(--ink); }
.engine-body { color: var(--ink-2); font-size: 16px; line-height: 1.55; }
.engine-body em { font-style: italic; color: var(--ink); }

/* citations */
.cite { text-decoration: none; color: var(--ink-3); }
.cite sup { font-family: var(--mono); font-size: 10px; padding: 1px 3px; margin-left: 1px; border-radius: 2px; transition: background 0.25s var(--ease), color 0.25s var(--ease); }
.cite:hover sup, .cite.is-lit sup { background: var(--ink); color: var(--bg); }
.cite-tip {
  position: fixed; z-index: 90; max-width: 340px; padding: 12px 15px;
  background: #0b0b0b; border: 1px solid var(--hair); color: var(--ink-2);
  font-family: var(--sans); letter-spacing: 0.01em; font-size: 13px; line-height: 1.5;
  pointer-events: none; opacity: 0; transform: translateY(4px);
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}
.cite-tip.is-on { opacity: 1; transform: translateY(0); }

/* pipeline */
.pipeline { margin: 0 0 40px; }
.pipe-track { position: relative; height: 1px; background: var(--hair); margin-bottom: -1px; }
.pipe-dot { position: absolute; top: -2px; left: 0; width: 5px; height: 5px; border-radius: 50%; background: var(--ink); transition: left 0.9s var(--ease); }
.pipe-stages { list-style: none; display: grid; grid-template-columns: repeat(5, 1fr); }
.stage { padding: 20px 12px 20px 0; border-top: 1px solid transparent; cursor: pointer; transition: border-color 0.4s var(--ease); }
.stage-btn { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.stage-no { display: block; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-4); margin-bottom: 7px; transition: color 0.35s var(--ease); }
.stage-name { font-family: var(--sans); font-size: 18px; color: var(--ink-3); transition: color 0.35s var(--ease); }
.stage:hover .stage-name, .stage.is-active .stage-name { color: var(--ink); }
.stage:hover .stage-no, .stage.is-active .stage-no { color: var(--ink-2); }
.stage.is-active { border-top-color: var(--ink); }
.stage-detail { border: 1px solid var(--hair-2); padding: 22px 26px; min-height: 108px; margin-top: 8px; }
.stage-detail-label { margin-bottom: 8px; }
.stage-detail-text { color: var(--ink-2); font-size: 17px; line-height: 1.55; max-width: 46em; }

/* fig 1 · spec replay */
.fig { border: 1px solid var(--hair); }
.fig-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--hair); }
.fig-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.tab { background: none; border: 1px solid transparent; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); padding: 6px 12px; cursor: pointer; transition: color 0.3s var(--ease), border-color 0.3s var(--ease); }
.tab:hover { color: var(--ink); }
.tab.is-active { color: var(--ink); border-color: var(--hair); }
.replay { background: none; border: none; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); cursor: pointer; padding: 6px 0; transition: color 0.3s var(--ease); }
.replay:hover { color: var(--ink); }
.fig-panes { display: grid; grid-template-columns: 1.1fr 1fr; }
.pane { min-width: 0; }
.pane-spec { border-right: 1px solid var(--hair); }
.pane-label { color: var(--ink-3); padding: 10px 16px; border-bottom: 1px solid var(--hair-2); }
#specStream { height: clamp(300px, 42vh, 440px); overflow: hidden; padding: 16px; }
#specStream code { font-family: var(--mono); font-size: 12.5px; line-height: 1.7; white-space: pre-wrap; word-break: break-word; color: var(--ink-3); }
#specStream .j-str { color: var(--ink); }
#specStream .j-type { color: var(--ink); background: rgba(234, 234, 234, 0.09); padding: 0 2px; }
#specStream .caret { display: inline-block; width: 5px; height: 13px; background: var(--ink); vertical-align: -2px; animation: caret-blink 0.9s steps(1) infinite; }
@keyframes caret-blink { 50% { opacity: 0; } }
.pane-render { display: flex; flex-direction: column; }
.wf-window { flex: 1; display: flex; flex-direction: column; margin: 16px; border: 1px solid var(--hair); border-radius: 8px; overflow: hidden; background: rgba(234,234,234,0.015); }
.wf-chrome { display: flex; align-items: center; gap: 6px; padding: 9px 11px; border-bottom: 1px solid var(--hair-2); }
.wf-light { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--ink-4); }
.wf-title { margin-left: 10px; color: var(--ink-3); }
.wf-stage { flex: 1; padding: 16px; display: flex; flex-direction: column; gap: 12px; overflow: hidden; }
.wf { opacity: 0; transform: translateY(10px); animation: wf-in 0.6s var(--ease) forwards; }
@keyframes wf-in { to { opacity: 1; transform: none; } }
.wf-heading { height: 15px; width: 46%; background: var(--ink-2); border-radius: 3px; }
.wf-row { display: flex; gap: 12px; }
.wf-row > * { flex: 1; }
.wf-slider { padding: 5px 0; }
.wf-slider .wf-cap { height: 7px; width: 42%; background: var(--ink-4); border-radius: 2px; margin-bottom: 9px; }
.wf-slider .wf-track { position: relative; height: 2px; background: var(--hair); border-radius: 1px; }
.wf-slider .wf-thumb { position: absolute; top: -4px; left: 60%; width: 10px; height: 10px; border-radius: 50%; background: var(--ink); animation: thumb-drift 5s ease-in-out infinite alternate; }
.wf-slider:nth-child(2) .wf-thumb { animation-delay: -2.4s; }
@keyframes thumb-drift { from { left: 22%; } to { left: 74%; } }
.wf-table { border: 1px solid var(--hair-2); border-radius: 6px; overflow: hidden; }
.wf-thead { display: flex; gap: 10px; padding: 8px 11px; border-bottom: 1px solid var(--hair-2); background: rgba(234,234,234,0.03); }
.wf-thead span { height: 6px; flex: 1; background: var(--ink-4); border-radius: 2px; }
.wf-tr { display: flex; gap: 10px; padding: 8px 11px; border-bottom: 1px solid var(--hair-2); }
.wf-tr:last-child { border-bottom: none; }
.wf-tr span { height: 6px; flex: 1; background: rgba(234,234,234,0.14); border-radius: 2px; }
.wf-tr span:last-child { background: var(--ink-2); }
.wf-stat { border: 1px solid var(--hair-2); border-radius: 6px; padding: 11px 13px; width: 46%; }
.wf-stat .wf-cap { height: 6px; width: 60%; background: var(--ink-4); border-radius: 2px; margin-bottom: 9px; }
.wf-stat .wf-val { height: 13px; width: 40%; background: var(--ink); border-radius: 3px; }
.wf-field { border: 1px solid var(--hair); border-radius: 6px; padding: 9px 11px; }
.wf-field .wf-cap { height: 6px; width: 30%; background: var(--ink-4); border-radius: 2px; margin-bottom: 8px; }
.wf-field .wf-in { height: 9px; width: 68%; background: rgba(234,234,234,0.16); border-radius: 2px; }
.wf-area .wf-in { height: 30px; width: 100%; }
.wf-toggle { display: flex; align-items: center; gap: 8px; }
.wf-toggle .wf-pill { width: 26px; height: 15px; border-radius: 8px; border: 1px solid var(--ink-3); position: relative; }
.wf-toggle .wf-pill::after { content: ""; position: absolute; top: 2px; left: 2px; width: 9px; height: 9px; border-radius: 50%; background: var(--ink); animation: pill-flip 3.4s steps(1) infinite; }
@keyframes pill-flip { 50% { left: 13px; } }
.wf-toggle .wf-cap { height: 6px; width: 22px; background: var(--ink-4); border-radius: 2px; }
.wf-badge { align-self: flex-start; font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--bg); background: var(--ink); border-radius: 3px; padding: 4px 8px; }
.wf-seg { display: flex; border: 1px solid var(--hair); border-radius: 6px; overflow: hidden; width: fit-content; }
.wf-seg span { padding: 6px 13px; }
.wf-seg span i { display: block; width: 40px; height: 6px; background: var(--ink-4); border-radius: 2px; }
.wf-seg span.on { background: rgba(234,234,234,0.12); }
.wf-seg span.on i { background: var(--ink); }
.wf-swatches { display: grid; grid-template-columns: repeat(5, 1fr); gap: 9px; }
.wf-swatch { border: 1px solid var(--hair-2); border-radius: 6px; overflow: hidden; }
.wf-swatch i { display: block; height: 40px; }
.wf-swatch .wf-cap { height: 5px; margin: 7px; background: var(--ink-4); border-radius: 2px; }
.wf-btn { align-self: flex-start; border: 1px solid var(--ink); border-radius: 6px; padding: 8px 16px; }
.wf-btn i { display: block; width: 88px; height: 7px; background: var(--ink); border-radius: 2px; }
.wf-skeleton { height: 38px; border-radius: 6px; background: linear-gradient(100deg, rgba(234,234,234,0.05) 40%, rgba(234,234,234,0.12) 50%, rgba(234,234,234,0.05) 60%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* fig 2 · ranking demo */
.demo { border: 1px solid var(--hair); }
.demo-controls { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--hair); }
.demo-slider { padding: 18px 22px; border-right: 1px solid var(--hair-2); }
.demo-slider:last-child { border-right: none; }
.demo-slider-top { display: flex; justify-content: space-between; align-items: baseline; color: var(--ink-2); margin-bottom: 13px; font-size: 15px; }
.demo-slider-top span[data-out] { font-family: var(--mono); color: var(--ink); font-variant-numeric: tabular-nums; }
.demo-slider-note { font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.06em; font-size: 10px; color: var(--ink-3); margin-top: 11px; }
.demo-range { -webkit-appearance: none; appearance: none; width: 100%; height: 2px; background: var(--hair); outline: none; cursor: pointer; }
.demo-range::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 13px; height: 13px; border-radius: 50%; background: var(--ink); border: none; transition: transform 0.2s var(--ease); }
.demo-range::-moz-range-thumb { width: 13px; height: 13px; border-radius: 50%; background: var(--ink); border: none; }
.demo-range:hover::-webkit-slider-thumb, .demo-range:active::-webkit-slider-thumb { transform: scale(1.25); }
.demo-table { padding: 10px; }
.demo-row { display: grid; grid-template-columns: 26px 1.1fr 0.8fr 0.9fr 0.8fr 1.5fr; align-items: center; gap: 16px; padding: 11px 14px; border-radius: 8px; }
.demo-head { font-family: var(--mono); color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; padding: 6px 14px 10px; font-size: 10px; }
.demo-rank { font-family: var(--mono); font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.demo-body-row { transition: background 0.4s var(--ease); }
.demo-body-row.is-top { background: rgba(234, 234, 234, 0.05); }
.demo-plan { color: var(--ink); font-weight: 500; font-size: 16px; }
.demo-num { font-variant-numeric: tabular-nums; color: var(--ink-2); text-align: left; }
.demo-score { display: flex; align-items: center; gap: 12px; }
.demo-bar { flex: 1; height: 4px; background: var(--hair-2); border-radius: 2px; overflow: hidden; }
.demo-bar i { display: block; height: 100%; background: var(--ink-3); border-radius: 2px; transition: width 0.5s var(--ease), background 0.4s var(--ease); }
.demo-body-row.is-top .demo-bar i { background: var(--ink); }
.demo-score-val { font-family: var(--mono); font-size: 13px; color: var(--ink); width: 34px; text-align: right; font-variant-numeric: tabular-nums; }
.demo-meta { font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.04em; font-size: 10px; padding: 6px 24px 16px; color: var(--ink-3); }

/* fig 3 · vocabulary */
.vocab { border: 1px solid var(--hair); }
.vocab-legend { display: flex; flex-wrap: wrap; gap: 4px 22px; padding: 14px 16px; border-bottom: 1px solid var(--hair); }
.vocab-legend button { background: none; border: none; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); cursor: pointer; padding: 3px 0; transition: color 0.3s var(--ease); }
.vocab-legend button:hover { color: var(--ink); }
.vocab-legend button.is-on { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.vocab-legend button em { font-style: normal; color: var(--ink-4); margin-left: 5px; }
.vocab-grid { display: flex; flex-wrap: wrap; gap: 7px; padding: 18px 16px; }
.chip { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.02em; border: 1px solid var(--hair); padding: 6px 12px; color: var(--ink-2); cursor: default; transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), opacity 0.35s var(--ease); }
.chip:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.vocab.is-filtered .chip { opacity: 0.16; }
.vocab.is-filtered .chip.is-kept { opacity: 1; }

/* findings */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--hair); margin-bottom: 52px; }
.stat { position: relative; padding: 28px 24px; border-right: 1px solid var(--hair-2); border-bottom: 1px solid var(--hair-2); }
.stat:nth-child(3n) { border-right: none; }
.stat:nth-child(n+4) { border-bottom: none; }
.stat-n { display: block; font-family: var(--sans); font-weight: 500; font-size: clamp(32px, 4vw, 48px); line-height: 1; margin-bottom: 10px; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.stat-l { font-family: var(--mono); color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.06em; font-size: 10.5px; }
.guarantees { list-style: none; max-width: 760px; }
.guarantees li { display: grid; grid-template-columns: 40px 1fr; gap: 18px; padding: 18px 0; border-top: 1px solid var(--hair-2); color: var(--ink-2); font-size: 16px; line-height: 1.5; }
.guarantees li:first-child { border-top: none; }
.g-no { font-family: var(--mono); color: var(--ink-3); font-size: 11px; letter-spacing: 0.04em; padding-top: 3px; }
.guarantees strong { color: var(--ink); font-weight: 500; }

/* guide */
.steps { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 46px; max-width: 900px; }
.steps li { display: grid; grid-template-columns: 38px 1fr; gap: 16px; padding: 16px 0; border-top: 1px solid var(--hair-2); color: var(--ink-2); font-size: 16px; line-height: 1.5; }
.step-no { font-family: var(--mono); color: var(--ink-3); font-size: 11px; letter-spacing: 0.04em; padding-top: 3px; }
.steps strong { color: var(--ink); font-weight: 500; }
.steps em { font-style: italic; color: var(--ink); }
.steps li.keys { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; grid-column: 1 / -1; border-top: 1px solid var(--hair-2); padding: 22px 0 0; }
.key { display: inline-flex; align-items: center; gap: 11px; border: 1px solid var(--hair); padding: 9px 15px; }
.key kbd { font-family: var(--mono); font-size: 13px; color: var(--ink); }
.key span { font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.08em; font-size: 10px; color: var(--ink-3); }

/* iron laws */
.laws { margin-top: 34px; }
.law { font-family: var(--serif); font-size: clamp(28px, 4.6vw, 54px); line-height: 1.12; padding: 26px 0; border-top: 1px solid var(--hair-2); color: var(--ink-3); transition: color 0.5s var(--ease), padding-left 0.5s var(--ease); }
.law:hover { color: var(--ink); padding-left: 16px; }
.law-no { font-family: var(--mono); color: var(--ink-4); margin-right: 22px; font-size: 14px; letter-spacing: 0.04em; vertical-align: 20%; }

/* references */
.refs { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 2px 46px; max-width: 1000px; }
.refs li { display: grid; grid-template-columns: 34px 1fr; gap: 14px; padding: 14px 10px; margin: 0 -10px; border-top: 1px solid var(--hair-2); color: var(--ink-2); font-size: 15px; line-height: 1.45; transition: background 0.3s var(--ease), color 0.3s var(--ease); }
.refs li:hover, .refs li.is-flash { background: rgba(234,234,234,0.05); color: var(--ink); }
.ref-no { font-family: var(--mono); color: var(--ink-3); font-size: 11px; padding-top: 3px; }
.refs em { font-style: italic; }

/* footer */
.footer { border-top: 1px solid var(--hair); padding: 72px var(--gutter) 44px; display: flex; flex-direction: column; gap: 50px; }
.footer-mark { width: 60px; height: 60px; color: var(--ink); opacity: 0.22; transition: opacity 0.6s var(--ease), transform 0.8s var(--ease); }
.footer-mark:hover { opacity: 1; transform: rotate(90deg); }
.footer-row { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--ink-3); }
.footer a { color: inherit; text-decoration: none; text-underline-offset: 3px; }
.footer a:hover { color: var(--ink); text-decoration: underline; }

/* toast */
.toast { position: fixed; bottom: 26px; left: 50%; transform: translate(-50%, 16px); background: var(--ink); color: var(--bg); font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; padding: 12px 20px; z-index: 95; opacity: 0; pointer-events: none; transition: opacity 0.35s var(--ease), transform 0.35s var(--ease); }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 980px) {
  .sec { grid-template-columns: 1fr; gap: 26px; padding: 76px var(--gutter); }
  .sec-rail { flex-direction: row; gap: 14px; }
  .sec-rail > span { position: static; }
  .two-col { grid-template-columns: 1fr; gap: 16px; }
  .engines { grid-template-columns: 1fr; }
  .fig-panes { grid-template-columns: 1fr; }
  .pane-spec { border-right: none; border-bottom: 1px solid var(--hair); }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3n) { border-right: 1px solid var(--hair-2); }
  .stat:nth-child(2n) { border-right: none; }
  .stat:nth-child(n+4) { border-bottom: 1px solid var(--hair-2); }
  .stat:nth-child(n+5) { border-bottom: none; }
  .steps { grid-template-columns: 1fr; }
  .refs { grid-template-columns: 1fr; }
  .nav-meta { display: none; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .nav-links { display: none; }
  .pipe-stages { grid-template-columns: 1fr; }
  .pipe-track { display: none; }
  .stage { padding: 14px 0; border-top: 1px solid var(--hair-2); }
  .demo-controls { grid-template-columns: 1fr; }
  .demo-slider { border-right: none; border-bottom: 1px solid var(--hair-2); }
  .demo-slider:last-child { border-bottom: none; }
  .demo-row { grid-template-columns: 22px 1fr 1.3fr; gap: 12px; }
  .demo-num, .demo-head .demo-num { display: none; }
  .stats { grid-template-columns: 1fr; }
  .stat { border-right: none !important; border-bottom: 1px solid var(--hair-2) !important; }
  .stat:last-child { border-bottom: none !important; }
}

/* reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rv { opacity: 1; transform: none; transition: none; }
  .wf { opacity: 1; transform: none; animation: none; }
  .wf-slider .wf-thumb, .wf-toggle .wf-pill::after, .wf-skeleton { animation: none; }
  .pipe-dot { transition: none; }
  .demo-bar i, .demo-body-row { transition: none; }
  .landing-mark, .brand-mark { transition: none; }
}
