/* CivilGate shared stylesheet (redesign-v1). One file for every page: tokens, base, header,
   cards, detail sheet, votes, static-page typography. Every colour is a token below.

   Colour has exactly one meaning each:
   - SCORE      --s-neg / --s-neu / --s-pos : one diverging scale (orange = harmful, grey = none, teal = beneficial).
                Used for scores and nothing else (chips, tiles, score bars, chart lines of scores).
   - BRAND      --brand : links, active pills, focus rings. Never on data marks.
   - Countries  flag + name, never a colour.   Dimensions  icon + name, never a colour.
   Dark is the default; [data-theme="light"] swaps the same tokens. */

/* Flag emoji for browsers that lack them (Edge/Windows): same family names, flag glyphs only */
@font-face{font-family:"Inter";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:400;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Inter";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:500;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Inter";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:600;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Inter";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:700;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"JetBrains Mono";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:400;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"JetBrains Mono";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:500;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"JetBrains Mono";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:600;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"JetBrains Mono";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:700;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Fira Code";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:400;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Fira Code";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:500;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Fira Code";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:600;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}
@font-face{font-family:"Fira Code";src:url(/TwemojiCountryFlags.woff2) format("woff2");font-weight:700;unicode-range:U+1F1E6-1F1FF,U+1F3F4,U+E0062-E007F;font-display:swap}

:root {
  color-scheme: dark;
  --bg: #0a0e18; --surface: #111827; --surface2: #172033; --border: #232d3f; --border2: #3b4659;
  --text: #eef0f4; --text2: #d1d5db; --muted: #9aa3b2;
  --brand: #7fd68f; --brand-ink: #7fd68f; --brand-bg: rgba(127,214,143,.12); --on-brand: #06210f;
  --s-neg: #f08a4b; --s-neu: #8d97a8; --s-pos: #2fc9bc;
  --s-neg-bg: rgba(240,138,75,.13); --s-pos-bg: rgba(47,201,188,.13); --s-neu-bg: rgba(141,151,168,.14);
  --glow: 1; --glow-px: 18px;
  --shadow: none;
  --scrim: rgba(0,0,0,.62);
  --mono: 'JetBrains Mono', 'Fira Code', ui-monospace, monospace;
  --sans: Inter, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --nav-h: 60px; --top-h: 56px; --jump-h: 58px;
  /* legacy names still used by a few inline styles and the archive page */
  --accent: var(--brand); --pos: var(--s-pos); --neg: var(--s-neg); --pos-bg: var(--s-pos-bg); --neg-bg: var(--s-neg-bg);
  --sub: var(--text2);
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f7f5f0; --surface: #ffffff; --surface2: #f0ede6; --border: #ddd8cc; --border2: #bdb6a6;
  --text: #14181f; --text2: #2c3441; --muted: #566070;
  --brand: #1f7a3d; --brand-ink: #1a6b35; --brand-bg: rgba(31,122,61,.10); --on-brand: #ffffff;
  --s-neg: #a63f08; --s-neu: #4f5867; --s-pos: #066a64;
  --s-neg-bg: rgba(166,63,8,.10); --s-pos-bg: rgba(6,106,100,.10); --s-neu-bg: rgba(79,88,103,.12);
  --glow: 0; --glow-px: 0px;
  --shadow: 0 1px 2px rgba(20,24,31,.06);
  --scrim: rgba(20,24,31,.45);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--top-h) + var(--jump-h) + 12px); }
body { margin: 0; background: var(--bg); color: var(--text2); font: 16px/1.6 var(--sans);
  padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); -webkit-font-smoothing: antialiased; }
a { color: var(--brand-ink); text-underline-offset: 2px; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
h1, h2, h3 { color: var(--text); }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.mono { font-family: var(--mono); }
.dim-word { font-size: 14px; color: var(--muted); }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.col { max-width: 740px; margin: 0 auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

/* ── Top bar (home markup and site-header.js share these classes) ── */
.top { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); font-family: var(--sans); }
.top .wrap { display: flex; align-items: center; gap: 12px; height: var(--top-h); position: relative; max-width: 1240px; }
.brand { display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.logo { font: 600 17px var(--mono); letter-spacing: 3px; text-decoration: none; color: var(--text); white-space: nowrap; line-height: 1.2; }
.tagline { display: none; color: var(--muted); font-size: 13px; line-height: 1.3; white-space: nowrap; }
.live { font: 12px var(--mono); color: var(--muted); display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
  border: 1px solid var(--border); border-radius: 999px; padding: 4px 10px; }
.live::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); animation: pulse 2.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }
.desk-nav { display: none; gap: 2px; margin-left: auto; font: 500 14px var(--sans); }
.desk-nav a { color: var(--text2); text-decoration: none; padding: 0 10px; min-height: 44px; display: inline-flex; align-items: center; border-radius: 999px; white-space: nowrap; }
.desk-nav a:hover { background: var(--surface2); color: var(--text); }
.desk-nav a[aria-current] { color: var(--brand-ink); background: var(--brand-bg); }
.region-btn, .theme-btn { font: 500 14px var(--sans); color: var(--text); border: 1px solid var(--border2); border-radius: 999px;
  padding: 0 14px; min-height: 44px; display: inline-flex; align-items: center; white-space: nowrap; background: var(--surface); }
.region-btn { margin-left: auto; max-width: 52vw; overflow: hidden; text-overflow: ellipsis; }
.region-btn:hover, .theme-btn:hover { border-color: var(--brand); }
.theme-btn { width: 44px; padding: 0; justify-content: center; }
.theme-btn svg { width: 20px; height: 20px; }
.menu { position: absolute; right: 16px; top: calc(var(--top-h) - 4px); background: var(--surface); border: 1px solid var(--border2); border-radius: 14px;
  padding: 6px; max-height: 70vh; overflow: auto; min-width: 240px; z-index: 60; box-shadow: 0 12px 32px rgba(0,0,0,.35); }
