/* One design system for the site and the brief. Colors and type come from build/brand.ts
   (written between the tokens markers by build/build.ts). No web fonts, no script. */

/* tokens:start */
/* Generated from build/brand.ts: do not edit by hand. */
:root {
  --paper: #fcf9f2;
  --paper-deep: #f3efe5;
  --panel: #fffdf9;
  --ink: #1f1d17;
  --dim: #686358;
  --rule: #e3ddd1;
  --rule-strong: #c4bdae;
  --accent: #007541;
  --accent-soft: #daf7e3;
  --on-accent: #fcf9f2;
  --use-mark: #d47a00;
  --use-text: #9b5700;
  --use-soft: #ffead9;
  --dark: #0d2b1c;
  --dark-ink: #f2eee6;
  --dark-dim: #b4c2b8;
  --dark-accent: #68e099;
  --dark-use: #ffa752;
  --dark-rule: #294131;
  --code: #f4f0e7;
  --serif: "Iowan Old Style", Charter, "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0f0d09;
    --paper-deep: #16140f;
    --panel: #191712;
    --ink: #efebe2;
    --dim: #b3ada3;
    --rule: #2e2b25;
    --rule-strong: #4b473f;
    --accent: #41d686;
    --accent-soft: #0f2e1b;
    --on-accent: #04130a;
    --use-mark: #ffa752;
    --use-text: #ffb169;
    --use-soft: #3a230c;
    --dark: #031b10;
    --dark-ink: #f2eee6;
    --dark-dim: #b4c2b8;
    --dark-accent: #68e099;
    --dark-use: #ffa752;
    --dark-rule: #1f3326;
    --code: #1a1813;
  }
}
/* tokens:end */
:root {
  --t-xs: 0.8125rem;
  --t-sm: 0.9375rem;
  --t-md: 1.0625rem;
  --t-lg: 1.25rem;

  --wrap: 72rem;
  --read: 40rem;
  --pad: clamp(4.5rem, 9vw, 8rem);
  --r: 12px;
  --shadow: 0 1px 2px rgb(28 26 22 / 0.05), 0 12px 32px rgb(28 26 22 / 0.07);
}
@media (prefers-color-scheme: dark) {
  :root {
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 12px 32px rgb(0 0 0 / 0.35);
  }
}

/* ── Base ──────────────────────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img,
svg {
  max-width: 100%;
}
a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}
::selection {
  background: color-mix(in oklab, var(--accent) 25%, transparent);
}
h1,
h2 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.015em;
  text-wrap: balance;
  margin: 0;
}
h1 {
  font-size: clamp(2.5rem, 5.4vw, 4.25rem);
  line-height: 1.05;
  max-width: 18ch;
}
h2 {
  font-size: clamp(1.875rem, 3.4vw, 2.75rem);
  line-height: 1.1;
  max-width: 22ch;
}
h3 {
  font-size: var(--t-md);
  font-weight: 650;
  line-height: 1.35;
  margin: 0 0 0.375rem;
}
p {
  text-wrap: pretty;
}
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 1.5rem;
}
[id] {
  scroll-margin-top: 5rem;
}
.skip {
  position: absolute;
  left: -999px;
  top: 0;
}
.skip:focus {
  left: 1rem;
  top: 0.5rem;
  z-index: 30;
  background: var(--panel);
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
}

/* ── Header ─────────────────────────────────────────────────────────────── */
.top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--paper);
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--rule);
}
.top-in {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: 4rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 650;
  font-size: var(--t-md);
  letter-spacing: -0.01em;
  flex: none;
}
/* The mark: use in amber, build in green. */
.mark .m-use {
  stroke: var(--use-mark);
}
.mark .m-build {
  stroke: var(--accent);
}
.foot .mark .m-use,
.band-dark .mark .m-use {
  stroke: var(--dark-use);
}
.foot .mark .m-build,
.band-dark .mark .m-build {
  stroke: var(--dark-accent);
}
.top-in > nav {
  margin-left: auto;
  display: flex;
  gap: 1.5rem;
  font-size: var(--t-sm);
}
.top nav a {
  color: var(--dim);
  text-decoration: none;
  white-space: nowrap;
}
.top nav a:hover,
.top nav a[aria-current="page"] {
  color: var(--ink);
}
.top nav a[aria-current="page"] {
  box-shadow: inset 0 -2px 0 var(--accent);
  padding-bottom: 0.25rem;
}
.top a.nav-cta {
  flex: none;
  font-size: var(--t-sm);
  font-weight: 600;
  text-decoration: none;
  color: var(--on-accent);
  background: var(--accent);
  border-radius: 999px;
  padding: 0.5rem 1rem;
}
.top a.nav-cta:hover {
  filter: brightness(1.08);
}

