/* Alethix: near-black paper, white for actions, one iris accent for what has been verified, and the verdict colours the CLI prints. */
:root {
  color-scheme: dark;
  --bg: #0a0b0d;
  --bg-2: #0f1114;
  --bg-3: #15181c;
  --bg-4: #1c2025;
  --line: rgb(236 237 233 / 0.08);
  --line-2: rgb(236 237 233 / 0.15);
  --ink: #ecede9;
  --ink-2: #b6b9b4;
  --mute: #868b87;
  --dim: #50555a;

  --white: #f2f3f0;
  --accent: #8c9bff;
  --accent-wash: rgb(140 155 255 / 0.13);
  --exp: #ff6257;
  --exp-wash: rgb(255 98 87 / 0.1);
  --rch: #f2a65a;
  --rch-wash: rgb(242 166 90 / 0.09);
  --hrd: #a3a8a4;
  --hrd-wash: rgb(163 168 164 / 0.08);
  --ok: #8c9bff;
  --ok-wash: rgb(140 155 255 / 0.1);
  --high: #ffa05a;

  --sans: "Schibsted Grotesk", ui-sans-serif, system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --wrap: 1200px;
  --gut: clamp(16px, 4vw, 40px);
  --r: 12px;
  --r-sm: 6px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --nav-h: 64px;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 24px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
::selection { background: rgb(140 155 255 / 0.35); color: var(--ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
a { color: inherit; text-decoration-color: var(--line-2); text-underline-offset: 0.2em; }
a:hover { text-decoration-color: var(--accent); }
p { margin: 0; text-wrap: pretty; }
h1, h2, h3 { margin: 0; font-weight: 600; text-wrap: balance; overflow-wrap: break-word; }
h2 { font-size: clamp(2rem, 1.2rem + 2.8vw, 3.25rem); line-height: 1.04; letter-spacing: -0.032em; max-width: 22ch; }
h3 { font-size: 1.1875rem; line-height: 1.25; letter-spacing: -0.01em; }
code, pre, kbd { font-family: var(--mono); }
code, pre, kbd, .term, .stage, .flood, .sources { font-variant-ligatures: none; font-feature-settings: "calt" 0, "liga" 0; }
code { font-size: 0.86em; }
mark { background: var(--accent-wash); color: var(--accent); border-radius: 3px; padding: 0 0.15em; }
.mute { color: var(--mute); }
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }
.lead { font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem); line-height: 1.5; color: var(--ink-2); max-width: 52ch; }
.caption { font-size: 0.875rem; color: var(--mute); }
.caption code { color: var(--ink-2); }

.skip { position: absolute; left: 16px; top: -64px; z-index: 50; padding: 8px 14px; background: var(--white); color: var(--bg); border-radius: var(--r-sm); font-weight: 600; }
.skip:focus-visible { top: 12px; }

/* Background: a probe field that follows the pointer, and a trace that connects the page as you scroll. */
.field { position: fixed; inset: 0; z-index: -1; width: 100%; height: 100%; pointer-events: none; }
.trace { position: absolute; top: 0; left: 0; width: 100%; z-index: 0; pointer-events: none; overflow: hidden; }
.trace svg { display: block; width: 100%; height: 100%; overflow: visible; }
.trace .track { fill: none; stroke: rgb(236 237 233 / 0.07); stroke-width: 1.5; }
.trace .lit { fill: none; stroke: var(--accent); stroke-width: 1.5; stroke-linecap: round; stroke-dasharray: 1 1; }
.trace .lit.c-exp { stroke: var(--exp); } .trace .lit.c-rch { stroke: var(--rch); } .trace .lit.c-hrd { stroke: var(--hrd); } .trace .lit.c-ok { stroke: var(--ok); }
.trace .node { fill: var(--bg); stroke: rgb(236 237 233 / 0.22); stroke-width: 1.5; transition: fill 300ms var(--ease), stroke 300ms var(--ease); }
.trace .node.is-on { fill: var(--accent); stroke: var(--accent); }
.trace .head { fill: var(--accent); }
.trace .halo { fill: rgb(140 155 255 / 0.16); }
main, .foot { position: relative; z-index: 1; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 22px; border-radius: 10px; border: 1px solid transparent;
  font: 600 1rem/1 var(--sans); letter-spacing: -0.005em; white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: background-color 180ms var(--ease), border-color 180ms var(--ease), transform 120ms var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn--sm { min-height: 38px; padding: 0 16px; font-size: 0.9375rem; border-radius: 8px; }
.btn--primary { background: var(--white); color: var(--bg); }
.btn--primary:hover { background: #ffffff; }
.btn--ghost { border-color: var(--line-2); color: var(--ink); background: rgb(236 237 233 / 0.02); }
.btn--ghost:hover { border-color: rgb(236 237 233 / 0.32); background: rgb(236 237 233 / 0.05); }
.btn--ink { background: var(--bg); color: var(--white); }
.btn--ink:hover { background: var(--bg-4); }
.btn--ink:focus-visible { outline-color: var(--bg); }
.linkbtn { background: none; border: 0; padding: 4px 2px; color: var(--ink-2); font: 500 0.8125rem/1 var(--mono); cursor: pointer; text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 0.25em; }
.linkbtn:hover { color: var(--ink); text-decoration-color: var(--accent); }

/* Nav */
.nav { position: sticky; top: 0; z-index: 40; height: var(--nav-h); border-bottom: 1px solid transparent; transition: background-color 200ms var(--ease), border-color 200ms var(--ease); }
.nav.is-stuck { background: rgb(10 11 13 / 0.82); border-bottom-color: var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.nav__in { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 600 1.125rem/1 var(--sans); letter-spacing: -0.025em; text-decoration: none; }
/* A hollow diamond: an aperture, for the thing being revealed. */
.brand__mark { width: 11px; height: 11px; margin: 0 2px; border: 2.5px solid var(--accent); border-radius: 2px; transform: rotate(45deg); }
.nav__links { display: flex; gap: 28px; font-size: 0.9375rem; color: var(--ink-2); }
.nav__links a { text-decoration: none; transition: color 160ms var(--ease); }
.nav__links a:hover, .nav__links a[aria-current] { color: var(--ink); }
@media (max-width: 860px) { .nav__links { display: none; } }

/* Hero */
.hero { position: relative; padding: clamp(48px, 9vh, 104px) 0 clamp(72px, 10vw, 120px); margin-top: calc(-1 * var(--nav-h)); padding-top: calc(var(--nav-h) + clamp(40px, 8vh, 96px)); isolation: isolate; }
.hero__grid {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px; background-position: center top;
  mask-image: radial-gradient(70% 55% at 50% 30%, black 10%, transparent 75%);
  -webkit-mask-image: radial-gradient(70% 55% at 50% 30%, black 10%, transparent 75%);
  opacity: 0.6;
}
.hero__grid::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(40% 30% at 50% 62%, rgb(140 155 255 / 0.1), transparent 70%);
}
.hero__in { display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero__for { font: 500 0.8125rem/1 var(--mono); color: var(--ink-2); padding: 8px 12px; border: 1px solid var(--line-2); border-radius: 999px; background: var(--bg-2); }
.hero h1 { margin-top: 28px; font-size: clamp(2.75rem, 1rem + 6.2vw, 5.5rem); line-height: 0.98; letter-spacing: -0.045em; max-width: 14ch; }
.hero__sub { margin-top: 24px; max-width: 46ch; font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.25rem); line-height: 1.5; color: var(--ink-2); }
.hero__cta { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.hero__caption { margin-top: 16px; max-width: 70ch; }
.trust { margin-top: clamp(48px, 7vw, 80px); display: grid; justify-items: center; gap: 18px; }
.trust__label { font-size: 0.875rem; color: var(--mute); }
.trust__list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 16px clamp(40px, 7vw, 88px); }
.trust__list li { font-size: clamp(1.375rem, 1rem + 1.2vw, 1.75rem); font-weight: 600; letter-spacing: -0.03em; color: var(--ink-2); opacity: 0.85; }

/* Terminals */
.term { position: relative; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg-2); text-align: left; box-shadow: 0 30px 80px -30px rgb(0 0 0 / 0.8), 0 0 0 1px rgb(0 0 0 / 0.4); }
.term__bar, .stage__bar, .flood__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 42px; padding: 0 16px; border-bottom: 1px solid var(--line); font: 500 0.8125rem/1 var(--mono); }
.term__title { color: var(--ink-2); }
.term__state { color: var(--mute); }
.term__state.is-live { color: var(--accent); }
.term--hero { margin-top: clamp(48px, 7vw, 72px); width: 100%; max-width: 1040px; }
.term--hero .term__body { padding-bottom: 56px; }
.term__body, .pane { padding: 18px 22px 22px; font: 400 0.8125rem/1.7 var(--mono); color: var(--ink); overflow-x: auto; }
.ln { white-space: pre; min-height: 1.7em; }
.ln.gap { margin-top: 1.1em; }
.ln .p, .log .p { color: var(--accent); }
.js .term__body .ln, .js .pane .ln { transition: opacity 160ms var(--ease); }
.term__body .ln.is-hidden, .pane .ln.is-hidden { opacity: 0; }
/* Until the script takes over, a terminal shows only its prompt, so the output never flashes before it types. */
.js [data-pending] .ln:not(:first-child), .js [data-pending] [data-type] { opacity: 0; }
.caret { display: inline-block; width: 0.6em; height: 1.15em; margin-left: 2px; vertical-align: -0.2em; background: var(--accent); }
.term__replay { position: absolute; right: 14px; bottom: 14px; padding: 6px 10px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--bg-3); color: var(--ink-2); font: 500 0.75rem/1 var(--mono); cursor: pointer; }
.term__replay:hover { color: var(--ink); border-color: rgb(236 237 233 / 0.3); }
b { font-weight: 600; }
.v-exp { color: var(--exp); }
.v-rch { color: var(--rch); }
.v-hrd { color: var(--hrd); }
.v-ok { color: var(--ok); }
.k { color: var(--accent); }
.s { color: var(--ink-2); }
.n { color: var(--rch); }

