:root {
  color-scheme: dark;
  --bg: #081018;
  --bg-elevated: #0f1824;
  --panel: rgba(15, 24, 36, 0.88);
  --panel-strong: rgba(17, 24, 39, 0.96);
  --panel-border: rgba(229, 231, 235, 0.1);
  --text: #f8fafc;
  --text-strong: #ffffff;
  --muted: #cbd5e1;
  --muted-strong: #e2e8f0;
  --primary: #2c98e3;
  --primary-hover: #1f86cd;
  --primary-light: rgba(44, 152, 227, 0.14);
  --success: #0b8043;
  --warning: #e37400;
  --danger: #cc0000;
  --neutral-900: #111827;
  --neutral-600: #4b5563;
  --neutral-400: #9ca3af;
  --neutral-200: #e5e7eb;
  --neutral-100: #f3f4f6;
  --white: #ffffff;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-pill: 9999px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 5;
  padding: 10px 14px;
  border-radius: var(--radius-pill);
  background: var(--white);
  color: var(--neutral-900);
  text-decoration: none;
  font-weight: 700;
}

.skip-link:focus {
  top: 16px;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: 'IBM Plex Sans', sans-serif;
  background:
    radial-gradient(circle at top left, rgba(44, 152, 227, 0.18), transparent 28%),
    radial-gradient(circle at top right, rgba(11, 128, 67, 0.14), transparent 24%),
    linear-gradient(180deg, #081018 0%, #0d1622 48%, #111c2b 100%);
  color: var(--text);
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    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: 72px 72px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 92%);
  opacity: 0.36;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.12;
  background-image: radial-gradient(rgba(255, 255, 255, 0.3) 0.7px, transparent 0.9px);
  background-size: 18px 18px;
}

a {
  color: var(--text-strong);
}

a:hover {
  color: var(--white);
}

.site-header,
main,
.site-footer {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) auto auto;
  gap: var(--space-lg);
  align-items: center;
  padding: var(--space-lg) 0 var(--space-md);
}

.brand-lockup {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-md);
  align-items: center;
  text-decoration: none;
  color: inherit;
}

.brand-mark {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-lg);
  display: grid;
  place-items: center;
  font-family: 'Sora', sans-serif;
  font-weight: 800;
  background: linear-gradient(145deg, var(--primary), #7ed0ff);
  color: var(--white);
  box-shadow: 0 20px 40px rgba(44, 152, 227, 0.24);
}

.eyebrow,
.section-kicker,
.section-meta,
.stat-label {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 12px;
  line-height: 1.2;
  color: #d7e3f2;
}

.site-header h1,
.hero h2,
.panel h2,
.route-card h3,
.column h3 {
  margin: 0;
  font-family: 'Sora', sans-serif;
  line-height: 1.08;
  color: var(--text-strong);
}

.site-header h1 {
  font-size: clamp(30px, 4.6vw, 56px);
  max-width: 11ch;
}

.hero h2,
.panel h2 {
  font-size: clamp(30px, 4vw, 44px);
}

.section-head h2,
.route-title,
.route-card h3,
.column h3 {
  font-size: 20px;
}

.top-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-sm);
}

.top-nav a,
.header-link,
.ghost-link,
.cta-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 var(--space-md);
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: background 140ms ease, border-color 140ms ease, transform 140ms ease, color 140ms ease;
}

.top-nav a {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted-strong);
  font-size: 14px;
  font-weight: 500;
}

.top-nav a:hover,
.top-nav a.active {
  background: var(--primary-light);
  border-color: rgba(44, 152, 227, 0.45);
  color: var(--white);
  transform: translateY(-1px);
}

.header-link {
  border: 1px solid rgba(44, 152, 227, 0.42);
  background: rgba(44, 152, 227, 0.12);
  color: var(--white);
  font-weight: 600;
}

.header-link:hover,
.cta-link:hover,
.ghost-link:hover {
  transform: translateY(-1px);
}

.ghost-link {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted-strong);
}