/* ── Type helpers ───────────────────────────────────────────────────────── */
.eyebrow {
  margin: 0 0 1rem;
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.lead {
  margin: 1.25rem 0 0;
  max-width: var(--read);
  font-size: var(--t-lg);
  line-height: 1.55;
  color: var(--dim);
}
.aside {
  margin: 1.5rem 0 0;
  max-width: var(--read);
  font-size: var(--t-sm);
  color: var(--dim);
}
.asof {
  margin: 1rem 0 0;
  font-size: var(--t-xs);
  color: var(--dim);
}

/* ── Hero and proof ─────────────────────────────────────────────────────── */
.hero {
  padding: clamp(5rem, 11vw, 9rem) 0 clamp(3.5rem, 7vw, 5.5rem);
}
.hero-sm {
  padding: clamp(4rem, 8vw, 6.5rem) 0 clamp(2.5rem, 5vw, 3.5rem);
}
.hero-sm h1 {
  font-size: clamp(2.25rem, 4.6vw, 3.5rem);
  max-width: 22ch;
}
/* The home hero: the statement on the left, a worked example of the workflow on the right. */
.hero-split {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 4rem;
  align-items: center;
}
.trace {
  margin: 0;
  padding: 1.5rem 1.75rem;
  border: 1px solid var(--rule);
  border-radius: var(--r);
  background: var(--panel);
  box-shadow: var(--shadow);
}
.trace figcaption {
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 1rem;
}
.trace ol {
  list-style: none;
  margin: 0;
  padding: 0;
}
.trace li {
  position: relative;
  display: grid;
  gap: 0.125rem;
  padding: 0 0 1.1rem 1.75rem;
  font-size: var(--t-sm);
}
.trace li::before {
  content: "";
  position: absolute;
  left: 0.3rem;
  top: 0.4rem;
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: var(--accent);
}
.trace li::after {
  content: "";
  position: absolute;
  left: 0.56rem;
  top: 1.1rem;
  bottom: 0.1rem;
  width: 1px;
  background: var(--rule-strong);
}
.trace li.last {
  padding-bottom: 0;
}
.trace li.last::after {
  display: none;
}
.trace li:first-child::before,
.trace li.last::before {
  background: var(--use-mark);
}
.trace li.last::before {
  box-shadow: 0 0 0 4px var(--use-soft);
}
.trace b {
  font-weight: 650;
}
.trace span {
  color: var(--dim);
}
@media (max-width: 64rem) {
  .hero-split {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .trace {
    max-width: 32rem;
  }
}

/* Kept for the 404 and retired-console pages. */
.sub {
  margin: 1.25rem 0 0;
  max-width: var(--read);
  font-size: var(--t-lg);
  color: var(--dim);
}
.cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.75rem;
  margin: 2.25rem 0 0;
}
.btn {
  display: inline-flex;
  align-items: center;
  min-height: 3rem;
  padding: 0 1.5rem;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
  font-size: var(--t-md);
  text-decoration: none;
  border: 1px solid var(--accent);
  transition:
    filter 0.15s ease,
    transform 0.15s ease;
}
.btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}
.btn.ghost {
  background: none;
  color: var(--ink);
  border-color: var(--rule-strong);
}
.link {
  font-weight: 600;
  font-size: var(--t-md);
  text-decoration: none;
}
.link:hover {
  text-decoration: underline;
}
.proof {
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--paper-deep);
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
}
.stats div {
  padding: 2rem 1.5rem 2rem 0;
}
.stats div + div {
  padding-left: 1.5rem;
  border-left: 1px solid var(--rule);
}
.stats dt {
  font-family: var(--serif);
  font-size: clamp(2.25rem, 3.6vw, 3rem);
  line-height: 1;
  letter-spacing: -0.02em;
}
.stats dd {
  margin: 0.625rem 0 0;
  font-size: var(--t-sm);
  line-height: 1.45;
  color: var(--dim);
  max-width: 18rem;
}