/* Sections */
.section { padding: clamp(80px, 11vw, 144px) 0; border-top: 1px solid var(--line); }
.head { display: grid; gap: 18px; margin-bottom: clamp(40px, 5vw, 64px); }
.head--split { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: end; gap: 32px; }
@media (max-width: 860px) { .head--split { grid-template-columns: minmax(0, 1fr); gap: 18px; } }

/* Problem */
.problem__in { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.problem__text { display: grid; gap: 20px; }
.problem__text > p { color: var(--ink-2); max-width: 46ch; }
.problem__text h2 { margin-bottom: 8px; }
.quote { margin: 16px 0 0; padding-left: 20px; border-left: 2px solid var(--accent); }
.quote blockquote { margin: 0; font-size: 1.5rem; line-height: 1.25; letter-spacing: -0.02em; font-weight: 500; }
.quote figcaption { margin-top: 8px; font-size: 0.875rem; color: var(--mute); }
.flood { margin: 0; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg-2); overflow: hidden; }
.flood__state { color: var(--exp); }
.flood__window { position: relative; height: 420px; overflow: hidden; mask-image: linear-gradient(transparent, black 14%, black 80%, transparent); -webkit-mask-image: linear-gradient(transparent, black 14%, black 80%, transparent); }
.flood__list { list-style: none; margin: 0; padding: 0 16px; }
.flood__list li { display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; align-items: center; gap: 14px; height: 52px; border-bottom: 1px solid var(--line); font-size: 0.9375rem; }
.flood__t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.flood__list code { color: var(--accent); background: var(--accent-wash); padding: 3px 7px; border-radius: 4px; white-space: nowrap; font-size: 0.75rem; }
.sev { justify-self: start; padding: 3px 8px; border-radius: 4px; border: 1px solid currentColor; font: 500 0.6875rem/1.2 var(--mono); }
.sev--crit { color: var(--exp); }
.sev--high { color: var(--high); }
.sev--med { color: var(--hrd); }
.sev--low { color: var(--mute); }
.flood__cap { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--line); font-size: 0.875rem; color: var(--mute); }
html:not(.js) .flood__cap .linkbtn { display: none; }
.js .flood.is-running .flood__list { animation: flood 26s linear infinite; }
@keyframes flood { to { transform: translateY(-50%); } }
@media (max-width: 860px) {
  .problem__in { grid-template-columns: minmax(0, 1fr); }
  .flood__window { height: 340px; }
  .flood__list li { grid-template-columns: 68px minmax(0, 1fr); height: 68px; row-gap: 4px; align-content: center; }
  .flood__list .sev { grid-row: span 2; align-self: center; }
  .flood__list code { grid-column: 2; justify-self: start; }
}

