/* andyhendricks.net — style-v2.css
   Sheet chrome (tabs, formula bar, row gutter, column letters) frames indexes and
   metadata. Reading columns stay plain prose. Light only.
   Sections: 1 tokens · 2 base · 3 chrome · 4 sheet index · 5 home · 6 article
   · 7 data ranges · 8 legacy article components · 9 legacy SVG remap
   · 10 pages (about, contact, guides) · 11 narrow screens */

/* ---------- 1. Tokens ---------- */
:root {
  color-scheme: light;
  --paper: #ffffff;
  --ink: #16181d;
  --ink-2: #3a3f4b;
  --ink-3: #5b6170;
  --grid: #dfe1e6;
  --line: #c9ccd3;
  --chrome: #f3f4f6;
  --bar: #fafafb;
  --select: #3d3bf3;
  --select-soft: #e6e6fd;
  --link: #2d2bd6;
  --link-hover: #16148f;
  --flag: #fff1a8;
  --note: #fffbe6;
  --bar-muted: #b9bcc6;
  --bar-light: #d3d6dd;
  --bar-mid: #9aa0ad;

  /* Aliases for inline styles in older articles. Keep until every page is migrated. */
  --ink-muted: var(--ink-3);
  --ink-faint: var(--ink-3);
  --rule: var(--grid);
  --paper-raised: var(--paper);
  --signal: var(--select);
  --signal-dim: var(--select-soft);
  --tag-cool: var(--ink-2);
  --tag-cool-bg: var(--chrome);

  --f-display: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --f-ui: "Arimo", Arial, "Helvetica Neue", sans-serif;
  --f-read: "Source Serif 4", Georgia, "Times New Roman", serif;

  --gutter-col: 44px;
  --col-a: 120px;
  --col-c: 136px;
  --col-d: 112px;
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-ui);
  font-size: 15px;
  line-height: 1.5;
}
a { color: var(--link); }
a:hover { color: var(--link-hover); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--select); outline-offset: 2px;
}
img { max-width: 100%; height: auto; }
.num { font-variant-numeric: tabular-nums; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Side gutter. .wrap and .wrap-narrow keep their old meaning for legacy page bodies. */
.gutter { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.wrap { max-width: 1120px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.wrap-narrow { max-width: 760px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }

/* ---------- 3. Chrome ---------- */
.site-header {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
  gap: 12px; padding-block: 16px;
}
.wordmark {
  font-family: var(--f-display); font-weight: 800; font-size: 20px; letter-spacing: -0.01em;
  color: var(--ink); text-decoration: none;
}
.header-right { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.header-right .tagline { color: var(--ink-3); }
.btn {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px;
  background: var(--ink); color: var(--paper); text-decoration: none;
  border: 0; font: inherit; font-weight: 700; cursor: pointer;
}
.btn:hover { color: var(--paper); background: var(--ink-2); }

.tabs {
  display: flex; overflow-x: auto; white-space: nowrap; scrollbar-width: none;
  border-bottom: 1px solid var(--line);
}
.tabs a {
  padding: 12px 18px; color: var(--ink-2); text-decoration: none;
  border: 1px solid transparent; border-bottom: 0; margin-bottom: -1px;
}
.tabs a:hover { color: var(--ink); background: var(--chrome); }
.tabs a[aria-current="page"], .tabs a.active {
  color: var(--ink); font-weight: 700; background: var(--paper);
  border-color: var(--line); box-shadow: inset 0 3px 0 var(--select);
}

/* Formula bar: shows the page's key finding. Leave it out on pages without one. */
.fx { display: flex; align-items: stretch; background: var(--bar); border-bottom: 1px solid var(--grid); }
.fx-ref {
  flex: none; width: 56px; padding: 10px 0; text-align: center;
  border-right: 1px solid var(--grid); color: var(--ink-3); font-weight: 700;
}
.fx-val { flex: 1; min-width: 0; padding: 10px 14px; }

.site-footer {
  border-top: 1px solid var(--line); padding-block: 20px 32px; margin-top: 48px;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px;
  font-size: 14px; color: var(--ink-3);
}
.site-footer nav { display: flex; gap: 20px; }

/* ---------- 4. Sheet index (home, articles, guides) ---------- */
.colhead, .row {
  display: grid;
  grid-template-columns: var(--gutter-col) var(--col-a) minmax(0, 1fr) var(--col-c) var(--col-d);
}
.colhead > span {
  height: 26px; line-height: 26px; text-align: center; font-size: 12px; color: var(--ink-3);
  background: var(--chrome); border-right: 1px solid var(--grid); border-bottom: 1px solid var(--grid);
}
.colhead > span:last-child { border-right: 0; }
.colhead > span.on { background: var(--select-soft); color: var(--ink); font-weight: 700; }
.rownum {
  background: var(--chrome); border-right: 1px solid var(--grid); border-bottom: 1px solid var(--grid);
  color: var(--ink-3); font-size: 12px; text-align: center; padding-top: 14px;
}
.row.is-selected .rownum { background: var(--select-soft); color: var(--ink); font-weight: 700; }
.row.head > div { padding: 10px 8px; font-weight: 700; border-bottom: 2px solid var(--ink); }
.row.head > .rownum { padding-top: 10px; }
.row:not(.head) > .cell { padding: 14px 8px; border-right: 1px solid var(--grid); border-bottom: 1px solid var(--grid); }
.row > .cell:last-child { border-right: 0; }
.row .title-cell a { color: var(--ink); text-decoration: none; font-size: 16px; }
.row .title-cell a:hover { text-decoration: underline; }
.row.is-selected .title-cell { outline: 2px solid var(--select); outline-offset: -2px; }
.row.is-selected .title-cell a { font-weight: 700; color: var(--link); }
.row .span-rest { grid-column: 3 / -1; }
.row .title-cell a.all-link { color: var(--link); font-weight: 700; }
.row .meta-line { display: none; }
.row .dek { color: var(--ink-3); font-size: 14px; margin: 4px 0 0; }
.kind-finding { background: var(--flag); }
.kind-framework, .kind-guide { background: var(--select-soft); }
.formula { color: var(--ink-3); font-style: italic; }

/* Sort and filter controls for the articles index */
.sheet-tools { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 20px; padding-block: 16px; }
.sheet-tools .field { display: flex; flex-direction: column; gap: 6px; }
.sheet-tools label { font-size: 13px; font-weight: 700; }
.sheet-tools select, .sheet-tools input {
  height: 44px; padding: 0 10px; font: inherit; color: var(--ink);
  background: var(--paper); border: 1px solid var(--line); border-radius: 0;
}
.sheet-tools .count { color: var(--ink-3); font-size: 14px; padding-bottom: 12px; }
.colhead button {
  all: unset; display: block; width: 100%; cursor: pointer;
}

/* ---------- 5. Home ---------- */
.merged { grid-column: 2 / -1; border-bottom: 1px solid var(--grid); padding: 40px 24px 36px; position: relative; }
.merged::after { /* cell comment marker */
  content: ""; position: absolute; top: 0; right: 0;
  border-top: 12px solid var(--select); border-left: 12px solid transparent;
}
.merged.hero {
  display: flex; flex-wrap: wrap-reverse; align-items: flex-end; justify-content: space-between; gap: 24px 40px;
}
.hero-title {
  margin: 0; max-width: 820px; flex: 1 1 420px; min-width: 0;
  font-family: var(--f-display); font-weight: 800; letter-spacing: -0.02em;
  font-size: clamp(32px, 4.6vw, 52px); line-height: 1.05; text-wrap: balance;
}
.hero-photo { flex: 0 0 auto; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.hero-photo img {
  display: block; width: 200px; height: 200px; max-width: 100%; object-fit: cover;
  outline: 2px solid var(--select); outline-offset: -2px; background: var(--chrome);
}
.hero-photo figcaption { font-size: 12px; color: var(--ink-3); }

.home-body { display: flex; flex-wrap: wrap; align-items: flex-start; }
.home-sheet { flex: 999 1 640px; min-width: 0; }
.home-side { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 24px; padding: 24px; }

.chart-obj { position: relative; margin: 0; border: 1px solid var(--line); padding: 18px; background: var(--paper); }
.chart-obj .h { font-family: var(--f-display); font-weight: 700; font-size: 16px; line-height: 1.3; }
.chart-obj .sub { font-size: 12px; color: var(--ink-3); padding: 4px 0 16px; }
.handle { position: absolute; width: 7px; height: 7px; background: var(--select); }
.handle.tl { top: -4px; left: -4px; } .handle.tr { top: -4px; right: -4px; }
.handle.bl { bottom: -4px; left: -4px; } .handle.br { bottom: -4px; right: -4px; }
.bars { display: grid; grid-template-columns: 96px minmax(0, 1fr); row-gap: 10px; column-gap: 10px; align-items: center; font-size: 13px; }
.bars .track { display: flex; align-items: center; gap: 6px; font-variant-numeric: tabular-nums; }
.bars .fill { height: 20px; background: var(--bar-muted); }
.bars .fill.hot { background: var(--select); }
.bars .hot-label { font-weight: 700; }

.copy-btn {
  background: none; border: 0; padding: 10px 0 0; min-height: 44px;
  font: inherit; font-size: 14px; font-weight: 700; color: var(--link); cursor: pointer;
}
.copy-btn:hover { color: var(--link-hover); text-decoration: underline; }

.note { border: 1px solid var(--line); background: var(--note); padding: 16px; font-size: 15px; line-height: 1.55; }
.note .note-h { font-weight: 700; padding-bottom: 6px; }
.note p { margin: 0; }

/* ---------- 6. Article and guide pages ---------- */
.art { max-width: 1120px; margin: 0 auto; padding-block: 40px 24px; }
.crumb { font-size: 14px; color: var(--ink-3); }
.art-title {
  margin: 14px 0 24px; max-width: 900px;
  font-family: var(--f-display); font-weight: 800; letter-spacing: -0.02em;
  font-size: clamp(30px, 4.2vw, 46px); line-height: 1.08; text-wrap: balance;
}
.meta-range { overflow-x: auto; max-width: 900px; }
.meta-range dl {
  margin: 0; min-width: 560px; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr);
  border: 1px solid var(--line);
}
.meta-range dl > div { border-right: 1px solid var(--grid); }
.meta-range dl > div:last-child { border-right: 0; }
.meta-range dt { background: var(--chrome); padding: 6px 10px; font-size: 12px; color: var(--ink-3); border-bottom: 1px solid var(--grid); }
.meta-range dd { margin: 0; padding: 10px; font-weight: 700; }

/* Hero chart or image, placed after the metadata range */
.article-hero { margin: 32px 0 0; max-width: 900px; border: 1px solid var(--line); background: var(--paper); }
.article-hero svg { display: block; width: 100%; height: auto; }
.article-hero img { display: block; width: 100%; max-height: 440px; object-fit: cover; }
.article-hero.is-photo { border: 0; }

.art-body { display: flex; flex-wrap: wrap; gap: 48px; padding-top: 40px; align-items: flex-start; }
.prose {
  flex: 999 1 600px; min-width: 0; max-width: 680px;
  font-family: var(--f-read); font-size: 19px; line-height: 1.68; color: var(--ink);
}
.prose > *, .prose > article > * { margin-top: 0; margin-bottom: 1.1em; }
.prose > article { margin-bottom: 0; }
.prose p, .prose li { font-size: inherit; line-height: inherit; color: inherit; }
.prose h2 {
  font-family: var(--f-display); font-weight: 800; font-size: 28px; line-height: 1.2;
  letter-spacing: -0.01em; margin: 1.8em 0 0.6em; text-wrap: balance;
}
.prose h3 { font-family: var(--f-display); font-weight: 700; font-size: 20px; line-height: 1.3; margin: 1.4em 0 0.4em; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose li { margin-bottom: 0.6em; }
.prose li::marker { font-family: var(--f-ui); font-weight: 700; color: var(--ink-3); }
.prose strong { font-weight: 600; }
.prose figure { margin: 1.6em 0; }
.prose figure img { display: block; border: 1px solid var(--line); }
.prose figcaption { font-family: var(--f-ui); font-size: 13px; color: var(--ink-3); margin-top: 8px; }
.prose blockquote {
  margin: 1.6em 0; padding: 14px 18px; background: var(--chrome);
  font-size: 17px; color: var(--ink-2);
}
.prose blockquote p:last-child { margin-bottom: 0; }
.prose pre {
  background: var(--bar); color: var(--ink); border: 1px solid var(--line);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; line-height: 1.6;
  padding: 16px 18px; overflow-x: auto;
}
.prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.82em;
  background: var(--chrome); padding: 1px 5px;
}
.prose pre code { background: none; padding: 0; font-size: inherit; }
.prose .note { font-family: var(--f-ui); margin-bottom: 2em; }
.prose .note ul { margin: 0; padding-left: 1.2em; }
.prose .note li { margin-bottom: 0.5em; font-size: 15px; line-height: 1.55; }

.side {
  flex: 1 1 260px; min-width: 0; display: flex; flex-direction: column; gap: 16px;
  position: sticky; top: 16px;
}
.side .box { border: 1px solid var(--line); padding: 16px; font-size: 14px; line-height: 1.55; }
.side .box-h { font-weight: 700; padding-bottom: 6px; }
.side .box a { display: block; padding: 5px 0; }
.side .box p { margin: 0; }

/* ---------- 7. Data ranges ---------- */
.range { font-family: var(--f-ui); font-size: 15px; line-height: 1.45; margin: 1.6em 0; }
.range-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; }
.range-top .cap { font-weight: 700; }
.range-top .copy-btn { padding: 0; min-height: 32px; }
.prose .range .table-wrap { margin: 0; }
.prose .range + .table-note { margin-top: -0.8em; }
.range-scroll { overflow-x: auto; }
.range table { min-width: 520px; }
.range table.fit { min-width: 0; }
.range-foot { font-size: 13px; color: var(--ink-3); padding-top: 6px; }

/* Every table in an article reads as a sheet range, including legacy .table-wrap tables */
.prose table, .range table {
  width: 100%; border-collapse: collapse; border: 1px solid var(--line);
  font-family: var(--f-ui); font-size: 15px; line-height: 1.45;
}
.prose th, .prose td {
  padding: 8px 10px; border-right: 1px solid var(--grid); border-bottom: 1px solid var(--grid);
  text-align: left; vertical-align: top; color: var(--ink);
  text-transform: none; letter-spacing: 0; white-space: normal;
}
.prose th { font-weight: 700; font-size: 15px; border-bottom: 2px solid var(--ink); }
.prose th:last-child, .prose td:last-child { border-right: 0; }
.prose td.r, .prose th.r { text-align: right; font-variant-numeric: tabular-nums; }
.prose .rn { width: 40px; background: var(--chrome); color: var(--ink-3); font-size: 12px; text-align: center; font-weight: 400; }
.prose tr.hot td:not(.rn) { background: var(--flag); font-weight: 700; }
.prose .bar-cell { width: 34%; }
.prose .bar-cell span { display: block; height: 14px; background: var(--bar-muted); margin-top: 3px; }
.prose tr.hot .bar-cell span { background: var(--select); }

/* Legacy tables: numeric columns carry class="r" (added by migrate.py) and right-align */
.prose .table-wrap { overflow-x: auto; margin: 1.6em 0 0.4em; }
.prose .table-wrap table.wrap-text { table-layout: fixed; }
.prose col.rn-col { width: 40px; }
/* Text tables read left to right; only number tables right-align */
.prose .table-wrap table.wrap-text td:not(.r):not(.rn), .prose .table-wrap table.wrap-text th:not(.r):not(.rn) { text-align: left; }
.prose .table-note, .prose .chart-caption { font-family: var(--f-ui); font-size: 13px; color: var(--ink-3); margin-bottom: 1.6em; }

/* ---------- 8. Legacy article components ---------- */
/* Key takeaways box becomes a cell note */
.prose .guide-start { border: 1px solid var(--line); background: var(--note); padding: 16px 18px; margin-bottom: 2em; font-family: var(--f-ui); }
.prose .guide-start p.label, .guide-start .label {
  font-family: var(--f-ui); font-size: 15px; font-weight: 700; text-transform: none; letter-spacing: 0;
  color: var(--ink); margin: 0 0 8px;
}
.prose .guide-start ul, .prose .guide-start ol { margin: 0; padding-left: 1.2em; }
.prose .guide-start li { font-size: 15px; line-height: 1.55; margin-bottom: 0.5em; }
.prose .guide-start p:not(.label) { font-size: 15px; line-height: 1.55; }

/* Pullquote becomes a ruled statement in the display face */
.prose .pullquote {
  font-family: var(--f-display); font-style: normal; font-weight: 700; font-size: 24px; line-height: 1.3;
  color: var(--ink); border: 0; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--grid);
  padding: 14px 0; margin: 1.8em 0;
}

/* Single stat and stat trio become metadata ranges */
.prose .stat-callout, .prose .stat-trio {
  display: flex; flex-wrap: wrap; gap: 0; border: 1px solid var(--line); padding: 0; margin: 1.6em 0;
  font-family: var(--f-ui); background: var(--paper);
}
.prose .stat-callout { align-items: stretch; }
.prose .stat-callout .stat-num, .prose .stat-trio .stat-item .num {
  font-family: var(--f-ui); font-weight: 700; color: var(--select); line-height: 1; letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}
.prose .stat-callout .stat-num { font-size: 44px; padding: 16px 18px; background: var(--flag); border-right: 1px solid var(--grid); white-space: nowrap; }
.prose .stat-callout .stat-desc { flex: 1 1 240px; padding: 16px 18px; font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.prose .stat-trio .stat-item { flex: 1 1 160px; text-align: left; border-right: 1px solid var(--grid); display: flex; flex-direction: column-reverse; }
.prose .stat-trio .stat-item:last-child { border-right: 0; }
.prose .stat-trio .stat-item .num { font-size: 30px; display: block; padding: 12px 12px 14px; margin: 0; }
.prose .stat-trio .stat-item .label {
  display: block; background: var(--chrome); border-bottom: 1px solid var(--grid); padding: 6px 12px;
  font-family: var(--f-ui); font-size: 12px; color: var(--ink-3); letter-spacing: 0; text-transform: none;
}

/* Formula box becomes a formula bar */
.prose .formula-box {
  position: relative; background: var(--bar); color: var(--ink); border: 1px solid var(--line);
  padding: 12px 14px 12px 62px; font-family: var(--f-ui); font-size: 16px; line-height: 1.5;
}
.prose .formula-box::before {
  content: "fx"; position: absolute; top: 0; bottom: 0; left: 0; width: 48px;
  display: flex; align-items: center; justify-content: center;
  border-right: 1px solid var(--grid); color: var(--ink-3); font-style: italic;
}

/* Chart figures become chart objects */
.prose .chart-figure { border: 1px solid var(--line); background: var(--paper); padding: 16px; margin: 1.6em 0 0.4em; }
.prose .chart-figure svg { display: block; width: 100%; height: auto; }
.prose .chart-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; font-family: var(--f-ui); font-size: 13px; color: var(--ink-2); margin-bottom: 8px; }
.prose .chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.prose .chart-legend .swatch { width: 12px; height: 12px; display: inline-block; border-radius: 0; }

/* Legacy inline swatch colors */
.swatch[style*="D6572E" i] { background: var(--select) !important; }
.swatch[style*="5C6B60" i] { background: var(--ink-2) !important; }

/* FAQ block becomes plain question and answer pairs */
.prose .faq { border-top: 2px solid var(--ink); padding-top: 8px; margin-top: 2.4em; }
.prose .faq-eyebrow { display: none; }
.prose .faq h2 { margin-top: 0.6em; }
.prose .faq-list { display: flex; flex-direction: column; gap: 0; }
.prose .faq-item { padding: 14px 0; border-bottom: 1px solid var(--grid); }
.prose .faq-item:last-child { border-bottom: 0; }
.prose .faq-item .q { font-family: var(--f-display); font-weight: 700; font-size: 19px; line-height: 1.35; margin: 0 0 6px; }
.prose .faq-item .a { font-size: 18px; line-height: 1.6; color: var(--ink-2); margin: 0; }

/* Guide link lists become sheet rows */
.guide-links { list-style: none; margin: 0 0 2em; padding: 0; border-top: 2px solid var(--ink); }
.guide-links li { padding: 14px 0; border-bottom: 1px solid var(--grid); margin: 0; }
.guide-links a.link-title { font-family: var(--f-display); font-weight: 700; font-size: 19px; color: var(--link); text-decoration: none; }
.guide-links a.link-title:hover { text-decoration: underline; }
.guide-links p.link-desc { font-family: var(--f-ui); font-size: 15px; line-height: 1.5; color: var(--ink-3); margin: 4px 0 0; }
.guide-eyebrow { font-family: var(--f-ui); font-size: 14px; font-weight: 700; color: var(--ink-3); text-transform: none; letter-spacing: 0; }
.guide-intro { font-size: inherit; line-height: inherit; }
.guide-section-intro { font-family: var(--f-ui); font-size: 16px; line-height: 1.6; color: var(--ink-3); }

/* Old tags and bylines, if any page still carries them */
.tag { display: inline-block; font-family: var(--f-ui); font-size: 13px; padding: 1px 6px; background: var(--chrome); color: var(--ink-2); border-radius: 0; }
.tag.signal { background: var(--select-soft); color: var(--ink); }

/* ---------- 9. Legacy SVG remap ---------- */
/* Older charts hardcode the coral palette and old fonts as SVG attributes.
   CSS overrides presentation attributes, so these rules recolor them in place. */
.article-hero svg text, .prose svg text, .chart-obj svg text { font-family: var(--f-ui); }
.article-hero svg text[font-family^="Fraunces"], .prose svg text[font-family^="Fraunces"] { font-family: var(--f-display); font-weight: 800; }
svg [fill="#D6572E" i] { fill: var(--select); }
svg [stroke="#D6572E" i] { stroke: var(--select); }
svg [fill="#B8420F" i] { fill: var(--link-hover); }
svg [stroke="#B8420F" i] { stroke: var(--link-hover); }
svg [fill="#FBEBE4" i] { fill: var(--select-soft); }
svg [stroke="#FBEBE4" i] { stroke: var(--select-soft); }
svg [fill="#232323" i] { fill: var(--ink); }
svg [stroke="#232323" i] { stroke: var(--ink); }
svg [fill="#6B6B66" i] { fill: var(--ink-3); }
svg [stroke="#6B6B66" i] { stroke: var(--ink-3); }
svg [fill="#9C9B93" i] { fill: var(--bar-mid); }
svg text[fill="#9C9B93" i] { fill: var(--ink-3); }
svg [stroke="#9C9B93" i] { stroke: var(--bar-mid); }
svg [fill="#E1DFD5" i] { fill: var(--grid); }
svg [stroke="#E1DFD5" i] { stroke: var(--grid); }
svg [fill="#5C6B60" i] { fill: var(--ink-2); }
svg [stroke="#5C6B60" i] { stroke: var(--ink-2); }
svg [fill="#C9C7BF" i] { fill: var(--bar-light); }
svg [fill="#B3B1A8" i] { fill: var(--bar-muted); }
svg [fill="#F5F4F2" i] { fill: var(--chrome); }

/* ---------- 10. Pages ---------- */
.page { max-width: 1120px; margin: 0 auto; padding-block: 40px 24px; }
.page-title {
  margin: 0 0 16px; font-family: var(--f-display); font-weight: 800; letter-spacing: -0.02em;
  font-size: clamp(30px, 4.2vw, 46px); line-height: 1.08; text-wrap: balance;
}
.page-head { padding-block: 40px 8px; }
.page-head .page-lead { margin-bottom: 16px; }
.page-lead { font-size: 18px; line-height: 1.6; color: var(--ink-2); max-width: 640px; margin: 0 0 32px; }

.about-grid { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; }
.about-grid .hero-photo img { width: 240px; height: 240px; }
.about-grid .prose { flex: 1 1 420px; }

.form { max-width: 520px; display: flex; flex-direction: column; gap: 20px; }
.form .field { display: flex; flex-direction: column; gap: 6px; }
.form label { font-size: 14px; font-weight: 700; color: var(--ink); text-transform: none; letter-spacing: 0; }
.form input, .form textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--paper);
  border: 1px solid var(--line); border-radius: 0; padding: 11px 12px; min-height: 44px;
}
.form input:focus, .form textarea:focus { outline: 2px solid var(--select); outline-offset: -2px; border-color: var(--select); }
.form textarea { min-height: 160px; resize: vertical; }
.form .btn { align-self: flex-start; }