.cta-link {
  border: 1px solid rgba(44, 152, 227, 0.4);
  background: linear-gradient(135deg, rgba(44, 152, 227, 0.22), rgba(126, 208, 255, 0.16));
  color: var(--white);
  font-weight: 600;
}

main {
  display: grid;
  gap: var(--space-lg);
  padding-bottom: var(--space-2xl);
}

.results-insights {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-lg);
}

.insight-panel {
  padding: clamp(20px, 3vw, 28px);
}

.results-meta-grid,
.monitoring-list {
  display: grid;
  gap: var(--space-md);
}

.results-meta-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.meta-stat-card p,
.monitoring-card p,
.supporting-copy {
  color: var(--muted-strong);
}

.supporting-copy {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

.state-card-topline,
.state-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.state-meta-row {
  margin: var(--space-sm) 0;
}

.confidence-pill,
.meta-chip {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
}

.confidence-high {
  background: rgba(11, 128, 67, 0.18);
  border: 1px solid rgba(63, 206, 163, 0.34);
  color: #c8ffe7;
}

.confidence-medium {
  background: rgba(227, 116, 0, 0.16);
  border: 1px solid rgba(255, 190, 0, 0.3);
  color: #ffe4b0;
}

.meta-chip {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted-strong);
}

.threshold-meter {
  width: 100%;
  height: 10px;
  margin: var(--space-md) 0;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.threshold-meter-fill {
  height: 100%;
  border-radius: inherit;
}

.threshold-meter-fill.accent {
  background: linear-gradient(90deg, #2c98e3, #7ed0ff);
}

.threshold-meter-fill.warn {
  background: linear-gradient(90deg, #e37400, #ffbe00);
}

.threshold-meter-fill.quiet {
  background: linear-gradient(90deg, #64748b, #94a3b8);
}

.compact-head {
  margin-bottom: var(--space-md);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(20px);
}

.route-notice {
  padding: 14px var(--space-md);
  border-radius: var(--radius-md);
  border: 1px solid rgba(44, 152, 227, 0.25);
  background: rgba(44, 152, 227, 0.12);
  color: #ddecfa;
}

.hero {
  padding: clamp(24px, 4vw, 40px);
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.92fr);
  gap: var(--space-lg);
}

.lede,
#taxabilityCopy p,
.faq-list li,
.site-footer p,
.route-card p,
.route-lede,
.state-card p {
  color: var(--muted-strong);
  line-height: 1.6;
}

.lede {
  max-width: 64ch;
  font-size: 16px;
}

.hero-pills {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
}

.hero-pills span,
.badge {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: var(--radius-pill);
  background: rgba(44, 152, 227, 0.1);
  border: 1px solid rgba(44, 152, 227, 0.2);
  color: var(--white);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
}

.hero-card,
.route-card,
.state-card,
.column,
.toggle,
.form-summary {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow-md);
}

.hero-card {
  padding: var(--space-lg);
  border-radius: var(--radius-lg);
}

.stat-grid {
  display: grid;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
}

.stat-grid div {
  padding: var(--space-md);
  border-radius: var(--radius-md);
  background: rgba(8, 16, 24, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.stat-grid strong {
  display: block;
  margin-bottom: var(--space-xs);
  color: var(--white);
}

.stat-grid span {
  color: var(--muted);
  font-size: 14px;
}

.calculator-shell,
.results,
.panel.info-card,
.route-shell {
  padding: var(--space-lg);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.calculator-grid,
.board,
.briefing-grid,
.content-grid,
.route-grid {
  display: grid;
  gap: var(--space-md);
}

.calculator-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

label {
  display: grid;
  gap: var(--space-sm);
  color: var(--text-strong);
  font-size: 16px;
  font-weight: 600;
}

label input,
label select {
  width: 100%;
  min-height: 54px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(8, 16, 24, 0.92);
  color: var(--white);
  padding: 0 14px;
  font-size: 16px;
  transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

label input::placeholder {
  color: var(--neutral-400);
}

label input:focus,
label select:focus,
button:focus,
.header-link:focus,
.cta-link:focus,
.ghost-link:focus,
.top-nav a:focus,
.brand-lockup:focus {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
}

label input:focus,
label select:focus {
  border-color: rgba(44, 152, 227, 0.48);
  box-shadow: 0 0 0 3px rgba(44, 152, 227, 0.12);
}

.field-hint,
.section-meta,
.route-notice,
.route-card p,
.route-lede,
.site-footer p {
  font-size: 14px;
}

.field-hint {
  color: #c9d7e8;
  font-weight: 500;
}

.field-error {
  color: #ffd7cf;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}

.has-error input,
.has-error select {
  border-color: rgba(204, 0, 0, 0.72);
  box-shadow: 0 0 0 1px rgba(204, 0, 0, 0.16);
}

.wide {
  grid-column: 1 / -1;
}

.toggle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-sm);
}

.toggle {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted-strong);
}

.toggle input {
  width: 24px;
  height: 24px;
  margin: 0;
  flex: 0 0 24px;
  accent-color: var(--primary);
}

.form-summary {
  padding: 14px 16px;
  border-radius: var(--radius-md);
  color: var(--muted-strong);
  line-height: 1.5;
}

.form-summary.has-error {
  border-color: rgba(227, 116, 0, 0.42);
  background: rgba(227, 116, 0, 0.12);
  color: #ffe3c2;
}

button {
  min-height: 56px;
  border: 0;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 700;
  color: var(--white);
  background: linear-gradient(135deg, var(--primary), #63bef7);
  box-shadow: 0 18px 36px rgba(44, 152, 227, 0.24);
  cursor: pointer;
  transition: transform 150ms ease, filter 150ms ease, opacity 150ms ease;
}

button:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.04);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  box-shadow: none;
}

.hidden {
  display: none !important;
}

.board {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.column {
  padding: 18px;
  border-radius: var(--radius-lg);
}

.column.quiet {
  border-color: rgba(156, 163, 175, 0.24);
}

.column.warn {
  border-color: rgba(227, 116, 0, 0.28);
}

.column.accent {
  border-color: rgba(11, 128, 67, 0.28);
}

.column.quiet h3 {
  color: var(--neutral-100);
}

.column.warn h3 {
  color: #ffd4aa;
}

.column.accent h3 {
  color: #c9f5db;
}

.state-card {
  padding: 14px;
  border-radius: var(--radius-md);
  margin-bottom: 12px;
}

.state-card:last-child {
  margin-bottom: 0;
}

.state-card strong {
  display: block;
  margin-bottom: var(--space-sm);
  color: var(--white);
}

.briefing-grid,
.content-grid,
.route-grid,
.export-summary-grid,
.export-brief-body {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-lg);
}

.next-steps {
  padding-left: 20px;
  line-height: 1.7;
  color: var(--white);
}

.route-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
}

.route-card {
  padding: 20px;
  border-radius: var(--radius-lg);
}

.route-card h3 {
  margin-bottom: var(--space-sm);
}

.export-brief {
  padding: 20px;
  margin-bottom: var(--space-lg);
  background: linear-gradient(180deg, rgba(44, 152, 227, 0.08), rgba(8, 16, 24, 0.9));
}

.export-brief-head {
  display: flex;
  justify-content: space-between;
  gap: var(--space-md);
  align-items: end;
  margin-bottom: var(--space-md);
}

.export-brief-head h3,
.export-body-card h3,
.export-stat-card strong {
  margin: 0;
  font-family: 'Sora', sans-serif;
  color: var(--text-strong);
}

.export-stat-card {
  display: grid;
  gap: 10px;
  align-content: start;
}

.export-stat-card strong {
  font-size: clamp(28px, 4vw, 42px);
}

.export-body-card {
  display: grid;
  gap: 12px;
}

.export-body-card .faq-list {
  margin: 0;
}

.export-actions {
  margin-top: var(--space-lg);
}

.faq-list {
  padding-left: 18px;
  margin: 0;
}

.site-footer {
  padding: 0 0 var(--space-2xl);
  display: flex;
  justify-content: space-between;
  gap: var(--space-lg);
}

@media (max-width: 1080px) {
  .site-header {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .top-nav {
    justify-content: flex-start;
  }
}

@media (max-width: 960px) {
  .hero,
  .content-grid,
  .briefing-grid,
  .board,
  .calculator-grid,
  .toggle-grid,
  .route-grid,
  .export-summary-grid,
  .export-brief-body,
  .results-insights,
  .results-meta-grid,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .section-head,
  .site-footer {
    display: grid;
  }
}

@media (max-width: 640px) {
  body {
    padding-bottom: 156px;
  }

  .site-header,
  main,
  .site-footer {
    width: min(100% - 20px, 1180px);
  }

  .site-header {
    gap: 14px;
    padding-top: 20px;
    margin-top: 90px;
  }

  .brand-lockup {
    grid-template-columns: 1fr;
    justify-items: start;
    gap: 12px;
  }

  .brand-mark {
    width: 48px;
    height: 48px;
  }

  .hero,
  .calculator-shell,
  .results,
  .results-insights .panel,
  .panel.info-card,
  .briefing-grid .panel,
  .route-shell,
  .export-brief {
    padding: 18px;
  }

  .site-header h1 {
    max-width: none;
    font-size: 32px;
  }

  .hero h2,
  .panel h2 {
    font-size: 30px;
  }

  .top-nav {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 12px;
    z-index: 20;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding: 10px;
    border-radius: 22px;
    background: rgba(8, 16, 24, 0.94);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 24px 42px rgba(0, 0, 0, 0.38);
    backdrop-filter: blur(16px);
  }

  .top-nav a {
    min-height: 56px;
    padding: 12px 8px;
    justify-content: center;
    text-align: center;
    font-size: 13px;
    line-height: 1.2;
  }

  .header-link {
    position: sticky;
    bottom: 104px;
    z-index: 10;
    width: 100%;
    justify-self: stretch;
    box-shadow: 0 18px 36px rgba(44, 152, 227, 0.2);
  }

  .toggle {
    align-items: flex-start;
    min-height: 72px;
    padding: 16px;
  }

  .toggle input {
    width: 26px;
    height: 26px;
    flex-basis: 26px;
    margin-top: 2px;
  }

  button,
  .cta-link,
  .ghost-link {
    width: 100%;
  }

  #calculateButton {
    position: sticky;
    bottom: 32px;
    z-index: 9;
  }
}

::selection {
  background: rgba(44, 152, 227, 0.34);
  color: var(--white);
}


body.page-enter .panel,
body.page-enter .route-notice,
body.page-enter .site-header,
body.page-enter .site-footer {
  animation: rise-in 220ms ease both;
}

#calculateButton {
  position: relative;
  overflow: hidden;
  gap: 10px;
}

#calculateButton .button-label,
#calculateButton .button-status {
  position: relative;
  z-index: 1;
}

