* { box-sizing: border-box; }
html, body { margin: 0; background: var(--ledger); color: var(--ink); font-family: 'Public Sans', system-ui, -apple-system, sans-serif; }
body { font-size: 16.5px; line-height: 1.6; }
a { color: var(--ink-blue); }

.page { max-width: 720px; margin: 0 auto; padding: 4.5rem 1.75rem 6rem; }

.masthead { margin-bottom: 2.5rem; }
.masthead__brand { display: flex; align-items: center; gap: 0.55rem; }
.masthead__icon { display: block; flex: none; }
.masthead__brand .masthead__kicker { margin: 0; }
.masthead__kicker { font-family: 'IBM Plex Mono', monospace; font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); margin: 0; }
.masthead__rule { width: 48px; height: 3px; background: var(--ink-blue); border: 0; margin: 0.9rem 0; }
.masthead__mark { font-family: 'Bitter', Georgia, serif; font-weight: 700; font-size: 2.1rem; line-height: 1.2; margin: 0; text-wrap: balance; }
.masthead__sub { font-size: 1.1rem; color: var(--graphite); margin: 0.9rem 0 0; max-width: 54ch; }

/* Task index */
.toc { background: var(--sheet); border: 1px solid var(--rule); border-radius: 4px; padding: 1.4rem 1.6rem; margin: 0 0 3rem; }
.toc__title { font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--graphite); margin: 0 0 0.9rem; }
.toc ol { list-style: none; counter-reset: toc; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0.55rem 1.5rem; }
@media (max-width: 560px) { .toc ol { grid-template-columns: 1fr; } }
.toc li { counter-increment: toc; }
.toc a { text-decoration: none; display: flex; gap: 0.6rem; align-items: baseline; }
.toc a::before { content: counter(toc, upper-alpha); font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; color: var(--graphite); flex: none; }
.toc a:hover { text-decoration: underline; }

/* Task section */
.task { padding-top: 2.5rem; margin-top: 2.5rem; border-top: 1px solid var(--rule); scroll-margin-top: 1.5rem; }
.task__label { font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-blue); margin: 0 0 0.5rem; }
.task h2 { font-family: 'Bitter', Georgia, serif; font-weight: 700; font-size: 1.55rem; line-height: 1.25; margin: 0 0 0.75rem; text-wrap: balance; max-width: 24ch; }
.task > p { max-width: 62ch; margin: 0 0 1.1rem; color: var(--ink); }
.task > p.muted { color: var(--graphite); }

/* Steps — the defining device: a numbered sequence */
ol.steps { list-style: none; counter-reset: step; margin: 1.4rem 0; padding: 0; display: flex; flex-direction: column; gap: 1.1rem; }
ol.steps > li { counter-increment: step; display: grid; grid-template-columns: 1.9rem 1fr; gap: 0.9rem; max-width: 64ch; }
ol.steps > li::before {
  content: counter(step);
  font-family: 'IBM Plex Mono', monospace; font-size: 0.85rem; font-weight: 600;
  color: var(--ink-blue);
  width: 1.9rem; height: 1.9rem; border: 1px solid var(--rule); border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  background: var(--sheet);
}
ol.steps .step-body { padding-top: 0.2rem; min-width: 0; }
ol.steps .step-body strong { font-weight: 600; }

.kbd, code {
  font-family: 'IBM Plex Mono', monospace; font-size: 0.86em;
  background: var(--sheet); border: 1px solid var(--rule); border-radius: 3px; padding: 0.08em 0.4em;
  white-space: nowrap;
}

/* Tip / note callouts */
.tip { border: 1px solid var(--rule); border-left: 3px solid var(--ink-blue); background: var(--sheet); border-radius: 4px; padding: 1rem 1.25rem; margin: 1.5rem 0; }
.tip__label { font-family: 'IBM Plex Mono', monospace; font-size: 0.68rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-blue); margin: 0 0 0.35rem; }
.tip p { margin: 0; max-width: 60ch; font-size: 0.96rem; }
.tip.amber { border-left-color: var(--notice-amber); background: var(--amber-bg); }
.tip.amber .tip__label { color: var(--notice-amber); }

/* Decision state chips */
.states { display: flex; flex-direction: column; gap: 0.7rem; margin: 1.25rem 0; }
.state { display: grid; grid-template-columns: auto 1fr; gap: 0.75rem; align-items: baseline; max-width: 60ch; }
.state__chip { display: inline-flex; align-items: center; gap: 0.4rem; font-family: 'IBM Plex Mono', monospace; font-size: 0.75rem; padding: 0.3rem 0.65rem; border-radius: 4px; border: 1px solid var(--rule); background: var(--sheet); white-space: nowrap; }
.state__dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.d-green { background: var(--settled-green); }
.d-violet { background: var(--negotiation-violet); }
.d-red { background: var(--deadline-red); }
.d-gray { background: var(--muted-gray); }
.state p { margin: 0; color: var(--graphite); font-size: 0.95rem; }
.state p strong { color: var(--ink); }

.backtop { display: inline-block; margin-top: 1rem; font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; color: var(--graphite); text-decoration: none; }
.backtop:hover { color: var(--ink-blue); }

.back-link { display: inline-block; margin-top: 3rem; font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; color: var(--ink-blue); text-decoration: none; }
.back-link:hover, .back-link:focus-visible { text-decoration: underline; }
footer { margin-top: 1rem; padding-top: 1.5rem; border-top: 1px solid var(--rule); font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; color: var(--graphite); }

@media (max-width: 520px) {
  .page { padding: 3rem 1.25rem 4rem; }
  .masthead__mark { font-size: 1.7rem; }
  .task h2 { font-size: 1.35rem; }
}

/* Annotated screenshots */
figure.shot { margin: 1.75rem 0 0.5rem; }
.shot__frame { position: relative; border: 1px solid var(--rule); border-radius: 6px; overflow: hidden; box-shadow: 0 1px 3px rgba(30,42,58,0.08); }
.shot__frame img { display: block; width: 100%; height: auto; }
.shot__overlay { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.shot__overlay rect { fill: none; stroke: var(--annot); stroke-width: 3; }
.shot__overlay .badge { fill: var(--annot); }
.shot__overlay .badge-txt { fill: #fff; font-family: 'IBM Plex Mono', monospace; font-weight: 600; font-size: 22px; }
figure.shot figcaption { font-size: 0.9rem; color: var(--graphite); margin-top: 0.85rem; max-width: 62ch; line-height: 1.55; }
figure.shot figcaption b { color: var(--annot); font-family: 'IBM Plex Mono', monospace; }

