:root {
  --bg: #eef1f8;
  --ink: #1a202c;
  --muted: #5a6478;
  --card: #ffffff;
  --line: #d5dcef;
  --navy: #1a3370;
  --navy-dark: #0f2558;
  --gold: #f0bc1a;
  --gold-light: #ffd040;
  --soft: #e8eef8;
  --amber: #8a5a12;
  --amber-soft: #fff6d8;
  --red: #8d3a2f;
  --red-soft: #f8ebe7;
  --shadow: 0 1px 3px rgba(15, 37, 88, 0.12);
  font-family: Montserrat, system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--bg);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
}

button, select, input { font: inherit; color: inherit; }

.top {
  background: var(--navy);
  color: #ffffff;
  border-bottom: 3px solid var(--gold);
}

.top-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}

.brand {
  display: block;
  width: min(260px, 100%);
  height: auto;
  border-radius: 6px;
}
.brand-link { display: block; width: min(260px, 100%); }
.brand-link .brand { width: 100%; }
.brand-link:focus-visible { outline: 3px solid var(--gold, #f0bc1a); outline-offset: 3px; border-radius: 6px; }

h1, h2, p { margin: 0; }

h1, h2 { color: var(--navy); }
h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.03em; color: #ffffff; }

.top-note {
  margin: 0;
  color: var(--gold);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 20px 20px 48px;
}

.loading, .error {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 18px;
}

.error { color: var(--red); background: var(--red-soft); }

[hidden] { display: none !important; }

.gate {
  display: grid;
  place-items: start center;
  padding-top: 28px;
}
.gate-card {
  width: min(440px, 100%);
  display: grid;
  gap: 12px;
}
.gate-card h2, .account-form { margin: 0; }
.gate-card p, .account-form p { color: var(--muted); line-height: 1.45; }
.gate-card label, .account-form label {
  display: grid;
  gap: 6px;
  color: var(--navy);
  font-size: 13px;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
}
.gate-card input, .account-form input {
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  font: inherit;
  font-size: 16px;
  font-weight: 500;
}
.account-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.account-bar p { color: var(--navy); font-weight: 700; }
.account-list {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  display: grid;
  gap: 8px;
}
.account-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--soft);
}
.account-row strong { margin-right: auto; }
.account-reset {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
}
.account-reset input {
  flex: 1 1 140px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
}
.account-note { color: var(--navy); font-weight: 700; }
.account-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 12px;
  align-items: end;
}
.account-form .error, .account-form .account-note, .account-form .btn { grid-column: 1 / -1; }
.account-form .btn { justify-self: start; }

