/* Florida Budget Explorer — "Guide Sign"
   The concept: Florida's green highway guide signs. Reflective white type on sign green,
   Overpass (the open-source descendant of the FHWA's Highway Gothic), the state-road shield
   as the mark, and a yellow exit tab on every section. Body copy in Public Sans (USWDS).
   Light palette on :root; dark redefines only what changes, under the OS query (guarded so a
   light stamp wins) and again under [data-theme="dark"] so an explicit toggle wins both ways. */

@font-face { font-family: "Overpass"; src: url("../assets/fonts/overpass-latin-var.woff2") format("woff2"); font-weight: 300 900; font-style: normal; font-display: swap; unicode-range: U+0000-00B6, U+00B8-10FFFF; }
@font-face { font-family: "Public Sans"; src: url("../assets/fonts/publicsans-latin-var.woff2") format("woff2"); font-weight: 300 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Public Sans"; src: url("../assets/fonts/publicsans-latin-italic-var.woff2") format("woff2"); font-weight: 300 600; font-style: italic; font-display: swap; }

:root {
  color-scheme: light;
  --paper: #f5f3ec;
  --paper-2: #ebe8de;
  --card: #ffffff;
  --card-2: #f8f7f2;
  --ink: #0f1f18;
  --ink-2: #33433b;
  --ink-3: #56645d;
  --rule: #dcd8cb;
  --rule-2: #e9e6dc;
  --line: #7d8a83;          /* control borders: >= 3:1 on card and paper */
  --sign: #005a3a;          /* guide-sign green */
  --sign-2: #00492f;
  --sign-deep: #06301f;
  --sign-ink: #ffffff;
  --sign-ink-2: #cfe6da;
  --sun: #ffc72c;           /* exit-tab yellow, only ever behind dark ink or on sign green */
  --sun-ink: #1b1600;
  --link: #00653f;
  --bar: #00714a;
  --link-hover: #004a2e;
  --accent: #b5400c;        /* citrus, for emphasis in text on light grounds */
  --up: #0b6b31;
  --down: #a52a1b;
  --veto: #b3261e;
  --focus: #1b6ef3;
  --shadow: 0 1px 0 rgba(15, 31, 24, .04), 0 10px 28px -18px rgba(15, 31, 24, .28);
  --shadow-lg: 0 2px 0 rgba(15, 31, 24, .04), 0 28px 60px -30px rgba(15, 31, 24, .45);
  /* program-area series — validated (dataviz validate_palette.js, adjacent pairs) on #fff and #f5f3ec */
  --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a; --s4: #eda100; --s5: #e87ba4; --s6: #4a3aa7;
  /* sequential ramp for the county maps: one hue, light -> dark */
  --q0: #edf3ee; --q1: #cfe5d6; --q2: #a3d0b3; --q3: #6fb58d; --q4: #3d9668; --q5: #16784d; --q6: #055a37; --q7: #023d25;
  --map-stroke: #ffffff;
  --map-none: #e7e4da;
  --r: 14px;
  --wrap: 1180px;
  --display: "Overpass", "Highway Gothic", system-ui, -apple-system, "Segoe UI", sans-serif;
  --body: "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #0a1410; --paper-2: #0e1a15; --card: #13201a; --card-2: #182720;
    --ink: #edf3ef; --ink-2: #c6d1cb; --ink-3: #9eaca5; --rule: #26362e; --rule-2: #1d2c25; --line: #73857b;
    --sign: #0b4a31; --sign-2: #083c28; --sign-deep: #052216; --sign-ink-2: #bcd8c9;
    --link: #7fd9ab; --link-hover: #a8ecc8; --bar: #3aa673; --accent: #ff9f66; --up: #5fd38c; --down: #ff8a7a; --veto: #ff7b72; --focus: #8fb8ff;
    --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 12px 30px -18px rgba(0, 0, 0, .7);
    --shadow-lg: 0 2px 0 rgba(0, 0, 0, .3), 0 30px 60px -30px rgba(0, 0, 0, .8);
    --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s5: #d55181; --s6: #9085e9;
    --q0: #15241d; --q1: #173b2a; --q2: #1d5239; --q3: #236b49; --q4: #2c875b; --q5: #3fa572; --q6: #6cc495; --q7: #a8e2c0;
    --map-stroke: #0a1410; --map-none: #1b2a23;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0a1410; --paper-2: #0e1a15; --card: #13201a; --card-2: #182720;
  --ink: #edf3ef; --ink-2: #c6d1cb; --ink-3: #9eaca5; --rule: #26362e; --rule-2: #1d2c25; --line: #73857b;
  --sign: #0b4a31; --sign-2: #083c28; --sign-deep: #052216; --sign-ink-2: #bcd8c9;
  --link: #7fd9ab; --link-hover: #a8ecc8; --bar: #3aa673; --accent: #ff9f66; --up: #5fd38c; --down: #ff8a7a; --veto: #ff7b72; --focus: #8fb8ff;
  --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 12px 30px -18px rgba(0, 0, 0, .7);
  --shadow-lg: 0 2px 0 rgba(0, 0, 0, .3), 0 30px 60px -30px rgba(0, 0, 0, .8);
  --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s5: #d55181; --s6: #9085e9;
  --q0: #15241d; --q1: #173b2a; --q2: #1d5239; --q3: #236b49; --q4: #2c875b; --q5: #3fa572; --q6: #6cc495; --q7: #a8e2c0;
  --map-stroke: #0a1410; --map-none: #1b2a23;
}

/* ---------------- base ---------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; } }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16.5px/1.6 var(--body); text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; }
a { color: var(--link); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--link-hover); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.08; margin: 0; letter-spacing: -.012em; }
p { margin: 0 0 .8em; }
.num, .tnum { font-variant-numeric: tabular-nums; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--sun); color: var(--sun-ink); padding: 10px 14px; border-radius: 8px; font: 800 15px var(--display); text-decoration: none; }
.skip:focus { top: 12px; }
mark { background: color-mix(in srgb, var(--sun) 55%, transparent); color: inherit; border-radius: 2px; padding: 0 1px; }

/* ---------------- header ---------------- */
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 40; background: var(--sign-deep); color: var(--sign-ink); border-bottom: 1px solid rgba(255, 255, 255, .08); }
.site-header .bar { display: flex; align-items: center; gap: 18px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; flex: 0 1 auto; min-width: 0; }
.brand:hover { color: inherit; }
.shield { width: 38px; height: 38px; flex: none; }
.shield rect, .f-seal rect, .pe-mark rect { fill: #111; stroke: #fff; stroke-width: 2; }
.shield-fl path { fill: #fff; }
.brand-t { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.brand-t b, .brand-t small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-t b { font: 800 17px/1.1 var(--display); letter-spacing: -.005em; }
.brand-t small { font: 600 12px/1.3 var(--display); color: var(--sign-ink-2); letter-spacing: .04em; text-transform: uppercase; margin-top: 2px; }
.site-nav { flex: 1; min-width: 0; overflow: hidden; }
.site-nav ul { list-style: none; display: flex; gap: 2px; margin: 0 0 0 auto; padding: 0; flex-wrap: nowrap; width: max-content; }
.site-nav a { display: block; padding: 8px 10px; color: var(--sign-ink-2); text-decoration: none; font: 700 14px/1 var(--display); white-space: nowrap; border-radius: 8px; letter-spacing: .005em; }
.site-nav a:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.site-nav a.active { color: var(--sign-deep); background: var(--sun); }
.tools { display: flex; align-items: center; gap: 8px; flex: none; }
.nav-toggle, .theme-toggle { display: inline-flex; align-items: center; gap: 7px; background: transparent; border: 1px solid rgba(255, 255, 255, .5); color: #fff; border-radius: 9px; padding: 7px 10px; font: 700 13px/1 var(--display); cursor: pointer; }
.nav-toggle:hover, .theme-toggle:hover { background: rgba(255, 255, 255, .1); }
.nav-toggle { display: none; }
.nt-i { width: 16px; height: 11px; background: linear-gradient(#fff 0 0) top/100% 2px no-repeat, linear-gradient(#fff 0 0) center/100% 2px no-repeat, linear-gradient(#fff 0 0) bottom/100% 2px no-repeat; }
.tt-i { width: 14px; height: 14px; border-radius: 50%; box-shadow: inset -4px -2px 0 1px #fff; transform: rotate(-20deg); }
.theme-toggle[aria-pressed="true"] .tt-i { box-shadow: none; background: var(--sun); }
.theme-toggle .tt-l { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.lang-switch select { appearance: none; background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23fff' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right 9px center/10px; color: #fff; border: 1px solid rgba(255, 255, 255, .5); border-radius: 9px; padding: 7px 28px 7px 10px; font: 700 13px/1 var(--display); cursor: pointer; }
.lang-switch select option { color: #111; background: #fff; }
.site-header.nav-collapsed .nav-toggle, .site-header.nav-narrow .nav-toggle { display: inline-flex; }
.site-header.nav-collapsed .site-nav { position: absolute; top: 100%; right: 16px; left: auto; width: min(340px, calc(100vw - 32px)); display: none; overflow: visible; }
.site-header.nav-collapsed.nav-open .site-nav { display: block; }
.site-header.nav-collapsed .site-nav ul { width: auto; margin: 0; flex-direction: column; background: var(--sign-deep); border: 1px solid rgba(255, 255, 255, .15); border-radius: 0 0 14px 14px; padding: 8px; box-shadow: var(--shadow-lg); }
.site-header.nav-collapsed .site-nav a { padding: 12px 12px; font-size: 16px; }
.lang-note { margin: 0; padding: 9px 24px; background: var(--paper-2); color: var(--ink-2); font-size: 13.5px; text-align: center; border-bottom: 1px solid var(--rule); }

/* ---------------- hero: the guide sign ---------------- */
.hero { background: radial-gradient(1200px 500px at 85% -10%, rgba(255, 255, 255, .07), transparent 60%), linear-gradient(180deg, var(--sign-2), var(--sign) 55%, var(--sign-2)); color: var(--sign-ink); padding: 36px 0 0; position: relative; outline: none; }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 96px; background: var(--paper); }
.hero-sign { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .9fr); gap: 36px; align-items: center; }
.hero-sign::before { content: ""; position: absolute; inset: 0 12px; border: 3px solid rgba(255, 255, 255, .92); border-radius: 26px; pointer-events: none; }
.hero-copy { padding: 54px 0 132px 52px; }
.hero-shield { display: inline-block; width: 58px; height: 58px; margin: 0 14px 18px 0; vertical-align: middle; }
.hero-shield svg { width: 100%; height: 100%; display: block; }
.hero-shield rect { fill: #111; stroke: #fff; stroke-width: 2; }
.hero-copy .chip { vertical-align: middle; }
.chip { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 22px; padding: 6px 12px 5px; border-radius: 7px; background: var(--sun); color: var(--sun-ink); font: 800 12.5px/1.2 var(--display); letter-spacing: .09em; text-transform: uppercase; }
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.hero h1 { font-size: clamp(2.5rem, 5.6vw, 4.7rem); font-weight: 850; line-height: .98; letter-spacing: -.028em; margin-bottom: 22px; text-wrap: balance; }
.hero h1 .hl { color: var(--sun); }
@media (min-width: 621px) { .hero h1 .hl { white-space: nowrap; } }
/* Spanish's figure is the longest unbreakable phrase ("$113.8 mil millones"): at the full size it ran up to
   46px out of the column from 1251px up, so the headline tops out smaller there */
:lang(es) .hero h1 { font-size: clamp(2.5rem, 5.1vw, 4.3rem); }
.lede { font-size: clamp(1.06rem, 1.5vw, 1.24rem); line-height: 1.55; color: #eaf4ee; max-width: 38em; margin-bottom: 28px; }
.lede b { color: #fff; }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px; border-radius: 11px; font: 800 15.5px/1.1 var(--display); text-decoration: none; cursor: pointer; border: 2px solid transparent; transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn-sun { background: var(--sun); color: var(--sun-ink); box-shadow: 0 6px 18px -8px rgba(0, 0, 0, .5); }
.btn-sun:hover { color: var(--sun-ink); background: #ffd45a; }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .8); }
.btn-ghost:hover { color: #fff; background: rgba(255, 255, 255, .1); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { color: var(--paper); }
.btn-line { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-line:hover { color: var(--ink); border-color: var(--ink); }
.btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; transform: none; }
.hero-note { font-size: 13.5px; color: var(--sign-ink-2); max-width: 44em; margin: 0; }
.hero-note a { color: #fff; }
.hero-mark { margin: 0; padding: 40px 48px 120px 0; position: relative; }
#hero-map { width: 100%; height: auto; display: block; overflow: visible; }
#hero-map .c { fill: rgba(255, 255, 255, .1); stroke: rgba(255, 255, 255, .35); stroke-width: 1.2; transition: fill .4s ease; }
#hero-map .c.lit { fill: rgba(255, 199, 44, .85); }
#hero-map .st { fill: none; stroke: #fff; stroke-width: 2.4; stroke-linejoin: round; }
#hero-map .cap { fill: var(--sun); stroke: var(--sign-deep); stroke-width: 3; }
#hero-map .cap-l { fill: #fff; font: 800 26px var(--display); paint-order: stroke; stroke: var(--sign-2); stroke-width: 6px; }
.pace { position: absolute; left: 6%; bottom: 128px; font: 700 14px/1.35 var(--display); color: var(--sign-ink-2); letter-spacing: .01em; max-width: 15em; }
.pace b { display: block; font: 850 clamp(1.6rem, 2.6vw, 2.15rem)/1 var(--display); color: #fff; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; position: relative; z-index: 2; }
.hero .stats { margin-top: 28px; padding-bottom: 8px; }   /* below the sign frame, never over its edge */
.stats-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 4px 0 22px; }
.stats-4 { margin: 4px 0 22px; }
.stat { background: var(--card); color: var(--ink); border: 1px solid var(--rule); border-radius: var(--r); padding: 18px 20px 17px; box-shadow: var(--shadow); min-width: 0; }
.stat .v { font: 850 clamp(1.7rem, 2.8vw, 2.35rem)/1 var(--display); letter-spacing: -.025em; margin-bottom: 8px; color: var(--ink); }
.stat .l { font: 800 13px/1.3 var(--display); text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); }
.stat .s { font-size: 13.5px; line-height: 1.45; color: var(--ink-3); margin-top: 5px; }
.stat .s .up { color: var(--up); font-weight: 700; } .stat .s .down { color: var(--down); font-weight: 700; }

/* ---------------- search band ---------------- */
.search-band { padding: 26px 0 10px; }
.search-box { position: relative; max-width: 780px; margin: 0 auto; }
.search-i { position: absolute; left: 18px; top: 50%; width: 22px; height: 22px; transform: translateY(-50%); fill: none; stroke: var(--ink-3); stroke-width: 2.2; stroke-linecap: round; pointer-events: none; }
#budget-search { width: 100%; height: 58px; border-radius: 16px; border: 2px solid var(--line); background: var(--card); color: var(--ink); padding: 0 18px 0 52px; font: 500 17px var(--body); box-shadow: var(--shadow); }
#budget-search::placeholder { color: var(--ink-3); }
#budget-search:focus { outline: none; border-color: var(--link); box-shadow: 0 0 0 4px color-mix(in srgb, var(--link) 22%, transparent), var(--shadow); }
#budget-search-list { position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 6px); margin: 0; padding: 6px; list-style: none; background: var(--card); border: 1px solid var(--rule); border-radius: 14px; box-shadow: var(--shadow-lg); max-height: min(62vh, 520px); overflow: auto; }
#budget-search-list li[role="option"] { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 9px; cursor: pointer; }
#budget-search-list li[aria-selected="true"], #budget-search-list li:hover { background: var(--paper-2); }
.opt-main { min-width: 0; font-weight: 600; }
.opt-sub { display: block; font-weight: 400; font-size: 13px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.opt-kind { font: 800 11px var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); border: 1px solid var(--rule); border-radius: 6px; padding: 3px 7px; white-space: nowrap; }
.opt-amt { font: 800 14px var(--display); font-variant-numeric: tabular-nums; white-space: nowrap; }
.search-empty { padding: 12px; color: var(--ink-3); }
.search-try { text-align: center; margin: 10px 0 0; font-size: 13.5px; color: var(--ink-3); }
.search-try button { background: none; border: 0; padding: 2px 4px; color: var(--link); text-decoration: underline; text-underline-offset: .18em; cursor: pointer; font-size: 13.5px; }

/* ---------------- sections ---------------- */
.section { padding: 84px 0; }
.section.alt { background: var(--paper-2); }
.eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font: 800 13px/1 var(--display); letter-spacing: .12em; text-transform: uppercase; color: var(--link); }
.exit { display: inline-block; background: var(--sun); color: var(--sun-ink); border-radius: 6px; padding: 5px 8px 4px; font-size: 11.5px; letter-spacing: .1em; box-shadow: inset 0 0 0 1.5px rgba(0, 0, 0, .12); }
.eyebrow-inv { color: var(--sun); }
.section h2, .h2 { font-size: clamp(2rem, 3.6vw, 2.9rem); font-weight: 850; letter-spacing: -.024em; margin-bottom: 12px; text-wrap: balance; }
.h-sm { font-size: clamp(1.5rem, 2.4vw, 2rem) !important; }
.intro { font-size: 1.12rem; color: var(--ink-2); max-width: 46em; margin-bottom: 28px; text-wrap: pretty; }
.sec-h3 { font-size: 1.45rem; font-weight: 800; margin: 40px 0 16px; }
.card { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); box-shadow: var(--shadow); padding: 24px; margin-bottom: 18px; min-width: 0; }
.card-h { font-size: 1.22rem; font-weight: 800; margin: 0 0 6px; letter-spacing: -.01em; }
.card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 10px; }
.sub { color: var(--ink-3); font-size: 14.5px; margin: 0 0 16px; }
.note { color: var(--ink-3); font-size: 13.5px; margin: 14px 0 0; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.grid-2 > .card { margin-bottom: 0; }
.grid-2 + .grid-2, .grid-2 + .card, .card + .grid-2 { margin-top: 18px; }
.source-chip, a.source-chip { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; font: 600 12.5px/1.3 var(--body); color: var(--ink-3); text-decoration: none; border: 1px solid var(--rule); border-radius: 999px; padding: 4px 10px; }
a.source-chip:hover { color: var(--link); border-color: var(--link); }
a.source-chip::before { content: "↗"; font-weight: 800; }
.seg { display: inline-flex; background: var(--paper-2); border: 1px solid var(--rule); border-radius: 11px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.section.alt .seg { background: var(--card-2); }
.seg button { border: 0; background: transparent; padding: 7px 12px; border-radius: 8px; font: 700 13.5px/1 var(--display); color: var(--ink-2); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.seg button:hover:not([aria-pressed="true"]) { background: var(--rule-2); }
.filter-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin: 4px 0 14px; }
.filter-row input[type="search"], .filter-row select { height: 42px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink); padding: 0 12px; font: 500 15px var(--body); min-width: 0; }
.filter-row input[type="search"] { flex: 1 1 240px; }
.filter-row .count { margin-left: auto; color: var(--ink-3); font-size: 14px; }
.chip-btn { border: 1.5px solid var(--line); background: var(--card); color: var(--ink-2); border-radius: 999px; padding: 6px 12px; font: 700 13px var(--display); cursor: pointer; display: inline-flex; align-items: center; gap: 7px; }
.chip-btn[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13.5px; color: var(--ink-2); }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.reveal { opacity: 1; }
/* reveals start visible and only settle into place: nothing is hidden at rest */
.js .reveal { transform: translateY(12px); transition: transform .6s ease; }
.js .reveal.in { transform: none; }

/* ---------------- calculator ---------------- */
.calc { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 18px; align-items: start; }
.calc .card { margin-bottom: 0; }
.field { margin: 0 0 18px; border: 0; padding: 0; min-width: 0; }
.field > label, .field > legend { display: block; font: 800 14.5px/1.3 var(--display); margin-bottom: 7px; color: var(--ink); padding: 0; }
.field select { width: 100%; height: 48px; border: 1.5px solid var(--line); border-radius: 11px; background: var(--card); color: var(--ink); padding: 0 12px; font: 500 16px var(--body); }
.hint { color: var(--ink-3); font-size: 13.5px; margin: 7px 0 0; line-height: 1.5; }
.money-in { display: flex; align-items: center; gap: 8px; height: 54px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--card); padding: 0 14px; }
.money-in:focus-within { border-color: var(--link); box-shadow: 0 0 0 4px color-mix(in srgb, var(--link) 20%, transparent); }
.money-in > span { font: 800 20px var(--display); color: var(--ink-3); }
.money-in input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--ink); font: 850 24px var(--display); letter-spacing: -.01em; font-variant-numeric: tabular-nums; outline: none; padding: 0; }
.money-in .per { font: 600 14px var(--body); color: var(--ink-3); white-space: nowrap; }
.money-in.sm { height: 46px; }
.money-in.sm input { font-size: 19px; }
.money-in input[aria-invalid="true"] { color: var(--down); }
.tv-note { color: var(--down); font-size: 13.5px; font-weight: 600; margin: 6px 0 0; }
.preset-row { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 9px; align-items: center; }
.preset-l { font-size: 13px; color: var(--ink-3); margin-right: 2px; }
.preset-row button { border: 1.5px solid var(--line); background: var(--card-2); color: var(--ink-2); border-radius: 9px; padding: 7px 11px; font: 700 13px var(--display); cursor: pointer; }
.preset-row button[aria-pressed="true"] { background: var(--sign); color: #fff; border-color: var(--sign); }
.field-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.field-grid .field { margin-bottom: 12px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; cursor: pointer; margin-bottom: 10px; }
.check input { width: 19px; height: 19px; margin: 2px 0 0; accent-color: var(--sign); flex: none; }
details.more { border-top: 1px dashed var(--rule); margin-top: 6px; padding-top: 12px; }
details.more > summary, details.method > summary, .see-table > summary, details.gl > summary, details.rec > summary { cursor: pointer; font: 800 14.5px/1.3 var(--display); color: var(--link); list-style: none; display: flex; align-items: center; gap: 8px; }
details > summary::-webkit-details-marker { display: none; }
details.more > summary::before, details.method > summary::before, .see-table > summary::before, details.gl > summary::before, details.rec > summary::before { content: ""; width: 9px; height: 9px; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: rotate(-45deg); transition: transform .2s ease; flex: none; margin-right: 2px; }
details[open] > summary::before { transform: rotate(45deg) !important; }
details.more[open] > summary { margin-bottom: 14px; }
details.more .field-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* the receipt */
.calc-out { position: sticky; top: 84px; }
.receipt { background: var(--card-2); border: 1px solid var(--rule); border-radius: 12px 12px 0 0; padding: 20px 20px 26px; position: relative; margin-bottom: 26px; font-family: var(--display); }
.receipt::after { content: ""; position: absolute; left: -1px; right: -1px; bottom: -12px; height: 12px; background: linear-gradient(-45deg, transparent 8px, var(--card-2) 0) 0 0/16px 12px repeat-x, linear-gradient(45deg, transparent 8px, var(--card-2) 0) 0 0/16px 12px repeat-x; }
.r-big { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.r-big .v { font: 900 clamp(2.8rem, 5.2vw, 4rem)/1 var(--display); letter-spacing: -.035em; color: var(--sign); font-variant-numeric: tabular-nums; }
:root[data-theme="dark"] .r-big .v { color: var(--sun); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .r-big .v { color: var(--sun); } }
.r-big .u { font: 700 16px var(--display); color: var(--ink-2); }
.r-sub { font: 500 15px/1.5 var(--body); color: var(--ink-2); margin-bottom: 14px; }
.r-rows { width: 100%; border-collapse: collapse; font-size: 15px; }
.r-rows th, .r-rows td { padding: 8px 0; border-bottom: 1px dotted var(--line); text-align: left; font-weight: 600; vertical-align: top; }
.r-rows td { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; padding-left: 12px; }
.r-rows th small { display: block; font: 400 12.5px/1.4 var(--body); color: var(--ink-3); }
.r-rows tr.t th, .r-rows tr.t td { border-bottom: 0; border-top: 2px solid var(--ink); padding-top: 11px; font-weight: 900; font-size: 16.5px; }
.r-rows tr.loc th, .r-rows tr.loc td { color: var(--ink-3); font-weight: 600; }
.r-note { font: 400 13px/1.5 var(--body); color: var(--ink-3); margin: 12px 0 0; }
.r-empty { font: 600 15px/1.5 var(--body); color: var(--ink-2); }
.out-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.buys { margin-top: 18px; }
.split-bar { display: flex; height: 40px; border-radius: 10px; overflow: hidden; gap: 2px; background: var(--card); margin: 4px 0 14px; }
.split-bar span { display: block; min-width: 2px; position: relative; }
.split-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px 22px; list-style: none; margin: 0; padding: 0; }
.split-list li { display: grid; grid-template-columns: 12px minmax(0, 1fr) auto; gap: 10px; align-items: baseline; padding: 7px 0; border-bottom: 1px solid var(--rule-2); }
.split-list .dot { transform: translateY(1px); }
.split-list b { font: 850 16px var(--display); font-variant-numeric: tabular-nums; }
.split-list small { display: block; color: var(--ink-3); font-size: 12.5px; }
details.method { margin-top: 14px; padding: 16px 20px; background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); }
details.method[open] > summary { margin-bottom: 12px; }
#method-body { font-size: 14.5px; color: var(--ink-2); max-width: 72em; }
#method-body table { border-collapse: collapse; margin: 8px 0 14px; font-size: 14px; }
#method-body td, #method-body th { border-bottom: 1px solid var(--rule); padding: 6px 14px 6px 0; text-align: left; vertical-align: top; }

/* ---------------- share band ---------------- */
.share-band { background: var(--sign-deep); color: #fff; padding: 34px 0; }
.share-in { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.share-in h2 { color: #fff; margin: 0; }
.share-in .eyebrow { margin-bottom: 8px; }
.share-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.share-panel { margin-top: 22px; background: var(--card); color: var(--ink); border-radius: var(--r); padding: 22px; box-shadow: var(--shadow-lg); }
.share-panel canvas, .share-panel img.preview { width: 100%; max-width: 720px; height: auto; border-radius: 10px; border: 1px solid var(--rule); display: block; }
.share-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.share-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.code-box { width: 100%; min-height: 110px; font: 13px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; border: 1.5px solid var(--line); border-radius: 10px; padding: 10px; background: var(--card-2); color: var(--ink); resize: vertical; }

/* ---------------- bar lists (HTML bars) ---------------- */
.bars { list-style: none; margin: 0; padding: 0; }
.bar-row { display: grid; grid-template-columns: minmax(150px, 30%) minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 6px 0; border-radius: 8px; }
.bar-row .bn { font-weight: 600; font-size: 14.5px; line-height: 1.3; min-width: 0; overflow-wrap: anywhere; }
.bar-row .bn small { display: block; color: var(--ink-3); font-weight: 400; font-size: 12.5px; }
.bar-row .bt { height: 22px; background: var(--rule-2); border-radius: 0 6px 6px 0; position: relative; overflow: hidden; }
.bar-row .bf { height: 100%; border-radius: 0 6px 6px 0; min-width: 2px; transform-origin: left; display: flex; }
.bar-row .bf > i { display: block; height: 100%; }
.bar-row .bf > i + i { border-left: 2px solid var(--card); }
.bar-row .bv { font: 800 14.5px var(--display); font-variant-numeric: tabular-nums; white-space: nowrap; min-width: 5.6em; text-align: right; }
.bar-row .bv small { display: block; font: 600 12px var(--body); color: var(--ink-3); }
.bar-row.home .bn { font-weight: 800; }
.bar-row.home .bn::before { content: "★ "; color: var(--accent); }
.bar-row.dim { opacity: .45; }
.bars .bar-row { padding: 6px 8px; margin: 0 -8px; width: calc(100% + 16px); }
button.bar-row { background: transparent; border: 0; text-align: left; cursor: pointer; color: inherit; font: inherit; }
button.bar-row:hover { background: var(--paper-2); }
button.bar-row:hover .bn { color: var(--link); text-decoration: underline; text-underline-offset: .15em; }
.bars.compact .bar-row { padding-top: 3px; padding-bottom: 3px; }
.bars.compact .bt { height: 16px; }
.axis-note { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-3); margin: 6px 0 0; }
.rank-badge { display: inline-block; min-width: 2.2em; font: 800 12px var(--display); color: var(--ink-3); }

/* compare tool */
.cmp-tool { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 16px; align-items: center; background: var(--card-2); border: 1px solid var(--rule); border-radius: 12px; padding: 16px 18px; margin: 4px 0 16px; }
.cmp-tool select { width: 100%; height: 46px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink); padding: 0 12px; font: 500 15.5px var(--body); }
.cmp-tool label { display: block; font: 800 13.5px var(--display); margin-bottom: 6px; }
.cmp-verdict { font-size: 15.5px; line-height: 1.5; }
.cmp-verdict b { font-family: var(--display); font-size: 1.15em; }

/* ---------------- what changed ---------------- */
.wn-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
a.wn-card { display: block; background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 18px 18px 16px; color: var(--ink); text-decoration: none; box-shadow: var(--shadow); transition: transform .15s ease, border-color .15s ease; }
a.wn-card:hover { transform: translateY(-2px); border-color: var(--link); color: var(--ink); }
.wn-card .k { font: 800 12.5px var(--display); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.wn-card .v { font: 850 1.95rem/1.05 var(--display); letter-spacing: -.02em; margin: 8px 0 6px; font-variant-numeric: tabular-nums; }
.wn-card .d { font-size: 14px; color: var(--ink-2); }
.wn-card .go { display: inline-block; margin-top: 8px; font: 800 13px var(--display); color: var(--link); }
.movers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.mv-list { list-style: none; margin: 0; padding: 0; }
.mv-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; align-items: baseline; padding: 9px 0; border-bottom: 1px solid var(--rule-2); }
.mv-list button { background: none; border: 0; padding: 0; text-align: left; font-weight: 600; color: var(--ink); cursor: pointer; font-size: 14.5px; }
.mv-list button:hover { color: var(--link); text-decoration: underline; }
.mv-list .amt { font: 800 14.5px var(--display); font-variant-numeric: tabular-nums; }
.pos { color: var(--up); } .neg { color: var(--down); }
.mv-list .pct { font: 700 13px var(--display); min-width: 4.4em; text-align: right; }
.callouts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.callout { background: var(--card); border: 1px solid var(--rule); border-left: 5px solid var(--sign); border-radius: 10px; padding: 14px 16px; font-size: 14.5px; }
.callout b { display: block; font: 800 15px var(--display); margin-bottom: 4px; }

/* ---------------- signature band ---------------- */
.signature { background: radial-gradient(900px 600px at 70% 40%, #0b3d29, #04180f 70%); color: #fff; padding: 76px 0; overflow: hidden; }
.sig-in { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 40px; align-items: center; }
.signature h2 { color: #fff; font-size: clamp(2rem, 3.5vw, 2.8rem); font-weight: 850; letter-spacing: -.025em; margin-bottom: 14px; }
.signature h2 span { color: var(--sun); }
.sig-copy > p { color: #cfe3d8; font-size: 1.05rem; }
.sig-legend { list-style: none; margin: 18px 0; padding: 0; display: grid; gap: 4px; }
.sig-legend button { width: 100%; display: grid; grid-template-columns: 14px minmax(0, 1fr) auto; gap: 12px; align-items: center; background: transparent; border: 1px solid transparent; color: #fff; padding: 8px 10px; border-radius: 9px; cursor: pointer; text-align: left; font: 600 15px var(--body); }
.sig-legend button:hover, .sig-legend button[aria-pressed="true"] { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .25); }
.sig-legend b { font: 800 15px var(--display); font-variant-numeric: tabular-nums; }
.sig-legend .dot { width: 14px; height: 14px; }
.sig-note { font-size: 13px; color: #a9c4b6; }
.sig-fig { margin: 0; }
#sig-map { width: 100%; height: auto; display: block; }
#sig-map circle { transition: opacity .25s ease, r .25s ease; }
#sig-map.focus circle:not(.on) { opacity: .14; }
.signature { --s1: #3987e5; --s2: #e06a35; --s3: #1fb07d; --s4: #d99a12; --s5: #e0679a; --s6: #9a90ee; }

/* ---------------- agencies ---------------- */
.agency-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 14px; }
.ag-card { display: flex; flex-direction: column; gap: 6px; text-align: left; background: var(--card); border: 1px solid var(--rule); border-top: 5px solid var(--c, var(--sign)); border-radius: var(--r); padding: 16px 18px; cursor: pointer; box-shadow: var(--shadow); color: var(--ink); transition: transform .15s ease, box-shadow .15s ease; min-width: 0; }
.ag-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.ag-card .an { font: 800 16px/1.25 var(--display); }
.ag-card .aa { font: 850 1.7rem/1 var(--display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.ag-card .ad { font-size: 13.5px; color: var(--ink-3); }
.ag-card .ad .pos, .ag-card .ad .neg { font-weight: 700; }
.ag-card .ab { font-size: 13.5px; color: var(--ink-2); line-height: 1.45; }
.ag-card .area-tag { font: 800 11px var(--display); text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }

/* ---------------- maps ---------------- */
.grid-map { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 18px; margin-bottom: 18px; }
.grid-map > .card { margin: 0; }
.cmap { width: 100%; height: auto; display: block; }
.cmap path { stroke: var(--map-stroke); stroke-width: 1.1; cursor: pointer; transition: opacity .15s ease; }
.cmap path:hover, .cmap path:focus-visible { stroke: var(--ink); stroke-width: 2.5; outline: none; }
.cmap path.sel { stroke: var(--accent); stroke-width: 3; }
.map-legend { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-3); margin-top: 8px; }
.map-legend .ramp { display: flex; height: 12px; border-radius: 3px; overflow: hidden; width: 220px; }
.map-legend .ramp i { flex: 1; }

/* ---------------- tables ---------------- */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: 10px; }
table.li, table.tbl { width: 100%; border-collapse: collapse; font-size: 14.5px; }
table.li caption, table.tbl caption { text-align: left; font: 800 13px var(--display); color: var(--ink-3); padding: 0 0 8px; letter-spacing: .04em; text-transform: uppercase; }
table.li th, table.li td, table.tbl th, table.tbl td { padding: 9px 10px; border-bottom: 1px solid var(--rule-2); text-align: left; vertical-align: top; }
table.li thead th, table.tbl thead th { font: 800 12.5px var(--display); text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); border-bottom: 2px solid var(--rule); white-space: nowrap; }
table.li .num, table.tbl .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.li tr.total th, table.li tr.total td, table.tbl tr.total th, table.tbl tr.total td { font-weight: 800; border-top: 2px solid var(--ink); }
table.tbl tbody tr:hover { background: var(--card-2); }
table.tbl th[aria-sort] button { all: unset; cursor: pointer; display: inline-flex; gap: 4px; align-items: center; }
table.tbl th[aria-sort] button:focus-visible { outline: 3px solid var(--focus); border-radius: 3px; }
table.tbl th[aria-sort="descending"] button::after { content: "↓"; } table.tbl th[aria-sort="ascending"] button::after { content: "↑"; }
.lnk { background: none; border: 0; padding: 0; color: var(--link); font: 700 14.5px var(--body); cursor: pointer; text-align: left; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--link) 35%, transparent); text-underline-offset: .18em; }
.lnk:hover { text-decoration-color: currentColor; }
.party { display: inline-block; font: 800 11px var(--display); border-radius: 5px; padding: 2px 6px; border: 1.5px solid currentColor; color: var(--ink-2); }
.badge-veto { display: inline-block; font: 800 10.5px var(--display); letter-spacing: .06em; text-transform: uppercase; color: var(--veto); border: 1.5px solid currentColor; border-radius: 5px; padding: 1px 5px; margin-left: 6px; vertical-align: 1px; }
.minibar { display: inline-block; height: 8px; background: var(--s3); border-radius: 0 3px 3px 0; vertical-align: middle; margin-right: 8px; }
.more-btn { margin-top: 12px; }
.see-table { margin-top: 12px; }
.see-table[open] > summary { margin-bottom: 10px; }

/* ---------------- charts (SVG) ---------------- */
.chart { overflow-x: auto; outline-offset: 4px; }
.chart svg { display: block; width: 100%; height: auto; }
.chart text { font: 600 12px var(--body); fill: var(--ink-3); }
.chart .ax { stroke: var(--rule); stroke-width: 1; }
.chart .grid { stroke: var(--rule-2); stroke-width: 1; }
.chart .lbl { font: 800 12.5px var(--display); fill: var(--ink); }
.chart-hint { font-size: 12.5px; color: var(--ink-3); margin: 6px 0 0; }
.col-hit { fill: transparent; cursor: default; }

/* ---------------- learn ---------------- */
.process { list-style: none; margin: 14px 0 6px; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0; position: relative; }
.process li { position: relative; padding: 34px 14px 0 0; font-size: 13.5px; color: var(--ink-2); }
.process li::before { content: ""; position: absolute; top: 9px; left: 0; right: 0; height: 4px; background: var(--rule); }
.process li::after { content: ""; position: absolute; top: 3px; left: 0; width: 16px; height: 16px; border-radius: 50%; background: var(--card); border: 3px solid var(--line); }
.process li.done::before { background: var(--sign); }
.process li.done::after { background: var(--sign); border-color: var(--sign); }
.process li.now::after { background: var(--sun); border-color: var(--sign); box-shadow: 0 0 0 5px color-mix(in srgb, var(--sun) 35%, transparent); }
.process b { display: block; font: 800 14.5px/1.25 var(--display); color: var(--ink); margin-bottom: 3px; }
.process time { display: block; font: 800 12px var(--display); color: var(--link); letter-spacing: .05em; text-transform: uppercase; margin-bottom: 4px; }
.say { margin-top: 18px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; background: var(--card-2); border: 1px solid var(--rule); border-radius: 12px; padding: 16px 18px; }
.say b { font: 800 16px var(--display); display: block; margin-bottom: 3px; }
.story { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 22px 0 6px; }
.story-card { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 18px; box-shadow: var(--shadow); }
.story-card .n { font: 900 2rem/1 var(--display); color: var(--sign); letter-spacing: -.02em; margin-bottom: 8px; font-variant-numeric: tabular-nums; }
:root[data-theme="dark"] .story-card .n { color: var(--sun); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .story-card .n { color: var(--sun); } :root:not([data-theme="light"]) .h-five { color: var(--sun); } }
:root[data-theme="dark"] .h-five { color: var(--sun); }
.story-card b { display: block; font: 800 15.5px/1.3 var(--display); margin-bottom: 6px; }
.story-card p { font-size: 14px; color: var(--ink-2); margin: 0; }
.learn-grid { margin-top: 10px; }
details.gl { background: var(--card); border: 1px solid var(--rule); border-radius: 11px; padding: 13px 16px; margin-bottom: 8px; }
details.gl > summary { color: var(--ink); font-size: 15px; }
details.gl[open] > summary { margin-bottom: 8px; color: var(--link); }
details.gl p { font-size: 14.5px; color: var(--ink-2); margin: 0; }
.dl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.dl { display: flex; gap: 12px; align-items: center; background: var(--card); border: 1px solid var(--rule); border-radius: 12px; padding: 13px 14px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 14.5px; }
.dl:hover { border-color: var(--link); color: var(--link); }
.dl .ext { font: 800 11px var(--display); color: #fff; background: var(--sign); border-radius: 6px; padding: 5px 6px; flex: none; }
.dl small { display: block; font-weight: 400; color: var(--ink-3); font-size: 12.5px; }
#status-stamp { margin-top: 22px; display: flex; gap: 16px; align-items: center; border-left: 6px solid var(--sun); }
#status-stamp:empty { display: none; }
.sources { font-size: 14px; color: var(--ink-2); padding-left: 1.2em; columns: 2 380px; column-gap: 34px; }
.sources li { margin-bottom: 7px; break-inside: avoid; }

/* ---------------- drawer ---------------- */
#drawer-scrim { position: fixed; inset: 0; background: rgba(4, 18, 12, .5); z-index: 60; backdrop-filter: blur(2px); }
#drawer { position: fixed; top: 0; bottom: 0; inset-inline-end: 0; width: min(760px, 100vw); background: var(--paper); color: var(--ink); z-index: 61; overflow-y: auto; overscroll-behavior: contain; transform: translateX(102%); transition: transform .36s cubic-bezier(.2, .8, .2, 1); box-shadow: -30px 0 60px -30px rgba(0, 0, 0, .5); }
#drawer.in { transform: none; }
[dir="rtl"] #drawer { transform: translateX(-102%); box-shadow: 30px 0 60px -30px rgba(0, 0, 0, .5); }
[dir="rtl"] #drawer.in { transform: none; }
body.drawer-open { overflow: hidden; }
.detail-head { position: sticky; top: 0; z-index: 2; background: var(--sign); color: #fff; padding: 20px 26px 22px; }
/* the crumb, like the title, keeps clear of the Close button (Spanish "Cámara de Representantes · Distrito 10" ran under "Cerrar" on a phone) */
.detail-head .crumb { font: 800 12px var(--display); letter-spacing: .1em; text-transform: uppercase; color: var(--sun); margin: 0 0 8px; padding-right: 90px; }
.detail-head h3 { font-size: clamp(1.5rem, 3vw, 2.05rem); font-weight: 850; letter-spacing: -.02em; margin: 0 0 8px; padding-right: 90px; outline: none; color: #fff; }
.detail-head .dh-amt { font: 850 1.6rem var(--display); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.detail-head .dh-sub { font-size: 14px; color: var(--sign-ink-2); margin: 4px 0 0; }
.detail-head .dh-sub b { color: #fff; }
.detail-close { position: absolute; top: 18px; inset-inline-end: 18px; background: rgba(255, 255, 255, .12); border: 1.5px solid rgba(255, 255, 255, .7); color: #fff; border-radius: 9px; padding: 7px 12px; font: 800 13.5px var(--display); cursor: pointer; }
.detail-close:hover { background: rgba(255, 255, 255, .22); }
.detail-body { padding: 22px 26px 60px; }
.detail-body h4 { font: 800 1.08rem var(--display); margin: 26px 0 10px; }
.detail-body h4:first-child { margin-top: 0; }
.detail-body p { font-size: 15px; color: var(--ink-2); }
.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 6px; }
.kv div { background: var(--card); border: 1px solid var(--rule); border-radius: 11px; padding: 12px 14px; }
.kv dt { font: 800 11.5px var(--display); letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); }
.kv dd { margin: 4px 0 0; font: 850 1.25rem var(--display); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.kv dd small { display: block; font: 500 12.5px var(--body); color: var(--ink-3); letter-spacing: 0; }
details.rec { background: var(--card); border: 1px solid var(--rule); border-radius: 11px; padding: 12px 15px; margin: 12px 0; }
details.rec[open] > summary { margin-bottom: 8px; }
details.rec p, details.rec li { font-size: 14px; }
.hl-list { margin: 0; padding-left: 1.1em; }
.hl-list li { margin-bottom: 6px; font-size: 14.5px; color: var(--ink-2); }
.li-hit { background: color-mix(in srgb, var(--sun) 40%, transparent) !important; }
.drawer-note { font-size: 13.5px; color: var(--ink-3); background: var(--card-2); border: 1px dashed var(--rule); border-radius: 10px; padding: 10px 12px; }

/* ---------------- tooltip ---------------- */
.tooltip { position: fixed; z-index: 80; pointer-events: auto; max-width: 300px; background: var(--ink); color: var(--paper); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; line-height: 1.45; box-shadow: var(--shadow-lg); opacity: 0; visibility: hidden; transition: opacity .12s ease; }
.tooltip.show { opacity: 1; visibility: visible; }
.tooltip b { font-family: var(--display); }
.tooltip .tt-v { font: 850 18px var(--display); font-variant-numeric: tabular-nums; display: block; margin-top: 2px; }

/* ---------------- footer ---------------- */
.site-footer { background: var(--sign-deep); color: #d5e6dc; padding: 44px 0; }
.foot { display: grid; grid-template-columns: auto 1fr auto; gap: 30px; align-items: center; }
.f-seal { width: 72px; height: 72px; }
.f1 { font-size: 13px; max-width: 60ch; line-height: 1.6; }
.f1 b { display: block; font: 800 16px var(--display); color: #fff; margin-bottom: 4px; }
.f1 a { color: #fff; }
.f-llms { display: inline-block; margin-top: 6px; font-size: 12px; }
.pcg-credit { display: flex; flex-direction: column; align-items: flex-end; gap: 11px; flex: none; }
.pc-lede { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #a9c6b6; }
.pc-logo img { width: 196px; height: auto; opacity: .94; transition: opacity .15s ease, transform .15s ease; }
.pc-logo:hover img, .pc-logo:focus-visible img { opacity: 1; transform: translateY(-1px); }

/* ---------------- print estimate ---------------- */
#print-estimate { display: none; }
@media print {
  @page { size: letter; margin: .5in; }
  body.printing-estimate > *:not(#print-estimate) { display: none !important; }
  body.printing-estimate #print-estimate { display: block !important; color: #000; font: 11pt/1.45 var(--body); }
  body:not(.printing-estimate) .site-header, body:not(.printing-estimate) #drawer, body:not(.printing-estimate) #drawer-scrim, body:not(.printing-estimate) .search-band, body:not(.printing-estimate) .share-band { display: none !important; }
  .pe-head { display: flex; gap: 14px; align-items: center; border-bottom: 3px solid #005a3a; padding-bottom: 10px; margin-bottom: 14px; }
  .pe-head b { display: block; font: 800 18pt var(--display); }
  .pe-head span { font-size: 10pt; color: #333; }
  .pe-mark { width: 46px; height: 46px; }
  .pe-big { font: 900 30pt/1 var(--display); color: #005a3a; margin: 4px 0 6px; }
  .pe-big small { font: 600 11pt var(--body); color: #333; }
  .pe-line { font-size: 10pt; color: #222; margin-bottom: 12px; }
  .pe-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
  .pe-h { font: 800 11pt var(--display); margin: 6px 0; border-bottom: 1px solid #999; padding-bottom: 3px; }
  .pe-table { width: 100%; border-collapse: collapse; font-size: 9.5pt; }
  .pe-table td { padding: 3px 0; border-bottom: 1px dotted #bbb; }
  .pe-table td.r { text-align: right; white-space: nowrap; }
  .pe-table tr.t td { font-weight: 800; border-top: 1.5px solid #000; border-bottom: 0; }
  .pe-bar { display: flex; height: 14px; margin: 6px 0 8px; gap: 1px; }
  .pe-bar i { display: block; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .pe-disc { font-size: 8.5pt; color: #444; margin-top: 14px; }
  .pe-foot { display: flex; justify-content: space-between; border-top: 1px solid #999; margin-top: 16px; padding-top: 8px; font-size: 9.5pt; }
  .shield-fl path { fill: #fff; }
  .pe-mark rect { fill: #111; }
}

/* ---------------- responsive ---------------- */
@media (max-width: 1100px) {
  .hero-copy { padding-left: 40px; }
  .wn-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .story { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .hero-sign { grid-template-columns: 1fr; gap: 0; }
  .hero-copy { padding: 40px 30px 10px; }
  .hero-mark { padding: 0 30px 120px; max-width: 520px; margin: 0 auto; width: 100%; }
  .pace { left: 30px; bottom: 116px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .calc { grid-template-columns: 1fr; }
  .calc-out { position: static; }
  .grid-2, .grid-map, .movers, .sig-in, .share-grid, .cmp-tool { grid-template-columns: 1fr; }
  .callouts { grid-template-columns: 1fr; }
  .section { padding: 64px 0; }
}
@media (max-width: 620px) {
  .wrap { padding: 0 16px; }
  .site-header .bar { gap: 10px; min-height: 58px; }
  .brand-t small { display: none; }
  .brand-t b { font-size: 15px; }
  .lang-switch select { padding: 7px 24px 7px 8px; max-width: 7.5em; }
  .tools { gap: 6px; }
  .site-nav { display: none; }
  .site-header.nav-narrow .site-nav { position: absolute; top: 100%; left: 0; right: 0; width: auto; }
  .site-header.nav-narrow.nav-open .site-nav { display: block; }
  .site-header.nav-narrow .site-nav ul { width: auto; margin: 0; flex-direction: column; background: var(--sign-deep); padding: 8px 12px 14px; border-bottom: 1px solid rgba(255, 255, 255, .15); box-shadow: var(--shadow-lg); }
  .site-header.nav-narrow .site-nav a { padding: 13px 10px; font-size: 16px; }
  .nav-toggle .nt-l { display: none; }
  .hero { padding-top: 16px; }
  .hero-sign::before { inset: 0 8px; border-width: 2.5px; border-radius: 18px; }
  .hero-copy { padding: 30px 22px 6px; }
  .hero-mark { padding: 6px 26px 112px; }
  .pace { left: 26px; bottom: 108px; font-size: 12.5px; }
  .stats, .stats-3, .stats-4 { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat { padding: 14px; }
  .stat .s { font-size: 12.5px; }
  .field-grid, details.more .field-grid { grid-template-columns: 1fr; }
  .wn-grid, .story { grid-template-columns: 1fr; }
  .bar-row { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; }
  .bar-row .bt { grid-column: 1 / -1; grid-row: 2; height: 14px; }
  .card { padding: 18px 16px; }
  .detail-head { padding: 16px 18px 18px; }
  .detail-body { padding: 18px 18px 50px; }
  .foot { grid-template-columns: 1fr; text-align: start; }
  .pcg-credit { align-items: flex-start; }
  .say { grid-template-columns: 1fr; }
  #budget-search { height: 54px; font-size: 16px; }
  .chart svg { min-width: 440px; }
}
@media (max-width: 380px) {
  .stats, .stats-3, .stats-4 { grid-template-columns: 1fr; }
  /* names get their own line: a one-word name ("Administrasyon") is wider than the name column here */
  .mv-list li { grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; }
  .mv-list li > :first-child { grid-column: 1 / -1; }
}
@media (forced-colors: active) {
  .exit, .chip, .btn { border: 2px solid CanvasText; }
  .bar-row .bf, .split-bar span, #sig-map circle { forced-color-adjust: none; }
}

/* strip plot (50 states) and rate columns (67 counties) */
.strip { position: relative; margin: 8px 0 4px; }
.strip svg { display: block; width: 100%; height: auto; overflow: visible; }
.strip .sd { stroke: var(--card); stroke-width: 1.5; cursor: default; }
.strip .sd.fl { fill: var(--accent); stroke: var(--ink); stroke-width: 2; }
.strip .lab { font: 700 12px var(--body); fill: var(--ink-2); }
.strip .lab-fl { font: 800 13px var(--display); fill: var(--ink); }
.strip .ax { stroke: var(--rule); }
.strip .tk { font: 600 11.5px var(--body); fill: var(--ink-3); }
details.full-rank { margin-top: 10px; }
details.full-rank > summary { cursor: pointer; font: 800 14.5px/1.3 var(--display); color: var(--link); list-style: none; display: flex; align-items: center; gap: 8px; }
details.full-rank > summary::before { content: ""; width: 9px; height: 9px; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: rotate(-45deg); transition: transform .2s ease; margin-right: 2px; }
details.full-rank[open] > summary { margin-bottom: 12px; }
.ratecols { display: grid; grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); gap: 10px; align-items: end; margin: 8px 0 6px; }
.ratecol { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ratecol .chips { display: flex; flex-wrap: wrap; gap: 4px; align-content: flex-end; background: var(--card-2); border: 1px solid var(--rule); border-radius: 10px; padding: 8px; min-height: 40px; }
.ratecol .rc-h { text-align: center; border-top: 4px solid var(--c); padding-top: 6px; }
.ratecol .rc-h b { display: block; font: 850 1.4rem/1 var(--display); letter-spacing: -.02em; }
.ratecol .rc-h small { font-size: 12.5px; color: var(--ink-3); }
.cchip { border: 1px solid var(--line); background: var(--card); color: var(--ink); border-radius: 6px; padding: 2px 6px; font: 600 12px/1.4 var(--body); cursor: pointer; white-space: nowrap; }
.cchip:hover { border-color: var(--link); color: var(--link); }
.cchip.home { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 800; }
.cchip.near { border-color: var(--accent); border-width: 2px; }
.ratecols.near-mode .cchip:not(.home):not(.near) { opacity: .35; }
@media (max-width: 620px) { .ratecols { grid-template-columns: 1fr; } .ratecol .rc-h { order: -1; text-align: left; display: flex; gap: 10px; align-items: baseline; border-top: 0; border-left: 4px solid var(--c); padding: 0 0 0 8px; } .ratecol .rc-h b { display: inline; } }

/* embedded widgets */
body.embed { background: var(--paper); }
body.embed .section { padding: 16px 0; }
body.embed .eyebrow, body.embed #tax-intro, body.embed .out-actions #copy-link-btn { display: none; }
body.embed-buys .calc, body.embed-buys #tax-h, body.embed-buys .method { display: none; }
body.embed-buys .buys { margin-top: 0; }
.embed-credit { font-size: 12px; color: var(--ink-3); text-align: center; padding: 8px 16px 14px; }
.embed-credit a { color: var(--link); font-weight: 700; }

.findings { border-left: 6px solid var(--sun); }
.findings .hl-list li { font-size: 15.5px; margin-bottom: 8px; }

/* the Claude Artifact preview: its frame cannot print or save files, so those controls stand down */
body.artifact #print-estimate-btn, body.artifact .dl[download], body.artifact .dl-file { display: none !important; }

/* ---------------- 2026-10-15: first minute, reconciliation, navigation, exports ---------------- */
/* hidden means hidden, whatever display a component sets (short lists, the drawer, panels) */
[hidden] { display: none !important; }
/* data as of: coverage, sources, page update */
.hero-asof { font-size: 12.5px; color: var(--sign-ink-2); max-width: 46em; margin: 10px 0 0; }
/* 5 things to know + why numbers differ, on the sign green under the hero figures */
/* on paper, under the hero's figures: its own full-width paper ground starts halfway up the tiles, so
   the tiles still straddle the green edge (they sit above it, z-index 2) */
.first-min { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 14px; margin-top: -60px; padding: 76px 0 8px; color: var(--ink);
  background: var(--paper); box-shadow: 0 0 0 100vmax var(--paper); clip-path: inset(0 -100vmax); }
.five, .why-differ { background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 16px 18px; box-shadow: var(--shadow); }
.why-differ { border-left: 4px solid var(--sun); }
.h-five { font: 800 15px/1.2 var(--display); letter-spacing: .06em; text-transform: uppercase; color: var(--sign); margin: 0 0 8px; }
.five-list { margin: 0; padding-left: 1.3em; display: grid; gap: 7px; font-size: 14.5px; line-height: 1.45; }
.five-list a, .why-differ a { color: var(--link); font-weight: 700; }
.five-go { white-space: nowrap; }
.why-differ p { margin: 0 0 8px; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.hero-cue { display: none; }
@media (max-width: 620px) { .hero-cue { display: inline-flex; align-items: center; min-height: 44px; color: #fff; font: 800 14.5px var(--display); margin: 6px 0 0; } }
.why-differ p:last-child { margin: 0; }
/* a defined term: a button that reads as text with a dotted underline, opening its definition inline */
.term { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: underline dotted; text-underline-offset: .2em; text-decoration-thickness: 1.5px; }
.term[aria-expanded="true"] { text-decoration-style: solid; }
.term-def { display: block; margin: 6px 0 4px; padding: 8px 10px; border-left: 3px solid var(--sun); background: rgba(0, 0, 0, .14); font-size: 13.5px; line-height: 1.45; border-radius: 0 8px 8px 0; }
.section .term-def, .drawer .term-def, .card .term-def { background: var(--card-2); border-left-color: var(--bar); color: var(--ink-2); }
/* short lists and their buttons; per-table downloads */
.show-more { display: inline-flex; align-items: center; min-height: 44px; margin: 12px 0 0; padding: 8px 16px; border-radius: 10px; border: 2px solid var(--line); background: var(--card); color: var(--ink); font: 800 14.5px var(--display); cursor: pointer; }
.show-more:hover { border-color: var(--ink); }
.dl-mini { display: inline-flex; align-items: center; min-height: 44px; margin: 8px 12px 0 0; font: 700 13.5px var(--body); color: var(--link); }
.dl-row { margin: 0 0 6px; }
.dl-row .dl-mini { margin-top: 0; }
/* back to top */
.to-top { position: fixed; right: max(16px, env(safe-area-inset-right, 0px)); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 40; min-width: 48px; min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 14px; border-radius: 24px; background: var(--sign); color: #fff; font: 800 14px var(--display); text-decoration: none; box-shadow: var(--shadow-lg); border: 2px solid rgba(255, 255, 255, .85); }
.to-top:hover { color: #fff; background: var(--sign-2); }
.to-top[hidden] { display: none; }
/* what is funded near me */
.near-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.near-row .field { margin: 0; flex: 1 1 220px; }
.near-row select { width: 100%; }
.glance { margin-top: 14px; border-top: 1px solid var(--rule); padding-top: 12px; }
.glance h4 { margin: 0 0 4px; }
.glance-h { font: 800 13.5px var(--display); margin: 12px 0 4px; }
.glance .btn { margin-top: 12px; }
/* calculator: the example is labelled, sharing up front, scope beside the result */
.r-sample { display: inline-block; margin: 0 0 8px; padding: 4px 10px; border-radius: 999px; background: var(--sun); color: var(--sun-ink); font: 800 12.5px var(--display); letter-spacing: .03em; text-transform: uppercase; }
.out-share { margin-top: 14px; border-top: 1px solid var(--rule); padding-top: 12px; }
.out-h { font: 800 14px var(--display); margin: 0 0 8px; }
.out-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.calc-scope details.scope { margin-top: 14px; font-size: 13.5px; color: var(--ink-2); }
.calc-scope summary { font: 800 14px var(--display); cursor: pointer; min-height: 44px; display: flex; align-items: center; }
.calc-scope p { margin: 6px 0; }
/* agency panel: why it changed; adjustment rows */
.why-chg { margin: 12px 0; padding: 12px 14px; background: var(--card-2); border-radius: 10px; border: 1px solid var(--rule); }
.why-chg h4 { margin-top: 0; }
.why-chg .cite { margin: 6px 0 0; color: var(--ink-3); }
tr.adj th, tr.adj td { font-style: italic; color: var(--ink-2); }
/* why numbers differ, in full; the change log */
details.differ summary .flag { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--accent); color: var(--accent); font: 700 11.5px var(--body); }
details.differ table th.num { white-space: nowrap; }
.changes { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 6px; font-size: 14px; }
.changes time { font-weight: 700; margin-right: 6px; }
/* charts: what the axis measures, and what to know before reading */
.ax-title { font: 600 12px var(--body); fill: var(--ink-3); }
.chart-scope { font-size: 13.5px; color: var(--ink-2); background: var(--card-2); border-left: 3px solid var(--bar); padding: 8px 12px; border-radius: 0 8px 8px 0; margin: 0 0 10px; }
.counts-note { margin: -8px 0 18px; }
/* the dot map's caveat sits under the map */
.sig-fig .sig-note { margin: 10px 0 0; font-size: 13px; line-height: 1.45; color: var(--sign-ink-2); }
/* footer links: public information first; the commercial invitation last and quieter */
.f-links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 10px; align-items: center; }
.f-links a, .f-btn { min-height: 44px; display: inline-flex; align-items: center; color: inherit; font: 700 13.5px var(--body); }
.f-btn { background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; }
.f-links .f-city { font-weight: 500; opacity: .85; }
.nav-x button { background: none; border: 1px solid rgba(255, 255, 255, .55); color: inherit; border-radius: 8px; font: 700 13px var(--display); padding: 6px 10px; min-height: 36px; cursor: pointer; }
.site-header:not(.nav-collapsed):not(.nav-narrow) .nav-x { display: none; }

/* lone last card: a three-tile strip on two columns lets the third span the row */
@media (max-width: 900px) and (min-width: 381px) { .stats-3 > .stat:nth-child(3):last-child { grid-column: 1 / -1; } }
@media (max-width: 620px) {
  .stats-3 > .stat:nth-child(3):last-child { grid-column: 1 / -1; }
  .first-min { grid-template-columns: 1fr; }
  .hero-shield { display: none; }            /* the header already carries the mark; the map comes up */
  .hero-copy { padding-top: 22px; }
  .hero h1 { margin-bottom: 16px; }
  .brand-t b { white-space: normal; overflow: visible; line-height: 1.05; font-size: 15px; }
}
/* 44 x 44 CSS-pixel targets on touch screens and phones */
@media (pointer: coarse), (max-width: 620px) {
  .nav-toggle, .theme-toggle { min-width: 44px; min-height: 44px; }
  .lang-switch select { min-height: 44px; }
  .skip:focus, .brand { min-height: 44px; }
  .search-try button, .seg button, .preset-row button, .cchip, .sig-legend button, .nav-x button { min-height: 44px; }
  .search-try button { padding: 8px 10px; }
  table.tbl th[aria-sort] button { min-height: 44px; min-width: 44px; }
  .mv-list button { min-height: 44px; }
  select, input[type="search"], .money-in input { min-height: 44px; }
  .check { min-height: 44px; align-items: center; margin-bottom: 4px; }
  .check input { width: 24px; height: 24px; margin: 0; }
  .cchip, .lnk { min-width: 44px; }
  .lnk { min-height: 44px; display: inline-flex; align-items: center; }
  .money-in input { min-height: 44px; }
  details > summary { min-height: 44px; display: flex; align-items: center; }
  .source-chip { min-height: 44px; display: inline-flex; align-items: center; }
  .why-differ p > a, .dl-mini { min-height: 44px; display: inline-flex; align-items: center; }
  .term { min-height: 32px; }
}

@media print {
  body.printing-overview > *:not(#print-overview) { display: none !important; }
  body.printing-overview #print-overview { display: block !important; color: #000; font: 10.5pt/1.4 var(--body); }
  .pe-five { margin: 4px 0 0; padding-left: 1.2em; font-size: 9.5pt; }
  .to-top, .show-more, .dl-mini, .dl-row { display: none !important; }
}
#print-overview { display: none; }
@media (max-width: 420px) { .brand-t b { font-size: 13px; line-height: 1.08; } .brand .shield { width: 34px; height: 34px; } }
