* {
  box-sizing: border-box;
}

:root {
  --navy: #0d2b4a;
  --navy-light: #173b61;
  --red: #b52b2f;
  --gold: #b99749;
  --text: #172033;
  --muted: #687386;
  --line: #d9dee5;
  --light: #f7f8fa;
  --green-bg: #e7f5e8;
  --green: #216e2d;
  --gray-bg: #eceff3;
  --gray: #4f5968;
  --blue-bg: #e4eefb;
  --blue: #1c5c9e;
  --amber-bg: #fff2cf;
  --amber: #8b6500;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  background: #ffffff;
  line-height: 1.45;
}

.container {
  width: min(1100px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  background: var(--navy);
  color: white;
  padding: 40px 0 32px;
}

.kicker {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.82rem;
  opacity: 0.86;
}

h1 {
  margin: 0 0 12px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.7rem, 7vw, 5rem);
  line-height: 0.95;
}

.tagline {
  margin: 0;
  color: #e8edf3;
  font-size: 1.08rem;
}

.top-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: white;
  border-bottom: 1px solid var(--line);
}

.nav-links {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
}

.nav-links a {
  color: var(--navy);
  text-decoration: none;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 14px 8px;
  border-right: 1px solid var(--line);
}

.nav-links a:first-child {
  border-left: 1px solid var(--line);
}

.nav-links a:hover {
  background: #f2f5f8;
}

.intro {
  padding: 28px 0 0;
  color: var(--muted);
  font-size: 1.04rem;
}

.guide-section {
  margin: 36px 0 50px;
}

h2 {
  margin: 0 0 14px;
  padding-bottom: 8px;
  color: var(--navy);
  border-bottom: 3px solid var(--red);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
}

h3 {
  margin: 28px 0 8px;
  padding: 11px 14px;
  color: white;
  background: var(--navy-light);
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.race-list {
  border: 1px solid var(--line);
  border-bottom: 0;
}

.race-row {
  display: grid;
  grid-template-columns: 2fr 1.2fr 180px;
  gap: 16px;
  align-items: center;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
}

.race-row:nth-child(even) {
  background: #fbfcfd;
}

.office {
  font-weight: 600;
}

.candidate {
  color: #293244;
}

.status {
  text-align: center;
  padding: 7px 8px;
  border-radius: 3px;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.recommended {
  background: var(--green-bg);
  color: var(--green);
}

.no-endorsement {
  background: var(--gray-bg);
  color: var(--gray);
}

.co-endorsement {
  background: var(--blue-bg);
  color: var(--blue);
}

.review {
  background: var(--amber-bg);
  color: var(--amber);
}

.simple-list {
  border: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(2, 1fr);
}

.simple-list div {
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
}

.simple-list div:nth-child(odd) {
  border-right: 1px solid var(--line);
}

.measure-list {
  border: 1px solid var(--line);
  border-bottom: 0;
}

.measure-card {
  display: grid;
  grid-template-columns: 1fr 150px;
  gap: 10px 20px;
  align-items: center;
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
}

.measure-card h4 {
  margin: 0 0 4px;
  color: var(--navy);
  font-size: 1.08rem;
}

.measure-card p {
  margin: 0;
}

.measure-card > div:first-child p {
  color: var(--muted);
  font-size: 0.92rem;
}

.measure-description {
  grid-column: 1 / -1;
  color: #4e5868;
}

.vote {
  text-align: center;
  padding: 9px 10px;
  border-radius: 3px;
  font-weight: 800;
}

.vote.no {
  background: #fde2e2;
  color: #a61b1f;
}

.vote.neutral {
  background: var(--gray-bg);
  color: var(--gray);
}

.draft-note {
  margin: 46px 0;
  padding: 20px;
  background: var(--light);
  border: 1px solid var(--line);
}

.draft-note h2 {
  font-size: 1.5rem;
}

.site-footer {
  margin-top: 50px;
  padding: 24px 0;
  background: var(--navy);
  color: white;
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .nav-links {
    grid-template-columns: repeat(4, 1fr);
  }

  .race-row {
    grid-template-columns: 1fr 1fr;
  }

  .status {
    grid-column: 1 / -1;
    justify-self: start;
    min-width: 160px;
  }
}

@media (max-width: 650px) {
  .site-header {
    padding: 30px 0 24px;
  }

  .nav-links {
    grid-template-columns: repeat(2, 1fr);
  }

  .race-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .status {
    grid-column: auto;
  }

  .simple-list {
    grid-template-columns: 1fr;
  }

  .simple-list div:nth-child(odd) {
    border-right: 0;
  }

  .measure-card {
    grid-template-columns: 1fr;
  }

  .measure-description {
    grid-column: auto;
  }
}
