:root {
  --bg: #f6f6f3;
  --surface: #ffffff;
  --text: #17171a;
  --muted: #6b6b70;
  --border: #e2e2dc;
  --accent: #2f5d8a;
  --accent-text: #ffffff;
  --chip: #ecece7;
  --block: #b3261e;
  --block-bg: #fdecea;
  --age: #8a5a00;
  --age-bg: #fdf3dd;
  --ok: #1e6b3a;
  --ok-bg: #e6f4ea;
  --code-bg: #f1f1ed;
  --radius: 14px;
  /* Area accents (AA on the surface and the page background, both themes). */
  --sellers: #2f5d8a;
  --sellers-text: #ffffff;
  --elder: #1f6b5c;
  --elder-text: #ffffff;
  --shadow: 0 1px 2px rgba(20, 20, 30, 0.06), 0 4px 14px rgba(20, 20, 30, 0.05);
  /* Spacing and type scales. */
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px;
  --fs-sm: 0.875rem; --fs-lg: 1.125rem; --fs-xl: 1.375rem; --fs-2xl: clamp(1.75rem, 5.5vw, 2.4rem);
  --tap: 44px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111113;
    --surface: #1b1b1e;
    --text: #ededee;
    --muted: #9b9ba1;
    --border: #2c2c31;
    --accent: #86b0dc;
    --accent-text: #0e1620;
    --chip: #26262b;
    --block: #ff8a80;
    --block-bg: #3a1a18;
    --age: #f0c46c;
    --age-bg: #362a12;
    --ok: #8fd6a6;
    --ok-bg: #16301f;
    --code-bg: #232327;
    --sellers: #86b0dc;
    --sellers-text: #0e1620;
    --elder: #7cc8b4;
    --elder-text: #0d1f1a;
    --shadow: none;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font: 17px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); }
code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 0.9em; }

