/* The Sourcing Herald — public site */
@font-face { font-family: 'Newsreader'; src: url('/fonts/newsreader/newsreader-latin-opsz-normal.woff2') format('woff2-variations'); font-weight: 200 800; font-style: normal; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url('/fonts/newsreader/newsreader-latin-opsz-italic.woff2') format('woff2-variations'); font-weight: 200 800; font-style: italic; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url('/fonts/newsreader/newsreader-latin-ext-opsz-normal.woff2') format('woff2-variations'); font-weight: 200 800; font-style: normal; font-display: swap; unicode-range: U+0100-024F, U+1E00-1EFF; }
@font-face { font-family: 'Plex'; src: url('/fonts/plex/ibm-plex-sans-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Plex'; src: url('/fonts/plex/ibm-plex-sans-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Plex'; src: url('/fonts/plex/ibm-plex-sans-latin-600-normal.woff2') format('woff2'); font-weight: 600; font-display: swap; }

:root {
  --paper: #fbfaf6;
  --paper-2: #f3f0e7;
  --ink: #161512;
  --ink-2: #3a3832;
  --muted: #5b574e;
  --rule: #161512;
  --hair: #d9d4c7;
  --accent: #1f5e4a;
  --accent-ink: #164536;
  --note: #f4ead0;
  --serif: 'Newsreader', 'Iowan Old Style', Georgia, serif;
  --sans: 'Plex', 'IBM Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --wrap: 1240px;
  --gutter: clamp(16px, 3vw, 32px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--serif); font-size: 18px; line-height: 1.5; font-optical-sizing: auto; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.15em; }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; font-family: var(--sans); z-index: 10; }
.skip:focus { left: 8px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Masthead ---------- */
.dateline { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0 0; font-family: var(--sans); font-size: 13px; color: var(--muted); }
.masthead { text-align: center; padding: 18px 0 14px; }
.masthead a { text-decoration: none; color: var(--ink); }
.masthead .name { display: block; font-family: var(--serif); font-weight: 700; font-variation-settings: 'opsz' 72; font-size: clamp(38px, 8.4vw, 92px); line-height: 0.95; letter-spacing: -0.025em; }
.masthead .tag { display: block; margin-top: 10px; font-style: italic; font-size: clamp(15px, 1.6vw, 18px); color: var(--ink-2); }
.double-rule { border: 0; border-top: 3px solid var(--rule); margin: 0; position: relative; height: 5px; border-bottom: 1px solid var(--rule); }

.sitenav .wrap { display: flex; align-items: center; gap: 24px; }
.sitenav .wrap > ul, .sitenav .wrap > form { border-bottom: 1px solid var(--rule); align-self: stretch; display: flex; align-items: center; }
.sitenav .wrap { gap: 0; }
.sitenav .wrap > form { padding-left: 24px; }
.sitenav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 28px; overflow-x: auto; scrollbar-width: none; flex: 1; }
.sitenav ul::-webkit-scrollbar { display: none; }
.sitenav li a { display: inline-block; padding: 13px 0 11px; font-family: var(--sans); font-weight: 500; font-size: 15px; text-decoration: none; white-space: nowrap; border-bottom: 3px solid transparent; }
.sitenav li a[aria-current='page'] { border-bottom-color: var(--accent); color: var(--accent-ink); }
.search-form { display: flex; align-items: center; border-bottom: 1px solid var(--ink); }
.search-form input { border: 0; background: transparent; font: 15px var(--sans); padding: 6px 4px; width: 190px; color: var(--ink); }
.search-form input::placeholder { color: var(--muted); }
.search-form button { border: 0; background: none; padding: 6px; cursor: pointer; color: var(--ink); }
.search-form svg { width: 18px; height: 18px; display: block; }

.sample-banner { background: var(--note); border-bottom: 1px solid #e2d3a6; font-family: var(--sans); font-size: 14px; }
.sample-banner .wrap { padding-top: 9px; padding-bottom: 9px; }

/* ---------- Shared story elements ---------- */
.kicker { display: inline-block; font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--accent); text-decoration: none; margin-bottom: 6px; }
.kicker:hover { text-decoration: underline; }
.headline { font-family: var(--serif); font-weight: 600; line-height: 1.12; letter-spacing: -0.01em; margin: 0; font-variation-settings: 'opsz' 36; text-wrap: balance; }
.headline a { text-decoration: none; }
.headline a:hover { text-decoration: underline; text-decoration-thickness: 1px; color: var(--ink); }
.dek { color: var(--ink-2); margin: 8px 0 0; }
.meta { font-family: var(--sans); font-size: 13px; color: var(--muted); margin-top: 10px; display: flex; flex-wrap: wrap; gap: 4px 14px; }
.sample-tag { font-family: var(--sans); font-size: 12px; background: var(--note); padding: 1px 6px; color: #5c4a14; }
figure { margin: 0; }
.media { background: var(--paper-2); }
.media img { width: 100%; }

/* ---------- Homepage ---------- */
.front { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: 0 40px; padding: 26px 0 8px; }
.lead .headline { font-size: clamp(30px, 4.2vw, 50px); font-variation-settings: 'opsz' 60; margin-top: 4px; max-width: 18em; }
.lead .dek { font-size: 20px; max-width: 46em; }
.lead .media { margin-top: 20px; }
.supporting { border-left: 1px solid var(--hair); padding-left: 32px; display: flex; flex-direction: column; }
.supporting .story { padding: 0 0 20px; margin-bottom: 20px; border-bottom: 1px solid var(--hair); }
.supporting .story:last-child { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.supporting .story:first-child .media { margin-bottom: 14px; }
.supporting .headline { font-size: 22px; }
.supporting .dek { font-size: 16px; }

.band-title { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; border-top: 3px solid var(--rule); padding-top: 10px; margin: 36px 0 20px; }
.band-title h2 { font-family: var(--serif); font-style: italic; font-weight: 600; font-size: clamp(26px, 3vw, 34px); margin: 0; font-variation-settings: 'opsz' 48; }
.band-title a { font-family: var(--sans); font-size: 14px; font-weight: 500; }

.latest-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px 48px; }
.latest-grid .story, .related-grid .story { position: relative; }
.latest-grid .story + .story::before, .related-grid .story + .story::before { content: ""; position: absolute; left: -24px; top: 0; bottom: 0; border-left: 1px solid var(--hair); }
.latest-grid .media { margin-bottom: 12px; }
.latest-grid .headline { font-size: 19px; }

.section-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 3fr) minmax(0, 3fr); gap: 0 32px; padding-bottom: 8px; }
.section-grid .main .media { margin-bottom: 14px; }
.section-grid .main .headline { font-size: 28px; }
.section-grid .col { border-left: 1px solid var(--hair); padding-left: 28px; }
.section-grid .col .story { padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--hair); }
.section-grid .col .story:last-child { border-bottom: 0; }
.section-grid .col .headline { font-size: 19px; }
.section-grid .col .media { margin-bottom: 10px; }

