/* =========================================================================
   Scout Recycling Fund: design system
   Tokens -> base -> layout -> components -> pages
   ========================================================================= */

/* ---------- Tokens ---------- */
:root {
  color-scheme: light dark;

  /* Neutrals */
  --bg: #f5f6f3;
  --surface: #ffffff;
  --surface-2: #f0f2ed;
  --surface-hover: #f7f8f5;
  --border: #e2e6de;
  --border-strong: #c9d0c3;
  --text: #17201a;
  --text-2: #4c584f;
  --text-3: #6f7a71;

  /* Brand */
  --brand: #2f6b3a;
  --brand-hover: #275a31;
  --brand-ink: #ffffff;
  --brand-soft: #e7f2e8;
  --brand-soft-ink: #1f5129;
  --accent: #f4c542;
  --accent-hover: #f7d164;
  --accent-ink: #362b00;

  /* Semantic */
  --success: #1d7a3c;
  --success-soft: #e6f4ea;
  --danger: #b4302a;
  --danger-hover: #9b2620;
  --danger-soft: #fdecea;
  --warning-ink: #7a5600;
  --warning-soft: #fff6db;
  --info-ink: #2f4ab2;
  --info-soft: #eaefff;

  /* Funds */
  --general-ink: #1f5129;
  --general-soft: #e3f1e5;
  --eagle-ink: #2f4ab2;
  --eagle-soft: #e8edff;

  /* Sidebar (dark in both themes) */
  --nav-bg: #1f3d25;
  --nav-text: #d3e2d0;
  --nav-muted: #93ad90;
  --nav-hover: rgba(255, 255, 255, 0.07);
  --nav-active: rgba(255, 255, 255, 0.14);

  /* Shape & depth */
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-full: 999px;
  --shadow-sm: 0 1px 2px rgba(20, 30, 20, 0.06);
  --shadow: 0 1px 2px rgba(20, 30, 20, 0.05), 0 4px 12px rgba(20, 30, 20, 0.06);
  --shadow-lg: 0 12px 32px rgba(20, 30, 20, 0.18);
  --focus-ring: 0 0 0 3px rgba(47, 107, 58, 0.35);

  /* Type */
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.75rem;

  /* Layout */
  --sidebar-w: 256px;
  --content-max: 1080px;
  --tap: 44px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1511;
    --surface: #171f19;
    --surface-2: #1d2720;
    --surface-hover: #1b241e;
    --border: #2a362d;
    --border-strong: #3a493e;
    --text: #e6ece6;
    --text-2: #b3bfb4;
    --text-3: #8b978c;

    --brand: #4f9a5c;
    --brand-hover: #5eab6b;
    --brand-ink: #0b130d;
    --brand-soft: #1d3322;
    --brand-soft-ink: #a9d8b1;

    --success: #6cc785;
    --success-soft: #16301e;
    --danger: #f08a80;
    --danger-hover: #f4a097;
    --danger-soft: #3a1d1b;
    --warning-ink: #f1cf72;
    --warning-soft: #33290f;
    --info-ink: #a9b9ff;
    --info-soft: #1d2440;

    --general-ink: #a9d8b1;
    --general-soft: #1d3322;
    --eagle-ink: #b6c3ff;
    --eagle-soft: #212a4a;

    --nav-bg: #111a13;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 4px 12px rgba(0, 0, 0, 0.3);
    --focus-ring: 0 0 0 3px rgba(111, 191, 125, 0.45);
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 var(--text-base)/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { line-height: 1.25; letter-spacing: -0.01em; margin: 0; }
h1 { font-size: var(--text-2xl); font-weight: 700; }
h2 { font-size: var(--text-lg); font-weight: 650; }
h3 { font-size: var(--text-base); font-weight: 650; }
p { margin: 0 0 12px; }
a { color: var(--brand); text-underline-offset: 2px; }
a:hover { color: var(--brand-hover); }
small { font-size: var(--text-sm); }
[hidden] { display: none !important; }
:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: 6px; }
.muted { color: var(--text-3); }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.neg { color: var(--danger); }
.pos { color: var(--success); }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 20px; height: 20px; flex: none; }