/* ---------- Lookup app ---------- */
body.app { min-height: 100dvh; display: flex; flex-direction: column; }
.bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; max-width: 640px; width: 100%; margin: 0 auto;
}
.brand { font-weight: 700; letter-spacing: -0.01em; color: var(--text); text-decoration: none; }
.bar nav a { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.stage { flex: 1; width: 100%; max-width: 640px; margin: 0 auto; padding: 8px 16px 40px; }
.foot { text-align: center; color: var(--muted); font-size: 0.8rem; padding: 16px; }

.step { animation: rise 220ms ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .step { animation: none; } }

.step h1 { font-size: clamp(1.8rem, 6vw, 2.4rem); letter-spacing: -0.02em; line-height: 1.15; margin: 12vh 0 20px; }
#step-what h1 { margin-top: 8px; }

input, select {
  font: inherit; color: var(--text); background: var(--surface);
  border: 1.5px solid var(--border); border-radius: var(--radius); padding: 12px 14px;
}
input:focus, select:focus { outline: none; border-color: var(--accent); }
input.big { width: 100%; font-size: 1.5rem; padding: 16px 18px; margin-bottom: 10px; }
input.small { width: 100%; margin-top: 12px; }
.tip { color: var(--muted); font-size: 0.85rem; margin: 0 0 20px; }

button { font: inherit; cursor: pointer; }
.go {
  width: 100%; margin-top: 20px; padding: 16px; border: 0; border-radius: var(--radius);
  background: var(--accent); color: var(--accent-text); font-weight: 600; font-size: 1.05rem;
}
.go:disabled { opacity: 0.55; cursor: default; }
.back { background: none; border: 0; color: var(--muted); padding: 4px 0; margin-top: 8px; font-size: 0.95rem; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.chips button {
  border: 1.5px solid transparent; background: var(--chip); color: var(--text);
  padding: 10px 16px; border-radius: 999px; font-size: 0.98rem;
}
.chips button[aria-checked="true"] { background: var(--accent); color: var(--accent-text); }
.chips button:focus-visible { border-color: var(--accent); outline: none; }

.route { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.lbl { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: var(--muted); margin-top: 12px; }
.lbl input { width: 100%; font-size: 1rem; }
.route label { flex: 1 1 200px; display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: var(--muted); }
.route input, .route select { width: 100%; font-size: 1rem; }

.error { color: var(--block); margin: 12px 0 0; }

/* Result */
.verdict { text-align: center; margin: 8vh 0 24px; }
.verdict .mark {
  width: 76px; height: 76px; border-radius: 50%; margin: 0 auto 14px;
  display: grid; place-items: center; font-size: 2.2rem; font-weight: 700;
}
.verdict.ok .mark { background: var(--ok-bg); color: var(--ok); }
.verdict.block .mark { background: var(--block-bg); color: var(--block); }
.verdict.age .mark { background: var(--age-bg); color: var(--age); font-size: 1.4rem; }
.verdict h1 { margin: 0 0 6px; font-size: clamp(1.8rem, 6vw, 2.4rem); letter-spacing: -0.02em; }
.verdict p { color: var(--muted); margin: 0; }
.levels { list-style: none; padding: 0; margin: 0 0 16px; border-top: 1px solid var(--border); }
.levels li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 2px; border-bottom: 1px solid var(--border); }
.levels .what { text-align: right; color: var(--muted); }
.levels .what.hit { color: var(--block); }
.note { color: var(--muted); font-size: 0.85rem; }
details.why { margin-top: 8px; }
details.why > summary { cursor: pointer; color: var(--accent); padding: 8px 0; list-style: none; }
details.why > summary::-webkit-details-marker { display: none; }
details.report { margin-top: 8px; }
details.report > summary { cursor: pointer; color: var(--accent); padding: 6px 0; font-size: 0.9rem; }
details.report form { display: flex; flex-direction: column; gap: 8px; }
details.report textarea, details.report select, details.report input { width: 100%; }
.rule { padding: 12px 0; border-bottom: 1px solid var(--border); }
.rule .cite { font-size: 0.85rem; }
.rule pre {
  white-space: pre-wrap; word-break: break-word; background: var(--code-bg); border-radius: 10px;
  padding: 12px; font: 0.8rem/1.5 ui-monospace, Menlo, Consolas, monospace; max-height: 320px; overflow: auto;
}
.again { background: none; border: 1.5px solid var(--border); color: var(--text); border-radius: var(--radius); padding: 14px; width: 100%; margin-top: 24px; }

/* ---------- Account pages (signup / verify / upgrade) ---------- */
.wrap { max-width: 640px; margin: 0 auto; padding: 0 16px; }
.top { padding: 20px 0 8px; }
.top h1 { font-size: 1.8rem; letter-spacing: -0.02em; margin: 8px 0; }
.nav { font-size: 0.9rem; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin: 16px 0; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 0.9rem; }
.field input { width: 100%; }
.card button { background: var(--accent); color: var(--accent-text); border: 0; border-radius: 10px; padding: 11px 18px; }
.card button:disabled { opacity: 0.55; }
.muted { color: var(--muted); }
.ok { color: var(--ok); }
.card h2 { font-size: 1.15rem; margin: 0 0 10px; }
.card button.secondary { background: none; color: var(--text); border: 1.5px solid var(--border); }
.card button.danger { background: none; color: var(--block); border: 1.5px solid var(--border); }
.card button.small { padding: 6px 12px; font-size: 0.85rem; border-radius: 8px; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.table-wrap { overflow-x: auto; }
table.keys { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
table.keys th, table.keys td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.keys th { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }
table.keys code { white-space: nowrap; }
table.keys tr.revoked td { color: var(--muted); }
table.keys .actions { display: flex; gap: 6px; justify-content: flex-end; }
.b-off { background: var(--chip); color: var(--muted); }
.create { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.create input { flex: 1 1 200px; }
.google { min-height: 44px; margin: 12px 0 0; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 0.85rem; margin: 14px 0; }
.or::before, .or::after { content: ""; flex: 1; border-top: 1px solid var(--border); }
@media (max-width: 520px) {
  table.keys .c-created { display: none; }
  /* Stack row buttons so the last one isn't scrolled out of view on phones. */
  table.keys .actions { flex-direction: column; align-items: stretch; gap: 4px; }
  table.keys .actions button { padding: 4px 8px; font-size: 0.82rem; }
  table.keys code { white-space: normal; word-break: break-all; }
}
pre.key { background: var(--code-bg); border-radius: 10px; padding: 12px; font: 0.95rem ui-monospace, Menlo, Consolas, monospace; word-break: break-all; white-space: pre-wrap; }

.brand { font-weight: 700; color: var(--text); text-decoration: none; }
.docs table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.docs th, .docs td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--border); }
.docs h2 { font-size: 1.15rem; margin: 0 0 8px; }
.docs h3 { font-size: 1rem; margin: 18px 0 4px; }
.foot-links { margin-bottom: 6px; }
.foot-links a { color: var(--muted); }

/* Tabs */
.tabs { display: flex; gap: 14px; }
.tabs a { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.tabs a[aria-current="page"] { color: var(--text); font-weight: 600; }

/* Ingredient check */
textarea {
  width: 100%; font: inherit; font-size: 1rem; padding: 14px 16px; resize: vertical;
  border: 1.5px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text);
}
textarea:focus { outline: none; border-color: var(--accent); }
.summary { margin: 28px 0 12px; } .summary h2 { margin: 0; font-size: 1.5rem; letter-spacing: -0.01em; }
.state { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; margin: 10px 0; }
.state h3 { margin: 0 0 8px; font-size: 1.05rem; }
.hit { padding: 8px 0; border-top: 1px solid var(--border); } .hit:first-of-type { border-top: 0; }
.badge { display: inline-block; font-size: .75rem; font-weight: 600; padding: 2px 9px; border-radius: 999px; margin-right: 6px; }
.b-ban { background: var(--block-bg); color: var(--block); }
.b-soon, .b-label { background: var(--age-bg); color: var(--age); }
.b-ok { background: var(--ok-bg); color: var(--ok); }

/* Progress: one segment per step, filled as each is completed */
.progress { list-style: none; display: flex; gap: 6px; padding: 0; margin: 8px 0 0; }
.progress li { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.progress .fill { display: block; height: 4px; border-radius: 2px; background: var(--chip); position: relative; overflow: hidden; }
.progress .fill::after { content: ""; position: absolute; inset: 0; width: 0; background: var(--accent); transition: width 300ms ease; }
.progress li.now .fill::after { width: 40%; }
.progress li.done .fill::after { width: 100%; }
.progress .lbl-step { font-size: 0.75rem; color: var(--muted); }
.progress li.now .lbl-step, .progress li.done .lbl-step { color: var(--text); }
.stage .step h1 { margin-top: 7vh; }
#step-item h1, #step-details h1 { margin-top: 8px; }

/* Route: From → To */
.lane { display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; gap: 8px; }
.lane .end { display: flex; flex-direction: column; gap: 4px; font-size: 0.8rem; color: var(--muted); min-width: 0; }
.lane .end > span { font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }
.lane input { width: 100%; font-size: 1.2rem; padding: 14px; }
.lane small { font-size: 0.75rem; }
.lane .arrow { font-size: 1.5rem; color: var(--accent); padding-top: 34px; }

/* Item tiles */
.group { font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); margin: 18px 0 8px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.tiles button {
  text-align: left; padding: 14px; border-radius: var(--radius); border: 1.5px solid var(--border);
  background: var(--surface); color: var(--text); font-weight: 600; display: flex; flex-direction: column; gap: 2px;
}
.tiles button small { font-weight: 400; font-size: 0.78rem; color: var(--muted); }
.tiles button:hover, .tiles button.on { border-color: var(--accent); }
.lbl-q { margin: 4px 0 8px; font-weight: 600; }
.hit-rule { margin-top: 6px; }
h3.sub { font-size: 1rem; margin: 14px 0 2px; }
.center { text-align: center; }
.levels .what .mini { display: block; color: var(--text); font-size: 0.9rem; }
.levels .what .mini .badge { margin: 0 0 0 6px; }

/* Law pages */
.law-page h1 { margin-top: 8px; }
.law-page h2 { font-size: 1.15rem; margin: 28px 0 4px; }
.law-page .lead { font-size: 1.05rem; }
.crumbs { margin: 8px 0 0; }
.go.cta { display: block; text-align: center; text-decoration: none; margin: 16px 0 8px; }
.levels.linked a { color: var(--text); font-weight: 600; text-decoration: none; }
.state-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px 14px; margin-top: 12px; }
.state-grid a { color: var(--text); text-decoration: none; padding: 6px 0; border-bottom: 1px solid var(--border); }
.drop { display: block; border: 1.5px dashed var(--border); border-radius: var(--radius); padding: 22px; text-align: center; cursor: pointer; background: var(--surface); }
.drop input { display: none; }
.drop:hover { border-color: var(--accent); }

/* Coverage matrix */
.stage.wide { max-width: 1100px; }
.cov-wrap { overflow-x: auto; margin-top: 12px; -webkit-overflow-scrolling: touch; }
.cov { border-collapse: collapse; font-size: 0.85rem; width: 100%; }
.cov th, .cov td { border-bottom: 1px solid var(--border); padding: 5px 6px; text-align: center; white-space: nowrap; }
.cov th[scope="row"] { text-align: left; font-weight: 500; position: sticky; left: 0; background: var(--bg); }
.cov thead th { font-size: 0.75rem; color: var(--muted); }
.cov td a { color: inherit; text-decoration: none; display: block; }
.cov-restricted { background: var(--block-bg); color: var(--block); font-weight: 600; }
.cov-no_restriction_found { color: var(--muted); }
.cov-not_checked { background: var(--age-bg); color: var(--age); }
.cov-key { display: inline-block; min-width: 1.4em; text-align: center; border-radius: 4px; }

/* Alert settings */
.check { display: block; font-size: 0.95rem; }
.check input { margin: 0 6px 0 0; vertical-align: -2px; }
.alerts-detail { border: 0; padding: 0; margin: 12px 0 0; }
.topic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px 14px; margin: 6px 0 12px; }
.tip.scope { margin: -10px 0 18px; }

/* Home: what this is */
.about { margin: 56px 0 8px; border-top: 1px solid var(--border); padding-top: 28px; }
.about h2 { font-size: 1.5rem; letter-spacing: -0.01em; margin: 0 0 6px; }
.about .lead { color: var(--muted); margin: 0 0 18px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin: 0 0 22px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; }
.stat strong { display: block; font-size: 1.35rem; letter-spacing: -0.01em; }
.stat span { color: var(--muted); font-size: 0.8rem; }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; }
.feature { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; }
.feature h3 { margin: 0 0 4px; font-size: 1rem; }
.feature p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.how { margin: 22px 0 8px; padding-left: 20px; }
.how li { margin: 6px 0; }
.ctas { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 10px; }
.pill { border: 1.5px solid var(--border); border-radius: 999px; padding: 8px 14px; text-decoration: none; color: var(--text); font-size: 0.92rem; }
.pill:hover { border-color: var(--accent); }
.plan-price { font-size: 1.3rem; font-weight: 700; margin: 2px 0 4px; }
.plan ul { padding-left: 18px; margin: 8px 0 0; }

/* ---------- Shell: home, states, facts categories (elder care) ---------- */
.shell .bar nav.tabs { gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
.pick { display: grid; gap: 4px; }
.topics { display: grid; gap: 10px; margin: 18px 0; }
@media (min-width: 560px) { .topics { grid-template-columns: 1fr 1fr; } }
.topic { display: flex; align-items: center; justify-content: center; text-align: center; font-size: 1.15rem; font-weight: 600; padding: 22px 16px; border: 2px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); text-decoration: none; }
.topic:hover, .topic.on { border-color: var(--accent); }
.topic.on { box-shadow: inset 0 0 0 1px var(--accent); }
.step { margin-bottom: 8px; }
.step .lbl { font-size: 1rem; font-weight: 600; color: var(--text); }
.home-foot { margin-top: 28px; }
.pick select, .pick input { width: 100%; font-size: 1.05rem; }
.cat-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; }
.cat-tile { display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 14px 16px; text-decoration: none; color: var(--text); }
.cat-tile span { color: var(--muted); font-size: 0.9rem; }
.cat-tile:hover { border-color: var(--accent); }
.cat-sec { border-top: 1px solid var(--border); margin-top: 24px; }
.banner { background: var(--age-bg); color: var(--text); border-radius: var(--radius); padding: 12px 14px; margin: 12px 0 8px; }
.banner p { margin: 0 0 6px; } .banner p:last-child { margin: 0; }
.gotcha { background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--block); border-radius: var(--radius); padding: 12px 14px; margin: 10px 0; }
.gotcha h3 { margin: 0 0 4px; font-size: 1rem; }
.gotcha p { margin: 0 0 6px; }
.ftiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 8px; margin: 8px 0 12px; }
.ftile { display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 12px; color: var(--text); text-decoration: none; min-width: 0; }
.ftile:hover { border-color: var(--accent); }
.ftile-label { color: var(--muted); font-size: 0.78rem; }
.ftile strong { font-size: 1rem; overflow-wrap: anywhere; }
.ftile .badge, .ftile .tag-arch { align-self: flex-start; }
.ftile-yr, .yr { display: block; font-size: 0.8rem; color: var(--muted); margin: 2px 0; overflow-wrap: anywhere; }
.yr-h { font-weight: 600; }
.ftile-yr.yr-next .yr-h, .yr.yr-next .yr-h { color: var(--accent); }
.ftile-yr .badge { font-size: 0.7rem; }
.c-high { background: var(--ok-bg); color: var(--ok); }
.c-medium { background: var(--age-bg); color: var(--age); }
.c-low { background: var(--block-bg); color: var(--block); }
.c-unknown, .c-sec { background: var(--chip); color: var(--muted); }
.tag-arch { display: inline-block; font-size: 0.75rem; padding: 2px 9px; border-radius: 999px; border: 1px dashed var(--border); color: var(--muted); margin-right: 6px; }
.fact { padding: 12px 0; border-bottom: 1px solid var(--border); }
.fact-head { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.fact-label { font-weight: 600; margin-right: 6px; }
.fact-value { margin-top: 4px; overflow-wrap: anywhere; }
.nc { color: var(--muted); font-style: italic; }
details.src > summary { cursor: pointer; color: var(--accent); font-size: 0.85rem; padding: 4px 0; }
.src-body { background: var(--code-bg); border-radius: 10px; padding: 10px 12px; font-size: 0.9rem; overflow-wrap: anywhere; }
.src-body p { margin: 0 0 6px; }
.src-body blockquote { margin: 0 0 8px; padding-left: 10px; border-left: 3px solid var(--border); white-space: pre-wrap; }
dl.kv { margin: 4px 0 0; font-size: 0.92rem; }
dl.kv > div { display: flex; gap: 0 8px; flex-wrap: wrap; }
dl.kv dt { color: var(--muted); }
dl.kv dt::after { content: ":"; }
dl.kv dd { margin: 0; flex: 1 1 200px; min-width: 0; }
.flist { padding-left: 18px; margin: 4px 0 0; }
.flist li { margin: 4px 0; }
.contacts { list-style: none; padding: 0; }
.contacts li { padding: 8px 0; border-bottom: 1px solid var(--border); }
.checklist { padding-left: 22px; margin: 8px 0; }
.checklist.notes { list-style: disc; }
.qitem { padding: 10px 0 12px; border-bottom: 1px solid var(--border); }
.qitem h3 { margin: 0 0 4px; font-size: 1rem; }
.qitem > p { margin: 0 0 6px; }
.qstate { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 2px 12px; margin: 8px 0; }
.qstate .fact:last-child { border-bottom: 0; }
.qstate-h { margin: 8px 0 0; font-weight: 600; font-size: 0.9rem; }
.mistake, .cando { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; margin: 10px 0; }
.mistake { border-left: 4px solid var(--block); }
.mistake h3, .cando h4 { margin: 0 0 4px; font-size: 1rem; }
.mistake > p, .cando > p { margin: 0 0 6px; }
.worked { border: 1px dashed var(--border); border-radius: 10px; padding: 4px 12px 2px; margin: 8px 0; overflow-wrap: anywhere; }
details.screener { margin: 16px 0; border: 2px solid var(--accent); border-radius: var(--radius); padding: 4px 14px; background: var(--surface); }
details.screener > summary { cursor: pointer; font-weight: 700; padding: 10px 0; }
.sq-list { list-style: none; padding-left: 0; margin: 8px 0; counter-reset: sq; }
.sq-q { padding: 8px 0 10px; border-bottom: 1px solid var(--border); counter-increment: sq; }
.sq-q legend::before { content: counter(sq) ". "; }
.sq-q fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.sq-q legend { font-weight: 600; padding: 0; }
.sq-q .note, .sq-guide { margin: 4px 0; }
.sq-choices { display: flex; gap: 8px; margin: 8px 0 4px; }
.sq-choices label { flex: 1 1 0; display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border: 1px solid var(--border); border-radius: 10px; background: var(--chip); cursor: pointer; font-weight: 600; }
.sq-choices label:has(input:checked) { border-color: var(--accent); outline: 2px solid var(--accent); }
.sq-choices label:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
.sq-choices input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.sq-result:not(:empty) { border-radius: var(--radius); padding: 12px 14px; margin-top: 14px; border: 1px solid var(--border); overflow-wrap: anywhere; }
.sq-result.sq-likely { background: var(--ok-bg); border-color: var(--ok); }
.sq-result.sq-steps { background: var(--age-bg); border-color: var(--age); }
.sq-result.sq-unlikely { background: var(--block-bg); border-color: var(--block); }
.sq-reset { margin: 10px 0 0; }
.alt-filter { border: 0; margin: 8px 0 12px; padding: 0; min-width: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.alt-filter legend { font-weight: 600; padding: 0 0 6px; }
.alt-filter label { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--chip); cursor: pointer; font-weight: 600; }
.alt-filter label:has(input:checked) { border-color: var(--accent); outline: 2px solid var(--accent); }
.alt-filter label:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
.alt-filter input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
details.alt-issue { margin: 10px 0; border: 1px solid var(--border); border-radius: var(--radius); padding: 2px 14px; background: var(--surface); }
details.alt-issue > summary { cursor: pointer; padding: 8px 0; }
details.alt-issue > summary h3 { display: inline; font-size: 1.05rem; margin: 0; }
.alt-options { list-style: none; padding-left: 0; margin: 4px 0 10px; }
.alt-option { padding: 10px 0 12px; border-top: 1px solid var(--border); overflow-wrap: anywhere; }
.alt-option h4 { margin: 0 0 4px; font-size: 1rem; }
.alt-option dl.alt-kv > div { display: block; margin-top: 6px; }
.alt-option dl.alt-kv dt { font-weight: 600; }
.alt-is-medicaid, .alt-needs-medicaid { border-left: 3px solid var(--age); padding-left: 10px; }
details.federal { margin-top: 28px; border: 1px solid var(--border); border-radius: var(--radius); padding: 4px 14px; background: var(--surface); }
details.federal > summary { cursor: pointer; font-weight: 600; padding: 10px 0; }
details.federal h3 { font-size: 1rem; margin: 18px 0 4px; }
table.cmp { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
table.cmp th, table.cmp td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--border); vertical-align: top; }
table.cmp thead button { background: none; border: 0; padding: 0; color: var(--muted); font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }
table.cmp th[scope="row"] a { color: var(--text); }
.calc { border-top: 1px solid var(--border); margin-top: 24px; }
.lbl select { width: 100%; font-size: 1rem; }
.calc-result:not(:empty) { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; margin-top: 14px; overflow-wrap: anywhere; }
.big-answer { font-size: 1.25rem; font-weight: 700; margin: 0 0 6px; }
.refuse { background: var(--block-bg); color: var(--text); border-radius: 10px; padding: 10px 12px; margin: 6px 0; }
.refuse strong { color: var(--block); }
.lbl input[type="date"] { width: 100%; }

