:root {
  --navy: #181326;
  --navy-mid: #2a2146;
  --navy-card: #ffffff;
  --navy-card-hover: #f4f0ff;
  --red: #4d3d79;
  --red-bright: #7d6bc4;
  --blue: #241c38;
  --blue-mid: #6d5fb8;
  --blue-bright: #9f8fe8;
  --blue-glow: rgba(109,95,184,0.14);
  --slate: #615872;
  --white: #ffffff;
  --text-primary: #181326;
  --text-muted: #4f465f;
  --border: rgba(24,19,38,0.14);
  --border-accent: rgba(109,95,184,0.35);
  --accent: #6d5fb8;
  --accent-strong: #4d3d79;
  --success-soft: #f4f0ff;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: "DM Sans", sans-serif; background: #ffffff; color: var(--text-primary); overflow-x: hidden; }
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 8%, rgba(191,176,240,0.18), transparent 24rem),
    radial-gradient(circle at 85% 36%, rgba(109,95,184,0.08), transparent 28rem),
    linear-gradient(180deg, #ffffff 0%, #fbf9ff 52%, #ffffff 100%);
}

.footer-social-links {
  display: flex;
  gap: 0.95rem;
  justify-content: center;
  flex-wrap: wrap;
}

.footer-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 0.1rem;
  border-radius: 0;
  border: none;
  background: transparent;
  color: var(--accent-strong);
  text-decoration: none;
  transition: color 0.18s ease, transform 0.18s ease;
}

.footer-social-link:hover {
  transform: translateY(-1px);
  color: var(--accent);
}

.footer-social-icon {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.footer-social-icon svg {
  width: 100%;
  height: 100%;
  display: block;
  fill: currentColor;
}

/* ── HEADER ── */
header {
  position: relative; min-height: auto;
  display: flex; flex-direction: column;
  justify-content: center; align-items: center;
  text-align: center; padding: 4.8rem 2rem 0.8rem; overflow: visible;
  z-index: 50;
}
.header-bg {
  position: absolute; inset: 0;
  background: transparent;
}
.stars { display: none; }
.stripe-bar {
  display: none;
}
.site-nav {
  position: absolute; top: 1.35rem; left: 1.6rem;
  z-index: 10; animation: fadeUp 0.6s ease both;
}
.logo-img {
  display: block;
  width: clamp(190px, 19vw, 280px);
  height: auto;
  max-width: calc(100vw - 9rem);
}
.site-menu {
  position: fixed;
  top: 4.85rem;
  right: 1.25rem;
  z-index: 1000;
  display: none;
  width: min(340px, calc(100vw - 2rem));
  max-width: none;
  grid-template-columns: 1fr;
  gap: 0.55rem;
  padding: 0.75rem;
  border: 1px solid rgba(24,19,38,0.16);
  border-radius: 18px;
  background: rgba(255,255,255,0.96);
  box-shadow: 0 22px 54px rgba(24, 19, 38, 0.18);
  backdrop-filter: blur(14px);
}
.site-menu.is-open {
  display: grid;
}
.site-menu a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  border: 1px solid rgba(24,19,38,0.14);
  border-radius: 12px;
  background: rgba(244,240,255,0.78);
  color: var(--text-primary);
  text-decoration: none;
  font-family: "DM Mono", monospace;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.78rem 0.9rem;
  box-shadow: 0 8px 22px rgba(24, 19, 38, 0.06);
}
.site-menu a::after {
  content: "→";
  color: var(--accent);
}
.site-menu a:hover {
  background: #f4f0ff;
  color: var(--accent-strong);
  border-color: rgba(109,95,184,0.28);
}
.site-menu a[href="/about"],
.site-menu a[href="/about/"],
.site-menu a[href="/contact"],
.site-menu a[href="/contact/"],
.site-menu a[href="/senate-races"],
.site-menu a[href="/senate-races/"],
.site-menu a[href="/house-races"],
.site-menu a[href="/house-races/"],
.site-menu a[href="/governor-races"],
.site-menu a[href="/governor-races/"] {
  display: none !important;
}
.menu-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: 1px solid rgba(24,19,38,0.16);
  border-radius: 999px;
  background: rgba(255,255,255,0.9);
  color: var(--text-primary);
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.55rem 0.8rem;
  box-shadow: 0 10px 28px rgba(24, 19, 38, 0.1);
  cursor: pointer;
}
.menu-toggle-lines {
  display: inline-flex;
  flex-direction: column;
  gap: 0.22rem;
}
.menu-toggle-lines span {
  display: block;
  width: 1.05rem;
  height: 2px;
  border-radius: 99px;
  background: var(--accent-strong);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.menu-toggle[aria-expanded="true"] .menu-toggle-lines span:nth-child(1) {
  transform: translateY(0.32rem) rotate(45deg);
}
.menu-toggle[aria-expanded="true"] .menu-toggle-lines span:nth-child(2) {
  opacity: 0;
}
.menu-toggle[aria-expanded="true"] .menu-toggle-lines span:nth-child(3) {
  transform: translateY(-0.32rem) rotate(-45deg);
}
.site-menu-toggle {
  position: fixed;
  top: 1.6rem;
  right: 1.25rem;
  z-index: 1001;
}
.header-content {
  position: relative; z-index: 2;
  animation: fadeUp 1s ease both;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
.badge {
  display: inline-block; font-family: "DM Mono", monospace;
  font-size: 0.68rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--accent); border: 1px solid var(--border-accent);
  padding: 0.35rem 1.1rem; border-radius: 2px;
  background: var(--blue-glow); margin-bottom: 1rem;
  animation: fadeUp 1s 0.2s ease both;
}
.header-title {
  font-family: "Playfair Display", serif;
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 900; line-height: 0.95;
  letter-spacing: -0.02em; margin-bottom: 0.7rem;
  color: var(--navy); animation: fadeUp 1s 0.3s ease both;
}
.header-title span { color: var(--accent); }
.tagline {
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  color: var(--text-muted); max-width: 500px;
  line-height: 1.7; margin: 0 auto 2.5rem;
  animation: fadeUp 1s 0.4s ease both;
}
.election-pill {
  display: inline-flex; align-items: center; gap: 0.6rem;
  background: rgba(109,95,184,0.1); border: 1px solid rgba(109,95,184,0.35);
  padding: 0.55rem 1.2rem; border-radius: 100px;
  font-size: 0.88rem; font-weight: 600; color: var(--accent);
  margin-bottom: 0; animation: fadeUp 1s 0.5s ease both;
}
.election-pill .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.6); opacity: 0.5; }
}
.nav-pills {
  display: flex; flex-wrap: wrap; gap: 0.6rem;
  justify-content: center; animation: fadeUp 1s 0.6s ease both;
}
.nav-pill {
  display: inline-block; padding: 0.55rem 1.3rem;
  border-radius: 100px; font-size: 0.82rem; font-weight: 500;
  cursor: pointer; text-decoration: none; transition: all 0.2s;
  border: 1px solid rgba(24,19,38,0.16); color: var(--text-primary);
  background: rgba(24,19,38,0.04);
}
.nav-pill:hover { background: rgba(109,95,184,0.12); color: var(--navy); transform: translateY(-2px); }
.nav-pill.featured {
  background: rgba(109,95,184,0.12); border-color: rgba(109,95,184,0.35);
  color: var(--accent-strong); font-weight: 700;
}
.nav-pill.featured:hover { background: rgba(109,95,184,0.2); }
.scroll-hint {
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  font-size: 0.68rem; letter-spacing: 0.15em; text-transform: uppercase;
  color: #716782; animation: fadeUp 1s 1.2s ease both;
}
.scroll-line {
  width: 1px; height: 36px;
  background: linear-gradient(to bottom, var(--slate), transparent);
  animation: scrollAnim 2s ease-in-out infinite;
}
@keyframes scrollAnim {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ── LAYOUT ── */
main { max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 5rem 0; border-top: 1px solid var(--border); }
.section-compact { padding-top: 4rem; }
.section-label {
  font-family: "DM Mono", monospace; font-size: 0.65rem;
  letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 0.6rem;
}
.section-title {
  font-family: "Playfair Display", serif;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700; line-height: 1.15; margin-bottom: 0.8rem; color: var(--text-primary);
}
.section-desc {
  color: var(--text-muted); max-width: 580px;
  line-height: 1.7; margin-bottom: 2.5rem; font-size: 0.95rem;
}

/* ── ZIP LOOKUP ── */
.lookup-section {
  padding: 1rem 0 0.8rem; border-top: none;
  background: transparent;
  border-bottom: 0;
  margin-bottom: 0;
}
.lookup-inner { max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; }
.lookup-box {
  background: rgba(255,255,255,0.86); border: 1px solid rgba(109,95,184,0.16);
  border-radius: 20px; padding: 2.35rem;
  box-shadow: 0 16px 44px rgba(24, 19, 38, 0.06);
  backdrop-filter: blur(10px);
}
.home-lookup-box {
  max-width: 760px;
  margin: 0 auto;
  padding: 1.4rem 1.5rem 1.05rem;
}
.home-lookup-centered {
  text-align: center;
}
.home-lookup-copy .section-label {
  margin-bottom: 0.35rem;
}
.home-lookup-box .lookup-title {
  font-size: clamp(1.35rem, 2.3vw, 1.8rem);
  margin-bottom: 0.25rem;
}
.home-lookup-box .lookup-desc {
  max-width: 560px;
  margin: 0 auto 0.9rem;
  line-height: 1.35;
}
.home-lookup-form {
  justify-content: center;
  margin-bottom: 0.65rem;
}
.home-lookup-box .api-note {
  font-size: 0.72rem;
  line-height: 1.35;
}
body.has-results .home-lookup-box {
  border: none;
  box-shadow: none;
  background: transparent;
  padding: 0;
}
body.has-results .home-lookup-copy,
body.has-results .home-lookup-box .api-note {
  display: none;
}
body.has-results .home-lookup-form {
  margin-bottom: 1.25rem;
}
body.has-results #lookup-results {
  margin-top: 0;
}
body.has-results #video-hub,
body.has-results .home-main {
  display: none;
}
.lookup-title {
  font-family: "Playfair Display", serif;
  font-size: 1.8rem; font-weight: 700; color: var(--text-primary); margin-bottom: 0.5rem;
}
.lookup-desc { color: var(--text-muted); margin-bottom: 2rem; font-size: 0.92rem; line-height: 1.6; }
.coverage-note {
  background: var(--success-soft);
  border: 1px solid rgba(109, 95, 184, 0.2);
  border-radius: 10px;
  color: var(--text-primary);
  font-size: 0.82rem;
  line-height: 1.6;
  padding: 0.85rem 1rem;
  margin-bottom: 1.35rem;
}
.coverage-note strong { color: var(--accent-strong); }
.lookup-form { display: flex; gap: 0.75rem; flex-wrap: wrap; align-items: flex-end; margin-bottom: 1.5rem; }
.local-lookup-form {
  row-gap: 0.75rem;
  column-gap: 0.75rem;
  align-items: stretch;
}
.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-group-wide { min-width: min(100%, 340px); flex: 1 1 320px; }
.form-group label {
  font-size: 0.72rem; font-family: "DM Mono", monospace;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent);
}
.optional-label {
  color: var(--slate);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
}
.form-group input {
  background: #f6f2ff; border: 1px solid rgba(109,95,184,0.25);
  border-radius: 8px; padding: 0.75rem 1rem; color: var(--text-primary);
  font-family: "DM Sans", sans-serif; font-size: 1rem; outline: none;
  transition: border-color 0.2s; min-width: 180px;
}
.form-group input:focus { border-color: var(--accent); background: #efe8ff; }
.form-group input::placeholder { color: #8f84a6; }
#state-input { text-transform: uppercase; }
.lookup-btn {
  background: var(--accent); color: var(--white); border: none;
  padding: 0.75rem 2rem; border-radius: 8px; font-weight: 700;
  font-family: "DM Sans", sans-serif; font-size: 0.95rem;
  cursor: pointer; transition: all 0.2s; white-space: nowrap; align-self: flex-end;
}
.lookup-btn,
a.lookup-btn,
a.lookup-btn:visited {
  color: var(--white);
  text-decoration: none;
}
.lookup-btn:hover { background: var(--accent-strong); transform: translateY(-1px); }
.lookup-btn:hover,
a.lookup-btn:hover,
a.lookup-btn:focus-visible {
  color: var(--white);
}
.lookup-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.api-note {
  font-size: 0.78rem; color: var(--text-muted); line-height: 1.5;
}
.api-note a { color: var(--accent); text-decoration: none; }
.api-note a:hover { text-decoration: underline; }
.lookup-promise-grid,
.ballot-snapshot-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 0.9rem;
}
.lookup-promise-grid div,
.ballot-snapshot-card {
  background: linear-gradient(145deg, rgba(255,255,255,0.94), rgba(246,242,255,0.72));
  border: 1px solid rgba(109,95,184,0.16);
  border-radius: 14px;
  padding: 0.8rem;
  text-align: left;
  box-shadow: 0 10px 24px rgba(24,19,38,0.045);
}
.lookup-promise-grid span,
.ballot-snapshot-card span {
  display: block;
  color: var(--accent);
  font-family: "DM Mono", monospace;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  margin-bottom: 0.25rem;
  text-transform: uppercase;
}
.lookup-promise-grid strong,
.ballot-snapshot-card strong {
  color: var(--text-primary);
  display: block;
  font-size: 0.82rem;
  line-height: 1.25;
}
.ballot-snapshot-grid {
  margin: 0 0 1.35rem;
}
.ballot-snapshot-card p {
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
  margin: 0.45rem 0 0;
}
#lookup-results { margin-top: 2rem; }
#lookup-results:empty { margin-top: 0; }
.lookup-results-skeleton {
  /* Fill the viewport while results load so the swap to the rendered
     ballot never moves visible content below it (mobile CLS was 0.13;
     the skeleton-to-results swap lands >500ms after the tap, so Chrome
     counts it). 100svh pushes the footer fully off-screen during load. */
  min-height: max(620px, 100svh);
  border: 1px solid rgba(109,95,184,0.14);
  border-radius: 12px;
  background:
    linear-gradient(90deg, rgba(255,255,255,0), rgba(255,255,255,0.78), rgba(255,255,255,0)) 0 0 / 220px 100% no-repeat,
    linear-gradient(180deg, rgba(251,249,255,0.92), rgba(246,242,255,0.72));
  animation: lookup-skeleton-sheen 1.15s ease-in-out infinite;
}
@keyframes lookup-skeleton-sheen {
  0% { background-position: -240px 0, 0 0; }
  100% { background-position: calc(100% + 240px) 0, 0 0; }
}
.lookup-mode-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0 0 1rem;
  line-height: 1.6;
}
.results-header { font-family: "Playfair Display", serif; font-size: 1.3rem; color: var(--text-primary); margin-bottom: 1.2rem; }
.results-location { font-family: "DM Mono", monospace; font-size: 0.75rem; color: var(--accent); letter-spacing: 0.1em; margin-bottom: 1.5rem; text-transform: uppercase; }
.live-results {
  background: #fbf9ff;
  border: 1px solid rgba(109, 95, 184, 0.2);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}
