/* ===== VANTA ===== */
:root {
  --bg: #050507;
  --bg2: #0a0a0e;
  --ink: #e8e8ec;
  --dim: #7b7b85;
  --cyan: #29e6ff;
  --cyan-dim: rgba(41, 230, 255, 0.35);
  --condensed: "Anton", "Arial Narrow", sans-serif;
  --body: "Archivo", "Helvetica Neue", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: auto; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* grain */
.grain {
  position: fixed; inset: -50%;
  pointer-events: none; z-index: 90;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  animation: grain 0.6s steps(2) infinite;
}
@keyframes grain { 0% { transform: translate(0,0);} 50% { transform: translate(2%, -1%);} 100% { transform: translate(-1%, 2%);} }

/* topbar */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 80;
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 32px;
  mix-blend-mode: difference;
}
.wordmark {
  font-family: var(--condensed);
  font-size: 20px; letter-spacing: 0.55em; color: #fff;
}
.topbar-cta {
  color: #fff; text-decoration: none; font-size: 12px;
  letter-spacing: 0.25em; text-transform: uppercase;
  border: 1px solid rgba(255,255,255,0.4);
  padding: 9px 18px; border-radius: 2px;
  transition: background 0.3s, color 0.3s;
}
.topbar-cta:hover { background: #fff; color: #000; }

/* HUD */
.hud {
  position: fixed; right: 32px; bottom: 28px; z-index: 70;
  width: 170px; text-align: right;
  font-variant-numeric: tabular-nums;
  opacity: 0; transition: opacity 0.5s;
  pointer-events: none;
}
.hud.on { opacity: 1; }
.hud-speed {
  font-family: var(--condensed);
  font-size: 56px; line-height: 1; color: var(--ink);
  text-shadow: 0 0 24px var(--cyan-dim);
}
.hud-unit { font-size: 14px; color: var(--cyan); margin-left: 6px; letter-spacing: 0.2em; }
.hud-bar {
  height: 2px; background: rgba(255,255,255,0.15);
  margin: 10px 0 6px; border-radius: 1px; overflow: hidden;
}
.hud-bar-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--cyan), #b7f7ff);
  box-shadow: 0 0 10px var(--cyan);
}
.hud-meta {
  display: flex; justify-content: space-between;
  font-size: 10px; letter-spacing: 0.28em; color: var(--dim);
}
#hudMode { color: var(--cyan); }

/* loader */
.loader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--bg);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 22px;
  transition: opacity 0.7s, visibility 0.7s;
}
.loader.done { opacity: 0; visibility: hidden; }
.loader-word {
  font-family: var(--condensed); font-size: 42px;
  letter-spacing: 0.6em; text-indent: 0.6em;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: 0.35; } }
.loader-track { width: 220px; height: 2px; background: rgba(255,255,255,0.12); }
.loader-fill { height: 100%; width: 0%; background: var(--cyan); box-shadow: 0 0 12px var(--cyan); transition: width 0.2s; }
.loader-label { font-size: 10px; letter-spacing: 0.35em; color: var(--dim); }

/* ===== journey ===== */
.journey { position: relative; height: 900vh; }
.stage { position: sticky; top: 0; height: 100vh; overflow: hidden; background: var(--bg); }
#film { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.vignette {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,0.55) 100%),
    linear-gradient(180deg, rgba(0,0,0,0.35) 0%, transparent 18%, transparent 82%, rgba(0,0,0,0.45) 100%);
}

/* overlays */
.overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  will-change: opacity, transform;
}
.overlay-left { justify-content: flex-start; padding-left: 8vw; }
.overlay-right { justify-content: flex-end; padding-right: 8vw; text-align: right; }

.hero-block { text-align: center; }
.hero-title {
  font-family: var(--condensed);
  font-size: clamp(90px, 19vw, 340px);
  line-height: 0.9;
  letter-spacing: 0.14em; text-indent: 0.14em;
  color: var(--ink);
  text-shadow: 0 0 80px rgba(41,230,255,0.18);
}
.hero-sub {
  margin-top: 18px; font-size: clamp(14px, 1.6vw, 22px);
  letter-spacing: 0.5em; text-indent: 0.5em;
  text-transform: uppercase; color: var(--cyan);
}
.hero-hint {
  margin-top: 7vh; font-size: 10px; letter-spacing: 0.4em;
  text-transform: uppercase; color: var(--dim);
  animation: hint 2s ease-in-out infinite;
}
@keyframes hint { 50% { transform: translateY(6px); opacity: 0.4; } }

.cap-kicker {
  font-size: 11px; letter-spacing: 0.45em; text-transform: uppercase;
  color: var(--cyan); margin-bottom: 16px;
}
.cap-title {
  font-family: var(--condensed);
  font-size: clamp(40px, 6vw, 96px);
  line-height: 1.02; letter-spacing: 0.03em;
  text-transform: uppercase;
}
.cap-center { text-align: center; }