/* How it works */
.how__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(32px, 4vw, 64px); align-items: start; }
.how__steps { list-style: none; margin: 0; padding: 0; }
.step__btn { all: unset; box-sizing: border-box; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 4px; width: 100%; padding: 22px 0 22px 18px; border-left: 2px solid var(--line); cursor: pointer; transition: border-color 220ms var(--ease); }
.step__btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.step__n { font: 500 0.8125rem/1.9 var(--mono); color: var(--dim); transition: color 220ms var(--ease); }
.step__body { display: grid; gap: 6px; }
.step__t { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.015em; color: var(--mute); transition: color 220ms var(--ease); }
.step__d { color: var(--mute); max-width: 40ch; transition: color 220ms var(--ease); }
.step.is-active .step__btn { border-left-color: var(--accent); }
.step.is-active .step__n { color: var(--accent); }
.step.is-active .step__t { color: var(--ink); }
.step.is-active .step__d { color: var(--ink-2); }
.step__btn:hover .step__t { color: var(--ink); }

.stage { position: sticky; top: calc(var(--nav-h) + 24px); border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg-2); box-shadow: 0 30px 80px -30px rgb(0 0 0 / 0.8); overflow: hidden; }
.stage__meter { display: flex; gap: 6px; }
.stage__meter i { width: 22px; height: 3px; border-radius: 2px; background: var(--line-2); transition: background-color 220ms var(--ease); }
.stage__meter i.is-on { background: var(--accent); }
.scene { padding: 24px; font: 400 0.8125rem/1.65 var(--mono); }
.js .how__grid .scene { display: none; }
.js .how__grid .scene.is-active { display: block; animation: scene-in 360ms var(--ease); }
@keyframes scene-in { from { opacity: 0; transform: translateY(8px); } }
html:not(.js) .scene + .scene { border-top: 1px solid var(--line); }
.scene__note { margin-top: 16px; color: var(--mute); font-family: var(--sans); font-size: 0.875rem; }

