/* ============================================================
 *  State Nomination v2 — Visual Upgrade
 *  Total overview + 8 state detail pages
 * ============================================================ */

/* ─── Overview Hero ────────────────────────────────────────── */
.state-nom-container {
  min-height: calc(100vh - 70px);
  background: var(--bg-page);
}

.sn-hero {
  position: relative;
  padding: 130px 0 80px;
  margin-top: -70px;
  background:
    radial-gradient(ellipse at top right, rgba(45, 140, 212, 0.2) 0%, transparent 55%),
    radial-gradient(ellipse at bottom left, rgba(232, 168, 56, 0.1) 0%, transparent 45%),
    linear-gradient(180deg, #0A2540 0%, #132F52 60%, #1A3A63 100%);
  color: #fff;
  overflow: hidden;
  text-align: center;
}
.sn-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at center top, black 25%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center top, black 25%, transparent 70%);
  pointer-events: none;
}
.sn-hero::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0; right: 0;
  height: 60px;
  background: var(--bg-page);
  clip-path: ellipse(65% 100% at 50% 100%);
  -webkit-clip-path: ellipse(65% 100% at 50% 100%);
}
.sn-hero .container { position: relative; z-index: 1; }

.sn-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(232, 168, 56, 0.12);
  border: 1px solid rgba(232, 168, 56, 0.25);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  color: #F5C76B;
  margin-bottom: 20px;
}
.sn-badge .dot {
  width: 6px; height: 6px;
  background: #E8A838;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(232, 168, 56, 0.2);
}

.sn-title {
  font-size: 44px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: #fff;
  margin-bottom: 16px;
}
.sn-title em {
  font-style: normal;
  background: linear-gradient(135deg, #F5C76B 0%, #E8A838 50%, #F5D28A 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.sn-subtitle {
  font-size: 18px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.68);
  max-width: 640px;
  margin: 0 auto 32px;
}

.sn-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: 700px;
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.sn-stat { text-align: center; }
.sn-stat .num {
  font-size: 30px;
  font-weight: 800;
  color: #fff;
  line-height: 1;
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}
.sn-stat .num span { color: #E8A838; font-size: 22px; }
.sn-stat .label {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}

/* ─── Section structure ────────────────────────────────────── */
.sn-section {
  padding: 64px 0;
}
.sn-section-header {
  text-align: center;
  margin-bottom: 40px;
}
.sn-section-eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: #E8A838;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.sn-section-title {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.sn-section-desc {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ─── State Cards Grid ─────────────────────────────────────── */
.state-cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: 1240px;
  margin: 0 auto;
}

.state-card {
  position: relative;
  display: block;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  padding: 24px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
}
.state-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: 0 16px 40px rgba(10, 37, 64, 0.10), 0 4px 12px rgba(10, 37, 64, 0.06);
}
.state-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--state-accent, linear-gradient(90deg, #1D6FB8, #2D8CD4));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.state-card:hover::before { transform: scaleX(1); }

.state-card__flag {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  background: var(--state-bg, linear-gradient(135deg, #1D6FB8, #2D8CD4));
  margin-bottom: 14px;
  box-shadow: 0 4px 12px rgba(29, 111, 184, 0.25);
}
.state-card__name {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.state-card__capital {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 14px;
}
.state-card__meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
}
.state-card__meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}
.state-card__meta-label { color: var(--text-muted); }
.state-card__meta-value {
  font-weight: 600;
  color: var(--text-secondary);
}
.state-card__arrow {
  position: absolute;
  bottom: 20px;
  right: 20px;
  color: var(--text-light);
  transition: all 0.2s ease;
}
.state-card:hover .state-card__arrow {
  color: var(--color-gold-500);
  transform: translateX(3px);
}

/* ─── Comparison Table ─────────────────────────────────────── */
.sn-compare-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  max-width: 1240px;
  margin: 0 auto;
}
.sn-compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.sn-compare-table th {
  background: var(--bg-soft);
  padding: 14px 16px;
  font-weight: 600;
  color: var(--text-primary);
  text-align: left;
  border-bottom: 1px solid var(--border-default);
  position: sticky;
  top: 70px;
  z-index: 2;
}
.sn-compare-table th:first-child {
  position: sticky;
  left: 0;
  z-index: 3;
  background: var(--bg-soft);
}
.sn-compare-table td {
  padding: 12px 16px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
}
.sn-compare-table td:first-child {
  position: sticky;
  left: 0;
  background: var(--bg-card);
  font-weight: 600;
  color: var(--text-primary);
  z-index: 1;
}
.sn-compare-table tr:last-child td { border-bottom: none; }
.sn-compare-table tr:hover td { background: var(--bg-card-hover); }

.state-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  background: var(--color-green-100);
  color: var(--color-green-600);
}
.state-chip--amber {
  background: var(--color-amber-100);
  color: var(--color-amber-600);
}
.state-chip--red {
  background: var(--color-red-100);
  color: var(--color-red-600);
}