/* stats */
.stats { display: flex; gap: clamp(30px, 7vw, 120px); }
.stat { text-align: center; }
.stat-num {
  font-family: var(--condensed);
  font-size: clamp(54px, 8vw, 128px); line-height: 1;
  color: var(--ink); font-variant-numeric: tabular-nums;
  text-shadow: 0 0 40px rgba(41,230,255,0.25);
}
.stat-num em { font-style: normal; font-size: 0.32em; color: var(--cyan); margin-left: 4px; }
.stat-label {
  margin-top: 12px; font-size: 11px; letter-spacing: 0.3em;
  text-transform: uppercase; color: var(--dim);
}

/* ===== flowing sections ===== */
.section { position: relative; padding: 16vh 8vw; background: var(--bg); }
.section-head { max-width: 720px; margin-bottom: 8vh; }
.section-title {
  font-family: var(--condensed);
  font-size: clamp(44px, 6.5vw, 104px);
  line-height: 1; text-transform: uppercase; letter-spacing: 0.02em;
  margin: 14px 0 22px;
}
.section-body { color: var(--dim); font-size: 17px; line-height: 1.7; max-width: 54ch; }

.macro-grid {
  display: grid; gap: 18px;
  grid-template-columns: repeat(3, 1fr);
  align-items: stretch;
}
.macro { position: relative; overflow: hidden; border-radius: 4px; background: var(--bg2); }
.macro img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  aspect-ratio: 3 / 4;
  filter: saturate(0.9) contrast(1.05);
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.macro-tall img { aspect-ratio: 3 / 4; }
.macro:hover img { transform: scale(1.05); }
.macro figcaption {
  position: absolute; left: 16px; bottom: 14px;
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  text-shadow: 0 1px 8px rgba(0,0,0,0.8);
}

/* configurator */
.config { text-align: center; }
.config .section-head { margin-left: auto; margin-right: auto; text-align: center; }
.config-stage {
  max-width: 1080px; margin: 0 auto;
  border-radius: 6px; overflow: hidden;
  box-shadow: 0 40px 120px rgba(0,0,0,0.7);
}
.config-stage img { width: 100%; display: block; transition: opacity 0.25s; }
.swatches { display: flex; gap: 14px; justify-content: center; margin-top: 34px; flex-wrap: wrap; }
.swatch {
  display: flex; align-items: center; gap: 10px;
  background: none; border: 1px solid rgba(255,255,255,0.18);
  color: var(--dim); font-family: var(--body);
  font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase;
  padding: 12px 22px; border-radius: 2px; cursor: pointer;
  transition: border-color 0.3s, color 0.3s;
}
.swatch:hover { color: var(--ink); }
.swatch.active { border-color: var(--cyan); color: var(--ink); box-shadow: 0 0 18px rgba(41,230,255,0.15); }
.chip { width: 14px; height: 14px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.3); }
.chip-obsidian { background: #101014; }
.chip-cyan { background: linear-gradient(135deg, #0e3f4a, #29e6ff); }
.chip-white { background: #e6e4dd; }
.config-name {
  margin-top: 22px; font-family: var(--condensed);
  font-size: 26px; letter-spacing: 0.35em; text-indent: 0.35em;
  text-transform: uppercase; color: var(--cyan);
}

/* reserve */
.reserve {
  text-align: center; padding: 24vh 8vw;
  background: radial-gradient(ellipse at 50% 120%, rgba(41,230,255,0.08), transparent 60%), var(--bg);
}
.reserve-title {
  font-family: var(--condensed);
  font-size: clamp(70px, 14vw, 240px);
  letter-spacing: 0.18em; text-indent: 0.18em; line-height: 1;
  background: linear-gradient(180deg, #fff 30%, #3a3a44 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.reserve-sub { margin: 26px 0 40px; color: var(--dim); letter-spacing: 0.12em; }
.reserve-btn {
  display: inline-block; text-decoration: none;
  font-size: 14px; letter-spacing: 0.28em; text-transform: uppercase;
  color: #000; background: var(--cyan);
  padding: 20px 46px; border-radius: 2px;
  box-shadow: 0 0 40px rgba(41,230,255,0.35);
  transition: transform 0.3s, box-shadow 0.3s;
}
.reserve-btn:hover { transform: translateY(-2px); box-shadow: 0 0 70px rgba(41,230,255,0.55); }
.reserve-fine { margin-top: 20px; font-size: 11px; color: #4a4a52; letter-spacing: 0.15em; }

.footer {
  padding: 30px; text-align: center;
  font-size: 10px; letter-spacing: 0.3em; text-transform: uppercase;
  color: #3c3c44; background: var(--bg);
}

@media (max-width: 760px) {
  .stats { flex-direction: column; gap: 26px; }
  .macro-grid { grid-template-columns: 1fr; }
  .hud { right: 18px; bottom: 18px; width: 130px; }
  .hud-speed { font-size: 40px; }
  .overlay-left, .overlay-right { padding-left: 6vw; padding-right: 6vw; }
}