.code, .http, .diff { margin: 0; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); white-space: pre; overflow-x: auto; font: inherit; }
.scene--ingest { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.js .how__grid .scene--ingest.is-active { display: grid; }
.ingest__h { font-family: var(--sans); font-size: 0.875rem; color: var(--mute); margin-bottom: 10px; }
.ingest__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.ingest__list li { display: flex; gap: 10px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg-3); white-space: nowrap; overflow: hidden; }
.ingest__list span { color: var(--accent); }
.ingest__list em { margin-left: auto; font-style: normal; color: var(--mute); }
.scene.is-active .ingest__list li { animation: row-in 420ms var(--ease) both; animation-delay: calc(120ms + var(--i) * 70ms); }
@keyframes row-in { from { opacity: 0; transform: translateX(-12px); } }

.log { display: grid; gap: 2px; margin-bottom: 18px; }
.box { border: 1px dashed var(--line-2); border-radius: 10px; padding: 16px; }
.box__label { color: var(--mute); margin-bottom: 12px; }
.tenants { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 14px; align-items: stretch; }
.tenant { display: grid; gap: 10px; align-content: start; padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg-3); }
.tenant__name { color: var(--ink-2); }
.who { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.who code, .rec code { color: var(--mute); }
.rec { color: var(--ink-2); }
.avatar { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--bg-4); border: 1px solid var(--line-2); font-size: 0.75rem; color: var(--ink); }
.wall { position: relative; width: 2px; background: repeating-linear-gradient(var(--exp) 0 6px, transparent 6px 12px); opacity: 0.7; }
.wall span { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) rotate(-90deg); white-space: nowrap; font-size: 0.6875rem; color: var(--exp); background: var(--bg-3); padding: 2px 6px; }
.canary { color: var(--accent); background: var(--accent-wash); border-radius: 4px; padding: 1px 5px; overflow-wrap: anywhere; }
.scene--sandbox.is-active .canary { animation: canary 1.4s var(--ease) 400ms both; }
@keyframes canary { 0%, 100% { box-shadow: 0 0 0 0 rgb(140 155 255 / 0); } 30% { box-shadow: 0 0 0 6px rgb(140 155 255 / 0.25); } }