.files {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.file-card, .stat, .panel, .toolbar {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.file-card { padding: 14px 16px; }
.file-card span, .stat span, .town-picker span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.file-card strong { display: block; margin: 4px 0; font-size: 18px; }
.file-card em { font-style: normal; color: var(--muted); font-size: 13px; }
.file-upload {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}
.file-upload input { font-size: 13px; max-width: 100%; }
.file-status { color: var(--navy); font-size: 13px; font-weight: 700; }

.toolbar {
  margin-top: 12px;
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
}

.town-picker select, .filters select, .search input {
  margin-top: 6px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  min-width: 240px;
}

.town-note { max-width: 520px; color: var(--muted); line-height: 1.4; font-size: 14px; }

.stats {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

.stat {
  text-align: left;
  padding: 12px;
  cursor: pointer;
  border: 1px solid var(--line);
}
.stat strong {
  display: block;
  margin-top: 6px;
  font-size: 26px;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
}
.stat.active { outline: 2px solid var(--navy); background: var(--soft); }
.stat.new strong { color: var(--navy); }
.stat.dropped strong { color: var(--red); }

.panel { margin-top: 12px; padding: 14px 16px 16px; }
.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: end;
  margin-bottom: 12px;
}
.panel-head p, #voter-count { color: var(--muted); font-size: 14px; margin-top: 4px; }

.table-scroll { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
th {
  font-size: 12px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 650;
}
.district-table tfoot td,
.district-table tr.total-row td { font-weight: 700; border-top: 2px solid var(--navy); cursor: default; }
.district-table tbody tr { cursor: pointer; }
.district-table tbody tr:hover { background: var(--soft); }
.district-table tbody tr.selected { background: var(--soft); box-shadow: inset 3px 0 0 var(--gold); }
.community-table td.mix { min-width: 120px; }
#community-more { margin-top: 10px; }
.district-table button {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  color: var(--muted);
  font-weight: 650;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-size: 12px;
}
.num { text-align: right; }
.district-label { font-weight: 700; }

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}
.search input { min-width: 220px; margin-top: 0; }
.filters select { min-width: 140px; margin-top: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip, .btn {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 7px 12px;
  cursor: pointer;
}
.chip.active { background: var(--navy); color: white; border-color: var(--navy); }
.btn { border-radius: 8px; background: var(--gold); border-color: var(--gold); color: var(--navy-dark); font-weight: 700; }
.btn:hover { background: var(--gold-light); }
.btn:disabled { opacity: 0.45; cursor: default; }

.streets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.street {
  background: var(--soft);
  border-radius: 8px;
  padding: 6px 8px;
  font-size: 13px;
}
.street b { font-variant-numeric: tabular-nums; }

.mark {
  display: inline-block;
  min-width: 28px;
  text-align: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.mark.on { background: var(--soft); color: var(--navy); }
.mark.off { color: #b3aa9e; }
.tag {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--amber-soft);
  color: var(--amber);
  font-size: 11px;
  font-weight: 700;
}
.tag-not-sent { background: var(--red-soft); color: var(--red); }
.addr-city { display: block; color: var(--muted); font-size: 12px; }

.pager {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.map-find { display: flex; gap: 8px; align-items: center; }
.map-finders { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.map-finders input { width: 260px; }
.map-facts { grid-template-columns: auto 1fr; }
.map-facts dd { text-align: left; font-weight: 500; }
.map-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; }
.district-map {
  height: 640px;
  border: 1px solid var(--line);
  border-radius: 10px;
  isolation: isolate;
}
.map-info { max-height: 640px; overflow-y: auto; font-size: 14px; }
.map-info h3 { margin: 6px 0 8px; color: var(--navy); }
.map-info h4 { margin: 14px 0 6px; color: var(--navy); }
.map-small { margin: 6px 0; color: var(--muted); font-size: 13px; }
.map-stats { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; margin: 0 0 10px; }
.map-stats dt { color: var(--muted); }
.map-stats dd { margin: 0; font-weight: 700; text-align: right; }
.map-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.map-table { width: 100%; border-collapse: collapse; }
.map-table th, .map-table td { padding: 5px 6px; border-bottom: 1px solid var(--line); text-align: left; }
.map-table .num { text-align: right; }
.map-table .mix { width: 90px; }
.map-streets { margin: 0; padding-left: 22px; }
.map-streets li { margin: 3px 0; }
.leaflet-tooltip.district-label {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line);
  box-shadow: none;
  color: var(--navy);
  font-weight: 700;
  text-align: center;
  line-height: 1.25;
}
.leaflet-tooltip.district-label::before { display: none; }
.district-count { display: block; font-weight: 500; font-size: 11px; color: var(--muted); }
.map-legend {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 12px;
  line-height: 1.5;
  min-width: 170px;
}
.map-legend-toggle { display: flex; align-items: center; gap: 6px; font-weight: 700; color: var(--navy); margin-bottom: 4px; }
.map-legend-row { display: flex; align-items: center; gap: 6px; }
.map-legend-count { margin-left: auto; font-variant-numeric: tabular-nums; color: var(--muted); }
.map-legend-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid #ffffff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
  flex: none;
}
.map-legend-note { margin-top: 4px; color: var(--muted); }
.map-legend-approx { background: rgba(138, 143, 152, 0.5); border-color: #333333; box-shadow: none; }
.map-home-list { list-style: none; margin: 6px 0 0; padding: 0; }
.map-home-list li { display: flex; align-items: center; gap: 6px; margin: 3px 0; }
@media (max-width: 900px) {
  .map-layout { grid-template-columns: 1fr; }
  .district-map { height: 460px; }
  .map-info { max-height: none; }
}
.btn-ai { background: var(--gold); color: var(--navy-dark); border-color: var(--gold); }
.btn-ai:hover { background: var(--gold-light); }
.btn-ai:disabled { opacity: 0.6; cursor: wait; }
.marko-launch {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  background: var(--navy);
  color: white;
  font: inherit;
  font-weight: 700;
  box-shadow: 0 6px 20px rgba(15, 37, 88, 0.35);
  cursor: pointer;
}
.marko-launch:hover { background: var(--navy-dark); }
.marko-launch[hidden], .marko-panel[hidden] { display: none; }
.marko-icon { width: 20px; height: 20px; color: var(--gold); }
.marko-panel {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 51;
  display: flex;
  flex-direction: column;
  width: min(400px, calc(100vw - 24px));
  height: min(600px, calc(100vh - 40px));
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  box-shadow: 0 12px 40px rgba(15, 37, 88, 0.3);
  overflow: hidden;
}
.marko-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--navy);
  color: white;
}
.marko-head > div { flex: 1; min-width: 0; }
.marko-head h2 { margin: 0; font-size: 17px; color: white; }
.marko-head p { margin: 2px 0 0; font-size: 12px; color: #c9d4ee; }
.marko-link {
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 6px;
  background: transparent;
  color: white;
  font: inherit;
  font-size: 13px;
  padding: 4px 8px;
  cursor: pointer;
}
.marko-link:hover { background: rgba(255, 255, 255, 0.12); }
.marko-close {
  border: 0;
  background: transparent;
  color: white;
  font-size: 24px;
  line-height: 1;
  padding: 0 4px;
  cursor: pointer;
}
.marko-form {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  padding: 10px 12px 6px;
  border-top: 1px solid var(--line);
}
.marko-form textarea {
  flex: 1;
  min-width: 0;
  max-height: 140px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  font: inherit;
  resize: none;
}
.marko-note { margin: 0; padding: 0 12px 10px; font-size: 11px; color: var(--muted); }
@media (max-width: 520px) {
  .marko-launch { right: 12px; bottom: 12px; }
  .marko-panel { right: 12px; bottom: 12px; }
}
.agent-log {
  flex: 1;
  display: grid;
  align-content: start;
  gap: 8px;
  overflow-y: auto;
  padding: 12px;
}
.agent-msg {
  max-width: 92%;
  padding: 8px 12px;
  border-radius: 8px;
  line-height: 1.45;
  font-size: 14px;
}
.agent-msg p { margin: 0 0 6px; }
.agent-msg p:last-child { margin-bottom: 0; }
.agent-msg ul { margin: 4px 0 6px; padding-left: 20px; }
.agent-user { justify-self: end; background: var(--navy); color: white; white-space: pre-wrap; }
.agent-ai { justify-self: start; background: var(--soft); color: var(--ink); }
.agent-working { justify-self: start; color: var(--muted); font-style: italic; }
.agent-error { justify-self: start; background: var(--red-soft); color: var(--red); }
.agent-open { margin-top: 6px; }
.search-actions { display: flex; gap: 8px; }
.extra-filters {
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--soft);
}
.extra-filters summary { cursor: pointer; font-weight: 700; color: var(--navy); }
.extra-filters p { margin: 8px 0 12px; }
.extra-filters .report-grid { margin-bottom: 12px; }
.report-extra-main { display: contents; }
.range-pair { display: flex; gap: 6px; }
.range-pair input { width: 100%; min-width: 0; }
.search-results { display: grid; gap: 16px; margin-top: 14px; }
.search-results .table-scroll { max-height: 420px; }
#search-status { margin: 12px 0 0; color: var(--navy); }

.report-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}
.vbm-check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 22px;
  text-transform: none;
  letter-spacing: 0;
  font-size: 14px;
  color: var(--navy, #1a3370);
}
.filters .vbm-check { margin-top: 0; }
.vbm-check input {
  width: auto;
  margin: 0;
  padding: 0;
}
.report-grid label, .report-sections label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--muted);
}
.report-grid select, .report-grid input {
  display: block;
  width: 100%;
  min-width: 0;
  margin-top: 6px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 600;
  color: var(--ink);
}
.report-grid .vbm-check {
  margin-top: 22px;
  text-transform: none;
  letter-spacing: 0;
  font-size: 14px;
  color: var(--navy, #1a3370);
}
.report-grid .vbm-check input {
  display: inline-block;
  width: auto;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.party-report {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.party-report h3 { margin: 0 0 6px; color: var(--navy); }
.party-report > p { margin: 0 0 12px; color: var(--muted); }
.report-sections, .report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
}
.report-sections label {
  text-transform: none;
  letter-spacing: 0;
  font-size: 14px;
  color: var(--ink);
}
.report-sections input { margin-right: 6px; }
#report-status { color: var(--navy); font-weight: 700; }
.btn-secondary {
  background: #fff;
  color: var(--navy);
  border-color: var(--line);
}
.btn-secondary:hover { background: var(--soft); }
.report-preview {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 3px solid var(--gold);
}
.report-block { margin-top: 18px; }
.report-block-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.report-block-head h3 { margin: 0; }
.report-block-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-shrink: 0;
}
.export-choice {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
  text-transform: none;
  letter-spacing: 0;
}
.export-choice input {
  width: auto;
  margin: 0;
}
.report-block-actions .btn {
  padding: 5px 12px;
  font-size: 13px;
}
.report-block .table-scroll { max-height: 480px; }
.report-preview .num { text-align: right; }

.views {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.view-tab {
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--navy);
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 700;
  cursor: pointer;
}
.view-tab.active {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
}

.panel-head:has(.pie-slot) { align-items: center; }
.pie-slot { position: relative; flex-shrink: 0; }
.pie-thumb {
  width: 64px;
  height: 64px;
  padding: 3px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  box-shadow: var(--shadow);
}
.pie-thumb svg, .pie-pop svg { display: block; }
.pie-thumb svg { width: 56px; height: 56px; }
.pie-pop {
  position: absolute;
  z-index: 30;
  top: 100%;
  right: 0;
  padding-top: 8px;
  width: min(340px, 86vw);
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(15, 37, 88, 0.2);
}
.pie-pop h3 { margin: 0 0 8px; color: var(--navy); }
.pie-pop svg { width: 220px; height: 220px; margin: 0 auto 12px; }
.pie-legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.pie-legend li { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.pie-legend i { width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }
.pie-legend b { margin-left: auto; font-variant-numeric: tabular-nums; color: var(--navy); }

.party-mix {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.turnout-total {
  grid-column: 1 / -1;
  margin: 0;
  padding-top: 10px;
  border-top: 2px solid var(--navy);
  color: var(--navy);
  font-weight: 700;
}
.party-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  background: var(--soft);
  color: inherit;
  font: inherit;
  text-align: left;
  width: 100%;
  cursor: pointer;
}
.party-card.selected {
  border-color: var(--navy);
  box-shadow: inset 0 0 0 1px var(--navy);
}
.party-card strong {
  display: block;
  margin: 4px 0;
  font-size: 28px;
  font-variant-numeric: tabular-nums;
  color: var(--navy);
}
.party-card span, .party-card em { color: var(--muted); font-style: normal; font-size: 13px; }
.meter {
  height: 8px;
  border-radius: 999px;
  background: #d5dcef;
  overflow: hidden;
  margin-top: 8px;
}
.meter i {
  display: block;
  height: 100%;
}
.like-most { background: #1a3370; }
.like-likely { background: #2f6f4e; }
.like-possible { background: #f0bc1a; }
.like-unlikely { background: #8d97a8; }
.eth-I, .eth-Indian { background: #1a3370; }
.eth-M { background: #2f6f4e; }
.eth-blank { background: #8d97a8; }
.DEM { background: #1a3370; }
.REP { background: #b23b3b; }
.UNA { background: #f0bc1a; }
.other { background: #8d97a8; }

.stack {
  display: flex;
  width: 140px;
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: #d5dcef;
}
.stack span { display: block; height: 100%; }
td.mix { width: 160px; }
.legend { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; color: var(--muted); font-size: 12px; font-weight: 700; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 4px; }

.rank-grid, .split {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.split { grid-template-columns: 1fr 1fr; }
.rank-card, .change-list {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
}
.rank-card h3, .split h3 { font-size: 15px; margin-bottom: 8px; }
.rank-card ol, .change-list ol { margin: 0; padding-left: 1.2rem; }
.rank-card li, .change-list li { margin: 6px 0; }
.rank-card button, .change-list button, .street-link {
  background: none;
  border: 0;
  padding: 0;
  color: var(--navy);
  font-weight: 700;
  cursor: pointer;
  text-align: left;
}
.rank-card b, .change-list b { font-variant-numeric: tabular-nums; }

.street-scroll { max-height: 640px; }
.street-filter {
  margin: 0 0 12px;
  color: var(--navy);
  font-weight: 700;
}
.street-filter button {
  margin-left: 8px;
  border: 0;
  background: var(--soft);
  color: var(--navy);
  border-radius: 999px;
  padding: 4px 10px;
  cursor: pointer;
  font-weight: 700;
}

.count-table { width: 100%; }
.count-table td:first-child { font-weight: 700; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

@media (max-width: 980px) {
  .files, .stats, .party-mix, .rank-grid, .report-grid { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; }
  .top-inner, .toolbar, .panel-head { flex-direction: column; align-items: start; }
  h1 { font-size: 26px; }
}

@media (max-width: 640px) {
  .files, .stats, .party-mix, .rank-grid, .report-grid, .account-form { grid-template-columns: 1fr; }
  .town-picker select, .search input { min-width: 0; width: 100%; }
}