#calculateButton .button-status {
  min-width: 1ch;
  font-weight: 700;
}

#calculateButton[data-state="loading"] {
  pointer-events: none;
}

#calculateButton[data-state="loading"] .button-status {
  animation: pulse-dots 900ms ease infinite;
}

#calculateButton[data-state="success"] {
  background: linear-gradient(135deg, rgba(11, 128, 67, 0.95), rgba(34, 197, 94, 0.78));
  border-color: rgba(134, 239, 172, 0.45);
}

.panel-enter {
  animation: panel-enter 260ms cubic-bezier(.22,1,.36,1);
}

.toast-stack {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 20;
  display: grid;
  gap: 12px;
  pointer-events: none;
}

.toast {
  width: min(320px, calc(100vw - 32px));
  padding: 16px 18px;
  border-radius: 16px;
  border: 1px solid rgba(126, 208, 255, 0.32);
  background: rgba(8, 16, 24, 0.94);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(18px);
  transform: translateY(-12px);
  opacity: 0;
  transition: transform 180ms ease, opacity 180ms ease;
}

.toast.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.toast strong {
  display: block;
  margin-bottom: 6px;
  font-family: 'Sora', sans-serif;
  font-size: 14px;
}

.toast p {
  margin: 0;
  color: var(--muted-strong);
  line-height: 1.5;
}

