/* =========================================================
   SYSTEMS PAGE
   Six chapters, each at least one screen tall. Visual first.
   ========================================================= */

:root {
    --ink: #2a2824;
    --paper: #efece5;
    /* palette, the same block as app.css. -ink: text on Ivory. -lt: text and lines on Charcoal. plain: fills, borders, icons. -bg: soft card backgrounds */
    --sage: #879487;   --sage-ink: #4F5E4F;   --sage-lt: #A9B5A8;   --sage-bg: #E3E7E0;
    --clay: #B97863;   --clay-ink: #8A4A36;   --clay-lt: #D49A85;   --clay-bg: #F2E3DC;
    --slate: #788B9A;  --slate-ink: #445767;  --slate-lt: #9DAEBB;  --slate-bg: #E0E6EA;
    --pop: #C8553D;    /* strong terracotta: fail, warnings, the one main action */
    --pop-ink: #B04A33;   /* the same, a little darker, for text and for Ivory text on it (4.6 to 1) */
    --none: rgba(42, 40, 36, 0.45);
    --line: rgba(42, 40, 36, 0.2);
    --line-d: rgba(239, 236, 229, 0.2);
    --line-s: rgba(239, 236, 229, 0.55);     /* How: tile borders and arrows, one stroke */
}

html { scroll-behavior: smooth; overflow-anchor: none; }   /* the page only moves when you scroll it */

body.sys { background: var(--paper); color: var(--ink); }

.header.solid,
.header.scrolled { background: var(--paper); }
.logo a, nav a { color: var(--ink); }

/* style.css styles every button; reset ours */
.sys main button,
.sys .rail button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    padding: 0;
    font-weight: inherit;
    text-align: left;
}
.sys main button { cursor: pointer; }

.eyebrow {
    display: block;
    font-size: 0.68rem;
    letter-spacing: 0.25rem;
    text-transform: uppercase;
    opacity: 0.6;
}


/* =========================================================
   CHAPTERS
   ========================================================= */

.chapter { position: relative; scroll-margin-top: 60px; }
/* only the opening screen fills the window; the other chapters are as tall as what they hold (no empty screen after short ones) */
.chapter.hero { min-height: 100vh; }
.chapter.light { background: var(--paper); color: var(--ink); }
.chapter.dark  { background: var(--ink);   color: var(--paper); --ask-flip: var(--ink); }

.ch-inner { padding: 7.5rem max(10vw, calc(2.2vw + 6.5rem)) 5rem 8vw; }   /* right: always clear of the rail */

.ch-inner h2 {
    font-family: 'Cinzel', serif;
    font-size: clamp(1.8rem, 3.6vw, 3rem);
    letter-spacing: 0.15rem;
    line-height: 1.2;
    margin-bottom: 2.5rem;
}

.ch-line {
    max-width: 720px;
    margin-top: 2.5rem;
    font-family: 'Fraunces', serif;
    font-style: italic;
    font-size: clamp(1.1rem, 1.8vw, 1.4rem);
    line-height: 1.55;
}

/* reveal on scroll */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.in { opacity: 1; transform: none; }


/* buttons */
.btn-row { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 2.2rem; }

.btn {
    display: inline-block;
    padding: 0.9rem 1.5rem;
    border: 1px solid currentColor;
    color: inherit;
    font-size: 0.78rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    text-decoration: none;
    transition: opacity 0.3s ease;
}
/* .btn hover: see the one hover rule at the end of this file */
.btn.solid { background: var(--paper); border-color: var(--paper); color: var(--ink); }
.btn-row.big .btn { padding: 1.3rem 2.4rem; font-size: 0.9rem; }


/* Given / Assumed / Derived squares: outline, filled, hatched */
.sq {
    display: inline-block;
    width: 0.75rem;
    height: 0.75rem;
    vertical-align: -0.05rem;
    margin-right: 0.5rem;
    flex-shrink: 0;
}
.sq.a { border: 1px dashed currentColor; background: transparent; }
.sq.g { border: 1px solid currentColor; background: currentColor; }
.sq.d {
    border: 1px solid currentColor;
    background: repeating-linear-gradient(135deg, currentColor 0 1px, transparent 1px 4px);
}


/* =========================================================
   HERO
   ========================================================= */

.hero {
    display: flex;
    align-items: flex-end;
    padding: 7rem 10vw 10vh 8vw;
    overflow: hidden;
}

.hero-plot {
    position: absolute;
    right: 4vw;
    top: 50%;
    width: min(48vw, 640px);
    transform: translateY(-46%);
    opacity: 0.9;
}

.hero-plot path, .hero-plot circle { fill: none; stroke: var(--paper); stroke-width: 1; }
.p-line  { stroke-dasharray: 1400; stroke-dashoffset: 1400; animation: draw 2.6s ease forwards 0.4s; }
.p-dash  { stroke-dasharray: 6 6; opacity: 0; animation: fade 1s ease forwards 2.2s; }
.p-ghost { stroke-dasharray: 3 7; opacity: 0; animation: ghost 4s ease-in-out infinite 3s; }
.hero-plot .p-peg { fill: var(--paper); opacity: 0; animation: fade 0.6s ease forwards 2.4s; }
.p-q     { fill: var(--paper); font-family: 'Fraunces', serif; font-style: italic; font-size: 48px; opacity: 0; animation: fade 1.2s ease forwards 3.4s; }

@keyframes draw  { to { stroke-dashoffset: 0; } }
@keyframes fade  { to { opacity: 1; } }
@keyframes ghost { 0%, 100% { opacity: 0.15; } 50% { opacity: 0.7; } }

.hero-text { position: relative; z-index: 2; max-width: 720px; }

.hero-text h1 {
    font-family: 'Cinzel', serif;
    font-size: clamp(3rem, 8.5vw, 7.6rem);
    letter-spacing: 0.5rem;
    line-height: 1;
}

.hero-quote {
    margin-top: 2rem;
    font-family: 'Fraunces', serif;
    font-style: italic;
    font-size: clamp(1.1rem, 1.8vw, 1.5rem);
    line-height: 1.45;
}
.hero-quote small {
    display: block;
    margin-top: 0.5rem;
    font-family: 'Work Sans', sans-serif;
    font-style: normal;
    font-size: 0.72rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    opacity: 0.7;
}


/* =========================================================
   01 THE MAP: the overview
   ========================================================= */

.halves { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 1.2rem; align-items: stretch; }

.half {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    min-height: 13rem;
    padding: 1.6rem 1.5rem;
    border: 1px solid var(--ink);
    color: inherit;
    text-decoration: none;
    transition: background 0.25s ease, color 0.25s ease;
}
.half:hover { background: rgba(42, 40, 36, 0.06); }
.half.solve { background: var(--ink); color: var(--paper); }

.half-tag { font-size: 0.7rem; letter-spacing: 0.2rem; text-transform: uppercase; opacity: 0.7; }
.half b { font-family: 'Cinzel', serif; font-size: clamp(1.4rem, 2.6vw, 2.3rem); letter-spacing: 0.06rem; }
.half span:last-child { font-size: 0.95rem; line-height: 1.5; opacity: 0.85; }
.half-arrow { align-self: center; font-style: normal; font-size: 1.5rem; opacity: 0.55; }

.states { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 2fr); gap: 1.2rem; align-items: center; margin-top: 2.2rem; }
.state { display: block; font-size: 0.9rem; }
.state .sq { width: 1rem; height: 1rem; vertical-align: -0.12rem; }
.state b { font-weight: 500; font-size: 1.02rem; }
.state small { display: block; margin-top: 0.3rem; font-size: 0.85rem; line-height: 1.45; opacity: 0.75; }
.state-arrow { font-style: normal; font-size: 1.3rem; opacity: 0.55; }
.state-split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }

.gad-more { overflow: hidden; transition: height 0.55s cubic-bezier(0.6, 0, 0.2, 1); }
.gad-more[hidden] { display: none; }

.life { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-top: 2rem; counter-reset: life; }
.life li {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.3rem 1.2rem;
    border: 1px solid var(--ink);
    counter-increment: life;
}
.life li + li::before {
    content: "\2192";
    position: absolute;
    left: -0.85rem;
    top: 1.4rem;
    font-size: 0.9rem;
    opacity: 0.55;
}
.life-sq .sq { width: 1rem; height: 1rem; margin-right: 0.3rem; }
.life b { font-family: 'Cinzel', serif; font-size: 1.15rem; letter-spacing: 0.05rem; }
.life b::before { content: counter(life) ". "; }
.life span:last-child { font-size: 0.88rem; line-height: 1.5; opacity: 0.85; }
.life-note { max-width: 720px; margin-top: 1.4rem; padding: 1rem 1.2rem; border-left: 2px solid var(--ink); background: rgba(42, 40, 36, 0.05); font-size: 0.9rem; line-height: 1.6; }

.sys main .inline-more { font-family: 'Work Sans', sans-serif; font-style: normal; font-size: 0.8rem; text-decoration: underline; text-underline-offset: 0.2rem; margin-left: 0.4rem; }