/* ─── 190 vs 491 ──────────────────────────────────────────── */
.sn-vs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 1000px;
  margin: 0 auto;
}
.sn-vs-card {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: 18px;
  padding: 32px;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}
.sn-vs-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 6px;
  background: var(--vs-color, linear-gradient(90deg, #1D6FB8, #2D8CD4));
}
.sn-vs-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.sn-vs-badge {
  display: inline-block;
  padding: 4px 12px;
  background: var(--color-blue-50);
  color: var(--color-blue-600);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}
.sn-vs-card h3 {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.sn-vs-sub {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 24px;
}
.sn-vs-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sn-vs-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}
.sn-vs-list li::before {
  content: '';
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  background: var(--color-green-100);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232E7D5B' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-size: 12px 12px;
  background-repeat: no-repeat;
  background-position: center;
}

/* ─── Timeline (process) ───────────────────────────────────── */
.sn-timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px 0;
}
.sn-timeline::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  left: 28px;
  width: 2px;
  background: var(--border-default);
}
.sn-timeline-item {
  position: relative;
  display: flex;
  gap: 24px;
  padding: 16px 0;
  padding-left: 72px;
}
.sn-timeline-item__dot {
  position: absolute;
  left: 20px;
  top: 22px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--color-gold-500);
  border: 3px solid var(--bg-page);
  box-shadow: 0 0 0 2px var(--color-gold-500);
}
.sn-timeline-item__step {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-gold-600);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.sn-timeline-item h4 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}
.sn-timeline-item p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0;
}
.sn-timeline-item__duration {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 3px 10px;
  background: var(--bg-soft);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* ─── State Detail Hero ────────────────────────────────────── */
.sd-hero {
  position: relative;
  padding: 130px 0 64px;
  margin-top: -70px;
  color: #fff;
  overflow: hidden;
}
.sd-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 30% top, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 30% top, black 20%, transparent 70%);
  pointer-events: none;
}
.sd-hero::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0; right: 0;
  height: 50px;
  background: var(--bg-page);
  clip-path: ellipse(70% 100% at 50% 100%);
  -webkit-clip-path: ellipse(70% 100% at 50% 100%);
}
.sd-hero .container { position: relative; z-index: 1; }

.sd-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 24px;
}
.sd-breadcrumb a { color: rgba(255, 255, 255, 0.75); }
.sd-breadcrumb a:hover { color: #fff; }
.sd-breadcrumb .sep { color: rgba(255, 255, 255, 0.3); }

.sd-header-row {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
}
.sd-flag {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 800;
  color: #fff;
  background: var(--state-bg, linear-gradient(135deg, #1D6FB8, #2D8CD4));
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  flex-shrink: 0;
}
.sd-title-block { flex: 1; min-width: 280px; }
.sd-title {
  font-size: 42px;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 8px;
}
.sd-subtitle {
  font-size: 17px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 20px;
}
.sd-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.sd-tag {
  padding: 5px 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
}

.sd-info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 20px 0 0;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.sd-info-card {
  padding: 12px 0;
}
.sd-info-card .label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 4px;
}
.sd-info-card .value {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
}

/* ─── State content sections ──────────────────────────────── */
.sd-content {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 20px;
}
.sd-section {
  margin-bottom: 48px;
}
.sd-section h2 {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border-subtle);
}
.sd-section h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 24px 0 12px;
}
.sd-section p {
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 14px;
}
.sd-section ul, .sd-section ol {
  color: var(--text-secondary);
  line-height: 1.7;
  padding-left: 24px;
  margin-bottom: 14px;
}
.sd-section li { margin-bottom: 6px; }