/* ── Sections ───────────────────────────────────────────────────────────── */
.band {
  padding: var(--pad) 0;
  border-top: 1px solid var(--rule);
}
.proof + .band,
.band-dark + .band {
  border-top: 0;
}
.band-tight {
  padding-top: 2.5rem;
  border-top: 0;
}
.section-head {
  margin-bottom: clamp(2.25rem, 4vw, 3.5rem);
}
.band-dark {
  background: var(--dark);
  color: var(--dark-ink);
  border-top: 0;
}
.band-dark .eyebrow {
  color: var(--dark-accent);
}
.band-dark .lead,
.band-dark p {
  color: var(--dark-dim);
}
.band-dark h3 {
  color: var(--dark-ink);
}
.band-dark .grid > div {
  border-color: var(--dark-rule);
}
.band-dark .grid p,
.band-dark .dest-l {
  color: var(--dark-dim);
}
.band-dark .dest-card {
  background: transparent;
  border-color: var(--dark-rule);
  color: var(--dark-ink);
}
.band-dark .dest-card:hover {
  border-color: var(--dark-accent);
}
.band-dark .dest-l {
  color: var(--dark-dim);
}
.band-dark .arrow {
  color: var(--dark-accent);
}

/* Statements in a two-column grid, separated by hairlines. */
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 3rem;
}
.grid > div {
  padding: 1.5rem 0;
  border-top: 1px solid var(--rule);
}
.grid p {
  margin: 0;
  font-size: var(--t-md);
  color: var(--dim);
}

/* The request workflow: six numbered steps. */
.flow {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 3rem;
}
.flow li {
  counter-increment: step;
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--rule);
}
.flow li:first-child::before,
.flow li:last-child::before {
  color: var(--use-text);
}
.flow li::before {
  content: counter(step, decimal-leading-zero);
  display: block;
  font-family: var(--serif);
  font-size: 2rem;
  line-height: 1;
  color: var(--accent);
  margin-bottom: 1rem;
}
.flow p,
.steps p,
.layer p {
  margin: 0;
  font-size: var(--t-md);
  color: var(--dim);
}

/* Numbered steps with a heavy rule above. */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2rem 3rem;
}
.steps-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 3rem;
}
.steps li {
  counter-increment: step;
  padding-top: 1.25rem;
  border-top: 2px solid var(--ink);
}
.steps li::before {
  content: counter(step);
  display: block;
  font-family: var(--mono);
  font-size: var(--t-sm);
  color: var(--accent);
  margin-bottom: 0.5rem;
}

/* The application template's three layers. */
.layers {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}
.layer {
  display: grid;
  grid-template-columns: 14rem minmax(0, 1fr);
  column-gap: 2rem;
  padding: 1.5rem 1.75rem;
  border: 1px solid var(--rule);
  border-radius: var(--r);
  background: var(--panel);
}
.layer .pace {
  grid-row: 1 / span 2;
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  padding-top: 0.2rem;
}
.layer h3,
.layer p {
  grid-column: 2;
}
.layer-base {
  background: var(--accent-soft);
  border-color: color-mix(in oklab, var(--accent) 40%, var(--rule));
}
.note {
  margin: 2rem 0 0;
  max-width: var(--read);
  font-size: var(--t-md);
  color: var(--dim);
}
.note b {
  color: var(--ink);
}

