
:root {
  --bg: #eef2ef;
  --surface: #ffffff;
  --ink: #14302b;
  --ink-soft: #4a5f5a;
  --line: #cfd9d4;
  --meter: #f2c230;
  --meter-ink: #3a2e00;
  --save: #16774a;
  --warn: #b4441c;
  --field: #f7faf8;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1a18; --surface: #172522; --ink: #e5eeea; --ink-soft: #9fb3ad;
    --line: #2c3f3a; --meter: #f2c230; --meter-ink: #2a2100; --save: #4cc38a;
    --warn: #ff8a5c; --field: #1c2d29; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1a18; --surface: #172522; --ink: #e5eeea; --ink-soft: #9fb3ad;
  --line: #2c3f3a; --meter: #f2c230; --meter-ink: #2a2100; --save: #4cc38a;
  --warn: #ff8a5c; --field: #1c2d29; color-scheme: dark;
}
*, *::before, *::after { box-sizing: inherit; }
html { scroll-padding-top: env(safe-area-inset-top, 0px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem; line-height: 1.55;
  font-variant-numeric: tabular-nums;
}
img, svg { max-width: 100%; }
a { color: inherit; text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--meter); outline-offset: 2px; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 1.25rem; }

header.site { border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .9rem; }
.logo { font-weight: 800; font-stretch: 112%; font-size: 1.25rem; text-decoration: none; letter-spacing: -.01em; display: flex; align-items: center; gap: .45rem; }
.logo-mark { width: 26px; height: 26px; border-radius: 50%; background: var(--meter); display: grid; place-items: center; color: var(--meter-ink); font-size: .8rem; font-weight: 800; }
nav.top { display: flex; gap: 1.2rem; font-size: .95rem; }
nav.top a { text-decoration: none; color: var(--ink-soft); }
nav.top a:hover { color: var(--ink); }
@media (max-width: 640px) { nav.top { display: none; } }

/* Hero */
.hero { padding: 2.5rem 0 1.5rem; }
.hero-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 2.5rem; align-items: start; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 1.5rem; } }
h1 {
  font-size: clamp(2.2rem, 5.2vw, 3.6rem); line-height: 1.02; margin: 0 0 1rem;
  font-weight: 800; font-stretch: 78%; letter-spacing: -.015em;
}
.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 34ch; margin: 0 0 1.5rem; }
.facts { display: grid; grid-template-columns: repeat(3, auto); gap: 1.25rem; justify-content: start; margin: 0; }
.facts div { border-left: 3px solid var(--meter); padding-left: .7rem; }
.facts dt { font-size: .85rem; color: var(--ink-soft); }
.facts dd { margin: 0; font-weight: 700; font-size: 1.2rem; }
@media (max-width: 480px) { .facts { grid-template-columns: 1fr 1fr; } }

/* Tool */
.tool { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.tabs { display: flex; border-bottom: 1px solid var(--line); }
.tabs button {
  flex: 1; font: inherit; font-weight: 600; font-size: .95rem; padding: .9rem .5rem; border: 0;
  background: transparent; color: var(--ink-soft); cursor: pointer; border-bottom: 3px solid transparent;
}
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--meter); }
.panel { padding: 1.25rem; }
.panel[hidden] { display: none; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; }
@media (max-width: 480px) { .grid2 { grid-template-columns: 1fr; } }
label { display: block; font-size: .9rem; font-weight: 600; margin-bottom: .3rem; }
.hint { font-weight: 400; color: var(--ink-soft); font-size: .82rem; }
input, select, textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: var(--field);
  border: 1px solid var(--line); border-radius: 8px; padding: .65rem .7rem;
}
textarea { min-height: 110px; resize: vertical; }
.field { margin-bottom: .9rem; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font: inherit; font-weight: 700; font-size: 1rem; padding: .8rem 1.2rem; border-radius: 8px;
  border: 0; cursor: pointer; background: var(--ink); color: var(--bg); width: 100%;
}
.btn.meter { background: var(--meter); color: var(--meter-ink); }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); width: auto; }
.btn:disabled { opacity: .55; cursor: progress; }
.drop {
  border: 2px dashed var(--line); border-radius: 10px; padding: 1.4rem 1rem; text-align: center;
  cursor: pointer; margin-bottom: .9rem; background: var(--field);
}
.drop.over { border-color: var(--meter); }
.drop strong { display: block; margin-bottom: .2rem; }
.status { font-size: .9rem; color: var(--ink-soft); margin: .6rem 0 0; min-height: 1.2em; }
.status.err { color: var(--warn); }
.esi-note { font-size: .85rem; margin-top: .35rem; color: var(--save); min-height: 1.1em; }
.or { text-align: center; font-size: .85rem; color: var(--ink-soft); margin: .6rem 0; }

