/* Public pages: the home page (landing.html) and the frame every model landing page
 * shares (site_layout.html). Loads after base.css and theme.css.
 *
 * Direction (docs/design/design-direction.md): an economic report. White page, ink type in
 * Schibsted Grotesk, charts as the main objects, structure from space and a thick
 * masthead rule rather than boxes and shadows. Colour appears only where a model is
 * meant: Solow green, New Keynesian violet (theme.css), or the open model's accent.
 * One motion moment per page (charts drawing in); nothing loops.
 */
.landing {
    /* --ink, --ink-2, --ink-3, --tone and --tone-2 come from theme.css. */
    --paper: #ffffff;
    --site: var(--ink);
    --solow: var(--theme-solow-accent);
    --solow-strong: var(--theme-solow-strong);
    --solow-soft: var(--theme-solow-soft);
    --nk: var(--theme-new-keynesian-accent);
    --nk-strong: var(--theme-new-keynesian-strong);
    --nk-soft: var(--theme-new-keynesian-soft);
    --accent: var(--ink);
    --good: #1d7a52;
    --bad: #b4232f;
    --radius: 3px;
    --gutter: clamp(16px, 4vw, 48px);
    --content: 1200px;
    /* Five sizes, far apart, plus one for sources and captions. */
    --t-small: 0.8125rem;
    --t-body: 1.0625rem;
    --t-lead: 1.3125rem;
    --t-h3: 1.625rem;
    --t-h2: clamp(2.25rem, 4.4vw, 3.5rem);
    --t-display: clamp(3.25rem, 8.4vw, 6rem);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: "Schibsted Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: var(--t-body);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    accent-color: var(--accent);
    caret-color: var(--accent);
}
/* Browser surfaces carry the design too. */
.landing ::selection { background: color-mix(in srgb, var(--accent) 22%, white); color: var(--ink); }
html:has(.landing) { scrollbar-color: var(--ink-3) var(--tone); }
.landing a { color: inherit; text-decoration: none; }
.landing h1, .landing h2, .landing h3 { color: var(--ink); font-weight: 700; text-wrap: balance; }
.landing p { text-wrap: pretty; }
.landing [id] { scroll-margin-top: 96px; }
.landing main { overflow-x: clip; }
html:has(.landing) { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html:has(.landing) { scroll-behavior: auto; } }