/* ── Cards: one component ───────────────────────────────────────────────── */
.dest,
.role-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 1rem;
  margin: 2.5rem 0 0;
}
.dest-card,
.card {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--rule);
  border-radius: var(--r);
  background: var(--panel);
  color: var(--ink);
  text-decoration: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}
.dest-card:hover,
.card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.dest-t,
.card-t {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  font-weight: 650;
  font-size: var(--t-md);
}
.dest-l {
  font-size: var(--t-sm);
  color: var(--dim);
}
.card .card-t {
  margin-top: auto;
}
.card-k {
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
}
.arrow {
  color: var(--accent);
  transition: transform 0.15s ease;
}
.dest-card:hover .arrow,
.card:hover .arrow {
  transform: translateX(3px);
}

.role-links {
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
}

/* ── Tables ─────────────────────────────────────────────────────────────── */
.stack-wrap {
  overflow-x: auto;
  border: 1px solid var(--rule);
  border-radius: var(--r);
  background: var(--panel);
}
.stack {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--t-sm);
  min-width: 36rem;
}
.stack th,
.stack td {
  text-align: left;
  vertical-align: top;
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--rule);
}
.stack tbody tr:last-child th,
.stack tbody tr:last-child td {
  border-bottom: 0;
}
.stack thead th {
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
  background: var(--paper-deep);
}
.stack tbody th {
  font-weight: 650;
  width: 12rem;
}
.stack tbody th a {
  color: var(--ink);
}
.stack td {
  color: var(--dim);
}
.stack.four td:nth-child(3) {
  color: var(--ink);
}

