/* ─── Variables ──────────────────────────────────────────────────────────── */
:root {
  --blue: #1A3A6B;
  --blue-dark: #0F2347;
  --blue-light: #2B5BA8;
  --red: #B22234;
  --gray-100: #F8F9FA;
  --gray-200: #E9ECEF;
  --gray-400: #CED4DA;
  --gray-500: #6C757D;
  --gray-800: #1A1A2E;
  --white: #FFFFFF;
  --shadow-card: 0 24px 64px rgba(0,0,0,0.28);
}

/* ─── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', sans-serif;
  background: var(--white);
  color: var(--gray-800);
  min-height: 100vh;
}

/* ─── Top bar ────────────────────────────────────────────────────────────── */
.top-bar {
  background: var(--red);
  height: 4px;
}

/* ─── Header ─────────────────────────────────────────────────────────────── */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 0 48px;
  height: 72px;
  display: flex;
  align-items: center;
}

.header-inner {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 14px;
}

.logo-flag {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.flag-bar {
  width: 36px;
  height: 5px;
  border-radius: 1px;
}
.flag-bar.red   { background: var(--red); }
.flag-bar.white { background: var(--gray-200); }
.flag-bar.blue  { background: var(--blue); }

.logo-text h1 {
  font-family: 'Merriweather', serif;
  font-size: 22px;
  font-weight: 900;
  color: var(--blue-dark);
  letter-spacing: -0.3px;
}

.logo-text span {
  font-size: 11px;
  color: var(--gray-500);
  display: block;
  margin-top: 1px;
  letter-spacing: 0.5px;
}

nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

nav a {
  color: var(--gray-500);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 6px;
  transition: all 0.15s;
}
nav a:hover {
  background: var(--gray-100);
  color: var(--blue);
}

/* ─── Hero ───────────────────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--blue) 60%, var(--blue-light) 100%);
  position: relative;
  overflow: hidden;
  padding: 72px 48px;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Ctext x='50%25' y='55%25' text-anchor='middle' dominant-baseline='middle' font-size='12' fill='rgba(255,255,255,0.045)'%3E%E2%98%85%3C/text%3E%3C/svg%3E");
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 5px;
  background: var(--red);
}

.hero-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 460px;
  gap: 64px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-text .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.9);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 24px;
}

.hero-text h2 {
  font-family: 'Merriweather', serif;
  font-size: 46px;
  font-weight: 900;
  color: var(--white);
  line-height: 1.2;
  margin-bottom: 20px;
}

.hero-text p {
  font-size: 17px;
  font-weight: 300;
  color: rgba(255,255,255,0.75);
  line-height: 1.75;
}

/* ─── Lookup Card ────────────────────────────────────────────────────────── */
.lookup-card {
  background: var(--white);
  border-radius: 12px;
  padding: 36px;
  box-shadow: var(--shadow-card);
}

.lookup-card h3 {
  font-family: 'Merriweather', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--blue-dark);
  margin-bottom: 6px;
}

.card-sub {
  font-size: 13px;
  color: var(--gray-500);
  margin-bottom: 24px;
}

/* ─── Address Autocomplete ───────────────────────────────────────────────── */
.autocomplete-wrapper {
  position: relative;
  margin-bottom: 12px;
}

.address-input {
  width: 100%;
  border: 2px solid var(--gray-200);
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 15px;
  font-family: 'Inter', sans-serif;
  color: var(--gray-800);
  outline: none;
  transition: border-color 0.2s;
}

.address-input:focus {
  border-color: var(--blue-light);
}

/* Google autocomplete dropdown styling */
.pac-container {
  border-radius: 8px !important;
  border: 1px solid var(--gray-200) !important;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12) !important;
  font-family: 'Inter', sans-serif !important;
  margin-top: 4px;
}

.pac-item {
  padding: 10px 14px !important;
  font-size: 14px !important;
  cursor: pointer;
}

.pac-item:hover {
  background: var(--gray-100) !important;
}

.pac-item-query {
  font-size: 14px !important;
  color: var(--gray-800) !important;
}

.lookup-btn {
  width: 100%;
  background: var(--blue);
  color: var(--white);
  border: none;
  border-radius: 8px;
  padding: 15px;
  font-size: 15px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.lookup-btn:hover:not(:disabled) {
  background: var(--blue-dark);
}

.lookup-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.trust-row {
  margin-top: 14px;
  font-size: 11px;
  color: var(--gray-500);
  text-align: center;
}

/* ─── Stats Bar ──────────────────────────────────────────────────────────── */
.stats-bar {
  background: var(--gray-100);
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
  padding: 28px 48px;
}

.stats-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}

.stat-num {
  font-family: 'Merriweather', serif;
  font-size: 32px;
  font-weight: 900;
  color: var(--blue);
}