/* =========================================================
   02 UNDERSTAND IT: one board, five rows
   ========================================================= */

.board-lead { margin-top: 0; }
.board { margin-top: 2.5rem; border-top: 1px solid var(--line-d); }
.qrow { border-bottom: 1px solid var(--line-d); }

.sys main .row-head {
    display: grid;
    grid-template-columns: auto 6.5rem minmax(0, 1fr) auto;
    align-items: center;
    gap: 1.2rem;
    width: 100%;
    padding: 1.4rem 0.4rem;
    transition: background 0.25s ease;
}
.sys main .row-head:hover { background: rgba(239, 236, 229, 0.05); }
.sys main .row-head:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
.row-sq .sq { width: 1.1rem; height: 1.1rem; margin: 0; }
.row-head b { font-family: 'Cinzel', serif; font-size: clamp(1.3rem, 2.2vw, 1.8rem); letter-spacing: 0.06rem; }
.row-q { display: block; font-family: 'Fraunces', serif; font-style: italic; font-size: clamp(1rem, 1.5vw, 1.2rem); }
.row-a { display: block; margin-top: 0.25rem; font-size: 0.86rem; line-height: 1.45; opacity: 0.72; }
.row-chev { position: relative; width: 1rem; height: 1rem; }
.row-chev::before, .row-chev::after { content: ""; position: absolute; left: 0; top: 50%; width: 100%; height: 1px; background: currentColor; transition: transform 0.3s ease; }
.row-chev::after { transform: rotate(90deg); }
.qrow.open .row-chev::after { transform: rotate(0deg); }

.row-body, .ex-body, .eq-detail, .gad-more, .tracker-panel { overflow: hidden; transition: height 0.45s cubic-bezier(0.6, 0, 0.2, 1), opacity 0.35s ease; }
.row-body { padding: 0 0.4rem 2rem; }
.row-body[hidden], .ex-body[hidden], .eq-detail[hidden] { display: none; }

.key-line { max-width: 780px; margin-bottom: 1.4rem; font-family: 'Fraunces', serif; font-style: italic; font-size: clamp(1.05rem, 1.6vw, 1.3rem); line-height: 1.5; }
.key-line span { display: block; margin-top: 0.4rem; font-family: 'Work Sans', sans-serif; font-style: normal; font-size: 0.92rem; opacity: 0.8; }

.lvls { display: grid; gap: 0.9rem; }
.lvls.wcb-lvls { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.lvl { padding: 1.2rem 1.3rem; border: 1px solid var(--line-d); }
.lvl.small { padding: 0.9rem 1rem; }
.lvl-head { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1rem; }
.lvl-head b { font-weight: 500; font-size: 1rem; }
.lvl-sq { display: inline-flex; align-items: center; gap: 0.45rem; font-size: 0.66rem; letter-spacing: 0.12rem; text-transform: uppercase; opacity: 0.85; }
.lvl-sq .sq { width: 0.95rem; height: 0.95rem; margin: 0; }
.lvl-auto { margin-left: auto; font-size: 0.72rem; opacity: 0.6; }
.lvl-ask { margin-top: 0.5rem; font-size: 0.9rem; line-height: 1.5; opacity: 0.8; }
.lvl-line { margin-top: 0.9rem; padding-left: 0.8rem; border-left: 2px solid var(--line-d); font-size: 0.88rem; line-height: 1.55; opacity: 0.88; }
.now { margin-top: 0.6rem; font-size: 0.95rem; line-height: 1.5; }
.now .sq { width: 0.8rem; height: 0.8rem; }
.src { margin-top: 0.7rem; font-size: 0.72rem; line-height: 1.45; opacity: 0.6; }
.row-body > .src { margin-top: 1.2rem; }
.eg { margin-top: 0.8rem; font-family: 'Fraunces', serif; font-style: italic; font-size: 1.02rem; line-height: 1.5; }

.sys main .confirm {
    margin-left: auto;
    min-width: 10.5rem;          /* Confirm and Confirmed: undo take the same room, so nothing wraps */
    text-align: center;
    padding: 0.45rem 0.9rem;
    border: 1px solid var(--paper);
    font-size: 0.7rem;
    letter-spacing: 0.12rem;
    text-transform: uppercase;
    transition: background 0.25s ease, color 0.25s ease;
}
.sys main .confirm.on { background: var(--paper); color: var(--ink); }
.sys main .confirm:disabled { opacity: 0.35; cursor: default; }

.opts { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.8rem; }
.sys main .opt {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    max-width: 24rem;
    padding: 0.7rem 1rem;
    border: 1px solid var(--line-d);
    transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}
.sys main .opt:hover { border-color: currentColor; background: color-mix(in srgb, currentColor 14%, transparent); }
.sys main .opt.on { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.opt b { font-weight: 500; font-size: 0.92rem; }
.opt small { font-size: 0.75rem; line-height: 1.35; opacity: 0.72; }
.sys main .opt:focus-visible, .sys main .check:focus-visible, .sys main .mini:focus-visible,
.sys main .confirm:focus-visible, .sys main .ex-head:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }

.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0.5rem; margin-top: 0.8rem; }
.sys main .check { display: flex; flex-direction: column; gap: 0.3rem; padding: 0.8rem 0.9rem; border: 1px dashed var(--line-s); }
.check b { font-weight: 500; }
.check small { font-size: 0.76rem; line-height: 1.35; opacity: 0.75; }
.check span { margin-top: auto; font-size: 0.66rem; letter-spacing: 0.12rem; text-transform: uppercase; opacity: 0.7; }
.sys main .check.pass { border-style: solid; border-color: var(--paper); background: var(--paper); color: var(--ink); }
.sys main .check.fail { border-style: solid; border-color: var(--paper); }
.check.fail b { text-decoration: line-through; }

.plain { list-style: none; margin-top: 0.7rem; }
.plain li { padding: 0.4rem 0; border-top: 1px solid var(--line-d); font-size: 0.9rem; line-height: 1.5; }
.plain b { font-weight: 500; margin-right: 0.35rem; }
.plain .sq { width: 0.75rem; height: 0.75rem; }
.loads { list-style: none; margin-top: 0.6rem; }
.loads li { padding: 0.3rem 0; font-size: 0.86rem; border-top: 1px solid var(--line-d); }
.loads b { font-weight: 500; }
.loads small { opacity: 0.6; }

.sub-q { margin-top: 0.9rem; }
.sub-q > span { display: block; font-size: 0.66rem; letter-spacing: 0.15rem; text-transform: uppercase; opacity: 0.65; }

.rank { list-style: none; margin-top: 0.8rem; max-width: 520px; }
.rank li { display: grid; grid-template-columns: 1.8rem minmax(0, 1fr) auto auto auto; align-items: center; gap: 0.6rem; padding: 0.45rem 0; border-top: 1px solid var(--line-d); }
.rank-n { display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border: 1px solid currentColor; border-radius: 50%; font-size: 0.78rem; }
.rank b { font-weight: 500; }
.rank-w { display: inline-flex; align-items: center; font-size: 0.82rem; font-variant-numeric: tabular-nums; }
.rank-w .sq { width: 0.7rem; height: 0.7rem; margin-right: 0.35rem; }
.sys main .mini { padding: 0.3rem 0.65rem; border: 1px solid var(--line-s); font-size: 0.8rem; }
.sys main .mini:disabled { opacity: 0.3; cursor: default; }
.rule { margin-top: 0.9rem; font-size: 0.88rem; line-height: 1.5; }
.rule small { display: block; margin-top: 0.2rem; font-size: 0.72rem; opacity: 0.65; }
.rule .sq { width: 0.75rem; height: 0.75rem; }

.path { list-style: none; margin-top: 0.8rem; counter-reset: step; }
.path li { padding: 0.4rem 0 0.4rem 2rem; border-top: 1px solid var(--line-d); position: relative; counter-increment: step; }
.path li::before { content: counter(step); position: absolute; left: 0; top: 0.45rem; font-size: 0.7rem; opacity: 0.6; }
.path span { display: block; font-size: 0.8rem; opacity: 0.7; }
.path b { font-weight: 500; font-size: 0.9rem; }
.tq p { margin-top: 0.9rem; font-family: 'Fraunces', serif; font-style: italic; font-size: clamp(1.05rem, 1.6vw, 1.25rem); }
.landed { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin: 1rem 0 0.6rem; font-size: 1.05rem; }
.landed b { font-family: 'Cinzel', serif; font-size: 2rem; line-height: 1; }
.landed small { opacity: 0.7; font-size: 0.8rem; }

.try { display: flex; flex-direction: column; gap: 0.3rem; max-width: 16rem; margin-top: 0.9rem; font-size: 0.78rem; }
.try input { font: inherit; font-size: 1rem; color: var(--paper); background: transparent; border: none; border-bottom: 1px solid var(--paper); padding: 0.3rem 0; }
.try input:focus { outline: none; border-bottom-width: 2px; }
.try-out { margin-top: 0.5rem; font-size: 0.88rem; line-height: 1.6; }

