:root {
  --forest: #1d4636;
  --forest-2: #2d6a52;
  --cream: #f6f2e8;
  --paper: #fffdf8;
  --ink: #1f2522;
  --ink-2: #4d5752;
  --ink-3: #7a847f;
  --line: #e4dfd2;
  --accent: #d9822b;
  --g-a: #0f8a5f;
  --g-b: #62b56b;
  --g-c: #efc43a;
  --g-d: #f08a36;
  --g-e: #dc4a3d;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(25, 40, 33, .16), 0 2px 6px rgba(25, 40, 33, .08);
  --topbar-h: 60px;
  --footer-h: 0px;
  font-family: Figtree, system-ui, -apple-system, Segoe UI, sans-serif;
  color: var(--ink);
  background: var(--cream);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--cream); display: flex; flex-direction: column; overflow: hidden; }
button, select, input { font: inherit; color: inherit; }
a { color: var(--forest-2); }

/* ---------- Top bar ---------- */
.topbar {
  height: var(--topbar-h);
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 16px;
  padding-top: env(safe-area-inset-top);
  background: var(--forest);
  color: var(--cream);
  z-index: 5;
}
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; line-height: 1.05; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center;
  background: var(--cream); color: var(--forest); font-weight: 800; font-size: 20px;
}
.brand-text { font-size: 13px; letter-spacing: .02em; opacity: .92; }
.brand-text b { font-size: 16px; letter-spacing: 0; opacity: 1; }
.tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.tab {
  border: 0; background: transparent; color: var(--cream); opacity: .78; padding: 8px 12px; border-radius: 999px;
  font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap; text-decoration: none;
}
.tab[aria-selected="true"] { background: rgba(255, 255, 255, .14); opacity: 1; }
.tab:hover { opacity: 1; }

main { flex: 1; position: relative; min-height: 0; }