.stat-label {
  font-size: 12px;
  color: var(--gray-500);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ─── Loading ────────────────────────────────────────────────────────────── */
.loading-section {
  text-align: center;
  padding: 64px 24px;
  color: var(--gray-500);
}

.spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--gray-200);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 16px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Error ──────────────────────────────────────────────────────────────── */
.error-section {
  max-width: 680px;
  margin: 32px auto;
  padding: 0 24px;
}

.error-msg {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: #991B1B;
  border-radius: 8px;
  padding: 16px 20px;
  font-size: 15px;
  line-height: 1.5;
}

/* ─── Results ────────────────────────────────────────────────────────────── */
.results-section {
  max-width: 900px;
  margin: 48px auto;
  padding: 0 24px;
}

.election-header {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--gray-200);
}

.election-header h2 {
  font-family: 'Merriweather', serif;
  font-size: 26px;
  font-weight: 700;
  color: var(--blue-dark);
}

.election-header p {
  font-size: 15px;
  color: var(--gray-500);
  margin-top: 6px;
}

/* Polling Locations */
.polling-locations {
  margin-bottom: 36px;
}

.polling-locations h3 {
  font-family: 'Merriweather', serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--blue-dark);
  margin-bottom: 16px;
}

.polling-card {
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 14px;
}

.polling-card strong {
  color: var(--blue-dark);
  font-size: 15px;
}

/* Contests */
.contests-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray-500);
  margin-bottom: 20px;
}

.contest-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 10px;
  margin-bottom: 20px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.contest-header {
  background: var(--gray-100);
  border-bottom: 1px solid var(--gray-200);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.contest-office {
  font-family: 'Merriweather', serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--blue-dark);
  flex: 1;
}

.contest-district {
  font-size: 13px;
  color: var(--gray-500);
}

.contest-level {
  background: var(--blue);
  color: var(--white);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
}

/* Candidate List */
.candidate-list {
  list-style: none;
  padding: 12px 0;
}

.candidate-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--gray-100);
}

.candidate-item:last-child {
  border-bottom: none;
}

.candidate-photo {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gray-200);
  flex-shrink: 0;
}

.candidate-photo-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gray-100);
  border: 2px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.candidate-name {
  font-weight: 600;
  font-size: 15px;
  color: var(--gray-800);
}

.candidate-party {
  font-size: 12px;
  font-weight: 500;
  margin-top: 3px;
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
}

