/* SILS site stylesheet. Built on the SILS Design System (Revolution tokens + COSIMO Red as the Seal).
   Layout concept: a dark instrument panel. Wide quiet grounds, one Seal per view, mono for anything the product emits. */

:root {
  /* SILS Design System v2. Single dark world. */
  --bg: #1A1A1C;
  --bg-deep: #0D0D0D;
  --surface: #252525;
  --elevated: #3D3D3D;
  --navy: #11296B;
  --navy-2: #071230;
  --line: #2F2F2F;
  --line-strong: #3D3D3D;
  --fg: #FFFFFF;
  --fg-2: #C4C4C4;
  --fg-3: #9A9A9A;
  --seal: #9E3E3F;
  --seal-deep: #6E2A2B;
  --seal-text: #E07A7C;
  --seal-accent: #C25353;
  --on-seal: #FFFFFF;
  --gold: #FFDA9E;
  --value: #FFDA9E;
  --on-gold: #1D1D1D;
  --tech: #1E96FC;
  --ok: #3DD68C;
  --warn: #FFB020;
  --bad: #FF5A5A;
  --on-navy: #FFFFFF;
  --on-navy-2: #C9D3F2;
  --code-bg: #0D0D0D;
  --code-k: #E07A7C;
  --code-s: #FFDA9E;
  --code-c: #7B7B7B;
  --code-n: #7CC4FF;
  --redact: #FFFFFF;
  --glow: 0 0 0 1px rgba(158,62,63,.45), 0 0 24px rgba(158,62,63,.28);
  --elev-1: 0 1px 2px rgba(0,0,0,.4);
  --elev-2: 0 4px 12px rgba(0,0,0,.45);
  color-scheme: dark;

  --f-core: 'Montserrat', 'Helvetica Neue', Arial, sans-serif;
  --f-display: 'Funnel Display', 'Helvetica Neue', Arial, sans-serif;
  --f-mono: 'Martian Mono', 'JetBrains Mono', ui-monospace, monospace;
  --f-code: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s6: 24px; --s8: 32px; --s12: 48px; --s16: 64px; --s24: 96px; --s32: 128px;
  --r1: 4px; --r2: 8px; --r3: 12px; --r4: 16px; --rf: 999px;
  --wrap: 1360px;
  --t1: 120ms; --t2: 200ms; --t3: 320ms; --t4: 600ms;
  --ease: cubic-bezier(.2,0,0,1);
  --ease-settle: cubic-bezier(.16,1,.3,1);
}


*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font-family: var(--f-core); font-size: 16px; line-height: 1.6; font-weight: 400;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
a { color: var(--tech); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--tech); outline-offset: 2px; border-radius: 2px; }
::selection { background: var(--seal); color: var(--on-seal); }
code, kbd, .mono { font-family: var(--f-mono); }
p { margin: 0; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; text-wrap: balance; }
ul, ol { margin: 0; padding: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--seal); color: var(--on-seal); padding: 8px 12px; border-radius: var(--r1); }
.skip:focus { left: 16px; }

/* ---------- Type scale ---------- */
.display { font-size: clamp(39px, 6.2vw, 76px); line-height: 1.02; letter-spacing: -0.03em; }
.h1 { font-size: clamp(31px, 5vw, 61px); line-height: 1.08; letter-spacing: -0.025em; }
.h2 { font-size: clamp(25px, 3.8vw, 49px); line-height: 1.1; letter-spacing: -0.02em; }
.h3 { font-size: clamp(20px, 2.8vw, 31px); line-height: 1.15; letter-spacing: -0.015em; }
.h4 { font-size: clamp(18px, 1.8vw, 22px); line-height: 1.25; letter-spacing: -0.01em; }
.lead { font-size: clamp(17px, 1.6vw, 20px); line-height: 1.55; color: var(--fg-2); max-width: 60ch; }
.body { color: var(--fg-2); max-width: 65ch; }
.small { font-size: 14px; line-height: 1.45; }
.muted { color: var(--fg-3); }
.eyebrow { font-size: 12.8px; line-height: 1.4; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-3); }
.eyebrow.seal { color: var(--seal-text); }
.caption { font-family: var(--f-mono); font-size: 12.8px; line-height: 1.45; color: var(--fg-3); }
.value { color: var(--value); font-variant-numeric: tabular-nums; }
.tnum { font-variant-numeric: tabular-nums; }
.name { font-family: var(--f-mono); font-size: .92em; color: var(--fg); background: var(--elevated); padding: 1px 8px; border-radius: var(--rf); white-space: nowrap; }
.stack > * + * { margin-top: var(--s4); }
.stack-l > * + * { margin-top: var(--s6); }