.wire { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "alice lane app"; align-items: center; gap: 12px; margin-bottom: 16px; }
.node--alice { grid-area: alice; }
.node--app { grid-area: app; }
.lane { grid-area: lane; }
.node { display: grid; justify-items: center; gap: 4px; min-width: 92px; padding: 12px 10px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--bg-3); text-align: center; }
.node small { font-size: 0.6875rem; color: var(--mute); }
.node--app { border-style: dashed; }
.node--patched { border-color: var(--ok); }
.lane { position: relative; height: 88px; border-top: 1px dashed var(--line-2); border-bottom: 1px dashed var(--line-2); overflow: hidden; }
.boundary { position: absolute; top: 0; bottom: 0; left: 66%; width: 0; border-left: 2px dashed var(--exp); opacity: 0.55; }
.boundary span { position: absolute; top: 3px; left: 6px; font-size: 0.625rem; line-height: 1; color: var(--exp); white-space: nowrap; }
.boundary--held { border-left-color: var(--ok); }
.boundary--held span { color: var(--ok); }
.pkt { position: absolute; left: 0; padding: 4px 8px; border-radius: 5px; font-size: 0.75rem; white-space: nowrap; }
.pkt--req { top: 18px; background: var(--bg-4); border: 1px solid var(--line-2); color: var(--ink); }
.pkt--res { bottom: 8px; background: var(--exp-wash); border: 1px solid var(--exp); color: var(--exp); }
.pkt--res .canary { padding: 0 4px; }
.pkt--deny { bottom: 8px; background: var(--ok-wash); border: 1px solid var(--ok); color: var(--ok); }
.http { margin-bottom: 14px; }
.verdict { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 14px; align-items: baseline; padding: 10px 14px; border-radius: 8px; border: 1px solid; margin-top: 10px; }
.verdict b { letter-spacing: 0.02em; }
.verdict span { color: var(--ink-2); font-family: var(--sans); font-size: 0.9375rem; }
.verdict--exp { border-color: rgb(255 98 87 / 0.5); background: var(--exp-wash); color: var(--exp); }
.verdict--ok { border-color: rgb(140 155 255 / 0.45); background: var(--ok-wash); color: var(--ok); }
.diff { margin-bottom: 16px; }
.del { color: var(--exp); background: var(--exp-wash); display: inline-block; min-width: 100%; }
.add { color: var(--ok); background: var(--ok-wash); display: inline-block; min-width: 100%; }

/* Replay choreography: the request crosses the tenant boundary, and bob's canary comes back over it. */
.scene--replay.is-active .pkt--req { animation: go 1000ms var(--ease) 200ms both; }
.scene--replay.is-active .boundary { animation: breach 900ms var(--ease) 1500ms both; }
.scene--replay.is-active .pkt--res { animation: back 1000ms var(--ease) 1300ms both; }
.scene--replay.is-active .http { animation: fade 400ms var(--ease) 600ms both; }
.scene--replay.is-active .node--alice { animation: hit 700ms var(--ease) 2200ms both; }
.scene--replay.is-active .verdict--exp { animation: pop 420ms var(--ease) 2300ms both; }
.scene--replay.is-active .verdict--ok { animation: pop 420ms var(--ease) 2650ms both; }
/* Fix choreography: the same request now stops at the check, and a 403 comes back. */
.scene--fix.is-active .diff .del { animation: strike 500ms var(--ease) 100ms both; }
.scene--fix.is-active .diff .add { animation: fade 300ms var(--ease) both; animation-delay: calc(400ms + var(--i) * 150ms); }
.scene--fix.is-active .pkt--req { animation: go-stop 800ms var(--ease) 1000ms both; }
.scene--fix.is-active .boundary { animation: hold 700ms var(--ease) 1750ms both; }
.scene--fix.is-active .pkt--deny { animation: back-stop 800ms var(--ease) 1900ms both; }
.scene--fix.is-active .verdict--ok { animation: pop 420ms var(--ease) 2700ms both; }
@keyframes go { from { transform: translateX(-100%); opacity: 0; } 15% { opacity: 1; } to { transform: translateX(calc(var(--lane, 320px) - 100%)); } }
@keyframes back { from { transform: translateX(calc(var(--lane, 320px) - 100%)); opacity: 0; } 15% { opacity: 1; } to { transform: translateX(0); } }
@keyframes go-stop { from { transform: translateX(-100%); opacity: 0; } 15% { opacity: 1; } to { transform: translateX(calc(var(--lane, 320px) * 0.66 - 100% - 6px)); } }
@keyframes back-stop { from { transform: translateX(calc(var(--lane, 320px) * 0.66 - 100% - 6px)); opacity: 0; } 15% { opacity: 1; } to { transform: translateX(0); } }
@keyframes breach { 0%, 100% { opacity: 0.55; } 30% { opacity: 1; box-shadow: -6px 0 18px -6px var(--exp); } }
@keyframes hold { from { opacity: 0.55; } 40% { opacity: 1; box-shadow: -6px 0 18px -6px var(--ok); } to { opacity: 1; } }
@keyframes strike { from { background-color: transparent; color: var(--ink-2); } }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(6px) scale(0.98); } }
@keyframes hit { 0%, 100% { box-shadow: 0 0 0 0 rgb(255 98 87 / 0); } 35% { box-shadow: 0 0 0 6px rgb(255 98 87 / 0.3); border-color: var(--exp); } }