.party-dem  { background: rgba(37,99,235,0.1);  color: #1D4ED8; }
.party-rep  { background: rgba(220,38,38,0.1);  color: #B91C1C; }
.party-ind  { background: rgba(107,114,128,0.1); color: #374151; }
.party-other{ background: rgba(107,114,128,0.1); color: #374151; }

.candidate-links {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.candidate-link {
  font-size: 12px;
  color: var(--blue);
  text-decoration: none;
  border: 1px solid var(--blue-light);
  padding: 2px 8px;
  border-radius: 4px;
  transition: all 0.15s;
}

.candidate-link:hover {
  background: var(--blue);
  color: var(--white);
}

/* Voting Record */
.voting-record {
  margin-top: 12px;
  border-top: 1px solid var(--gray-200);
  padding-top: 12px;
}

.voting-record-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray-500);
  margin-bottom: 8px;
}

.vr-source {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--gray-400);
  font-size: 10px;
  margin-left: 6px;
}

.votes-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.vote-row {
  border-bottom: 1px solid var(--gray-100);
}

.vote-row:last-child { border-bottom: none; }

.vote-position {
  font-weight: 700;
  font-size: 11px;
  text-transform: uppercase;
  padding: 5px 8px 5px 0;
  white-space: nowrap;
  width: 40px;
}

.vote-yes  { color: #16A34A; }
.vote-no   { color: #DC2626; }
.vote-other{ color: var(--gray-500); }

.vote-desc {
  color: var(--gray-800);
  padding: 5px 8px;
  line-height: 1.4;
}

.vote-date {
  color: var(--gray-500);
  white-space: nowrap;
  padding: 5px 0 5px 8px;
  font-size: 11px;
}

.summarize-btn {
  display: inline-block;
  margin-left: 8px;
  background: none;
  border: 1px solid var(--blue-light);
  color: var(--blue);
  font-size: 11px;
  font-family: 'Inter', sans-serif;
  padding: 2px 8px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.summarize-btn:hover:not(:disabled) {
  background: var(--blue);
  color: var(--white);
}

.summarize-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.bill-summary-box {
  margin-top: 10px;
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  padding: 14px;
}

.summary-badge {
  display: inline-block;
  background: rgba(26,58,107,0.08);
  color: var(--blue);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.summary-section {
  margin-bottom: 10px;
}

.summary-section:last-child { margin-bottom: 0; }

.summary-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray-500);
  margin-bottom: 4px;
}

.summary-text {
  font-size: 13px;
  color: var(--gray-800);
  line-height: 1.6;
}

.summary-loading {
  font-size: 13px;
  color: var(--gray-500);
  text-align: center;
  padding: 8px;
}

.summary-error {
  font-size: 13px;
  color: #991B1B;
}

/* Referendum */
.referendum-body {
  padding: 20px;
}

.referendum-subtitle {
  font-weight: 600;
  font-size: 15px;
  color: var(--gray-800);
  margin-bottom: 10px;
}

.referendum-text {
  font-size: 14px;
  color: var(--gray-500);
  line-height: 1.65;
}

.no-data {
  text-align: center;
  color: var(--gray-500);
  font-size: 15px;
  padding: 40px 0;
}

/* ─── US Map Section ─────────────────────────────────────────────────────── */
.map-section {
  padding: 64px 48px;
  background: var(--white);
  border-top: 1px solid var(--gray-200);
}

.map-header {
  max-width: 1100px;
  margin: 0 auto 32px;
}

.map-header h2 {
  font-family: 'Merriweather', serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--blue-dark);
  margin-bottom: 8px;
}

.map-header p {
  font-size: 15px;
  color: var(--gray-500);
}

.map-container {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
  align-items: start;
}

.map-wrap {
  position: relative;
}

#us-map {
  width: 100%;
  display: block;
}

.state-path {
  transition: opacity 0.15s;
}

.map-legend {
  display: flex;
  gap: 20px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--gray-500);
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.legend-dot.rep   { background: #C8102E; }
.legend-dot.dem   { background: #003A70; }
.legend-dot.split { background: #6B21A8; }
.legend-dot.none  { background: #CBD5E1; }

/* State Panel */
.state-panel {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  overflow: hidden;
  position: sticky;
  top: 20px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
}

.state-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  background: var(--blue-dark);
  color: var(--white);
  flex-shrink: 0;
}

.state-panel-name {
  font-family: 'Merriweather', serif;
  font-size: 20px;
  font-weight: 700;
}

.state-panel-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.6);
  margin-top: 2px;
}

.state-panel-close {
  background: rgba(255,255,255,0.15);
  border: none;
  color: var(--white);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
  flex-shrink: 0;
}

.state-panel-close:hover {
  background: rgba(255,255,255,0.25);
}

.state-panel-body {
  overflow-y: auto;
  padding: 16px;
  flex: 1;
}

.state-panel-loading {
  text-align: center;
  padding: 32px 16px;
  color: var(--gray-500);
}

.panel-section-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray-500);
  padding: 12px 4px 8px;
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: 8px;
}

.member-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 8px;
  border-radius: 8px;
  transition: background 0.15s;
  border-bottom: 1px solid var(--gray-100);
}

.member-card:last-child { border-bottom: none; }
.member-card:hover { background: var(--gray-100); }

.member-photo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gray-200);
  flex-shrink: 0;
}

.member-photo-placeholder {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gray-100);
  border: 2px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.member-name {
  font-weight: 600;
  font-size: 14px;
  color: var(--gray-800);
}

.member-role {
  font-size: 12px;
  color: var(--gray-500);
  margin-top: 2px;
}

.member-party {
  display: inline-block;
  font-size: 11px;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 4px;
  margin-top: 4px;
}

.panel-error {
  text-align: center;
  color: var(--gray-500);
  font-size: 14px;
  padding: 24px;
}

.votes-toggle-btn {
  display: inline-block;
  margin-top: 6px;
  background: none;
  border: 1px solid var(--gray-400);
  color: var(--gray-500);
  font-size: 11px;
  font-family: 'Inter', sans-serif;
  padding: 3px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
}

.votes-toggle-btn:hover:not(:disabled) {
  border-color: var(--blue);
  color: var(--blue);
}

.member-votes-box {
  margin-top: 10px;
  border-top: 1px solid var(--gray-200);
  padding-top: 10px;
  width: 100%;
}

@media (max-width: 900px) {
  .map-container {
    grid-template-columns: 1fr;
  }

  .state-panel {
    position: static;
    max-height: none;
  }

  .map-section {
    padding: 40px 20px;
  }
}

/* ─── Features ───────────────────────────────────────────────────────────── */
.features-section {
  background: var(--gray-100);
  border-top: 1px solid var(--gray-200);
  padding: 64px 48px;
}

.features-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 10px;
  padding: 32px;
  transition: box-shadow 0.2s;
}

.feature-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
}

.feature-dot {
  width: 48px;
  height: 48px;
  background: rgba(26,58,107,0.08);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-family: 'Merriweather', serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--blue-dark);
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14px;
  color: var(--gray-500);
  line-height: 1.65;
}

