/* Sentinel v2. Builds on the Cucumbs shared tokens (tokens.css). System fonts only, no external assets. */
:root {
  color-scheme: light dark;
  --bg: var(--cu-color-paper);
  --surface: var(--cu-color-surface);
  --surface-2: var(--cu-color-surface-sunken);
  --text: var(--cu-color-ink);
  --muted: var(--cu-color-ink-muted);
  --line: var(--cu-color-line);
  --line-strong: var(--cu-color-line-strong);
  --link: var(--cu-color-vine-700);
  --vine: var(--cu-color-vine-700);
  --vine-ink: #ffffff;
  --vine-soft: var(--cu-color-vine-100);
  --sentinel: #b4392d;        /* Sentinel identity accent (hub coral, darkened for light backgrounds) */
  --sentinel-soft: #fbe6e2;
  --focus: #b5470b;
  --hard: #a3241b;
  --hard-bg: #fbe3e0;
  --caution: #8a5100;
  --caution-bg: #fbefd6;
  --note: #2f5288;
  --note-bg: #e3ecfa;
  --go: var(--cu-status-confirmed);
  --go-bg: var(--cu-status-confirmed-bg);
  --radius: var(--cu-radius-lg);
  --maxw: 74rem;
  --font: var(--cu-font-sans);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, ui-serif, serif;
  --mono: var(--cu-font-mono);
  --shadow: var(--cu-shadow-panel);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #07130e;
    --surface: #10251c;
    --surface-2: #153126;
    --text: #eaf1e8;
    --muted: #a9bdb0;
    --line: #24453a;
    --line-strong: #3d6a5a;
    --link: #5fd3a0;
    --vine: #5fd3a0;
    --vine-ink: #06241a;
    --vine-soft: #153126;
    --sentinel: #ff9a8f;
    --sentinel-soft: #3a1c19;
    --focus: #f4e3b5;
    --hard: #ff9c92;
    --hard-bg: #44201c;
    --caution: #f3c063;
    --caution-bg: #3a2c0f;
    --note: #a9c3f0;
    --note-bg: #1b2a40;
    --go: #8fe3b5;
    --go-bg: #12392a;
    --shadow: none;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1.5rem; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 1.0625rem/1.62 var(--font);
  border-top: 4px solid var(--sentinel);
}
[hidden] { display: none !important; }
img, svg { max-width: 100%; }
a { color: var(--link); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible, :where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px;
}
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.22; letter-spacing: -0.005em; }
h1 { font-size: clamp(2rem, 4.2vw, 2.8rem); margin: 0 0 0.6rem; }
h2 { font-size: clamp(1.4rem, 2.6vw, 1.8rem); margin: 2.6rem 0 0.9rem; }
h3 { font-size: 1.15rem; margin: 0 0 0.4rem; }
h4 { font-size: 1rem; margin: 0 0 0.3rem; }
p, ul, ol { margin: 0 0 1rem; }
code, kbd { font-family: var(--mono); font-size: 0.9em; overflow-wrap: anywhere; }
small { font-size: 0.85em; }

.skip { position: absolute; left: 1rem; top: -3rem; background: var(--vine); color: var(--vine-ink); padding: 0.5rem 0.9rem; border-radius: var(--radius); z-index: 10; }
.skip:focus { top: 1rem; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.inner { max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1.5rem; padding-top: 0.8rem; padding-bottom: 0.8rem; }
.brand { display: inline-flex; align-items: center; gap: 0.55rem; color: var(--text); text-decoration: none; font-weight: 700; font-size: 1.15rem; }
.brand img { width: 28px; height: 28px; }
.brand small { font-weight: 500; color: var(--muted); font-size: 0.82rem; }
.site-nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 0.15rem; margin: 0; padding: 0; }
.site-nav a { display: block; padding: 0.35rem 0.7rem; border-radius: 999px; color: var(--text); text-decoration: none; font-weight: 500; font-size: 0.97rem; }
.site-nav a:hover { background: var(--surface-2); }
.site-nav a[aria-current="page"] { background: var(--vine); color: var(--vine-ink); }
.hubline { background: var(--surface-2); border-bottom: 1px solid var(--line); font-size: 0.85rem; color: var(--muted); }
.hubline .inner { padding-top: 0.3rem; padding-bottom: 0.3rem; }
.hubline a { color: var(--muted); }