.menu button { display: block; width: 100%; text-align: left; color: var(--text); font: 15px var(--sans); padding: 11px 12px; min-height: 44px; border-radius: 10px; }
.menu button:hover { background: var(--surface2); }
.menu button[aria-pressed="true"] { color: var(--brand-ink); background: var(--brand-bg); }
@media (max-width: 559px) { .live-text { display: none; } .live { padding: 4px 8px; } .top .wrap { gap: 8px; } .logo { letter-spacing: 2px; font-size: 15px; } }
@media (min-width: 1000px) { .desk-nav { display: flex; } .region-btn { margin-left: 4px; } .theme-btn { margin-left: 0; } }
@media (min-width: 1000px) and (max-width: 1119px) { .live-text { display: none; } .live { padding: 4px 8px; } }
@media (min-width: 1240px) { .tagline { display: block; } }

/* ── Sticky jump pills (home) ── */
.jump { position: sticky; top: var(--top-h); z-index: 40; background: color-mix(in srgb, var(--bg) 94%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
.jump .wrap { display: flex; gap: 8px; align-items: center; height: var(--jump-h); overflow-x: auto; scrollbar-width: none; }
.jump .wrap::-webkit-scrollbar { display: none; }
.jump a { flex: none; font: 500 14px var(--sans); color: var(--text2); text-decoration: none; border: 1px solid var(--border2); border-radius: 999px;
  min-height: 44px; padding: 0 14px; display: inline-flex; align-items: center; background: var(--surface); }
.jump a:hover { border-color: var(--brand); color: var(--text); }
.jump a[aria-current="true"] { color: var(--brand-ink); border-color: var(--brand); background: var(--brand-bg); }

/* ── Section headings ── */
.section { padding: 34px 0 4px; }
.section > h2, .label { font: 600 22px/1.25 var(--sans); color: var(--text); margin: 0 0 4px; letter-spacing: -.2px; }
.label { margin: 26px 0 10px; font-size: 18px; }
.section > .section-sub { margin: 0 0 14px; color: var(--muted); font-size: 15px; }

/* ── Hero ── */
.hero { padding: 26px 0 8px; display: grid; gap: 22px; }
.hero-copy { order: 1; } .bignums { order: 2; } .hero-vis { order: 3; }
.hero h1 { font: 700 32px/1.15 var(--sans); letter-spacing: -.6px; margin: 0 0 10px; }
.hero-lede { margin: 0 0 14px; font-size: 17px; color: var(--text2); max-width: 46ch; }
.legend { display: grid; gap: 6px; max-width: 420px; margin-top: 18px; }
.legend-bar { height: 10px; border-radius: 999px; background: linear-gradient(90deg, var(--s-neg), var(--s-neu) 50%, var(--s-pos)); opacity: .95; }
.legend-ends { display: flex; justify-content: space-between; font: 13px var(--mono); color: var(--text2); }
.legend-note { font-size: 14px; color: var(--muted); margin: 0; }
.legend-note a { white-space: nowrap; }
.bignums { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.bn { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; min-width: 0; box-shadow: var(--shadow); }
.bn b { display: block; font: 600 34px/1.05 var(--mono); letter-spacing: -1px; color: var(--text); }
.bn b.scorev { color: var(--sc, var(--text)); text-shadow: 0 0 calc(var(--glow-px) * var(--glow)) color-mix(in srgb, var(--sc, transparent) 55%, transparent); }
.bn span { display: block; font-size: 14px; color: var(--muted); margin-top: 4px; line-height: 1.35; }
.bn small { display: block; font-size: 13px; color: var(--text2); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tiles-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.tiles-head h2 { font: 600 16px var(--sans); margin: 0; color: var(--text); }
.tiles-head p { margin: 0; font-size: 13px; color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tile { text-align: left; background: var(--surface); border: 1px solid color-mix(in srgb, var(--sc, var(--border2)) 38%, var(--border)); border-radius: 12px;
  padding: 10px 10px 9px; min-height: 104px; display: flex; flex-direction: column; justify-content: space-between; gap: 4px; min-width: 0;
  box-shadow: 0 0 calc(var(--glow-px) * var(--glow)) -6px var(--sc, transparent), var(--shadow); transition: border-color .15s, transform .15s; }
.tile:hover { border-color: var(--sc, var(--brand)); transform: translateY(-1px); }
.tile[aria-pressed="true"] { border-color: var(--brand); outline: 2px solid var(--brand); outline-offset: 1px; }
.tile-top { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.tile-flag { font-size: 20px; line-height: 1; }
.tile-name { font: 500 13px/1.25 var(--sans); color: var(--text); min-width: 0; }
.tile-score { font: 600 24px/1 var(--mono); letter-spacing: -.5px; color: var(--sc, var(--muted)); text-shadow: 0 0 calc(var(--glow-px) * var(--glow)) color-mix(in srgb, var(--sc, transparent) 60%, transparent); }
.tile-n { font-size: 12px; color: var(--muted); }
.tile.empty .tile-score { font-size: 15px; color: var(--muted); text-shadow: none; }
@media (min-width: 560px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } .bignums { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 900px) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); align-items: start; gap: 28px 36px; padding-top: 36px; }
  .hero h1 { font-size: 40px; }
  .hero { grid-template-rows: auto 1fr; }
  .hero-copy { grid-column: 1; order: 0; } .hero-vis { grid-column: 2; grid-row: 1 / span 2; order: 0; } .bignums { order: 0; }
  .bignums { grid-column: 1; grid-template-columns: repeat(2, minmax(0, 1fr)); align-self: start; }
  .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ── This week (large cards) and Being decided now (compact strip) ── */
.week { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.week li { display: flex; }
.week-card { width: 100%; text-align: left; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px 16px 14px;
  display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow); }
.week-card:hover { border-color: var(--border2); }
.w-where { font-size: 14px; color: var(--muted); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.w-head { font: 600 18px/1.35 var(--sans); color: var(--text); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.w-why { font-size: 15px; color: var(--text2); margin: 0; display: -webkit-box; -webkit-line-clamp: 7; -webkit-box-orient: vertical; overflow: hidden; }
.week-card .score { margin-top: auto; }
@media (min-width: 760px) { .week { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ── Score chip: the one place the score scale appears on a card ── */
.score { display: inline-flex; align-items: center; gap: 10px; align-self: flex-start; border-radius: 12px; padding: 6px 12px 6px 10px; background: var(--sbg, var(--s-neu-bg));
  border: 1px solid color-mix(in srgb, var(--sc, var(--s-neu)) 45%, transparent);
  box-shadow: 0 0 calc(var(--glow-px) * var(--glow)) -4px var(--sc, transparent); }
.score b { font: 600 24px/1 var(--mono); color: var(--sc, var(--s-neu)); letter-spacing: -.5px; }
.score span { font: 600 14px var(--sans); color: var(--sc, var(--s-neu)); }
.score.sm { padding: 3px 9px 3px 8px; gap: 7px; border-radius: 9px; box-shadow: none; }
.score.sm b { font-size: 16px; } .score.sm span { font-size: 13px; }
.pos { --sc: var(--s-pos); --sbg: var(--s-pos-bg); } .neg { --sc: var(--s-neg); --sbg: var(--s-neg-bg); } .zero { --sc: var(--s-neu); --sbg: var(--s-neu-bg); }
.dimtag { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text2); }
.dimtag svg { width: 18px; height: 18px; flex: none; color: var(--muted); }

/* ── Topic pills + sort ── */
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 2px 16px 6px; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; font: 500 14px var(--sans); border: 1px solid var(--border2); border-radius: 999px; min-height: 44px; padding: 0 16px; color: var(--text2);
  background: var(--surface); display: inline-flex; align-items: center; }
.chip:hover { border-color: var(--brand); color: var(--text); }
.chip[aria-pressed="true"] { border-color: var(--brand); color: var(--brand-ink); background: var(--brand-bg); }
.chip:disabled { opacity: .5; cursor: default; }
.sortbar { display: flex; align-items: center; gap: 6px; margin: 14px 0 12px; font-size: 14px; color: var(--muted); }
.sortbar button { color: var(--text2); min-height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid transparent; }
.sortbar button[aria-pressed="true"] { color: var(--brand-ink); border-color: var(--brand); background: var(--brand-bg); }
.sortbar .count { margin-left: auto; font: 13px var(--mono); }

/* ── Search ── */
.searchbar { margin-top: 14px; }
.searchbar input { width: 100%; background: var(--surface); border: 1px solid var(--border2); border-radius: 14px; color: var(--text); font: 16px var(--sans); padding: 0 16px; min-height: 52px; }
.searchbar input::placeholder { color: var(--muted); }
.searchbar input:focus { border-color: var(--brand); outline: 2px solid var(--brand); outline-offset: 1px; }
#search-note { margin-top: 8px; }

/* ── Feed cards ── */
.feed { display: grid; gap: 12px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px; cursor: pointer; box-shadow: var(--shadow); transition: border-color .15s; }
.card:hover { border-color: var(--border2); }
.card[data-open="true"] { border-color: var(--border2); }
.card-top { display: flex; align-items: center; gap: 8px 10px; font-size: 14px; color: var(--muted); margin-bottom: 8px; flex-wrap: wrap; }
.where { color: var(--text2); font-weight: 500; }
.status { border: 1px solid var(--border2); border-radius: 999px; padding: 1px 9px; font-size: 13px; color: var(--muted); }
.new { color: var(--brand-ink); border: 1px solid var(--brand); border-radius: 999px; padding: 1px 8px; font-size: 13px; font-weight: 600; }
.card-top time { margin-left: auto; font-size: 13px; }
.headline { font: 600 19px/1.35 var(--sans); margin: 0 0 4px; color: var(--text); letter-spacing: -.1px; }
.headline .clamp, .clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card[data-open="true"] .headline .clamp { -webkit-line-clamp: unset; display: block; }
.headline button { text-align: left; font: inherit; color: inherit; letter-spacing: inherit; width: 100%; display: flex; align-items: center; min-height: 44px; }
.headline button:focus-visible { outline-offset: 4px; }
.card .score { margin: 0 0 8px; }
.why { font-size: 16px; color: var(--text2); margin: 0 0 4px; }
.card:not([data-open="true"]) .why { display: -webkit-box; -webkit-line-clamp: 7; -webkit-box-orient: vertical; overflow: hidden; }
.card-actions { display: flex; align-items: center; gap: 4px; margin-top: 6px; }
.more { font: 500 14px var(--sans); color: var(--brand-ink); min-height: 44px; padding: 0 4px; margin-right: auto; display: inline-flex; align-items: center; gap: 6px; }
.more svg { width: 16px; height: 16px; transition: transform .15s; }
.card[data-open="true"] .more svg { transform: rotate(180deg); }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; color: var(--muted); }
.icon-btn:hover { background: var(--surface2); color: var(--text); }
.icon-btn[aria-pressed="true"] { color: var(--brand-ink); }
.icon-btn svg { width: 20px; height: 20px; }
.card-more { border-top: 1px solid var(--border); margin-top: 10px; padding-top: 12px; display: grid; gap: 12px; cursor: default; }
.card-more[hidden] { display: none; }
.cm-summary { margin: 0; font-size: 16px; color: var(--text2); }
.cm-summary.none { color: var(--muted); font-style: italic; }
.cm-official { margin: 0; font-size: 14px; color: var(--muted); }
.cm-official .code { font-family: var(--mono); font-size: 13px; color: var(--text2); }
.cm-dims { display: grid; gap: 10px; }
.cm-dim { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; align-items: start; }
.cm-dim .dimtag { grid-column: 2; font-weight: 500; color: var(--text); }
.cm-dim .score { grid-row: 1 / span 2; margin: 0; }
.cm-dim p { grid-column: 2; margin: 0; font-size: 15px; color: var(--text2); }
.cm-links { display: flex; flex-wrap: wrap; gap: 8px; }
.cm-links .btn { min-height: 44px; }

/* Cards without a score: one quiet group under the feed */
.routine { margin-top: 20px; border: 1px dashed var(--border2); border-radius: 14px; padding: 0 14px; }
.routine summary { cursor: pointer; min-height: 48px; display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); list-style: none; }
.routine summary::-webkit-details-marker { display: none; }
.routine summary::before { content: '+'; font: 600 16px var(--mono); width: 18px; color: var(--muted); }
.routine[open] summary::before { content: '−'; }
.routine ul { list-style: none; margin: 0; padding: 0 0 8px; }
.routine li { border-top: 1px solid var(--border); }
.routine-row { width: 100%; text-align: left; min-height: 44px; display: flex; gap: 10px; align-items: baseline; padding: 8px 0; font-size: 14px; color: var(--text2); }
.routine-row .rt { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.routine-row small { color: var(--muted); font-size: 13px; white-space: nowrap; }
.plain-card { padding: 10px 14px; border-radius: 12px; }
.plain-card .card-top { margin-bottom: 2px; }
.plain-card .headline { font-size: 16px; font-weight: 500; margin-bottom: 2px; }
.plain-card .why { font-size: 14px; color: var(--muted); }

.interlude { border: 1px dashed var(--border2); border-radius: 16px; padding: 16px; font-size: 15px; color: var(--text2); }
.interlude a { display: inline-block; margin-top: 6px; font-weight: 500; }
.empty { text-align: center; color: var(--text2); padding: 40px 12px; font-size: 15px; }
.empty a, .empty button { color: var(--brand-ink); font-weight: 500; text-decoration: underline; min-height: 44px; }
.sentinel { height: 1px; }
.skeleton { height: 200px; border-radius: 16px; background: var(--surface); animation: shimmer 1.4s ease-in-out infinite; }
@keyframes shimmer { 50% { opacity: .5; } }

/* ── "How scoring works" block ── */
.howto { margin-top: 34px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px 18px 14px; box-shadow: var(--shadow); }
.howto h2 { font: 600 20px var(--sans); margin: 0 0 8px; }
.howto p { margin: 0 0 10px; }
.howto ul { margin: 0 0 12px; padding-left: 20px; } .howto li { margin: 4px 0; }

footer { color: var(--muted); font-size: 14px; padding: 36px 0 28px; line-height: 1.8; }
footer a { color: var(--text2); }

/* ── Bottom nav (phones) ── */
.bottom { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; background: color-mix(in srgb, var(--bg) 96%, transparent); border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.bottom ul { list-style: none; margin: 0 auto; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); max-width: 640px; height: var(--nav-h); }
.bottom a, .bottom button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: 100%; width: 100%;
  font: 500 13px var(--sans); color: var(--muted); text-decoration: none; }
.bottom svg { width: 22px; height: 22px; }
.bottom [aria-current] { color: var(--brand-ink); }
@media (min-width: 1000px) { body { padding-bottom: 0; } .bottom { display: none; } }

/* ── Detail sheet ── */
.scrim { position: fixed; inset: 0; background: var(--scrim); z-index: 70; opacity: 0; pointer-events: none; transition: opacity .2s; }
.scrim.open { opacity: 1; pointer-events: auto; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 71; max-height: 92vh; max-height: 92dvh; overflow-y: auto; background: var(--bg); border: 1px solid var(--border);
  border-bottom: 0; border-radius: 20px 20px 0 0; transform: translateY(100%); transition: transform .25s ease; overscroll-behavior: contain; padding: 0 18px calc(24px + env(safe-area-inset-bottom)); }
.sheet.open { transform: none; }
.sheet-head { position: sticky; top: 0; background: var(--bg); padding: 12px 0 8px; display: flex; align-items: center; z-index: 1; }
.grab { width: 40px; height: 4px; border-radius: 2px; background: var(--border2); position: absolute; left: 50%; top: 8px; transform: translateX(-50%); }
.sheet-close { margin-left: auto; margin-top: 6px; font: 500 14px var(--sans); color: var(--text); border: 1px solid var(--border2); border-radius: 999px; min-height: 44px; padding: 0 16px; background: var(--surface); }
.sheet h2 { font: 600 21px/1.35 var(--sans); margin: 10px 0 6px; }
.orig { font-size: 14px; color: var(--muted); margin: 0 0 12px; }
.dates { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 14px; color: var(--muted); margin: 10px 0 0; }
.dates b { color: var(--text2); font-weight: 500; }
.sheet .summary { color: var(--text2); font-size: 16px; margin: 12px 0 0; }
.plain { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; font-size: 15px; color: var(--text2); margin-top: 14px; }
.plain b { color: var(--text); font-weight: 600; }
.dim { border-top: 1px solid var(--border); padding: 14px 0; }
.dim-row { display: flex; align-items: center; gap: 14px; }
.dim-num { font: 600 28px/1 var(--mono); min-width: 52px; color: var(--sc, var(--s-neu)); }
.dim-name { font-weight: 600; font-size: 16px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.dim-name svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.dim-name small { font-size: 13px; color: var(--muted); font-weight: 400; margin-left: 4px; }
.dim-word { font-size: 14px; color: var(--muted); }
.meter { position: relative; height: 6px; border-radius: 3px; background: var(--surface2); margin-top: 6px; }
.meter::after { content: ''; position: absolute; left: 50%; top: -3px; bottom: -3px; width: 1px; background: var(--border2); }
.meter span { position: absolute; top: 0; bottom: 0; border-radius: 3px; background: var(--sc, var(--s-neu)); }
.dim-why { font-size: 15px; color: var(--text2); margin: 8px 0 0; }
.dim-why b { color: var(--text); font-weight: 600; }
.na { font-size: 14px; color: var(--muted); border-top: 1px solid var(--border); padding: 12px 0; }
.note { font-size: 14px; border-radius: 10px; padding: 10px 12px; margin-top: 10px; border: 1px solid var(--border); color: var(--text2); }
.note.warn { border-color: var(--border2); background: var(--surface2); color: var(--text); }
.sheet-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; }
.btn { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border: 1px solid var(--border2); border-radius: 12px; font: 500 14px var(--sans);
  text-decoration: none; color: var(--text); padding: 8px 12px; text-align: center; background: var(--surface); }
.btn:hover { border-color: var(--brand); }
.btn.wide { grid-column: 1 / -1; }
.btn.primary { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.btn[aria-pressed="true"] { border-color: var(--brand); color: var(--brand-ink); }
.sheet-links { font-size: 14px; color: var(--muted); margin-top: 18px; display: flex; flex-wrap: wrap; gap: 6px 16px; }
.sheet-links a { color: var(--text2); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.tags span { font: 12px var(--mono); color: var(--muted); background: var(--surface); border: 1px solid var(--border); border-radius: 6px; padding: 2px 8px; }
.opt-list { display: grid; gap: 4px; margin: 6px 0 10px; }
.opt { display: flex; align-items: center; gap: 10px; text-align: left; padding: 0 12px; min-height: 48px; border-radius: 10px; font-size: 16px; color: var(--text); }
.opt:hover { background: var(--surface); }
.opt[aria-pressed="true"] { background: var(--brand-bg); color: var(--brand-ink); }
.opt small { margin-left: auto; font-size: 12px; color: var(--muted); }
.field { display: flex; gap: 8px; margin: 10px 0; }
.field input { flex: 1; min-width: 0; background: var(--surface); border: 1px solid var(--border2); border-radius: 10px; color: var(--text); font: 16px var(--sans); padding: 10px 12px; min-height: 44px; }
.field .btn { min-width: 80px; }
.rep { border: 1px solid var(--border); border-radius: 12px; padding: 12px; margin-top: 8px; font-size: 15px; }
.rep a { margin-right: 12px; }
textarea.msg { width: 100%; min-height: 200px; background: var(--surface); border: 1px solid var(--border2); border-radius: 10px; color: var(--text); font: 15px/1.5 var(--sans); padding: 10px 12px; margin-top: 8px; }
.toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + 16px + env(safe-area-inset-bottom)); transform: translateX(-50%) translateY(20px); background: var(--text); color: var(--bg);
  font: 500 14px var(--sans); padding: 10px 16px; border-radius: 999px; opacity: 0; transition: .2s; z-index: 90; pointer-events: none; }
.toast.show { opacity: 1; transform: translateX(-50%); }
@media (min-width: 900px) {
  .sheet { left: auto; top: 0; width: 540px; max-height: none; border-radius: 0; border: 0; border-left: 1px solid var(--border); transform: translateX(100%); }
  .grab { display: none; } .toast { bottom: 24px; }
}

/* ── Votes, journey ── (for/against use neutral weights, never the score scale) */
.vote-for { --vc: var(--text2); } .vote-against { --vc: var(--border2); }
.votebox { border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; margin-top: 10px; background: var(--surface); }
.vb-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.vb-chamber { font-weight: 600; font-size: 15px; color: var(--text); }
.vb-meta { font-size: 13px; color: var(--muted); }
.vb-result { margin-left: auto; font: 600 14px var(--sans); color: var(--text); }
.vbar { display: flex; height: 10px; border-radius: 5px; overflow: hidden; background: var(--surface2); margin: 10px 0 6px; }
.vbar span { display: block; height: 100%; }
.vbar .y { background: var(--text2); } .vbar .n { background: var(--border2); } .vbar .a { background: repeating-linear-gradient(45deg, var(--border2) 0 3px, var(--surface2) 3px 6px); }
.vb-counts { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 14px; color: var(--text2); }
.vb-counts .y { font-weight: 600; color: var(--text); }
.parties { margin-top: 10px; display: grid; gap: 6px; }
.prow { display: grid; grid-template-columns: minmax(0, 1fr) 90px; gap: 10px; align-items: center; font-size: 13px; }
.prow .pname { color: var(--text2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prow .vbar { margin: 0; height: 8px; }
.prow small { grid-column: 1 / -1; font-size: 12px; color: var(--muted); margin-top: -4px; }
.linkbtn { font: 500 14px var(--sans); color: var(--brand-ink); padding: 10px 0 0; min-height: 44px; }
.mlist-tools { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 8px; }
.mlist-tools input { flex: 1 1 180px; min-width: 0; background: var(--surface); border: 1px solid var(--border2); border-radius: 10px; color: var(--text); font: 15px var(--sans); padding: 8px 10px; min-height: 44px; }
.mlist-tools .chip { min-height: 40px; padding: 0 12px; font-size: 13px; }
.mrow { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--border); font-size: 14px; }
.mrow .who { flex: 1; min-width: 0; color: var(--text); }
.mrow .who small { display: block; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pos-badge { font: 500 12px var(--sans); border-radius: 6px; padding: 2px 8px; white-space: nowrap; border: 1px solid var(--border2); color: var(--text2); }
.pos-badge.y { color: var(--text); background: var(--surface2); font-weight: 600; } .pos-badge.x { color: var(--muted); border-style: dashed; }
.vb-credit { font-size: 12px; line-height: 1.5; color: var(--muted); margin: 8px 0 0; }
.vb-credit a { color: var(--muted); text-decoration: underline; }
.journey { list-style: none; margin: 0; padding: 0 0 0 4px; }
.journey li { position: relative; padding: 0 0 14px 22px; font-size: 15px; color: var(--text2); }
.journey li::before { content: ''; position: absolute; left: 0; top: 6px; width: 9px; height: 9px; border-radius: 50%; background: var(--bg); border: 2px solid var(--border2); }
.journey li::after { content: ''; position: absolute; left: 5px; top: 17px; bottom: -2px; width: 1px; background: var(--border2); }
.journey li:last-child::after { display: none; }
.journey li.enacted::before { border-color: var(--text2); background: var(--text2); }
.journey li.vote::before { border-color: var(--brand); }
.journey time { display: block; font-size: 13px; color: var(--muted); }
.updates { margin-top: 14px; border: 1px solid var(--brand); border-radius: 12px; padding: 12px 14px; font-size: 15px; }
.updates button.u-item { display: block; text-align: left; color: var(--text); padding: 6px 0; width: 100%; min-height: 44px; }
.updates button.u-item small { display: block; font-size: 13px; color: var(--brand-ink); }
.updates .u-dismiss { font-size: 13px; color: var(--muted); min-height: 44px; }
.myrep-btn { margin-right: 0; }
.yourrep-cta { display: block; width: 100%; text-align: left; margin: 10px 0 4px; padding: 10px 12px; border: 1px dashed var(--brand); border-radius: 10px; font-size: 14px; color: var(--text); }
.yourrep-cta b { color: var(--brand-ink); font-weight: 600; }
.yourrep { margin: 10px 0 4px; padding: 10px 12px; border: 1px solid var(--border2); border-radius: 10px; font-size: 15px; display: grid; gap: 6px; }
.yourrep small { font-size: 12px; font-weight: 600; color: var(--muted); }
.yr-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.eu-note { flex-basis: 100%; order: 5; color: var(--muted); font-size: 13px; }
.cov { margin-top: 14px; border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; font-size: 14px; color: var(--text2); }
.cov-head { font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 8px; }
.cov-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.cov-grid b { display: block; font: 600 18px var(--mono); color: var(--text); }
.cov-grid small { font-size: 13px; color: var(--muted); }
@media (min-width: 560px) { .cov-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* Collapsible info boxes (#plain in the sheet) */
.fold-tog, .plain button { font: 600 16px/1 var(--mono); width: 32px; height: 32px; flex: none; border: 1px solid var(--border2); border-radius: 8px; color: var(--brand-ink); margin: 0 0 0 auto; padding: 0; text-align: center; }
.plain { display: flex; gap: 12px; align-items: flex-start; }
.fold-body { flex: 1; min-width: 0; }
.collapsed .fold-body { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Archive controls (explore.html) ── */
.intro { padding: 26px 0 6px; }
.intro h1 { font: 700 30px/1.2 var(--sans); letter-spacing: -.4px; margin: 0 0 6px; }
.intro p { margin: 0; color: var(--muted); }
.filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; margin-top: 14px; }
.filters label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 500; color: var(--muted); min-width: 0; }
.filters select { width: 100%; min-width: 0; background-color: var(--surface); color: var(--text); border: 1px solid var(--border2); border-radius: 10px; padding: 0 28px 0 10px; min-height: 44px; font: 15px var(--sans);
  appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 15px) 55%, calc(100% - 10px) 55%; background-size: 5px 5px; background-repeat: no-repeat; }
.filters select:focus { border-color: var(--brand); }
.filters .wide { grid-column: 1 / -1; }
.filters .check { flex-direction: row; align-items: center; gap: 10px; font-size: 15px; color: var(--text2); min-height: 44px; }
.filters .check input { width: 20px; height: 20px; accent-color: var(--brand); margin: 0; flex: none; }
.filter-foot { display: flex; align-items: center; gap: 12px; margin-top: 6px; font-size: 14px; color: var(--muted); }
.filter-foot button { color: var(--brand-ink); font-size: 14px; min-height: 44px; }
.arch-status { text-align: center; color: var(--text2); font-size: 14px; padding: 18px 8px 8px; }
.arch-status button { margin-top: 10px; font-size: 14px; color: var(--brand-ink); border: 1px solid var(--border2); border-radius: 999px; min-height: 44px; padding: 0 16px; }
@media (min-width: 560px) { .filters { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ── Cookie choice: small, non-blocking, bottom-left ── */
.cg-consent { position: fixed; left: 12px; bottom: 12px; z-index: 9999; width: min(340px, calc(100vw - 24px)); background: var(--surface); border: 1px solid var(--border2);
  border-radius: 14px; padding: 14px; font: 14px/1.5 var(--sans); color: var(--text2); box-shadow: 0 10px 30px rgba(0,0,0,.35); }
.cg-consent p { margin: 0 0 10px; }
.cg-consent .cg-consent-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cg-consent button { min-height: 44px; border-radius: 10px; border: 1px solid var(--border2); background: var(--surface2); color: var(--text); font: 600 14px var(--sans); cursor: pointer; }
.cg-consent button:hover { border-color: var(--brand); }
@media (max-width: 999px) { .cg-consent { bottom: calc(var(--nav-h) + 8px + env(safe-area-inset-bottom)); } }

/* ── Static pages (methodology, coverage, sources) ── */
.doc { max-width: 820px; margin: 0 auto; padding: 28px 16px 72px; }
.doc h1 { font: 700 32px/1.2 var(--sans); letter-spacing: -.5px; margin: 8px 0 8px; }
.doc h2 { font: 600 22px/1.3 var(--sans); margin: 36px 0 10px; }
.doc h3 { font: 600 17px var(--sans); margin: 22px 0 6px; }
.doc p, .doc li { color: var(--text2); }
.doc p { margin: 0 0 14px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 15px; }
.doc th { text-align: left; font-weight: 600; color: var(--text); border-bottom: 2px solid var(--border2); padding: 8px 10px 8px 0; }
.doc td { border-bottom: 1px solid var(--border); padding: 8px 10px 8px 0; vertical-align: top; color: var(--text2); }
.doc code, .code { font-family: var(--mono); font-size: .9em; background: var(--surface2); border-radius: 4px; padding: 1px 5px; }
.table-scroll { overflow-x: auto; max-width: 100%; }

.doc .page-sub { font-size: 17px; color: var(--muted); margin: 0 0 26px; }
.doc table { display: block; overflow-x: auto; max-width: 100%; margin-bottom: 20px; }
.doc td:first-child { color: var(--text); font-weight: 500; }
.doc strong, .doc b { color: var(--text); font-weight: 600; }
.doc ul { padding-left: 22px; margin: 0 0 14px; } .doc li { margin-bottom: 6px; }
.doc .note { color: var(--muted); font-size: 14px; }
.doc .mono { font-family: var(--mono); font-size: 13px; }
.doc footer { border-top: 1px solid var(--border); margin-top: 40px; padding: 16px 0; font-size: 14px; }
.callout { background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--border2); border-radius: 10px; padding: 12px 16px; margin: 0 0 16px; font-size: 15px; color: var(--text2); }
.callout strong { color: var(--text); }
.callout.warn { background: var(--surface2); border-left-color: var(--text2); }
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 8px; }
.stat-box { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; }
.stat-val { font: 600 28px/1.1 var(--mono); color: var(--text); letter-spacing: -.5px; }
.stat-label { font-size: 14px; color: var(--muted); }
.tag { display: inline-block; font-size: 13px; border: 1px solid var(--border2); border-radius: 999px; padding: 0 9px; color: var(--text2); }
.tag.gap { border-style: dashed; }
.src { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; }
.src b { color: var(--text); font-weight: 600; }
.src .lic { font-size: 14px; color: var(--text2); margin-top: 4px; }
.src .cr { font-size: 15px; color: var(--text); margin-top: 6px; }
.src .cr small { display: block; font-size: 12px; color: var(--muted); }


/* ═══ Follow-up v2 (2026-10-16): heat-map tiles, stat tiles, compact cards, related laws, consent bar, readable small text ═══ */

/* Small text is sans and at least 13px; mono stays on the big numerals and the wordmark */
.live { font: 500 13px var(--sans); }
.legend-ends { font: 500 14px var(--sans); color: var(--text2); }
.legend-note { font-size: 14px; }
.sortbar .count { font: 14px var(--sans); }
.tags span { font: 13px var(--sans); }
.cm-official .code { font: 600 13px var(--sans); }
.vote-line { font-size: 14px; line-height: 1.45; color: var(--text2); margin: 6px 0 0; }
.vote-line b { font-weight: 600; color: var(--text); }
.rep-link { display: inline-flex; align-items: center; align-self: flex-start; min-height: 40px; padding: 0 14px; border: 1px solid var(--brand); border-radius: 999px; color: var(--brand-ink);
  font: 500 14px var(--sans); background: var(--brand-bg); }

/* The score scale, everywhere: --sc is set inline from the score (grey at 0, full colour at ±4) */
.score { background: color-mix(in srgb, var(--sc, var(--s-neu)) calc(8% + var(--t, 0) * 10%), transparent);
  border-color: color-mix(in srgb, var(--sc, var(--s-neu)) calc(22% + var(--t, 0) * 45%), transparent);
  box-shadow: 0 0 calc(var(--glow-px) * var(--glow) * var(--t, 0)) -3px var(--sc, transparent); }
.score-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 8px; }
.card .score-row { margin-bottom: 8px; }

/* Country tiles: a heat map (tint, number and a bottom bar all in the one score colour; near 0 reads as grey) */
.hero-vis { min-width: 0; }
.tiles-head { align-items: center; margin-bottom: 4px; }
.tiles-note { margin: 0 0 8px; font-size: 14px; color: var(--muted); }
.seg { display: flex; gap: 6px; flex-wrap: wrap; }
.seg button { min-height: 44px; padding: 0 14px; border: 1px solid var(--border2); border-radius: 999px; font: 500 14px var(--sans); color: var(--text2); background: var(--surface); }
.seg button:hover { border-color: var(--brand); color: var(--text); }
.seg button[aria-pressed="true"] { border-color: var(--brand); color: var(--brand-ink); background: var(--brand-bg); }
.tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 480px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.tile { position: relative; overflow: hidden; min-height: 112px; padding: 10px 12px 14px; justify-content: flex-start; gap: 2px;
  background: color-mix(in srgb, var(--sc, var(--s-neu)) calc(var(--t, 0) * 17%), var(--surface));
  border-color: color-mix(in srgb, var(--sc, var(--s-neu)) calc(18% + var(--t, 0) * 60%), var(--border));
  box-shadow: 0 0 calc(var(--glow-px) * var(--glow) * var(--t, 0)) -4px var(--sc, transparent), var(--shadow); }
.tile-flag { font-size: 20px; line-height: 1; margin-bottom: 2px; }
.tile-score { font: 600 28px/1.1 var(--mono); letter-spacing: -.5px; color: var(--sc, var(--muted)); text-shadow: 0 0 calc(var(--glow-px) * var(--glow) * var(--t, 0)) color-mix(in srgb, var(--sc, transparent) 60%, transparent); }
.tile-name { font: 600 14px/1.25 var(--sans); color: var(--text); }
.tile-n { font-size: 13px; color: var(--text2); }
.tile-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 6px; display: flex; gap: 1px; background: var(--border); }
.tile-bar.plain { background: var(--sc, var(--s-neu)); opacity: .5; }
.tile-bar i, .tl-bar i { display: block; flex-basis: 0; min-width: 2px; }
.tb-harm { background: var(--s-neg); } .tb-neu { background: var(--s-neu); } .tb-help { background: var(--s-pos); }
.tiles-legend { display: flex; align-items: center; gap: 10px; margin: 10px 0 0; font-size: 14px; color: var(--text2); }
.tl-bar { display: inline-flex; width: 56px; height: 6px; flex: none; gap: 1px; border-radius: 3px; overflow: hidden; }
.tl-bar i { flex-grow: 1; }
.tile.empty { background: var(--surface); } .tile.empty .tile-score { font-size: 22px; color: var(--muted); text-shadow: none; } .tile.empty .tile-bar { opacity: .25; }
.tile[aria-pressed="true"] { outline: 3px solid var(--brand); outline-offset: 1px; border-color: var(--brand); }

/* Stat tiles: four, the same window and scope written under every number */
.bignums { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 560px) and (max-width: 899px) { .bignums { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.bn { display: flex; flex-direction: column; gap: 2px; text-decoration: none; }
.bn b { font-size: 34px; }
.bn span { margin-top: 2px; }
.bn .bn-title { font-size: 14px; line-height: 1.35; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 4px; }
.bn .bn-foot { font-size: 13px; color: var(--muted); white-space: normal; margin-top: auto; padding-top: 4px; }
.bn-law:hover { border-color: var(--sc, var(--brand)); }
.bn-law:focus-visible { outline-offset: 2px; }
.bn a, .bn-foot a { color: var(--brand-ink); }

/* This week / Being decided now: one card design, the same text sizes everywhere */
.week { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) { .week { grid-template-columns: repeat(3, minmax(0, 1fr)); } .week.live-one { grid-template-columns: minmax(0, 1fr); } }
.week-card { gap: 8px; min-height: 100%; }
.week-card .score-row { margin: auto 0 0; padding-top: 4px; }
.w-why.na { color: var(--muted); font-style: italic; }
.week-card .vote-line { margin: 0; }
.live-one .week-card { padding: 18px 20px; } .live-one .w-head { font-size: 19px; -webkit-line-clamp: 2; } 
.live-more { grid-column: 1 / -1; justify-content: center; }
.live-more .btn { min-width: 180px; }

/* Related laws */
.card-actions { flex-wrap: wrap; }
.card-actions .more { margin-right: 0; }
.card-actions [data-act="save"] { margin-left: auto; }
.rel-btn { padding-left: 10px; }
.related { border-top: 1px solid var(--border); margin-top: 10px; padding-top: 6px; cursor: default; }
.related[hidden] { display: none; }
.related ul { list-style: none; margin: 0; padding: 0; }
.rel-head { margin: 0 0 2px; font-size: 14px; font-weight: 600; color: var(--text2); }
.rel-row { width: 100%; text-align: left; display: flex; align-items: center; gap: 12px; justify-content: space-between; min-height: 52px; padding: 8px 0; border-top: 1px solid var(--border); }
.related li:first-child .rel-row { border-top: 0; }
.rel-main { display: grid; gap: 2px; min-width: 0; }
.rel-title { font: 500 15px/1.35 var(--sans); color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rel-meta { font-size: 13px; color: var(--muted); }
.rel-row:hover .rel-title { text-decoration: underline; }
.cm-official .cm-label { font-weight: 600; color: var(--text2); }

/* Scrollable pill rows: a fade on the side that has more, and arrows for the topics */
.chips-wrap { position: relative; display: flex; align-items: center; gap: 4px; }
.chips-wrap .chips { flex: 1; min-width: 0; margin: 0; padding: 2px 2px 6px; }
.chips-arrow { flex: none; width: 44px; height: 44px; border: 1px solid var(--border2); border-radius: 999px; background: var(--surface); color: var(--text); font-size: 24px; line-height: 1; display: grid; place-items: center; }
.chips-arrow:hover:not(:disabled) { border-color: var(--brand); }
.chips-arrow:disabled { opacity: .35; cursor: default; }
.chips-arrow[hidden] { display: none; }
.chips-wrap.fade-r .chips { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 44px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 44px), transparent); }
.chips-wrap.fade-l .chips { -webkit-mask-image: linear-gradient(90deg, transparent, #000 44px); mask-image: linear-gradient(90deg, transparent, #000 44px); }
.chips-wrap.fade-l.fade-r .chips { -webkit-mask-image: linear-gradient(90deg, transparent, #000 44px, #000 calc(100% - 44px), transparent); mask-image: linear-gradient(90deg, transparent, #000 44px, #000 calc(100% - 44px), transparent); }
#jump.fade-r .wrap { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); }
#jump.fade-l .wrap { -webkit-mask-image: linear-gradient(90deg, transparent, #000 40px); mask-image: linear-gradient(90deg, transparent, #000 40px); }
#jump.fade-l.fade-r .wrap { -webkit-mask-image: linear-gradient(90deg, transparent, #000 40px, #000 calc(100% - 40px), transparent); mask-image: linear-gradient(90deg, transparent, #000 40px, #000 calc(100% - 40px), transparent); }

/* Cookie choice: a slim bar along the bottom (above the tab bar on phones). The page reserves its height, so it never covers a heading. */
.cg-consent { left: 0; right: 0; bottom: 0; width: auto; border: 0; border-top: 1px solid var(--border2); border-radius: 0; padding: 8px 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px;
  font-size: 14px; line-height: 1.45; box-shadow: 0 -6px 20px rgba(0,0,0,.18); }
.cg-consent p { margin: 0; flex: 1 1 360px; }
.cg-consent .cg-consent-btns { display: flex; gap: 8px; flex: none; }
.cg-consent button { min-width: 112px; padding: 0 18px; }
body.cg-consent-open { padding-bottom: calc(var(--consent-h, 0px) + var(--nav-h) + env(safe-area-inset-bottom)); }
@media (max-width: 999px) { .cg-consent { bottom: calc(var(--nav-h) + env(safe-area-inset-bottom)); } }
@media (min-width: 1000px) { body.cg-consent-open { padding-bottom: var(--consent-h, 0px); } }
@media (max-width: 559px) { .cg-consent .cg-consent-btns { width: 100%; } .cg-consent button { flex: 1; } }

@media (max-width: 559px) { .sortbar { flex-wrap: wrap; } .sortbar .count { flex-basis: 100%; margin-left: 0; } .sortbar button { white-space: nowrap; } }

/* tiles are not ranked by score (2026-10-17): the counts and the bar carry the picture */
.tile-counts { font-size: 12px; color: var(--text2); line-height: 1.35; display: block; }
.tile-counts b { font-family: var(--mono); font-weight: 600; }
.tile-counts .c-harm { color: var(--s-neg); } .tile-counts .c-help { color: var(--s-pos); } .tile-counts .c-neu { color: var(--text); }

/* sanctions cards: two numbers side by side, no winner */
.sanction-row { display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center; }
.sanction-row .sr-pair { display: inline-flex; align-items: center; gap: 8px; }
.sanction-note { font-size: 12px; color: var(--muted); margin: 4px 0 0; }

/* single-country build */
.region-btn, .where { display: none !important; }
.hero { grid-template-columns: minmax(0, 1fr) !important; }
.hero .bignums { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 900px) { .hero .bignums { grid-template-columns: repeat(4, minmax(0, 1fr)); } .hero-copy { max-width: 720px; } }
html.embed body > :not(#sheet):not(#toast):not(script) { display: none !important; }
html.embed .sheet { left: 0; right: 0; top: 0; bottom: 0; width: 100%; max-height: none; border: 0; border-radius: 0; transform: none; }
html.embed .grab { display: none; }
