/* Groove Street Journal — one hand-written stylesheet. No trackers, no ads, no external requests.
   Typography: self-hosted variable fonts. Jost (geometric) for display, Inter for text. */
@font-face {
  font-family: 'Jost';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/static/fonts/jost.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/static/fonts/inter.woff2') format('woff2');
}
:root {
  --display: 'Jost', 'Avenir Next', 'Century Gothic', system-ui, sans-serif;
  --text: 'Inter', 'Helvetica Neue', system-ui, sans-serif;
  color-scheme: light dark;
  --paper: #fcfcfb;
  --ink: #1a1a19;
  --ink-2: #55554f;
  --ink-3: #8a8a82;
  --rule: #d8d8d2;
  --accent: #1a1a19;
  --card: #f4f4f1;
  --bias-left: #2a78d6;
  --bias-center: #eda100;
  --bias-right: #e34948;
  --bias-unrated: #b9b9b1;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1a1a19;
    --ink: #f0efe9;
    --ink-2: #c3c2b7;
    --ink-3: #8f8e85;
    --rule: #3a3a36;
    --accent: #f0efe9;
    --card: #232320;
    --bias-left: #3987e5;
    --bias-center: #c98500;
    --bias-right: #d94b56;
    --bias-unrated: #5a5a54;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.6 var(--text);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
a:hover { text-decoration-thickness: 2px; }
img { max-width: 100%; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 1rem; }

/* Masthead */
header.masthead { border-bottom: 3px double var(--rule); padding: 1.2rem 0 0.6rem; text-align: center; }
.masthead h1 { margin: 0; font-family: var(--display); font-size: clamp(1.6rem, 5vw, 3rem); letter-spacing: 0.16em; text-transform: uppercase; font-weight: 500; }
.masthead h1 a { text-decoration: none; }
.masthead .tagline { color: var(--ink-2); font-family: var(--display); font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; margin: 0.3rem 0 0.7rem; }
nav.sections { border-top: 1px solid var(--rule); padding: 0.5rem 0; display: flex; flex-wrap: wrap; gap: 0.25rem 1.2rem; justify-content: center; font-family: var(--display); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; }
nav.sections a { text-decoration: none; color: var(--ink-2); }
nav.sections a:hover, nav.sections a.active { color: var(--ink); text-decoration: underline; }

main { padding: 1.4rem 0 2.5rem; }

/* Front page grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.2rem; }
.lead-row { display: grid; grid-template-columns: 2fr 1fr; gap: 1.6rem; margin-bottom: 1.6rem; }
@media (max-width: 760px) { .lead-row { grid-template-columns: 1fr; } }

.kicker { font-family: var(--text); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-3); }
.kicker a { color: inherit; text-decoration: none; }

article.card { border-top: 1px solid var(--rule); padding-top: 0.7rem; }
.card h2, .card h3 { margin: 0.25rem 0 0.4rem; line-height: 1.25; font-family: var(--display); font-weight: 500; }
.card h2 a, .card h3 a { text-decoration: none; }
.card h2 a:hover, .card h3 a:hover { text-decoration: underline; }
.card .summary { color: var(--ink-2); margin: 0.3rem 0 0.5rem; font-size: 0.95rem; }
.card .meta { font-family: var(--text); font-size: 0.78rem; color: var(--ink-3); }

/* Bias coverage bar — stacked proportion meter with 2px gaps, 4px rounded ends,
   always-visible count labels (color is never the only encoding). */
.bias { margin: 0.45rem 0 0.2rem; font-family: var(--text); }
.bias-bar { display: flex; gap: 2px; height: 8px; border-radius: 4px; overflow: hidden; background: transparent; max-width: 260px; }
.bias-bar span { display: block; height: 100%; }
.bias-bar .b-left { background: var(--bias-left); border-radius: 4px 0 0 4px; }
.bias-bar .b-center { background: var(--bias-center); }
.bias-bar .b-right { background: var(--bias-right); border-radius: 0 4px 4px 0; }
.bias-bar span:only-child { border-radius: 4px; }
.bias-legend { font-size: 0.74rem; color: var(--ink-2); margin-top: 0.25rem; display: flex; gap: 0.8rem; flex-wrap: wrap; }
.bias-legend .dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 0.3rem; vertical-align: baseline; }
.dot-left { background: var(--bias-left); }
.dot-center { background: var(--bias-center); }
.dot-right { background: var(--bias-right); }
.dot-unrated { background: var(--bias-unrated); }