/* ---------- 11. Narrow screens ---------- */
@media (max-width: 760px) {
  .header-right .tagline { display: none; }
  .colhead { display: none; }
  .row { grid-template-columns: var(--gutter-col) minmax(0, 1fr); }
  .row.head .cell:not(.title-col) { display: none; }
  .row:not(.head) > .cell:not(.title-cell) { display: none; }
  .row .title-cell { border-right: 0; }
  .row .span-rest { grid-column: 2 / -1; }
  .row .meta-line { display: block; font-size: 13px; color: var(--ink-2); padding-bottom: 4px; }
  .row .meta-line .kind { padding: 1px 4px; }
  .merged { grid-column: 2 / -1; padding: 28px 16px 24px; }
  .merged.hero { flex-direction: column-reverse; align-items: flex-start; flex-wrap: nowrap; gap: 18px; }
  .merged.hero .hero-title { flex: none; }
  .hero-photo img { width: 120px; height: 120px; }
  .about-grid .hero-photo img { width: 160px; height: 160px; }
  .home-side { padding: 24px 16px; }
  .side { position: static; }
  .prose { font-size: 18px; }
  .prose .stat-callout .stat-num { font-size: 36px; }
  .meta-range { overflow: visible; }
  .meta-range dl { min-width: 0; grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meta-range dl > div { border-bottom: 1px solid var(--grid); }
  .meta-range dl > div:nth-child(2n) { border-right: 0; }
  .meta-range dl > div:nth-last-child(-n+2):nth-child(2n+1),
  .meta-range dl > div:nth-last-child(1) { border-bottom: 0; }
}
@media print {
  .tabs, .fx, .side, .copy-btn, .site-header .btn { display: none; }
}