.skip-link { position: absolute; left: 16px; top: -60px; z-index: 20; padding: 10px 14px; border-radius: var(--radius); background: var(--ink); color: #fff !important; font-weight: 600; }
.skip-link:focus { top: 12px; }


/* ---------- Buttons and links ---------- */
.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 22px; border: 2px solid var(--ink); border-radius: var(--radius); background: var(--ink); color: #fff !important; font-weight: 600; font-size: var(--t-body); transition: background 160ms var(--ease-out), color 160ms var(--ease-out), border-color 160ms var(--ease-out); }
.button span { transition: transform 160ms var(--ease-out); }
.button:hover span { transform: translateX(3px); }
.button:hover { background: #2a323b; border-color: #2a323b; }
.button-quiet { background: transparent; color: var(--ink) !important; }
.button-quiet:hover { background: var(--tone); border-color: var(--ink); }
.button-small { min-height: 40px; padding: 0 16px; font-size: 0.9375rem; }
.button-solow { background: var(--solow); border-color: var(--solow); }
.button-solow:hover { background: var(--theme-solow-accent-hover); border-color: var(--theme-solow-accent-hover); }
.button-nk { background: var(--nk); border-color: var(--nk); }
.button-nk:hover { background: var(--theme-new-keynesian-accent-hover); border-color: var(--theme-new-keynesian-accent-hover); }
.text-link { display: inline-flex; gap: 6px; color: var(--ink) !important; font-weight: 600; text-decoration: underline !important; text-decoration-thickness: 2px !important; text-underline-offset: 5px; text-decoration-color: var(--solow) !important; }
.text-link-nk { text-decoration-color: var(--nk) !important; }
.text-link:hover { text-decoration-color: var(--ink) !important; }

/* One drawn arrow for every "go there" link (R2): a mask, so it takes the text colour. */
.arrow { display: inline-block; flex-shrink: 0; width: 0.95em; height: 0.95em; background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='square'%3E%3Cpath d='M2 8h11M9 3.5 13.5 8 9 12.5'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='square'%3E%3Cpath d='M2 8h11M9 3.5 13.5 8 9 12.5'/%3E%3C/svg%3E") center / contain no-repeat; }

/* ---------- Masthead ---------- */
.site-bar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 24px; max-width: calc(var(--content) + 2 * var(--gutter)); margin: 0 auto; padding: 14px var(--gutter); background: var(--paper); border-bottom: 3px solid var(--masthead-rule, var(--ink)); }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font-size: 1.125rem; letter-spacing: -0.02em; font-weight: 500; }
.wordmark strong { font-weight: 800; }
.wordmark-mark { width: 30px; height: 30px; }
.site-bar-links { display: flex; gap: 2px; margin-left: auto; }
.site-bar-links a { padding: 8px 12px; border-radius: var(--radius); color: var(--ink-2); font-size: 0.9375rem; font-weight: 500; transition: background 160ms var(--ease-out), color 160ms var(--ease-out); }
.site-bar-links a:hover { color: var(--ink); background: var(--tone); }
@media (max-width: 720px) {
    .site-bar-links { display: none; }
    .site-bar .button-small { margin-left: auto; }
}

/* ---------- Sections: a report's rhythm, title column and body column ---------- */
.section { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 24px clamp(24px, 4vw, 64px); max-width: var(--content); margin: 0 auto; padding: clamp(72px, 10vw, 128px) var(--gutter) 0; }
.section > * { grid-column: 2; min-width: 0; }
/* The title sticks beside the body while it scrolls, so it spans exactly the rows the
   body uses: one per block after the title. Spanning spare rows would add their row
   gaps as blank space at the end of the section, with the title stuck over it. */
.section > .section-head { grid-column: 1; grid-row: 1 / span 1; align-self: start; position: sticky; top: 104px; }
.section:has(> :nth-child(3)) > .section-head { grid-row: 1 / span 2; }
.section:has(> :nth-child(4)) > .section-head { grid-row: 1 / span 3; }
.section:has(> :nth-child(5)) > .section-head { grid-row: 1 / span 4; }
.section:has(> :nth-child(6)) > .section-head { grid-row: 1 / span 5; }
.section-head h2 { margin: 0; font-size: var(--t-h2); letter-spacing: -0.035em; line-height: 1.02; }
.section-lede { margin: 16px 0 0; color: var(--ink-2); font-size: var(--t-body); }
@media (max-width: 900px) {
    .section { grid-template-columns: 1fr; }
    .section > *, .section > .section-head { grid-column: 1; grid-row: auto; position: static; }
}

/* ---------- Hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; gap: clamp(32px, 5vw, 72px); max-width: var(--content); margin: 0 auto; padding: clamp(48px, 7vw, 96px) var(--gutter) 0; }
.hero h1 { margin: 0; font-size: var(--t-display); font-weight: 800; letter-spacing: -0.04em; line-height: 0.94; }
.lede { max-width: 30em; margin: 28px 0 0; color: var(--ink-2); font-size: var(--t-lead); line-height: 1.45; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.proof { max-width: 30em; margin: 28px 0 0; color: var(--ink-3); font-size: var(--t-small); line-height: 1.6; }
.proof strong { color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; }
.proof .stat { display: none; }
.proof .stat.is-loaded { display: inline; }

/* The hero figure: a report chart, framed by a thick top rule, not a card. */
.golden-card { margin: 0; padding-top: 14px; border-top: 3px solid var(--ink); }
.golden-head h2 { margin: 0; font-size: var(--t-lead); font-weight: 700; letter-spacing: -0.015em; }
.golden-chart { position: relative; margin: 12px -4px 0; }
.golden-chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart-message { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; padding: 20px; background: rgba(255, 255, 255, 0.92); color: var(--ink-3); font-size: var(--t-small); text-align: center; }
.chart-message[hidden] { display: none; }
.golden-chart .grid line { stroke: var(--tone-2); stroke-width: 1; }
.golden-chart .grid line.zero { stroke: var(--ink-3); stroke-width: 1.25; }
.golden-chart .tick { fill: var(--ink-3); font-size: 11px; font-variant-numeric: tabular-nums; }
.golden-chart .axis-title { fill: var(--ink-2); font-size: 11.5px; font-weight: 600; }
.golden-chart .curve { fill: none; stroke: var(--solow); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.golden-chart .golden-rule { stroke: var(--ink); stroke-width: 1.5; stroke-dasharray: 2 4; }
.golden-chart .golden-rule-label { fill: var(--ink); font-size: 11.5px; font-weight: 700; }
.golden-chart .today-dot { fill: var(--paper); stroke: var(--ink); stroke-width: 2; }
.golden-chart .today-label { fill: var(--ink-2); font-size: 11.5px; font-weight: 600; }
.golden-chart .chosen { transition: transform 120ms var(--ease-out); }
.golden-chart .chosen-guide { stroke: var(--solow); stroke-width: 1.5; stroke-dasharray: 3 4; }
.golden-chart .chosen-halo { fill: var(--solow); opacity: 0.14; }
.golden-chart .chosen-dot { fill: var(--solow); stroke: var(--paper); stroke-width: 2.5; }

.golden-control { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 4px 12px; margin-top: 14px; }
.golden-control label { color: var(--ink-2); font-size: 0.9375rem; font-weight: 600; }
.golden-control output { color: var(--solow-strong); font-size: var(--t-h3); font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.golden-control input { grid-column: 1 / -1; width: 100%; height: 32px; margin: 0; accent-color: var(--solow); cursor: pointer; }
.golden-control input:disabled { cursor: progress; opacity: 0.5; }
.golden-readout { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; margin: 14px 0 0; background: var(--paper); }
.golden-readout div { padding: 12px 14px; background: var(--tone); }
.golden-readout dt { color: var(--ink-2); font-size: var(--t-small); font-weight: 600; }
.golden-readout dd { margin: 2px 0 0; font-size: var(--t-h3); font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.golden-readout dd[data-sign="1"] { color: var(--good); }
.golden-readout dd[data-sign="-1"] { color: var(--bad); }
.golden-headline { min-height: 3em; margin: 14px 0 6px; color: var(--ink); font-size: var(--t-body); font-weight: 500; }
.figure-source { margin: 16px 0 0; color: var(--ink-3); font-size: var(--t-small); }
.golden-card .text-link { margin-top: 14px; }

/* ---------- Models ---------- */
#models { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
#models > .section-head { grid-column: 1 / -1; grid-row: auto; position: static; max-width: 720px; }
#models > .model-grid, #models > .more-models-title, #models > .more-models, #models > .roadmap { grid-column: 1 / -1; }
.model-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 5vw, 72px); }
.model-card { --accent: var(--site); display: flex; flex-direction: column; padding-top: 16px; border-top: 6px solid var(--accent); }
.model-solow { --accent: var(--solow); --accent-strong: var(--solow-strong); --accent-soft: var(--solow-soft); }
.model-nk { --accent: var(--nk); --accent-strong: var(--nk-strong); --accent-soft: var(--nk-soft); }
.clock { margin: 0; color: var(--accent-strong); font-size: 0.9375rem; font-weight: 700; }
.model-card h3 { margin: 4px 0 10px; font-size: var(--t-h2); letter-spacing: -0.035em; line-height: 1.02; }
.model-question { max-width: 32em; margin: 0; color: var(--ink-2); }
.card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: auto; padding-top: 24px; }

.schematic { margin: 24px 0 4px; }
.schematic svg { display: block; width: 100%; max-height: 160px; }
.schematic-axis { stroke: var(--ink-3); stroke-width: 1.25; }
.schematic-target { stroke: var(--accent); stroke-width: 1.5; stroke-dasharray: 4 5; }
.schematic-path { fill: none; stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; }
.schematic-dot { fill: var(--accent); }
.schematic-label { fill: var(--ink-2); font-size: 11px; font-weight: 600; }
.schematic-accent { fill: var(--accent-strong); }
.schematic figcaption { color: var(--ink-3); font-size: var(--t-small); }

.page-links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 20px 0 0; padding: 0; list-style: none; }
.page-links a { display: inline-flex; min-height: 36px; align-items: center; color: var(--ink); font-size: 0.9375rem; font-weight: 600; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; text-decoration-color: var(--accent); transition: text-decoration-color 160ms var(--ease-out); }
.page-links a:hover { text-decoration-color: var(--ink); }