/* ── Bill of materials ──────────────────────────────────────────────────── */
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2.5rem;
  margin: 0;
}
.legend div {
  display: flex;
  gap: 0.75rem;
  align-items: baseline;
}
.legend dd {
  margin: 0;
  font-size: var(--t-sm);
  color: var(--dim);
  max-width: 28rem;
}
.key {
  display: inline-block;
  white-space: nowrap;
  font-size: var(--t-sm);
  font-weight: 600;
  padding: 0.125rem 0.625rem;
  border-radius: 6px;
  border: 1px solid var(--rule-strong);
}
.key-built-in {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.toc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1.75rem 0 0;
}
.toc a {
  font-size: var(--t-sm);
  text-decoration: none;
  color: var(--ink);
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 0.3rem 0.875rem;
  background: var(--panel);
}
.toc a:hover {
  border-color: var(--accent);
}
.bom-wrap {
  padding-bottom: var(--pad);
}
.bom-group {
  padding-top: 3.5rem;
}
.bom-group > h2 {
  margin-bottom: 1.25rem;
}
.bom {
  display: grid;
  gap: 0.75rem;
}
.bom-row {
  display: grid;
  grid-template-columns: 13rem 11rem minmax(0, 1fr) minmax(0, 1.25fr);
  gap: 1.25rem 2rem;
  padding: 1.5rem 1.75rem 1.25rem;
  border: 1px solid var(--rule);
  border-radius: var(--r);
  background: var(--panel);
}
.bom-row h3 {
  margin: 0 0 0.25rem;
}
.bom-row p {
  margin: 0;
  font-size: var(--t-sm);
  color: var(--dim);
}
.bom-col b {
  display: block;
  font-size: var(--t-sm);
  font-weight: 650;
}
.k {
  display: block;
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 0.625rem;
}
.chips {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
}
.chips li {
  font-size: var(--t-sm);
  line-height: 1.3;
  padding: 0.25rem 0.625rem;
  border-radius: 6px;
  border: 1px solid var(--rule-strong);
}
.chips-built-in li {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.none {
  color: var(--dim);
}
.bom-foot {
  grid-column: 1 / -1;
  padding-top: 1rem;
  border-top: 1px solid var(--rule);
}
.bom-foot b {
  color: var(--ink);
  font-weight: 650;
}
.bom-foot details {
  margin-top: 0.5rem;
}
.bom-foot summary {
  font-size: var(--t-xs);
  color: var(--dim);
  cursor: pointer;
  width: fit-content;
}
.bom-foot code {
  font-family: var(--mono);
  font-size: var(--t-xs);
  background: var(--code);
  padding: 0.05em 0.35em;
  border-radius: 4px;
  word-break: break-all;
}

/* ── Worksheet ──────────────────────────────────────────────────────────── */
.ws-wrap {
  padding-bottom: var(--pad);
  counter-reset: ref built fit;
}
.ws-group {
  margin-top: 3.5rem;
}
.ws-group h2 {
  margin-bottom: 1rem;
}
.ws {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--t-sm);
}
.ws th,
.ws td {
  text-align: left;
  vertical-align: top;
  padding: 0.75rem 1rem 0.75rem 0;
  border-bottom: 1px solid var(--rule);
}
.ws thead th {
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--dim);
  border-bottom: 2px solid var(--ink);
}
.ws tbody th {
  width: 13rem;
  font-weight: 650;
}
.ticks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.125rem;
}
.ticks label {
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
  padding: 0.2rem 0.4rem;
  margin: 0 -0.4rem;
  border-radius: 6px;
  cursor: pointer;
}
.ticks label:hover {
  background: var(--code);
}
.ticks label:has(input:checked) {
  background: var(--accent-soft);
  font-weight: 600;
}
.pick {
  flex: none;
  width: 1rem;
  height: 1rem;
  margin: 0;
  accent-color: var(--accent);
  transform: translateY(0.15rem);
  cursor: pointer;
}
.pick-reference:checked {
  counter-increment: ref;
}
.pick-built-in:checked {
  counter-increment: built;
}
.pick-retrofit:checked {
  counter-increment: fit;
}
.n-ref::after {
  content: counter(ref);
}
.n-built::after {
  content: counter(built);
}
.n-fit::after {
  content: counter(fit);
}
.ws-sum {
  position: sticky;
  bottom: 1rem;
  margin: 3rem 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  border-radius: 999px;
  background: var(--dark);
  color: var(--dark-dim);
  font-size: var(--t-sm);
  box-shadow: var(--shadow);
}
.ws-sum span {
  font-weight: 650;
  color: var(--dark-ink);
  margin-right: 0.75rem;
}
.ws-sum b {
  font-family: var(--serif);
  font-size: var(--t-lg);
  color: var(--dark-accent);
  margin-left: 1rem;
}
.ws-sum b:first-of-type {
  margin-left: 0;
}

/* ── Diagrams ───────────────────────────────────────────────────────────── */
/* A diagram is drawn 1920 wide: it breaks out of the text column to use the screen (up to
   1600px). On a phone it keeps a readable size and scrolls sideways inside its frame. */
.fig {
  --fig-w: min(calc(100vw - 3rem), 1600px);
  width: var(--fig-w);
  margin: 0 0 0 calc((100% - var(--fig-w)) / 2);
}
.diagram {
  display: block;
  overflow-x: auto;
  border-radius: var(--r);
}
.diagram img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--rule);
  border-radius: var(--r);
  background: var(--paper);
}
.fig figcaption {
  margin-top: 0.75rem;
  font-size: var(--t-sm);
  text-align: right;
}

/* The evaluation guide: question on the left, answer on the right, hairline between. */
.qas {
  border-top: 2px solid var(--ink);
}
.qa {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 0.5rem 3rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--rule);
}
.qa h3 {
  margin: 0;
  font-size: var(--t-lg);
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.3;
}
.qa p {
  margin: 0;
  font-size: var(--t-md);
  color: var(--dim);
}
@media (max-width: 52rem) {
  .qa {
    grid-template-columns: 1fr;
  }
}