/* ---------- Layout ---------- */
main { max-width: var(--content-max); margin: 0 auto; padding: 32px 32px 64px; }
main:focus { outline: none; box-shadow: none; }
.section { margin-top: 32px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.section-head a { font-size: var(--text-sm); font-weight: 600; text-decoration: none; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.narrow { max-width: 460px; margin-left: auto; margin-right: auto; }
.form-width { max-width: 640px; }

/* Page header */
.page-header { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.page-header .eyebrow { display: inline-block; margin-bottom: 4px; font-size: var(--text-sm); font-weight: 600; color: var(--text-3); text-decoration: none; }
.page-header .eyebrow:hover { color: var(--brand); }
.page-sub { margin: 6px 0 0; color: var(--text-2); }
.page-actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- Buttons ---------- */
button, .button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 40px; padding: 8px 16px;
  font: 600 var(--text-sm)/1.2 var(--font);
  color: var(--text); background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  text-decoration: none; cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
}
button:hover, .button:hover { background: var(--surface-hover); border-color: var(--text-3); color: var(--text); }
button:focus-visible, .button:focus-visible { box-shadow: var(--focus-ring); border-radius: var(--radius-sm); }
button .icon, .button .icon { width: 18px; height: 18px; }
.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.primary:hover { background: var(--brand-hover); border-color: var(--brand-hover); color: var(--brand-ink); }
.danger { background: var(--surface); border-color: var(--danger); color: var(--danger); }
.danger:hover { background: var(--danger-soft); border-color: var(--danger-hover); color: var(--danger-hover); }
.ghost { background: transparent; border-color: transparent; box-shadow: none; }
.ghost:hover { background: var(--surface-2); border-color: transparent; }
.big { min-height: var(--tap); padding: 10px 20px; font-size: var(--text-base); border-radius: 10px; }
.block { width: 100%; }
.linklike {
  display: inline; min-height: 0; padding: 0; border: none; background: none; box-shadow: none;
  color: var(--brand); font: inherit; font-weight: 500; text-decoration: underline; text-underline-offset: 2px;
}
.linklike:hover { background: none; color: var(--brand-hover); }
.danger-text { color: var(--danger); }
.danger-text:hover { color: var(--danger-hover); }
form.inline { display: inline; }

/* ---------- Cards ---------- */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); padding: 24px;
}
.card + .card { margin-top: 16px; }
/* In a grid the gap does the spacing; a top margin would push cards out of line. */
.grid-2 > .card { margin-top: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.card-title { margin-bottom: 12px; }
.after-list { margin-top: 12px; }
.quote { margin: 16px 0 0; font-style: italic; }
.card-head p { margin: 4px 0 0; color: var(--text-2); font-size: var(--text-sm); }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.stat {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 18px; box-shadow: var(--shadow-sm);
}
.stat-label { display: flex; align-items: center; gap: 6px; font-size: var(--text-sm); color: var(--text-2); }
.stat-value { display: block; margin-top: 6px; font-size: 1.625rem; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat-sub { display: block; margin-top: 2px; font-size: var(--text-xs); color: var(--text-3); }
.stat.highlight { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.stat.highlight .stat-label, .stat.highlight .stat-sub { color: inherit; opacity: 0.85; }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.dot.general { background: var(--brand); }
.dot.eagle { background: var(--eagle-ink); }

/* ---------- Pills & badges ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 9px; border-radius: var(--radius-full);
  font-size: var(--text-xs); font-weight: 600; line-height: 1.6; white-space: nowrap;
  background: var(--surface-2); color: var(--text-2);
}
.pill.general { background: var(--general-soft); color: var(--general-ink); }
.pill.eagle { background: var(--eagle-soft); color: var(--eagle-ink); }
.pill.expense { background: var(--danger-soft); color: var(--danger); }
.pill.adjustment, .pill.correction { background: var(--info-soft); color: var(--info-ink); }
.pill.collection { background: var(--success-soft); color: var(--success); }
.pill.leader { background: var(--warning-soft); color: var(--warning-ink); }
.badge {
  display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px;
  border-radius: var(--radius-full); background: var(--accent); color: var(--accent-ink);
  font-size: var(--text-xs); font-weight: 700;
}

/* ---------- Alerts ---------- */
.flash {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 12px 16px; margin: 0 0 20px; border-radius: var(--radius-sm);
  border: 1px solid transparent; font-size: var(--text-sm);
}
.flash .icon { width: 18px; height: 18px; margin-top: 1px; }
.flash a { font-weight: 600; color: inherit; }
.flash ul { margin: 0; padding-left: 18px; }
.flash > div { flex: 1; }
.flash.success { background: var(--success-soft); color: var(--success); border-color: color-mix(in srgb, var(--success) 25%, transparent); }
.flash.error { background: var(--danger-soft); color: var(--danger); border-color: color-mix(in srgb, var(--danger) 25%, transparent); }
.flash.notice { background: var(--warning-soft); color: var(--warning-ink); border-color: color-mix(in srgb, var(--warning-ink) 25%, transparent); }

/* ---------- Forms ---------- */
label { display: block; margin: 0 0 16px; font-size: var(--text-sm); font-weight: 600; color: var(--text); }
.help { display: block; margin-top: 4px; font-size: var(--text-xs); font-weight: 400; color: var(--text-3); }
input, select, textarea {
  display: block; width: 100%; margin-top: 6px;
  min-height: var(--tap); padding: 10px 12px;
  font: 400 var(--text-base)/1.4 var(--font); color: var(--text);
  background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  transition: border-color 0.15s, box-shadow 0.15s;
}
input::placeholder, textarea::placeholder { color: var(--text-3); }
input:hover, select:hover, textarea:hover { border-color: var(--text-3); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: var(--focus-ring); }
select {
  appearance: none; padding-right: 36px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236f7a71' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
input[type=checkbox], input[type=radio] {
  display: inline-block; width: 18px; height: 18px; min-height: 0; margin: 0; padding: 0;
  accent-color: var(--brand); flex: none; cursor: pointer;
}
input[type=date] { min-width: 0; }
input.short { max-width: 120px; }
fieldset { border: none; padding: 0; margin: 0 0 20px; min-width: 0; }
legend { padding: 0; margin-bottom: 8px; font-size: var(--text-sm); font-weight: 600; }
.form-section { padding: 22px 0; border-top: 1px solid var(--border); }
.form-section:first-of-type { border-top: none; padding-top: 0; }
.form-section > h2 { margin-bottom: 4px; font-size: var(--text-base); }
.form-section > .help { margin: 0 0 14px; font-size: var(--text-sm); }
.form-section > :last-child { margin-bottom: 0; }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 16px; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding-top: 4px; }

/* Checkbox rows */
.check { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 10px; font-weight: 500; cursor: pointer; }
.check input { margin-top: 2px; }
.check .help { margin-top: 2px; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 4px 16px; }

/* Choice tiles (radio buttons as selectable cards) */
.choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.choice {
  display: flex; align-items: flex-start; gap: 10px; margin: 0;
  padding: 12px 14px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: var(--surface); font-weight: 600; cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
}
.choice:hover { border-color: var(--text-3); }
.choice input { margin-top: 2px; }
.choice .help { font-weight: 400; }
.choice:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand); }
.choice:has(input:focus-visible) { box-shadow: var(--focus-ring); }

/* ---------- Tables ---------- */
.table-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }
th, td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { font-size: var(--text-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-3); white-space: nowrap; }
th.num, td.num { text-align: right; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: var(--surface-hover); }
tfoot th, tfoot td { border-top: 1px solid var(--border-strong); border-bottom: none; font-size: var(--text-sm); text-transform: none; letter-spacing: 0; color: var(--text); font-weight: 700; }
td a { font-weight: 600; text-decoration: none; }
td a:hover { text-decoration: underline; }
tr.inactive td { color: var(--text-3); }
.cell-sub { display: block; font-size: var(--text-xs); font-weight: 400; color: var(--text-3); }
.form-table td { padding: 8px 10px; }
.form-table input { margin: 0; }
.row-actions { text-align: right; white-space: nowrap; }