.live-results-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 0.9rem;
  margin-bottom: 0.8rem;
}
.live-results-title {
  font-family: "Playfair Display", serif;
  font-size: 1.2rem;
  color: var(--text-primary);
  font-weight: 700;
}
.live-results-meta {
  font-size: 0.76rem;
  font-family: "DM Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.live-results-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1rem;
}
.live-results-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.live-results-summary div {
  min-width: 180px;
  background: #ffffff;
  border: 1px solid rgba(109, 95, 184, 0.16);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
}
.live-results-summary span {
  display: block;
  font-size: 0.68rem;
  font-family: "DM Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 0.3rem;
}
.live-results-summary strong {
  display: block;
  font-size: 0.86rem;
  color: var(--text-primary);
  line-height: 1.5;
}
.authority-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  margin-bottom: 1rem;
}
.authority-label {
  font-size: 0.72rem;
  font-family: "DM Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate);
  margin-right: 0.2rem;
}
.authority-links a {
  display: inline-flex;
  align-items: center;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  background: rgba(109, 95, 184, 0.1);
  border: 1px solid rgba(109, 95, 184, 0.18);
}
.authority-links a:hover {
  background: rgba(109, 95, 184, 0.18);
}
.contest-grid {
  display: grid;
  /* minmax(0, 1fr), not the implicit `auto` track. An auto track sizes to the
     item's MAX-CONTENT width, so on a 390px phone the single column resolved
     to 429px inside a 304px container and #lookup-results (overflow-x:hidden)
     silently sliced ~84px off the right edge of every bio, priority and
     voting-record line. No scrollbar appeared, so it read as truncated text
     rather than a layout bug. Found 2026-08-10 from Clarity mobile replays. */
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
}
.candidate-list,
.office-accordion-wrap {
  grid-template-columns: minmax(0, 1fr);
}
/* Grid and flex children default to min-width:auto, which refuses to shrink
   below their content. Every ancestor of the bio text needs an explicit 0. */
.contest-grid > *,
.candidate-list > *,
.office-accordion-wrap > *,
.accordion-sim,
.accordion-sim details,
.accordion-content {
  min-width: 0;
}
/* INP fix (Clarity July 11: 540ms poor): skip layout/paint for offscreen
   contest cards on long ballots. The browser renders them as they scroll
   into view; anchors and scrollIntoView still work. */
