/* ActaTrail landing page.
   Brand: the lockup's navy ground, white "acta" in Roboto Light, amber "trail" in Roboto Black,
   light blue for the version and the byline, one short amber rule.
   Every headline splits light and black the way the wordmark does, and every section heading is
   followed by the lockup's rule. Hashes are set in the reader's system monospace. */

@font-face { font-family: "Roboto"; src: url("fonts/roboto-300.woff") format("woff"); font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: "Roboto"; src: url("fonts/roboto-400.woff") format("woff"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Roboto"; src: url("fonts/roboto-700.woff") format("woff"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Roboto"; src: url("fonts/roboto-900.ttf") format("truetype"); font-weight: 900; font-style: normal; font-display: swap; }

:root {
  /* the four colours of the lockup */
  --navy: #10274a;
  --amber: #f1a31c;
  --sky: #8dafd5;
  --white: #ffffff;

  /* drawn from them */
  --navy-deep: #0a1a33;
  --navy-line: #2a426b;
  --amber-mark: #c27a06;
  --paper: #f3f6fa;
  --paper-deep: #e1e8f2;
  --sheet: #ffffff;
  --ink-soft: #485a79;
  --rule: #b9c5d8;
  --breach: #c4361f;
  --breach-paper: #fbe7e2;
  --breach-night: #ff8f78;
  --flash: #fde8bf;

  --sans: "Roboto", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

  --spine: 172px;
  --seal: 116px;
  --pad: clamp(20px, 4vw, 44px);
  --gap: clamp(28px, 5vw, 72px);
}

/* Two grounds. Light is the default, and every sheet (a card, a table, a slip) is light whatever it lies on. */
body, .acts, .gates, .register, .certificate, .ledger, .slip, .phone-frame, .screen, .erasure-card, .tenant {
  --ground: var(--paper);
  --text: var(--navy);
  --soft: var(--ink-soft);
  --line: var(--navy);
  --hair: var(--rule);
  --mark-a: var(--navy);
  --mark-b: var(--amber-mark);
  --bad: var(--breach);
  --bad-ground: var(--breach-paper);
  --panel: var(--sheet);
  --cta: var(--navy);
  --cta-text: var(--white);
  --focus: var(--navy);
  color: var(--text);
}
body { --shadow: var(--paper-deep); }
.block-ink, .masthead, .foot {
  --ground: var(--navy);
  --text: var(--white);
  --soft: #b6c8e2;
  --line: var(--sky);
  --hair: var(--navy-line);
  --mark-a: var(--sky);
  --mark-b: var(--amber);
  --bad: var(--breach-night);
  --bad-ground: rgba(255, 143, 120, 0.16);
  --panel: rgba(255, 255, 255, 0.07);
  --cta: var(--amber);
  --cta-text: var(--navy);
  --focus: var(--amber);
  --shadow: rgba(4, 12, 28, 0.5);
  background: var(--ground);
  color: var(--text);
}
.block-deep, .foot { --ground: var(--navy-deep); }
.acts, .gates, .register, .certificate, .ledger, .slip, .phone-frame, .screen, .erasure-card, .tenant { --ground: var(--sheet); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 24px; background: var(--navy-deep); }
body {
  margin: 0;
  background: var(--paper);
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
h1, h2, h3, p, ol, ul, dl, dd, figure, table { margin: 0; padding: 0; }
ol, ul { list-style: none; }
[hidden] { display: none !important; }
button { font: inherit; color: inherit; }
a { color: inherit; text-underline-offset: 0.18em; }
code { font-family: var(--mono); font-size: 0.82em; letter-spacing: 0; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--amber); color: var(--navy); }

.skip { position: absolute; left: -999px; top: 8px; background: var(--amber); color: var(--navy); padding: 10px 16px; z-index: 20; font-weight: 700; }
.skip:focus { left: 8px; }

/* ---------- the wordmark and the lockup ---------- */
.wordmark { font-weight: 300; letter-spacing: -0.012em; line-height: 1; white-space: nowrap; color: var(--white); text-decoration: none; }
.wordmark b { font-weight: 900; color: var(--amber); }
.wordmark sup { font-size: 0.17em; font-weight: 400; letter-spacing: 0; vertical-align: top; position: relative; top: 0.25em; margin-left: 0.12em; }
.lockup { display: grid; justify-items: start; }
.lockup .wordmark { font-size: clamp(3.25rem, 7.4vw, 6rem); }
.lockup-version { font-size: 0.55em; color: var(--sky); margin-left: 0.5em; letter-spacing: 0; }
.lockup::after { content: ""; display: block; order: 2; width: clamp(56px, 7.2vw, 94px); height: clamp(3px, 0.4vw, 5px); background: var(--amber); margin: clamp(20px, 2.8vw, 36px) 0 clamp(16px, 2.4vw, 30px); }
.lockup-by { order: 3; font-size: clamp(1rem, 2.2vw, 1.75rem); line-height: 1.2; letter-spacing: 0.16em; text-transform: uppercase; color: var(--sky); }

/* ---------- header ---------- */
.top {
  display: flex; align-items: center; gap: 28px;
  max-width: 1280px; margin: 0 auto; padding: 20px var(--pad);
  position: relative; z-index: 3;
}
.brand { font-size: 2.125rem; }
.top-nav { display: flex; gap: 28px; margin-left: auto; font-size: 1.0625rem; }
.top-nav a { color: var(--text); text-decoration: none; padding: 6px 0; border-bottom: 2px solid transparent; }
.top-nav a:hover { border-bottom-color: var(--amber); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 12px 26px;
  border: 2px solid var(--cta); border-radius: 3px;
  font-weight: 700; font-size: 1.0625rem; line-height: 1.2; text-decoration: none; cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}
.btn-solid { background: var(--cta); color: var(--cta-text); }
.btn-solid:hover { background: var(--text); border-color: var(--text); color: var(--ground); }
.btn-line { background: transparent; color: var(--text); border-color: var(--line); }
.btn-line:hover { background: var(--text); border-color: var(--text); color: var(--ground); }
.btn-quiet { background: transparent; color: var(--soft); border-color: transparent; text-decoration: underline; text-underline-offset: 0.2em; padding-left: 10px; padding-right: 10px; }
.btn-quiet:hover { color: var(--text); }
.btn-paper { background: var(--white); color: var(--breach); border-color: var(--white); }
.btn-paper:hover { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-small { min-height: 42px; padding: 8px 16px; font-size: 1rem; }
.btn-large { min-height: 64px; padding: 16px 40px; font-size: 1.3125rem; }
.btn[aria-pressed="true"] { background: var(--amber); border-color: var(--amber); color: var(--navy); }
.actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------- the chain: every section is a block ---------- */
.block { position: relative; }
.inner {
  display: grid; grid-template-columns: var(--spine) minmax(0, 1fr);
  max-width: 1280px; margin: 0 auto; padding: 0 var(--pad);
}
.body { padding: clamp(64px, 9vw, 128px) 0; min-width: 0; }

.spine { position: relative; padding-top: clamp(64px, 9vw, 128px); }
.spine::after {
  content: ""; position: absolute; left: calc(var(--seal) / 2 - 1px); top: 0; bottom: 0; width: 2px;
  background: var(--line);
}
.block-hero .spine::after { top: calc(clamp(40px, 6vw, 72px) + var(--seal) / 2); }
.block-last .spine::after { bottom: auto; height: calc(clamp(64px, 9vw, 128px) + var(--seal) / 2); }
.seal {
  position: relative; z-index: 1; display: block;
  width: var(--seal); height: var(--seal); border-radius: 50%;
  background: var(--ground);
}
.seal path { fill: none; stroke-width: 0.6; }
.ring-a { stroke: var(--mark-a); }
.ring-b { stroke: var(--mark-b); }
.seal .seal-core { fill: var(--ground); stroke: var(--line); stroke-width: 1; }
.seal .seal-no { font-family: var(--sans); font-weight: 900; font-size: 26px; fill: var(--text); text-anchor: middle; dominant-baseline: central; }

.meta { position: relative; z-index: 1; margin-top: 12px; padding: 4px 0; width: var(--seal); background: var(--ground); font-size: 0.875rem; line-height: 1.45; color: var(--soft); text-align: center; }
.meta b { display: block; color: var(--text); font-weight: 700; font-size: 1rem; }
.meta code { display: block; font-size: 0.8125rem; color: var(--text); }
.meta .state { display: inline-block; margin-top: 4px; padding: 1px 8px; border: 1.5px solid var(--line); border-radius: 2px; color: var(--line); font-weight: 700; font-size: 0.8125rem; }

/* a block whose content no longer matches its hash, and every block after it */
.is-broken .spine::after { background: repeating-linear-gradient(to bottom, var(--bad) 0 7px, transparent 7px 14px); }
.is-broken .seal .ring-a, .is-broken .seal .ring-b, .is-broken .seal .seal-core { stroke: var(--bad); }
.is-broken .seal .seal-no { fill: var(--bad); }
.is-broken .meta .state { border-color: var(--bad); color: var(--ground); background: var(--bad); }
.is-broken .meta code.was { text-decoration: line-through; color: var(--bad); }
.is-checking .seal { animation: pulse 0.5s ease-out; }
@keyframes pulse { 0% { transform: scale(1); } 45% { transform: scale(1.09); } 100% { transform: scale(1); } }

[contenteditable] { outline: 2px dashed var(--mark-b); outline-offset: 6px; border-radius: 2px; cursor: text; }
[contenteditable]:focus { outline-style: solid; }

/* ---------- type ---------- */
h1, h2 { font-weight: 300; text-wrap: balance; }
h1 b, h2 b { font-weight: 900; }
.block-ink h1 b, .block-ink h2 b { color: var(--amber); }
h1 { font-size: clamp(2.9rem, 5.7vw, 4.6rem); line-height: 1.02; letter-spacing: -0.028em; }
h1 b, h2.split b { display: block; }
h2 { font-size: clamp(2rem, 3.9vw, 3.1rem); line-height: 1.08; letter-spacing: -0.022em; max-width: 17ch; }
/* the lockup's rule, under every section heading */
h2[data-editable]::after, .closing-title::after { content: ""; display: block; width: 60px; height: 4px; background: var(--amber); margin-top: 24px; }
h3 { font-weight: 700; font-size: 1.375rem; line-height: 1.2; }
.body p { max-width: 58ch; }
h2 + p, h1 + p { margin-top: 28px; }
p + p { margin-top: 18px; }
.lede { font-size: clamp(1.1875rem, 1.75vw, 1.375rem); line-height: 1.5; max-width: 36ch; }
.block-ink .lede { color: #e6edf8; }
.block-ink .lede-2 { color: var(--white); }
.lede-2 { font-weight: 700; }
.small { font-size: 1rem; color: var(--soft); }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.two-col-wide { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); }

/* ---------- hero ---------- */
.block-hero { overflow: hidden; }
.block-hero .spine { padding-top: clamp(40px, 6vw, 72px); }
.block-hero .body { padding-top: clamp(40px, 6vw, 72px); }
.watermark { position: absolute; right: -210px; top: -250px; width: 900px; height: 900px; pointer-events: none; }
.watermark path { fill: none; stroke-width: 0.6; }
.watermark .ring-a { stroke: var(--navy-line); }
.watermark .ring-b { stroke: rgba(241, 163, 28, 0.2); }
.hero-body { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: var(--gap); align-items: start; position: relative; }
.hero-copy .actions { margin-top: 36px; }

.acts { background: var(--sheet); border-radius: 4px; padding: 22px 22px 20px; box-shadow: 10px 10px 0 var(--shadow); }
.acts-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; padding-bottom: 14px; border-bottom: 1.5px solid var(--navy); }
.acts-title { font-size: 1.3125rem; font-weight: 900; letter-spacing: -0.01em; max-width: none; line-height: 1.2; }
.acts-head .acts-note { font-size: 0.9375rem; color: var(--soft); margin-top: 0; }
.acts-list { margin-top: 4px; }
.act {
  display: grid; grid-template-columns: 54px minmax(0, 1fr); column-gap: 14px; align-items: start;
  padding: 14px 0; border-bottom: 1px solid var(--hair); position: relative;
  transition: opacity 0.4s ease-out, transform 0.4s ease-out, background-color 0.25s;
}
.act:last-child { border-bottom: 0; }
.act-seal { width: 54px; height: 54px; }
.act-seal path { fill: none; stroke-width: 0.75; }
.act-what { font-weight: 700; font-size: 1.0625rem; line-height: 1.3; }
.act-detail { font-size: 1rem; line-height: 1.4; color: var(--soft); margin-top: 2px; }
.act-detail mark { background: none; color: var(--text); font-weight: 700; }
.act-hashes { margin-top: 6px; font-size: 0.875rem; line-height: 1.5; color: var(--soft); display: flex; flex-wrap: wrap; gap: 2px 16px; }
.act-hashes code { color: var(--text); font-size: 0.8125rem; }
.act-flag { display: none; margin-top: 6px; font-size: 0.9375rem; font-weight: 700; color: var(--bad); }
.act.is-bad { background: var(--bad-ground); margin: 0 -22px; padding-left: 22px; padding-right: 22px; }
.act.is-bad .ring-a, .act.is-bad .ring-b { stroke: var(--bad); }
.act.is-bad .act-flag { display: block; }
.act.is-bad .act-detail mark { color: var(--bad); text-decoration: underline; }
.act.is-gone .act-what, .act.is-gone .act-detail { text-decoration: line-through; color: var(--bad); }
.act.is-new { animation: arrive 0.6s ease-out; }
.act.is-arriving { opacity: 0; transform: translateY(8px); }
@keyframes arrive { 0% { background: var(--flash); } 100% { background: transparent; } }
.acts-status { margin-top: 14px; padding: 12px 14px; border-left: 4px solid var(--amber); background: var(--paper); font-size: 1rem; line-height: 1.45; min-height: 4.4em; max-width: none; }
.acts.is-refused .acts-status { border-left-color: var(--bad); background: var(--bad-ground); }
.acts-controls { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- block 1: the register ---------- */
.register { width: 100%; border-collapse: collapse; font-size: 1.0625rem; line-height: 1.4; background: var(--sheet); border: 2px solid var(--navy); }
.register caption { text-align: left; font-weight: 700; padding-bottom: 12px; font-size: 1.0625rem; }
.register th, .register td { text-align: left; vertical-align: top; padding: 16px 18px; border-bottom: 1px solid var(--hair); }
.register thead th { font-weight: 400; font-size: 0.9375rem; color: var(--soft); border-bottom: 1.5px solid var(--navy); padding-top: 10px; padding-bottom: 10px; }
.register tbody th { font-weight: 700; width: 42%; }
.register tr:last-child th, .register tr:last-child td { border-bottom: 0; }
.stamp { display: inline-block; margin-right: 8px; padding: 0 9px; border: 2px solid currentColor; border-radius: 2px; font-weight: 900; font-size: 0.9375rem; letter-spacing: 0.02em; transform: rotate(-2deg); }
.stamp-no { color: var(--breach); }
.stamp-yes { color: var(--navy); }

/* ---------- block 2: the signature ---------- */
.certificate {
  position: relative; background: var(--sheet); border: 2px solid var(--navy); padding: 30px 30px 26px;
  outline: 1px solid var(--navy); outline-offset: -8px;
}
.certificate-seal { position: absolute; right: 22px; top: 22px; width: 104px; height: 104px; }
.certificate-seal path, .erasure-seal path { fill: none; stroke-width: 0.65; }
.certificate dl > div, .erasure-card dl > div { padding: 11px 0; border-bottom: 1px solid var(--hair); }
.certificate dl > div:last-child, .erasure-card dl > div:last-child { border-bottom: 0; padding-bottom: 0; }
.certificate dl > div:nth-child(-n+2) { margin-right: 124px; }
dt { font-size: 0.9375rem; color: var(--soft); line-height: 1.3; }
dd { font-weight: 700; font-size: 1.125rem; line-height: 1.35; }

/* ---------- block 3: the evidence, on the deepest ground ---------- */
.block-ink .meta, .block-ink .small { color: var(--soft); }
.evidence-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.evidence-head h2 + p { margin-top: 6px; color: #e6edf8; }
.wall-wrap { margin-top: clamp(40px, 6vw, 72px); }
.body .wall-figure { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 28px; max-width: none; }
.wall-number {
  font-weight: 900; font-size: clamp(4.25rem, 12.4vw, 11rem); line-height: 0.86; letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
  color: transparent;
  background-image: repeating-linear-gradient(118deg, var(--amber) 0 1.5px, transparent 1.5px 4.5px);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-stroke: 1.5px var(--amber);
}
.wall-caption { font-size: clamp(1.125rem, 1.8vw, 1.5rem); font-weight: 300; max-width: 18ch; line-height: 1.25; padding-bottom: 0.5em; }
.wall { display: block; width: 100%; height: auto; margin-top: 26px; }
.wall-legend { margin-top: 14px; font-size: 1rem; color: var(--soft); max-width: none; }
.key { display: inline-block; width: 11px; height: 11px; margin: 0 7px 0 0; vertical-align: -1px; }
.key-test { background: var(--sky); }
.key-scenario { background: var(--amber); margin-left: 22px; }

.evidence-foot { margin-top: clamp(48px, 7vw, 88px); display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: var(--gap); align-items: start; }
.areas { margin-top: 20px; }
.areas li { display: grid; grid-template-columns: minmax(0, 15.5em) minmax(0, 1fr) 3.2em; gap: 14px; align-items: center; padding: 7px 0; font-size: 1.0625rem; line-height: 1.3; }
.area-bar { height: 12px; background: repeating-linear-gradient(90deg, var(--hair) 0 1px, transparent 1px 4px); }
.area-bar i { display: block; height: 100%; width: 0; background: repeating-linear-gradient(90deg, var(--sky) 0 2px, transparent 2px 4px); transition: width 0.9s cubic-bezier(0.2, 0.7, 0.2, 1); }
.area-n { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }

.slip {
  background: var(--sheet); padding: 34px 28px 26px; position: relative;
  transform: rotate(1.1deg);
  -webkit-mask: radial-gradient(circle at 9px 0, transparent 6px, #000 6.5px) -9px 0 / 18px 100%;
  mask: radial-gradient(circle at 9px 0, transparent 6px, #000 6.5px) -9px 0 / 18px 100%;
}
.slip figcaption { font-weight: 900; font-size: 1.5rem; padding-bottom: 12px; border-bottom: 1.5px dashed var(--navy); }
.slip li { position: relative; padding: 9px 0 9px 34px; border-bottom: 1px dashed var(--hair); font-size: 1.0625rem; line-height: 1.35; }
.slip li::before { content: ""; position: absolute; left: 4px; top: 13px; width: 16px; height: 9px; border-left: 3px solid var(--amber); border-bottom: 3px solid var(--amber); transform: rotate(-45deg) scale(0.86); }
.slip-total { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-top: 14px; font-weight: 700; font-size: 1.125rem; max-width: none; }
.slip-total span:last-child { font-weight: 900; font-size: 2rem; line-height: 1; font-variant-numeric: tabular-nums; }
.slip-note { margin-top: 8px; font-size: 1rem; color: var(--soft); }

/* ---------- the validation framework: the gates of a release ---------- */
.framework { margin-top: 34px; }
.gates { background: var(--sheet); border-radius: 4px; padding: 22px 22px 20px; box-shadow: 10px 10px 0 var(--shadow); }
.gates-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; padding-bottom: 14px; border-bottom: 1.5px solid var(--navy); }
.gates-title { font-size: 1.3125rem; font-weight: 900; letter-spacing: -0.01em; line-height: 1.2; }
.gates-head .gates-note { font-size: 0.9375rem; color: var(--soft); }
.attempts { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; margin-top: 16px; }
.attempt { min-height: 42px; padding: 8px 12px; border: 1.5px solid var(--navy); border-radius: 3px; background: var(--sheet); font-weight: 700; font-size: 0.9375rem; line-height: 1.25; text-align: left; cursor: pointer; transition: background-color 0.15s, color 0.15s; }
.attempt:hover { background: var(--paper-deep); }
.attempt[aria-pressed="true"] { background: var(--navy); color: var(--white); }
.attempt-good { border-style: dashed; }
.gates-list { margin-top: 12px; counter-reset: gate; }
.gate { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; column-gap: 14px; align-items: start; padding: 9px 0; transition: opacity 0.2s, background-color 0.2s; }
.gate::before {
  counter-increment: gate; content: counter(gate); position: relative; z-index: 1;
  width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--hair); background: var(--sheet); color: var(--soft);
  font-weight: 900; font-size: 0.875rem; line-height: 26px; text-align: center;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s;
}
.gate::after { content: ""; position: absolute; left: 14px; top: 39px; bottom: -9px; width: 2px; background: var(--hair); transition: background-color 0.2s; }
.gate:last-child::after { display: none; }
.gate-name { font-weight: 700; font-size: 1.0625rem; line-height: 1.3; }
.gate-detail { font-size: 0.9375rem; line-height: 1.4; color: var(--soft); margin-top: 1px; }
.gate-state { visibility: hidden; margin-top: 3px; padding: 0 7px; border: 1.5px solid currentColor; border-radius: 2px; font-size: 0.8125rem; font-weight: 700; white-space: nowrap; }
.gate.is-pass::before { background: var(--navy); border-color: var(--navy); color: var(--white); }
.gate.is-pass::after { background: var(--navy); }
.gate.is-pass .gate-state, .gate.is-stop .gate-state, .gate.is-unreached .gate-state { visibility: visible; }
.gate.is-stop { background: var(--bad-ground); margin: 0 -22px; padding-left: 22px; padding-right: 22px; }
.gate.is-stop::before { background: var(--bad); border-color: var(--bad); color: var(--white); }
.gate.is-stop::after { left: 36px; background: repeating-linear-gradient(to bottom, var(--bad) 0 5px, transparent 5px 10px); }
.gate.is-stop .gate-name { color: var(--bad); }
.gate.is-stop .gate-state { color: var(--white); background: var(--bad); border-color: var(--bad); }
.gate.is-unreached .gate-name, .gate.is-unreached .gate-detail { color: #7c8aa3; }
.gate.is-unreached .gate-state { color: var(--soft); border-style: dashed; }
.gates-status { display: flex; align-items: center; gap: 14px; margin-top: 12px; padding: 12px 14px; border-left: 4px solid var(--amber); background: var(--paper); font-size: 1rem; line-height: 1.45; min-height: 5.6em; }
.gates-status p { max-width: none; }
.gates.is-refused .gates-status { border-left-color: var(--bad); background: var(--bad-ground); }
.gates-seal { flex: none; width: 64px; height: 64px; }
.gates-seal path { fill: none; stroke-width: 0.75; }

/* ---------- block 4: the journey ---------- */
.stations { margin-top: 34px; counter-reset: station; }
.stations li { position: relative; padding: 0 0 26px 52px; font-size: 1.0625rem; line-height: 1.5; max-width: 46ch; }
.stations li::before {
  counter-increment: station; content: counter(station);
  position: absolute; left: 0; top: -2px; width: 34px; height: 34px; border-radius: 50%;
  border: 2px solid var(--line); background: var(--ground); color: var(--text);
  font-weight: 900; font-size: 1rem; line-height: 30px; text-align: center; z-index: 1;
}
.stations li::after { content: ""; position: absolute; left: 16px; top: 30px; bottom: -2px; width: 2px; background: var(--line); }
.stations li:last-child { padding-bottom: 0; }
.stations li:last-child::after { display: none; }
.stations strong { display: block; font-weight: 700; }

.phone { display: flex; justify-content: center; }
.phone-frame { width: 100%; max-width: 330px; border: 3px solid var(--navy); border-radius: 34px; background: var(--sheet); padding: 22px 16px 26px; box-shadow: 12px 12px 0 var(--shadow); }
.phone-title { text-align: center; font-weight: 700; font-size: 1rem; padding-bottom: 12px; border-bottom: 1px solid var(--hair); }
.bubble { margin-top: 16px; background: var(--paper-deep); border-radius: 16px 16px 16px 4px; padding: 12px 14px; font-size: 0.9375rem; line-height: 1.42; }
.bubble-link { text-decoration: underline; font-weight: 700; }
.checkin { margin-top: 16px; border: 2px solid var(--navy); border-radius: 12px; padding: 14px 14px 12px; }
.checkin-step { font-size: 0.875rem; color: var(--soft); }
.checkin-q { margin-top: 6px; font-weight: 700; font-size: 1.125rem; line-height: 1.28; }
.scale { margin-top: 14px; display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.scale button { min-height: 40px; border: 1.5px solid var(--hair); border-radius: 8px; background: var(--sheet); font-weight: 700; font-size: 1rem; cursor: pointer; padding: 0; }
.scale button:hover { border-color: var(--navy); }
.scale button.is-picked { background: var(--amber); border-color: var(--navy); }
.checkin-ends { margin-top: 8px; display: flex; justify-content: space-between; font-size: 0.8125rem; color: var(--soft); }

/* ---------- block 5: erasure ---------- */
.erasure-card { position: relative; background: var(--sheet); border: 2px solid var(--navy); padding: 22px 26px; }
.erasure-seal { position: absolute; right: 18px; top: 18px; width: 92px; height: 92px; }
.erasure-card dl > div:nth-child(-n+2) { margin-right: 108px; }
[data-secret] { transition: color 0.3s; }
.is-erased [data-secret] {
  color: transparent; user-select: none; border-radius: 2px; width: fit-content; min-width: 9em;
  background: repeating-linear-gradient(118deg, var(--navy) 0 2px, transparent 2px 5px);
}
.tick { display: inline-block; margin-left: 6px; padding: 0 7px; border: 1.5px solid var(--navy); border-radius: 2px; font-size: 0.8125rem; font-weight: 700; vertical-align: 2px; }
.erasure-status { margin: 14px 0; padding: 12px 14px; border-left: 4px solid var(--amber); background: var(--sheet); font-size: 1rem; line-height: 1.45; min-height: 4.4em; }

/* ---------- block 6: isolation ---------- */
.fits li { padding: 14px 0; border-bottom: 1px solid var(--hair); font-size: 1.0625rem; line-height: 1.5; }
.fits li:first-child { border-top: 1.5px solid var(--line); }
.fits strong { font-weight: 700; }
.tenants { margin-top: clamp(40px, 6vw, 72px); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 clamp(14px, 3vw, 40px); }
.tenant { border: 2px solid var(--navy); background: var(--sheet); padding: 18px 18px 8px; display: grid; gap: 8px; }
.tenant-name { font-weight: 900; font-size: 1.25rem; }
.tenant span { display: block; padding: 9px 12px; border: 1.5px solid var(--navy); font-weight: 700; font-size: 1rem; background: var(--paper); }
.tenant span:last-child { margin-bottom: 10px; }
.body .tenants-base { grid-column: 1 / -1; max-width: none; margin-top: 14px; padding: 12px 18px; text-align: center; font-size: 1rem; color: var(--soft); background: repeating-linear-gradient(118deg, var(--paper-deep) 0 2px, transparent 2px 6px); border: 1.5px dashed var(--hair); }

/* ---------- block 7: words ---------- */
.switch { margin-top: 30px; display: inline-flex; border: 2px solid var(--navy); border-radius: 3px; overflow: hidden; }
.switch button { border: 0; background: var(--sheet); padding: 12px 18px; min-height: 50px; font-weight: 700; font-size: 1.0625rem; cursor: pointer; }
.switch button + button { border-left: 2px solid var(--navy); }
.switch button.is-on { background: var(--navy); color: var(--white); }
.screen { background: var(--sheet); border: 2px solid var(--navy); border-radius: 4px; overflow: hidden; box-shadow: 10px 10px 0 var(--shadow); }
.screen-bar { background: var(--navy); color: var(--white); padding: 10px 16px; font-weight: 700; font-size: 1rem; max-width: none; }
.screen table { width: 100%; border-collapse: collapse; font-size: 1rem; line-height: 1.35; }
.screen th, .screen td { text-align: left; padding: 11px 16px; border-bottom: 1px solid var(--hair); }
.screen th { font-weight: 400; color: var(--soft); font-size: 0.9375rem; }
.screen td:first-child { font-family: var(--mono); font-size: 0.875rem; }
.screen-refusal { margin: 14px 16px 16px; padding: 10px 12px; border-left: 4px solid var(--breach); background: var(--breach-paper); font-size: 1rem; line-height: 1.4; }
[data-word].is-swapped { animation: swap 0.45s ease-out; }
@keyframes swap { 0% { background: var(--flash); } 100% { background: transparent; } }
.screen-bar [data-word].is-swapped { animation: none; }

/* ---------- block 8: verify, and the close ---------- */
.verify { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: var(--gap); align-items: start; }
.verify h2 { max-width: 18ch; }
.verify-copy > p { color: #e6edf8; }
.ledger-title-line { font-size: 1.0625rem; font-weight: 700; padding-bottom: 12px; }
.ledger { background: var(--sheet); font-size: 1rem; line-height: 1.35; border-radius: 4px; }
.ledger li { display: grid; grid-template-columns: 1.4em minmax(0, 1fr) auto auto; gap: 12px; align-items: baseline; padding: 10px 14px; border-bottom: 1px solid var(--hair); }
.ledger li:last-child { border-bottom: 0; }
.ledger-no { font-weight: 900; }
.ledger-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ledger-state { font-weight: 700; font-size: 0.8125rem; border: 1.5px solid currentColor; border-radius: 2px; padding: 0 7px; }
.ledger li.is-bad { background: var(--bad-ground); }
.ledger li.is-bad .ledger-state { color: var(--white); background: var(--bad); border-color: var(--bad); }
.ledger li.is-bad code { color: var(--bad); }
.verify-controls { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; }
.verify-status { margin-top: 20px; padding: 14px 16px; border-left: 4px solid var(--amber); background: var(--panel); font-size: 1.0625rem; line-height: 1.45; min-height: 3.2em; max-width: 62ch; }
.verify-status:empty { visibility: hidden; }
.verify.is-refused .verify-status { border-left-color: var(--bad); background: var(--bad-ground); }
.closing { margin-top: clamp(72px, 10vw, 136px); padding-top: clamp(40px, 6vw, 72px); border-top: 1.5px solid var(--hair); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 400px); gap: var(--gap); align-items: center; }
.closing-seal { display: block; width: 100%; height: auto; }
.closing-seal path { fill: none; stroke-width: 0.8; }
.closing-seal.is-broken .ring-a, .closing-seal.is-broken .ring-b { stroke: var(--bad); }
.closing-seal-wrap figcaption { margin-top: 10px; text-align: center; font-size: 0.9375rem; color: var(--soft); }
.closing-title { font-size: clamp(2.4rem, 5.4vw, 4.4rem); line-height: 1.02; max-width: 13ch; }
.closing-title b { display: block; }
.closing p { font-size: clamp(1.125rem, 1.6vw, 1.3125rem); max-width: 44ch; color: #e6edf8; }
.closing .actions { margin-top: 32px; }

/* the bar that appears while the page's chain is broken */
.alarm {
  position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 10;
  display: flex; align-items: center; gap: 16px; width: max-content; max-width: calc(100vw - 28px);
  background: var(--breach); color: var(--white); padding: 12px 14px 12px 20px; border-radius: 4px;
  box-shadow: 0 10px 30px rgba(4, 12, 28, 0.4); font-size: 1rem; line-height: 1.35;
}
.alarm[hidden] { display: none; }

/* ---------- footer: the lockup, whole ---------- */
.foot-inner { max-width: 1280px; margin: 0 auto; padding: clamp(48px, 7vw, 88px) var(--pad) clamp(40px, 6vw, 64px); display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 40px var(--gap); align-items: end; }
.foot-notes { display: grid; gap: 14px; font-size: 0.9375rem; line-height: 1.55; color: var(--soft); max-width: 52ch; }
.foot-notes p { margin: 0; }
.foot-name { color: var(--text); font-size: 1.0625rem; }
.foot-name strong { font-weight: 900; }

/* ---------- the one orchestrated moment: the record is engraved as the page opens ---------- */
.engrave path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: engrave 1.1s cubic-bezier(0.3, 0.6, 0.2, 1) forwards; }
@keyframes engrave { to { stroke-dashoffset: 0; } }

/* ---------- narrower screens ---------- */
@media (max-width: 1040px) {
  :root { --spine: 132px; --seal: 92px; }
  .hero-body, .two-col, .two-col-wide, .evidence-head, .evidence-foot, .verify, .closing, .foot-inner { grid-template-columns: minmax(0, 1fr); }
  .closing-seal-wrap { max-width: 320px; }
  .evidence-head h2 + p { margin-top: 0; }
  .top-nav { display: none; }
  .top .btn { margin-left: auto; }
  .lede { max-width: 40ch; }
  .slip { max-width: 520px; }
  .foot-inner { align-items: start; }
}
@media (max-width: 700px) {
  :root { --seal: 56px; }
  body { font-size: 1.0625rem; }
  .brand { font-size: 1.75rem; }
  .inner { grid-template-columns: minmax(0, 1fr); }
  .spine { display: flex; align-items: center; gap: 14px; padding-top: 56px; }
  .block-hero .spine { padding-top: 28px; }
  .spine::after, .block-hero .spine::after, .block-last .spine::after { left: 27px; top: 0; bottom: auto; height: 56px; }
  .block-hero .spine::after { display: none; }
  .body { padding-top: 24px; padding-bottom: 56px; }
  .block-hero .body { padding-top: 22px; }
  .meta { margin-top: 0; width: auto; text-align: left; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 12px; background: transparent; }
  .meta b, .meta code { display: inline; }
  .meta .state { margin-top: 0; }
  .seal .seal-no { font-size: 30px; }
  .watermark { width: 560px; height: 560px; right: -260px; top: -200px; }
  .acts, .gates { padding: 18px 16px 16px; box-shadow: 6px 6px 0 var(--shadow); }
  .gate.is-stop { margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
  .gate.is-stop::after { left: 30px; }
  .gate { grid-template-columns: 30px minmax(0, 1fr); }
  .gate-state { grid-column: 2; justify-self: start; margin-top: 6px; }
  .gate:not(.is-pass):not(.is-stop):not(.is-unreached) .gate-state { display: none; }
  .act.is-bad { margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
  .act { grid-template-columns: 44px minmax(0, 1fr); column-gap: 12px; }
  .act-seal { width: 44px; height: 44px; }
  .areas li { grid-template-columns: minmax(0, 1fr) 3.2em; }
  .area-bar { grid-column: 1 / -1; grid-row: 2; }
  .tenants { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .tenants-base { margin-top: 0; }
  .switch { display: flex; }
  .switch button { flex: 1; padding: 10px 10px; }
  .alarm { flex-direction: column; align-items: flex-start; gap: 10px; left: 14px; right: 14px; transform: none; width: auto; }
  .certificate { padding: 24px 20px 20px; }
  .slip { transform: none; }
  .phone-frame { box-shadow: 6px 6px 0 var(--shadow); }
  .screen { box-shadow: 6px 6px 0 var(--shadow); }
  .screen th, .screen td { padding: 9px 10px; font-size: 0.9375rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001s !important; transition-duration: 0.001s !important; }
  .engrave path { stroke-dashoffset: 0; animation: none; }
}