/* Results */
#results { border-top: 1px solid var(--line); padding: 1.25rem; }
#results[hidden] { display: none; }
.verdict { font-size: 1.35rem; font-weight: 700; line-height: 1.2; margin: 0 0 .3rem; font-stretch: 90%; }
.verdict.good { color: var(--save); }
.verdict.bad { color: var(--warn); }
.sub { color: var(--ink-soft); margin: 0 0 1rem; font-size: .95rem; }
.gauge { position: relative; height: 54px; margin: .5rem 0 1.4rem; }
.gauge-track { position: absolute; left: 0; right: 0; top: 18px; height: 12px; border-radius: 6px;
  background: linear-gradient(90deg, #2e9a63 0%, #9cc34a 35%, #f2c230 60%, #e0772f 80%, #c2371c 100%); }
.pin { position: absolute; top: 0; transform: translateX(-50%); text-align: center; font-size: .75rem; white-space: nowrap; }
.pin::after { content: ""; display: block; width: 2px; height: 30px; margin: 0 auto; background: var(--ink); }
.pin.you { top: auto; bottom: 0; display: flex; flex-direction: column-reverse; }
.pin.you::after { height: 34px; width: 4px; border-radius: 2px; }
.pin b { font-weight: 700; }
.options { display: grid; gap: .7rem; }
.opt { border: 1px solid var(--line); border-radius: 10px; padding: .9rem 1rem; display: grid; grid-template-columns: 1fr auto; gap: .25rem 1rem; align-items: center; }
.opt h3 { margin: 0; font-size: 1rem; }
.opt p { margin: 0; font-size: .88rem; color: var(--ink-soft); grid-column: 1; }
.opt .amt { grid-row: 1 / span 2; grid-column: 2; text-align: right; }
.opt .amt strong { display: block; font-size: 1.15rem; }
.opt .amt span { font-size: .8rem; color: var(--save); font-weight: 600; }
.opt a.go { grid-column: 1 / -1; font-size: .88rem; font-weight: 700; margin-top: .3rem; }
.disclaimer { font-size: .8rem; color: var(--ink-soft); margin: 1rem 0 0; }

/* Ads */
.ad-slot {
  margin: 2rem auto; min-height: 100px; border: 1px dashed var(--line); border-radius: 8px;
  display: grid; place-items: center; color: var(--ink-soft); font-size: .8rem; max-width: 970px;
}

/* Content sections */
section.content { padding: 2.5rem 0; border-top: 1px solid var(--line); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); font-weight: 800; font-stretch: 82%; line-height: 1.1; margin: 0 0 .8rem; letter-spacing: -.01em; }
.prose { max-width: 70ch; }
.prose p { margin: 0 0 1rem; }
.table-tools { display: flex; gap: .8rem; flex-wrap: wrap; align-items: center; margin: 1rem 0; }
.table-tools input { max-width: 260px; }
.scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { text-align: left; padding: .6rem .9rem; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font-size: .85rem; color: var(--ink-soft); font-weight: 600; background: var(--field); position: sticky; top: 0; }
th button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
td.num, th.num { text-align: right; }
tr:last-child td { border-bottom: 0; }
.bar { display: inline-block; height: 8px; border-radius: 4px; background: var(--meter); vertical-align: middle; margin-right: .5rem; }
.tag { font-size: .75rem; font-weight: 600; padding: .1rem .45rem; border-radius: 4px; background: var(--field); border: 1px solid var(--line); }
.tag.choice { background: var(--meter); color: var(--meter-ink); border-color: transparent; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; padding: 0; list-style: none; counter-reset: s; margin: 1.2rem 0 0; }
.steps li { counter-increment: s; }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: var(--bg); font-weight: 800; margin-bottom: .6rem; }
.steps h3 { margin: 0 0 .3rem; font-size: 1.05rem; }
.steps p { margin: 0; color: var(--ink-soft); font-size: .95rem; }
@media (max-width: 720px) { .steps { grid-template-columns: 1fr; } }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
@media (max-width: 800px) { .two-col { grid-template-columns: 1fr; } }
.bill-anatomy { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 1rem 1.2rem; }
.bill-anatomy dl { margin: 0; }
.bill-anatomy dt { font-weight: 700; margin-top: .7rem; }
.bill-anatomy dt:first-child { margin-top: 0; }
.bill-anatomy dd { margin: .15rem 0 0; color: var(--ink-soft); font-size: .95rem; }
details { border-bottom: 1px solid var(--line); padding: .9rem 0; max-width: 75ch; }
summary { font-weight: 700; cursor: pointer; font-size: 1.05rem; }
details p { margin: .6rem 0 0; color: var(--ink-soft); }
footer { border-top: 1px solid var(--line); padding: 2rem 0 3rem; font-size: .88rem; color: var(--ink-soft); }
footer .cols { display: flex; flex-wrap: wrap; gap: 2rem; justify-content: space-between; }
footer a { color: var(--ink-soft); }
@media (prefers-reduced-motion: no-preference) {
  .pin { transition: left .6s cubic-bezier(.2,.8,.2,1); }
}

.crumbs{font-size:.85rem;color:var(--ink-soft);padding-top:1rem}
.crumbs a{color:var(--ink-soft)}
.state-links{display:flex;flex-wrap:wrap;gap:.5rem;padding:0;list-style:none}
.state-links a{display:inline-block;padding:.35rem .7rem;border:1px solid var(--line);border-radius:6px;text-decoration:none;font-size:.92rem;background:var(--surface)}
.state-links a:hover{border-color:var(--meter)}
.statbox{display:grid;grid-template-columns:repeat(4,1fr);gap:1rem;margin:1.2rem 0}
.statbox div{background:var(--surface);border:1px solid var(--line);border-radius:10px;padding:.8rem 1rem}
.statbox dt{font-size:.82rem;color:var(--ink-soft)}.statbox dd{margin:0;font-weight:700;font-size:1.3rem}
@media(max-width:640px){.statbox{grid-template-columns:1fr 1fr}}
.prose ul{padding-left:1.2rem}.prose li{margin-bottom:.35rem}
td a{font-weight:600}