.toast-progress {
  display: block;
  margin-top: 12px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(126, 208, 255, 0.95), rgba(44, 152, 227, 0.25));
  transform-origin: left center;
  animation: toast-timer 3s linear forwards;
}

.route-card,
.state-card,
.hero-card,
.info-card,
.toggle,
.header-link,
.ghost-link,
.cta-link,
.top-nav a,
button {
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease, background 160ms ease, color 160ms ease, opacity 160ms ease;
}

.route-card:hover,
.state-card:hover,
.hero-card:hover,
.info-card:hover,
.toggle:hover,
.state-card:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.24);
}

.state-card {
  animation: stagger-in 240ms ease both;
}

.state-card:focus-visible {
  outline: 2px solid rgba(126, 208, 255, 0.72);
  outline-offset: 2px;
}

.state-card:nth-child(2) { animation-delay: 40ms; }
.state-card:nth-child(3) { animation-delay: 80ms; }
.state-card:nth-child(4) { animation-delay: 120ms; }
.state-card:nth-child(5) { animation-delay: 160ms; }

::selection {
  background: rgba(126, 208, 255, 0.28);
  color: var(--white);
}

::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.03);
}

::-webkit-scrollbar-thumb {
  background: rgba(126, 208, 255, 0.28);
  border-radius: 999px;
  border: 2px solid rgba(8, 16, 24, 0.85);
}