/* Example requests: what a person types into the Tell the builders box. */
.asks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.ask {
  margin: 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--rule);
  border-left: 3px solid var(--use-mark);
  border-radius: var(--r);
  background: var(--panel);
  font-family: var(--serif);
  font-size: var(--t-lg);
  line-height: 1.4;
}
.ask-k {
  display: block;
  margin-bottom: 0.5rem;
  font-family: var(--sans);
  font-size: var(--t-xs);
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--use-text);
}
@media (max-width: 52rem) {
  .asks {
    grid-template-columns: 1fr;
  }
}

/* The security summary: five commitments, each one line. */
.commit {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  border-top: 2px solid var(--ink);
}
.commit li {
  padding: 1rem 0;
  border-bottom: 1px solid var(--rule);
  font-size: var(--t-lg);
  color: var(--dim);
}
.commit b {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.5rem;
  color: var(--ink);
  margin-right: 0.5rem;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ── Footer ─────────────────────────────────────────────────────────────── */
.foot {
  background: var(--dark);
  color: var(--dark-dim);
  padding: clamp(4rem, 8vw, 6rem) 0 3rem;
}
.foot-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  padding-bottom: 3.5rem;
  border-bottom: 1px solid var(--dark-rule);
}
.foot-cta h2 {
  color: var(--dark-ink);
}
.foot-cta p {
  margin: 1rem 0 0;
  max-width: 34rem;
  color: var(--dark-dim);
}
.foot-cta .cta {
  margin: 0;
}
.btn-light {
  background: var(--dark-ink);
  color: var(--dark);
  border-color: var(--dark-ink);
}
.link-light {
  color: var(--dark-ink);
  font-weight: 600;
  text-decoration: none;
}
.link-light:hover {
  text-decoration: underline;
}
.foot-cols {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 2rem;
  padding-top: 3rem;
  font-size: var(--t-sm);
}
.foot-brand .brand {
  color: var(--dark-ink);
}

.foot-brand p {
  margin: 1rem 0 0;
  max-width: 22rem;
}
.foot a {
  color: var(--dark-dim);
}
.foot a:hover {
  color: var(--dark-ink);
}
.foot .btn-light {
  color: var(--dark);
}
.foot .link-light {
  color: var(--dark-ink);
}
.foot nav {
  display: grid;
  align-content: start;
  gap: 0.5rem;
}
.foot nav a {
  text-decoration: none;
}
.foot nav h3 {
  color: var(--dark-ink);
  font-size: var(--t-xs);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
}