/* ---------- Activity list (tallies) ---------- */
.list { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.list-item { border-bottom: 1px solid var(--border); }
.list-item:last-child { border-bottom: none; }
.list-link { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 14px 16px; color: inherit; text-decoration: none; }
.list-link:hover { background: var(--surface-hover); color: inherit; }
.list-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-soft-ink); }
.list-body { min-width: 0; }
.list-title { font-weight: 600; }
.list-meta { font-size: var(--text-sm); color: var(--text-3); }
.list-shares { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 6px; }
.share-chip { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: var(--text-sm); color: var(--text-2); }
.list-amount { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.list-amount small { display: block; font-weight: 400; color: var(--text-3); font-size: var(--text-xs); }

/* ---------- Empty state ---------- */
.empty { text-align: center; padding: 40px 24px; background: var(--surface); border: 1px dashed var(--border-strong); border-radius: var(--radius); }
.empty-icon { display: inline-grid; place-items: center; width: 48px; height: 48px; margin-bottom: 12px; border-radius: 12px; background: var(--brand-soft); color: var(--brand-soft-ink); }
.empty h2 { margin-bottom: 6px; font-size: var(--text-base); }
.empty p { color: var(--text-2); max-width: 420px; margin: 0 auto 16px; }
.empty p:last-child { margin-bottom: 0; }

/* ---------- Filters toolbar ---------- */
.toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; padding: 16px; margin-bottom: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.toolbar label { margin: 0; flex: 1 1 160px; }
.toolbar-actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- App shell: sidebar ---------- */
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 100; padding: 8px 12px; border-radius: var(--radius-sm); background: var(--surface); color: var(--text); }
.skip-link:focus { left: 8px; }