/* ---------- Layout ---------- */
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--s6); }
@media (max-width: 720px) { .wrap { padding-inline: var(--s4); } }
.sec { padding-block: var(--s24); }
.sec.tight { padding-block: var(--s16); }
@media (max-width: 720px) { .sec { padding-block: var(--s16); } .sec.tight { padding-block: var(--s12); } }
.sec-deep { background: var(--bg-deep); }
.sec-navy { background: var(--navy); color: var(--on-navy); --fg: #FFFFFF; --fg-2: var(--on-navy-2); --fg-3: #AEBBE6; --line: rgba(255,255,255,.16); --surface: rgba(255,255,255,.06); --elevated: rgba(255,255,255,.12); --tech: #7CC4FF; --seal-text: #F0A3A4; --value: #FFDA9E; --ok: #57E3A0; --warn: #FFC24D; }
.sec-head { display: grid; gap: var(--s4); margin-bottom: var(--s12); max-width: 820px; }
.grid { display: grid; gap: var(--s6); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s12); align-items: center; }
.split.wide-l { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); }
@media (max-width: 1000px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 860px) { .split, .split.wide-l { grid-template-columns: minmax(0, 1fr); gap: var(--s8); } }
@media (max-width: 720px) { .g2, .g3, .g4 { grid-template-columns: minmax(0, 1fr); } }
.grid > *, .split > * { min-width: 0; }
hr.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }


/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: var(--r2); font: 600 15px/1.2 var(--f-core); border: 1px solid transparent; cursor: pointer; transition: background var(--t2) var(--ease), border-color var(--t2) var(--ease), color var(--t2) var(--ease); white-space: nowrap; }
.btn:hover { text-decoration: none; }
.btn-seal { background: var(--seal); color: var(--on-seal); }
.btn-seal:hover { background: var(--seal-deep); }
.btn-ghost { border-color: var(--line-strong); color: var(--fg); background: transparent; }
.btn-ghost:hover { background: var(--surface); }
.btn-sm { min-height: 36px; padding: 6px 14px; font-size: 14px; }
.link-arrow { font-weight: 600; display: inline-flex; gap: 6px; align-items: center; }
.link-arrow::after { content: "\2192"; transition: transform var(--t2) var(--ease); }
.link-arrow:hover::after { transform: translateX(3px); }
.cta-row { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }

/* ---------- Status badges ---------- */
.status { display: inline-flex; align-items: center; gap: 6px; font: 600 12px/1 var(--f-core); letter-spacing: .04em; padding: 5px 10px 5px 8px; border-radius: var(--rf); border: 1px solid var(--line); color: var(--fg-2); background: var(--surface); white-space: nowrap; vertical-align: middle; }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status[data-s="live"] { color: var(--ok); }
.status[data-s="test"] { color: var(--warn); }
.status[data-s="dev"] { color: var(--warn); }
.status[data-s="spec"] { color: var(--tech); }
.status[data-s="plan"] { color: var(--fg-3); }
.status[data-s="plan"]::before { background: transparent; border: 1.5px solid currentColor; }
.status span { color: var(--fg); font-weight: 600; }
.legend { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s3); align-items: center; }

