:root {
  --void: #03070d;
  --cyan: #7ee0ff;
  --electric: #3aa0ff;
  --metal: #9eb6c8;
  --white: #f5f8fc;
  --warm: #d4b48a;
  --line: rgba(126, 224, 255, 0.22);
  --font: "Avenir Next", "Helvetica Neue", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: auto;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--void);
  color: var(--white);
  line-height: 1.45;
}

a {
  color: var(--cyan);
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: -3rem;
  z-index: 50;
  padding: 0.5rem 0.85rem;
  background: var(--cyan);
  color: var(--void);
  font-weight: 600;
}

.skip:focus {
  top: 0.75rem;
}

.banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  margin: 0;
  padding: 0.32rem 1rem;
  background: rgba(3, 7, 13, 0.55);
  color: var(--metal);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-align: center;
  text-transform: uppercase;
}

.site-header {
  position: fixed;
  top: 1.55rem;
  left: 0;
  right: 0;
  z-index: 25;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 1.1rem;
  pointer-events: none;
}

.site-header > * {
  pointer-events: auto;
}

.brand {
  text-decoration: none;
  color: var(--white);
  display: flex;
  flex-direction: column;
  justify-self: start;
}

.brand strong {
  letter-spacing: 0.22em;
  font-size: 0.72rem;
  font-weight: 600;
}

.brand span {
  color: var(--metal);
  font-size: 0.58rem;
  letter-spacing: 0.16em;
}

.progress {
  margin: 0;
  justify-self: center;
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  color: var(--cyan);
}

.header-end {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.scene-nav {
  display: flex;
  justify-content: flex-end;
  gap: 0.15rem;
}

.scene-nav a {
  color: transparent;
  text-decoration: none;
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  overflow: hidden;
  font-size: 0;
}

.scene-nav a[aria-current="true"],
.scene-nav a:hover,
.scene-nav a:focus-visible {
  background: var(--cyan);
  border-color: var(--cyan);
}

.text-btn {
  justify-self: end;
  background: none;
  border: 0;
  color: var(--metal);
  font: inherit;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 0.2rem 0;
}

.mission-bar {
  position: fixed;
  top: 1.55rem;
  left: 0;
  right: 0;
  z-index: 24;
  height: 1px;
  background: rgba(126, 224, 255, 0.12);
}

.mission-bar span {
  display: block;
  height: 100%;
  width: 0;
  background: var(--cyan);
}

.voyage {
  position: relative;
  background: var(--void);
}

.stage {
  position: sticky;
  top: 0;
  height: 100svh;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.stage__depth {
  position: absolute;
  inset: 0;
}

.stage__stars {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1px 1px at 12% 18%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(1px 1px at 38% 72%, rgba(126, 224, 255, 0.5), transparent),
    radial-gradient(1.4px 1.4px at 71% 24%, rgba(255, 255, 255, 0.45), transparent),
    radial-gradient(1px 1px at 88% 61%, rgba(126, 224, 255, 0.4), transparent),
    radial-gradient(1px 1px at 54% 8%, rgba(255, 255, 255, 0.35), transparent);
  opacity: 0.45;
  mix-blend-mode: screen;
}

.stage__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 46%;
  opacity: 0;
  will-change: opacity, filter;
}

.stage__light {
  position: absolute;
  inset: 10% 20%;
  background: radial-gradient(circle, rgba(58, 160, 255, 0.18), transparent 62%);
  pointer-events: none;
}

.stage__veil {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 42%, transparent 28%, rgba(3, 7, 13, 0.42) 100%),
    linear-gradient(180deg, rgba(3, 7, 13, 0.28), transparent 22%, transparent 70%, rgba(3, 7, 13, 0.55));
  pointer-events: none;
}

.story {
  position: relative;
  z-index: 1;
  margin-top: -100svh;
}

.chapter {
  min-height: 155svh;
  display: block;
  padding: 0 1.25rem 8vh;
}

.chapter--long {
  min-height: 210svh;
}

.hud--hero {
  top: 16vh;
  gap: 0.8rem;
}

.hud--hero h1 {
  max-width: 12.5em;
  font-size: clamp(1.7rem, 4.4vw, 3.05rem);
  letter-spacing: 0.08em;
}

.hero-lede {
  margin: 0;
  max-width: 36rem;
  color: #d5e4f0;
  font-size: clamp(0.88rem, 1.7vw, 1.02rem);
  line-height: 1.45;
  letter-spacing: 0.02em;
  text-transform: none;
  font-weight: 400;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.55);
}

.hud {
  position: sticky;
  top: 26vh;
  width: min(42rem, 92vw);
  margin: 0 auto;
  padding: 4vh 0 6vh;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.05rem;
  opacity: 0;
  will-change: opacity, transform;
}

.kicker {
  margin: 0;
  color: var(--cyan);
  letter-spacing: 0.42em;
  font-size: 0.68rem;
}

.mission h1,
.mission h2 {
  margin: 0;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.08;
  text-transform: uppercase;
  font-size: clamp(1.7rem, 4.4vw, 3.15rem);
  max-width: 16ch;
  text-shadow: 0 8px 40px rgba(0, 0, 0, 0.45);
}

.dash h1,
.dash h2 {
  margin: 0 0 0.6rem;
  font-weight: 500;
  letter-spacing: 0.04em;
}

h3 {
  margin: 0.2rem 0 0.7rem;
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 500;
}