.contest-grid .accordion-sim {
  content-visibility: auto;
  contain-intrinsic-size: auto 240px;
}
.office-accordion {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
}
.office-accordion + .office-accordion {
  margin-top: 0.5rem;
}
.office-accordion summary {
  list-style: none;
  cursor: pointer;
  padding: 0.9rem 1rem;
  margin: 0;
  background: var(--navy-card);
  border-bottom: 1px solid rgba(109,95,184,0.12);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.8rem;
}
.office-accordion summary::-webkit-details-marker {
  display: none;
}
.office-accordion summary::after {
  content: "▸";
  font-size: 0.95rem;
  color: var(--slate);
  transform: rotate(0deg);
  transition: transform 0.18s ease;
  flex: 0 0 auto;
}
.office-accordion[open] summary {
  border-bottom: 1px solid rgba(109,95,184,0.18);
}
.office-accordion[open] summary::after {
  transform: rotate(90deg);
}
.office-accordion summary .contest-office {
  margin-bottom: 0.35rem;
}
.office-accordion .office-accordion-content {
  padding: 0.95rem 1rem 1rem;
}
.contest-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1rem 0.95rem;
}
.contest-office {
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.2rem;
}
.contest-type {
  font-size: 0.74rem;
  font-family: "DM Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 0.7rem;
}
.candidate-list {
  display: grid;
  gap: 0.7rem;
}
.candidate-item {
  border-top: 1px solid rgba(24,19,38,0.08);
  padding-top: 0.7rem;
  min-width: 0;
}
.candidate-item:first-child {
  border-top: none;
  padding-top: 0;
}
.candidate-name {
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.15rem;
}
.candidate-profile-trigger {
  all: unset;
  cursor: default;
  width: 100%;
  text-align: left;
  display: block;
  box-sizing: border-box;
  min-width: 0;
}
.candidate-party,
.candidate-channels {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.candidate-profile-panel {
  margin-top: 0.65rem;
  border-radius: 10px;
  padding: 0.7rem;
  background: #f8f4ff;
  border: 1px solid rgba(109,95,184,0.2);
  display: block;
}
.candidate-profile-panel[hidden] {
  display: none;
}
.candidate-profile-photo-wrap {
  display: flex;
  justify-content: center;
  margin: 0 0 0.55rem;
}
.candidate-profile-photo {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  object-fit: cover;
  object-position: top;
  border: 2px solid rgba(109,95,184,0.2);
  background: #fff;
}
.candidate-profile-row {
  display: flex;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.45rem;
  font-size: 0.8rem;
  color: var(--text-primary);
}
.candidate-profile-row:last-child {
  margin-bottom: 0;
}
.candidate-profile-row span {
  color: var(--text-muted);
}
.candidate-profile-row strong {
  font-family: "DM Mono", monospace;
  font-size: 0.72rem;
  text-align: right;
  font-weight: 600;
}
.candidate-profile-row a {
  color: #4d3d79;
  text-decoration: none;
}
.candidate-profile-row a:hover {
  text-decoration: underline;
}
.candidate-profile-note {
  margin-top: 0.55rem;
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.6;
}
.candidate-profile-note strong,
.candidate-profile-section strong {
  color: var(--text-primary);
  font-weight: 600;
}
.candidate-profile-section {
  margin-top: 0.5rem;
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.45;
}
.candidate-profile-priorities {
  margin: 0.4rem 0 0;
  padding-left: 1rem;
}
.candidate-profile-priorities li {
  margin-bottom: 0.18rem;
}
.candidate-profile-links {
  margin-top: 0.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.candidate-profile-meta {
  margin-top: 0.6rem;
  font-size: 0.74rem;
  color: var(--slate);
  line-height: 1.45;
}
.candidate-inline-photo-wrap {
  display: flex;
  justify-content: flex-start;
  margin: 0.45rem 0 0.35rem;
}
.candidate-inline-photo {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  object-fit: cover;
  object-position: top;
  border: 1px solid rgba(109,95,184,0.25);
  background: #fff;
}
.candidate-inline-bio {
  margin-top: 0.4rem;
  color: var(--text-primary);
  font-size: 0.82rem;
  line-height: 1.55;
}
.candidate-inline-priorities {
  margin: 0.45rem 0 0.2rem;
  padding-left: 1rem;
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}
.candidate-inline-priorities li {
  margin-bottom: 0.18rem;
}
.candidate-channels a {
  color: var(--accent);
  text-decoration: none;
}
.candidate-channels a:hover {
  text-decoration: underline;
}
.candidate-missing {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-style: italic;
}
.location-section {
  margin-top: 1rem;
}
.location-section-title {
  font-size: 0.78rem;
  font-family: "DM Mono", monospace;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 0.7rem;
}
.location-grid {
  display: grid;
  gap: 0.8rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.location-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.95rem;
}
.location-name {
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}
.location-address,
.location-detail {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.55;
}
.location-detail strong {
  color: var(--text-primary);
}
.lookup-divider {
  margin: 1.5rem 0 1rem;
  border: none;
  border-top: 1px solid rgba(24,19,38,0.12);
}
.lookup-subhead {
  font-size: 1rem;
  color: var(--text-primary);
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.office-group { margin-bottom: 2rem; }
.office-group-label {
  font-family: "DM Mono", monospace; font-size: 0.65rem; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--slate); padding: 0.4rem 0;
  border-bottom: 1px solid rgba(109,95,184,0.16); margin-bottom: 1rem;
}
.rep-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.governor-office-group {
  text-align: center;
}
.governor-rep-cards {
  grid-template-columns: minmax(280px, 520px);
  justify-content: center;
}
.governor-rep-cards .rep-card {
  margin-left: auto;
  margin-right: auto;
  max-width: 520px;
  width: 100%;
}
.governor-office-group .race2026-card {
  margin-left: auto;
  margin-right: auto;
  max-width: 620px;
  text-align: left;
}
.rep-card {
  background: #ffffff; border: 1px solid var(--border);
  border-radius: 10px; padding: 1.25rem; transition: all 0.2s;
  box-shadow: 0 10px 25px rgba(24, 19, 38, 0.05);
}
.rep-card:hover { background: #f4f0ff; border-color: rgba(109,95,184,0.25); }
.rep-name { font-weight: 700; font-size: 1rem; color: var(--text-primary); margin-bottom: 0.2rem; }
.rep-office { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.6rem; line-height: 1.4; }
.rep-party {
  display: inline-block; font-family: "DM Mono", monospace;
  font-size: 0.65rem; letter-spacing: 0.08em; padding: 0.2rem 0.55rem;
  border-radius: 3px; margin-bottom: 0.8rem; font-weight: 700;
}
.party-D { background: rgba(109,95,184,0.12); color: #4d3d79; border: 1px solid rgba(109,95,184,0.3); }
.party-R { background: rgba(125,107,196,0.12); color: #4d3d79; border: 1px solid rgba(125,107,196,0.3); }
.party-I { background: rgba(109,95,184,0.1); color: var(--accent-strong); border: 1px solid var(--border-accent); }
.rep-links { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.rep-link {
  display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.72rem; font-family: "DM Mono", monospace;
  padding: 0.3rem 0.7rem; border-radius: 4px; text-decoration: none;
  transition: all 0.2s; border: 1px solid;
}
.rep-link.website { background: rgba(109,95,184,0.1); color: var(--accent); border-color: rgba(109,95,184,0.3); }
.rep-link.website:hover { background: rgba(109,95,184,0.18); }
.rep-link.youtube { background: rgba(255,0,0,0.1); color: #ff8888; border-color: rgba(255,0,0,0.3); }
.rep-link.youtube:hover { background: rgba(255,0,0,0.2); }
.rep-link.facebook { background: rgba(59,89,182,0.15); color: #8aadff; border-color: rgba(59,89,182,0.35); }
.rep-link.facebook:hover { background: rgba(59,89,182,0.25); }
.rep-link.twitter { background: rgba(29,161,242,0.1); color: #5bc0ff; border-color: rgba(29,161,242,0.3); }
.rep-link.twitter:hover { background: rgba(29,161,242,0.2); }
.rep-link.votes { background: rgba(24,19,38,0.04); color: var(--text-primary); border-color: var(--border); }
.rep-link.votes:hover { color: var(--text-primary); background: rgba(24,19,38,0.08); }
.rep-status {
  margin-top: 0.65rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.phone-num { font-size: 0.78rem; color: var(--text-muted); margin-top: 0.5rem; font-family: "DM Mono", monospace; }
.fallback-links { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.5rem; }
.fallback-btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.6rem 1.2rem; border-radius: 8px; font-size: 0.83rem;
  text-decoration: none; font-weight: 600; transition: all 0.2s;
  background: #ffffff; color: var(--text-primary);
  border: 1px solid rgba(109,95,184,0.22);
}
.fallback-btn:hover { background: #f4f0ff; color: var(--navy); transform: translateY(-1px); box-shadow: 0 2px 8px rgba(109,95,184,0.14); }
.error-msg { background: rgba(159,47,35,0.08); border: 1px solid rgba(159,47,35,0.25); border-radius: 8px; padding: 1rem 1.25rem; color: #7b2219; font-size: 0.88rem; line-height: 1.6; }
.lookup-info-msg { background: rgba(109,95,184,0.1); border: 1px solid rgba(109,95,184,0.22); border-radius: 8px; padding: 1rem 1.25rem; color: var(--text-primary); font-size: 0.88rem; line-height: 1.6; }
.loading-msg { color: var(--text-muted); font-size: 0.92rem; padding: 1rem 0; display: flex; align-items: center; gap: 0.75rem; }
.spinner {
  width: 18px; height: 18px; border-radius: 50%;
  border: 2px solid rgba(109,95,184,0.22); border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }


.snap-loading-stage {
  position: fixed;
  inset: 0;
  z-index: 9999;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  display: grid;
  place-items: center;
  margin: 0;
  padding: max(18px, env(safe-area-inset-top)) 18px max(18px, env(safe-area-inset-bottom));
  overflow: hidden;
  border-radius: 0;
  background: rgba(248,246,242,0.82);
  backdrop-filter: blur(8px);
  --snap-step-duration: 2.2s;
  --snap-card-delay: 2.2s;
}
.snap-loading-stage.snap-loading-fast {
  --snap-step-duration: 1.45s;
  --snap-card-delay: 1.45s;
}
.snap-loading-card {
  position: relative;
  z-index: 2;
  width: min(330px, calc(100% - 8px));
  margin: 0 auto;
  padding: 16px;
  border: 1px solid rgba(109,95,184,0.18);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(24,19,38,0.08);
  animation: snap-card-working 1.35s ease-in-out var(--snap-card-delay) infinite;
}
.snap-loading-title {
  margin: 0 0 10px;
  font-size: 1.05rem;
  line-height: 1.3;
  font-weight: 800;
  color: var(--text-primary);
}
.snap-loading-title .initial {
  animation: none;
}
.snap-loading-title::after {
  display: block;
  content: "";
  color: var(--accent);
  opacity: 0;
  margin-top: 2px;
  text-align: left;
}
.snap-loading-more {
  margin: -2px 0 12px;
  color: var(--text-muted);
  font-size: 0.8rem;
  line-height: 1.45;
  text-align: left;
  opacity: 1;
}
.snap-loading-place {
  margin: 0 0 13px;
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.45;
}
.snap-loading-steps {
  display: grid;
  gap: 10px;
}
.snap-step {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 10px;
  align-items: center;
  color: var(--text-muted);
  opacity: 0.46;
  font-size: 0.92rem;
  transform: translateY(2px);
}
.snap-step-icon {
  position: relative;
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: #fff;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 900;
  line-height: 1;
  overflow: visible;
}
.snap-step-1 { animation: snap-step-on var(--snap-step-duration) steps(1, end) forwards; }
.snap-step-2 { animation: snap-step-two-on var(--snap-step-duration) steps(1, end) forwards; }
.snap-step-3 { animation: snap-step-three-on var(--snap-step-duration) steps(1, end) forwards; }
.snap-step-1 .snap-step-icon { animation: snap-first-check var(--snap-step-duration) ease forwards; }
.snap-step-2 .snap-step-icon { animation: snap-gps-to-check var(--snap-step-duration) ease forwards; }
.snap-step-3 .snap-step-icon { animation: snap-avatar-active var(--snap-step-duration) ease forwards; }
.snap-step-3 .snap-step-icon::after {
  content: "";
  position: absolute;
  inset: -7px;
  border: 2px solid rgba(109,95,184,0.26);
  border-radius: 50%;
  opacity: 0;
  animation: snap-avatar-ring 1s ease-out var(--snap-card-delay) infinite;
}
.snap-step-1 .snap-step-text { animation: snap-text-lock var(--snap-step-duration) ease forwards; }
.snap-step .check-symbol {
  position: absolute;
  opacity: 0;
  color: #fff;
}
.snap-step-1 .check-symbol { animation: snap-check-one-symbol var(--snap-step-duration) steps(1, end) forwards; }
.snap-step-2 .check-symbol { animation: snap-check-two-symbol var(--snap-step-duration) steps(1, end) forwards; }
.snap-step-3 .check-symbol { display: none; }
.gps-dot {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0;
  animation: snap-gps-dot var(--snap-step-duration) ease forwards;
}
.gps-dot::before {
  content: "";
  position: absolute;
  inset: -8px;
  border: 2px solid rgba(109,95,184,0.24);
  border-radius: 50%;
  animation: snap-gps-ring 0.8s ease-out infinite;
}
.candidate-avatar {
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  opacity: 0;
  background:
    radial-gradient(circle at 50% 34%, #fff 0 18%, transparent 19%),
    radial-gradient(circle at 50% 83%, #fff 0 32%, transparent 33%),
    var(--accent);
  animation: snap-avatar-symbol var(--snap-step-duration) ease forwards, snap-avatar-pulse 0.75s ease-in-out calc(var(--snap-step-duration) * 0.8) infinite;
}
@keyframes snap-step-on {
  0%, 100% { opacity: 1; color: var(--text-primary); transform: translateY(0); font-weight: 700; }
}
@keyframes snap-step-two-on {
  0%, 19% { opacity: 0.46; color: var(--text-muted); transform: translateY(2px); font-weight: 400; }
  20%, 100% { opacity: 1; color: var(--text-primary); transform: translateY(0); font-weight: 700; }
}
@keyframes snap-step-three-on {
  0%, 52% { opacity: 0.46; color: var(--text-muted); transform: translateY(2px); font-weight: 400; }
  53%, 100% { opacity: 1; color: var(--text-primary); transform: translateY(0); font-weight: 700; }
}
@keyframes snap-first-check {
  0% { color: #fff; background: #2e8b57; border-color: #2e8b57; transform: scale(0.24); }
  8% { color: #fff; background: #2e8b57; border-color: #2e8b57; transform: scale(1.24); }
  14%, 100% { color: #fff; background: #2e8b57; border-color: #2e8b57; transform: scale(1); }
}
@keyframes snap-gps-to-check {
  0%, 19% { background: #fff; border-color: var(--border); transform: scale(1); }
  20%, 52% { background: rgba(109,95,184,0.08); border-color: rgba(109,95,184,0.35); transform: scale(1.04); }
  53% { background: #2e8b57; border-color: #2e8b57; transform: scale(1.24); }
  62%, 100% { background: #2e8b57; border-color: #2e8b57; transform: scale(1); }
}
@keyframes snap-avatar-active {
  0%, 52% { background: #fff; border-color: var(--border); transform: scale(1); }
  53%, 100% { background: rgba(109,95,184,0.08); border-color: rgba(109,95,184,0.35); transform: scale(1.06); }
}
@keyframes snap-check-one-symbol { 0%, 100% { opacity: 1; } }
@keyframes snap-check-two-symbol {
  0%, 52% { opacity: 0; }
  53%, 100% { opacity: 1; }
}
@keyframes snap-gps-dot {
  0%, 19% { opacity: 0; transform: scale(0.6); }
  20%, 52% { opacity: 1; transform: scale(1); }
  53%, 100% { opacity: 0; transform: scale(0.6); }
}
@keyframes snap-gps-ring {
  0% { transform: scale(0.5); opacity: 0.8; }
  100% { transform: scale(1.45); opacity: 0; }
}
@keyframes snap-avatar-symbol {
  0%, 52% { opacity: 0; transform: scale(0.6); }
  53%, 100% { opacity: 1; transform: scale(1); }
}
@keyframes snap-avatar-pulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 0 rgba(109,95,184,0)); }
  50% { transform: scale(1.38); filter: drop-shadow(0 0 14px rgba(109,95,184,0.58)); }
}
@keyframes snap-avatar-ring {
  0% { opacity: 0.72; transform: scale(0.72); }
  100% { opacity: 0; transform: scale(1.72); }
}
@keyframes snap-card-working {
  0%, 100% {
    box-shadow: 0 14px 34px rgba(24,19,38,0.08);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 20px 48px rgba(109,95,184,0.3), 0 0 0 3px rgba(109,95,184,0.08);
    transform: scale(1.018);
  }
}
@keyframes snap-text-lock {
  0% { transform: translateX(0); }
  3% { transform: translateX(-2px); }
  6% { transform: translateX(2px); }
  9%, 100% { transform: translateX(0); }
}
@keyframes snap-hide-initial-title {
  0%, 79% { opacity: 1; }
  80%, 100% { opacity: 0; }
}

@media (max-width: 640px) {
  .snap-loading-stage {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    display: grid;
    margin: 0;
    padding: max(14px, env(safe-area-inset-top)) 12px max(14px, env(safe-area-inset-bottom));
    overflow: hidden;
  }
  .snap-loading-card {
    position: relative;
    width: min(100%, 350px);
    margin-top: 0;
    padding: 14px;
    box-shadow: 0 10px 26px rgba(24,19,38,0.08);
  }
  .snap-loading-title {
    margin-bottom: 8px;
    font-size: 0.96rem;
  }
  .snap-loading-more {
    margin: -1px 0 10px;
    font-size: 0.76rem;
  }
  .snap-loading-place {
    margin-bottom: 11px;
    font-size: 0.76rem;
    word-break: break-word;
  }
  .snap-loading-steps {
    gap: 8px;
  }
  .snap-step {
    grid-template-columns: 28px 1fr;
    gap: 8px;
    font-size: 0.84rem;
  }
  .snap-step-icon {
    width: 24px;
    height: 24px;
    font-size: 0.76rem;
  }
  .gps-dot {
    width: 9px;
    height: 9px;
  }
  .gps-dot::before {
    inset: -7px;
  }
  .candidate-avatar {
    width: 17px;
    height: 17px;
  }
  .snap-step-3 .snap-step-icon::after {
    inset: -8px;
    border-color: rgba(109,95,184,0.34);
  }
}

@media (prefers-reduced-motion: reduce) {
  .snap-loading-stage,
  .snap-loading-card,
  .snap-loading-title,
  .snap-loading-title .initial,
  .snap-loading-title::after,
  .snap-step,
  .snap-step-icon,
  .snap-step .check-symbol,
  .snap-step-3 .snap-step-icon::after,
  .gps-dot,
  .gps-dot::before,
  .candidate-avatar,
  .snap-loading-more {
    animation: none !important;
  }
  .lookup-results-skeleton {
    animation: none !important;
  }
  .snap-loading-stage {
    min-height: 100svh;
    display: grid;
  }
  .snap-loading-card {
    position: static;
    margin-top: 0;
    transform: none;
    box-shadow: 0 14px 34px rgba(24,19,38,0.08);
  }
  .snap-loading-more {
    opacity: 1;
  }
  .snap-step {
    opacity: 1;
    transform: none;
  }
  .snap-step-1 .snap-step-icon,
  .snap-step-2 .snap-step-icon {
    background: #2e8b57;
    border-color: #2e8b57;
  }
  .snap-step-3 .snap-step-icon {
    background: rgba(109,95,184,0.08);
    border-color: rgba(109,95,184,0.35);
  }
  .snap-step-1 .check-symbol,
  .snap-step-2 .check-symbol {
    opacity: 1;
  }
  .candidate-avatar {
    opacity: 1;
  }
}

/* ── STATS GRID ── */
.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1px; background: rgba(109,95,184,0.14);
  border: 1px solid rgba(109,95,184,0.16); border-radius: 12px;
  overflow: hidden; margin-bottom: 2.5rem;
}
.balance-power-section {
  position: relative;
  z-index: 2;
  width: min(760px, 100%);
  max-width: 760px;
  margin: 0 auto;
  padding: 0 1.5rem;
  border-top: 0;
}
.balance-power-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 0;
}
.balance-power-grid .stat-label {
  color: inherit;
}
.balance-card-r {
  background: var(--navy-card);
  border-left: 0;
  color: #7b2219;
}
.balance-card-d {
  background: var(--navy-card);
  border-left: 0;
  color: #0d4f8f;
}
.balance-card-r:hover {
  background: var(--navy-card-hover);
}
.balance-card-d:hover {
  background: var(--navy-card-hover);
}
.balance-r {
  color: #7b2219;
}
.balance-d {
  color: #0d4f8f;
}
.stat-box {
  background: var(--navy-card); padding: 1.45rem 1.5rem;
  text-align: center; transition: background 0.2s;
}
.balance-power-grid .stat-box {
  padding: 0.95rem 0.8rem;
}
.stat-box:hover { background: var(--navy-card-hover); }
.stat-num {
  font-family: "Playfair Display", serif; font-size: 2.8rem;
  font-weight: 900; color: var(--accent); line-height: 1; margin-bottom: 0.4rem;
}
.balance-power-grid .stat-num {
  font-size: 2.15rem;
  margin-bottom: 0.25rem;
}
.balance-power-grid .stat-label {
  font-size: 0.65rem;
}
.balance-power-grid .stat-num.balance-r {
  color: #7b2219;
}
.balance-power-grid .stat-num.balance-d {
  color: #0d4f8f;
}
.stat-label { font-size: 0.75rem; color: var(--slate); letter-spacing: 0.06em; text-transform: uppercase; font-weight: 600; }

/* ── RACE CARDS ── */
.race-grid { display: grid; gap: 1.25rem; }
.race-grid-2 { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.race-card {
  background: var(--navy-card); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.5rem 1.75rem;
  transition: all 0.25s; position: relative; overflow: hidden;
}
.race-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
}
.race-card.tossup::before { background: linear-gradient(180deg, var(--accent), #bfb0f0); }
.race-card.lean-d::before { background: var(--blue-mid); }
.race-card.lean-r::before { background: var(--red-bright); }
.race-card.likely-d::before { background: rgba(37,99,235,0.6); }
.race-card.likely-r::before { background: rgba(192,57,43,0.6); }
.race-card.safe-d::before { background: rgba(37,99,235,0.3); }
.race-card.safe-r::before { background: rgba(192,57,43,0.3); }
.race-card:hover { background: #f4f0ff; transform: translateY(-2px); border-color: rgba(109,95,184,0.25); box-shadow: 0 4px 12px rgba(109,95,184,0.12); }
.race-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 0.75rem; gap: 0.5rem; flex-wrap: wrap; }
.race-state { font-family: "Playfair Display", serif; font-size: 1.25rem; font-weight: 700; color: var(--text-primary); }
.race-card h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}
.race-card p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.55;
}
.race-card a:not(.race-link) {
  display: inline-block;
  font-size: 0.73rem;
  font-family: "DM Mono", monospace;
  color: var(--accent);
  text-decoration: none;
  margin-top: 0.75rem;
}
.race-card a:not(.race-link):hover {
  text-decoration: underline;
}
.chip {
  font-size: 0.65rem; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; padding: 0.22rem 0.6rem; border-radius: 4px;
  font-family: "DM Mono", monospace;
}
.chip-tossup { background: rgba(109,95,184,0.16); color: var(--accent-strong); border: 1px solid rgba(109,95,184,0.36); }
.chip-lean-d { background: rgba(109,95,184,0.12); color: #4d3d79; border: 1px solid rgba(109,95,184,0.32); }
.chip-lean-r { background: rgba(125,107,196,0.12); color: #4d3d79; border: 1px solid rgba(125,107,196,0.32); }
.chip-likely-d { background: rgba(191,176,240,0.35); color: #4d3d79; border: 1px solid rgba(109,95,184,0.3); }
.chip-likely-r { background: rgba(192,57,43,0.15); color: #ee9080; border: 1px solid rgba(192,57,43,0.3); }
.chip-d { background: rgba(109,95,184,0.18); color: #4d3d79; border: 1px solid rgba(109,95,184,0.36); }
.chip-r { background: rgba(159,47,35,0.12); color: #9f2f23; border: 1px solid rgba(159,47,35,0.28); }
.chip-open { background: rgba(109,95,184,0.1); color: var(--accent-strong); border: 1px solid rgba(109,95,184,0.25); }
.race-meta { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.6rem; line-height: 1.5; }
.race-meta strong { color: var(--text-primary); }
.race-candidates { margin-top: 0.75rem; }
.candidate-row { display: flex; justify-content: space-between; align-items: center; padding: 0.45rem 0; border-top: 1px solid rgba(255,255,255,0.05); font-size: 0.83rem; }
.candidate-name { color: var(--text-primary); font-weight: 500; }
.candidate-info { font-size: 0.75rem; color: var(--text-muted); font-family: "DM Mono", monospace; }
.race-link { display: inline-block; font-size: 0.73rem; font-family: "DM Mono", monospace; color: var(--accent); text-decoration: none; margin-top: 0.75rem; transition: opacity 0.2s; }
.race-link:hover { opacity: 0.7; text-decoration: underline; }
.race-desc { font-size: 0.82rem; color: var(--text-muted); line-height: 1.55; margin-top: 0.5rem; }
.incumbent-badge { font-size: 0.62rem; background: rgba(255,255,255,0.08); color: var(--slate); padding: 0.15rem 0.45rem; border-radius: 3px; font-family: "DM Mono", monospace; margin-left: 0.4rem; vertical-align: middle; }
.open-badge { font-size: 0.62rem; background: rgba(109,95,184,0.12); color: var(--accent); padding: 0.15rem 0.45rem; border-radius: 3px; font-family: "DM Mono", monospace; vertical-align: middle; }

/* ── NOTICE ── */
.notice {
  background: rgba(109,95,184,0.1); border: 1px solid rgba(109,95,184,0.25);
  border-radius: 8px; padding: 0.9rem 1.2rem;
  font-size: 0.82rem; color: var(--text-muted); line-height: 1.6; margin-bottom: 2rem;
}
.notice strong { color: var(--accent); }
.notice a { color: var(--accent); }

/* ── RESOURCES ── */
.resources-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.1rem; }
.resource-card {
  background: var(--navy-card); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.6rem; text-decoration: none;
  color: inherit; transition: all 0.25s; display: block;
}
.resource-card:hover { background: #f4f0ff; transform: translateY(-3px); border-color: var(--border-accent); box-shadow: 0 4px 12px rgba(109,95,184,0.12); }
.resource-icon { font-size: 1.8rem; margin-bottom: 0.9rem; display: block; }
.resource-title { font-weight: 600; font-size: 0.95rem; margin-bottom: 0.35rem; color: var(--text-primary); }
.resource-desc { font-size: 0.8rem; color: var(--text-muted); line-height: 1.55; margin-bottom: 0.65rem; }
.resource-link { font-size: 0.74rem; color: var(--accent); font-family: "DM Mono", monospace; letter-spacing: 0.04em; font-weight: 600; }

/* ── TIMELINE ── */
.timeline { position: relative; padding-left: 2rem; }
.timeline::before { content: ""; position: absolute; left: 6px; top: 0; bottom: 0; width: 1px; background: rgba(109,95,184,0.22); }
.timeline-item { position: relative;  padding-bottom: 2rem;
}



.timeline-dot { position: absolute; left: -1.65rem; top: 4px; width: 13px; height: 13px; border-radius: 50%; background: #f0eaff; border: 2px solid var(--accent); }
.timeline-date { font-family: "DM Mono", monospace; font-size: 0.73rem; color: var(--accent); letter-spacing: 0.1em; margin-bottom: 0.25rem; font-weight: 600; }
.timeline-title { font-weight: 600; font-size: 0.93rem; margin-bottom: 0.2rem; color: var(--text-primary); }
.timeline-desc { font-size: 0.8rem; color: var(--text-muted); line-height: 1.5; }

.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}
.guide-card {
  display: block;
  text-decoration: none;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.35rem;
  box-shadow: 0 12px 28px rgba(24, 19, 38, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.guide-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px rgba(24, 19, 38, 0.08);
  border-color: rgba(109, 95, 184, 0.28);
}
.guide-card-label {
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.55rem;
}
.guide-card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  line-height: 1.35;
}
.guide-card-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.video-filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) repeat(3, minmax(150px, 0.45fr)) auto;
  gap: 0.9rem;
  align-items: end;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1rem;
  box-shadow: 0 12px 28px rgba(24, 19, 38, 0.05);
  margin-bottom: 1.25rem;
}
.video-source-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  background:
    radial-gradient(circle at 12% 20%, rgba(191,176,240,0.28), transparent 18rem),
    linear-gradient(135deg, #181326 0%, #4d3d79 100%);
  border: 1px solid rgba(191,176,240,0.32);
  border-radius: 20px;
  color: #ffffff;
  padding: 1.35rem;
  box-shadow: 0 22px 46px rgba(24,19,38,0.16);
}
.video-source-panel h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.45rem;
  margin-bottom: 0.4rem;
}
.video-source-panel p {
  max-width: 680px;
  color: rgba(255,255,255,0.82);
  font-size: 0.88rem;
  line-height: 1.65;
}
.source-scan-btn {
  border: 1px solid rgba(255,255,255,0.36);
  border-radius: 999px;
  background: rgba(255,255,255,0.94);
  color: var(--accent-strong);
  cursor: pointer;
  font-family: "DM Mono", monospace;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 0.8rem 1rem;
  text-transform: uppercase;
  transition: transform 0.2s ease, opacity 0.2s ease;
  white-space: nowrap;
}
.source-scan-btn:hover {
  transform: translateY(-2px);
}
.source-scan-btn:disabled {
  cursor: wait;
  opacity: 0.6;
  transform: none;
}
.video-source-status {
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.6;
  margin-top: 0.8rem;
}
.video-filter-bar label {
  display: grid;
  gap: 0.4rem;
}
.video-filter-bar span,
.video-count {
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.video-filter-bar input,
.video-filter-bar select {
  width: 100%;
  border: 1px solid rgba(109,95,184,0.25);
  background: #f6f2ff;
  color: var(--text-primary);
  border-radius: 10px;
  padding: 0.75rem 0.85rem;
  font-family: "DM Sans", sans-serif;
  font-size: 0.92rem;
  outline: none;
}
.video-filter-bar input:focus,
.video-filter-bar select:focus {
  border-color: var(--accent);
  background: #efe8ff;
}
.video-count {
  align-self: center;
  justify-self: end;
  color: var(--slate);
  white-space: nowrap;
}
.video-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.15rem;
}
.video-card,
.video-empty-state {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1.25rem;
  box-shadow: 0 12px 28px rgba(24, 19, 38, 0.05);
}
.video-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  overflow: hidden;
}
.video-card-topline {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.8rem;
}
.video-card-topline span {
  font-family: "DM Mono", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(109,95,184,0.1);
  border: 1px solid rgba(109,95,184,0.2);
  border-radius: 999px;
  padding: 0.25rem 0.55rem;
}
.video-card h3,
.video-empty-state h3 {
  font-size: 1.05rem;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
}
.video-card p,
.video-empty-state p {
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.6;
}
.video-card-meta {
  font-family: "DM Mono", monospace;
  font-size: 0.72rem !important;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}
.video-card blockquote {
  margin: 0.9rem 0;
  border-left: 3px solid var(--accent);
  padding-left: 0.8rem;
  color: var(--text-primary);
  font-size: 0.9rem;
  line-height: 1.6;
}
.video-card a {
  display: inline-flex;
  margin-top: auto;
  padding-top: 1rem;
  color: var(--accent);
  text-decoration: none;
  font-family: "DM Mono", monospace;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.video-card a:hover {
  text-decoration: underline;
}
.video-empty-state {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, rgba(109,95,184,0.1), rgba(191,176,240,0.18));
}
.video-empty-state code {
  font-family: "DM Mono", monospace;
  color: var(--accent-strong);
}
.video-search-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1rem;
}
.video-search-chip {
  border: 1px solid rgba(109,95,184,0.28);
  border-radius: 999px;
  background: rgba(255,255,255,0.7);
  color: var(--accent-strong) !important;
  font-family: "DM Mono", monospace;
  font-size: 0.7rem !important;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 0.55rem 0.75rem !important;
  text-decoration: none;
  text-transform: uppercase;
}
.video-search-chip:hover {
  background: #ffffff;
  text-decoration: none !important;
}
.video-forward-section {
  background: transparent;
  border-radius: 0;
  border: 0;
  padding: 1rem 1.5rem 1.2rem;
  margin: 0 auto;
  max-width: 1100px;
  width: 100%;
}
.video-home-layout {
  display: block;
}
.home-video-results {
  display: grid;
  gap: 1rem;
  min-width: 0;
}
.home-video-lead {
  border-radius: 22px;
  color: #ffffff;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,0.18), transparent 24%),
    linear-gradient(135deg, #181326 0%, #4d3d79 100%);
  padding: 1.35rem 1.5rem;
}
.home-video-lead h3 {
  font-family: "Playfair Display", serif;
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1;
  margin-bottom: 0.7rem;
}
.home-video-lead p {
  color: rgba(255,255,255,0.82);
  line-height: 1.6;
  max-width: 620px;
}
.home-video-lead a {
  display: inline-flex;
  margin-top: 1rem;
  color: #ffffff;
  font-family: "DM Mono", monospace;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}
.home-video-grid {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  padding: 0.25rem 0.15rem 1rem;
  scroll-snap-type: inline mandatory;
  scrollbar-color: rgba(109,95,184,0.55) rgba(109,95,184,0.12);
}
.home-video-grid .video-card {
  flex: 0 0 min(340px, 82vw);
  scroll-snap-align: start;
}
.home-video-grid .video-card-topline span:nth-child(3),
.home-video-grid .video-card-topline span:nth-child(4) {
  display: none;
}
.video-feature-card {
  display: grid;
  align-content: end;
  min-height: 320px;
  border-radius: 22px;
  padding: 2rem;
  text-decoration: none;
  color: #ffffff;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,0.22), transparent 24%),
    linear-gradient(135deg, #181326 0%, #4d3d79 52%, #bfb0f0 100%);
  box-shadow: 0 24px 55px rgba(24,19,38,0.18);
  overflow: hidden;
}
.video-feature-kicker {
  width: fit-content;
  margin-bottom: 1rem;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.32);
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.video-feature-card h3 {
  font-family: "Playfair Display", serif;
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 0.98;
  margin-bottom: 1rem;
}
.video-feature-card p {
  max-width: 540px;
  line-height: 1.65;
  color: rgba(255,255,255,0.88);
  margin-bottom: 1.25rem;
}
.video-feature-card span {
  font-family: "DM Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.video-home-links {
  display: grid;
  gap: 0.75rem;
  position: sticky;
  top: 1rem;
}
.video-home-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: #ffffff;
  padding: 1rem 1.1rem;
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 12px 28px rgba(24, 19, 38, 0.05);
}
.video-home-links a::after {
  content: "→";
  color: var(--accent);
}
.video-home-links a:hover {
  background: #f4f0ff;
  border-color: var(--border-accent);
}
.lookup-video-section {
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  padding-top: 2rem;
}
.lookup-video-section h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.45rem;
  color: var(--text-primary);
  margin-bottom: 1rem;
}
.lookup-video-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}
.homepage-detail-section {
  display: none;
}
.video-embed {
  margin: -0.35rem -0.35rem 1rem;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid rgba(24,19,38,0.1);
  background: linear-gradient(135deg, rgba(24,19,38,0.08), rgba(109,95,184,0.1));
}
.video-embed iframe {
  display: block;
  width: 100%;
  border: 0;
}
.video-embed-youtube {
  aspect-ratio: 16 / 9;
}
.video-embed-youtube iframe {
  height: 100%;
}
.video-embed-lite {
  position: relative;
}
.youtube-lite-button {
  position: absolute;
  inset: 0;
  width: 100%;
  border: 0;
  background-color: #181326;
  background-position: center;
  background-size: cover;
  cursor: pointer;
}
.youtube-lite-button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(24,19,38,0.04), rgba(24,19,38,0.22));
}
.youtube-play-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 14px 36px rgba(24,19,38,0.22);
}
.youtube-play-badge::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-40%, -50%);
  width: 0;
  height: 0;
  border-top: 0.55rem solid transparent;
  border-bottom: 0.55rem solid transparent;
  border-left: 0.82rem solid var(--accent-strong);
}
.video-embed-tiktok iframe {
  aspect-ratio: 9 / 16;
  min-height: 600px;
}
.video-embed-x {
  min-height: 260px;
  padding: 1rem;
}
.video-embed-platform {
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}
.video-embed-x p {
  margin: 0;
}

.guide-page {
  background: linear-gradient(180deg, rgba(109, 95, 184, 0.06) 0%, rgba(255, 255, 255, 0) 18rem);
}
.guide-hero {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 1.5rem 2rem;
}
.guide-topbar {
  position: relative;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
  width: 100%;
}
.guide-home-link {
  color: var(--accent);
  text-decoration: none;
  font-family: "DM Mono", monospace;
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.guide-home-link:hover {
  text-decoration: underline;
}
.guide-logo-link {
  display: inline-flex;
  align-items: center;
  flex: 0 1 auto;
  max-width: min(280px, calc(100vw - 8rem));
}
.guide-logo-link:hover {
  text-decoration: none;
}
.guide-logo-img {
  display: block;
  width: clamp(180px, 18vw, 260px);
  height: auto;
  max-width: 100%;
}
.guide-nav {
  position: fixed;
  top: 4.85rem;
  right: 1.25rem;
  z-index: 1000;
  display: none;
  flex-direction: column;
  width: min(340px, calc(100vw - 2rem));
  gap: 0.55rem;
  padding: 0.75rem;
  border: 1px solid rgba(24,19,38,0.16);
  border-radius: 18px;
  background: rgba(255,255,255,0.96);
  box-shadow: 0 22px 54px rgba(24, 19, 38, 0.18);
  backdrop-filter: blur(14px);
  max-height: calc(100vh - 6rem);
  overflow-y: auto;
}
.guide-nav.is-open {
  display: flex;
}
.guide-nav a {
  text-decoration: none;
  color: var(--text-primary);
  font-size: 0.82rem;
  width: 100%;
  padding: 0.78rem 0.9rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(244,240,255,0.78);
}
.guide-nav a:hover {
  border-color: rgba(109, 95, 184, 0.28);
  color: var(--accent-strong);
}
.guide-nav a[href="/about"],
.guide-nav a[href="/about/"],
.guide-nav a[href="/contact"],
.guide-nav a[href="/contact/"],
.guide-nav a[href="/senate-races"],
.guide-nav a[href="/senate-races/"],
.guide-nav a[href="/house-races"],
.guide-nav a[href="/house-races/"],
.guide-nav a[href="/governor-races"],
.guide-nav a[href="/governor-races/"] {
  display: none !important;
}
.guide-menu-toggle {
  flex: 0 0 auto;
  margin-left: auto;
}
.guide-kicker {
  font-family: "DM Mono", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.85rem;
}
.guide-title {
  font-family: "Playfair Display", serif;
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1.02;
  color: var(--text-primary);
  margin-bottom: 0.9rem;
}
.guide-intro {
  max-width: 760px;
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.75;
}
.byline {
  margin-top: 0.9rem;
  color: var(--slate);
  font-family: "DM Mono", monospace;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  line-height: 1.6;
  text-transform: uppercase;
}
.byline a {
  color: var(--accent-strong);
  text-decoration: none;
}
.byline a:hover {
  text-decoration: underline;
}
.guide-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}
/* Mobile: nested containers each add side padding (page 24 + results 16 +
   list 12 + card 6 = 58px/side), leaving bios only ~69% of a phone's width.
   Halve the outermost layer here; the inner layers are trimmed in the
   lookup's injected critical CSS. */
@media (max-width: 760px) {
  .guide-main {
    padding: 0 0.35rem 3rem;
  }
}
.guide-section {
  padding: 4.5rem 0;
  border-top: 1px solid var(--border);
}
.trending-topics-page .guide-hero {
  padding-bottom: 0.5rem;
}
.trending-topics-page .guide-main .guide-section:first-child {
  border-top: 0;
  padding-top: 1.5rem;
}
.topic-seo-note {
  max-width: 860px;
  margin: 0.85rem 0 1.5rem;
  color: var(--slate);
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  line-height: 1.7;
}
.guide-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 1.75rem;
}
.guide-meta-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.1rem;
}
.guide-meta-label {
  font-family: "DM Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 0.4rem;
}
.guide-meta-value {
  color: var(--text-primary);
  font-weight: 700;
}
.guide-list {
  display: grid;
  gap: 1rem;
}
.guide-list-card {
  background: var(--navy-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 1.75rem;
  transition: all 0.25s;
}
.guide-list-card:hover {
  background: #f4f0ff;
  transform: translateY(-2px);
  border-color: rgba(109,95,184,0.25);
  box-shadow: 0 4px 12px rgba(109,95,184,0.12);
}
.guide-list-card h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.2rem;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}
.guide-list-card p {
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.55;
}
.guide-list-card a {
  display: inline-block;
  margin-top: 0.75rem;
  font-family: "DM Mono", monospace;
  font-size: 0.73rem;
  color: var(--accent);
  text-decoration: none;
}
.guide-list-card a:hover {
  text-decoration: underline;
}
.ballot-reminder-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.25rem;
  align-items: center;
  border: 1px solid rgba(109,95,184,0.26);
  border-radius: 22px;
  background:
    radial-gradient(circle at 12% 18%, rgba(191,176,240,0.22), transparent 18rem),
    linear-gradient(135deg, #ffffff, #f8f5ff);
  padding: 1.5rem;
  box-shadow: 0 16px 36px rgba(24, 19, 38, 0.08);
}
.ballot-reminder-card p {
  color: var(--text-muted);
  line-height: 1.65;
}
.ballot-followup-shell {
  margin-top: 1rem;
}
.followup-email-form {
  display: flex;
  gap: 0.65rem;
  align-items: flex-end;
  flex-wrap: wrap;
}
.followup-email-form input[type="email"] {
  min-width: 220px;
  flex: 1;
}
#google-signin-root {
  margin-top: 0.55rem;
}
.ballot-followup-saved ul {
  margin: 0.75rem 0 0;
}
.guide-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}
.guide-callout {
  background: rgba(109,95,184,0.1);
  border: 1px solid rgba(109,95,184,0.25);
  border-radius: 8px;
  padding: 0.9rem 1.2rem;
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.6;
}

/* ── FOOTER ── */
footer { border-top: 1px solid rgba(109,95,184,0.18); background: #f4f0ff; padding: 3rem 1.5rem; text-align: center; color: var(--text-muted); font-size: 0.82rem; line-height: 1.7; }
footer a { color: var(--accent); text-decoration: none; }
footer a:hover { text-decoration: underline; }

.footer-nav-columns {
  margin: 2rem auto 0.75rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 200px));
  align-items: start;
  justify-content: center;
  gap: 2rem;
  font-size: 0.8rem;
  padding-top: 0.4rem;
}

.footer-link-column {
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  text-align: left;
}

.footer-link-column h3 {
  margin: 0 0 0.15rem;
  color: var(--navy);
  font-family: "DM Sans", sans-serif;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer-link-column a {
  color: rgba(35, 26, 69, 0.8);
  text-decoration: none;
}

.footer-link-column a:hover {
  color: var(--accent-strong);
  text-decoration: underline;
}

@media (max-width: 560px) {
  .footer-nav-columns {
    grid-template-columns: 1fr;
    max-width: 220px;
    gap: 1.4rem;
  }
}

/* ── STATE HUBS ── */
.state-hub-header {
  background: var(--navy);
  padding: 1rem 1.5rem;
}

.state-hub-logo {
  color: #fff;
  font-family: "Playfair Display", serif;
  font-size: 1.45rem;
  font-weight: 900;
  text-decoration: none;
}

.state-hub-page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 3.5rem 1.25rem;
}

.state-hub-hero {
  margin-bottom: 2.5rem;
  max-width: 760px;
}

.state-hub-hero h1 {
  margin: 0.35rem 0 0.8rem;
  color: var(--navy);
  font-family: "Playfair Display", serif;
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  line-height: 0.95;
}

.state-hub-hero p:not(.eyebrow) {
  color: var(--slate);
  font-size: 1.05rem;
}

.state-candidate-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.2rem;
}

.state-candidate-card {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  border: 1px solid rgba(109,95,184,0.18);
  border-radius: 20px;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 18px 45px rgba(24,19,38,0.07);
  padding: 1.1rem;
}

.state-candidate-card img {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  object-fit: cover;
  background: #efe9ff;
  flex-shrink: 0;
}

.state-candidate-card h2 {
  margin: 0 0 0.25rem;
  font-size: 1.1rem;
  line-height: 1.15;
}

.state-candidate-card h2 a {
  color: var(--navy);
  text-decoration: none;
}

.state-candidate-card h2 a:hover {
  color: var(--accent-strong);
}

.state-candidate-meta {
  margin: 0 0 0.55rem;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 800;
}

.state-candidate-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.state-candidate-link {
  display: inline-block;
  margin-top: 0.75rem;
  color: var(--accent-strong);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.state-empty {
  grid-column: 1 / -1;
  color: var(--text-muted);
}

/* ── TABS ── */
.tab-bar { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin-bottom: 2rem; }
.tab {
  padding: 0.6rem 1.2rem; font-size: 0.82rem; font-weight: 500;
  cursor: pointer; color: var(--slate); border: none; background: none;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  transition: all 0.2s; font-family: "DM Sans", sans-serif;
}
.tab:hover { color: var(--text-primary); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }

@media (max-width: 640px) {
  .lookup-section {
    padding-top: 0.5rem;
  }

  .lookup-inner {
    padding: 0 1rem;
  }
  .home-lookup-box {
    text-align: center;
    padding: 0.9rem 0.65rem;
    width: 100%;
    max-width: 100%;
    border-radius: 14px;
  }
  .home-lookup-box .lookup-desc {
    margin-bottom: 0.85rem;
  }
  .home-lookup-box .api-note {
    margin-top: 1rem;
  }
  .lookup-promise-grid,
  .ballot-snapshot-grid {
    grid-template-columns: 1fr;
  }
  .home-lookup-box .lookup-form {
    align-items: stretch;
    justify-content: center;
    text-align: center;
  }
  .lookup-form {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 0.5rem;
  }
  .local-lookup-form {
    gap: 0.5rem;
  }
  .form-group {
    width: 100%;
    text-align: center;
  }
  .form-group-wide {
    min-width: 0;
    flex: 1 1 auto;
  }
  .form-group input {
    width: 100%;
    min-width: 0;
    text-align: center;
  }
  .lookup-btn {
    width: 100%;
    align-self: stretch;
  }
  #lookup-results {
    text-align: left;
    max-width: 100%;
    width: 100%;
    margin-top: 1rem;
  }
  body.has-results .home-lookup-box {
    padding: 0 !important;
  }
  body.has-results .home-lookup-form {
    margin-bottom: 1rem;
  }
  #lookup-results .live-results {
    padding: 1rem;
    border-radius: 12px;
  }
  #lookup-results .ballot-dashboard {
    padding: 0.95rem;
    border-radius: 12px;
    margin-bottom: 1rem;
  }
  #lookup-results .dashboard-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.55rem;
  }
  #lookup-results .dash-card {
    padding: 0.75rem;
  }
  #lookup-results .accordion-sim {
    border-radius: 10px;
    margin-bottom: 0.75rem !important;
  }
  #lookup-results .accordion-header {
    padding: 0.8rem;
  }
  #lookup-results .accordion-content {
    overflow: visible;
  }
  #lookup-results .no-election-status {
    grid-template-columns: 1fr;
    gap: 0.75rem;
    padding: 1rem;
  }
  #lookup-results .no-election-status-meta {
    min-width: 0;
    border-left: none;
    border-top: 1px solid var(--border);
    padding-left: 0;
    padding-top: 0.75rem;
  }
  #lookup-results .candidate-list {
    gap: 0.55rem;
  }
  #lookup-results .candidate-item {
    overflow: visible !important;
    border-radius: 10px !important;
    margin-bottom: 0.55rem !important;
  }
  #lookup-results .candidate-profile-panel {
    margin: 0.3rem 0.75rem 0.75rem !important;
    padding: 0.9rem !important;
  }
  .logo-img {
    width: min(56vw, 220px);
    max-width: calc(100vw - 8.5rem);
  }
    .candidate-profile-panel {
    margin-top: 0.55rem;
    padding: 0.65rem;
    border-radius: 0.65rem;
  }
  .candidate-profile-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.18rem;
    font-size: 0.78rem;
  }
  .candidate-profile-row strong {
    font-size: 0.72rem;
    text-align: left;
    overflow-wrap: anywhere;
  }
  .candidate-profile-row span {
    max-width: 100%;
    overflow-wrap: anywhere;
  }
  .candidate-profile-note,
  .candidate-profile-section {
    font-size: 0.78rem;
    line-height: 1.55;
  }
  .candidate-profile-priorities li {
    margin-bottom: 0.2rem;
  }
}