.stage__desc { display: none; }
@media (min-width: 981px) {
  .how__steps .step { min-height: 44vh; }
  .how__steps .step:last-child { min-height: 30vh; }
}
@media (max-width: 980px) {
  .how__grid { grid-template-columns: minmax(0, 1fr); }
  .js .stage__desc { display: block; padding: 14px 24px 0; color: var(--ink-2); font-size: 0.9375rem; }
  .stage { position: relative; top: auto; }
  .how__steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
  .step__btn { grid-template-columns: minmax(0, 1fr); padding: 12px; border: 1px solid var(--line); border-radius: 8px; }
  .step.is-active .step__btn { border-color: var(--accent); }
  .js .step__d { display: none; }
  .js .step__t { font-size: 0.875rem; }
  html:not(.js) .how__steps { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .scene { padding: 16px; font-size: 0.75rem; }
  .scene--ingest { grid-template-columns: minmax(0, 1fr); }
  .tenants { grid-template-columns: minmax(0, 1fr); }
  .wall { width: auto; height: 2px; background: repeating-linear-gradient(90deg, var(--exp) 0 6px, transparent 6px 12px); margin: 8px 0; }
  .wall span { transform: translate(-50%, -50%); }
  .wire { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "alice app" "lane lane"; }
  .node { min-width: 0; padding: 10px 6px; }
  .verdict { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .code, .http, .diff { white-space: pre-wrap; overflow-wrap: anywhere; }
  .how__steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Verdicts */
.buckets { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.bucket { --c: var(--hrd); --w: var(--hrd-wash); display: flex; flex-direction: column; gap: 14px; padding: 20px; border: 1px solid var(--line); border-top: 2px solid var(--c); border-radius: var(--r); background: linear-gradient(var(--w), transparent 140px), var(--bg-2); }
.bucket--exp { --c: var(--exp); --w: var(--exp-wash); }
.bucket--rch { --c: var(--rch); --w: var(--rch-wash); }
.bucket--ok { --c: var(--ok); --w: var(--ok-wash); }
.bucket header { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.bucket h3 { color: var(--c); }
.bucket__n { font: 600 2rem/1 var(--sans); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.bucket__def { color: var(--ink-2); font-size: 0.9375rem; }
.chips { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.chip { display: grid; gap: 2px; padding: 9px 11px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--bg-3); font-size: 0.875rem; line-height: 1.35; }
.chip em { font: 400 0.75rem/1.3 var(--mono); font-style: normal; color: var(--mute); }
.bucket__ev { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); font: 400 0.75rem/1.55 var(--mono); color: var(--ink-2); }
.bucket__sarif { font-size: 0.8125rem; color: var(--mute); }
.bucket__sarif code { color: var(--c); }
.js .buckets .chip { transition: transform 700ms var(--ease), opacity 400ms var(--ease); }
@media (max-width: 1040px) { .buckets { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .buckets { grid-template-columns: minmax(0, 1fr); } }

/* CLI */
.cli__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(32px, 4vw, 56px); align-items: start; }
.tabs { display: flex; gap: 4px; padding: 8px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { flex: none; padding: 8px 12px; border: 1px solid transparent; border-radius: 7px; background: none; color: var(--mute); font: 500 0.8125rem/1 var(--mono); cursor: pointer; transition: color 160ms var(--ease), background-color 160ms var(--ease); }
.tab:hover { color: var(--ink); }
.tab[aria-selected="true"] { color: var(--ink); background: var(--bg-4); border-color: var(--line-2); }
.pane { min-height: 360px; }
.facts { margin: 0; display: grid; gap: 0; }
.facts div { padding: 20px 0; border-top: 1px solid var(--line); }
.facts div:first-child { border-top: 0; padding-top: 4px; }
.facts dt { font-weight: 600; font-size: 1.0625rem; letter-spacing: -0.01em; }
.facts dd { margin: 6px 0 0; color: var(--ink-2); font-size: 0.9375rem; }
.facts code { color: var(--accent); }
@media (max-width: 980px) { .cli__grid { grid-template-columns: minmax(0, 1fr); } .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 32px; } .facts div:nth-child(2) { border-top: 0; padding-top: 4px; } }
@media (max-width: 560px) { .facts { grid-template-columns: minmax(0, 1fr); } .facts div:nth-child(2) { border-top: 1px solid var(--line); padding-top: 20px; } }

/* Why: any tool in, one verdict out */
.why__in { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.why__text { display: grid; gap: 22px; }
.why__text > p:not(.lead) { color: var(--mute); max-width: 52ch; }
.sources { margin: 0; display: grid; grid-template-columns: minmax(0, 1.25fr) 56px auto 56px minmax(0, 1fr); align-items: center; padding: 24px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg-2); }
.sources__in, .sources__out { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-rows: 52px; row-gap: 12px; }
.sources__in li { display: flex; flex-direction: column; justify-content: center; gap: 1px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg-3); font-size: 0.875rem; line-height: 1.25; }
.sources__in code { font-size: 0.6875rem; color: var(--mute); }
.sources__out li { display: flex; align-items: center; padding: 0 12px; border: 1px solid currentColor; border-radius: 8px; font: 500 0.75rem/1.2 var(--mono); background: var(--bg-3); }
.sources__hub { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border: 1px solid var(--accent); border-radius: 10px; background: var(--bg); font: 600 0.9375rem/1 var(--mono); box-shadow: 0 0 0 6px var(--accent-wash); }
.wires { width: 100%; height: 248px; overflow: visible; }
.wires path { fill: none; stroke: var(--line-2); stroke-width: 1.5; vector-effect: non-scaling-stroke; stroke-dasharray: 3 5; }
.wires--out .w-exp { stroke: var(--exp); } .wires--out .w-rch { stroke: var(--rch); } .wires--out .w-hrd { stroke: var(--hrd); } .wires--out .w-ok { stroke: var(--ok); }
.js .sources.is-running .wires path { animation: flow 1.2s linear infinite; }
@keyframes flow { to { stroke-dashoffset: -16; } }
@media (max-width: 900px) { .why__in { grid-template-columns: minmax(0, 1fr); } .why__text { order: -1; } }
@media (max-width: 560px) {
  .sources { grid-template-columns: minmax(0, 1.3fr) 24px auto 24px minmax(0, 1fr); padding: 14px; }
  .sources__in li { padding: 0 8px; font-size: 0.75rem; }
  .sources__out li { padding: 0 6px; font-size: 0.625rem; }
  .sources__hub { padding: 8px; font-size: 0.75rem; gap: 6px; box-shadow: 0 0 0 4px var(--accent-wash); }
  .sources__hub .brand__mark { display: none; }
}

/* Close */
.close { background: var(--white); color: var(--bg); padding: clamp(72px, 9vw, 120px) 0; }
.close ::selection { background: var(--bg); color: var(--white); }
.close :focus-visible { outline-color: var(--bg); }
.close__in { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 32px; align-items: end; }
.close h2 { font-size: clamp(2.25rem, 1rem + 4vw, 4rem); max-width: 16ch; letter-spacing: -0.04em; }
.close__cta { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.close__mail { font: 500 0.9375rem/1 var(--mono); text-decoration-color: rgb(10 11 13 / 0.35); }
.close__mail:hover { text-decoration-color: var(--bg); }
@media (max-width: 760px) { .close__in { grid-template-columns: minmax(0, 1fr); } }

/* Footer */
.foot { padding: 32px 0 40px; }
.foot__in { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; color: var(--mute); font-size: 0.875rem; }

@media (max-width: 640px) {
  body { font-size: 16px; }
  .ln { white-space: pre-wrap; overflow-wrap: anywhere; }
  .term__body, .pane { padding: 14px 16px 18px; font-size: 0.6875rem; }
  .hero__cta { width: 100%; }
  .hero__cta .btn { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-pending] .ln, .js [data-pending] [data-type] { opacity: 1; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .js .flood.is-running .flood__list { animation: none; }
}

/* Code shows the characters typed: no ligatures (`!=` stays `!=`). Last, so no `font` shorthand above resets it. */
pre, code, .ln, .scene, .scene *, .flood *, .sources * { font-variant-ligatures: none; font-feature-settings: "calt" 0, "liga" 0; }