/* ---------- Areas: sellers and elder care (scripts/brand.ts AREAS) ---------- */
/* Each area sets the accent; elder care also reads larger and roomier. */
.area-sellers { --accent: var(--sellers); --accent-text: var(--sellers-text); }
.area-elder { --accent: var(--elder); --accent-text: var(--elder-text); }
.area-sellers, .area-elder, .area-site { --accent-soft: color-mix(in srgb, var(--accent) 13%, transparent); }
body.area-elder { font-size: 18.5px; line-height: 1.6; }
body.area-elder .note, body.area-elder .tip { font-size: 0.92em; }
body.area-elder .law-page h2 { font-size: 1.3rem; margin-top: var(--s6); }
body.area-elder .stage { max-width: 720px; }
body.area-elder .ftile-label { font-size: 0.85rem; }
body.area-elder .crumbs { font-size: 0.85em; }
h1, h2, h3 { line-height: 1.2; }
body.area-elder .lbl { font-size: 0.95rem; }
body.area-elder .lbl > span { font-weight: 600; color: var(--text); }

/* Focus: one visible ring everywhere. */
a:focus-visible, button:focus-visible, summary:focus-visible, .choice:focus-visible {
  outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px;
}
input:focus-visible, select:focus-visible, textarea:focus-visible { box-shadow: 0 0 0 3px var(--accent-soft); }