.empty-front { padding: 64px 0; text-align: center; color: var(--muted); }

/* ---------- Category & search lists ---------- */
.page-head { padding: 30px 0 18px; border-bottom: 1px solid var(--rule); }
.page-head h1 { font-family: var(--serif); font-size: clamp(36px, 5vw, 56px); font-variation-settings: 'opsz' 60; margin: 0; letter-spacing: -0.015em; line-height: 1.05; }
.page-head p { margin: 8px 0 0; color: var(--ink-2); max-width: 44em; }
.river { list-style: none; margin: 0; padding: 0; }
.river li { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 28px; padding: 24px 0; border-bottom: 1px solid var(--hair); }
.river .headline { font-size: 25px; }
.river .dek { font-size: 17px; }
.river .media { order: 2; }
.pagination { display: flex; justify-content: space-between; align-items: center; padding: 24px 0 8px; font-family: var(--sans); font-size: 15px; }
.pagination a { font-weight: 500; }
.pagination .off { color: var(--hair); }
.search-page-form { display: flex; gap: 10px; margin: 18px 0 0; max-width: 560px; }
.search-page-form input { flex: 1; font: 18px var(--sans); padding: 10px 12px; border: 1px solid var(--ink); background: #fff; }
.search-page-form button, .button { font: 500 15px var(--sans); background: var(--ink); color: var(--paper); border: 0; padding: 10px 18px; cursor: pointer; text-decoration: none; display: inline-block; }
.button:hover, .search-page-form button:hover { background: var(--accent); color: #fff; }
.notice { font-family: var(--sans); font-size: 15px; color: var(--muted); padding: 28px 0; }

/* ---------- Article ---------- */
.article-head { max-width: 860px; padding: 34px 0 22px; }
.article-head .headline { font-size: clamp(32px, 5vw, 54px); font-variation-settings: 'opsz' 66; line-height: 1.06; letter-spacing: -0.018em; }
.article-head .dek { font-size: clamp(19px, 2vw, 23px); line-height: 1.4; margin-top: 14px; }
.byline { font-family: var(--sans); font-size: 14px; color: var(--muted); margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--hair); display: flex; flex-wrap: wrap; gap: 6px 24px; }
.byline strong { color: var(--ink); font-weight: 600; }
.hero { margin: 0 0 8px; }
.hero figcaption, .inline-figure figcaption { font-family: var(--sans); font-size: 13px; color: var(--muted); padding-top: 8px; line-height: 1.45; }
.credit { color: var(--muted); }
.credit a { color: inherit; }
.article-layout { display: grid; grid-template-columns: minmax(0, 680px) minmax(0, 1fr); gap: 64px; padding: 28px 0 40px; }
.toc { position: sticky; top: 20px; align-self: start; font-family: var(--sans); font-size: 14px; border-top: 3px solid var(--rule); padding-top: 10px; max-width: 300px; }
.toc h2 { font-size: 14px; margin: 0 0 8px; font-weight: 600; }
.toc ol { margin: 0; padding-left: 20px; }
.toc li { margin: 6px 0; color: var(--muted); }
.toc a { text-decoration: none; color: var(--ink-2); }
.toc a:hover { text-decoration: underline; color: var(--accent); }
.prose { font-size: 20px; line-height: 1.62; }
.prose > * + * { margin-top: 1.05em; }
.prose p, .prose ul, .prose ol { margin: 1.05em 0 0; }
.prose h2 { font-size: 29px; line-height: 1.18; margin: 1.7em 0 0; font-weight: 600; font-variation-settings: 'opsz' 40; scroll-margin-top: 16px; }
.prose h3 { font-size: 22px; margin: 1.4em 0 0; font-weight: 600; }
.prose li { margin: 0.35em 0; }
.prose ul { padding-left: 1.2em; }
.prose ul li::marker { color: var(--accent); }
.prose a { color: var(--accent-ink); text-decoration-color: rgba(31, 94, 74, 0.45); }
.prose blockquote { margin: 1.4em 0; padding: 2px 0 2px 20px; border-left: 3px solid var(--accent); font-style: italic; color: var(--ink-2); }
.prose strong { font-weight: 650; }
.inline-figure { margin: 1.8em 0; }
.inline-figure img { width: 100%; background: var(--paper-2); }

/* Ledger-style tables */
.table-wrap { margin: 1.6em 0; overflow-x: auto; -webkit-overflow-scrolling: touch; border-top: 2px solid var(--rule); border-bottom: 1px solid var(--rule); }
.table-wrap table { border-collapse: collapse; width: 100%; min-width: 520px; font-family: var(--sans); font-size: 15px; line-height: 1.45; font-variant-numeric: tabular-nums; }
.table-wrap th { text-align: left; font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--rule); background: var(--paper-2); vertical-align: bottom; }
.table-wrap td { padding: 10px 12px; border-bottom: 1px solid var(--hair); vertical-align: top; }
.table-wrap tr:last-child td { border-bottom: 0; }
.table-wrap td:first-child { font-weight: 500; }