/* Pros / Cons */
.sd-proscons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 24px 0;
}
.sd-proscons__col {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: 14px;
  padding: 24px;
}
.sd-proscons__col h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-primary);
}
.sd-proscons__col.pros h4 { color: var(--color-green-600); }
.sd-proscons__col.cons h4 { color: var(--color-red-600); }
.sd-proscons__col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.sd-proscons__col li {
  position: relative;
  padding: 8px 0 8px 28px;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
  border-bottom: 1px solid var(--border-subtle);
}
.sd-proscons__col li:last-child { border-bottom: none; }
.sd-proscons__col li::before {
  position: absolute;
  left: 0; top: 10px;
  width: 18px; height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
}
.sd-proscons__col.pros li::before {
  content: '+';
  background: var(--color-green-500);
}
.sd-proscons__col.cons li::before {
  content: '−';
  background: var(--color-red-500);
}

/* ─── Dark mode ────────────────────────────────────────────── */
html[data-theme="dark"] .sn-hero {
  background:
    radial-gradient(ellipse at top right, rgba(45, 140, 212, 0.12) 0%, transparent 55%),
    radial-gradient(ellipse at bottom left, rgba(232, 168, 56, 0.06) 0%, transparent 45%),
    linear-gradient(180deg, #051830 0%, #0A2540 60%, #132F52 100%);
}
html[data-theme="dark"] .sd-hero::after,
html[data-theme="dark"] .sn-hero::after {
  background: var(--bg-page);
}
html[data-theme="dark"] .sn-compare-table th,
html[data-theme="dark"] .sn-compare-table td:first-child {
  background: var(--bg-card);
}
html[data-theme="dark"] .sn-timeline::before {
  background: var(--border-default);
}
html[data-theme="dark"] .sn-timeline-item__dot {
  border-color: var(--bg-page);
}

/* ─── Responsive ───────────────────────────────────────────── */
@media (max-width: 1024px) {
  .state-cards-grid { grid-template-columns: repeat(2, 1fr); }
  .sn-stats { grid-template-columns: repeat(2, 1fr); }
  .sd-info-grid { grid-template-columns: repeat(2, 1fr); }
  .sn-vs-grid { grid-template-columns: 1fr; }
  .sd-proscons { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .sn-hero { padding: 110px 0 60px; }
  .sn-title { font-size: 32px; }
  .sn-subtitle { font-size: 15px; }
  .sn-stats { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .sn-stat .num { font-size: 24px; }
  .state-cards-grid { grid-template-columns: 1fr; }
  .sn-section { padding: 48px 0; }
  .sn-section-title { font-size: 26px; }
  .sd-title { font-size: 30px; }
  .sd-flag { width: 52px; height: 52px; font-size: 22px; border-radius: 12px; }
  .sd-info-grid { grid-template-columns: repeat(2, 1fr); }
  .sd-content { padding: 32px 0; }
  .sd-section h2 { font-size: 22px; }
  .sn-compare-wrap { overflow-x: auto; }
}

/* ─── Print ────────────────────────────────────────────────── */
@media print {
  .sn-hero, .sd-hero { background: #fff !important; color: #000 !important; }
  .sn-hero *, .sd-hero * { color: #000 !important; }
  .sn-hero::before, .sd-hero::before,
  .sn-hero::after, .sd-hero::after { display: none; }
  .state-card { break-inside: avoid; }
}