.lvl.examples { border-style: dashed; }
.ex + .ex { border-top: 1px solid var(--line-d); }
.sys main .ex-head { display: flex; justify-content: space-between; width: 100%; padding: 0.7rem 0; font-size: 0.95rem; }
.sys main .ex-head::after { content: "+"; opacity: 0.7; }
.sys main .ex-head[aria-expanded="true"]::after { content: "\2212"; }
.ex-body p { padding-bottom: 0.4rem; font-size: 0.9rem; line-height: 1.5; }
.ex-body span { display: inline-block; min-width: 4rem; font-size: 0.66rem; letter-spacing: 0.15rem; text-transform: uppercase; opacity: 0.65; }

/* the Where component sits on its own paper sheet inside the dark chapter */
.sheet { margin-top: 1rem; padding: 1.2rem; background: var(--paper); color: var(--ink); }
.sheet[hidden] { display: none; }
.wcb-title { margin-top: 1rem; font-family: 'Cinzel', serif; font-size: clamp(1.3rem, 2.2vw, 1.8rem); letter-spacing: 0.08rem; }
.sheet .wcb { margin: 0; }


/* =========================================================
   03 PROBLEM STATEMENT
   ========================================================= */

.equation { display: flex; flex-wrap: wrap; align-items: center; gap: 0.8rem 0.9rem; }
.equation i { font-style: normal; font-size: 1.4rem; opacity: 0.5; }

.sys main .eq {
    display: block;
    min-width: 8.5rem;
    padding: 1.3rem 1.2rem;
    border: 1px solid var(--ink);
    color: inherit;
    text-decoration: none;
    transition: background 0.25s ease, color 0.25s ease;
}

.eq span { display: block; font-size: 0.62rem; letter-spacing: 0.13rem; text-transform: uppercase; opacity: 0.65; }
.eq b { display: block; margin-top: 0.4rem; font-family: 'Cinzel', serif; font-size: 1.5rem; letter-spacing: 0.06rem; }
.sys main .eq.still { border-style: dashed; }
.sys main .eq.out { opacity: 0.45; }
.sys main .eq.out.ready { opacity: 1; background: var(--ink); color: var(--paper); }

.sys main .eq[aria-expanded="true"] { background: var(--ink); color: var(--paper); }

.eq-detail { max-width: 780px; margin-top: 1.5rem; padding: 1.3rem 1.4rem; border: 1px solid var(--ink); font-size: 0.95rem; line-height: 1.6; }
.equation .eq-detail { width: 100%; margin-top: 0; }
.eq-now { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-top: 0.7rem; padding-top: 0.6rem; border-top: 1px solid var(--line); }
.eq-now b { font-weight: 500; }
.eq-detail .plain li { border-top-color: var(--line); }
.eq-detail .sq { width: 0.8rem; height: 0.8rem; margin-right: 0.2rem; }
.sys main .eq-detail .mini { margin-left: 0.6rem; padding: 0.25rem 0.6rem; border: 1px solid var(--ink); font-size: 0.75rem; }

.stmt-chips { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 2.5rem; }
.sys main .stmt-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    padding: 0.8rem 1.2rem;
    border: 1px dashed var(--ink);
    border-radius: 999px;
    font-size: 0.95rem;
}
.sys main .stmt-chip.g, .sys main .stmt-chip.d { border-style: solid; }
.stmt-chip small { margin-left: 0.4rem; font-size: 0.68rem; letter-spacing: 0.08rem; text-transform: uppercase; opacity: 0.6; }
.sys main .stmt-chip:focus-visible, .sys main .eq:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }


/* =========================================================
   04 HOW: the main event, drawn in SVG
   Feasibility and Design in a loop, then Document and Respond once,
   then a dashed line back to Why. One stroke weight for everything.
   ========================================================= */

/* title, diagram and text box fit one laptop screen: the wide diagram is
   sized by the screen height (1200 x 520 viewBox), never wider than the column */
#how { scroll-margin-top: 0; --how-w: min(100%, 880px); }
#how .ch-inner { padding-top: 5rem; }
#how h2 { margin-bottom: 1rem; }
.how-wrap { color: var(--paper); }
.how-map { display: block; width: 100%; height: auto; overflow: visible; }
.how-map.wide { width: var(--how-w); margin: 0 auto; }
.how-map.wide .draw, .how-map.wide .ret, .how-map.wide .ret-end { vector-effect: non-scaling-stroke; }
.how-map.tall { display: none; max-width: 420px; margin: 0 auto; }