.disclosure { font-family: var(--sans); font-size: 14px; color: var(--ink-2); background: var(--paper-2); padding: 14px 16px; margin-top: 36px; border-left: 3px solid var(--accent); }
.sample-note { font-family: var(--sans); font-size: 14px; background: var(--note); padding: 12px 16px; margin-top: 18px; color: #4a3b10; }
.sources { margin-top: 40px; border-top: 3px solid var(--rule); padding-top: 12px; font-family: var(--sans); font-size: 14px; }
.sources h2 { font-family: var(--serif); font-size: 24px; margin: 0 0 10px; }
.sources ol { padding-left: 22px; margin: 0; }
.sources li { margin: 0 0 10px; line-height: 1.45; overflow-wrap: anywhere; }
.sources .src-meta { color: var(--muted); }
.related { border-top: 1px solid var(--rule); padding: 0 0 40px; }
.related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 48px; }
.related-grid .media { margin-bottom: 12px; }
.related-grid .headline { font-size: 20px; }
.preview-banner { background: var(--ink); color: var(--paper); font-family: var(--sans); font-size: 14px; }
.preview-banner .wrap { padding-top: 10px; padding-bottom: 10px; display: flex; gap: 16px; justify-content: space-between; flex-wrap: wrap; }
.preview-banner a { color: var(--paper); }