.hike-picker { display: inline-flex; margin: 20px 0 16px; border: 2px solid var(--nk); border-radius: var(--radius); }
.hike-picker button { min-height: 40px; padding: 0 16px; border: 0; background: transparent; color: var(--nk-strong); font: inherit; font-size: 0.9375rem; font-weight: 700; font-variant-numeric: tabular-nums; cursor: pointer; transition: background 160ms var(--ease-out), color 160ms var(--ease-out); }
.hike-picker button + button { border-left: 2px solid var(--nk); }
.hike-picker button:hover { background: var(--nk-soft); }
.hike-picker button[aria-pressed="true"] { background: var(--nk); color: #fff; }
.hike-charts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; background: var(--paper); }
.spark { margin: 0; padding: 12px 12px 8px; background: var(--tone); }
.spark figcaption { display: grid; gap: 1px; }
.spark figcaption span { color: var(--ink-2); font-size: var(--t-small); font-weight: 600; }
.spark figcaption strong { font-size: var(--t-lead); font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.spark figcaption small { color: var(--ink-3); font-size: 0.75rem; line-height: 1.3; }
.spark svg { display: block; width: 100%; height: auto; margin-top: 6px; overflow: visible; }
.spark-zero { stroke: var(--ink-3); stroke-width: 1; stroke-dasharray: 3 3; }
.spark-area { fill: var(--nk); opacity: 0.12; }
.spark-line { fill: none; stroke: var(--nk); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.spark-dot { fill: var(--nk); stroke: var(--tone); stroke-width: 2; }
/* Names the sparks' shared time span once, above them, instead of labelling each end. */
.response-span { display: flex; align-items: center; gap: 6px; margin: 0 0 8px; color: var(--ink-3); font-size: var(--t-small); font-weight: 600; }
.hike-headline { min-height: 1.5em; margin: 14px 0 0; font-weight: 600; }
.lab-error { margin: 10px 0 0; color: var(--bad); font-size: var(--t-small); }
.lab-error[hidden] { display: none; }

.more-models-title { margin: clamp(48px, 6vw, 72px) 0 4px; font-size: var(--t-h3); letter-spacing: -0.02em; }
.more-models { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: clamp(20px, 3vw, 40px); margin: 0; padding: 0; list-style: none; }
.more-model { --card-accent: var(--site); display: grid; gap: 6px; height: 100%; padding-top: 12px; border-top: 4px solid var(--card-accent); }
.more-model[data-model-card="intertemporal"] { --card-accent: var(--theme-intertemporal-accent, var(--site)); }
.more-model[data-model-card="portfolio"] { --card-accent: var(--theme-portfolio-accent, var(--site)); }
.more-model-scale { color: var(--ink-3); font-size: var(--t-small); font-weight: 600; }
.more-model-name { font-size: var(--t-lead); font-weight: 700; letter-spacing: -0.015em; }
.more-model-question { color: var(--ink-2); }
.more-model-open { margin-top: 4px; font-weight: 600; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; text-decoration-color: var(--card-accent); }
.roadmap { margin: 32px 0 0; color: var(--ink-3); font-size: var(--t-small); }

/* ---------- Questions: a banded list, not cards ---------- */
.question-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.question { --accent: var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; padding: 16px 20px; background: var(--tone); transition: background 160ms var(--ease-out); }
.question-solow { --accent: var(--solow-strong); }
.question-nk { --accent: var(--nk-strong); }
.question-text { font-size: var(--t-lead); font-weight: 600; letter-spacing: -0.015em; line-height: 1.3; }
.question-page { flex-shrink: 0; color: var(--accent); font-size: 0.9375rem; font-weight: 700; white-space: nowrap; }
.question:hover { background: var(--tone-2); }

/* ---------- How it works ---------- */
/* The three moves run down the body column, each drawing beside its words, so the
   section is as tall as its sticky title deserves rather than three cramped columns. */
.steps { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.step { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); grid-template-rows: auto 1fr; column-gap: clamp(20px, 3vw, 40px); padding: 0 0 clamp(20px, 3vw, 32px); }
.step + .step { padding-top: clamp(20px, 3vw, 32px); border-top: 2px solid var(--tone-2); }
.step .step-art { grid-row: 1 / span 2; }
.step h3 { align-self: end; margin: 0 0 4px; font-size: var(--t-lead); letter-spacing: -0.015em; }
.step p { margin: 0; color: var(--ink-2); }
.step-art { display: grid; align-content: center; justify-items: start; gap: 10px; height: 120px; padding: 16px; background: var(--tone); }
.mock-select, .mock-years { display: inline-flex; align-items: center; gap: 10px; padding: 8px 12px; border: 2px solid var(--ink); border-radius: var(--radius); background: var(--paper); color: var(--ink); font-size: var(--t-small); font-weight: 600; }
.mock-select i, .mock-years i { color: var(--ink-3); font-style: normal; }
.mock-slider { position: relative; width: 100%; height: 6px; background: var(--tone-2); }
.mock-fill { position: absolute; inset: 0 40% 0 0; background: var(--solow); }
.mock-knob { position: absolute; left: 60%; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; border: 3px solid var(--paper); border-radius: 50%; background: var(--solow); }
.mock-caption { color: var(--ink-2); font-size: var(--t-small); }
.mock-caption b { color: var(--ink); }
.mock-chart { width: 100%; height: 56px; }
.mock-chart path { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.mock-chart .mock-chart-base { stroke: var(--ink-3); stroke-width: 2; stroke-dasharray: 4 4; }
.mock-eco { padding: 4px 10px; border-radius: var(--radius); background: var(--ink); color: #fff; font-size: 0.75rem; font-weight: 700; }

/* ---------- Data and sources: a report table and two lists ---------- */
.stats { display: grid; gap: 2px; margin: 0 0 clamp(32px, 5vw, 48px); }
.stats div { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 2px 24px; padding: 16px 20px; background: var(--tone); }
.stats dt { color: var(--ink-2); font-weight: 600; }
.stats dd { margin: 0; font-size: var(--t-h3); font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; text-align: right; }
.stats dd.stat-detail { grid-column: 1 / -1; color: var(--ink-3); font-size: var(--t-small); font-weight: 500; letter-spacing: 0; text-align: left; }
.source-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(24px, 4vw, 48px); }
.source-columns h3 { margin: 0 0 4px; font-size: var(--t-lead); letter-spacing: -0.015em; }
.source-list { margin: 0; padding: 0; list-style: none; }
.source-list li { padding: 10px 0; color: var(--ink-2); font-size: 0.9375rem; line-height: 1.5; }
.source-list strong { color: var(--ink); }
.source-list small { color: var(--ink-3); font-size: var(--t-small); font-weight: 600; white-space: nowrap; }
.source-list small::before { content: "· "; }

/* ---------- Close and footer ---------- */
.closing { max-width: none; margin: clamp(88px, 12vw, 144px) 0 0; padding: clamp(56px, 8vw, 96px) var(--gutter); background: var(--ink); }
.closing h2 { max-width: var(--content); margin: 0 auto; color: #fff; font-size: var(--t-h2); letter-spacing: -0.035em; }
.closing .hero-actions { max-width: var(--content); margin: 28px auto 0; }
.button-on-dark { border-color: rgba(255, 255, 255, 0.5); background: transparent; color: #fff !important; }
.button-on-dark:hover { border-color: #fff; background: rgba(255, 255, 255, 0.08); }
.site-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; max-width: var(--content); margin: 0 auto; padding: 32px var(--gutter) 48px; color: var(--ink-3); font-size: var(--t-small); }
.site-footer p { margin: 0; max-width: 60em; }
.site-footer a, .footer-print { color: var(--ink-2); text-decoration: underline; text-underline-offset: 4px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
/* The rights notice sits on its own line under the footer's text and links. */
.site-footer .footer-rights { flex-basis: 100%; color: var(--ink-3); }
.footer-print { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.footer-print:hover, .site-footer a:hover { color: var(--ink); }

/* ---------- Motion: charts draw in (site-charts.js); nothing else moves on its own ---------- */
@media (prefers-reduced-motion: reduce) {
    .golden-chart .chosen, .button, .button span, .question, .page-links a, .site-bar-links a, .hike-picker button { transition: none; }
}

/* ---------- Narrow screens ---------- */
@media (max-width: 960px) {
    .hero { grid-template-columns: 1fr; }
    .model-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
    .source-columns { grid-template-columns: 1fr; }
    .step { grid-template-columns: 1fr; grid-template-rows: none; }
    .step .step-art { grid-row: auto; margin-bottom: 14px; }
    .question { min-height: 60px; padding: 14px 16px; }
    .question-page { display: none; }
    .hike-charts { gap: 2px; }
    .spark { padding: 10px 8px 6px; }
    .spark figcaption strong { font-size: var(--t-body); }
    .spark figcaption small { display: none; }
}
@media (max-width: 560px) {
    .golden-chart .tick, .golden-chart .golden-rule-label, .golden-chart .today-label { font-size: 15px; }
    .golden-chart .axis-title { font-size: 14px; }
}
@media (max-width: 420px) {
    .hike-charts { grid-template-columns: 1fr; }
    .spark figcaption { grid-template-columns: 1fr auto; align-items: baseline; }
    .spark figcaption small { display: block; grid-column: 1 / -1; }
    .golden-readout dd { font-size: var(--t-lead); }
}

/* Large figures use the face's proportional digits: its tabular "1" carries serifs
   that read as a typewriter at display size. Axis ticks keep tabular digits. */
.golden-readout dd, .golden-control output, .proof strong, .spark figcaption strong, .stats dd,
.live-readout dd, .experiment-readout dd, .experiment-controls output, .term-values dd, .assumption-grid dd { font-variant-numeric: proportional-nums lining-nums; }

/* ---------- Print: a handout (footer button "Print as a handout") ----------
   Keeps the argument (title, lesson, charts as last drawn, key ideas, sources) and
   drops what only works on screen: the masthead, buttons, pickers, and the close. */
@media print {
    @page { margin: 16mm 14mm; }
    .landing { --t-display: 2.6rem; --t-h2: 1.7rem; --t-h3: 1.3rem; --t-lead: 1.1rem; --t-body: 0.95rem; font-size: 10.5pt; }
    .site-bar, .skip-link, .hero-actions, .closing, .site-footer nav, .country-picker, .shock-picker, .hike-picker,
    .golden-control input, .experiment-controls input, .card-actions, .text-link, .page-links, .chart-message { display: none !important; }
    .hero, .section { display: block; padding-top: 18pt; }
    .section > .section-head { position: static; margin-bottom: 8pt; }
    .golden-card, .live-card, .experiment-card, .response-card, .equation-card, figure, .golden-readout, .live-readout, .concept, .lab-page, .assumption-grid div { break-inside: avoid; }
    .golden-readout div, .live-readout div, .experiment-readout div, .stats div, .question, .lab-page, .assumption-grid div, .term-values div, .spark, .equation-card code, .equation-math { background: none; padding-left: 0; }
    .lab-page-arrow, .arrow { display: none; }
    a { text-decoration: none !important; }
    .site-footer { padding-top: 12pt; }
}

/* Page shown for a wrong address or a failed page request (templates/error.html):
   the masthead's ink rule, a headline, one way out, and the status code as a source line. */
.error-page { max-width: 36rem; margin: 14vh auto 64px; padding: 28px var(--gutter) 0; border-top: 3px solid var(--ink); }
.error-page h1 { margin: 0 0 12px; font-size: var(--t-h3); letter-spacing: -0.02em; }
.error-page p { margin: 0 0 24px; color: var(--ink-2); }
.error-page .error-code { margin: 24px 0 0; color: var(--ink-3); font-size: var(--t-small); }