/* ─── Footer ─────────────────────────────────────────────────────────────── */
.site-footer {
  background: var(--blue-dark);
  color: rgba(255,255,255,0.5);
  text-align: center;
  padding: 24px 48px;
  font-size: 12px;
  line-height: 1.6;
}

/* ─── Bill Summary Modal ─────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 22, 40, 0.75);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  backdrop-filter: blur(3px);
}

.modal-box {
  background: var(--white);
  border-radius: 16px;
  max-width: 680px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 32px 80px rgba(0,0,0,0.35);
}

.modal-close {
  position: sticky;
  top: 16px;
  float: right;
  margin: 16px 16px 0 0;
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  color: var(--gray-800);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  z-index: 10;
}

.modal-close:hover {
  background: var(--gray-800);
  color: var(--white);
}

.modal-body {
  padding: 24px 36px 36px;
  clear: both;
}

.modal-vote-desc {
  font-family: 'Merriweather', serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--blue-dark);
  line-height: 1.4;
  margin-bottom: 8px;
}

.modal-vote-meta {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.modal-vote-position {
  font-size: 13px;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: 20px;
}

.modal-vote-position.vote-yes  { background: rgba(22,163,74,0.1);  color: #15803D; }
.modal-vote-position.vote-no   { background: rgba(220,38,38,0.1);  color: #B91C1C; }
.modal-vote-position.vote-other{ background: var(--gray-100); color: var(--gray-500); }

.modal-vote-result {
  font-size: 13px;
  color: var(--gray-500);
  padding: 3px 0;
}

.modal-vote-date {
  font-size: 13px;
  color: var(--gray-500);
  padding: 3px 0;
}

.modal-divider {
  border: none;
  border-top: 1px solid var(--gray-200);
  margin: 20px 0;
}

.modal-ai-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(26,58,107,0.06);
  border: 1px solid rgba(26,58,107,0.15);
  color: var(--blue);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 20px;
}

.modal-section {
  margin-bottom: 24px;
}

.modal-section:last-child { margin-bottom: 0; }

.modal-section-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gray-500);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-200);
}

.modal-section-text {
  font-size: 16px;
  color: var(--gray-800);
  line-height: 1.75;
}

.modal-member-header {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--gray-200);
}

.modal-member-name {
  font-family: 'Merriweather', serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--blue-dark);
}

.modal-member-sub {
  font-size: 13px;
  color: var(--gray-500);
  margin-top: 4px;
}

.modal-votes-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal-vote-item {
  border: 1px solid var(--gray-200);
  border-radius: 10px;
  padding: 16px 18px;
  transition: box-shadow 0.15s;
}

.modal-vote-item:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.07);
}

.modal-vote-item-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.modal-vote-item-date {
  font-size: 12px;
  color: var(--gray-500);
}

.modal-vote-category {
  font-size: 11px;
  background: var(--gray-100);
  color: var(--gray-500);
  padding: 2px 8px;
  border-radius: 4px;
}

.modal-vote-item-desc {
  font-size: 15px;
  color: var(--gray-800);
  line-height: 1.5;
  margin-bottom: 6px;
  font-weight: 500;
}

.modal-vote-item-result {
  font-size: 12px;
  color: var(--gray-500);
  margin-bottom: 10px;
}

.modal-summarize-btn {
  background: var(--blue);
  color: var(--white);
  border: none;
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: background 0.15s;
  margin-top: 4px;
}

.modal-summarize-btn:hover {
  background: var(--blue-dark);
}

.modal-back-bar {
  margin-bottom: 20px;
}

.modal-back-btn {
  background: none;
  border: 1px solid var(--gray-300);
  color: var(--blue);
  font-size: 13px;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s;
}

.modal-back-btn:hover {
  background: var(--gray-100);
}

.modal-bill-section {
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 4px;
}

.modal-disclaimer {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--gray-200);
  font-size: 11px;
  color: var(--gray-500);
  font-style: italic;
  text-align: center;
}

.modal-loading {
  text-align: center;
  padding: 48px 24px;
  color: var(--gray-500);
  font-size: 15px;
}

.modal-error {
  text-align: center;
  padding: 32px 24px;
  color: #991B1B;
  font-size: 15px;
}

/* ─── Utility ────────────────────────────────────────────────────────────── */
.hidden { display: none !important; }
.container { max-width: 900px; margin: 0 auto; padding: 0 24px; }

/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-text h2 {
    font-size: 34px;
  }

  .hero {
    padding: 48px 24px;
  }

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

  .features-inner {
    grid-template-columns: 1fr;
  }

  .site-header {
    padding: 0 20px;
  }

  nav { display: none; }
}