/* ---------- Static pages ---------- */
.static { max-width: 720px; padding: 8px 0 56px; }
.static .prose { font-size: 19px; }

/* ---------- 404 ---------- */
.notfound { padding: 56px 0 64px; max-width: 720px; }
.notfound h1 { font-size: clamp(36px, 5vw, 56px); margin: 0 0 12px; line-height: 1.05; }
.notfound ul { padding-left: 1.2em; }

/* ---------- Footer ---------- */
.site-footer { border-top: 3px solid var(--rule); margin-top: 48px; padding: 26px 0 40px; font-family: var(--sans); font-size: 14px; color: var(--ink-2); }
.site-footer .cols { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.site-footer .brand { font-family: var(--serif); font-size: 26px; font-weight: 700; color: var(--ink); font-variation-settings: 'opsz' 48; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 8px 22px; flex-wrap: wrap; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer .fine { margin-top: 18px; color: var(--muted); font-size: 13px; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .article-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .toc { display: none; }
  .prose { max-width: 680px; }
  .latest-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .latest-grid .story:nth-child(3)::before { display: none; }
}
@media (max-width: 860px) {
  .front { grid-template-columns: minmax(0, 1fr); }
  .supporting { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); margin-top: 26px; padding-top: 22px; }
  .supporting .story:first-child .media { display: none; }
  .section-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 24px; }
  .section-grid .main { grid-column: 1 / -1; padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--hair); }
  .section-grid .col:first-of-type { border-left: 0; padding-left: 0; }
  .related-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .related-grid .story + .story::before { display: none; }
  .related-grid .story { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--hair); }
  .related-grid .media { margin: 0; }
  .river li { grid-template-columns: minmax(0, 1fr) 132px; gap: 16px; padding: 18px 0; }
  .river .headline { font-size: 20px; }
  .river .dek { display: none; }
  .search-form input { width: 120px; }
}
@media (max-width: 600px) {
  body { font-size: 17px; }
  .dateline .edition { display: none; }
  .masthead { padding: 12px 0 10px; }
  .masthead .tag { margin-top: 6px; }
  .sitenav .wrap { gap: 12px; padding-right: 0; }
  .sitenav ul { gap: 20px; -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); padding-right: 24px; }
  .search-form { border: 0; padding-right: var(--gutter); }
  .search-form input { display: none; }
  .lead .dek { font-size: 18px; }
  .lead .media { margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); margin-top: 16px; }
  .latest-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .latest-grid .story::before { display: none; }
  .latest-grid .story, .latest-grid .story + .story { padding: 14px 0; border-bottom: 1px solid var(--hair); display: grid; grid-template-columns: minmax(0, 1fr) 110px; gap: 14px; }
  .latest-grid .story > a:first-child { order: 2; }
  .latest-grid .story .media { margin: 0; }
  .section-grid { grid-template-columns: minmax(0, 1fr); }
  .section-grid .col { border-left: 0; padding-left: 0; }
  .section-grid .col .media { display: none; }
  .section-grid .main .headline { font-size: 24px; }
  .article-head { padding-top: 22px; }
  .hero { margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); }
  .hero figcaption { padding-left: var(--gutter); padding-right: var(--gutter); }
  .prose { font-size: 18.5px; line-height: 1.6; }
  .prose h2 { font-size: 25px; }
  .inline-figure { margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); }
  .inline-figure figcaption { padding-left: var(--gutter); padding-right: var(--gutter); }
  .table-wrap { margin-right: calc(-1 * var(--gutter)); }
  .table-wrap table { font-size: 14px; }
  .byline { gap: 4px 16px; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }
@media print { .sitenav, .site-footer, .toc, .related, .dateline { display: none; } body { background: #fff; } }
.site-footer ul.second { margin-top: 10px; }
.band-title.plain { border-top: 0; margin-top: 20px; }
.notice.tight { padding-bottom: 0; }
.errmsg { white-space: pre-wrap; font-size: 14px; }
.spaced { margin-top: 28px; }

/* ---------- Formats, citations, key points, FAQ ---------- */
.kicker-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin-bottom: 6px; }
.kicker-row .kicker { margin-bottom: 0; }
.format { font-family: var(--sans); font-size: 12px; font-weight: 600; letter-spacing: 0.02em; padding: 1px 7px 2px; border: 1px solid currentColor; line-height: 1.4; }
.format-news { color: #a3281b; }
.format-comparison { color: var(--accent); }
.format-analysis { color: #7a5410; }

.cite { font-family: var(--sans); font-size: 0.62em; font-weight: 600; line-height: 0; margin-left: 1px; white-space: nowrap; }
.cite a { color: var(--accent); text-decoration: none; padding: 0 1px; }
.cite a:hover, .cite a:focus-visible { text-decoration: underline; }
.cite .sep { color: var(--muted); }
.sources li:target { background: var(--note); outline: 6px solid var(--note); }
.primary-tag { font-size: 12px; font-weight: 600; color: var(--accent); border: 1px solid currentColor; padding: 0 5px; margin-left: 4px; white-space: nowrap; }
.sources .src-meta { display: block; }

.key-points { background: var(--paper-2); border-top: 3px solid var(--accent); padding: 18px 22px 8px; margin: 0 0 32px; }
.key-points h2 { font-family: var(--sans); font-size: 15px; font-weight: 600; margin: 0 0 10px; color: var(--accent-ink); }
.key-points ul { margin: 0; padding: 0; list-style: none; }
.key-points li { position: relative; padding-left: 20px; margin: 0 0 12px; font-size: 18px; line-height: 1.45; }
.key-points li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 8px; height: 8px; background: var(--accent); }

.faq { margin-top: 40px; border-top: 3px solid var(--rule); padding-top: 12px; }
.faq > h2 { font-family: var(--serif); font-size: 26px; margin: 0 0 6px; }
.faq .qa { border-bottom: 1px solid var(--hair); padding: 14px 0; }
.faq .qa:last-child { border-bottom: 0; }
.faq h3 { font-family: var(--serif); font-size: 20px; margin: 0 0 6px; line-height: 1.3; }
.faq p { margin: 0; font-size: 17px; line-height: 1.55; color: var(--ink-2); }

.hero.kind-screenshot img, .inline-figure.kind-screenshot img { border: 1px solid var(--hair); }
.band-note { font-family: var(--sans); font-size: 14px; color: var(--muted); }
.desk-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 48px; }
.desk-grid .story { position: relative; }
.desk-grid .story + .story::before { content: ""; position: absolute; left: -24px; top: 0; bottom: 0; border-left: 1px solid var(--hair); }
.desk-grid .media { margin-bottom: 12px; }
.desk-grid .headline { font-size: 21px; }
@media (max-width: 860px) {
  .desk-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .desk-grid .story + .story::before { display: none; }
  .desk-grid .story { padding: 16px 0; border-bottom: 1px solid var(--hair); }
  .band-note { display: none; }
  .key-points { padding: 16px 16px 6px; margin-left: calc(-1 * var(--gutter) / 2); margin-right: calc(-1 * var(--gutter) / 2); }
}