@keyframes rise-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes panel-enter {
  from { opacity: 0; transform: translateY(16px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes stagger-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse-dots {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}

@keyframes toast-timer {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

.offline-banner {
  position: sticky;
  top: 14px;
  z-index: 40;
  width: min(1180px, calc(100% - 32px));
  margin: 16px auto 0;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(227, 116, 0, 0.38);
  background: rgba(55, 30, 8, 0.92);
  color: #ffe8c2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: 0 18px 40px rgba(0,0,0,0.28);
  backdrop-filter: blur(18px);
}

.banner-button {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.06);
  color: var(--white);
  font-weight: 600;
  box-shadow: none;
}

.state-panel {
  min-height: 260px;
}

.state-empty {
  display: grid;
  gap: 14px;
  align-content: center;
  min-height: 100%;
}

.state-empty-subpage {
  min-height: 320px;
}

.state-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 22px;
  background: rgba(44, 152, 227, 0.12);
  border: 1px solid rgba(44, 152, 227, 0.24);
  color: #dff3ff;
}

.state-empty h2 {
  margin: 0;
}

.state-empty p:not(.section-kicker) {
  margin: 0;
  color: var(--muted-strong);
  line-height: 1.6;
  max-width: 62ch;
}

.state-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.loading-shell {
  display: grid;
  gap: 18px;
}

.loading-board .column {
  min-height: 210px;
}

.skeleton-summary,
.skeleton-line,
.skeleton-card {
  border-radius: 14px;
  background: rgba(255,255,255,0.06);
  position: relative;
  overflow: hidden;
}

.skeleton-summary {
  height: 28px;
  width: min(460px, 100%);
}

.skeleton-title {
  height: 18px;
  width: 52%;
  margin-bottom: 16px;
}

.skeleton-card {
  height: 72px;
  margin-bottom: 12px;
}

.shimmer::after {
  content: '';
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.14), transparent);
  animation: shimmer 1.2s infinite;
}

.toast-success {
  border-color: rgba(52, 211, 153, 0.28);
}

.toast-warning {
  border-color: rgba(251, 191, 36, 0.28);
}

body.is-offline .cta-link {
  border-color: rgba(251, 191, 36, 0.35);
}

@keyframes shimmer {
  100% { transform: translateX(100%); }
}

@media (max-width: 640px) {
  .offline-banner {
    width: min(100% - 20px, 1180px);
    grid-template-columns: 1fr;
    display: grid;
  }

  .state-actions,
  .banner-button {
    width: 100%;
  }
}