.brand { display: flex; align-items: center; gap: 10px; min-width: 0; color: inherit; text-decoration: none; }
.brand:hover { color: inherit; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: 10px; background: linear-gradient(135deg, #4d9a59, #2f6b3a); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2); }
.brand-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.brand-text strong { font-size: var(--text-base); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-text small { font-size: var(--text-xs); opacity: 0.75; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 40; width: var(--sidebar-w);
  display: flex; flex-direction: column; gap: 4px;
  padding: 20px 14px 14px; overflow-y: auto;
  background: var(--nav-bg); color: var(--nav-text);
}
.with-nav main { margin-left: calc(var(--sidebar-w) + max(0px, (100vw - var(--sidebar-w) - var(--content-max)) / 2)); }
.sidebar-head { display: flex; align-items: center; justify-content: space-between; padding: 0 6px 16px; color: #fff; }
.nav-cta {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); margin: 0 4px 16px; padding: 10px 14px; border-radius: 10px;
  background: var(--accent); color: var(--accent-ink); font-weight: 700; text-decoration: none;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.nav-cta:hover { background: var(--accent-hover); color: var(--accent-ink); }
.nav-cta.active { box-shadow: 0 0 0 2px var(--nav-bg), 0 0 0 4px var(--accent); }
.nav-group { display: flex; flex-direction: column; gap: 2px; margin-bottom: 12px; }
.nav-label { margin: 8px 10px 6px; font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--nav-muted); }
.nav-item {
  display: flex; align-items: center; justify-content: flex-start; gap: 12px; width: 100%; min-height: 40px;
  padding: 8px 10px; border: none; border-radius: var(--radius-sm); background: none; box-shadow: none;
  color: var(--nav-text); font: 500 var(--text-sm)/1.2 var(--font); text-align: left; text-decoration: none; cursor: pointer;
}
.nav-item:hover { background: var(--nav-hover); border: none; color: #fff; }
.nav-item.active { background: var(--nav-active); color: #fff; font-weight: 600; }
.nav-item .badge { margin-left: auto; }
.sidebar :focus-visible { box-shadow: 0 0 0 2px var(--accent); }
.sidebar-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, 0.1); display: flex; flex-direction: column; gap: 2px; }
.sidebar-foot form { margin: 0; }
.who { display: flex; align-items: center; gap: 10px; padding: 6px 10px 10px; }
.avatar { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 50%; background: #3f7a48; color: #fff; font-size: var(--text-xs); font-weight: 700; }
.who-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.who-text strong { color: #fff; font-size: var(--text-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who-text small { color: var(--nav-muted); font-size: var(--text-xs); }

.icon-btn { display: grid; place-items: center; width: var(--tap); height: var(--tap); min-height: 0; padding: 0; border: none; border-radius: var(--radius-sm); background: none; box-shadow: none; color: inherit; }
.icon-btn:hover { background: var(--nav-hover); color: inherit; border: none; }
.icon-btn .icon { width: 24px; height: 24px; }
.sidebar-head .sidebar-close { display: none; }
.appbar, .scrim { display: none; }

/* ---------- Signed-out & pending pages ---------- */
.no-nav main { max-width: 480px; padding-top: 32px; }
.simplebar { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 480px; margin: 0 auto; padding: 32px 16px 0; }
.auth-card { padding: 28px; }
.auth-card h1 { font-size: var(--text-xl); }
.auth-card .empty-icon { margin-bottom: 14px; }
.auth-card .page-sub { margin: 6px 0 20px; }
.forgot-link { margin: -8px 0 16px; text-align: right; font-size: var(--text-sm); }
.auth-foot { margin-top: 20px; text-align: center; font-size: var(--text-sm); color: var(--text-2); }
.auth-foot p { margin-bottom: 6px; }
.oauth { display: grid; gap: 10px; }
.oauth-btn { min-height: var(--tap); font-size: var(--text-base); }
.oauth-btn svg { width: 20px; height: 20px; }
.oauth-btn.facebook { background: #1877f2; border-color: #1877f2; color: #fff; }
.oauth-btn.facebook:hover { background: #166fe5; border-color: #166fe5; color: #fff; }
.divider { display: flex; align-items: center; gap: 12px; margin: 20px 0; color: var(--text-3); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.06em; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--border); }

/* ---------- Page-specific ---------- */
/* Scout cards on a parent's home page */
.scout-card { padding: 20px; }
.scout-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.scout-card-head h2 a { color: inherit; text-decoration: none; }
.scout-card-head h2 a:hover { color: var(--brand); }
.scout-total { display: block; font-size: 2rem; font-weight: 750; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.scout-total-label { font-size: var(--text-sm); color: var(--text-3); }
.fund-split { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.fund { padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); }
.fund .stat-label { font-size: var(--text-xs); }
.fund strong { display: block; margin-top: 2px; font-size: var(--text-lg); font-variant-numeric: tabular-nums; }

/* Tally form */
.share-row { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) auto; gap: 10px; align-items: end; margin-bottom: 10px; }
.share-row label { margin: 0; }
.share-row.no-fund { grid-template-columns: minmax(0, 1fr) auto; }
.share-row .remove-share { width: var(--tap); height: var(--tap); padding: 0; color: var(--text-3); }
.share-row .remove-share:hover { color: var(--danger); }
.row-error { grid-column: 1 / -1; margin: 0; color: var(--danger); font-size: var(--text-sm); font-weight: 600; }
.share-row.has-error .combo-input { border-color: var(--danger); }
.new-scout { grid-column: 1 / -1; padding: 14px; border: 1px dashed var(--border-strong); border-radius: var(--radius-sm); background: var(--surface); }
.new-scout label { margin-bottom: 12px; }
.new-scout label:last-child { margin-bottom: 0; }
.new-scout-help { margin: -6px 0 12px; }
.new-scout-title { margin: 0 0 10px; font-size: var(--text-sm); font-weight: 650; }
.js .new-scout-title .muted { display: none; }
/* Without JavaScript there's no picker to open it, so always show it. */
html:not(.js) .share-row .new-scout { display: block !important; }

/* Type-to-search scout picker */
.combo { position: relative; }
.combo-list {
  position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 4px);
  max-height: 264px; overflow-y: auto; margin: 0; padding: 4px; list-style: none;
  background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
}
.combo-option { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: var(--tap); padding: 8px 10px; border-radius: 6px; font-size: var(--text-base); font-weight: 500; cursor: pointer; }
.combo-option.active, .combo-option:hover { background: var(--brand-soft); color: var(--brand-soft-ink); }
.combo-new { color: var(--brand); font-weight: 600; border-top: 1px solid var(--border); border-radius: 0 0 6px 6px; }
.combo-new:first-child { border-top: none; border-radius: 6px; }

/* "My scouts" quick picks */
.quick-picks { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
.quick-label { font-size: var(--text-sm); color: var(--text-3); }
.chip { min-height: 36px; padding: 6px 14px; border-radius: var(--radius-full); font-weight: 600; }
.chip .icon { display: none; width: 16px; height: 16px; }
.chip[aria-pressed="true"] { background: var(--brand-soft); border-color: var(--brand); color: var(--brand-soft-ink); }
.chip[aria-pressed="true"] .icon { display: block; }
.counts { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.count { display: flex; flex-direction: column; justify-content: space-between; margin: 0; padding: 12px; font-size: var(--text-sm); font-weight: 600; color: var(--text); border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface-2); }
.count-label { display: flex; justify-content: space-between; gap: 6px; margin: 0; }
.count-label .muted { font-weight: 500; text-align: right; }
.rate-now { display: block; font-size: var(--text-xs); font-weight: 400; }
.count input { margin-top: 8px; font-size: 1.375rem; font-weight: 600; text-align: center; font-variant-numeric: tabular-nums; }
/* − / + around each count */
.stepper { display: flex; align-items: stretch; gap: 6px; margin-top: 8px; }
.stepper input { margin-top: 0; min-width: 0; flex: 1; padding: 10px 4px; -moz-appearance: textfield; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.step {
  flex: none; width: var(--tap); min-height: var(--tap); padding: 0;
  font-size: 1.5rem; font-weight: 600; line-height: 1;
  touch-action: manipulation; user-select: none; -webkit-user-select: none;
}
.step:disabled, .step.is-off { opacity: 0.4; cursor: default; }
.step:active:not(:disabled):not(.is-off) { background: var(--brand-soft); border-color: var(--brand); color: var(--brand-soft-ink); }
.summary-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-top: 20px; padding: 16px 20px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
}
.summary-bar button { flex: none; white-space: nowrap; }
.summary-total { font-size: var(--text-xl); font-weight: 750; font-variant-numeric: tabular-nums; }
.summary-meta { display: block; font-size: var(--text-sm); color: var(--text-3); }

/* Balance preview on the spending / adjustment form */
.balance-preview { margin: -4px 0 20px; padding: 14px; border-radius: var(--radius-sm); background: var(--surface-2); }
.balance-preview-title { margin: 0 0 10px; font-size: var(--text-sm); font-weight: 650; }
.balance-preview .fund-split { margin-top: 0; }
.balance-preview .fund { background: var(--surface); border: 1px solid var(--border); }
.balance-preview .fund.selected { border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }
.balance-after { margin: 12px 0 0; font-size: var(--text-sm); font-weight: 600; font-variant-numeric: tabular-nums; }
.balance-after.warn { color: var(--danger); }

.draft-actions { display: inline-block; margin-left: 4px; font-weight: 600; }
.draft-actions .linklike { color: inherit; font-weight: 600; }

/* Read-only tally */
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 24px; margin: 0; font-size: var(--text-sm); }
.kv dt { color: var(--text-3); }
.kv dd { margin: 0; font-weight: 500; }
.share-list { list-style: none; margin: 0; padding: 0; }
.share-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.share-list li:last-child { border-bottom: none; }

/* Sign-in methods */
.signins { list-style: none; margin: 0; padding: 0; }
.signins li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.signins li:last-child { border-bottom: none; }
.signins .provider { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.signins svg { width: 20px; height: 20px; }

.requested { display: flex; gap: 10px; padding: 12px 14px; margin-bottom: 20px; border-radius: var(--radius-sm); background: var(--warning-soft); color: var(--warning-ink); font-size: var(--text-sm); }
.danger-zone { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--border); }
.danger-zone p { margin: 0; font-size: var(--text-sm); color: var(--text-2); }

/* ---------- Reports ---------- */
/* Chart colors (validated for colorblind separation in both themes). */
.chart-card {
  --viz-slot-1: #2a78d6; --viz-slot-2: #eb6834; --viz-slot-3: #1baf7a; --viz-slot-4: #eda100;
  --viz-slot-5: #e87ba4; --viz-slot-6: #008300; --viz-slot-7: #6250d6; --viz-slot-8: #e34948;
  --viz-fund-general: #008300; --viz-fund-eagle: #2a78d6; --viz-fund-troop: #eda100;
  --viz-single: #008300; --viz-other: #898781;
  --viz-hover: rgba(11, 11, 11, 0.04);
}
@media (prefers-color-scheme: dark) {
  .chart-card {
    --viz-slot-1: #3987e5; --viz-slot-2: #d95926; --viz-slot-3: #199e70; --viz-slot-4: #c98500;
    --viz-slot-5: #d55181; --viz-slot-6: #008300; --viz-slot-7: #9085e9; --viz-slot-8: #e66767;
    --viz-fund-general: #008300; --viz-fund-eagle: #3987e5; --viz-fund-troop: #c98500;
    --viz-hover: rgba(255, 255, 255, 0.05);
  }
}
.report-filters label { flex: 1 1 140px; }
.filter-note { margin: -6px 0 16px; font-size: var(--text-sm); }
.delta { font-weight: 700; }
.chart-card .card-head { margin-bottom: 12px; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0 0 12px; padding: 0; list-style: none; font-size: var(--text-sm); color: var(--text-2); }
.chart-legend li { display: inline-flex; align-items: center; gap: 6px; }
.swatch { width: 10px; height: 10px; border-radius: 2px; flex: none; }
.chart { position: relative; min-height: 220px; }
.chart-svg { display: block; overflow: visible; touch-action: pan-y; }
.chart-svg:focus { outline: none; }
.chart-svg:focus-visible { box-shadow: var(--focus-ring); border-radius: var(--radius-sm); }
.chart-grid { stroke: var(--border); stroke-width: 1; shape-rendering: crispEdges; }
.chart-baseline { stroke: var(--border-strong); stroke-width: 1; shape-rendering: crispEdges; }
.chart-tick { fill: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.chart-value { fill: var(--text); font-size: 12px; font-weight: 600; }
.chart-hover { fill: var(--viz-hover); }
.chart-tip {
  position: absolute; z-index: 5; min-width: 160px; padding: 10px 12px; pointer-events: none;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
}
.chart-tip.docked { position: static; margin-top: 8px; box-shadow: none; background: var(--surface-2); border-color: transparent; }
.chart-tip-title { margin-bottom: 6px; color: var(--text-2); font-weight: 600; }
.chart-tip-row { display: grid; grid-template-columns: 12px auto 1fr; align-items: center; gap: 8px; padding: 2px 0; }
.chart-tip-row strong { font-variant-numeric: tabular-nums; }
.chart-tip-row span:last-child { color: var(--text-2); }
.chart-tip-key { width: 12px; height: 2px; border-radius: 1px; }
.chart-tip-total { margin-top: 4px; padding-top: 6px; border-top: 1px solid var(--border); }
.chart-table { margin-top: 12px; font-size: var(--text-sm); }
.chart-table summary { cursor: pointer; color: var(--brand); font-weight: 600; }
.chart-table table { margin-top: 10px; }

/* Ranked bars (top collectors) */
.bar-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.bar-list li { display: grid; grid-template-columns: minmax(90px, 9em) 1fr auto; align-items: center; gap: 10px; font-size: var(--text-sm); }
.bar-list a { font-weight: 600; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-track { height: 12px; }
.bar-fill { display: block; height: 12px; border-radius: 0 4px 4px 0; background: #008300; }
.bar-value { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.bar-value small { display: block; font-weight: 400; color: var(--text-3); font-size: var(--text-xs); }

.table-scroll table.compact th, .table-scroll table.compact td { padding: 10px 14px; white-space: nowrap; }
th .dot, td .dot { display: inline-block; margin-right: 4px; vertical-align: middle; }

/* Downloads */
.downloads { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.download { display: flex; gap: 12px; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow-sm); color: var(--text); text-decoration: none; }
.download:hover { border-color: var(--brand); color: var(--text); }
.download .icon { color: var(--brand); margin-top: 2px; }
.download strong { display: block; }
.download small { display: block; margin-top: 2px; color: var(--text-2); font-size: var(--text-sm); }

/* ---------- Responsive ---------- */
@media (max-width: 899px) {
  .with-nav main { margin-left: auto; }
  .appbar {
    position: sticky; top: 0; z-index: 30;
    display: flex; align-items: center; gap: 4px; height: 56px; padding: 0 8px 0 4px;
    background: var(--nav-bg); color: #fff; box-shadow: 0 1px 0 rgba(0, 0, 0, 0.2);
  }
  .appbar-brand { flex: 1; min-width: 0; font-weight: 700; color: #fff; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .appbar-brand:hover { color: #fff; }
  .appbar-action { display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 6px 14px 6px 10px; border-radius: var(--radius-full); background: var(--accent); color: var(--accent-ink); font-weight: 700; font-size: var(--text-sm); text-decoration: none; }
  .appbar-action:hover { background: var(--accent-hover); color: var(--accent-ink); }
  .appbar-action .icon { width: 18px; height: 18px; }

  .js .sidebar { width: min(84vw, 300px); transform: translateX(-100%); visibility: hidden; box-shadow: var(--shadow-lg); transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0.25s; }
  /* Opening shows the drawer at once so focus can move into it; closing waits for the slide. */
  .js .menu-open .sidebar { transform: none; visibility: visible; transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1); }
  .js .sidebar-head .sidebar-close { display: grid; color: var(--nav-text); }
  .scrim { display: block; position: fixed; inset: 0; z-index: 35; background: rgba(8, 14, 9, 0.5); backdrop-filter: blur(2px); }
  .scrim[hidden] { display: none; }
  .menu-open { overflow: hidden; }
  /* Without JavaScript the menu sits above the page content instead. */
  html:not(.js) .sidebar { position: static; width: auto; }
  html:not(.js) #menu-open { display: none; }

  /* The tally form's total and save button stay in reach while scrolling. */
  .summary-bar { position: sticky; bottom: 12px; z-index: 10; }
}

@media (max-width: 640px) {
  main { padding: 20px 16px 48px; }
  h1 { font-size: var(--text-xl); }
  .card { padding: 18px; }
  .page-header { margin-bottom: 18px; }
  .page-actions { width: 100%; }
  .page-actions > * { flex: 1 1 auto; white-space: nowrap; }
  .stats { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat { padding: 12px 14px; }
  .stat-value { font-size: 1.25rem; }
  .stat.wide { grid-column: 1 / -1; }
  .share-row { grid-template-columns: 1fr auto; padding: 12px; border-radius: var(--radius-sm); background: var(--surface-2); }
  .share-row .scout-field { grid-column: 1 / -1; }
  .share-row.no-fund .scout-field { grid-column: auto; }
  /* One container per row: name and value on the left, − count + on the right. */
  .counts { grid-template-columns: 1fr; gap: 8px; }
  .count { flex-direction: row; align-items: center; gap: 10px; padding: 8px 8px 8px 12px; }
  .count-label { flex: 1; flex-direction: column; justify-content: center; gap: 0; }
  .count-label .muted { text-align: left; }
  .stepper { margin-top: 0; flex: none; }
  .stepper input { flex: none; width: 76px; }
  .summary-bar { padding: 12px 14px; }
  .list-link { grid-template-columns: 1fr auto; gap: 10px; }
  .list-icon, .hide-sm { display: none; }

  /* Tables become stacked cards: each cell shows its column name. */
  table.responsive thead { display: none; }
  table.responsive, table.responsive tbody, table.responsive tr, table.responsive td { display: block; width: 100%; }
  table.responsive tr { display: flex; flex-direction: column; padding: 12px 16px; border-bottom: 1px solid var(--border); }
  table.responsive tbody tr:last-child { border-bottom: none; }
  table.responsive td { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 4px 0; border: none; text-align: right; }
  table.responsive td::before { content: attr(data-label); flex: none; color: var(--text-3); font-size: var(--text-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; text-align: left; }
  table.responsive td.primary-cell { order: -1; display: block; padding-bottom: 6px; font-size: var(--text-base); text-align: left; }
  table.responsive td.primary-cell::before { content: none; }
  table.responsive td:empty { display: none; }
  table.responsive tfoot, table.responsive tfoot tr { display: block; }
  table.responsive tfoot tr { padding: 12px 16px; border-top: 1px solid var(--border-strong); }
  table.responsive tfoot th, table.responsive tfoot td { display: flex; justify-content: space-between; padding: 2px 0; border: none; }
  table.responsive tfoot [data-label]::before { content: attr(data-label); color: var(--text-3); font-weight: 600; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

/* Merging scouts */
.merge-intro { margin: 0 0 14px; font-size: var(--text-sm); color: var(--text-2); }
.merge-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.merge-grid > .card { margin-top: 0; }
.merge-grid .card.kept { border-color: var(--brand); }
.merge-role { display: block; margin-bottom: 4px; font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-3); }
.merge-facts { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 12px 0 0; font-size: var(--text-sm); }
.merge-facts dt { color: var(--text-2); }
.merge-facts dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.merge-parents { margin: 12px 0 0; }

/* Privacy policy and terms */
.no-nav.wide main { max-width: 760px; }
.legal { line-height: 1.6; }
.legal .page-header { margin-bottom: 8px; }
.legal h2 { margin: 28px 0 8px; font-size: var(--text-lg); }
.legal p, .legal li { color: var(--text); }
.legal ul { padding-left: 22px; }
.legal li + li { margin-top: 6px; }
.legal h2[id] { scroll-margin-top: 80px; }
.legal-foot { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--border); font-size: var(--text-sm); }
.legal-links { font-size: var(--text-xs); color: var(--text-3); }
.legal-links a { color: inherit; }
.sidebar-legal { margin: 8px 12px 0; font-size: var(--text-xs); color: rgba(255, 255, 255, 0.6); }
.sidebar-legal a { color: inherit; text-decoration: none; }
.sidebar-legal a:hover { color: #fff; text-decoration: underline; }
.no-nav.wide .simplebar { max-width: 760px; padding-left: 32px; padding-right: 32px; }
@media (max-width: 640px) { .no-nav.wide .simplebar { padding-left: 16px; padding-right: 16px; } }

/* Newer / Older page links */
.pager { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; margin-top: 16px; }
.pager > :last-child { justify-self: end; }
.pager-label { font-size: var(--text-sm); color: var(--text-2); }

/* Backup page */
.steps { margin: 0; padding-left: 22px; line-height: 1.6; }
.steps li + li { margin-top: 6px; }
code { padding: 1px 5px; border-radius: 4px; background: var(--surface-hover); font-size: 0.9em; }

/* Change history */
.history { list-style: none; margin: 16px 0 0; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.history-item { padding: 14px 18px; }
.history-item + .history-item { border-top: 1px solid var(--border); }
.history-meta { font-size: var(--text-xs); color: var(--text-3); }
.history-summary { margin-top: 2px; overflow-wrap: anywhere; }
.history-summary a { font-size: var(--text-sm); font-weight: 600; }
.history-details { margin-top: 8px; font-size: var(--text-sm); }
.history-details summary { cursor: pointer; color: var(--text-2); font-weight: 600; }
.history-details table { margin-top: 8px; }
.history-details th[scope=row] { font-weight: 600; text-align: left; white-space: nowrap; }
.history-details td { overflow-wrap: anywhere; }
.history-details th[scope=row] { text-transform: none; letter-spacing: normal; font-size: inherit; color: var(--text-2); }
.history-details tbody tr:last-child > * { border-bottom: none; }

/* Troop share setting and troop fund */
.input-suffix { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.input-suffix input { margin-top: 0; }
.share-list .troop-share span { color: var(--text-2); }
a.stat-link { color: inherit; text-decoration: none; }
a.stat-link:hover { border-color: var(--brand); }
.stat-label .icon { width: 16px; height: 16px; }
.backup-status { margin: 12px 0 0; font-size: var(--text-sm); color: var(--success); }
.backup-status.error { color: var(--danger); }

/* List filters */
.toolbar .toolbar-search { flex: 2 1 220px; }
.list-count { margin: -4px 0 12px; font-size: var(--text-sm); color: var(--text-2); }
.check-grid label[hidden] { display: none; }
.nav-divider { margin: 6px 10px; border: none; border-top: 1px solid rgba(255, 255, 255, 0.1); }
/* Short screens with a mouse: tighter menu so it fits without scrolling.
   Touch screens keep full-size tap targets. */
@media (hover: hover) and (pointer: fine) and (max-height: 880px) {
  .sidebar { padding-top: 14px; gap: 2px; }
  .nav-cta { margin-bottom: 10px; }
  .nav-group { margin-bottom: 6px; }
  .nav-item { min-height: 32px; padding: 6px 10px; }
  .nav-label { margin: 4px 10px 4px; }
  .nav-divider { margin: 3px 10px; }
  .sidebar-foot { padding-top: 6px; }
}

/* Offline: saved-tally notice and the offline page */
.queue-note { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 60; width: min(560px, calc(100% - 32px));
  padding: 12px 16px; border-radius: var(--radius); background: var(--text); color: var(--bg); font-size: var(--text-sm); box-shadow: var(--shadow-lg, 0 8px 24px rgba(0,0,0,.2)); }
.queue-note a, .queue-note .linklike { color: inherit; font-weight: 700; text-decoration: underline; }
.queue-note[hidden] { display: none; }
.offline-card .flash { margin-bottom: 16px; }
.offline-queue { margin: 0 0 16px; padding-left: 20px; font-size: var(--text-sm); }
.offline-queue li + li { margin-top: 4px; }

/* Groups */
.plain-list { margin: 0; padding-left: 18px; }
.plain-list li { margin: 4px 0; }
.group-picker { margin-bottom: 16px; }
.scout-group { display: block; margin-top: 2px; font-size: var(--text-sm); color: var(--text-3); }

/* Pickups */
.form-grid-counts { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.form-grid-counts label { margin: 0; }
.warn-text { color: var(--danger); }
.scout-helped { margin: 4px 0 0; font-size: var(--text-sm); }
.picked-list { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 4px; }
.picked-list .check { margin: 0; }
.picker-combo { position: relative; max-width: 420px; }
.tally-disclaimer { display: flex; gap: 8px; align-items: flex-start; margin: 12px 4px 0; }
.tally-disclaimer .icon { flex: none; margin-top: 2px; }
a.pill { text-decoration: none; }
a.pill:hover { text-decoration: underline; }
