/* The Rebalance Edge — scrollytelling styles.
   Stage (pinned canvas) + HUD overlays + scroll step cards. */

body.story { background: #fcfcfb; }

.story-topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 40;
  max-width: none;
  background: linear-gradient(rgba(252, 252, 251, 0.95) 65%, transparent);
}

.scrolly { position: relative; }

/* ---------- Stage ---------- */

.stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100dvh;
  z-index: 1;
}

#stage { width: 100%; height: 100%; display: block; }

.hud { position: absolute; inset: 0; pointer-events: none; }

.ticker-bar {
  position: absolute;
  top: 74px; left: 0; right: 0;
  display: flex;
  gap: 2.25rem;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--navy-60);
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.ticker-bar .tick-up { color: #1554a0; }
.ticker-bar .tick-down { color: #b54a3c; }

.live-chip {
  position: absolute;
  top: 108px; right: 28px;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--navy-60);
  opacity: 0;
  transition: opacity 0.6s ease;
}

.live-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #b54a3c;
}

@media (prefers-reduced-motion: no-preference) {
  .live-dot { animation: live-pulse 1.6s ease-in-out infinite; }
  @keyframes live-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
}

.announce-banner {
  position: absolute;
  top: 112px; left: 50%;
  transform: translate(-50%, -16px);
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  background: var(--navy);
  color: #fff;
  padding: 0.8rem 1.3rem;
  border-radius: 10px;
  font-size: 0.8rem;
  max-width: min(92vw, 480px);
  text-align: center;
  opacity: 0;
  transition: opacity 0.5s ease, transform 0.5s ease;
  box-shadow: 0 12px 32px rgba(8, 28, 54, 0.25);
}

.announce-banner b { font-size: 0.68rem; letter-spacing: 0.16em; color: #c9d7ea; }
.announce-banner.show { opacity: 1; transform: translate(-50%, 0); }

.countdown-chip {
  position: absolute;
  top: 108px; left: 28px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  font-variant-numeric: tabular-nums;
  color: #b54a3c;
  border: 1.5px solid rgba(181, 74, 60, 0.45);
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
  background: rgba(252, 252, 251, 0.85);
  opacity: 0;
  transition: opacity 0.5s ease, color 0.5s ease, border-color 0.5s ease;
}

.countdown-chip.elapsed {
  color: var(--navy-60);
  border-color: var(--navy-30);
}

.sim-note {
  position: absolute;
  bottom: 14px; left: 0; right: 0;
  text-align: center;
  font-size: 0.68rem;
  color: var(--navy-30);
}

.hud .show { opacity: 1; }

/* ---------- Steps ---------- */

.step {
  position: relative;
  z-index: 10;
  min-height: 130vh;
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
  pointer-events: none;
}

.step > * { pointer-events: auto; }

.step-hero {
  min-height: 100vh;
  margin-top: -100vh; /* overlay the stage's first screen */
  justify-content: center;
  text-align: center;
}

.hero-card h1 {
  font-size: clamp(1.9rem, 4.5vw, 3rem);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.05;
  color: var(--navy);
}

.eyebrow-chip {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue);
  border: 1px solid rgba(21, 84, 160, 0.35);
  border-radius: 999px;
  padding: 0.35rem 0.9rem;
  margin-bottom: 1.4rem;
  background: rgba(252, 252, 251, 0.8);
}

.hero-sub {
  margin-top: 1.25rem;
  font-size: 1.1rem;
  color: var(--navy-60);
  line-height: 1.55;
}

.hero-disclaimer {
  margin: 1.75rem auto 0;
  max-width: 480px;
  text-align: left;
  background: #fff;
  border: 1px solid var(--navy-12);
  border-left: 4px solid #b54a3c;
  border-radius: 10px;
  padding: 0.9rem 1.1rem;
}

.hero-disclaimer > b {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #b54a3c;
  margin-bottom: 0.35rem;
}

.hero-disclaimer p { font-size: 0.82rem; line-height: 1.55; color: var(--navy-60); }
.hero-disclaimer p b { color: var(--navy); }

.scroll-hint {
  margin-top: 2rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--navy-30);
}

@media (prefers-reduced-motion: no-preference) {
  .scroll-hint { animation: hint-bob 2.2s ease-in-out infinite; }
  @keyframes hint-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(6px); } }
}

.step-context { justify-content: center; text-align: center; }

.context-card { max-width: 620px; }

.context-card h2 {
  font-size: clamp(1.9rem, 5vw, 3.2rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--navy);
}

.context-card p {
  margin: 1.25rem auto 0;
  max-width: 460px;
  font-size: 1.02rem;
  line-height: 1.6;
  color: var(--navy-60);
}

.step-card {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--navy-12);
  border-radius: 14px;
  padding: 1.5rem 1.6rem;
  max-width: 380px;
  margin-left: clamp(0px, 6vw, 90px);
  box-shadow: 0 16px 40px rgba(8, 28, 54, 0.08);
  backdrop-filter: blur(4px);
}

.step-card h3 { font-size: 1.25rem; letter-spacing: -0.015em; margin-bottom: 0.55rem; color: var(--navy); }
.step-card p { font-size: 0.95rem; color: var(--navy-60); }
.step-card em { color: #b54a3c; font-style: normal; font-weight: 700; }

/* ---------- Outro ---------- */

.step-outro { min-height: 110vh; justify-content: center; text-align: center; }

.outro-card { max-width: 460px; padding-bottom: 4rem; }

.outro-card h2 {
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -0.025em;
  line-height: 1.08;
  color: var(--navy);
}

.outro-card > p { margin-top: 1.1rem; color: var(--navy-60); }

.interest-form {
  margin-top: 2rem;
  text-align: left;
  background: #fff;
  border: 1px solid var(--navy-12);
  border-radius: 14px;
  padding: 1.5rem 1.6rem;
  box-shadow: 0 16px 40px rgba(8, 28, 54, 0.08);
}

.interest-form textarea {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--navy-30);
  border-radius: 8px;
  font: inherit;
  color: var(--navy);
  resize: vertical;
}

.interest-form .btn { width: 100%; margin-top: 0.4rem; }

.disclaimer-line { margin-top: 1.5rem; font-size: 0.75rem; }
.disclaimer-line a { color: var(--navy-60); }

/* ---------- Progress bar, scene dots, replay ---------- */

.progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0;
  background: var(--blue);
  z-index: 60;
}

.scene-dots {
  position: fixed;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 30;
}

.scene-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border-radius: 50%;
  border: 1.5px solid var(--navy-30);
  background: transparent;
  cursor: pointer;
  transition: background 200ms ease, border-color 200ms ease, transform 200ms ease;
}

.scene-dots button:hover { border-color: var(--blue); }

.scene-dots button.is-active {
  background: var(--navy);
  border-color: var(--navy);
  transform: scale(1.25);
}

.replay-btn { margin-top: 1.5rem; }

@media (max-width: 900px) {
  .scene-dots { display: none; }
}

/* ---------- Small screens ---------- */

@media (max-width: 640px) {
  .step-card { margin-left: 0; max-width: none; }
  .ticker-bar { justify-content: flex-start; padding-left: 1rem; }
  .live-chip { top: 100px; right: 16px; }
  .countdown-chip { top: 100px; left: 16px; }
}