.note {
  margin: 0;
  color: var(--metal);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.6rem;
  padding: 0.55rem 1.4rem;
  background: transparent;
  color: var(--white);
  text-decoration: none;
  border: 1px solid rgba(126, 224, 255, 0.55);
  cursor: pointer;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font: inherit;
  font-size: 0.68rem;
  border-radius: 999px;
  transition: background 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
}

.cta:hover,
.cta:focus-visible {
  background: rgba(126, 224, 255, 0.12);
  box-shadow: 0 0 24px rgba(126, 224, 255, 0.18);
}

.cta:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem 1.1rem;
}

.scroll-hint {
  margin-top: 1.4rem;
  color: var(--metal);
  font-size: 0.62rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
}

.scroll-hint span {
  width: 1px;
  height: 2.2rem;
  background: linear-gradient(var(--cyan), transparent);
  animation: ds-pulse 1.8s ease-in-out infinite;
}

@keyframes ds-pulse {
  0%,
  100% { opacity: 0.25; transform: scaleY(0.7); }
  50% { opacity: 1; transform: scaleY(1); }
}

.hud-extra,
.hud-panel {
  width: min(36rem, 100%);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.hud-panel {
  max-height: min(58svh, 34rem);
  overflow: auto;
  padding: 1rem 1.1rem 1.15rem;
  background: rgba(5, 12, 22, 0.42);
  border: 1px solid var(--line);
  border-radius: 1.1rem;
  backdrop-filter: blur(14px);
  text-align: left;
}

.chip-grid,
#resource-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem;
}

.chip {
  background: transparent;
  border: 1px solid var(--line);
  color: inherit;
  padding: 0.42rem 0.7rem;
  cursor: pointer;
  font: inherit;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  border-radius: 999px;
}

.chip[aria-pressed="true"] {
  border-color: var(--cyan);
  color: var(--cyan);
}

.destinations {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
  width: min(40rem, 100%);
}

.destination {
  background: transparent;
  border: 1px solid var(--line);
  color: inherit;
  padding: 1rem 0.7rem;
  cursor: pointer;
  font: inherit;
  border-radius: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-height: 8.5rem;
}

.destination span {
  color: var(--cyan);
  letter-spacing: 0.2em;
  font-size: 0.62rem;
}

.destination strong {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 500;
}

.destination em {
  font-style: normal;
  color: var(--metal);
  font-size: 0.78rem;
}

.destination.is-selected,
.destination:hover,
.destination:focus-visible {
  border-color: var(--cyan);
}

.form-progress {
  display: flex;
  justify-content: center;
  gap: 0.55rem;
  padding: 0;
  margin: 0 0 0.8rem;
  list-style: none;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  color: var(--metal);
}

.form-progress [aria-current="step"] {
  color: var(--cyan);
}

label {
  display: block;
  margin: 0.65rem 0 0.25rem;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

input,
textarea,
select {
  width: 100%;
  padding: 0.58rem 0.7rem;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--white);
  font: inherit;
  border-radius: 0;
}

.field-error {
  color: #ffb4a2;
  font-size: 0.82rem;
}

.summary,
.compare,
.scan-steps {
  padding: 0;
}

.scan-steps {
  list-style: none;
  margin: 0;
  display: flex;
  gap: 0.8rem;
  justify-content: center;
  flex-wrap: wrap;
}

.scan-steps li {
  opacity: 0.28;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.68rem;
}

.scan-steps li.is-on {
  opacity: 1;
  color: var(--cyan);
}

.compare table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.compare th,
.compare td {
  border-bottom: 1px solid var(--line);
  padding: 0.4rem;
  text-align: left;
}

.icon-btn {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: rgba(3, 7, 13, 0.4);
  color: var(--cyan);
  cursor: pointer;
}

.scene-controls {
  position: fixed;
  right: 1rem;
  bottom: 1.1rem;
  z-index: 21;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.site-footer {
  position: relative;
  z-index: 2;
  padding: 1.2rem;
  color: var(--metal);
  font-size: 0.72rem;
  text-align: center;
}

.cta:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
a:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

.dash {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 16rem 1fr;
}

.dash-side {
  background: #071018;
  border-right: 1px solid var(--line);
  padding: 1.2rem;
}

.dash-main {
  padding: 1.2rem;
}

.dash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.7rem;
}

.dash-card {
  border: 1px solid var(--line);
  background: rgba(6, 16, 28, 0.72);
  padding: 0.9rem;
}

.chat {
  margin-top: 0.7rem;
}

.chat p {
  margin: 0.35rem 0;
  font-size: 0.88rem;
}

@media (max-width: 900px) {
  .dash {
    grid-template-columns: 1fr;
  }

  .site-header {
    grid-template-columns: 1fr auto;
    top: 1.8rem;
  }

  .progress {
    display: none;
  }

  .destinations {
    grid-template-columns: 1fr;
  }

  .chapter,
  .chapter--long {
    min-height: 175svh;
    padding: 0 1rem 6vh;
  }

  .hud,
  .hud--hero {
    top: 20vh;
  }

  .hud--hero h1 {
    max-width: 11em;
    font-size: clamp(1.55rem, 7.4vw, 2.2rem);
  }

  .hero-lede {
    max-width: 32rem;
    font-size: 0.9rem;
  }

  .hud-panel {
    max-height: min(62svh, 28rem);
  }

  h1,
  h2 {
    font-size: clamp(1.45rem, 8vw, 2.2rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .scroll-hint span,
  .stage__video,
  .hud,
  .stage__stars,
  .stage__light {
    animation: none;
    transform: none !important;
  }
}