/* Outlet chips */
.chips { list-style: none; margin: 0.8rem 0; padding: 0; }
.chips li { padding: 0.55rem 0; border-top: 1px solid var(--rule); }
.chip-outlet { font-family: var(--text); font-size: 0.78rem; color: var(--ink-2); }
.chip-outlet .fact { color: var(--ink-3); }
.chips .headline { font-size: 1rem; }
.chips .headline a { text-decoration: none; }
.chips .headline a:hover { text-decoration: underline; }

/* Article page */
.article-body { max-width: 720px; margin: 0 auto; }
.article-body h1 { font-family: var(--display); font-weight: 500; font-size: clamp(1.7rem, 4vw, 2.5rem); line-height: 1.2; margin: 0.4rem 0; }
.article-body .dek { font-size: 1.1rem; color: var(--ink-2); font-weight: 300; line-height: 1.5; margin: 0.3rem 0 0.8rem; }
.article-body .byline { font-family: var(--text); font-size: 0.85rem; color: var(--ink-2); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 0.5rem 0; margin: 0.8rem 0 1.2rem; }
.article-body .byline .ai-label { background: var(--card); border: 1px solid var(--rule); border-radius: 3px; padding: 0.1rem 0.45rem; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; margin-left: 0.5rem; }
.article-body p { margin: 0.9rem 0; }
.article-body blockquote { border-left: 3px solid var(--rule); margin: 1rem 0; padding-left: 1rem; color: var(--ink-2); }
.sources-box { background: var(--card); border: 1px solid var(--rule); border-radius: 6px; padding: 0.9rem 1.1rem; margin: 1.5rem 0; font-size: 0.9rem; }
.sources-box h2 { font-size: 0.95rem; margin: 0 0 0.5rem; font-family: var(--text); text-transform: uppercase; letter-spacing: 0.06em; }
.sources-box ul { margin: 0; padding-left: 1.2rem; }
.corrections { border: 1px solid var(--bias-right); border-radius: 6px; padding: 0.8rem 1.1rem; margin: 1.2rem 0; font-size: 0.9rem; }

/* Section pages */
.section-head { border-bottom: 2px solid var(--ink); margin-bottom: 1.2rem; padding-bottom: 0.4rem; }
.section-head h1 { margin: 0; font-family: var(--display); font-weight: 500; letter-spacing: 0.04em; font-size: 1.9rem; }
.section-head .mission { color: var(--ink-2); font-size: 0.92rem; }

/* Footer */
footer { border-top: 3px double var(--rule); padding: 1.2rem 0 2rem; font-family: var(--text); font-size: 0.82rem; color: var(--ink-2); }
footer .pledge { font-weight: 700; color: var(--ink); }
footer nav { display: flex; gap: 1.2rem; flex-wrap: wrap; margin-top: 0.5rem; }
footer a { color: var(--ink-2); }

/* Prose pages (about/methodology) */
.prose { max-width: 720px; margin: 0 auto; }
.prose h1 { font-family: var(--display); font-weight: 500; font-size: 2rem; }
.prose h2 { margin-top: 1.6rem; font-family: var(--display); font-weight: 500; }
table.outlet-table { border-collapse: collapse; width: 100%; font-family: var(--text); font-size: 0.82rem; }
.outlet-table th, .outlet-table td { text-align: left; padding: 0.35rem 0.6rem; border-bottom: 1px solid var(--rule); }
.outlet-table th { text-transform: uppercase; letter-spacing: 0.05em; font-size: 0.72rem; color: var(--ink-2); }
.table-scroll { overflow-x: auto; }

/* Card art & hero figures — generated geometric SVG or credited photos */
.card-art { display: block; width: 100%; aspect-ratio: 600 / 315; object-fit: cover; border: 1px solid var(--rule); border-radius: 4px; margin-bottom: 0.5rem; background: var(--card); }
figure.hero { margin: 0 0 1.2rem; }
figure.hero img { display: block; width: 100%; aspect-ratio: 600 / 315; object-fit: cover; border: 1px solid var(--rule); border-radius: 4px; }
figure.hero figcaption { font-family: var(--text); font-size: 0.72rem; color: var(--ink-3); margin-top: 0.3rem; text-transform: uppercase; letter-spacing: 0.06em; }

/* Developing badge — fast-moving multi-outlet stories (rule on /methodology/) */
.badge-developing { display: inline-block; vertical-align: middle; font-family: var(--text); font-size: 0.62rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--paper); background: var(--bias-center); border-radius: 3px; padding: 0.15rem 0.4rem; margin-left: 0.4rem; }