/* ── Small screens ──────────────────────────────────────────────────────── */
@media (max-width: 60rem) {
  .bom-row {
    grid-template-columns: 1fr 1fr;
  }
  .bom-what {
    grid-column: 1 / -1;
  }
  .steps-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .foot-cols {
    grid-template-columns: repeat(3, 1fr);
  }
  .foot-brand {
    grid-column: 1 / -1;
  }
}
@media (max-width: 52rem) {
  .top-in {
    flex-wrap: wrap;
    row-gap: 0;
    padding-top: 0.75rem;
  }
  .top-in > nav {
    order: 3;
    width: 100%;
    margin-left: 0;
    overflow-x: auto;
    padding: 0.75rem 0;
    scrollbar-width: none;
  }
  .top a.nav-cta {
    margin-left: auto;
  }
  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stats div:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }
  .stats div:nth-child(n + 3) {
    border-top: 1px solid var(--rule);
  }
  .flow,
  .steps {
    grid-template-columns: 1fr 1fr;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .layer {
    grid-template-columns: 1fr;
  }
  .layer .pace {
    grid-row: auto;
    margin-bottom: 0.5rem;
  }
  .layer h3,
  .layer p {
    grid-column: 1;
  }
}
@media (max-width: 40rem) {
  body {
    font-size: 1.0625rem;
  }
  .wrap {
    padding: 0 1rem;
  }
  .flow,
  .steps,
  .steps-4,
  .bom-row {
    grid-template-columns: 1fr;
  }
  .fig {
    --fig-w: calc(100vw - 2rem);
  }
  .fig .diagram img {
    width: 62rem;
    max-width: none;
  }
  .foot-cols {
    grid-template-columns: 1fr 1fr;
  }
  /* The worksheet's table becomes one card per layer. */
  .ws thead {
    display: none;
  }
  .ws,
  .ws tbody,
  .ws tr,
  .ws th,
  .ws td {
    display: block;
    width: auto;
  }
  .ws tr {
    padding: 1rem 0;
    border-bottom: 1px solid var(--rule);
  }
  .ws th,
  .ws td {
    border: 0;
    padding: 0.25rem 0;
  }
  .ws td:nth-of-type(1)::before {
    content: "Default";
  }
  .ws td:nth-of-type(2)::before {
    content: "Built-in options";
  }
  .ws td:nth-of-type(3)::before {
    content: "Integration options";
  }
  .ws td::before {
    display: block;
    font-size: var(--t-xs);
    font-weight: 650;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--dim);
    margin: 0.5rem 0 0.25rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}

