:root {
  --paper: #f3f6fa;
  --paper-2: #e6edf5;
  --card: #ffffff;
  --ink: #14283d;
  --muted: #425569;
  --line: #d5dee9;
  --rust: #1755a6;
  --rust-ink: #ffffff;
  --pine: #183b61;
  --pine-ink: #ffffff;
  --gold: #77531a;
  --focus: #14283d;
  --danger: #7f1d1d;
  --ok: #14532d;
  --shadow: 0 1px 0 rgba(20, 40, 61, 0.05);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "Avenir Next", "Segoe UI", "Helvetica Neue", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.5;
}
.skip {
  position: absolute;
  left: 0.5rem;
  top: -3rem;
  background: var(--ink);
  color: var(--paper);
  padding: 0.4rem 0.7rem;
}
.skip:focus { top: 0.5rem; z-index: 1000; }
a { color: var(--rust); }
a:hover { color: var(--ink); }
.site-header, main, .site-footer { 
  width: min(920px, calc(100% - 1.5rem));
  margin-left: auto;
  margin-right: auto;
}
.site-header {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: end;
  justify-content: space-between;
  padding: 1rem 0 0.75rem;
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; flex-direction: column; }
.brand a {
  color: var(--ink);
  text-decoration: none;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
}
.brand span {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.8rem;
  font-family: var(--sans);
  font-size: 0.95rem;
}
.nav a { color: var(--ink); text-decoration: none; }
.nav form { display: inline; }
.nav-logout { min-height: 0; padding: 0; border: 0; background: transparent; color: var(--ink); font-size: 0.95rem; text-decoration: underline; text-underline-offset: 0.2em; }
.nav a[aria-current="page"] { color: var(--rust); text-decoration: underline; text-underline-offset: 0.2em; }
.nav { align-items: center; gap: 0.25rem; }
.nav a,
.nav .nav-logout {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.5rem 0.65rem;
  border-radius: 4px;
}
.nav form { margin: 0; }
.nav .nav-logout { border: 0; }
.nav a:focus-visible,
.nav .nav-logout:focus-visible { outline-offset: -3px; }
input:not([type="checkbox"]):not([type="radio"]),
select { min-height: 44px; }
input,
select,
textarea { border-color: #70839a; }
button.quiet,
a.quiet { border-color: #70839a; }
.card,
.panel,
.official,
.letter,
td,
th { min-width: 0; overflow-wrap: anywhere; }
.mobile-nav { display: none; }
@media (max-width: 719px) {
  .nav-desktop { display: none; }
  .mobile-nav {
    display: block;
    flex: 1 0 100%;
    font-family: var(--sans);
    font-size: 0.95rem;
  }
  .mobile-nav summary {
    display: flex;
    align-items: center;
    min-height: 44px;
    cursor: pointer;
    list-style: none;
    text-decoration: underline;
    text-underline-offset: 0.2em;
  }
  .mobile-nav summary::-webkit-details-marker { display: none; }
  .mobile-nav summary::after {
    content: '+';
    margin-left: 0.4rem;
    text-decoration: none;
  }
  .mobile-nav[open] summary::after { content: '−'; }
  .mobile-nav nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.25rem 0.5rem;
    padding: 0.25rem 0 0.5rem;
  }
  .mobile-nav nav a,
  .mobile-nav nav button {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0.5rem;
    color: var(--ink);
    white-space: normal;
  }
  .mobile-nav nav a { text-decoration: none; }
  .mobile-nav nav a[aria-current="page"] {
    color: var(--rust);
    text-decoration: underline;
    text-underline-offset: 0.2em;
  }
  .mobile-nav nav form { margin: 0; }
  .mobile-nav nav .nav-logout {
    justify-content: flex-start;
    width: 100%;
    min-height: 44px;
    padding: 0.5rem;
  }
}

main { padding: 1.25rem 0 2.5rem; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; font-weight: 600; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); margin: 0 0 0.75rem; }
h2 { font-size: 1.55rem; margin: 1.6rem 0 0.5rem; }
h3 { font-size: 1.15rem; margin: 0 0 0.35rem; }
.lede, .truth, .why { font-size: 1.15rem; }
.truth { background: var(--card); border-left: 4px solid var(--rust); padding: 0.8rem 1rem; }
.why { color: var(--ink); }
.grid { display: grid; gap: 0.8rem; }
.cards { grid-template-columns: 1fr; }
@media (min-width: 720px) {
  .cards { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(4, 1fr); }
}
.card, .panel, .official, .letter {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.9rem 1rem;
  box-shadow: var(--shadow);
}
.card p, .official p { margin: 0.35rem 0; }
.meta, .fine, .site-footer, label, button, .nav, .stat span, input, select, textarea {
  font-family: var(--sans);
}
.meta, .fine, .site-footer { color: var(--muted); font-size: 0.95rem; }
.points {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--gold);
}
.actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.7rem; }
button, .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.55rem 0.9rem;
  border-radius: 6px;
  border: 2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
}
button.primary, a.primary {
  background: var(--pine);
  border-color: var(--pine);
  color: var(--pine-ink);
}
button.rust, a.rust {
  background: var(--rust);
  border-color: var(--rust);
  color: var(--rust-ink);
}
button.quiet, a.quiet { border-color: var(--line); background: transparent; }
.stack { display: flex; flex-direction: column; gap: 0.45rem; margin: 0.8rem 0; }
label { font-size: 0.92rem; color: var(--ink); }
input, select, textarea {
  width: 100%;
  font-size: 1rem;
  padding: 0.55rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  color: var(--ink);
}
textarea { min-height: 7rem; }
.letter, .copy-box {
  white-space: pre-wrap;
  font-size: 1rem;
}
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.stat {
  background: var(--pine);
  color: var(--pine-ink);
  border-radius: 6px;
  padding: 0.8rem;
}
.stat strong { display: block; font-size: 1.8rem; font-family: var(--serif); }
.stat span { font-size: 0.85rem; }
table { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 0.98rem; }
th, td { text-align: left; padding: 0.45rem 0.35rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.flash { padding: 0.7rem 0.8rem; border-radius: 6px; margin: 0.6rem 0 1rem; font-family: var(--sans); }
.flash-ok { background: #e7f5ec; color: var(--ok); }
.flash-error { background: #fde8e4; color: var(--danger); }
.banner { width: min(920px, calc(100% - 1.5rem)); margin: 0.6rem auto 0; background: #fde8e4; padding: 0.6rem 0.8rem; border-radius: 6px; }
.site-footer { padding: 1rem 0 2.5rem; border-top: 1px solid var(--line); }
.site-footer p { margin: 0.35rem 0; }
.row { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.check { display: flex; gap: 0.5rem; align-items: flex-start; }
.check input { width: auto; margin-top: 0.3rem; }
.tag {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
hr { border: 0; border-top: 1px solid var(--line); margin: 1.2rem 0; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
.badge {
  display: inline-block;
  margin-left: 0.45rem;
  padding: 0.05rem 0.45rem;
  border-radius: 999px;
  background: var(--gold);
  color: #ffffff;
  font-family: var(--sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.explainer { background: var(--card); border: 2px solid var(--ink); border-radius: 6px; padding: 0.9rem 1rem; margin: 1.2rem 0; }
.explainer h2 { margin-top: 0; }
.steps { list-style: none; padding: 0; margin: 0.4rem 0; display: grid; gap: 0.45rem; }
.steps li { border-left: 4px solid var(--pine); padding-left: 0.7rem; }
.points-table td:nth-child(2) { color: var(--gold); font-size: 1.1rem; }
.panel { margin: 0.8rem 0; }
.panel h3 { margin-top: 0; }
.person ul { padding-left: 1.1rem; margin: 0.4rem 0; }
.local-frame { border-left: 4px solid var(--pine); }

.started-confirm {
  background: #eef5ff;
  border: 1px solid var(--rust, #1755a6);
  border-radius: 6px;
  padding: 0.8rem 0.9rem;
  margin: 0 0 1rem;
}
.started-confirm[hidden] { display: none; }
.started-confirm p { margin: 0 0 0.6rem; }
.started-confirm .actions { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }

/* weekly dashboard, tracker, standing */
.dashboard { margin: 1.5rem 0; }
.top-actions { padding-left: 1.2rem; margin: 0; }
.top-actions li { margin-bottom: .75rem; }
.meter { background: #e5e7eb; border-radius: 999px; height: .6rem; overflow: hidden; margin: .4rem 0 .6rem; }
.meter span { display: block; height: 100%; background: #1d4ed8; }
.tracker-callout { border-left: 4px solid #1d4ed8; }
.tracker-entry .badge { white-space: normal; }
ul.plain { list-style: none; padding-left: 0; }
ul.plain li { margin: .3rem 0; }

/* Accessible navigation and form controls; existing colors and content remain. */
.nav { align-items: center; gap: .25rem; }
.nav a, .nav .nav-logout {
  display: inline-flex; align-items: center; min-height: 44px;
  padding: .5rem .65rem; border-radius: 4px;
}
.nav form { margin: 0; }
.nav .nav-logout { border: 0; }
input:not([type=checkbox]):not([type=radio]), select { min-height: 44px; }
input, select, textarea { border-color: #70839a; }
button.quiet, a.quiet { border-color: #70839a; }
.nav a:focus-visible, .nav .nav-logout:focus-visible { outline-offset: -3px; }
.card, .panel, .official, .letter, td, th { min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 719px) {
  .site-header { align-items: stretch; gap: .5rem; }
  .nav { width: 100%; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .25rem; }
  .nav a, .nav form { min-width: 0; white-space: normal; }
  .nav a, .nav .nav-logout { width: 100%; justify-content: flex-start; text-align: left; }
  .menu-toggle:not([hidden]) { display: inline-flex; align-self: center; }
  .brand { flex: 1; min-width: 0; }
  .brand a { overflow-wrap: anywhere; }
  .actions > .button, .actions > button { max-width: 100%; text-align: center; }
  main { min-width: 0; }
}
.menu-toggle[hidden], .nav[hidden] { display: none; }

/* Consistent visual system for public information and account pages. */
:root {
  --shadow: 0 2px 8px rgba(20,40,61,.075);
  --radius: 12px;
}
body { font-family: var(--sans); line-height: 1.6; }
.site-header, main, .site-footer { width: min(1080px, calc(100% - 2rem)); }
.site-header { align-items: center; padding: 1.25rem 0 .9rem; gap: .75rem; }
.brand a { font-family: var(--serif); font-size: clamp(1.25rem,2.8vw,1.65rem); font-weight: 700; line-height: 1.15; }
.brand span { margin-top: .25rem; }
.nav a, .nav .nav-logout { font-size: .95rem; font-weight: 600; }
main { padding-top: clamp(1.5rem,4vw,2.75rem); }
h1,h2,h3 { font-family: var(--serif); }
h1 { font-size: clamp(2rem,4.8vw,3.35rem); max-width: 22ch; }
h2 { margin-top: 2rem; }
main > p, .lede { max-width: 74ch; }
.card,.panel,.official,.letter,.explainer,.stat,.flash {
  border-radius: var(--radius);
}
.card,.panel,.official,.letter { padding: clamp(1rem,2.2vw,1.4rem); }
.grid { gap: 1rem; }
.truth { border-radius: 0 var(--radius) var(--radius) 0; }
.stats { gap: .75rem; }
.stat { min-width: 0; padding: 1rem; }
.stat span { display: block; overflow-wrap: anywhere; }
.stat strong { font-variant-numeric: tabular-nums; }
button,.button { border-radius: 8px; line-height: 1.35; }
button.quiet,a.quiet { border-color: #70839a; }
.stack { gap: .65rem; }
input,select,textarea { border-radius: 8px; }
input[type=checkbox],input[type=radio] { width: 1.2rem; height: 1.2rem; flex-shrink: 0; accent-color: var(--pine); }
.site-footer { line-height: 1.65; }
@media (min-width:720px) {
  .site-header { flex-direction: column; align-items: flex-start; }
  .nav { width: 100%; }
}
@media (max-width:719px) {
  body { font-size: 1rem; }
  .site-header { align-items: center; }
  .menu-toggle:not([hidden]) { margin-left: auto; }
  h2 { font-size: 1.45rem; }
  .grid { gap: .75rem; }
  .actions { gap: .65rem; }
  th,td { padding: .6rem .35rem; font-size: .875rem; }
}

/* Cool, contemporary palette and high-contrast reading surfaces from 1ec31d14268fa485e111a6ab4479e78031a1b4d7. */
:root {
  --sans: system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: system-ui, -apple-system, "Segoe UI", sans-serif;
}
.brand a { font-weight: 800; letter-spacing: -.035em; }
h1,h2,h3 { font-weight: 750; letter-spacing: -.025em; }
.nav a[aria-current="page"] { background: var(--paper-2); text-decoration-thickness: 2px; }
a { text-underline-offset: .18em; }
.card,.panel,.official,.letter { box-shadow: var(--shadow); }
.truth { border-left-color: var(--rust); }
button.primary,a.primary { background: var(--pine); }
button.primary:hover,a.primary:hover { background: #102e4c; color: white; }
.nav a:hover,.nav .nav-logout:hover { background: var(--paper-2); }
.site-footer { border-top-color: #c3d0df; }
@media (max-width:719px) {
  body { font-size: 1.0625rem; }
  .nav { padding: .5rem; background: var(--card); border: 1px solid var(--line); border-radius: 12px; }
}

/* A compact visual reference for points, standings and public contact details. */
.rules-overview { max-width: 850px; margin-inline: auto; }
.rules-overview h2 { margin: 2rem 0 .85rem; }
.score-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; grid-template-columns: repeat(2,minmax(0,1fr)); }
.score-tile { display: flex; align-items: center; justify-content: space-between; gap: .8rem; min-width: 0; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: .9rem 1rem; box-shadow: var(--shadow); }
.score-tile > div { min-width: 0; }
.score-tile strong,.score-tile .fine { display: block; overflow-wrap: anywhere; }
.score-value { white-space: nowrap; flex-shrink: 0; color: var(--pine); font-weight: 800; font-size: 1.65rem; font-variant-numeric: tabular-nums; }
.score-value small { font-size: .75rem; font-weight: 600; }
.standing-list { list-style: none; padding: 0; margin: 0; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--card); }
.standing-list li { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .85rem 1rem; border-bottom: 1px solid var(--line); }
.standing-list li:last-child { border: 0; }
.standing-list strong { flex-shrink: 0; font-variant-numeric: tabular-nums; }
.rule-detail { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: .3rem 1rem; margin-top: .8rem; }
.rule-detail summary { cursor: pointer; padding: .75rem 0; min-height: 44px; font-weight: 650; }
.rule-detail ul { padding-left: 1.4rem; }
.donor-contact { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .8rem; }
@media (max-width: 719px) {
  .score-grid { grid-template-columns: 1fr; }
  .score-tile { padding: .8rem .9rem; }
  .donor-contact > .button { flex: 1 1 auto; }
}

/* Project identification and resource navigation */
.project-intro { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: clamp(1rem,3vw,2rem); margin: 0 0 1rem; box-shadow: var(--shadow); }
.project-kicker { margin: 0 0 .5rem; font-size: .82rem; font-weight: 700; color: var(--muted); }
.project-intro h1 { margin: 0 0 .65rem; max-width: 25ch; }
.project-intro .lede { margin: 0 0 1rem; }
.project-links { display: flex; flex-wrap: wrap; gap: .5rem 1rem; }
.project-links a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
@media(max-width:719px) { .project-links { flex-direction: column; gap: .2rem; } .project-intro { padding: 1rem; } }

/* Keep the existing native disclosure menu on mobile. */
@media (max-width: 719px) {
  .nav-desktop { display: none; }
  .mobile-nav { display: block; flex: 1 0 100%; }
  .mobile-nav summary { margin-left: auto; }
  .mobile-nav nav {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 0.5rem;
  }
}