@media (max-width: 760px) {
  .guide-page .lookup-box .lookup-form {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
    align-items: stretch;
  }
  .guide-page .lookup-box .local-lookup-form {
    gap: 0.5rem;
  }

  .guide-page .lookup-box .form-group,
  .guide-page .lookup-box .form-group-wide {
    width: 100%;
    min-width: 0;
    flex: 1 1 auto;
    margin: 0;
  }
}

@media (max-width: 760px) {
  header {
    min-height: auto;
    padding: 5rem 1rem 1rem;
  }
  .balance-power-section {
    margin-top: 0;
    padding: 0;
  }
  .balance-power-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stat-box {
    padding: 1.2rem 1rem;
  }
  .balance-power-grid .stat-box {
    padding: 0.9rem 0.65rem;
  }
  .site-nav {
    top: 1.15rem;
    left: 1rem;
  }
  .menu-toggle {
    display: inline-flex;
  }
  .site-menu {
    display: none;
    position: fixed;
    top: 4.85rem;
    right: 1rem;
    left: 1rem;
    width: auto;
    z-index: 1000;
    max-width: none;
    grid-template-columns: 1fr;
    gap: 0.55rem;
    padding: 0.75rem;
    border: 1px solid rgba(24,19,38,0.16);
    border-radius: 18px;
    background: rgba(255,255,255,0.96);
    box-shadow: 0 22px 54px rgba(24, 19, 38, 0.18);
    backdrop-filter: blur(14px);
  }
  .site-menu.is-open {
    display: grid;
  }
  .site-menu a {
    justify-content: space-between;
    width: 100%;
    border-radius: 12px;
    background: rgba(244,240,255,0.78);
    padding: 0.78rem 0.9rem;
    font-size: 0.74rem;
  }
  .site-menu a::after {
    content: "→";
    color: var(--accent);
  }
  .guide-topbar {
    position: relative;
    align-items: center;
  }
  .guide-nav {
    display: none;
    position: fixed;
    top: 4.85rem;
    right: 1rem;
    left: 1rem;
    flex-direction: column;
    width: auto;
    z-index: 1000;
    gap: 0.55rem;
    padding: 0.75rem;
    border: 1px solid rgba(24,19,38,0.16);
    border-radius: 18px;
    background: rgba(255,255,255,0.96);
    box-shadow: 0 22px 54px rgba(24, 19, 38, 0.18);
    backdrop-filter: blur(14px);
    max-height: calc(100vh - 6rem);
    overflow-y: auto;
  }
  .guide-nav.is-open {
    display: flex;
  }
  .guide-nav a {
    width: 100%;
    border-radius: 12px;
    padding: 0.78rem 0.9rem;
    background: rgba(244,240,255,0.78);
  }
}