/* Main */
main { max-width: var(--maxw); margin: 0 auto; padding: 2.4rem 1.25rem 3.5rem; }
.lede { font-size: 1.18rem; color: var(--muted); max-width: 46rem; }
.prose { max-width: 46rem; }
.eyebrow { display: inline-block; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--sentinel); margin-bottom: 0.6rem; }
.hero { display: grid; gap: 2rem; align-items: center; padding: 1rem 0 0.5rem; }
@media (min-width: 60rem) { .hero { grid-template-columns: 1.25fr 1fr; } }
.actions { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 1.3rem; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem; padding: 0.55rem 1.05rem; border-radius: var(--radius); border: 1px solid var(--vine); background: var(--vine); color: var(--vine-ink); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn:hover { filter: brightness(1.08); }
.btn.secondary { background: transparent; color: var(--link); }
.btn.quiet { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.linkish { background: none; border: 0; padding: 0; font: inherit; color: var(--link); text-decoration: underline; cursor: pointer; text-align: left; }

/* Cards and grids */
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); }
.grid.two { grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.15rem 1.25rem; box-shadow: var(--shadow); }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
a.card { display: block; color: var(--text); text-decoration: none; }
a.card:hover { border-color: var(--vine); }
a.card h3 { color: var(--link); }
.card .meta { color: var(--muted); font-size: 0.88rem; margin-bottom: 0.5rem; }