/* Header */
.site-head { background: var(--surface); border-bottom: 1px solid var(--border); }
.head-in {
  max-width: 1100px; margin: 0 auto; padding: var(--s2) var(--s4);
  display: flex; flex-wrap: wrap; align-items: center; gap: 0 var(--s4);
}
.site-head .brand { order: 1; display: inline-flex; align-items: center; gap: var(--s2); min-height: var(--tap); color: var(--text); text-decoration: none; }
.brand-name { font-weight: 700; letter-spacing: -0.01em; }
.brand-area {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.02em; color: var(--accent);
  background: var(--accent-soft); padding: 3px 9px; border-radius: 999px; white-space: nowrap;
}
.area-nav { order: 2; flex: 1 1 auto; display: flex; gap: 2px; min-width: 0; }
.area-nav a {
  display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 var(--s3);
  border-radius: 10px; color: var(--text); text-decoration: none; font-size: 0.95rem; white-space: nowrap;
}
.area-nav a:hover { background: var(--chip); }
.area-nav a[aria-current="page"] { color: var(--accent); background: var(--accent-soft); font-weight: 600; }
.topics-link {
  order: 3; display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 var(--s2);
  color: var(--muted); text-decoration: none; font-size: 0.9rem; white-space: nowrap;
}
.topics-link::before { content: "⇆"; margin-right: 6px; font-size: 1rem; }
.topics-link:hover { color: var(--text); }
/* Narrow screens: brand and "All topics" on the first row; the nav is a
   second row that scrolls sideways inside itself (never the page). */