.race-badge {
  display: inline-block;
  font-size: 0.68rem; font-weight: 700;
  padding: 0.18rem 0.55rem;
  border-radius: 20px;
  margin-left: 0.5rem;
  vertical-align: middle;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.race-badge.open    { background: rgba(255,200,50,0.18);  color: #f5c842; border: 1px solid rgba(255,200,50,0.35); }
.race-badge.toss-up { background: rgba(255,120,60,0.18);  color: #ff9060; border: 1px solid rgba(255,120,60,0.35); }
.race-badge.safe    { background: rgba(80,200,120,0.15);  color: #60cc88; border: 1px solid rgba(80,200,120,0.3); }
.rep-district { font-size: 0.72rem; color: var(--accent); letter-spacing: 0.03em; margin-bottom: 0.3rem; }
.rep-note { font-size: 0.72rem; color: #f5c842; margin-top: 0.35rem; font-style: italic; }
.delegation-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.1rem 1.3rem;
  margin-top: 0.75rem;
}
.delegation-bar {
  height: 10px; border-radius: 5px;
  overflow: hidden; display: flex;
  margin: 0.6rem 0;
}
.delegation-bar .r-seg { background: rgba(77,61,121,0.78); }
.delegation-bar .d-seg { background: rgba(191,176,240,0.9); }
.delegation-stats { display: flex; gap: 1.5rem; font-size: 0.82rem; margin-top: 0.3rem; }
.delegation-stats .r-num { color: #4d3d79; font-weight: 700; }
.delegation-stats .d-num { color: #6d5fb8; font-weight: 700; }
.find-rep-btn {
  display: inline-block;
  margin-top: 0.9rem;
  padding: 0.55rem 1.2rem;
  background: rgba(109,95,184,0.14);
  border: 1px solid rgba(109,95,184,0.35);
  border-radius: 8px;
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s;
}
.find-rep-btn:hover { background: rgba(109,95,184,0.24); }
.primary-local-btn {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}
.primary-local-btn:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: var(--white);
}
.secondary-source-btn {
  opacity: 0.82;
}


.race2026-card {
  background: linear-gradient(135deg, rgba(109,95,184,0.1), rgba(0,0,0,0));
  border: 1px solid rgba(109,95,184,0.25);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 1rem 1.2rem;
  margin-top: 0.75rem;
}
.race2026-label {
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 0.5rem;
}
.race2026-note {
  font-size: 0.82rem; color: var(--text-muted);
  line-height: 1.5; margin-bottom: 0.75rem;
}
.race2026-open-badge {
  display: inline-block; font-size: 0.7rem; font-weight: 700;
  padding: 0.2rem 0.6rem; border-radius: 20px; margin-bottom: 0.6rem;
  background: rgba(255,200,50,0.15); color: #f5c842;
  border: 1px solid rgba(255,200,50,0.35); letter-spacing: 0.05em;
  text-transform: uppercase;
}
.cand-party-block { margin-top: 0.6rem; }
.cand-party-block .party-head {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.05em;
  text-transform: uppercase; margin-bottom: 0.25rem;
}
.cand-party-block.r-block .party-head { color: #4d3d79; }
.cand-party-block.d-block .party-head { color: #6d5fb8; }
.cand-list { list-style: none; padding: 0; margin: 0; }
.cand-list li { font-size: 0.83rem; color: var(--text-muted);
  padding: 0.18rem 0; border-bottom: 1px solid rgba(255,255,255,0.04); }
.cand-list li:last-child { border-bottom: none; }
.race2026-bp-link {
  display: inline-block; margin-top: 0.75rem; font-size: 0.8rem;
  color: var(--accent); text-decoration: none;
  padding: 0.35rem 0.85rem;
  background: rgba(109,95,184,0.1); border: 1px solid rgba(109,95,184,0.25);
  border-radius: 6px;
}
.race2026-bp-link:hover { background: rgba(109,95,184,0.18); }

@media (max-width: 760px) {
  .video-forward-section {
    padding: 0.9rem 1rem 1rem;
    margin: 0;
    width: 100%;
  }

  .video-filter-bar {
    grid-template-columns: 1fr;
  }

  .video-source-panel {
    grid-template-columns: 1fr;
  }

  .source-scan-btn {
    width: 100%;
  }

  .video-count {
    justify-self: start;
  }

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

  .followup-email-form {
    display: block;
  }

  .followup-email-form input[type="email"] {
    width: 100%;
  }

  .ballot-reminder-card .lookup-btn {
    width: 100%;
    text-align: center;
  }
}

/* =========================================
   NEW DASHBOARD & PROFILE UI INTEGRATION
   ========================================= */

    /* NEW UI TOKENS */
:root {
      --navy: #181326;
      --navy-card: #ffffff;
      --accent: #6d5fb8;
      --accent-strong: #4d3d79;
      --accent-glow: rgba(109,95,184,0.15);
      --slate: #615872;
      --text-primary: #181326;
      --text-muted: #4f465f;
      --border: rgba(24,19,38,0.12);
      --bg-color: #fbf9ff;
      --dem-gradient: linear-gradient(135deg, #3b82f6, #1e3a8a);
    }
    .ballot-guide-container { max-width: 760px; margin: 0 auto; }

    /* =========================================
       HEADER & LOCATION MODULE
       ========================================= */
    .page-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 2rem; padding-bottom: 1.5rem; border-bottom: 2px solid var(--border); flex-wrap: wrap; gap: 1rem; }
    .page-title { margin: 0 0 0.3rem 0; font-family: 'Playfair Display', serif; font-size: 2.8rem; color: var(--navy); line-height: 1; }
    .page-date { font-family: 'DM Mono', monospace; font-size: 0.85rem; color: var(--slate); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600; }
    
    .location-card { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 0.8rem 1.2rem; display: flex; flex-direction: column; align-items: flex-end; box-shadow: 0 4px 12px rgba(0,0,0,0.02); }
    .location-text { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.4rem; }
    .location-btn { background: var(--accent-glow); color: var(--accent-strong); border: 1px solid rgba(109,95,184,0.2); border-radius: 8px; padding: 0.5rem 1rem; font-weight: 700; font-family: 'DM Sans'; font-size: 0.8rem; cursor: pointer; transition: all 0.2s; }
    .location-btn:hover { background: rgba(109,95,184,0.25); transform: translateY(-1px); }

    /* =========================================
       1. BALLOT SUMMARY DASHBOARD
       ========================================= */
    .ballot-dashboard { background: #fff; border: 1px solid var(--border); border-radius: 16px; padding: 1.5rem; margin-bottom: 2.5rem; box-shadow: 0 12px 34px rgba(0,0,0,0.03); }
    .dashboard-title { font-family: "Playfair Display", serif; font-size: 1.4rem; font-weight: 900; color: var(--navy); margin-bottom: 1.2rem; }
    .dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 1rem; }
    .dash-card { background: var(--bg-color); border: 1px solid var(--border); border-radius: 10px; padding: 1.2rem 1rem; text-align: center; }
    .dash-card-link { display: block; text-decoration: none; color: inherit; transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease; }
    .dash-card-link:hover, .dash-card-link:focus-visible { transform: translateY(-2px); border-color: rgba(109,95,184,0.35); background: #fff; box-shadow: 0 12px 24px rgba(25, 35, 65, 0.08); outline: none; }
    .dash-card-disabled { opacity: 0.48; }
    .dash-val { font-size: 2.2rem; font-weight: 700; color: var(--accent-strong); line-height: 1; margin-bottom: 0.4rem; font-family: "Playfair Display", serif; }
    .dash-label { font-size: 0.8rem; font-weight: 600; color: var(--text-muted); line-height: 1.2; }

    /* =========================================
       2. RACE ACCORDION HEADER
       ========================================= */
    .accordion-sim { background: #ffffff; border: 1px solid var(--border); border-radius: 16px; overflow: hidden; box-shadow: 0 12px 34px rgba(0,0,0,0.03); margin-bottom: 1.5rem;}
    .accordion-header { background: #faf8ff; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; cursor: pointer; }
    .race-title-group { display: flex; flex-direction: column; gap: 0.3rem; }
    .race-title { font-weight: 700; font-size: 1.1rem; color: var(--navy); }
    .race-meta { font-family: "DM Mono", monospace; font-size: 0.7rem; color: var(--slate); text-transform: uppercase; font-weight: 500; letter-spacing: 0.03em; }
    .accordion-header span { color: var(--accent); font-family: "DM Mono", monospace; font-size: 0.8rem; }
    
    .accordion-content { padding: 0; }

    .no-election-status {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(10.75rem, max-content);
        gap: 1.25rem;
        align-items: start;
        padding: 1.05rem 1.2rem;
        background: #ffffff;
    }
    .no-election-status-copy {
        min-width: 0;
    }
    .no-election-status-title {
        font-size: 0.98rem;
        font-weight: 800;
        color: var(--navy);
        margin-bottom: 0.28rem;
    }
    .no-election-status-text {
        font-size: 0.84rem;
        line-height: 1.45;
        color: var(--text-muted);
    }
    .no-election-status-meta {
        min-width: 10.75rem;
        border-left: 1px solid var(--border);
        padding-left: 1rem;
        white-space: nowrap;
    }
    .no-election-status-label {
        font-family: "DM Mono", monospace;
        font-size: 0.66rem;
        letter-spacing: 0.11em;
        text-transform: uppercase;
        color: var(--accent);
        font-weight: 700;
        margin-bottom: 0.28rem;
        white-space: nowrap;
    }
    .no-election-status-year {
        font-size: 0.88rem;
        font-weight: 800;
        color: var(--navy);
        white-space: nowrap;
    }

    /* =========================================
       3. CANDIDATE PROFILE HEADER
       ========================================= */
    .profile-header { padding: 1rem 1.5rem 1rem 1rem; display: flex; align-items: center; gap: 1rem; }
    .avatar-wrapper { position: relative; width: 58px; height: 58px; flex-shrink: 0; }
    .avatar-img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; object-position: top; box-shadow: 0 4px 12px rgba(0,0,0,0.08); border: 2px solid #fff; display: block; }
    .avatar-fallback { position: absolute; inset: 0; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--accent-strong); font-family: "DM Mono", monospace; font-size: 1.1rem; font-weight: 700; background: #efe9ff; }
    .avatar-wrapper.has-image .avatar-fallback { display: none; }
    .avatar-wrapper.no-image .avatar-img { display: none; }
    .avatar-wrapper.no-image .avatar-fallback { display: flex; }

    .header-info { display: flex; flex-direction: column; gap: 0.2rem; flex: 1; }
    .cand-name { font-family: "Playfair Display", serif; font-size: 1.25rem; font-weight: 900; color: var(--navy); }
    
    .pill-group {
        display: inline-flex;
        gap: 6px;
        align-items: center;
        margin-top: 0.2rem;
        margin-bottom: 0.3rem;
    }
    .pill {
        font-family: "DM Mono", monospace;
        font-size: 0.65rem;
        font-weight: 700;
        letter-spacing: 0.5px;
        padding: 3px 8px;
        border-radius: 4px;
        text-transform: uppercase;
    }
    .pill.dem {
        background: rgba(30, 58, 138, 0.08);
        color: #1e3a8a;
        border: 1px solid rgba(30, 58, 138, 0.2);
    }
    .pill.rep {
        background: rgba(127, 29, 29, 0.08);
        color: #7f1d1d;
        border: 1px solid rgba(127, 29, 29, 0.2);
    }
    .pill.np {
        background: rgba(109, 95, 184, 0.08);
        color: var(--accent-strong);
        border: 1px solid rgba(109, 95, 184, 0.2);
    }
    .pill.status {
        background: #f8f9fa;
        color: var(--slate);
        border: 1px solid var(--border);
    }
    .pill.suspended {
        background: #fff;
        color: #b91c1c;
        border: 1.5px solid #dc2626;
        display: inline-flex;
        align-items: center;
        gap: 5px;
    }
    .suspended-dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #dc2626;
        display: inline-block;
        flex-shrink: 0;
    }

    .result-badge { display: inline-block; padding: 0.2rem 0.5rem; border-radius: 4px; font-family: "DM Mono", monospace; font-size: 0.65rem; font-weight: 700; text-transform: uppercase; margin-top: 0.4rem; border: 1px solid currentColor; align-self: flex-start; }
    .result-badge.active { background: #f0ebff; color: var(--accent-strong); border-color: rgba(109,95,184,0.3); }

    /* Modern Tabs */
    .tab-nav { display: flex; gap: 0.5rem; padding: 0 1.5rem; border-bottom: 1px solid var(--border); background: #faf8ff; overflow-x: auto; scrollbar-width: none; }
    .tab-nav::-webkit-scrollbar { display: none; }
    .tab-btn { background: transparent; border: none; padding: 0.8rem 0.5rem; margin-bottom: -1px; font-family: "DM Sans", sans-serif; font-size: 0.85rem; font-weight: 600; color: var(--slate); border-bottom: 2px solid transparent; cursor: pointer; transition: all 0.2s ease; display: flex; align-items: center; gap: 0.4rem; white-space: nowrap; }
    .tab-btn:hover { color: var(--accent); }
    .tab-btn.active { color: var(--accent-strong); border-bottom-color: var(--accent-strong); }
    .tab-btn svg { width: 14px; height: 14px; fill: currentColor; }

    /* Tab Content Area */
    .tab-content-container { position: relative; padding: 1.5rem 1.5rem 3.5rem; min-height: 300px; }
    .tab-pane { display: none; animation: fadeIn 0.3s ease forwards; }
    .tab-pane.active { display: block; }
    @keyframes fadeIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }

    /* Shared Tab Styles */
    .bio-text { font-size: 0.9rem; line-height: 1.6; color: var(--text-muted); margin-bottom: 1.5rem; }
    .contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.75rem; margin-bottom: 1rem; }
    .contact-item { background: #fbf9ff; border: 1px solid var(--border); border-radius: 8px; padding: 0.7rem; display: flex; align-items: center; gap: 0.5rem; }
    .contact-item svg { width: 14px; height: 14px; fill: var(--accent); flex-shrink: 0; }
    .contact-item a { color: var(--navy); text-decoration: none; font-size: 0.82rem; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .social-row { display: flex; gap: 0.5rem; margin-bottom: 1.5rem; }
    .social-btn { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: #f0ebff; color: var(--accent-strong); transition: all 0.2s; border: 1px solid rgba(109,95,184,0.15);}
    
    .section-label { font-family: "DM Mono", monospace; font-size: 0.7rem; color: var(--slate); text-transform: uppercase; margin-bottom: 0.75rem; border-bottom: 1px solid var(--border); padding-bottom: 0.2rem;}
    .priority-item { margin-bottom: 1rem; }
    .priority-tag { display: inline-block; background: rgba(109,95,184,0.1); color: var(--accent-strong); font-size: 0.7rem; font-weight: 700; padding: 0.2rem 0.5rem; border-radius: 6px; margin-bottom: 0.3rem; text-transform: uppercase; letter-spacing: 0.05em;}
    .priority-text { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }
    
    .vote-list { display: flex; flex-direction: column; gap: 0.8rem; margin-top: 1.5rem; }
    .vote-item { padding: 0.5rem 0; border-bottom: 1px solid var(--border); }
    .vote-item:last-child { border-bottom: none; }
    .vote-title { font-weight: 400; font-size: 0.95rem; margin-bottom: 0.3rem; display: flex; justify-content: space-between; align-items: flex-start;}
    .vote-badge { background: #f3f0e8; color: #5d4a1f; font-size: 0.65rem; padding: 0.2rem 0.5rem; border-radius: 4px; font-family: "DM Mono", monospace; text-transform: uppercase; font-weight: 400; flex-shrink: 0; margin-left: 0.5rem;}
    .vote-badge-yea { background: #e8f5e9; color: #1b5e20; }
    .vote-badge-nay { background: #fdeaea; color: #9f1d1d; }
    .vote-badge-neutral { background: #f3f0e8; color: #5d4a1f; }
    .vote-desc { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

    .finance-grid { display: grid; grid-template-columns: 1fr; gap: 1.2rem; }
    .metric-card { background: #fbf9ff; border: 1px solid var(--border); border-radius: 10px; padding: 1.5rem; text-align: center; }
    .metric-val { font-family: "Playfair Display", serif; font-size: 2.5rem; font-weight: 900; color: var(--navy); line-height: 1; margin-bottom: 0.4rem; }
    .metric-label { font-family: "DM Mono", monospace; font-size: 0.75rem; color: var(--slate); text-transform: uppercase; letter-spacing: 0.05em; }
    .donors-box { border: 1px solid var(--border); border-radius: 10px; padding: 1.2rem; }
    .donor-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
    .donor-tag { background: #fff; border: 1px solid var(--border); padding: 0.4rem 0.9rem; border-radius: 99px; font-size: 0.85rem; font-weight: 600; color: var(--text-muted); box-shadow: 0 2px 8px rgba(0,0,0,0.02);}

    /* Cohesive Candidate Detail Layout */
    .candidate-data-stream.clean-layout {
      display: grid;
      gap: 0.95rem;
      padding-top: 0.35rem;
    }
    .candidate-section {
      border: 1px solid var(--border);
      border-radius: 12px;
      background: #fff;
      padding: 0.95rem 1rem;
      box-shadow: 0 4px 12px rgba(24, 19, 38, 0.03);
    }
    .candidate-section-head {
      display: flex;
      align-items: center;
      gap: 0.5rem;
      font-family: "DM Mono", monospace;
      font-size: 0.72rem;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--slate);
      margin-bottom: 0.65rem;
    }
    .section-icon {
      width: 1.2rem;
      height: 1.2rem;
      border-radius: 50%;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 0.66rem;
      color: #fff;
      background: linear-gradient(135deg, #ca3b2f, #2d6fd1);
      box-shadow: 0 3px 8px rgba(45, 111, 209, 0.22);
      flex: 0 0 auto;
    }
    .contact-pill-row {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem;
      margin-top: 0.75rem;
    }
    .contact-pill {
      display: inline-flex;
      align-items: center;
      gap: 0.45rem;
      padding: 0.42rem 0.68rem;
      border-radius: 999px;
      border: 1px solid rgba(24, 19, 38, 0.14);
      background: #f7f8ff;
      color: var(--text-primary);
      font-size: 0.78rem;
      font-weight: 600;
      font-family: "DM Sans", sans-serif;
      letter-spacing: 0;
      text-decoration: none;
    }
    .contact-pill:hover {
      background: #eef2ff;
      border-color: rgba(45, 111, 209, 0.35);
    }
    .pill-ico {
      font-size: 0.7rem;
      opacity: 0.75;
    }
    .priority-list-clean {
      margin: 0;
      padding: 0;
      list-style: none;
      display: grid;
      gap: 0.55rem;
    }
    .priority-list-clean li {
      display: flex;
      align-items: flex-start;
      gap: 0.52rem;
      font-size: 0.86rem;
      color: var(--text-muted);
      line-height: 1.55;
    }
    .priority-dot {
      width: 0.85rem;
      height: 0.85rem;
      margin-top: 0.15rem;
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236d5fb8' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
      background-size: contain;
      background-repeat: no-repeat;
      background-position: center;
      flex: 0 0 auto;
    }
    .vote-list.clean {
      margin-top: 0;
    }
    .finance-kpi-row {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
      gap: 0.7rem;
      margin-bottom: 0.8rem;
    }
    .finance-kpi {
      border: 1px solid rgba(24, 19, 38, 0.12);
      border-radius: 10px;
      background: #f8f9ff;
      padding: 0.85rem 0.95rem;
      text-align: left;
    }
    .kpi-label {
      font-family: "DM Mono", monospace;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      font-size: 0.66rem;
      color: var(--slate);
      margin-bottom: 0.28rem;
    }
    .kpi-value {
      font-family: "Playfair Display", serif;
      font-size: 1.35rem;
      color: var(--text-primary);
      line-height: 1.1;
      font-weight: 800;
    }
    .donor-chip-grid {
      display: flex;
      flex-wrap: wrap;
      gap: 0.45rem;
    }
    .donor-chip {
      border: 1px solid rgba(24, 19, 38, 0.12);
      border-radius: 999px;
      padding: 0.35rem 0.7rem;
      font-size: 0.77rem;
      font-weight: 600;
      color: var(--text-muted);
      background: #fff;
    }
    .section-empty {
      font-size: 0.82rem;
      color: var(--text-muted);
      line-height: 1.5;
    }

    /* Compact Side-by-Side Layout */
    .compact-data-module {
      padding: 0;
    }
    .compact-module-title {
      font-family: "DM Mono", monospace;
      font-size: 0.7rem;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      color: var(--slate);
      border-bottom: 1px solid rgba(24,19,38,0.06);
      padding-bottom: 0.35rem;
      margin-bottom: 0.6rem;
      font-weight: 700;
    }
    .voting-record-module .compact-module-title {
      font-family: inherit;
      font-size: 0.86rem;
      font-weight: 400;
      text-transform: none;
      letter-spacing: 0;
      color: var(--text-muted);
    }
    .voting-record-module .vote-title {
      font-family: inherit;
      font-weight: 400;
      color: var(--text-muted);
    }
    .voting-record-module .vote-copy,
    .vote-list.clean .vote-copy {
      display: block;
      font-family: inherit;
      font-size: 0.85rem;
      font-weight: 400;
      line-height: 1.5;
      color: var(--text-muted);
      letter-spacing: 0;
    }
    .voting-record-module .vote-copy *,
    .vote-list.clean .vote-copy *,
    .voting-record-module .vote-title,
    .vote-list.clean .vote-title {
      font-weight: 400 !important;
    }
    .voting-record-module .vote-badge,
    .vote-list.clean .vote-badge {
      display: inline-flex;
      vertical-align: 0.08em;
      margin: 0 0 0 0.35rem;
      padding: 0.1rem 0.36rem;
      border-radius: 4px;
      font-size: 0.58rem;
      font-weight: 400;
      letter-spacing: 0.04em;
      line-height: 1.25;
    }



  

/* Premium Layout for Candidate Cards */
.premium-layout {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  padding: 1.2rem 0;
  background: transparent;
}
.premium-profile-header, .premium-section {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.02);
}
.premium-section-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: "Playfair Display", serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 1.2rem;
  border-bottom: 1px solid rgba(0,0,0,0.04);
  padding-bottom: 0.8rem;
}
.premium-icon {
  width: 24px;
  height: 24px;
  min-width: 24px;
  min-height: 24px;
  flex-shrink: 0;
  color: var(--accent);
}
.premium-contact-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.2rem;
}
.premium-contact-row .contact-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #fbf9ff;
  color: var(--accent-strong);
  border: 1px solid rgba(109, 95, 184, 0.2);
  padding: 0.5rem 1.2rem;
  border-radius: 30px;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: "DM Sans", sans-serif;
  letter-spacing: 0;
  text-decoration: none;
  transition: all 0.2s ease;
}
.premium-contact-row .contact-pill:hover {
  background: var(--accent);
  color: white;
}
.premium-finance-kpi {
  background: linear-gradient(135deg, #f8f6ff 0%, #ffffff 100%);
  border-left: 4px solid var(--accent);
  padding: 1.5rem;
  border-radius: 0 12px 12px 0;
  margin-bottom: 1.5rem;
  border-top: 1px solid var(--border);
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.premium-finance-kpi .kpi-label {
  font-family: "DM Mono", monospace;
  font-size: 0.75rem;
  color: var(--slate);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}
.premium-finance-kpi .kpi-value {
  font-family: "Playfair Display", serif;
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--navy);
  line-height: 1;
}

@media (max-width: 640px) {
  .ballot-guide-container,
  .accordion-sim,
  .accordion-content,
  .candidate-item,
  .profile-panel-wrap,
  .candidate-profile-panel,
  .tab-content-container,
  .tab-pane,
  .premium-layout,
  .premium-profile-header,
  .premium-section {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    overflow-wrap: anywhere;
  }

  .ballot-guide-container {
    padding-inline: 0;
  }

  .accordion-sim {
    border-radius: 14px;
    overflow: hidden;
  }

  .accordion-header {
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
  }

  .race-title-group,
  .header-info,
  .tab-pane,
  .candidate-data-stream,
  .candidate-section,
  .data-column,
  .compact-data-module,
  .contact-grid,
  .finance-grid,
  .finance-kpi-row,
  .vote-list,
  .donors-box {
    min-width: 0;
  }

  .profile-header {
    align-items: flex-start;
    gap: 0.65rem;
    padding: 0.75rem;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
  }

  .avatar-wrapper {
    width: 44px;
    height: 44px;
  }

  .cand-name {
    font-size: 1.08rem;
    line-height: 1.12;
    overflow-wrap: anywhere;
    white-space: normal;
  }

  .candidate-profile-trigger,
  .candidate-list,
  .profile-panel-wrap,
  .header-info,
  .candidate-data-stream,
  .data-column,
  .compact-data-module,
  .pill-group {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
  }

  .candidate-data-stream {
    padding: 0 0 1rem !important;
    overflow: visible;
  }

  .candidate-data-stream > div {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.85rem !important;
    padding: 0 0.35rem !important;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .data-column {
    display: grid;
    gap: 0.85rem;
  }

  .compact-data-module,
  .bio-text,
  .priority-list-clean,
  .vote-list,
  .vote-item,
  .vote-title,
  .vote-desc,
  .donor-chip-grid,
  .donor-chip,
  .premium-contact-row,
  .contact-pill {
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    overflow-wrap: anywhere;
    word-break: normal;
  }

  .priority-list-clean li {
    min-width: 0;
  }

  .header-info {
    overflow: visible;
  }

  .pill-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
  }

  .pill {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .cand-meta,
  .race-meta,
  .accordion-header span {
    font-size: 0.68rem;
    line-height: 1.35;
    white-space: normal;
  }

  .tab-nav {
    padding: 0 0.85rem;
    gap: 0.35rem;
  }

  .tab-btn {
    flex: 0 0 auto;
    font-size: 0.78rem;
    padding: 0.72rem 0.42rem;
  }

  .tab-content-container {
    padding: 1rem 0.9rem 1.35rem;
    min-height: 0;
  }

  .contact-grid,
  .finance-kpi-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact-item,
  .contact-pill,
  .premium-contact-row .contact-pill {
    max-width: 100%;
    min-width: 0;
  }

  .contact-item a,
  .contact-pill,
  .premium-contact-row .contact-pill {
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .candidate-section,
  .premium-profile-header,
  .premium-section,
  .premium-finance-kpi {
    padding: 1rem;
  }

  .metric-val,
  .premium-finance-kpi .kpi-value {
    font-size: clamp(1.55rem, 9vw, 2rem);
    overflow-wrap: anywhere;
  }

  .vote-title {
    display: block;
  }

  .vote-badge {
    display: inline-flex;
    margin: 0.35rem 0 0;
  }

  .state-candidate-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .state-candidate-card {
    align-items: flex-start;
    padding: 0.95rem;
  }

  .state-candidate-card img {
    width: 58px;
    height: 58px;
    border-radius: 16px;
  }
}

/* Clarity dead-click audit (Jul 2026): non-interactive sections must not invite clicks */
.guide-section,
.live-results,
.data-column {
  cursor: default;
}
/* Instant pressed feedback on candidate profile triggers */
.candidate-profile-trigger {
  transition: opacity 0.15s ease;
}
.candidate-profile-trigger.is-pressed {
  opacity: 0.55;
}