/* ---------- Map view ---------- */
.map-view { position: absolute; inset: 0; }
#map { position: absolute; inset: 0; }
.map-top {
  position: absolute; top: 12px; left: 12px; right: 12px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start;
  pointer-events: none; z-index: 2;
}
.map-top > * { pointer-events: auto; }
.lens-bar {
  display: flex; gap: 6px; max-width: 100%; overflow-x: auto; scrollbar-width: none; padding: 5px;
  background: rgba(255, 253, 248, .92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-radius: 999px; box-shadow: var(--shadow); scroll-snap-type: x proximity;
  mask-image: linear-gradient(90deg, #000 calc(100% - 24px), transparent);
}
.lens-bar::-webkit-scrollbar { display: none; }
.lens {
  flex: none; display: inline-flex; align-items: center; gap: 6px; border: 0; background: transparent; cursor: pointer;
  padding: 8px 13px 8px 10px; border-radius: 999px; font-weight: 700; font-size: 14px; color: var(--ink-2); white-space: nowrap;
  scroll-snap-align: center; transition: background .15s, color .15s, transform .15s;
}
.lens:hover { background: rgba(29, 70, 54, .08); color: var(--ink); }
.lens:active { transform: scale(.96); }
.lens[aria-selected="true"] { background: var(--forest); color: #fff; box-shadow: 0 4px 12px rgba(29, 70, 54, .35); }
.lens-icon { font-size: 17px; line-height: 1; }
.lens-sep { flex: none; width: 1px; margin: 6px 2px; background: var(--line); }

.lens-key {
  background: rgba(255, 253, 248, .95); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px 14px; width: 300px; max-width: 100%;
  animation: pop .25s ease;
}
@keyframes pop { from { opacity: 0; transform: translateY(-4px); } }
.key-head { display: flex; gap: 10px; align-items: flex-start; }
.key-icon { font-size: 26px; line-height: 1; }
.key-head b { font-size: 16px; }
.key-head p { margin: 2px 0 0; font-size: 12.5px; color: var(--ink-2); line-height: 1.35; }
.scale { display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; margin-top: 10px; }
.scale i { height: 20px; border-radius: 5px; display: grid; place-items: center; }
.scale i b { color: #fff; font-size: 12px; font-style: normal; text-shadow: 0 1px 2px rgba(0, 0, 0, .25); }
.scale span { font-size: 11px; color: var(--ink-3); font-weight: 600; grid-column: span 2; }
.scale span:last-child { grid-column: 4 / -1; text-align: right; }
.key-layers { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 5px; font-size: 13px; font-weight: 600; }
.key-layers li { display: flex; align-items: center; gap: 8px; }
.sw { width: 14px; height: 14px; flex: none; background: var(--c); display: inline-block; }
.sw-dot { border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--c); width: 13px; height: 13px; }
.sw-area { border-radius: 3px; opacity: .8; }
.sw-heat { border-radius: 50%; background: radial-gradient(circle, #9c0d38 0 25%, #e03131 45%, #fd7e14 70%, rgba(255, 212, 59, .4)); }
.more-layers { margin-top: 10px; border-top: 1px solid var(--line); padding-top: 8px; }
.more-layers summary { cursor: pointer; font-size: 12.5px; font-weight: 700; color: var(--forest-2); list-style: none; }
.more-layers summary::-webkit-details-marker { display: none; }
.more-layers summary::before { content: "+ "; }
.more-layers[open] summary::before { content: "– "; }
.more-layers > div { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.layer-chip {
  display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--paper);
  border-radius: 999px; padding: 4px 9px 4px 6px; font-size: 12px; font-weight: 600; cursor: pointer;
}
.layer-chip .sw { width: 11px; height: 11px; }
.layer-chip[aria-pressed="true"] { border-color: var(--forest); background: #e7f0eb; }

.hover-tip {
  position: absolute; top: 0; left: 0; z-index: 4; pointer-events: none; display: flex; gap: 10px; align-items: center;
  background: var(--paper); border-radius: 12px; padding: 9px 12px 9px 9px; box-shadow: var(--shadow); max-width: 280px;
}
.hover-tip[hidden] { display: none; }
.hover-tip > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.hover-tip b { font-size: 15px; }
.hover-tip small { font-size: 11.5px; color: var(--ink-3); font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.hover-tip em { font-style: normal; font-size: 12.5px; color: var(--ink-2); }
.tip-grade { flex: none; width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 20px; text-shadow: 0 1px 2px rgba(0, 0, 0, .2); }

.btn-3d { font-weight: 800 !important; font-size: 12px !important; color: var(--forest) !important; }
.btn-3d[aria-pressed="true"] { background: var(--forest) !important; color: #fff !important; }

@media (max-width: 819px) {
  .map-top { top: 8px; left: 8px; right: 8px; gap: 6px; }
  .lens { padding: 7px 11px 7px 9px; font-size: 13.5px; }
  .lens-key { width: auto; padding: 8px 10px; border-radius: 12px; }
  .key-head p { display: none; }
  .key-icon { font-size: 18px; }
  .key-head { align-items: center; gap: 7px; }
  .key-head b { font-size: 14px; }
  .scale { margin-top: 6px; } .scale i { height: 15px; } .scale span { display: none; }
  .key-layers { margin-top: 6px; font-size: 12px; gap: 3px; }
  .more-layers { margin-top: 6px; padding-top: 5px; }
}

/* ---------- Panel / bottom sheet ---------- */
.panel {
  position: absolute; z-index: 3; background: var(--paper); box-shadow: var(--shadow);
  display: flex; flex-direction: column;
}
.panel-body { overflow-y: auto; overscroll-behavior: contain; padding: 4px 18px 24px; }
.sheet-handle { display: none; }

@media (min-width: 820px) {
  .panel { top: 12px; right: 12px; bottom: 12px; width: 400px; border-radius: var(--radius); }
  .panel-body { padding-top: 18px; }
  .map-top { right: 424px; }
  .maplibregl-ctrl-bottom-right { right: 412px !important; }
}
@media (max-width: 819px) {
  .panel {
    left: 0; right: 0; bottom: 0; border-radius: 18px 18px 0 0; max-height: 88%;
    height: var(--sheet-h, 190px); transition: height .25s ease;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .panel.dragging { transition: none; }
  .sheet-handle { display: block; border: 0; background: transparent; height: 22px; width: 100%; cursor: grab; flex: none; touch-action: none; }
  .sheet-handle span { display: block; width: 44px; height: 5px; border-radius: 3px; background: var(--line); margin: 8px auto 0; }
  .maplibregl-ctrl-bottom-right { bottom: calc(var(--sheet-h, 190px) - 4px) !important; }
  .maplibregl-ctrl-bottom-left { display: none; }
}

.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 4px; }
.panel h2 { margin: 0; font-size: 26px; line-height: 1.1; letter-spacing: -.01em; }
.panel .sub { margin: 6px 0 0; color: var(--ink-2); font-size: 14px; }
.panel h3 { font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin: 22px 0 8px; display: flex; justify-content: space-between; align-items: center; }

.grades { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 14px; }
.grade {
  display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 10px; background: var(--cream);
  border: 0; text-align: left; cursor: pointer; min-width: 0;
}
.grade b { width: 26px; height: 26px; flex: none; border-radius: 7px; display: grid; place-items: center; color: #fff; font-size: 15px; }
.grade span { font-size: 12.5px; font-weight: 600; line-height: 1.15; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; }
.grade:hover, .grade:focus-visible { outline: 2px solid var(--forest-2); outline-offset: 1px; }
.g-A { background: var(--g-a); } .g-B { background: var(--g-b); } .g-C { background: var(--g-c); color: #1f2522 !important; } .g-D { background: var(--g-d); } .g-E { background: var(--g-e); }

.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.fact { background: var(--cream); border-radius: 10px; padding: 10px 12px; }
.fact strong { display: block; font-size: 20px; letter-spacing: -.01em; }
.fact small { color: var(--ink-2); font-size: 12.5px; }
.bar { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; margin-top: 6px; }
.bar i { display: block; height: 100%; background: var(--forest-2); border-radius: 4px; }
.bar.warn i { background: var(--g-d); }
.list { margin: 0; padding: 0; list-style: none; font-size: 14.5px; }
.list li { padding: 7px 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 10px; }
.list li:last-child { border-bottom: 0; }
.list .meta { color: var(--ink-3); font-size: 13px; white-space: nowrap; }
.chips { display: flex; flex-wrap: wrap; gap: 5px; }
.chip { font-size: 12.5px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: var(--cream); color: var(--forest); }
.note { font-size: 13px; color: var(--ink-2); background: #f3ecdc; border-left: 3px solid var(--accent); padding: 9px 11px; border-radius: 6px; margin-top: 10px; line-height: 1.45; }
.muted { color: var(--ink-3); font-size: 13px; }
.panel p { line-height: 1.5; font-size: 14.5px; }
.hood-picker { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.hood-picker button { border: 1px solid var(--line); background: var(--paper); border-radius: 999px; padding: 6px 11px; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.hood-picker button:hover { border-color: var(--forest-2); }
.back { border: 0; background: none; padding: 0; color: var(--forest-2); font-weight: 700; font-size: 14px; cursor: pointer; margin-bottom: 8px; }
.share { border: 1px solid var(--line); background: var(--paper); border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 700; cursor: pointer; color: var(--forest); }

/* ---------- Lists view ---------- */
.lists-view { position: absolute; inset: 0; overflow-y: auto; background: var(--cream); }
.lists-inner { max-width: 1040px; margin: 0 auto; padding: 28px 16px 60px; }
.lists-inner h1 { font-size: clamp(26px, 5vw, 38px); margin: 0 0 8px; letter-spacing: -.02em; color: var(--forest); }
.lede { color: var(--ink-2); max-width: 680px; line-height: 1.5; margin: 0 0 20px; }
.persona-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.persona-tabs button { border: 1px solid var(--line); background: var(--paper); padding: 9px 16px; border-radius: 999px; font-weight: 700; cursor: pointer; }
.persona-tabs button[aria-selected="true"] { background: var(--forest); color: var(--cream); border-color: var(--forest); }
.lists-grid { display: grid; gap: 18px; }
@media (min-width: 820px) { .lists-grid { grid-template-columns: 300px 1fr; align-items: start; } .weights { position: sticky; top: 16px; } }
.weights { background: var(--paper); border-radius: var(--radius); padding: 16px; box-shadow: 0 1px 0 var(--line); }
.weights summary { font-size: 15px; font-weight: 700; cursor: pointer; list-style: none; }
.weights summary::-webkit-details-marker { display: none; }
.weights summary::after { content: " ▾"; color: var(--ink-3); }
.weights[open] summary { margin-bottom: 6px; }
.narrow { display: none; }
@media (max-width: 520px) {
  .wide { display: none; } .narrow { display: inline; }
  .tab { padding: 7px 10px; font-size: 13.5px; }
  .topbar { padding: 0 12px; gap: 8px; }
  .brand-text { font-size: 12px; } .brand-text b { font-size: 14.5px; }
}
.weight { display: grid; grid-template-columns: 1fr 38px; align-items: center; gap: 2px 8px; margin: 10px 0; font-size: 14px; font-weight: 600; }
.weight input { grid-column: 1 / -1; width: 100%; accent-color: var(--forest-2); }
.weight output { text-align: right; color: var(--ink-3); font-size: 13px; }
.ranking { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; counter-reset: r; }
.rank-card {
  background: var(--paper); border-radius: var(--radius); padding: 14px 16px; display: grid; grid-template-columns: 40px 1fr auto; gap: 4px 12px; align-items: center;
  box-shadow: 0 1px 0 var(--line); cursor: pointer; border: 0; width: 100%; text-align: left;
}
.rank-card:hover { box-shadow: 0 0 0 2px var(--forest-2); }
.rank-num { font-size: 24px; font-weight: 800; color: var(--forest-2); }
.rank-name { font-size: 18px; font-weight: 700; }
.rank-score { font-size: 22px; font-weight: 800; text-align: right; }
.rank-score small { display: block; font-size: 11px; color: var(--ink-3); font-weight: 600; }
.rank-why { grid-column: 2 / -1; font-size: 13.5px; color: var(--ink-2); }
.rank-grades { grid-column: 2 / -1; display: flex; flex-wrap: wrap; gap: 4px; }
.mini { font-size: 12px; font-weight: 700; padding: 2px 7px; border-radius: 6px; color: #fff; }

/* ---------- Footer ---------- */
.attrib { flex: none; font-size: 11px; color: var(--ink-3); padding: 6px 16px calc(6px + env(safe-area-inset-bottom)); background: var(--cream); border-top: 1px solid var(--line); line-height: 1.4; }
@media (max-width: 819px) { body:not(.page) > .attrib { display: none; } }
.attrib-inline { font-size: 11.5px; color: var(--ink-3); line-height: 1.45; margin-top: 26px; }
@media (min-width: 820px) { .attrib-inline { display: none; } }

.maplibregl-popup-content { font-family: inherit; border-radius: 10px; padding: 10px 12px; font-size: 13.5px; box-shadow: var(--shadow); }
.maplibregl-popup-content b { display: block; font-size: 14px; }

/* ---------- Static pages (methodology, neighbourhood pages) ---------- */
body.page { overflow: auto; display: block; }
.page main { max-width: 760px; margin: 0 auto; padding: 28px 16px 60px; }
.page h1 { font-size: clamp(28px, 6vw, 40px); letter-spacing: -.02em; color: var(--forest); margin: 0 0 12px; line-height: 1.1; }
.page h2 { font-size: 21px; margin: 32px 0 8px; }
.page p, .page li { line-height: 1.6; font-size: 16px; color: var(--ink-2); }
.page table { border-collapse: collapse; width: 100%; font-size: 14.5px; margin: 10px 0; }
.page th, .page td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.page .cta { display: inline-block; background: var(--forest); color: var(--cream); text-decoration: none; padding: 12px 18px; border-radius: 999px; font-weight: 700; margin: 8px 0; }
.page .attrib { display: block; margin-top: 30px; }

/* ---------- Leaderboard + selected headline ---------- */
.board { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 6px; }
.board-row {
  width: 100%; border: 0; cursor: pointer; text-align: left; display: grid; grid-template-columns: 22px 40px 1fr auto; gap: 10px; align-items: center;
  background: var(--cream); border-radius: 12px; padding: 9px 12px 9px 8px; transition: transform .15s, box-shadow .15s, background .15s;
  animation: rise .35s ease both; animation-delay: var(--d);
}
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
.board-row:hover, .board-row.hover { background: #fff; box-shadow: 0 0 0 2px var(--forest-2), var(--shadow); transform: translateX(2px); }
.board-rank { font-weight: 800; color: var(--ink-3); text-align: center; font-size: 14px; }
.board-grade { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 20px; text-shadow: 0 1px 2px rgba(0, 0, 0, .2); }
.board-main { min-width: 0; display: flex; flex-direction: column; }
.board-main b { font-size: 15px; }
.board-main small { font-size: 12px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.board-bar { height: 5px; border-radius: 3px; background: rgba(0, 0, 0, .07); margin-top: 5px; overflow: hidden; }
.board-bar i { display: block; height: 100%; border-radius: 3px; animation: grow .6s ease both; animation-delay: var(--d); transform-origin: left; }
@keyframes grow { from { transform: scaleX(0); } }
.board-score { font-weight: 800; font-size: 18px; text-align: right; }
.board-score small { display: block; font-size: 10.5px; color: var(--ink-3); font-weight: 600; }

.nav-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.nav-row .back { margin: 0; }
.stepper { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; color: var(--ink-3); }
.stepper button { width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); font-size: 18px; line-height: 1; cursor: pointer; color: var(--forest); }
.stepper button:hover:not(:disabled) { background: var(--forest); color: #fff; border-color: var(--forest); }
.stepper button:disabled { opacity: .35; cursor: default; }
.headline {
  display: flex; gap: 12px; align-items: center; margin-top: 12px; padding: 12px; border-radius: 14px;
  background: color-mix(in srgb, var(--c) 14%, var(--paper)); border: 1.5px solid color-mix(in srgb, var(--c) 45%, transparent);
  animation: pop .3s ease;
}
.headline-grade { flex: none; width: 56px; height: 56px; border-radius: 14px; background: var(--c); color: var(--ink, #fff); display: grid; place-items: center; font-size: 30px; font-weight: 800; text-shadow: 0 1px 3px rgba(0, 0, 0, .2); }
.headline > span:last-child { display: flex; flex-direction: column; gap: 1px; }
.headline small { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); }
.headline b { font-size: 15.5px; line-height: 1.25; }
.headline em { font-style: normal; font-size: 12.5px; color: var(--ink-2); }
.grade.active { outline: 2.5px solid var(--forest); outline-offset: 1px; background: #fff; }
.chips .chip { border: 0; cursor: pointer; }
.chip.active { background: var(--forest); color: #fff; }
.sec { border-radius: 12px; transition: background .3s; }
.sec.hot { background: #f1f6f2; margin: 14px -10px 0; padding: 2px 10px 10px; box-shadow: inset 3px 0 0 var(--forest-2); }
.sec.hot h3 { color: var(--forest); }

/* ---------- Who lives here ---------- */
.facts .vs { display: block; font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }
.panel h4 { font-size: 12.5px; font-weight: 700; color: var(--ink-2); margin: 14px 0 6px; }
.stack { display: flex; height: 14px; border-radius: 7px; overflow: hidden; background: var(--line); gap: 2px; }
.stack i { display: block; height: 100%; animation: grow .6s ease both; transform-origin: left; }
.stack-key { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12.5px; color: var(--ink-2); }
.stack-key li { display: flex; align-items: center; gap: 5px; }
.stack-key span { width: 9px; height: 9px; border-radius: 2px; }
.stack-key b { color: var(--ink); }

/* Areas with no data for a category, and places outside the city limits */
.g-none { background: #e2e0da; color: #6b706c; }
.tag-out { font-style: normal; font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #55615b; background: #ecebe5; border-radius: 4px; padding: 1px 5px; margin-left: 4px; vertical-align: 2px; }
.outside-note { font-size: 13px; line-height: 1.45; color: #45504a; background: #f4f2ec; border: 1px dashed #b9b6ab; border-radius: 10px; padding: 10px 12px; margin: 10px 0 0; }

/* Census-area card (zoomed in) */
.area-card { display: grid; gap: 10px; margin-top: 6px; }
.area-card .ac-eyebrow { color: var(--muted, #5f6b65); font-size: 12px; }
.ac-lens { display: flex; gap: 10px; align-items: center; font-size: 13px; line-height: 1.3; }
.ac-lens b { display: block; font-size: 14px; }
.ac-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.ac-chip { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; background: #f3f1ec; border-radius: 6px; padding: 2px 6px 2px 2px; }
.area-card .ac-chip b { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 4px; font-size: 11px; color: #fff; }
.ac-chip b.g-C, .ac-chip b.g-none { color: #1f2522; }
.area-card h4 { margin: 4px 0 0; font-size: 13px; }
.area-card h4 small { font-weight: 400; color: var(--muted, #5f6b65); }
.ac-census { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; font-size: 13px; }
.ac-census li { display: flex; justify-content: space-between; gap: 12px; }
.ac-census li b { display: inline; font-size: 13px; }
.ac-note { margin: 0; font-size: 11.5px; color: var(--muted, #5f6b65); }
.area-card .share { justify-self: start; }
/* Longer shade badges ($ figures) shrink to fit their square */
.board-grade[data-len="4"], .tip-grade[data-len="4"] { font-size: 14px; }
.board-grade[data-len="3"], .tip-grade[data-len="3"] { font-size: 16px; }
.headline-grade[data-len="4"] { font-size: 19px; }
.headline-grade[data-len="3"] { font-size: 23px; }
.census-next { margin: 10px 0 0; padding: 8px 10px; border-radius: 8px; background: #eef4fb; color: #24405e; font-size: 12.5px; line-height: 1.4; }

/* ---------- mapscores.com city picker ---------- */
.home main { max-width: 880px; }
.home .lede { font-size: 18px; max-width: 640px; }
.cities { list-style: none; padding: 0; margin: 12px 0 18px; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.city-card { display: block; background: #fff; border-radius: 16px; overflow: hidden; text-decoration: none; color: var(--ink); box-shadow: 0 2px 10px rgba(29, 70, 54, .1); transition: transform .15s, box-shadow .15s; }
.city-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(29, 70, 54, .18); }
.city-card img { display: block; width: 100%; height: auto; aspect-ratio: 1200 / 630; object-fit: cover; }
.city-body { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px 16px; }
.city-body b { font-size: 19px; color: var(--forest); }
.city-body span { color: var(--ink-2); font-size: 14.5px; line-height: 1.4; }
.city-body .city-go { color: var(--forest-2); font-weight: 700; margin-top: 4px; }
.city-links { font-size: 14px; margin: 10px 4px 0; }

/* ---------- Answer-first summaries, FAQs and neighbourhood link lists ---------- */
.page .answer { font-size: 17.5px; color: var(--ink); background: #fff; border-left: 4px solid var(--forest-2); border-radius: 10px; padding: 12px 16px; }
.page h3 { font-size: 17px; margin: 22px 0 4px; color: var(--ink); }
.page .eyebrow a { color: inherit; text-decoration: none; }
.hood-links { list-style: none; padding: 0; margin: 10px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 6px 16px; }
.hood-links li { display: flex; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); padding: 6px 0; font-size: 15px; }
.hood-links span { color: var(--ink-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.hood-index { margin-top: 32px; }
.hood-index h2 { font-size: 20px; margin: 0 0 6px; }
.hood-index p { margin: 0 0 6px; }