.passes { counter-reset: pass; list-style: none; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.passes li { counter-increment: pass; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.2rem 1.1rem 3.4rem; position: relative; }
.passes li::before { content: counter(pass); position: absolute; left: 1.05rem; top: 1rem; width: 1.65rem; height: 1.65rem; border-radius: 50%; display: grid; place-items: center; background: var(--sentinel-soft); color: var(--sentinel); font-weight: 700; font-size: 0.9rem; }
.passes strong { display: block; font-family: var(--serif); font-size: 1.08rem; }

.principles { list-style: none; padding: 0; display: grid; gap: 0.9rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.principles li { border-left: 3px solid var(--vine); padding: 0.15rem 0 0.15rem 0.9rem; }
.principles strong { display: block; }

table.status-table { width: 100%; border-collapse: collapse; font-size: 0.96rem; }
table.status-table th, table.status-table td { text-align: left; padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
table.status-table th[scope="col"] { color: var(--muted); font-weight: 600; font-size: 0.85rem; }
.cu-status { font-size: 0.78rem; }
@media (prefers-color-scheme: dark) {
  .cu-status--implemented { color: #a9c8ff; background: #172a48; }
  .cu-status--planned { color: #8fd8e8; background: #10323a; }
  .cu-status--proposed { color: #cdb3ff; background: #2a1f45; }
  .cu-status--confirmed { color: #8fe3b5; background: #12392a; }
  .cu-status--unresolved { color: #c4cad1; background: #2a2f35; }
}

/* Flow diagram */
.flow { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem; }
.flow svg { display: block; width: 100%; height: auto; }
.flow .box { fill: var(--surface-2); stroke: var(--line-strong); stroke-width: 1.5; }
.flow .box.you { stroke: var(--vine); }
.flow .box.wall { fill: none; stroke: var(--sentinel); stroke-dasharray: 6 5; stroke-width: 2; }
.flow text { fill: var(--text); font: 600 15px var(--font); }
.flow text.small { fill: var(--muted); font: 400 13px var(--font); }
.flow .arrow { stroke: var(--vine); stroke-width: 2; fill: none; marker-end: url(#arrowhead); }
.flow .arrow.blocked { stroke: var(--sentinel); stroke-dasharray: 4 4; }
.flow #arrowhead path { fill: var(--vine); }
.flow figcaption { color: var(--muted); font-size: 0.9rem; margin-top: 0.5rem; }

/* Notices */
.banner { border: 2px solid var(--caution); background: var(--caution-bg); color: var(--text); border-radius: var(--radius); padding: 0.85rem 1.1rem; margin: 0 0 1.5rem; }
.banner strong { color: var(--caution); }
.callout { background: var(--surface-2); border-radius: var(--radius); padding: 1rem 1.2rem; margin: 1.5rem 0; }
.callout > :last-child { margin-bottom: 0; }

/* Severity and verdicts */
.sev { display: inline-block; font-size: 0.76rem; font-weight: 700; letter-spacing: 0.03em; text-transform: uppercase; padding: 0.12rem 0.55rem; border-radius: 999px; border: 1px solid currentColor; white-space: nowrap; font-family: var(--font); }
.sev-hard { color: var(--hard); background: var(--hard-bg); }
.sev-caution { color: var(--caution); background: var(--caution-bg); border-style: dashed; }
.sev-note { color: var(--note); background: var(--note-bg); border-style: dotted; }
.sev-go { color: var(--go); background: var(--go-bg); }
.sev-unknown { color: var(--muted); background: var(--surface-2); border-style: dotted; }

/* Guide */
.toc { columns: 2 16rem; column-gap: 2rem; padding-left: 1.2rem; }
.toc li { break-inside: avoid; margin-bottom: 0.3rem; }
.checklist { list-style: none; padding: 0; columns: 2 18rem; column-gap: 2rem; }
.checklist li { break-inside: avoid; margin-bottom: 0.45rem; }
.checklist label { display: flex; gap: 0.6rem; align-items: flex-start; cursor: pointer; }
.checklist input { width: 1.1rem; height: 1.1rem; margin-top: 0.25rem; accent-color: var(--vine); flex: none; }
.item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem 1.4rem; margin: 0 0 1.1rem; box-shadow: var(--shadow); }
.item h2 { margin: 0 0 0.8rem; font-size: 1.25rem; display: flex; flex-wrap: wrap; gap: 0.5rem 0.75rem; align-items: center; }
.item dl { margin: 0; display: grid; grid-template-columns: 9.5rem 1fr; gap: 0.5rem 1.2rem; }
.item dt { font-weight: 700; color: var(--muted); }
.item dd { margin: 0; }
.item .tools { margin: 0.9rem 0 0; font-size: 0.93rem; }
@media (max-width: 40rem) { .item dl { grid-template-columns: 1fr; } .item dd { margin-bottom: 0.5rem; } }

/* Gallery */
.legend { display: flex; flex-wrap: wrap; gap: 0.6rem 1.4rem; align-items: center; margin-bottom: 1.2rem; }
.legend .desc { color: var(--muted); font-size: 0.94rem; }
.filters { display: grid; gap: 0.9rem 1.2rem; grid-template-columns: 1fr; align-items: end; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; margin: 0 0 1.4rem; }
@media (min-width: 52rem) { .filters { grid-template-columns: 1.4fr 1fr auto; } }
.filters label, .filters legend { font-weight: 700; font-size: 0.92rem; display: block; margin-bottom: 0.3rem; padding: 0; }
.filters fieldset { border: 0; margin: 0; padding: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 0.4rem 0.9rem; }
.chips label { font-weight: 500; display: inline-flex; align-items: center; gap: 0.35rem; margin: 0; cursor: pointer; }
.chips input { accent-color: var(--vine); width: 1.05rem; height: 1.05rem; }
input[type="search"], input[type="text"], select {
  width: 100%; padding: 0.55rem 0.7rem; border: 1px solid var(--line-strong); border-radius: var(--cu-radius-md);
  background: var(--bg); color: var(--text); font: inherit;
}
.filter-count { color: var(--muted); font-size: 0.93rem; margin: 0; }
.flag { display: flex; flex-direction: column; gap: 0.55rem; }
.flag header { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.75rem; }
.flag blockquote { margin: 0; padding: 0.75rem 0.9rem; border-left: 3px solid var(--line-strong); background: var(--surface-2); border-radius: 0 6px 6px 0; font-family: var(--mono); font-size: 0.86rem; line-height: 1.55; }
.flag blockquote p { margin: 0; }
.flag .tag { font-size: 0.78rem; color: var(--muted); font-style: italic; margin: 0; }
.flag .cat { font-size: 0.82rem; color: var(--muted); margin: 0; }
.flag p { margin: 0; }
.flag.hard { border-top: 4px solid var(--hard); }
.flag.caution { border-top: 4px dashed var(--caution); }
.flag.note { border-top: 4px dotted var(--note); }
.empty-state { color: var(--muted); font-style: italic; }

/* Tools (highlighter, scopes, triage) */
.tool { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 62rem) { .tool { grid-template-columns: 1fr 1fr; } }
.field label.big, .field .label { display: block; font-weight: 700; margin-bottom: 0.4rem; }
.hint { color: var(--muted); font-size: 0.92rem; margin: 0 0 0.5rem; }
textarea { width: 100%; min-height: 20rem; resize: vertical; padding: 0.85rem 0.95rem; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); color: var(--text); font: 0.93rem/1.55 var(--mono); }
textarea.short { min-height: 9rem; }
.toolbar { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.7rem; align-items: center; }
.toolbar .count { color: var(--muted); font-size: 0.9rem; margin-left: auto; }
.output { min-height: 20rem; max-height: 40rem; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; padding: 0.85rem 0.95rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); font: 0.93rem/1.7 var(--mono); }
.output .empty { color: var(--muted); font-family: var(--font); margin: 0; }
mark.hl { color: inherit; border-radius: 3px; padding: 0 1px; border-bottom: 2px solid; cursor: pointer; }
mark.hl.sev-hard { background: var(--hard-bg); border-bottom-color: var(--hard); border-bottom-style: solid; }
mark.hl.sev-caution { background: var(--caution-bg); border-bottom-color: var(--caution); border-bottom-style: dashed; }
mark.hl.sev-note { background: var(--note-bg); border-bottom-color: var(--note); border-bottom-style: dotted; }
mark.hl:focus, mark.hl.active { outline: 3px solid var(--focus); outline-offset: 1px; }
.status { font-weight: 600; min-height: 1.6em; }
.results { margin-top: 1.25rem; display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 62rem) { .results { grid-template-columns: 1fr 1fr; } }
.controls { margin-top: 1.25rem; }
.controls fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.8rem 1rem 0.9rem; margin: 0 0 1rem; background: var(--surface); }
.controls legend { font-weight: 700; padding: 0 0.3rem; }
.explain { border-left: 4px solid var(--vine); }
.explain h3 { display: flex; gap: 0.6rem; flex-wrap: wrap; align-items: center; }
table.summary { width: 100%; border-collapse: collapse; font-size: 0.94rem; }
table.summary th, table.summary td { text-align: left; padding: 0.5rem 0.4rem; border-bottom: 1px solid var(--line); vertical-align: top; }
table.summary td.num { font-variant-numeric: tabular-nums; font-weight: 700; text-align: right; }
table.summary .why { display: block; color: var(--muted); font-size: 0.87rem; font-weight: 400; }
ol.jumps { margin: 0; padding-left: 1.6rem; max-height: 28rem; overflow: auto; font-size: 0.92rem; }
ol.jumps li { margin-bottom: 0.35rem; }
ol.jumps .ctx { color: var(--muted); }
.report-opts { display: flex; flex-wrap: wrap; gap: 0.6rem 1.2rem; align-items: center; }
.report-opts label { display: inline-flex; gap: 0.4rem; align-items: center; }
pre.report { white-space: pre-wrap; overflow-wrap: anywhere; background: var(--surface-2); border-radius: var(--radius); padding: 0.9rem 1rem; font: 0.85rem/1.5 var(--mono); max-height: 24rem; overflow: auto; }
noscript p { border: 1px solid var(--line); padding: 0.8rem 1rem; border-radius: var(--radius); background: var(--surface); }

/* Triage */
.triage-wrap { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 62rem) { .triage-wrap { grid-template-columns: 1.3fr 1fr; align-items: start; } }
.progress { height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; margin: 0 0 0.4rem; border: 1px solid var(--line); }
.progress span { display: block; height: 100%; width: 0; background: var(--vine); }
.progress-label { color: var(--muted); font-size: 0.9rem; margin: 0 0 1rem; }
fieldset.q { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 1.1rem 1.25rem 1.2rem; margin: 0 0 1rem; box-shadow: var(--shadow); }
fieldset.q legend { font-family: var(--serif); font-weight: 600; font-size: 1.18rem; line-height: 1.3; padding: 0 0.25rem; }
fieldset.q .qnum { display: block; font-family: var(--font); font-size: 0.8rem; font-weight: 700; color: var(--muted); letter-spacing: 0.05em; text-transform: uppercase; }
fieldset.q .why { color: var(--muted); font-size: 0.94rem; margin: 0.3rem 0 0.8rem; }
.answers { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.answers label { display: inline-flex; align-items: center; gap: 0.45rem; border: 1px solid var(--line-strong); border-radius: 999px; padding: 0.4rem 0.95rem; cursor: pointer; background: var(--bg); }
.answers input { accent-color: var(--vine); width: 1.05rem; height: 1.05rem; margin: 0; }
.answers label:has(input:checked) { border-color: var(--vine); background: var(--vine-soft); font-weight: 600; }
.stepper-nav { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.js .q-step:not(.current) { display: none; }
.readout { border-top: 6px solid var(--line-strong); }
.readout.v-nogo { border-top-color: var(--hard); }
.readout.v-caution { border-top-color: var(--caution); }
.readout.v-go { border-top-color: var(--go); }
.verdict { font-family: var(--serif); font-size: 1.9rem; font-weight: 700; margin: 0.2rem 0 0.4rem; }
.verdict.v-nogo { color: var(--hard); }
.verdict.v-caution { color: var(--caution); }
.verdict.v-go { color: var(--go); }
.readout ul { padding-left: 1.2rem; }
.readout li { margin-bottom: 0.55rem; }
.tally { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1rem; }

/* Scopes */
.scope-table { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
.scope-table th, .scope-table td { text-align: left; padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.scope-table th[scope="col"] { color: var(--muted); font-size: 0.85rem; }
.scope-table code { font-size: 0.82rem; color: var(--muted); }
.scope-table .gdesc { font-style: italic; }
.picker { columns: 2 17rem; column-gap: 1.5rem; }
.picker .group { break-inside: avoid; margin-bottom: 0.9rem; }
.picker h4 { margin-bottom: 0.25rem; }
.picker label { display: flex; gap: 0.5rem; align-items: flex-start; font-size: 0.94rem; margin-bottom: 0.2rem; cursor: pointer; }
.picker input { accent-color: var(--vine); margin-top: 0.3rem; flex: none; }
.decoded .scope-row { padding: 0.8rem 0; border-bottom: 1px solid var(--line); }
.decoded .scope-row:last-child { border-bottom: 0; }
.decoded .scope-row h4 { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.decoded .scope-row p { margin: 0.2rem 0; }
.decoded .scope-row code { color: var(--muted); font-size: 0.82rem; }

/* Worked example */
.example-step { display: grid; gap: 1rem 1.5rem; grid-template-columns: 1fr; margin-bottom: 2rem; }
@media (min-width: 60rem) { .example-step { grid-template-columns: 1.1fr 1fr; } }
.mock { background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 1.1rem 1.2rem; font-size: 0.95rem; }
.mock .mock-title { font-weight: 700; margin-bottom: 0.6rem; }
.mock ul { padding-left: 1.1rem; }
.mock .doc { font-family: var(--mono); font-size: 0.86rem; line-height: 1.7; white-space: normal; }
.finding { list-style: none; padding: 0; margin: 0; }
.finding li { border-left: 3px solid var(--line-strong); padding: 0.1rem 0 0.1rem 0.8rem; margin-bottom: 0.8rem; }
.finding li.hard { border-left-color: var(--hard); }
.finding li.caution { border-left-color: var(--caution); border-left-style: dashed; }
.finding li.note { border-left-color: var(--note); border-left-style: dotted; }
.basis { display: inline-block; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); border: 1px solid var(--line-strong); border-radius: 4px; padding: 0 0.35rem; margin-left: 0.3rem; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: 0.92rem; }
.site-footer .inner { padding-top: 1.4rem; padding-bottom: 1.6rem; display: flex; flex-wrap: wrap; gap: 0.5rem 2rem; justify-content: space-between; }
.site-footer p { margin: 0; }

@media (max-width: 34rem) {
  .brand small { display: none; }
  .site-nav a { padding: 0.3rem 0.55rem; font-size: 0.93rem; }
}
@media print {
  .site-header nav, .hubline, .actions, .toolbar, .skip, .filters, .stepper-nav { display: none; }
  body { background: #fff; color: #000; border-top: 0; }
  .item, .card, fieldset.q { break-inside: avoid; box-shadow: none; }
  .js .q-step:not(.current) { display: block; }
}

/* Axioms */
ol.axioms { padding-left: 1.4rem; margin: 0; }
ol.axioms li { margin-bottom: 0.8rem; color: var(--muted); }
ol.axioms li strong { display: block; color: var(--text); font-family: var(--serif); font-size: 1.08rem; }

/* How this site was made */
.facts { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr)); }
pre.headers { white-space: pre-wrap; overflow-wrap: anywhere; background: var(--surface-2); border-radius: var(--radius); padding: 0.9rem 1rem; font: 0.82rem/1.5 var(--mono); margin: 0; }
table.files { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
table.files th, table.files td { text-align: left; padding: 0.4rem 0.4rem; border-bottom: 1px solid var(--line); }
table.files td.num { text-align: right; font-variant-numeric: tabular-nums; }
ul.checks { list-style: none; padding: 0; }
ul.checks li { padding-left: 1.6rem; position: relative; margin-bottom: 0.45rem; }
ul.checks li::before { content: "\2713"; position: absolute; left: 0.2rem; color: var(--go); font-weight: 700; }
ul.checks.open li::before { content: "?"; color: var(--caution); }

/* ---------- v3: depth, texture and the journey ---------- */
:root {
  --paper: #eceee7;
  --paper-glow: rgba(29, 94, 72, 0.07);
  --band-bg: #0b1c15;
  --band-ink: #eaf1e8;
  --band-muted: #b9cbbf;
  --band-line: #24453a;
  --band-vine: #5fd3a0;
  --lift: 0 1px 0 rgba(255, 255, 255, 0.6) inset, 0 1px 2px rgba(24, 32, 25, 0.08), 0 8px 24px -12px rgba(24, 32, 25, 0.18);
}
@media (prefers-color-scheme: light) {
  :root { --bg: var(--paper); --surface: #f9f9f5; --surface-2: #e4e8e0; }
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper-glow: rgba(95, 211, 160, 0.08);
    --band-bg: #04100b;
    --lift: 0 1px 0 rgba(255, 255, 255, 0.03) inset, 0 10px 30px -14px rgba(0, 0, 0, 0.7);
  }
}
.card, .item, fieldset.q, .mock, .filters, .flow, .controls fieldset { box-shadow: var(--lift); }
.site-header { background: color-mix(in srgb, var(--surface) 88%, transparent); }
.site-footer { background: var(--band-bg); color: var(--band-muted); border-top-color: var(--band-line); }
.site-footer a { color: var(--band-vine); }
h2 { position: relative; }
main > h2::before, main > section > h2::before {
  content: ""; display: block; width: 2.2rem; height: 3px; border-radius: 2px;
  background: var(--sentinel); margin-bottom: 0.6rem; opacity: 0.85;
}

/* Hero band: the one deep, dark room on the home page, in both color schemes. */
.band {
  background-color: var(--band-bg);
  color: var(--band-ink);
  border-radius: calc(var(--radius) + 6px);
  padding: clamp(1.5rem, 4vw, 2.8rem);
  margin-bottom: 1rem;
  border: 1px solid var(--band-line);
}
.band .lede { color: var(--band-muted); }
.band .eyebrow { color: #ff9a8f; }
.band .btn { background: var(--band-vine); border-color: var(--band-vine); color: #06241a; }
.band .btn.secondary { background: transparent; color: var(--band-vine); }
.band a:not(.btn) { color: var(--band-vine); }
.band :focus-visible { outline-color: #f4e3b5; }
.band .flow { background: rgba(16, 37, 28, 0.85); border-color: var(--band-line); box-shadow: none; }
.band .flow text { fill: var(--band-ink); }
.band .flow text.small, .band .flow figcaption { fill: var(--band-muted); color: var(--band-muted); }
.band .flow .box { fill: #153126; stroke: #3d6a5a; }
.band .flow .box.you { stroke: var(--band-vine); }
.band .flow .box.wall { stroke: #ff9a8f; fill: none; }
.band .flow .arrow { stroke: var(--band-vine); }
.band .flow .arrow.blocked { stroke: #ff9a8f; }
.band .flow #arrowhead path { fill: var(--band-vine); }

/* The route on the home page */
ol.route { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: 0.6rem; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); counter-reset: none; }
ol.route li > a, ol.route li.here { display: flex; gap: 0.8rem; align-items: flex-start; padding: 0.85rem 1rem; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text); text-decoration: none; box-shadow: var(--lift); height: 100%; }
ol.route li > a:hover { border-color: var(--vine); }
ol.route .n { flex: none; width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; background: var(--sentinel-soft); color: var(--sentinel); font-weight: 700; }
ol.route strong { display: block; font-family: var(--serif); font-size: 1.08rem; color: var(--link); margin-bottom: 0.15rem; }
ol.route .body { flex: 1; }
ol.route .sev { margin-bottom: 0.25rem; }
ol.route li.here { border-style: dashed; background: transparent; box-shadow: none; color: var(--muted); }
ol.route li.here strong { color: var(--text); }

/* Axiom epigraphs */
figure.epigraph { margin: 0.4rem 0 0.4rem; padding: 0.9rem 1.1rem 0.8rem 1.2rem; border-left: 3px solid var(--vine); background: linear-gradient(90deg, var(--vine-soft), transparent 85%); border-radius: 0 var(--radius) var(--radius) 0; max-width: 46rem; }
figure.epigraph blockquote { margin: 0; }
figure.epigraph blockquote p { margin: 0; font-family: var(--serif); font-size: 1.2rem; font-style: italic; }
figure.epigraph figcaption { color: var(--muted); font-size: 0.85rem; margin-top: 0.3rem; }
p.ours { max-width: 46rem; color: var(--muted); font-size: 0.95rem; margin: 0.2rem 0 1.4rem; }
.ours-label { font-weight: 700; font-size: 0.78rem; letter-spacing: 0.04em; text-transform: uppercase; margin-right: 0.3rem; }

/* Journey: the next-step hand-off at the end of every page */
nav.journey { margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid var(--line); display: grid; gap: 0.8rem; }
.journey-step { margin: 0; color: var(--muted); font-size: 0.85rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
a.handoff {
  display: grid; gap: 0.2rem; text-decoration: none; color: var(--band-ink); max-width: 40rem;
  padding: 1.1rem 3.4rem 1.2rem 1.3rem; border-radius: calc(var(--radius) + 4px); position: relative;
  background-color: var(--band-bg);
  border: 1px solid var(--band-line); box-shadow: var(--lift);
}
a.handoff::after { content: "\2192"; position: absolute; right: 1.3rem; top: 50%; transform: translateY(-50%); font-size: 1.6rem; color: var(--band-vine); }
@media (prefers-reduced-motion: no-preference) {
  a.handoff::after { transition: transform var(--cu-duration-base) var(--cu-ease); }
  a.handoff:hover::after, a.handoff:focus-visible::after { transform: translate(4px, -50%); }
}
a.handoff:hover { border-color: var(--band-vine); }
a.handoff:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.handoff-label { color: var(--band-muted); font-size: 0.82rem; }
.handoff-title { font-family: var(--serif); font-size: 1.45rem; font-weight: 600; color: var(--band-vine); }
.handoff-blurb { color: var(--band-ink); }
.journey-prev { margin: 0; font-size: 0.93rem; }
ol.journey-rail { list-style: none; padding: 0; margin: 0.4rem 0 0; display: flex; flex-wrap: wrap; gap: 0.3rem; font-size: 0.85rem; }
ol.journey-rail a { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.2rem 0.6rem 0.2rem 0.25rem; border-radius: 999px; color: var(--muted); text-decoration: none; border: 1px solid var(--line); background: var(--surface); }
ol.journey-rail .n { width: 1.3rem; height: 1.3rem; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); font-weight: 700; font-size: 0.75rem; }
ol.journey-rail li.done .n { background: var(--vine-soft); color: var(--vine); }
ol.journey-rail a[aria-current="step"] { color: var(--vine-ink); background: var(--vine); border-color: var(--vine); font-weight: 600; }
ol.journey-rail a[aria-current="step"] .n { background: rgba(255, 255, 255, 0.25); color: inherit; }
ol.journey-rail a:hover { border-color: var(--vine); }
@media print { nav.journey { display: none; } body { background: #fff; } .band { background: none; color: #000; } }

/* Moving inward, then back out: each step of the route sits a little deeper than the last,
   the fine-print pages are the deepest, and the last pages lift back toward the decision. */
@media (prefers-color-scheme: light) {
  body.depth-1 { --bg: #f2f3ee; }
  body.depth-2 { --bg: #eceee7; }
  body.depth-3 { --bg: #e6e9e1; --surface: #f6f6f1; }
  body.depth-4 { --bg: #dfe3da; --surface: #f3f4ee; }
}
@media (prefers-color-scheme: dark) {
  body.depth-1 { --bg: #0b1912; }
  body.depth-2 { --bg: #08150f; }
  body.depth-3 { --bg: #06110c; }
  body.depth-4 { --bg: #030c08; --surface: #0d2018; }
}
body.depth-3 main, body.depth-4 main { padding-top: 2.8rem; }

/* The reader's moment, at the top of each page */
p.moment { margin: 0 0 0.5rem; font-family: var(--serif); font-style: italic; font-size: 1.08rem; color: var(--sentinel); max-width: 44rem; }
.band p.moment { color: #ff9a8f; }

/* A quiet second layer before the hand-off */
aside.second-layer { margin: 2.6rem 0 0; max-width: 40rem; padding: 0.2rem 0 0.2rem 1.1rem; border-left: 2px solid var(--line-strong); color: var(--muted); }
aside.second-layer p { margin: 0; font-family: var(--serif); font-size: 1.12rem; line-height: 1.55; }
aside.second-layer .aside-label { display: block; font-family: var(--font); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 0.35rem; }