@media (max-width: 900px) {
  .topics-link { order: 2; margin-left: auto; }
  .area-nav {
    order: 3; flex-basis: 100%; overflow-x: auto; scrollbar-width: none;
    margin: 0 calc(-1 * var(--s4)); padding: 0 var(--s3) var(--s1);
    -webkit-mask-image: linear-gradient(to right, #000 88%, transparent);
    mask-image: linear-gradient(to right, #000 88%, transparent);
  }
  .area-nav::-webkit-scrollbar { display: none; }
  .area-site .area-nav { -webkit-mask-image: none; mask-image: none; }
}

/* Footer */
.site-foot { border-top: 1px solid var(--border); margin-top: var(--s7); background: var(--surface); }
.foot-in { max-width: 1100px; margin: 0 auto; padding: var(--s4) var(--s4) var(--s6); color: var(--muted); font-size: var(--fs-sm); }
.site-foot .foot-links { display: flex; flex-wrap: wrap; margin: 0 calc(-1 * var(--s2)) var(--s2); }
.site-foot .foot-links a { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 var(--s2); color: var(--text); text-decoration: none; }
.site-foot .foot-links a:hover { text-decoration: underline; }
.foot-note { margin: 0 0 var(--s2); }
.foot-legal { margin: 0; }
.foot-legal a { color: var(--muted); display: inline-block; padding: 10px 2px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 var(--s5);
  border-radius: 12px; font-weight: 600; font-size: 1rem; text-decoration: none; border: 1.5px solid transparent; cursor: pointer;
}
.btn-primary { background: var(--accent); color: var(--accent-text); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-secondary:hover { border-color: var(--accent); }
.go { min-height: 48px; }
.pill { display: inline-flex; align-items: center; min-height: var(--tap); }
.ctas { gap: var(--s2); }

/* Pages that used the old top header (account, sign-up, verify, docs). */
.stage-page { flex: 1; width: 100%; padding-top: var(--s4); padding-bottom: var(--s6); }
.stage-page > h1 { font-size: 1.8rem; letter-spacing: -0.02em; margin: var(--s2) 0; }
.stage-page > .nav { margin-top: 0; }

/* Home: the two audience choices */
main.home { max-width: 860px; padding-top: var(--s6); }
.home-h { font-size: var(--fs-2xl); letter-spacing: -0.02em; line-height: 1.15; margin: 0 0 var(--s2); }
.home-lead { color: var(--muted); margin: 0 0 var(--s5); font-size: var(--fs-lg); }
.choices { display: grid; gap: var(--s4); }
@media (min-width: 720px) { .choices { grid-template-columns: 1fr 1fr; } }
.choice {
  position: relative; display: flex; flex-direction: column; gap: var(--s2);
  padding: var(--s5) var(--s5) var(--s6); border-radius: 18px; background: var(--surface);
  border: 1.5px solid var(--border); border-top: 6px solid var(--accent); box-shadow: var(--shadow);
  color: var(--text); text-decoration: none; transition: border-color 120ms, transform 120ms;
}
.choice:hover { border-color: var(--accent); transform: translateY(-1px); }
.choice-tag { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.choice-title { font-size: var(--fs-xl); line-height: 1.25; letter-spacing: -0.01em; padding-right: var(--s5); }
.choice-sub { list-style: none; padding: 0; margin: var(--s1) 0 0; color: var(--muted); display: grid; gap: 2px; }
.choice-sub li::before { content: "·"; color: var(--accent); font-weight: 700; margin-right: 8px; }
.choice-go { position: absolute; right: var(--s5); top: var(--s5); font-size: 1.5rem; line-height: 1; color: var(--accent); }
@media (prefers-reduced-motion: reduce) { .choice { transition: none; } .choice:hover { transform: none; } }
.more-topics { margin-top: var(--s6); }
.more-topics h2 { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin: 0; }
.more-topics .ctas { margin-top: var(--s2); }

/* Landing pages (sellers, elder care) */
main.landing { max-width: 860px; }
.landing h2 { font-size: var(--fs-xl); letter-spacing: -0.01em; margin: var(--s6) 0 var(--s3); }
.hero { padding: var(--s5) 0 var(--s2); }
.hero h1, .elder-hero h1 { font-size: var(--fs-2xl); letter-spacing: -0.02em; line-height: 1.15; margin: var(--s2) 0 var(--s3); }
.hero .lead, .elder-hero .lead { font-size: var(--fs-lg); color: var(--muted); margin: 0 0 var(--s4); max-width: 40em; }
.hero-ctas { margin: var(--s4) 0 var(--s5); }
@media (max-width: 480px) { .hero-ctas .btn { flex: 1 1 100%; } }
.landing .features { gap: var(--s3); grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.landing .feature { padding: var(--s4); }
.feature.integ { color: var(--text); text-decoration: none; border-left: 4px solid var(--accent); }
.feature.integ:hover { border-color: var(--accent); }
.feature.integ h3 { color: var(--accent); }
.trust { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s3); }
.trust li { position: relative; padding-left: 30px; }
.trust li::before {
  content: "✓"; position: absolute; left: 0; top: 1px; width: 20px; height: 20px; border-radius: 50%;
  display: grid; place-items: center; font-size: 0.75rem; font-weight: 700; background: var(--accent-soft); color: var(--accent);
}

/* Elder-care landing */
.elder-hero { padding: var(--s5) 0 var(--s2); }
.state-pick { display: grid; gap: var(--s3); margin: var(--s3) 0; max-width: 520px; }
.state-pick .lbl { margin: 0; font-size: 1rem; font-weight: 600; color: var(--text); }
.state-pick select { width: 100%; font-size: 1.1rem; min-height: 52px; }
.pick-actions { display: flex; flex-wrap: wrap; gap: var(--s2); }
.pick-actions .btn { flex: 1 1 auto; }
@media (min-width: 560px) {
  .state-pick { grid-template-columns: minmax(0, 1fr) 13em; align-items: end; }
}
details.all-states { margin: var(--s3) 0 0; }
details.all-states > summary { cursor: pointer; color: var(--accent); min-height: var(--tap); display: flex; align-items: center; font-weight: 600; }
details.all-states .state-grid a { min-height: var(--tap); display: flex; align-items: center; }
.landing section { scroll-margin-top: var(--s4); }
.questions { list-style: none; padding: 0; margin: var(--s3) 0 0; display: grid; gap: var(--s2); }
.questions a {
  display: flex; flex-direction: column; gap: 2px; padding: var(--s3) var(--s4); border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border); color: var(--text); text-decoration: none;
}
.questions a:hover { border-color: var(--accent); }
.questions .q { font-weight: 600; }
.questions .q-what { color: var(--accent); font-size: 0.92em; }
.questions .q-what::after { content: " →"; }
.calc-cards { display: grid; gap: var(--s3); grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.calc-card {
  display: flex; flex-direction: column; gap: var(--s1); padding: var(--s4); border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border); border-top: 4px solid var(--accent); color: var(--text); text-decoration: none;
}
.calc-card:hover { border-color: var(--accent); }
.calc-card span { color: var(--muted); font-size: 0.92em; }

/* State hubs: one card per area */
.area-cards { display: grid; gap: var(--s5); margin-top: var(--s4); }
.cat-sec.area-card {
  border: 1px solid var(--border); border-top: 5px solid var(--accent); border-radius: var(--radius);
  background: var(--surface); padding: var(--s2) var(--s4) var(--s3); margin: 0;
}
.area-card h2 { margin-top: 2px; }
.area-card .ftile { background: var(--bg); }
.area-tag { margin: var(--s3) 0 0; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.toc { margin-top: var(--s2); }
.levels .what.hit { padding: 0; border: 0; }
.levels.linked li { align-items: center; }