.how-map .draw, .how-map .ret, .how-map .ret-end { fill: none; stroke: var(--paper); stroke-width: 2; }
.how-map .shape { fill: rgba(239, 236, 229, 0.04); transition: fill 0.25s ease; }
.how-map .ret { stroke-dasharray: 8 7; }
.how-map .ret-mask { stroke: #fff; stroke-width: 6; fill: none; }
.how-map .head { fill: var(--paper); }
.how-map .orbit { fill: none; stroke: none; }
.how-map .dot { fill: var(--paper); }
.how-map .hit-line { fill: none; stroke: transparent; stroke-width: 26; }

.how-map text { fill: var(--paper); pointer-events: none; }
.how-map .name { font-family: 'Cinzel', serif; font-size: 26px; letter-spacing: 1px; }
.how-map .num { font-family: 'Work Sans', sans-serif; font-size: 15px; opacity: 0.7; }
.how-map .lab { font-family: 'Fraunces', serif; font-style: italic; font-size: 20px; }
.how-map .lab.small { font-size: 16px; }
.how-map.tall .name { font-size: 21px; }
/* the wide diagram is drawn smaller than its viewBox: keep labels at 13 px or more on screen */
.how-map.wide .num, .how-map.wide .lab, .how-map.wide .lab.small { font-size: 22px; }
.how-map.wide [data-stage="document"] .name, .how-map.wide [data-stage="respond"] .name { font-size: 23px; letter-spacing: 0; }

/* every shape can be tapped */
.how-map .stage { cursor: pointer; outline: none; }
.how-map .stage:hover .shape, .how-map .stage.on .shape { fill: rgba(239, 236, 229, 0.16); }
.how-map .stage:focus-visible .shape, .how-map .stage:focus-visible .draw { stroke-width: 4; }
.how-map .stage:focus-visible .ret { stroke-width: 4; }
.how-map .stage.on .lab { text-decoration: underline; }

/* drawing on scroll: app sets each line's length, then .drawn lets it run */
.how-map .draw { transition: stroke-dashoffset 1.2s cubic-bezier(0.6, 0, 0.2, 1); }
.how-map .ret-end, .how-map .dot, .how-map .lab { opacity: 0; transition: opacity 0.6s ease; }
.how-map.drawn .ret-end, .how-map.drawn .dot, .how-map.drawn .lab { opacity: 1; transition-delay: 1.6s; }

.how-hint { width: var(--how-w); margin: 0.6rem auto 0; font-size: 0.85rem; opacity: 0.7; }
/* same box for every stage: text on the left, button on the right, fixed min height so it does not jump */
.how-detail {
    display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 0.6rem 1.8rem;
    width: var(--how-w); min-height: 11rem; margin: 0.7rem auto 0; padding: 1.1rem 1.4rem;
    border: 2px solid var(--line-s); overflow: hidden;
    transition: height 0.45s cubic-bezier(0.6, 0, 0.2, 1), opacity 0.35s ease;
}
.how-detail[hidden] { display: none; }
.how-detail .hd-text { align-self: start; }
.how-detail h3 { font-family: 'Cinzel', serif; font-size: clamp(1.2rem, 2vw, 1.5rem); letter-spacing: 0.05rem; }
.how-detail p { margin-top: 0.45rem; font-size: 0.95rem; line-height: 1.55; opacity: 0.9; }
.how-detail .how-status { margin-top: 0.2rem; font-size: 0.7rem; letter-spacing: 0.14rem; text-transform: uppercase; opacity: 0.65; }
.how-detail .how-status.live { opacity: 1; }
.how-detail .how-status.live::before { content: ""; display: inline-block; width: 0.5rem; height: 0.5rem; margin-right: 0.5rem; border-radius: 50%; background: currentColor; vertical-align: 0.05rem; }
.how-detail .hd-act .btn { margin-top: 0; white-space: nowrap; }
.how-detail .btn.off { opacity: 0.4; cursor: default; pointer-events: none; }
.sys main .how-detail .go-why { padding: 0.8rem 1.3rem; border: 1px solid var(--paper); font-size: 0.75rem; letter-spacing: 0.12rem; text-transform: uppercase; white-space: nowrap; }
.how-note { margin-top: 0.8rem; padding: 0.6rem 0.8rem; border: 1px dashed var(--line-s); font-size: 0.88rem; }


/* =========================================================
   05 SOURCES
   ========================================================= */

.sources { list-style: none; max-width: 760px; border-top: 1px solid var(--line); }
.sources li { padding: 1rem 0; border-bottom: 1px solid var(--line); font-size: 1rem; line-height: 1.5; }


/* =========================================================
   TRACKER (bottom left, the whole page)
   ========================================================= */

.tracker { position: fixed; left: 1.4rem; bottom: 1.4rem; z-index: 950; color: var(--ink); }

.sys .tracker button { font: inherit; color: inherit; background: none; border: none; padding: 0; text-align: left; cursor: pointer; }

.sys .tracker .tracker-bar {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 0.55rem 0.8rem;
    background: var(--paper);
    border: 1px solid var(--ink);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}
.sys .tracker .tracker-bar:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

.tracker-sqs { display: flex; gap: 0.45rem; }
.t-sq { display: flex; flex-direction: column; align-items: center; gap: 0.2rem; }
.t-sq .sq { width: 0.85rem; height: 0.85rem; margin: 0; transition: background 0.4s ease; }
.t-sq.here .sq { outline: 2px solid var(--ink); outline-offset: 2px; }
.t-sq small { font-size: 0.55rem; letter-spacing: 0.04rem; opacity: 0.75; }
.tracker-msg { font-size: 0.72rem; letter-spacing: 0.1rem; text-transform: uppercase; white-space: nowrap; }
.tracker.ready .tracker-msg { font-weight: 500; }

.tracker-panel {
    position: absolute;
    left: 0;
    bottom: calc(100% + 0.5rem);
    width: min(440px, calc(100vw - 2.8rem));
    padding: 1rem 1.1rem;
    background: var(--paper);
    border: 1px solid var(--ink);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}
.tracker-panel[hidden] { display: none; }

.tracker-panel table { width: 100%; border-collapse: collapse; font-size: 0.8rem; line-height: 1.4; }
.tracker-panel th, .tracker-panel td { text-align: left; vertical-align: top; padding: 0.45rem 0.6rem 0.45rem 0; border-bottom: 1px solid var(--line); }
.tracker-panel thead th { font-size: 0.58rem; letter-spacing: 0.14rem; text-transform: uppercase; font-weight: 500; opacity: 0.6; }
.tracker-panel tbody th { font-family: 'Cinzel', serif; font-weight: 600; }
.tracker-panel .tg { display: inline-flex; align-items: center; white-space: nowrap; }
.tracker-panel .tg .sq { width: 0.6rem; height: 0.6rem; margin-right: 0.35rem; }
.tracker-panel td small { display: block; margin-top: 0.2rem; font-size: 0.72rem; opacity: 0.7; }


/* =========================================================
   RAIL (chapter numbers, right side)
   ========================================================= */

.rail {
    position: fixed;
    right: 2.2vw;
    top: 50%;
    transform: translateY(-50%);
    z-index: 900;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    color: #fff;
    mix-blend-mode: difference;   /* readable on light and dark chapters */
    opacity: 0;
    pointer-events: none;         /* the rail box never catches a tap, only its numbers do */
    transition: opacity 0.5s ease;
}
.rail.show { opacity: 1; }
.rail.show .rail-item { pointer-events: auto; }

.rail-item {
    display: flex !important;
    align-items: center;
    justify-content: flex-end;
    padding: 0.3rem 0 !important;
    cursor: pointer;
    pointer-events: none;
}

/* chapter name: on hover only, left of the number, solid background.
   It lives outside the rail (the rail blends with the page, this must not). */
.rail-tip {
    position: fixed;
    z-index: 901;
    transform: translate(-100%, -50%);
    padding: 0.3rem 0.6rem;
    background: var(--ink);
    color: var(--paper);
    border: 1px solid var(--paper);
    font-size: 0.68rem;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
    white-space: nowrap;
    pointer-events: none;
}
.rail-tip[hidden] { display: none; }

/* 00 to 05 and the tracker step aside once Sources comes into view */
.rail.away, .tracker.away, .tracker.over-how { opacity: 0 !important; visibility: hidden; pointer-events: none; }
.rail.away .rail-item { pointer-events: none; }
.tracker { transition: opacity 0.4s ease, visibility 0s linear 0s; }
.rail { transition: opacity 0.5s ease, visibility 0s linear 0s; }
.rail.away, .tracker.away, .tracker.over-how { transition: opacity 0.4s ease, visibility 0s linear 0.4s; }

.rail-num {
    font-family: 'Cinzel', serif;
    display: inline-flex;
    align-items: center;
    font-size: 0.78rem;
    letter-spacing: 0.1rem;
    opacity: 0.4;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.rail-num::before {
    content: "";
    display: inline-block;
    width: 0.6rem;
    height: 1px;
    margin-right: 0.5rem;
    background: currentColor;
    transition: width 0.4s ease;
}

.rail-item:hover .rail-num { opacity: 1; transform: scale(1.25); }

.rail-item.active .rail-num { opacity: 1; }
.rail-item.active .rail-num::before { width: 1.6rem; }


/* =========================================================
   FOOTER
   ========================================================= */

.sys .footer-contact { background: var(--ink); color: var(--paper); border-top: 1px solid var(--line-d); }
.sys .footer-nav a,
.sys .email-link { color: var(--paper); }
.sys .footer-contact textarea { border-color: var(--paper); color: var(--paper); }

.sys .footer-contact button {
    background: var(--paper) !important;
    color: var(--ink) !important;
    padding: 0.8rem 1.5rem !important;
    font-weight: 500 !important;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1100px) {
    .lvls.wcb-lvls { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 900px) {
    .ch-inner { padding: 6rem calc(7vw + 2rem) 4rem 7vw; }
    .hero { padding-left: 7vw; padding-right: 7vw; }
    .hero-plot { width: 74vw; right: -8vw; top: 32%; opacity: 0.45; }
    .sys main .row-head { grid-template-columns: auto minmax(0, 1fr) auto; }
    .row-text { grid-column: 2 / 4; grid-row: 2; }
    .rail { right: 0.8rem; gap: 0; }
    .rail-item { padding: 0.15rem 0 !important; }
    .rail-num { font-size: 0.62rem; }
    .rail-num::before { width: 0; margin-right: 0.3rem; }
    .rail-item.active .rail-num::before { width: 0.8rem; }
    .footer-top { flex-direction: column; gap: 3rem; }
    .contact-right { text-align: left; width: 100%; max-width: 100%; }
    .sys .footer-contact form { align-items: flex-start; }
}

@media (max-width: 760px) {
    /* everything goes vertical */
    .how-map.wide { display: none; }
    .how-map.tall { display: block; }
    #how { --how-w: 100%; }
    .how-detail { grid-template-columns: minmax(0, 1fr); align-items: start; }
}

@media (max-width: 600px) {
    .rail { display: none; }

    .header,
    .header.shrink-header { padding-left: 16px; padding-right: 16px; }

    .ch-inner { padding: 5.5rem 16px 3.5rem; }
    .hero { padding: 6rem 16px 3rem; }
    .hero-text h1 { letter-spacing: 0.2rem; }
    .btn-row .btn { flex: 1 1 100%; text-align: center; }
    .sys .footer-contact { padding-left: 16px; padding-right: 16px; }

    .sys main .row-head { gap: 0.4rem 0.8rem; padding: 1.1rem 0; }
    .row-body { padding: 0 0 1.6rem; }
    .lvl { padding: 1rem; }
    .sys main .confirm { margin-left: 0; }
    .lvl-auto { margin-left: 0; width: 100%; }
    .sys main .opt { max-width: 100%; width: 100%; }
    .checks { grid-template-columns: minmax(0, 1fr); }
    .rank li { grid-template-columns: 1.8rem minmax(0, 1fr) auto auto auto; gap: 0.4rem; }
    .sheet { margin-left: -16px; margin-right: -16px; padding: 1rem 16px; }
    .sheet .wcb-bar { margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; }
    .halves, .states, .state-split { grid-template-columns: minmax(0, 1fr); }
    .half { min-height: 0; }
    .half-arrow, .state-arrow { justify-self: center; transform: rotate(90deg); }

    /* Website round 15: a two column grid of small cells (label over value), not a tall stack */
    .equation { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
    .equation i { display: none; }
    .sys main .eq { width: auto; min-width: 0; min-height: 44px; padding: 0.55rem 0.7rem; }
    .eq b { margin-top: 0.15rem; font-size: 1.05rem; }
    .equation .eq-detail { grid-column: 1 / -1; }


    body.sys { padding-bottom: 46px; }
    .tracker { left: 0; right: 0; bottom: 0; }
    .sys .tracker .tracker-bar { width: 100%; justify-content: space-between; padding: 0.4rem 16px; border: none; border-top: 1px solid var(--ink); box-shadow: none; }
    .tracker-sqs { gap: 0.6rem; }
    .t-sq small { font-size: 0.5rem; }
    .tracker-msg { font-size: 0.62rem; letter-spacing: 0.06rem; }
    .tracker-panel { left: 0; right: 0; bottom: 100%; width: 100%; border-left: none; border-right: none; box-shadow: 0 -8px 20px rgba(0, 0, 0, 0.15); }
    .life { grid-template-columns: minmax(0, 1fr); }
    .life li + li::before { left: 1.2rem; top: -0.95rem; transform: rotate(90deg); }
}

@media (max-width: 900px) and (min-width: 601px) {
    .life { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none; transition: none; }
    .how-map .draw, .how-map .ret-end, .how-map .dot, .how-map .lab { transition: none; opacity: 1; }
    .how-map .dot { display: none; }
    .gad-more, .t-sq .sq, .row-body, .ex-body, .eq-detail, .tracker-panel, .row-chev::after { transition: none; }
    .tracker-panel { animation: none; }
    .rail, .tracker, .rail.away, .tracker.away { transition: none; }
}


/* ---------- Understand it: order, goal number, start over ---------- */
.order-note { display: inline-block; margin-bottom: 1rem; padding: 0.35rem 0.7rem; border: 1px dashed var(--line-s); font-size: 0.8rem; }
.order-note[hidden] { display: none; }
.ooo-tag { display: inline-block; margin-top: 0.5rem; padding: 0.1rem 0.45rem; border: 1px dashed currentColor; font-size: 0.62rem; letter-spacing: 0.1rem; text-transform: uppercase; opacity: 0.8; }
.ooo-tag[hidden] { display: none; }
.t-sq.ooo small::after { content: " *"; }
.tracker-panel .ooo-line { display: block; margin-top: 0.2rem; font-style: italic; }
.goal-in { display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; }
.board-foot { margin-top: 1.4rem; text-align: right; }
.sys main .start-over { padding: 0.55rem 1rem; border: 1px solid var(--line-s); font-size: 0.72rem; letter-spacing: 0.12rem; text-transform: uppercase; }
.sys main .start-over.sure { background: var(--paper); color: var(--ink); }
.sys main .start-over:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
.btn[hidden] { display: none; }


/* ---------- Understand it: search on top, Change per level, a tracker you just read ---------- */
.board-search { margin-top: 0.5rem; }
.board-lead { margin-top: 1.4rem; }
.row-ex { display: inline-block; margin-right: 0.3rem; padding: 0 0.4rem; border: 1px dashed currentColor; font-size: 0.66rem; letter-spacing: 0.1rem; text-transform: uppercase; }
.sys main .change { margin-left: auto; padding: 0; border: none; font-size: 0.8rem; text-decoration: underline; text-underline-offset: 0.2rem; }
.sys main .change:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
.lvl-edit { overflow: hidden; transition: height 0.45s cubic-bezier(0.6, 0, 0.2, 1), opacity 0.35s ease; }
.lvl-edit[hidden] { display: none; }
.sys .tracker .tracker-bar { display: flex; align-items: center; gap: 0.9rem; padding: 0.55rem 0.8rem; background: var(--paper); border: 1px solid var(--ink); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18); }
@media (max-width: 600px) {
    .sys .tracker .tracker-bar { width: 100%; justify-content: space-between; padding: 0.4rem 16px; border: none; border-top: 1px solid var(--ink); box-shadow: none; }
}

/* the project sheet */
.sq.n { border: 1px dotted currentColor; background: transparent; position: relative; }
.sq.n::after { content: ""; position: absolute; left: 20%; right: 20%; top: 50%; height: 1px; background: currentColor; }
.sheet-sentence { max-width: 900px; margin-top: 1.4rem; font-family: 'Fraunces', serif; font-size: clamp(1.5rem, 3vw, 2.3rem); line-height: 1.25; min-height: 1.2em; }
.sheet-sentence:empty { display: none; }
.sheet-bar { display: flex; gap: 2px; margin: 1rem 0 1.4rem; max-width: 900px; }
.sheet-bar .sb { display: flex; align-items: center; gap: 0.3rem; min-width: 3.2rem; padding: 0.35rem 0.5rem; border-top: 3px solid currentColor; font-size: 0.72rem; white-space: nowrap; overflow: hidden; }
.sheet-bar .sb.a { border-top-style: dashed; }
.sheet-bar .sb.n { border-top-style: dotted; }
.sheet-bar .sb.d { border-top-style: double; }
.sheet-bar .sb .sq { margin: 0; width: 0.6rem; height: 0.6rem; }
.row-chips { display: flex; flex-wrap: wrap; gap: 0.35rem 0.9rem; margin-top: 0.5rem; }
.fact { display: inline-flex; align-items: center; gap: 0.2rem; font-size: 0.78rem; line-height: 1.3; opacity: 0.85; }
.fact .sq { width: 0.6rem; height: 0.6rem; margin-right: 0.15rem; }
.fact small { opacity: 0.65; margin-right: 0.2rem; }
.lvls { display: block; }
.blk { margin-bottom: 1.1rem; }
.blk h4 { font-size: 0.68rem; letter-spacing: 0.18rem; text-transform: uppercase; font-weight: 400; opacity: 0.7; margin-bottom: 0.35rem; }
.blk li small { display: block; margin: 0.1rem 0 0 1.25rem; opacity: 0.65; font-size: 0.78rem; line-height: 1.4; }
.d2 { margin: 0.6rem 0 0.4rem; padding: 0.8rem 1rem; border: 1px solid var(--line-d); }
.d2[hidden] { display: none; }
.d2-toggle, .edit-line .mini { margin-right: 0.6rem; }
.edit-line { margin-top: 1rem; }
.d2 .mix-wrap { display: flex; gap: 1rem; }
.d2 .mix-bar { display: flex; flex-direction: column-reverse; width: 4rem; min-height: 8rem; flex: none; border: 1px solid currentColor; }
.d2 .mix-bar i { display: flex; align-items: center; justify-content: center; font-style: normal; font-size: 0.6rem; border-top: 1px solid currentColor; overflow: hidden; text-align: center; }
@media (max-width: 600px) { .sheet-bar { flex-wrap: wrap; } .sheet-bar .sb { flex: 1 1 40% !important; } }


/* =========================================================
   MEANING COLOURS (UI round 7). The shape says it first (solid, dashed,
   hatched, dotted); the colour is added on top, never instead of it.
   Given = slate, Assumed = clay, Derived = sage, Not given = charcoal 45%.
   ========================================================= */
.sq.g { color: var(--slate-ink); }
.sq.a { color: var(--clay-ink); }
.sq.d { color: var(--sage-ink); }
.sq.n { color: var(--none); }
.dark .sq.g { color: var(--slate-lt); }
.dark .sq.a { color: var(--clay-lt); }
.dark .sq.d { color: var(--sage-lt); }
.dark .sq.n { color: rgba(239, 236, 229, 0.5); }

/* the sheet bar: row 1 the bar, sized by count (a 0 is not drawn); row 2 the four labels. Nothing is cut. */
.sbar { max-width: 900px; margin: 0.6rem 0 1rem; }
.sbar:empty { display: none; }
.sbar-track { display: flex; gap: 2px; height: 10px; }
.sbar-track i { display: block; min-width: 6px; }
.sbar-track .g { background: var(--slate); }
.sbar-track .a { background: repeating-linear-gradient(90deg, var(--clay) 0 7px, transparent 7px 10px); box-shadow: inset 0 0 0 1px var(--clay); }
.sbar-track .n { background: radial-gradient(circle, var(--none) 1.2px, transparent 1.6px) 0 0 / 5px 5px; box-shadow: inset 0 0 0 1px var(--none); }
.sbar-track .d { background: repeating-linear-gradient(135deg, var(--sage) 0 2px, transparent 2px 5px); box-shadow: inset 0 0 0 1px var(--sage); }
.sbar-key { display: flex; flex-wrap: wrap; gap: 0.4rem 1.25rem; margin-top: 0.5rem; font-size: 0.78rem; }
.sbar-key span { display: inline-flex; align-items: center; white-space: nowrap; }
.sbar-key .sq { width: 0.7rem; height: 0.7rem; margin-right: 0.4rem; }
.sbar-key b { font-weight: 500; margin-right: 0.25rem; }


/* =========================================================
   UI ROUND 7
   ========================================================= */

/* tracker: hidden on the cover and on Sources; tucks below the screen edge while text is under it */
.tracker { transition: transform 0.2s ease, opacity 0.4s ease, visibility 0s linear 0s; }
.tracker.tuck { transform: translateY(calc(100% + 1rem)); }
.tracker.on-cover { opacity: 0 !important; visibility: hidden; pointer-events: none; transition: opacity 0.3s ease, visibility 0s linear 0.3s; }
.t-sq .sq.g { color: var(--slate-ink); }
.t-sq .sq.a { color: var(--clay-ink); }
.t-sq .sq.d { color: var(--sage-ink); }
.t-sq .sq.n { color: var(--none); }
@media (prefers-reduced-motion: reduce) { .tracker, .tracker.tuck { transition: none; } }

/* 02 Understand it: an explainer. 3 columns, the wide card takes the full last row. */
.ex-lead { margin-top: 0; margin-bottom: 2rem; }
/* six columns: three cards on the first row, two wider ones on the second, How the check works across the last. No empty cell. */
.ex-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: auto; gap: 1.25rem; align-items: stretch; }
.ex-card { grid-column: span 2; }
.ex-card[data-k="who"], .ex-card[data-k="when"] { grid-column: span 3; }
.ex-card { display: flex; flex-direction: column; gap: 0.8rem; padding: 1.3rem 1.4rem 1.1rem; border: 1px solid var(--line-d); border-top: 3px solid var(--sage-lt); border-radius: 10px; background: rgba(239, 236, 229, 0.03); }
.ex-card[data-k="what"], .ex-card[data-k="who"] { border-top-color: var(--slate-lt); }
.ex-card[data-k="where"] { border-top-color: var(--clay-lt); }
.ex-card[data-k="how"] { border-top-color: var(--paper); }
.ex-card.wide { grid-column: 1 / -1; }
.ex-card h3 { font-family: 'Cinzel', serif; font-size: clamp(1.3rem, 2vw, 1.7rem); letter-spacing: 0.08rem; font-weight: 600; }
.ex-short { font-size: 1rem; line-height: 1.55; opacity: 0.92; }
.ex-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.ex-chip { display: inline-flex; align-items: center; padding: 0.25rem 0.7rem; border: 1px solid var(--line-s); border-radius: 999px; font-size: 0.78rem; }
.ex-chip .sq { width: 0.65rem; height: 0.65rem; margin-right: 0.4rem; }
.ex-more { overflow: hidden; transition: height 0.4s cubic-bezier(0.6, 0, 0.2, 1), opacity 0.3s ease; }
.ex-more[hidden] { display: none; }
.ex-more > * + * { margin-top: 0.7rem; }
.ex-more p { font-size: 0.92rem; line-height: 1.6; opacity: 0.9; }
.ex-more .src { font-size: 0.75rem; opacity: 0.6; }
.ex-list, .ex-groups { list-style: none; display: flex; flex-direction: column; gap: 0.3rem; font-size: 0.88rem; }
.ex-list li::before { content: ""; display: inline-block; width: 0.5rem; height: 1px; margin-right: 0.5rem; vertical-align: 0.25rem; background: currentColor; opacity: 0.6; }
.ex-groups { flex-direction: row; flex-wrap: wrap; gap: 0.35rem; }
.ex-groups li { padding: 0.2rem 0.6rem; border: 1px solid var(--line-s); border-radius: 6px; font-size: 0.8rem; }
.ex-out { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.3rem 1rem; }
/* the four layers, top to bottom: four thin bars */
.ex-layers { list-style: none; display: flex; flex-direction: column; gap: 0.45rem; }
.ex-layers li { display: grid; grid-template-columns: 3.2rem minmax(0, 1fr); align-items: center; gap: 0.7rem; font-size: 0.86rem; line-height: 1.35; }
.ex-layers i { display: block; height: 6px; border-radius: 3px; background: var(--clay-lt); width: calc(100% - var(--i) * 18%); opacity: calc(1 - var(--i) * 0.18); }
.ex-layers li:last-child i { background: repeating-linear-gradient(90deg, var(--clay-lt) 0 6px, transparent 6px 9px); opacity: 1; }
.ex-states { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem 1.4rem; font-size: 0.9rem; line-height: 1.45; }
.ex-states .sq { width: 0.85rem; height: 0.85rem; }
.ex-states span { opacity: 0.85; }
.sys main .ex-toggle { align-self: flex-start; margin-top: auto; min-height: 36px; font-size: 0.82rem; text-decoration: underline; text-underline-offset: 0.2rem; }
.sys main .ex-toggle:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
#seek .btn-row { margin-top: 2.4rem; }

/* 03 Your building: on Ivory, the chat centred, then the sheet */
#build { border-top: 1px solid var(--line); }
#build .ch-inner h2 { max-width: 760px; margin-left: auto; margin-right: auto; }
#build .board-search { margin-top: 0; }
.sheet-wrap { max-width: 1180px; margin: 4rem auto 0; padding-top: 2.4rem; border-top: 1px solid var(--line); }
.sheet-wrap .sheet-sentence { margin-top: 0; }
.sheet-wrap .sheet-sentence:empty { display: none; }
#build .board { color: var(--ink); }
#build .board.is-empty .row-chips, #build .board.is-empty .row-chev { display: none; }
#build .board-foot .start-over { border-color: var(--line); }
.sys main #build .start-over.sure { background: var(--ink); color: var(--paper); }
.sys main #build .start-over:focus-visible { outline-color: var(--ink); }
#statement { border-top: 1px solid var(--line); }

/* Sources: two columns on a wide screen */
@media (min-width: 1000px) {
    .sources { columns: 2; column-gap: 3rem; max-width: 1100px; border-top: none; }
    .sources li { break-inside: avoid; border-top: 1px solid var(--line); border-bottom: none; }
}

@media (max-width: 1100px) and (min-width: 701px) {
    .ex-out { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
    .ex-card, .ex-card[data-k="who"] { grid-column: span 3; }
    .ex-card[data-k="when"] { grid-column: 1 / -1; }
}
@media (max-width: 700px) {
    .ex-grid { grid-template-columns: minmax(0, 1fr); }
    .ex-card, .ex-card[data-k="who"], .ex-card[data-k="when"] { grid-column: 1 / -1; }
    .ex-out, .ex-states { grid-template-columns: minmax(0, 1fr); }
}

/* the board was drawn for a dark chapter: on Ivory its lines and hovers use the ink */
#build { --line-d: rgba(42, 40, 36, 0.18); --line-s: rgba(42, 40, 36, 0.5); }
.sys main #build .row-head:hover { background: rgba(42, 40, 36, 0.04); }
.sys main #build .row-head:focus-visible, .sys main #build .mini:focus-visible { outline-color: var(--ink); }
.sys main #build .opt.on, .sys main #build .check.pass { background: var(--ink); color: var(--paper); border-color: var(--ink); }
#build .sheet { background: #f6f4ee; border: 1px solid var(--line); }
#build .board .fact { opacity: 1; }


/* =========================================================
   HOW: ONE FLOW AND ONE BUTTON (Website round 15)
   The loop drawing is a picture only. Under it six steps (Data/how_stages.json "flow"): a table at desktop width, a thin
   line on the left joins the rows of one loop stage; on a phone the same rows stack as cards. State on a square, text never coloured.
   ========================================================= */
.how-map .stage { cursor: default; }
.how-map .stage:hover .shape { fill: none; }
.how-flow { width: var(--how-w); margin: 1.6rem auto 0; color: var(--paper); font-size: 0.92rem; line-height: 1.45; }
.hf-row { display: grid; grid-template-columns: 2.2rem minmax(8rem, 1.1fr) minmax(0, 1.5fr) minmax(0, 1.3fr) minmax(0, 1.3fr) 9rem; gap: 0 1rem; padding: 0.7rem 0; border-top: 1px solid var(--line-d); align-items: baseline; }
.hf-head { grid-template-columns: 2.2rem minmax(8rem, 1.1fr) minmax(0, 1.5fr) minmax(0, 1.3fr) minmax(0, 1.3fr) 9rem; border-top: none; padding: 0 0 0.4rem; font-size: 0.68rem; letter-spacing: 0.14rem; text-transform: uppercase; opacity: 0.65; }
.hf-head .hf-stage { display: none; }
.hf-group { position: relative; padding-left: 1.2rem; margin-top: 0.4rem; }
.hf-group::before { content: ""; position: absolute; left: 0.2rem; top: 0.4rem; bottom: 0.4rem; width: 1px; background: var(--line-s); }
.hf-feasibility::before { background: var(--sage-lt); }
.hf-design::before { background: var(--slate-lt); }
.hf-document::before { background: var(--clay-lt); }
.hf-stage-name { margin: 0; padding-top: 0.5rem; font-size: 0.68rem; letter-spacing: 0.14rem; text-transform: uppercase; opacity: 0.7; }
.hf-head { padding-left: 1.2rem; }
.hf-n { font-family: 'Cinzel', serif; font-size: 1.05rem; }
.hf-name { font-weight: 500; }
.hf-cell { opacity: 0.88; }
.hf-state { font-size: 0.8rem; white-space: normal; }
.hf-state::before { content: ""; display: inline-block; width: 0.6rem; height: 0.6rem; margin-right: 0.45rem; vertical-align: 0; border: 1px solid var(--paper); }
.hf-state.ok::before { background: var(--sage); border-color: var(--sage); }
.hf-state.beta::before { background: var(--slate); border-color: var(--slate); }
.hf-state.part::before { border-style: dashed; border-color: var(--clay-lt); }
.hf-state.plan::before { border-style: dotted; }
.how-go { width: var(--how-w); margin: 1.8rem auto 0; display: flex; flex-wrap: wrap; align-items: center; gap: 0.8rem 1.4rem; }
.how-go .btn { margin: 0; min-height: 44px; display: inline-flex; align-items: center; }
.how-go p { margin: 0; font-size: 0.92rem; opacity: 0.85; }
@media (max-width: 760px) {
    .hf-head { display: none; }
    .hf-row { grid-template-columns: 2rem minmax(0, 1fr); gap: 0.2rem 0.6rem; padding: 0.8rem 0; }
    .hf-row > .hf-cell, .hf-row > .hf-state { grid-column: 2; }
    .hf-cell::before { content: attr(data-k) ": "; font-size: 0.68rem; letter-spacing: 0.1rem; text-transform: uppercase; opacity: 0.7; }
}

/* =========================================================
   06 WHAT IS BUILT, 07 DATA AND LICENCES, 08 WHO MADE THIS (Website round 15)
   ========================================================= */
.built-nums { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.built-nums .bn { padding: 1.2rem 1rem 1.2rem 0; border-right: 1px solid var(--line); }
.built-nums .bn:last-child { border-right: none; }
.built-nums b { display: block; font-family: 'Cinzel', serif; font-size: clamp(1.8rem, 4vw, 2.8rem); letter-spacing: 0.04rem; }
.built-nums span { display: block; margin-top: 0.3rem; font-size: 0.9rem; line-height: 1.4; opacity: 0.85; }
.built-pics { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0.6rem; margin-top: 1.4rem; }
.built-pics[hidden] { display: none; }
.built-pics img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.credits { list-style: none; margin: 1.2rem 0 0; padding: 0; max-width: 1100px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 3rem; }
.credits li { display: grid; gap: 0.15rem; padding: 0.9rem 0; border-top: 1px solid var(--line-d); font-size: 0.95rem; line-height: 1.45; }
.credits li b { font-weight: 500; }
.credits li span { opacity: 0.8; }
.sources-head { margin-top: 2.4rem; font-family: 'Cinzel', serif; font-size: 1.2rem; letter-spacing: 0.05rem; }
.chapter.dark .sources, .chapter.dark .sources li { border-color: var(--line-d); }
.who-lines { list-style: none; margin: 0; padding: 0; max-width: 820px; }
.who-lines li { padding: 0.8rem 0; border-top: 1px solid var(--line); font-size: 1.02rem; line-height: 1.55; }
.who-links { margin-top: 1.4rem; }
.who-links .btn { min-height: 44px; display: inline-flex; align-items: center; }
@media (max-width: 760px) {
    .built-nums { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .built-nums .bn { padding: 0.9rem 0.6rem 0.9rem 0; border-right: none; border-bottom: 1px solid var(--line); }
    .built-nums .bn:nth-child(odd) { border-right: 1px solid var(--line); }
    .built-nums .bn:nth-child(even) { padding-left: 0.8rem; }
    .built-nums .bn:nth-last-child(-n+2) { border-bottom: none; }
    .credits { grid-template-columns: minmax(0, 1fr); }
}
/* tap targets 44 px (Website round 15) */
.sys main .inline-more, .sys main .ex-toggle, .sys main .mini, .sys main .start-over { min-height: 44px; }

/* =========================================================
   ONE HOVER EVERYWHERE (UI round 9): it lifts with a shadow, it never fades
   or flips its colours. Picked = ink fill with Ivory text (Ivory fill with ink
   text on Charcoal). Disabled = dashed border, 45% text, no hover.
   ========================================================= */
.sys main button:not(:disabled), .sys main .btn, .sys main a.btn-main, .sys main .cv-go, .sys main .half, .sys main .stmt-chip, .sys main .door, .sys main .pc-w, .sys main .cv-chip, .sys main .bs-chip, .sys main .bs-use {
    transition: transform 150ms ease, box-shadow 150ms ease;
}
.sys main button:not(:disabled):hover, .sys main .btn:hover, .sys main a.btn-main:hover, .sys main .cv-go:hover, .sys main .half:hover, .sys main .stmt-chip:hover, .sys main .door:hover, .sys main .bs-chip:hover, .sys main .bs-use:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(42, 40, 36, 0.18);
    opacity: 1;
}
.sys .dark button:not(:disabled):hover, .sys .dark .btn:hover, .sys .dark .bs-chip:hover { box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45); }
.sys .dark button:not(:disabled):not(.solid):not(.on):not(.is):hover, .sys .dark .btn:not(.solid):hover, .sys .dark .bs-chip:hover { background-color: rgba(239, 236, 229, 0.08); }
.sys .dark button:disabled { color: rgba(239, 236, 229, 0.45) !important; }
.sys .dark :focus-visible { outline-color: var(--slate-lt); }
.sys main button:disabled { border-style: dashed !important; color: rgba(42, 40, 36, 0.45) !important; opacity: 1 !important; box-shadow: none !important; transform: none !important; cursor: default; }
.sys main :focus-visible { outline: 2px solid var(--slate); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
    .sys main button:not(:disabled):hover, .sys main .btn:hover, .sys main a.btn-main:hover, .sys main .cv-go:hover, .sys main .half:hover, .sys main .stmt-chip:hover, .sys main .door:hover, .sys main .bs-chip:hover, .sys main .bs-use:hover { transform: none; }
}


/* =========================================================
   UI ROUND 9: the summary band (Charcoal, full width, in tabs)
   ========================================================= */
.summary-band { background: var(--ink); color: var(--paper); scroll-margin-top: 60px; }
.sb-inner { padding: 4rem max(10vw, calc(2.2vw + 6.5rem)) 3.4rem 8vw; }
.summary-band .sheet-sentence { margin: 0 0 0.6rem; max-width: 900px; }
.summary-band .sbar-track .g { background: var(--slate-lt); }
.summary-band .sbar-track .a { background: repeating-linear-gradient(90deg, var(--clay-lt) 0 7px, transparent 7px 10px); box-shadow: inset 0 0 0 1px var(--clay-lt); }
.summary-band .sbar-track .n { background: radial-gradient(circle, rgba(239, 236, 229, 0.5) 1.2px, transparent 1.6px) 0 0 / 5px 5px; box-shadow: inset 0 0 0 1px rgba(239, 236, 229, 0.5); }
.summary-band .sbar-track .d { background: repeating-linear-gradient(135deg, var(--sage-lt) 0 2px, transparent 2px 5px); box-shadow: inset 0 0 0 1px var(--sage-lt); }
#summary .board { color: var(--paper); margin-top: 1.6rem; border-top: none; --line-d: rgba(239, 236, 229, 0.2); --line-s: rgba(239, 236, 229, 0.55); }
.tabs { display: flex; flex-wrap: wrap; gap: 0.2rem 1.6rem; border-bottom: 1px solid rgba(239, 236, 229, 0.2); }
.sys main .tab { display: inline-flex; align-items: center; gap: 0.5rem; min-height: 44px; padding: 0.4rem 0.1rem; font-family: "Cinzel", serif; font-size: 1.05rem; letter-spacing: 0.05rem; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.sys main .tab .sq { width: 0.8rem; height: 0.8rem; margin: 0; }
.sys main .tab[aria-selected="true"][data-tab="why"], .sys main .tab[aria-selected="true"][data-tab="when"] { border-bottom-color: var(--sage-lt); }
.sys main .tab[aria-selected="true"][data-tab="what"], .sys main .tab[aria-selected="true"][data-tab="who"] { border-bottom-color: var(--slate-lt); }
.sys main .tab[aria-selected="true"][data-tab="where"] { border-bottom-color: var(--clay-lt); }
.sys main .tab:hover { transform: none; box-shadow: none; background: rgba(239, 236, 229, 0.06); }
#summary .qrow.tabpanel { border: none; padding: 1.2rem 0 0.4rem; min-height: 220px; }
#summary .qrow.tabpanel[hidden] { display: none; }
.tp-q { font-family: "Fraunces", serif; font-style: italic; font-size: 1.15rem; margin-bottom: 0.8rem; }
.tp-pairs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.35rem 2rem; max-width: 900px; font-size: 0.9rem; }
.tp-pairs div { display: flex; gap: 0.6rem; align-items: baseline; padding: 0.25rem 0; border-bottom: 1px solid rgba(239, 236, 229, 0.12); min-width: 0; }
.tp-pairs dt { display: inline-flex; align-items: center; flex: none; opacity: 0.75; }
.tp-pairs dt .sq { width: 0.6rem; height: 0.6rem; margin-right: 0.4rem; }
.tp-pairs dd { min-width: 0; overflow-wrap: anywhere; }
.tp-why { margin-top: 0.8rem; max-width: 760px; font-size: 0.88rem; line-height: 1.5; opacity: 0.85; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tp-links { display: flex; gap: 0.6rem; margin-top: 0.7rem; }
#summary .row-body { padding: 0.8rem 0 0; }
#summary .board-foot { margin-top: 1rem; }
#summary .start-over { border-color: rgba(239, 236, 229, 0.55); }
#build { padding-bottom: 0; }
#build > .ch-inner { padding-bottom: 3.5rem; }

/* the problem statement tiles: a 3 px top border in their colour */
.sys main .eq[data-detail="goal"] { border-top: 3px solid var(--sage); }
.sys main .eq[data-detail="limits"] { border-top: 3px solid var(--slate); }
.sys main .eq[data-detail="scores"] { border-top: 3px solid var(--clay); }
.sys main .eq[data-detail="time"] { border-top: 3px solid var(--slate); }
.sys main .eq[data-detail="still"] { border-top: 3px solid var(--clay); }
.sys main .eq.out.ready { background: var(--pop-ink); border-color: var(--pop-ink); color: var(--paper); }

/* How: coloured on Charcoal */
.how-map [data-stage="feasibility"] .shape { stroke: var(--sage-lt); fill: rgba(135, 148, 135, 0.18); }
.how-map [data-stage="design"] .shape { stroke: var(--slate-lt); fill: rgba(120, 139, 154, 0.18); }
.how-map [data-stage="document"] .shape, .how-map [data-stage="respond"] .shape { stroke: var(--clay-lt); }
.how-map .ret, .how-map .ret-end { stroke: var(--clay-lt); }
.how-map .dot { fill: var(--pop); }
.how-map .sub { font-family: "Work Sans", sans-serif; font-size: 18px; fill: var(--sage-lt); }
.how-map.tall .sub { font-size: 12px; }
.how-map .stage:hover .shape, .how-map .stage.on .shape { fill-opacity: 1; }
.how-detail .hd-act { display: flex; flex-direction: column; align-items: flex-end; gap: 0.5rem; }
.sys main .how-detail .btn.main-act { background: var(--paper); border-color: var(--paper); color: var(--ink); }
.sys main .how-detail .btn.main-act:hover { background: var(--pop-ink); border-color: var(--pop-ink); color: var(--paper); }
.how-detail .btn.is-off { border-style: dashed; color: rgba(239, 236, 229, 0.45); pointer-events: none; }
.how-detail .needs { font-size: 0.78rem; opacity: 0.75; margin: 0; }

@media (max-width: 900px) { .sb-inner { padding: 3rem calc(7vw + 2rem) 3rem 7vw; } }
@media (max-width: 600px) { .sb-inner { padding: 2.6rem 16px; } .tp-pairs { grid-template-columns: minmax(0, 1fr); } }

#summary .start-over.sure { background: var(--paper); color: var(--ink); }

/* round 10: comes later, shown muted and never counted */
.sq.c { border: 1px dashed currentColor; background: transparent; opacity: 0.45; }
.tp-pairs .is-later, .plain li.is-later { opacity: 0.55; }
.tp-pairs dd b { font-weight: 500; margin-left: 0.3rem; }
.tp-pairs dd a { color: inherit; font-size: 0.8rem; }



/* =========================================================
   UI ROUND 11
   ========================================================= */

/* back from the app with the wave (wave.js): the page starts under Ivory, the cover pulls away */
html.wave-in::after { content: ""; position: fixed; inset: 0; z-index: 6000; background: #EFECE5; }

/* How: the diagram is the hero, the full content width (max 1200 px), centred, no side cards (round 12) */
#how { --how-w: min(100%, 1200px); }
.how-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* the circles: a faint inner gradient of their colour and a 1 px glow ring */
.how-map [data-stage="feasibility"] .shape { fill: url(#hg-sage); stroke-width: 1px; filter: drop-shadow(0 0 6px rgba(169, 181, 168, 0.45)); }
.how-map [data-stage="design"] .shape { fill: url(#hg-slate); stroke-width: 1px; filter: drop-shadow(0 0 6px rgba(157, 174, 187, 0.45)); }
.how-map [data-stage="document"] .shape, .how-map [data-stage="respond"] .shape { fill: url(#hg-clay); stroke-width: 1px; filter: drop-shadow(0 0 6px rgba(212, 154, 133, 0.35)); }
.how-map .trail { fill: var(--pop); pointer-events: none; }

/* the three Feasibility steps: glowing pills, each a link */
.how-map .spill { cursor: pointer; }
.how-map .spill rect { stroke-width: 1px; transition: transform 150ms ease, filter 150ms ease; }
.how-map .spill text { fill: var(--paper); font-family: 'Work Sans', sans-serif; font-size: 16px; pointer-events: none; }
.how-map.tall .spill text { font-size: 10.5px; }
.how-map .spill.sage rect { fill: rgba(135, 148, 135, 0.18); stroke: var(--sage-lt); filter: drop-shadow(0 0 8px rgba(135, 148, 135, 0.35)); }
.how-map .spill.slate rect { fill: rgba(120, 139, 154, 0.18); stroke: var(--slate-lt); filter: drop-shadow(0 0 8px rgba(120, 139, 154, 0.35)); }
.how-map .spill.clay rect { fill: rgba(185, 120, 99, 0.18); stroke: var(--clay-lt); filter: drop-shadow(0 0 8px rgba(185, 120, 99, 0.35)); }
.how-map .spill:hover rect, .how-map .spill:focus-visible rect { transform: translateY(-1px); transform-box: fill-box; }
.how-map .spill:focus-visible { outline: none; }
.how-map .spill:focus-visible rect { stroke: var(--slate); stroke-width: 2px; }
.how-map .spill.next rect { animation: spill-glow 2.4s ease-in-out infinite; }
@keyframes spill-glow { 0%, 100% { filter: drop-shadow(0 0 6px rgba(239, 236, 229, 0.15)); } 50% { filter: drop-shadow(0 0 14px rgba(239, 236, 229, 0.55)); } }
/* Design, Document, Respond: the same pill, dimmed, with "coming" */
.how-map .npill { stroke-width: 1px; opacity: 0.4; }
.how-map .npill.slate { fill: rgba(120, 139, 154, 0.18); stroke: var(--slate-lt); }
.how-map .npill.clay { fill: rgba(185, 120, 99, 0.18); stroke: var(--clay-lt); }
.how-map .coming { font-family: 'Work Sans', sans-serif; font-size: 13px; letter-spacing: 1px; opacity: 0.6; }
.how-map.tall .coming { font-size: 10px; }
@media (prefers-reduced-motion: reduce) {
    .how-map .spill.next rect { animation: none; }
    .how-map .trail { display: none; }
    .how-map .spill:hover rect { transform: none; }
}


/* round 11: a disabled How button looks like every other disabled button (dashed, 45%), not faded */
.how-detail .btn.off { opacity: 1; border-style: dashed; color: rgba(239, 236, 229, 0.45); }

/* round 12: readable at 1366 px (the diagram is about 1120 px there, 0.93 of the 1200 viewBox):
   names 21 to 24 px, numbers 20 px, step pills 16 px, "coming" 13 px, the italic notes 20 px on screen */
.how-map.wide .spill text { font-size: 17px; }
.how-map.wide .coming { font-size: 14px; }
.how-map.wide .name { font-size: 26px; }
.how-map.wide [data-stage="document"] .name, .how-map.wide [data-stage="respond"] .name { font-size: 23px; }

/* round 12: the tracker is a small Ivory card (on dark sections too), same place and hide rules as before.
   Top: the five squares and the status; under it Given, Assumed, Not given, Derived as counters. Width fits the content. */
.sys .tracker .tracker-bar { display: flex; flex-direction: column; align-items: stretch; gap: 0.6rem; width: max-content; max-width: calc(100vw - 2.8rem); padding: 12px 16px; background: var(--paper); color: var(--ink); border: none; border-radius: 12px; box-shadow: 0 1px 2px rgba(42, 40, 36, 0.08), 0 8px 24px rgba(42, 40, 36, 0.18); }
.tracker-top { display: flex; align-items: center; gap: 0.9rem; }
.sys .tracker .tracker-msg { font-size: 0.85rem; font-weight: 500; letter-spacing: 0; text-transform: none; white-space: nowrap; }
.tracker.ready .tracker-msg { color: var(--sage-ink); }
.tracker.todo .tracker-msg { color: var(--clay-ink); }
.tracker-counts { display: grid; grid-template-columns: repeat(4, auto); gap: 0 1.1rem; margin: 0; }
.tracker-counts[hidden] { display: none; }
.tracker-counts .tc { display: flex; flex-direction: column; min-width: 0; }
.tracker-counts dd { display: flex; align-items: center; gap: 0.35rem; margin: 0; }
.tracker-counts dd .sq { width: 0.6rem; height: 0.6rem; margin: 0; }
.tracker-counts b { font-size: 18px; font-weight: 500; line-height: 1.1; font-variant-numeric: tabular-nums; }
.tracker-counts dt { font-size: 11px; line-height: 1.3; opacity: 0.8; white-space: nowrap; }
.tracker-counts .tc.g b { color: var(--slate-ink); }
.tracker-counts .tc.a b { color: var(--clay-ink); }
.tracker-counts .tc.n b { color: rgba(42, 40, 36, 0.7); }   /* the square is charcoal 45%; the number a little darker so it reads */
.tracker-counts .tc.d b { color: var(--sage-ink); }
@media (max-width: 760px) {
    .sys .tracker .tracker-bar { width: 100%; max-width: none; border-radius: 12px 12px 0 0; padding: 10px 16px; }
    .tracker-top { justify-content: space-between; }
    .tracker-counts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
/* footer links: 44 px tap targets on the Systems page (Website round 15) */
body.sys .footer-nav a, body.sys .email-link { min-height: 44px; display: inline-flex; align-items: center; }

/* Design round 1: a flow step with a page links to it */
.hf-name a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.hf-name a:focus-visible { outline: 2px solid var(--slate); outline-offset: 2px; }