/* ========== EASTER EGGS (Hour 16) ========== */

/* EE-1: Konami rain */
.ee-rain {
  position: fixed;
  top: -40px;
  color: #2563eb;
  font-weight: 700;
  font-family: var(--font-mono, monospace);
  opacity: 0.7;
  pointer-events: none;
  z-index: 9999;
  animation: ee-fall 3s linear forwards;
}
@keyframes ee-fall {
  0% { transform: translateY(0) rotate(0deg); opacity: 0.8; }
  100% { transform: translateY(110vh) rotate(360deg); opacity: 0; }
}

/* EE-2: Delaware flip */
.ee-flip {
  animation: ee-card-flip 0.6s ease forwards;
  position: relative;
}
@keyframes ee-card-flip {
  0% { transform: perspective(400px) rotateY(0deg); }
  50% { transform: perspective(400px) rotateY(90deg); }
  100% { transform: perspective(400px) rotateY(0deg); }
}
.ee-flip-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-card, #fff);
  border-radius: inherit;
  font-size: 1.1rem;
  font-weight: 600;
  color: #059669;
  z-index: 2;
}

/* EE-3: Midnight badge */
.ee-midnight-badge {
  position: fixed;
  top: 16px;
  right: 16px;
  background: #1e1b4b;
  color: #e0e7ff;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  z-index: 9999;
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity 0.5s, transform 0.5s;
  pointer-events: none;
}
.ee-midnight-badge.ee-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Footer enhancement */
.site-footer {
  margin-top: var(--space-2xl);
  padding: var(--space-2xl) 0 var(--space-lg);
  border-top: 1px solid var(--border-subtle);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.footer-section h4 {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text);
  margin-bottom: var(--space-md);
}

.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-section ul li {
  margin-bottom: var(--space-xs);
}

.footer-section a {
  color: var(--muted-strong);
  text-decoration: none;
  font-size: var(--text-sm);
  transition: color 0.15s ease;
}

.footer-section a:hover {
  color: var(--text);
}

.footer-tagline {
  font-size: var(--text-sm);
  line-height: 1.6;
  margin-bottom: var(--space-sm);
}

.footer-disclaimer {
  font-size: var(--text-xs);
  color: var(--muted);
  font-style: italic;
}

.footer-bottom {
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-subtle);
  text-align: center;
}

.footer-bottom p {
  font-size: var(--text-xs);
  color: var(--muted);
  margin: 0;
}

/* pSEO pages */
.pseo-page {
  max-width: 800px;
  margin: var(--space-2xl) auto;
  padding: 0 var(--space-md);
}

.pseo-content {
  padding: var(--space-2xl);
}

.pseo-content h1 {
  font-size: var(--text-3xl);
  line-height: 1.2;
  margin-bottom: var(--space-lg);
  color: var(--text);
}

.pseo-intro {
  margin-bottom: var(--space-2xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
}

.pseo-section {
  margin-bottom: var(--space-2xl);
}

.pseo-section h2 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-md);
  color: var(--text);
}

.pseo-section p {
  line-height: 1.7;
  margin-bottom: var(--space-md);
}

.pseo-section ul {
  margin: var(--space-md) 0;
  padding-left: var(--space-lg);
}

.pseo-section li {
  margin-bottom: var(--space-xs);
  line-height: 1.6;
}

.pseo-cta {
  background: linear-gradient(135deg, var(--bg-subtle) 0%, var(--bg-panel) 100%);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  margin-top: var(--space-2xl);
  text-align: center;
}

.pseo-cta h3 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-sm);
  color: var(--text);
}

.pseo-cta p {
  color: var(--muted-strong);
  margin-bottom: var(--space-md);
}

.cta-button {
  display: inline-block;
  background: var(--accent);
  color: var(--bg);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: var(--space-sm) var(--space-xl);
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(34, 197, 94, 0.3);
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .pseo-content {
    padding: var(--space-lg);
  }

  .pseo-content h1 {
    font-size: var(--text-2xl);
  }
}
