* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--color-bg);
  color: var(--color-text-main);
  font-family: var(--font-sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.interactive-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 4rem 1.25rem;
}

.story-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border);
}

.kicker {
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-columbus);
  margin-bottom: 0.5rem;
}

.story-title {
  font-size: 2.125rem;
  line-height: 1.2;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.story-deck {
  font-size: 1.125rem;
  color: var(--color-text-muted);
  max-width: 72ch;
  margin-bottom: 1.25rem;
}

.scene-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.nav-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-text-faint);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.nav-btn {
  background: var(--color-surface);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  padding: 0.4rem 0.75rem;
  border-radius: 4px;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.nav-btn:hover,
.nav-btn:focus-visible {
  color: #fff;
  border-color: var(--color-columbus);
  outline: 2px solid var(--color-columbus);
  outline-offset: 1px;
}

/* Scrolly layout */
.scrolly-layout {
  position: relative;
}

@media (min-width: 860px) {
  .scrolly-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(320px, 1fr);
    column-gap: 2.5rem;
    align-items: start;
  }
}

.stage-wrapper {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

@media (min-width: 860px) {
  .stage-wrapper {
    position: sticky;
    top: 1.5rem;
    z-index: 10;
    height: 520px;
  }
}

@media (max-width: 859px) {
  .stage-wrapper {
    position: sticky;
    top: 0.5rem;
    z-index: 30;
    height: 280px;
    margin-bottom: 2rem;
  }
}

.graphic-stage {
  position: relative;
  width: 100%;
  height: 100%;
}

.stage-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.narrative-flow {
  display: flex;
  flex-direction: column;
}

@media (min-width: 860px) {
  .narrative-flow {
    gap: 18rem;
    padding: 1.5rem 0 20rem 0;
  }
}

@media (max-width: 859px) {
  .narrative-flow {
    position: relative;
    z-index: 10;
    gap: 22rem;
    padding: 2.5rem 0 20rem 0;
  }
}

.scene-card {
  position: relative;
}

@media (max-width: 859px) {
  .scene-card {
    min-height: 400px;
  }
}

.card-inner {
  background: rgba(24, 32, 44, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 1.25rem 1.375rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

@media (min-width: 860px) {
  .card-inner {
    padding: 1.75rem;
  }
}

.scene-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.scene-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-columbus);
  background: rgba(56, 189, 248, 0.12);
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.scene-topic {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
}

.scene-card h2 {
  font-size: 1.25rem;
  line-height: 1.25;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.75rem;
}

@media (min-width: 860px) {
  .scene-card h2 {
    font-size: 1.375rem;
  }
}

.scene-card p {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
  line-height: 1.55;
}

@media (min-width: 860px) {
  .scene-card p {
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 0.875rem;
  }
}

.scene-card p strong {
  color: #fff;
}

.data-annotation {
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--color-border);
  font-size: 0.75rem;
  color: var(--color-text-faint);
  line-height: 1.45;
}

/* Footer & Caveats */
.story-footer {
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.caveats-box {
  background: var(--color-surface);
  border-left: 4px solid var(--color-columbus);
  border-radius: 0 6px 6px 0;
  padding: 1.25rem 1.5rem;
}

.caveats-box h3 {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.caveats-box p {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.caveats-box p:last-child {
  margin-bottom: 0;
}

.metadata-box {
  font-size: 0.75rem;
  color: var(--color-text-faint);
  line-height: 1.5;
}

/* SVG Chart Typography & Styling */
text {
  font-family: var(--font-sans);
}

@media (prefers-reduced-motion: reduce), html[data-pique-reduced-motion="reduce"] * {
  transition: none !important;
  animation: none !important;
}