/* ---------- Cards and panels ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r2); padding: var(--s6); display: flex; flex-direction: column; gap: var(--s3); }
.card h3 { font-size: 20px; line-height: 1.25; letter-spacing: -0.01em; }
.card .body { font-size: 15px; }
.card .card-foot { margin-top: auto; padding-top: var(--s3); display: flex; justify-content: space-between; align-items: center; gap: var(--s3); flex-wrap: wrap; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); overflow: hidden; }
.plain-list { list-style: none; display: grid; gap: 10px; }
.plain-list li { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 10px; color: var(--fg-2); }
.plain-list li::before { content: ""; width: 6px; height: 6px; border-radius: 1px; background: var(--line-strong); margin-top: 10px; }
.check-list li::before { width: 10px; height: 6px; border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); background: none; transform: rotate(-45deg); margin-top: 8px; border-radius: 0; }

/* ---------- Hero ---------- */
.hero { padding-block: var(--s24) var(--s16); position: relative; }
.hero::before { content: ""; position: absolute; inset: 0; pointer-events: none; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 48px 48px; opacity: .35; -webkit-mask-image: radial-gradient(ellipse 70% 60% at 70% 30%, #000 0%, transparent 75%); mask-image: radial-gradient(ellipse 70% 60% at 70% 30%, #000 0%, transparent 75%); }
.hero > .wrap { position: relative; }
.hero .display { margin-top: var(--s4); }
.hero .lead { margin-top: var(--s6); }
.hero .cta-row { margin-top: var(--s8); }
.hero-note { margin-top: var(--s6); display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }
.page-hero { padding-block: var(--s16) var(--s12); border-bottom: 1px solid var(--line); }
.page-hero .h1 { margin-top: var(--s3); max-width: 18ch; }
.page-hero .lead { margin-top: var(--s4); }

/* ---------- The redaction receipt (signature device) ---------- */
.receipt { font-family: var(--f-mono); font-size: 13px; line-height: 1.6; background: var(--code-bg); color: #E6E6E6; border: 1px solid #2F2F2F; border-radius: var(--r3); overflow: hidden; box-shadow: var(--elev-2); }
.receipt-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid #2F2F2F; color: #9A9A9A; font-size: 12px; }
.receipt-head b { color: #FFFFFF; font-weight: 500; }
.receipt-body { padding: 16px; display: grid; gap: 6px; overflow-x: auto; }
.rrow { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 12px; align-items: baseline; white-space: nowrap; }
.rrow .k { color: #8A8A8A; }
.rrow .v { color: #E6E6E6; overflow: hidden; text-overflow: ellipsis; }
.rrow .v.amt { color: #FFDA9E; }
.rrow .v.nm { color: #FFFFFF; }
.redact { position: relative; display: inline-block; color: #E6E6E6; }
.redact::after { content: ""; position: absolute; left: -3px; right: -3px; top: 50%; height: 1.15em; transform: translateY(-50%) scaleX(1); transform-origin: left center; background: #EDEDED; border-radius: 2px; }
.receipt .tag { font-size: 11px; color: #9A9A9A; margin-left: 8px; }
.proof-line { margin-top: 10px; padding: 10px 12px; border-radius: var(--r2); border: 1px solid rgba(61,214,140,.35); background: rgba(61,214,140,.08); color: #3DD68C; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; white-space: normal; }
.proof-line svg { width: 16px; height: 16px; flex: none; }
.proof-line.glow { box-shadow: var(--glow); }
.receipt.anim .redact::after { animation: redact var(--t4) var(--ease) both; }
.receipt.anim .redact.d1::after { animation-delay: 500ms; }
.receipt.anim .redact.d2::after { animation-delay: 650ms; }
.receipt.anim .redact.d3::after { animation-delay: 800ms; }
.receipt.anim .proof-line { animation: proofin var(--t4) var(--ease) 1200ms both; }
@keyframes redact { from { transform: translateY(-50%) scaleX(0); } to { transform: translateY(-50%) scaleX(1); } }
@keyframes proofin { from { opacity: .25; box-shadow: none; } 60% { box-shadow: var(--glow); } to { opacity: 1; box-shadow: var(--glow); } }

.duo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s4); }
@media (max-width: 720px) { .duo { grid-template-columns: minmax(0, 1fr); } }
.duo-label { display: flex; justify-content: space-between; align-items: center; margin-bottom: var(--s2); gap: 8px; }

/* ---------- Code ---------- */
.code { background: var(--code-bg); border: 1px solid #2F2F2F; border-radius: var(--r3); overflow: hidden; color: #E6E6E6; }
.code-bar { display: flex; align-items: center; gap: 2px; padding: 6px 6px 0 6px; border-bottom: 1px solid #2F2F2F; overflow-x: auto; }
.code-tab { font: 500 12.5px/1 var(--f-mono); color: #9A9A9A; background: transparent; border: 0; padding: 10px 12px; cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; }
.code-tab[aria-selected="true"] { color: #FFFFFF; border-bottom-color: #E07A7C; }
.code-tab:hover { color: #FFFFFF; }
.code-title { font: 500 12.5px/1 var(--f-mono); color: #9A9A9A; padding: 10px 10px 12px; }
.copy-btn { margin-left: auto; font: 600 12px/1 var(--f-core); color: #C4C4C4; background: #252525; border: 1px solid #3D3D3D; border-radius: var(--r1); padding: 6px 10px; cursor: pointer; margin-bottom: 6px; flex: none; }
.copy-btn:hover { color: #FFFFFF; }
.code pre { margin: 0; padding: 16px 18px; overflow-x: auto; font: 400 13px/1.65 var(--f-mono); tab-size: 2; }
.code .k { color: #E07A7C; } .code .s { color: #FFDA9E; } .code .c { color: #8A8A8A; } .code .n { color: #7CC4FF; } .code .p { color: #3DD68C; }
.code-note { padding: 10px 18px; border-top: 1px solid #2F2F2F; font: 400 12px/1.5 var(--f-core); color: #9A9A9A; }

/* ---------- Tables ---------- */
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r2); background: var(--surface); }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.45; min-width: 640px; }
.tbl th, .tbl td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl thead th { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--fg-3); background: var(--bg-deep); position: sticky; top: 0; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl td { color: var(--fg-2); font-variant-numeric: tabular-nums; }
.tbl td:first-child, .tbl th[scope="row"] { color: var(--fg); font-weight: 600; }
.tbl .hl td { background: color-mix(in srgb, var(--seal) 9%, transparent); }
.tbl code { font-size: 12.5px; color: var(--fg); }
.yes { color: var(--ok); font-weight: 600; } .part { color: var(--warn); font-weight: 600; } .nd { color: var(--fg-3); }

/* ---------- Diagrams ---------- */
.diagram { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: var(--s6); overflow-x: auto; }
.diagram svg { display: block; min-width: 680px; width: 100%; height: auto; }
.diagram .d-box { fill: var(--bg); stroke: var(--line-strong); stroke-width: 1; }
.diagram .d-box-seal { fill: var(--bg); stroke: var(--seal-text); stroke-width: 1.5; }
.diagram .d-box-navy { fill: var(--navy); stroke: var(--navy); }
.diagram .d-line { stroke: var(--line-strong); stroke-width: 1; fill: none; }
.diagram .d-arrow { stroke: var(--tech); stroke-width: 1.5; fill: none; }
.diagram .d-head { fill: var(--tech); }
.diagram .d-t { fill: var(--fg); font: 600 13px var(--f-core); }
.diagram .d-t2 { fill: var(--fg-2); font: 400 12px var(--f-core); }
.diagram .d-m { fill: var(--fg-2); font: 400 11.5px var(--f-mono); }
.diagram .d-lbl { fill: var(--fg-3); font: 600 10.5px var(--f-core); letter-spacing: .12em; text-transform: uppercase; }
.diagram .d-seal { fill: var(--seal-text); }
.diagram .d-ok { fill: var(--ok); }
.diagram .d-navy-t { fill: #FFFFFF; font: 600 13px var(--f-core); }
.diagram-cap { margin-top: var(--s3); }

/* ---------- Name tree ---------- */
.tree { font-family: var(--f-mono); font-size: 14px; line-height: 1; display: grid; gap: 0; }
.tree .node { display: flex; align-items: center; gap: 10px; padding: 9px 0; }
.tree .root { font-size: 16px; color: var(--fg); }
.tree .kid { padding-left: 26px; position: relative; color: var(--fg); }
.tree .kid::before { content: ""; position: absolute; left: 8px; top: 0; bottom: 50%; width: 12px; border-left: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); }
.tree .kid + .kid::before { top: -50%; }
.tree .meta { font-family: var(--f-core); font-size: 12px; color: var(--fg-3); margin-left: auto; text-align: right; }
.tree svg { width: 18px; height: 18px; flex: none; }

/* ---------- Steps (real sequences only) ---------- */
.steps { display: grid; gap: var(--s6); counter-reset: st; }
.step { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: var(--s4); }
.step-n { counter-increment: st; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); display: grid; place-items: center; font: 600 14px var(--f-mono); color: var(--fg); }
.step-n::before { content: counter(st); }
.step h3 { font-size: 18px; line-height: 1.3; }
.step p { color: var(--fg-2); margin-top: 6px; font-size: 15px; }

/* ---------- Stat / spec strip ---------- */
.specs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--r2); overflow: hidden; }
.spec { padding: var(--s6); border-right: 1px solid var(--line); display: grid; gap: 6px; align-content: start; }
.spec:last-child { border-right: 0; }
.spec .k { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-3); }
.spec .v { font-size: 20px; font-weight: 700; letter-spacing: -.01em; }
.spec .n { font-size: 13px; color: var(--fg-3); }
@media (max-width: 860px) { .specs { grid-template-columns: repeat(2, minmax(0, 1fr)); } .spec:nth-child(2n) { border-right: 0; } .spec { border-bottom: 1px solid var(--line); } }
@media (max-width: 480px) { .specs { grid-template-columns: minmax(0, 1fr); } .spec { border-right: 0; } }

/* ---------- Chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: var(--s2); }
.chip { font: 500 13px/1 var(--f-mono); padding: 9px 12px; border-radius: var(--rf); border: 1px solid var(--line); color: var(--fg-2); background: var(--surface); }

/* ---------- Callout ---------- */
.note { border: 1px solid var(--line); background: var(--surface); border-radius: var(--r2); padding: var(--s4) var(--s6); font-size: 14px; color: var(--fg-2); display: grid; gap: 4px; }
.note b { color: var(--fg); }

/* ---------- Page TOC (deep pages) ---------- */
.with-toc { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: var(--s12); align-items: start; }
.toc { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 88px); display: grid; gap: 2px; font-size: 13.5px; }
.toc .eyebrow { margin-bottom: var(--s2); }
.toc a { color: var(--fg-3); padding: 6px 0 6px 12px; border-left: 1px solid var(--line); }
.toc a:hover { color: var(--fg); text-decoration: none; }
.toc a.on { color: var(--fg); border-left-color: var(--seal-text); }
@media (max-width: 1000px) { .with-toc { grid-template-columns: minmax(0, 1fr); } .toc { display: none; } }
.doc-sec { padding-block: var(--s12); border-bottom: 1px solid var(--line); scroll-margin-top: 80px; }
.doc-sec:last-child { border-bottom: 0; }
.doc-sec > .h3 { margin-bottom: var(--s4); }
.doc-sec > * + * { margin-top: var(--s4); }

/* ---------- Sources ---------- */
.sources { font-size: 13px; line-height: 1.5; color: var(--fg-3); }
.sources ol { padding-left: 22px; display: grid; gap: 6px; }
.sources a { color: var(--fg-2); word-break: break-word; }
sup.ref { font-size: 11px; font-weight: 600; margin-left: 1px; }
sup.ref a { color: var(--tech); }


/* ---------- Motion safety ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-delay: 0ms !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
}
.status[data-s="verified"] { color: var(--ok); }
.status[data-s="revoked"] { color: var(--bad); }
.status[data-s="revoked"]::before { background: transparent; border: 1.5px solid currentColor; }
.card .card-foot { flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 8px; }
.specs.specs-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.specs.specs-2 .spec:nth-child(2n) { border-right: 0; }
.specs.specs-2 .spec:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
@media (max-width: 480px) { .specs.specs-2 { grid-template-columns: minmax(0, 1fr); } .specs.specs-2 .spec { border-right: 0; border-bottom: 1px solid var(--line); } }
.sec-navy .specs, .sec-navy .spec { border-color: var(--line); }
.sec-navy .btn-ghost { color: #fff; border-color: rgba(255,255,255,.5); }
.sec-navy .btn-ghost:hover { background: rgba(255,255,255,.08); }
.proof-line { flex-wrap: nowrap; align-items: flex-start; }
.proof-line svg { margin-top: 3px; }
@media (max-width: 480px) { .rrow { grid-template-columns: 92px minmax(0, 1fr); gap: 8px; } .receipt .tag { display: none; } }

/* ==================================================================
   v2 layer: Proof field direction applied to every page
   ================================================================== */
body { font-family: var(--f-core); background: var(--bg); }
.wrap { max-width: 1520px; padding-inline: clamp(16px, 4vw, 56px); }
@media (max-width: 720px) { .wrap { padding-inline: 16px; } }

/* Type */
.display, .h1, .h2, .h3, .h4, .card h3, .step h3 { font-family: var(--f-display); }
.display { font-weight: 300; font-size: clamp(44px, 9vw, 150px); line-height: .92; letter-spacing: -0.045em; }
.h1 { font-weight: 300; font-size: clamp(42px, 6.6vw, 108px); line-height: .94; letter-spacing: -0.042em; }
.h2 { font-weight: 300; font-size: clamp(34px, 4.8vw, 76px); line-height: .98; letter-spacing: -0.038em; }
.h3 { font-weight: 400; font-size: clamp(24px, 2.6vw, 38px); line-height: 1.05; letter-spacing: -0.025em; }
.h4 { font-weight: 500; font-size: clamp(19px, 1.7vw, 23px); line-height: 1.2; letter-spacing: -0.015em; }
.lead { color: var(--fg-2); font-size: clamp(17px, 1.45vw, 21px); line-height: 1.55; }
.eyebrow { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-weight: 400; font-size: 11px; letter-spacing: .1em; color: var(--fg-3); }
.eyebrow.seal { color: var(--seal-text); }
.caption { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-size: 11.5px; letter-spacing: .02em; }
.name { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; background: transparent; border: 1px solid var(--line-strong); }
code, kbd, .mono { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; }

/* Sections */
.sec { padding-block: clamp(80px, 11vw, 160px); }
.sec.tight { padding-block: clamp(56px, 7vw, 96px); }
.sec-deep { background: var(--bg-deep); }
.sec-head { gap: var(--s6); margin-bottom: clamp(40px, 6vw, 88px); max-width: 980px; }
.sec-head .eyebrow { padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.sec-navy { --fg-3: #AEBBE6; --line: rgba(255,255,255,.16); --surface: rgba(255,255,255,.05); }

/* Page hero: PhotoGround, illustration or typographic */
.page-hero { position: relative; isolation: isolate; overflow: hidden; min-height: min(86vh, 900px); display: flex; align-items: flex-end; padding-block: calc(env(safe-area-inset-top, 0px) + 150px) clamp(56px, 8vw, 110px); border-bottom: 1px solid var(--line); background: var(--bg-deep); }
.page-hero > .wrap { width: 100%; position: relative; }
.page-hero .h1 { max-width: 15ch; margin-top: var(--s4); }
.page-hero .lead { margin-top: var(--s8); max-width: 54ch; }
.page-hero .hero-note { margin-top: var(--s8); }
.page-hero .ph-img { position: absolute; inset: -6% 0; width: 100%; height: 112%; object-fit: cover; z-index: -3; }
.page-hero.photo::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(90deg, rgba(13,13,13,.95) 0%, rgba(13,13,13,.7) 40%, rgba(13,13,13,.2) 80%); }
.page-hero .ph-fade { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: 55%; z-index: -1; pointer-events: none; }
.page-hero.art > .wrap { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr); gap: clamp(32px, 5vw, 80px); align-items: end; }
.hero-art { width: 100%; max-width: 420px; justify-self: end; }
.hero-art img { width: 100%; height: auto; display: block; }
.hero-art.well { background: #fff; border-radius: var(--r2); overflow: hidden; }
.hero-art figcaption { margin-top: 10px; }
.page-hero.type { background: radial-gradient(ellipse 70% 80% at 85% 20%, rgba(158,62,63,.16), transparent 60%), var(--bg-deep); }
.page-hero.type::after { content: ""; position: absolute; right: -8vw; top: 50%; transform: translateY(-50%); width: min(46vw, 560px); aspect-ratio: 1; z-index: -1; opacity: .07; background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M80.81 35.63A34 34 0 0 1 27.69 75.66' fill='none' stroke='%23fff' stroke-width='11'/%3E%3Cpath d='M24.34 72.31A34 34 0 0 1 64.37 19.19' fill='none' stroke='%23fff' stroke-width='11'/%3E%3Ccircle cx='74.04' cy='25.96' r='8.5' fill='%23fff'/%3E%3C/svg%3E"); }
@media (max-width: 900px) {
  .page-hero { min-height: 0; padding-top: calc(env(safe-area-inset-top, 0px) + 130px); }
  .page-hero.photo::before { background: linear-gradient(0deg, rgba(13,13,13,.95) 20%, rgba(13,13,13,.6) 70%, rgba(13,13,13,.4) 100%); }
  .page-hero.art > .wrap { grid-template-columns: minmax(0, 1fr); }
  .hero-art { justify-self: start; max-width: 300px; }
}

/* Status: instrument style */
.status { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-weight: 400; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; padding: 0; border: 0; background: transparent; gap: 8px; }
.status::before { width: 6px; height: 6px; }
.status span { color: inherit; }

/* Buttons */
.btn { border-radius: var(--r1); font-weight: 500; font-size: 14px; }
.btn-seal:hover { background: var(--seal-deep); }
.btn-ghost { border-color: var(--line-strong); }
.btn-ghost:hover { background: transparent; border-color: var(--tech); color: var(--tech); }
.page-hero .btn { border-radius: var(--rf); }

/* Cards and panels */
.card { border-radius: var(--r3); padding: var(--s8); gap: var(--s4); transition: border-color var(--t2) var(--ease), transform var(--t2) var(--ease); }
.card:hover { border-color: #4A4A4A; }
.card h3 { font-weight: 500; font-size: 22px; line-height: 1.15; letter-spacing: -0.02em; }
.panel { border-radius: var(--r3); }
.note { border-radius: var(--r2); border-left: 2px solid var(--tech); }
.plain-list li::before { background: var(--seal-text); width: 6px; height: 1px; margin-top: 12px; }

/* Tables: ruled, not boxed */
.tbl-wrap { border: 0; border-top: 1px solid #4F4F4F; border-radius: 0; background: transparent; }
.tbl thead th { background: transparent; font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-weight: 400; font-size: 11px; letter-spacing: .1em; color: var(--fg-3); padding: 14px 16px 14px 0; border-bottom: 1px solid var(--line); }
.tbl td { padding: 16px 16px 16px 0; }
.tbl td:first-child { font-weight: 500; }
.tbl .hl td { background: linear-gradient(90deg, rgba(158,62,63,.14), rgba(158,62,63,.04)); }
.tbl .hl td:first-child { box-shadow: inset 2px 0 0 var(--seal-text); padding-left: 12px; }

/* Code */
.code { border-radius: var(--r2); border-color: #2A2A2D; background: var(--code-bg); }
.code pre { font-family: var(--f-code); font-size: 13.5px; }
.code-tab, .code-title { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-size: 11px; letter-spacing: .04em; }
.code-tab[aria-selected="true"] { border-bottom-color: var(--seal-text); }
.code-note { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; }
.copy-btn { border-radius: var(--r1); }
.receipt { font-family: var(--f-code); border-radius: var(--r3); }

/* Diagrams */
.diagram { border-radius: var(--r3); background: var(--bg-deep); border-color: var(--line); }
.diagram .d-box, .diagram .d-box-seal { fill: var(--bg); }
.diagram .d-box-navy { fill: var(--navy); }
.diagram .d-t, .diagram .d-navy-t { font-family: var(--f-core); font-weight: 600; }
.diagram .d-m { font-family: var(--f-code); }
.diagram .d-lbl { font-family: var(--f-mono); font-weight: 400; letter-spacing: .1em; }

/* Specs, chips, steps */
.specs { border-radius: var(--r3); }
.spec .k { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-weight: 400; font-size: 11px; }
.spec .v { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-weight: 400; font-size: 22px; letter-spacing: -0.03em; }
.chip { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-size: 11.5px; }
.step-n { font-family: var(--f-mono); border-color: var(--line-strong); }
.step h3 { font-weight: 500; font-size: 20px; }

/* TOC */
.toc { top: calc(env(safe-area-inset-top, 0px) + 96px); }
.toc a { font-family: var(--f-mono); font-variation-settings: "wdth" 87.5; font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }
.toc a.on { border-left-color: var(--seal-text); }
.doc-sec { scroll-margin-top: 96px; padding-block: clamp(48px, 6vw, 80px); }
.doc-sec > .h3 { font-weight: 400; }

/* Sources */
.sources { font-size: 12.5px; }
.sources a { color: var(--fg-2); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }

/* Forms (Company early access) */
input, select, textarea { font-family: var(--f-core); border-radius: var(--r1) !important; }

/* Animated page heroes (assets/heroes.js) */
.page-hero.anim { background: radial-gradient(ellipse 60% 70% at 72% 50%, #16161A 0%, var(--bg-deep) 70%); min-height: min(92vh, 940px); }
.page-hero.anim .hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; opacity: 0; transition: opacity 1.2s var(--ease); }
.page-hero.anim .hero-canvas.on { opacity: 1; }
.page-hero.anim::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(90deg, rgba(13,13,13,.92) 0%, rgba(13,13,13,.72) 30%, rgba(13,13,13,0) 52%); }
.page-hero.anim > .wrap { max-width: 1520px; }
.page-hero.anim .wrap > * { max-width: min(660px, 46vw); }
@media (max-width: 900px) {
  .page-hero.anim { min-height: 0; padding-top: calc(env(safe-area-inset-top, 0px) + min(118vw, 560px)); }
  .page-hero.anim::before { background: linear-gradient(0deg, rgba(13,13,13,.97) 0%, rgba(13,13,13,.9) 46%, rgba(13,13,13,0) 72%); }
  .page-hero.anim .wrap > * { max-width: none; }
}
.page-hero.anim .h1 { max-width: min(660px, 46vw) !important; }
@media (max-width: 900px) { .page-hero.anim .h1 { max-width: 16ch !important; } }
.page-hero.anim .h1 { font-size: clamp(40px, 5.4vw, 92px); }

/* Privacy by zero-knowledge proof is always violet (zk-sealed). */
:root { --zk: #9B8CFF; --zk-tint: rgba(155,140,255,.12); }
.zk, .tbl td.zk { color: var(--zk); }
.diagram .d-box-zk { fill: rgba(155,140,255,.08); stroke: var(--zk); stroke-width: 1.5; }
.diagram .d-zk { fill: var(--zk); }
.zk-sec > .eyebrow, .zk-sec .prod-head .eyebrow { color: var(--zk); }
.zk-sec .panel { border-color: rgba(155,140,255,.45); background: linear-gradient(180deg, var(--zk-tint), transparent 70%); }
.zk-list li::before { background: var(--zk) !important; }
.zk-list li { color: var(--zk); }
#identity .tbl code, #identity .tbl td.mono, #facets .tbl code, .facet { color: var(--zk) !important; }
.zk-chip { display: inline-flex; align-items: center; gap: 6px; font: 400 10.5px/1 var(--f-mono); font-variation-settings: "wdth" 87.5; letter-spacing: .08em; text-transform: uppercase; color: var(--zk); border: 1px solid rgba(155,140,255,.5); background: var(--zk-tint); border-radius: 999px; padding: 5px 10px; }

/* Sealed field: a value held by a zero-knowledge proof. Always violet. Replaces the old white redaction bar. */
.zseal { display: inline-grid; align-items: center; vertical-align: middle; max-width: 100%; }
.zseal > * { grid-area: 1 / 1; }
.zs-raw { color: #E6E6E6; visibility: hidden; white-space: nowrap; }
.zs-chip { display: inline-flex; align-items: center; gap: 8px; padding: 3px 10px; border: 1px solid var(--zk); border-radius: 4px; color: var(--zk); overflow: hidden; min-width: 0;
  background: repeating-linear-gradient(115deg, rgba(155,140,255,.18) 0 8px, rgba(155,140,255,.05) 8px 16px); background-size: 200% 100%; animation: zsflow 7s linear infinite; }
.zs-chip .zk-mark { width: 13px; height: 13px; flex: none; }
.zs-chip b { font: 500 10.5px/1.3 var(--f-mono); font-variation-settings: "wdth" 87.5; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.zs-chip i { font: 400 10.5px/1.3 var(--f-mono); font-style: normal; color: rgba(205,198,255,.7); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
@keyframes zsflow { to { background-position: -200% 0; } }
@media (max-width: 1180px) { .zs-chip i { display: none; } }
/* Sealing sequence: the raw value shows, scrambles (sils.js), then the chip wipes over it. */
.receipt.anim .zs-raw { animation: zsraw 2.6s linear both; }
.receipt.anim .zs-chip { animation: zsin .55s cubic-bezier(.85,0,.15,1) both, zsflow 7s linear infinite; }
.receipt.anim .zseal.d1 .zs-raw { animation-duration: 1.35s; }
.receipt.anim .zseal.d1 .zs-chip { animation-delay: .95s, 0s; }
.receipt.anim .zseal.d2 .zs-raw { animation-duration: 1.8s; }
.receipt.anim .zseal.d2 .zs-chip { animation-delay: 1.4s, 0s; }
.receipt.anim .zseal.d3 .zs-raw { animation-duration: 2.25s; }
.receipt.anim .zseal.d3 .zs-chip { animation-delay: 1.85s, 0s; }
@keyframes zsraw { 0%, 99% { visibility: visible; } 100% { visibility: hidden; } }
@keyframes zsin { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
.proof-line.zk { border-color: rgba(155,140,255,.5); background: rgba(155,140,255,.08); color: #CFC8FF; }
.proof-line.zk b { color: var(--zk); font-weight: 500; }
.proof-line.zk .zk-mark { width: 16px; height: 16px; flex: none; color: var(--zk); }
.receipt.anim .proof-line.zk { animation: zkproofin .9s cubic-bezier(.16,1,.3,1) 2.3s both; }
@keyframes zkproofin { from { opacity: .2; box-shadow: none; } 60% { box-shadow: 0 0 0 1px rgba(155,140,255,.6), 0 0 28px rgba(155,140,255,.35); } to { opacity: 1; box-shadow: 0 0 22px rgba(155,140,255,.18); } }
@media (prefers-reduced-motion: reduce) { .zs-chip, .receipt.anim .zs-chip, .receipt.anim .zs-raw, .receipt.anim .proof-line.zk { animation: none; } }

/* Protection fade, drawn in CSS */
.ph-fade { display: block; background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.29) 18%, rgba(0,0,0,.58) 37%, rgba(0,0,0,.86) 55%, #000 73%); }