/* ── Print ──────────────────────────────────────────────────────────────── */
@page {
  size: letter;
  margin: 0.6in 0.6in 0.75in;
}
@page wide {
  size: letter landscape;
  margin: 0.45in 0.5in 0.6in;
}
@media print {
  :root {
    --paper: #fff;
    --paper-deep: #f6f3ec;
    --panel: #fff;
    --code: #f4f1ea;
  }
  html {
    font-size: 12px;
  }
  html,
  body {
    background: #fff;
  }
  body {
    font-size: 1rem;
    line-height: 1.5;
  }
  .wrap {
    max-width: none;
    padding: 0;
  }
  .skip,
  .top nav,
  .nav-cta,
  .cta,
  .dest,
  .role-links,
  .toc,
  .foot,
  .ws-sum,
  .fig figcaption,
  .bom-foot details {
    display: none !important;
  }
  .top {
    position: static;
    background: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border: 0;
  }
  .hero,
  .hero-sm {
    padding: 0 0 1.5rem;
  }
  .band,
  .band-tight {
    padding: 1.5rem 0;
    border-top: 0;
  }
  .band-dark {
    background: none;
    color: var(--ink);
  }
  .band-dark .lead,
  .band-dark p {
    color: var(--dim);
  }
  .band-dark h3 {
    color: var(--ink);
  }
  .band-dark .grid > div {
    border-color: var(--rule);
  }
  .band-dark .eyebrow {
    color: var(--accent);
  }
  h1 {
    font-size: 2.75rem;
  }
  h2 {
    font-size: 1.85rem;
    break-after: avoid;
  }
  h3 {
    break-after: avoid;
  }
  .flow li,
  .steps li,
  .grid > div,
  .layer,
  .bom-row,
  .stack tr,
  .ws tr,
  .b-list li,
  .qa,
  .stats div {
    break-inside: avoid;
  }
  .bom-row {
    grid-template-columns: 10rem 9rem minmax(0, 1fr) minmax(0, 1fr);
    gap: 0.75rem 1.25rem;
    padding: 0.9rem 1.1rem;
  }
  .fig {
    width: 100%;
    margin: 0;
  }
  .fig .diagram {
    overflow: visible;
  }
  .fig .diagram img,
  .diagram img {
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 6px;
  }
  .stack-wrap {
    overflow: visible;
    border-radius: 6px;
  }
  .stack {
    min-width: 0;
  }
  thead {
    display: table-header-group;
  }
  a {
    color: inherit;
    text-decoration: none;
  }

  /* The brief: a cover page, an overview, the bill of materials, then each diagram on its own
     landscape page at full width. */
  .brief .top {
    display: none;
  }
  .b-cover {
    height: 9.4in;
    display: flex;
    flex-direction: column;
    padding: 0.4in 0 0;
  }
  .b-cover .wrap {
    display: flex;
    flex-direction: column;
    height: 100%;
  }
  .b-cover h1 {
    font-size: 3.8rem;
    max-width: 15ch;
    margin-top: 1.5in;
  }
  .b-cover .lead {
    font-size: 1.4rem;
    max-width: 34rem;
  }
  .b-cover .stats {
    margin-top: auto;
    border-top: 2px solid var(--ink);
  }
  .b-cover .stats div {
    padding: 1.1rem 1rem 0 0;
  }
  .b-cover .stats div + div {
    padding-left: 1rem;
  }
  .b-cover .stats dt {
    font-size: 2.4rem;
  }
  .b-sec {
    break-before: page;
  }
  .b-sec h2 {
    margin: 1.75rem 0 0.6rem;
  }
  .b-sec h2:first-child {
    margin-top: 0;
  }
  .b-sec .wrap > p,
  .b-list {
    max-width: 44rem;
    color: var(--dim);
  }
  .b-list {
    padding-left: 1.1rem;
  }
  .b-list li {
    margin-bottom: 0.4rem;
  }
  .b-list b {
    color: var(--ink);
  }
  .b-sec .flow {
    margin-top: 0.75rem;
    gap: 0 1.5rem;
  }
  .b-sec .flow li {
    padding: 0.75rem 0 0.9rem;
  }
  .b-sec .flow li::before {
    font-size: 1.4rem;
    margin-bottom: 0.4rem;
  }
  .b-sec .flow p {
    font-size: 0.95rem;
  }
  .b-sec .legend {
    margin: 0.75rem 0 1rem;
  }
  .stack.compact {
    font-size: 0.85rem;
  }
  .stack.compact th,
  .stack.compact td {
    padding: 0.35rem 0.6rem;
  }
  .stack.compact tbody {
    break-inside: avoid;
  }
  .stack.compact tr.grp th {
    background: var(--paper-deep);
    font-size: 0.75rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--dim);
  }
  .b-diagram {
    page: wide;
    break-before: page;
    break-inside: avoid;
  }
  /* A diagram fits one landscape page: its height is capped and its width follows. */
  .b-diagram .fig .diagram img {
    width: 100% !important;
  }
  .b-diagram.tall .fig .diagram img {
    width: auto !important;
    height: 6.2in;
    margin: 0 auto;
  }
  .brief .stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .brief .stats div:nth-child(3) {
    padding-left: 1rem;
    border-left: 1px solid var(--rule);
  }
  .brief .stats div:nth-child(n + 3) {
    border-top: 0;
  }
  .brief .flow {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .b-diagram h2 {
    margin: 0 0 0.6rem;
  }
  .b-diagram .lead {
    margin: 0 0 0.8rem;
    font-size: 1rem;
  }
  .b-contact {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: var(--dim);
  }
}

/* On screen the brief reads as a plain document. */
@media screen {
  .b-cover {
    padding: 5rem 0 3rem;
  }
  .b-cover .stats {
    margin-top: 3rem;
    border-top: 1px solid var(--rule);
  }
  .b-sec {
    padding: 3rem 0;
    border-top: 1px solid var(--rule);
  }
  .b-sec h2 {
    margin: 2.5rem 0 1rem;
  }
  .b-sec .wrap > p,
  .b-list {
    max-width: var(--read);
    color: var(--dim);
  }
  .b-list b {
    color: var(--ink);
  }
  .b-diagram .fig {
    margin-top: 1rem;
  }
  .b-contact {
    margin-top: 2rem;
    font-size: var(--t-sm);
    color: var(--dim);
  }
}
