:root {
  --bg: #05070c;
  --bg2: #0a0e17;
  --panel: rgba(16, 21, 33, 0.72);
  --line: rgba(255, 255, 255, 0.08);
  --text: #e8ebf3;
  --muted: #8a93a8;
  --blue: #4c6ef5;
  --cyan: #22d3ee;
  --gold: #ffc94d;
  --green: #2fd287;
  --red: #ff5a62;
  --grad: linear-gradient(100deg, var(--cyan), var(--gold));
  --radius: 18px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { display: block; }
h1, h2, h3 { margin: 0; letter-spacing: -0.03em; line-height: 1.05; }
h2 { font-size: clamp(34px, 5vw, 64px); font-weight: 800; }
h2 em, h1 em {
  font-style: normal;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
p { margin: 0; }
.mono { font-family: "JetBrains Mono", ui-monospace, Menlo, monospace; }
.center { text-align: center; margin-left: auto; margin-right: auto; }
.eyebrow {
  display: inline-block;
  font: 600 12px/1 "JetBrains Mono", ui-monospace, monospace;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 18px;
}
.eyebrow.center { display: block; }
section { position: relative; }

/* ---------- global effects ---------- */
.progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; }
.progress i { display: block; height: 100%; width: 100%; background: var(--grad); transform-origin: 0 50%; transform: scaleX(var(--sp, 0)); }
.spot {
  position: fixed; inset: 0; pointer-events: none; z-index: 1;
  background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 30%), rgba(76, 110, 245, 0.10), transparent 60%);
}
.grain {
  position: fixed; inset: -50%; pointer-events: none; z-index: 70; opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain { 0% { transform: translate(0, 0); } 33% { transform: translate(-3%, 2%); } 66% { transform: translate(2%, -3%); } 100% { transform: translate(0, 0); } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 18px; border-radius: 999px;
  font-weight: 600; font-size: 14px; white-space: nowrap;
  border: 1px solid var(--line);
  transition: transform .3s var(--ease), background .3s, border-color .3s, box-shadow .3s;
  cursor: pointer; font-family: inherit; color: var(--text); background: transparent;
}
.btn.big { padding: 15px 28px; font-size: 16px; }
.btn.full { width: 100%; }
.btn.ghost:hover { background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.18); }
.btn.primary {
  position: relative; overflow: hidden; border: 0; color: #061018;
  background: linear-gradient(100deg, #5ee7ff, #ffd56b);
  box-shadow: 0 10px 40px -10px rgba(34, 211, 238, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
.btn.primary::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, 0.65) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform .8s var(--ease);
}
.btn.primary:hover::after { transform: translateX(120%); }
.btn.primary:hover { box-shadow: 0 16px 60px -10px rgba(34, 211, 238, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.5); }
.btn span { position: relative; z-index: 1; }

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 14px; left: 50%; z-index: 50;
  transform: translateX(-50%);
  width: min(1180px, calc(100% - 28px));
  display: flex; align-items: center; gap: 20px;
  padding: 10px 12px 10px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: background .4s, border-color .4s, backdrop-filter .4s, padding .4s;
}
.nav.scrolled { background: rgba(8, 11, 18, 0.66); border-color: var(--line); backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%); }
.brand { display: flex; align-items: center; gap: 9px; font-size: 18px; font-weight: 500; letter-spacing: -0.01em; }
.brand b { font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand img { filter: drop-shadow(0 0 10px rgba(76, 110, 245, 0.5)); }
.links { display: flex; gap: 4px; margin: 0 auto; }
.links a { padding: 8px 14px; border-radius: 999px; font-size: 14px; color: var(--muted); transition: color .2s, background .2s; }
.links a:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.nav-cta { display: flex; gap: 8px; }
.burger { display: none; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: transparent; cursor: pointer; position: relative; }
.burger i { position: absolute; left: 12px; right: 12px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .3s var(--ease), top .3s; }
.burger i:first-child { top: 16px; } .burger i:last-child { top: 24px; }
.nav.open .burger i:first-child { top: 20px; transform: rotate(45deg); }
.nav.open .burger i:last-child { top: 20px; transform: rotate(-45deg); }

/* ---------- hero ---------- */
.hero {
  min-height: 100vh; min-height: 100svh;
  padding: 150px 20px 80px;
  display: flex; flex-direction: column; align-items: center;
  overflow: hidden;
  perspective: 1400px;
}
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0.22; filter: blur(1.5px); mask-image: linear-gradient(180deg, #000 40%, transparent 90%); -webkit-mask-image: linear-gradient(180deg, #000 40%, transparent 90%); }
.orb { position: absolute; border-radius: 50%; filter: blur(90px); pointer-events: none; animation: float 14s ease-in-out infinite; }
.o1 { width: 520px; height: 520px; background: rgba(76, 110, 245, 0.35); top: -120px; left: -160px; }
.o2 { width: 460px; height: 460px; background: rgba(255, 201, 77, 0.18); top: 160px; right: -180px; animation-delay: -6s; }
@keyframes float { 50% { transform: translate(40px, 30px) scale(1.08); } }
.hero-copy { position: relative; z-index: 2; text-align: center; max-width: 980px; transform: translateY(calc(var(--hp, 0) * -60px)); opacity: calc(1 - var(--hp, 0) * 1.4); }
.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px; border-radius: 999px; font-size: 13px; color: var(--muted);
  border: 1px solid var(--line); background: rgba(255, 255, 255, 0.03); backdrop-filter: blur(6px);
}
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 0 rgba(47, 210, 135, 0.7); animation: ping 1.8s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 10px rgba(47, 210, 135, 0); } 100% { box-shadow: 0 0 0 0 rgba(47, 210, 135, 0); } }
.headline { margin: 26px 0 22px; font-size: clamp(46px, 8.6vw, 112px); font-weight: 800; letter-spacing: -0.045em; line-height: 0.98; }
.headline .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.08em; }
.headline .w > span { display: inline-block; transform: translateY(110%) rotate(6deg); opacity: 0; transition: transform 1.1s var(--ease), opacity 1.1s var(--ease); transition-delay: calc(var(--i) * 70ms + 150ms); }
.loaded .headline .w > span { transform: none; opacity: 1; }
.headline em { display: inline-block; }
.sub { font-size: clamp(16px, 1.6vw, 19px); color: var(--muted); max-width: 680px; margin: 0 auto; }
.hero-cta { margin-top: 34px; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.reveal-now { opacity: 0; transform: translateY(20px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.loaded .reveal-now { opacity: 1; transform: none; }
.reveal-now.d2 { transition-delay: .55s; } .reveal-now.d3 { transition-delay: .75s; }

.device-wrap { position: relative; z-index: 2; width: min(1120px, 100%); margin-top: 70px; transform-style: preserve-3d; }
.device {
  position: relative;
  border-radius: 20px; overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #070a12;
  box-shadow: 0 60px 140px -40px rgba(34, 211, 238, 0.35), 0 30px 80px -30px rgba(0, 0, 0, 0.9);
  transform: rotateX(calc((1 - var(--dp, 0)) * 32deg)) scale(calc(0.84 + var(--dp, 0) * 0.16)) translateY(calc((1 - var(--dp, 0)) * 40px));
  transform-origin: 50% 0;
  opacity: 0; transition: opacity 1.2s var(--ease) .9s;
}
.loaded .device { opacity: 1; }
.device-bar { display: flex; align-items: center; gap: 7px; padding: 11px 14px; border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, 0.02); font-size: 12px; color: var(--muted); }
.device-bar > i { width: 10px; height: 10px; border-radius: 50%; background: #2a3142; }
.device-bar > i:first-child { background: #ff5f57; } .device-bar > i:nth-child(2) { background: #febc2e; } .device-bar > i:nth-child(3) { background: #28c840; }
.device-title { display: flex; align-items: center; gap: 6px; margin-left: 10px; }
.device-price { margin-left: auto; color: var(--text); font-weight: 600; transition: color .3s; }
.device-price.up { color: var(--green); } .device-price.down { color: var(--red); }
.device-canvas { display: block; width: 100%; aspect-ratio: 16 / 8.2; }
.device-glow { position: absolute; inset: auto 10% -40% 10%; height: 60%; background: radial-gradient(closest-side, rgba(34, 211, 238, 0.18), transparent); pointer-events: none; }
.scroll-hint { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: 3; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 8px; opacity: calc(1 - var(--hp, 0) * 4); }
.scroll-hint span { width: 22px; height: 34px; border: 1.5px solid rgba(255, 255, 255, 0.3); border-radius: 12px; position: relative; }
.scroll-hint span::after { content: ""; position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: var(--text); animation: wheel 1.6s infinite; }
@keyframes wheel { 0% { opacity: 0; transform: translateY(-3px); } 40% { opacity: 1; } 100% { opacity: 0; transform: translateY(9px); } }

/* ---------- story (pinned, scroll-scrubbed) ---------- */
.story { height: 760vh; }
.story-sticky {
  position: sticky; top: 0; height: 100vh; height: 100svh;
  display: grid; place-items: center;
  padding: 96px 24px 32px;
}
/* as wide as the screen allows while the whole chart still fits in the window */
.story-stage { width: min(1480px, 100%, calc((100svh - 140px) * 1.9)); }
.stage-frame {
  position: relative; border-radius: 20px; overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.1);
  background: #070a12; box-shadow: 0 40px 120px -40px rgba(76, 110, 245, 0.5);
}
.story-canvas { display: block; width: 100%; aspect-ratio: 1.9; }
.stage-hud { position: absolute; top: 12px; left: 12px; right: 72px; display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); pointer-events: none; }
.stage-hud span { padding: 5px 9px; border-radius: 8px; background: rgba(5, 7, 12, 0.7); border: 1px solid var(--line); backdrop-filter: blur(6px); }
.stage-hud [data-hud-label] { color: var(--cyan); }

/* ---------- horizontal features ---------- */
.hscroll { height: 340vh; }
.hscroll-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; display: flex; flex-direction: column; justify-content: center; gap: 46px; }
.hscroll-head { padding: 0 max(24px, calc((100vw - 1240px) / 2)); }
.hscroll-track { display: flex; gap: 22px; padding: 0 max(24px, calc((100vw - 1240px) / 2)); width: max-content; transform: translateX(var(--hx, 0px)); will-change: transform; }
.card {
  position: relative; width: min(380px, 78vw); min-height: 300px; padding: 30px;
  border-radius: var(--radius); border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01)), var(--bg2);
  transform: perspective(900px) rotateX(var(--ry, 0deg)) rotateY(var(--rx, 0deg));
  transition: transform .4s var(--ease), border-color .4s;
  overflow: hidden;
}
.card::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(300px circle at var(--cx, 50%) var(--cy, 0%), rgba(34, 211, 238, 0.16), transparent 60%);
  opacity: 0; transition: opacity .4s;
}
.card:hover { border-color: rgba(34, 211, 238, 0.35); }
.card:hover::before { opacity: 1; }
.card { display: flex; flex-direction: column; min-height: 470px; padding-top: 0; }
.card-viz {
  display: block; width: calc(100% + 60px); margin: 0 -30px 22px; height: 230px;
  background: #070a12; border-bottom: 1px solid var(--line);
  mask-image: linear-gradient(180deg, #000 70%, transparent); -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent);
  transition: transform .6s var(--ease);
}
.card:hover .card-viz { transform: scale(1.03); }
.card .tag { position: static; align-self: flex-start; margin-top: auto; }
.card p { margin-bottom: 22px; }
.card h3 { font-size: 23px; margin-bottom: 12px; }
.card p { color: var(--muted); font-size: 15px; }
.tag { position: absolute; left: 30px; bottom: 26px; font-size: 11.5px; color: var(--cyan); padding: 5px 10px; border-radius: 999px; border: 1px solid rgba(34, 211, 238, 0.3); }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(36px); filter: blur(6px); transition: opacity 1s var(--ease), transform 1s var(--ease), filter 1s var(--ease); }
.reveal.in { opacity: 1; transform: none; filter: none; }
.reveal.d1 { transition-delay: .1s; } .reveal.d2 { transition-delay: .2s; } .reveal.d3 { transition-delay: .3s; }

/* ---------- pricing ---------- */
.pricing { padding: 140px 24px; max-width: 1240px; margin: 0 auto; }
.billing { display: flex; width: max-content; margin: 34px auto 50px; padding: 4px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg2); }
.billing button { border: 0; background: transparent; color: var(--muted); font: 600 14px Inter, sans-serif; padding: 9px 20px; border-radius: 999px; cursor: pointer; transition: background .3s, color .3s; }
.billing button.on { background: rgba(255, 255, 255, 0.08); color: var(--text); }
.billing small { color: var(--gold); font-weight: 600; margin-left: 4px; }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.plan { position: relative; padding: 34px 30px; border-radius: 22px; border: 1px solid var(--line); background: var(--bg2); display: flex; flex-direction: column; }
.plan.hot { border-color: transparent; background: linear-gradient(var(--bg2), var(--bg2)) padding-box, linear-gradient(140deg, var(--cyan), var(--gold)) border-box; border: 1px solid transparent; box-shadow: 0 40px 120px -50px rgba(34, 211, 238, 0.6); transform: translateY(-10px); }
.plan .badge { position: absolute; top: -12px; left: 30px; padding: 4px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; color: #061018; background: var(--grad); }
.plan h3 { font-size: 22px; }
.plan .desc { color: var(--muted); font-size: 14.5px; margin: 8px 0 24px; min-height: 46px; }
.plan .price { font-size: 44px; font-weight: 800; letter-spacing: -0.04em; }
.plan .price small { font-size: 15px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.plan .was { display: flex; align-items: center; gap: 10px; margin-bottom: 2px; font-size: 18px; }
.plan .was s { color: var(--muted); text-decoration-color: var(--red); text-decoration-thickness: 2px; }
.plan .was span { font: 600 12px "JetBrains Mono", monospace; color: var(--green); padding: 3px 9px; border-radius: 999px; background: rgba(47, 210, 135, 0.1); border: 1px solid rgba(47, 210, 135, 0.35); }
.plan .soon { display: inline-block; font: 600 12px "JetBrains Mono", monospace; color: var(--gold); padding: 4px 10px; border-radius: 999px; border: 1px solid rgba(255, 201, 77, 0.35); margin-top: 8px; }
.plan ul { list-style: none; padding: 0; margin: 26px 0 30px; display: grid; gap: 11px; font-size: 14.5px; color: #c6ccda; }
.plan li { display: flex; gap: 10px; }
.plan li::before { content: "✓"; color: var(--cyan); font-weight: 700; }
.plan .btn { margin-top: auto; }
.fine { color: var(--muted); font-size: 14px; margin-top: 34px; }

/* ---------- FAQ ---------- */
.faq { padding: 120px 24px; max-width: 860px; margin: 0 auto; }
.faq-list { margin-top: 50px; display: grid; gap: 12px; }
details { border: 1px solid var(--line); border-radius: 16px; background: var(--bg2); padding: 0 22px; transition: border-color .3s; }
details[open] { border-color: rgba(34, 211, 238, 0.3); }
summary { cursor: pointer; list-style: none; padding: 20px 0; font-weight: 600; font-size: 17px; display: flex; justify-content: space-between; gap: 20px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 22px; line-height: 1; color: var(--cyan); transition: transform .3s var(--ease); }
details[open] summary::after { transform: rotate(45deg); }
details p { color: var(--muted); padding-bottom: 20px; }

/* ---------- final CTA ---------- */
.final { min-height: 90vh; display: grid; place-items: center; text-align: center; overflow: hidden; padding: 120px 24px; }
.final-bg { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0.45; mask-image: radial-gradient(ellipse at center, #000 20%, transparent 70%); -webkit-mask-image: radial-gradient(ellipse at center, #000 20%, transparent 70%); }
.final-copy { position: relative; max-width: 820px; }
.final h2 { font-size: clamp(40px, 7vw, 92px); margin-bottom: 22px; }
.final p { color: var(--muted); font-size: 19px; margin-bottom: 36px; }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--line); padding: 50px max(24px, calc((100vw - 1240px) / 2)) 40px; background: var(--bg2); }
.foot-top { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.foot nav { display: flex; gap: 22px; flex-wrap: wrap; }
.foot nav a { color: var(--muted); font-size: 14px; } .foot nav a:hover { color: var(--text); }
.risk { margin-top: 34px; font-size: 12.5px; color: #69728a; max-width: 900px; line-height: 1.6; }
.copy { margin-top: 16px; font-size: 13px; color: #69728a; }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .links, .nav-cta .btn.ghost { display: none; }
  .burger { display: block; }
  .nav { padding: 8px 8px 8px 16px; gap: 10px; }
  .nav-cta { margin-left: auto; }
  .nav.open { border-radius: 24px; flex-wrap: wrap; background: rgba(8, 11, 18, 0.92); border-color: var(--line); backdrop-filter: blur(16px); }
  .nav.open .links { display: flex; flex-direction: column; order: 5; width: 100%; margin: 6px 0 4px; }
  .nav.open .links a { padding: 12px 14px; font-size: 16px; }
  .story { height: 620vh; }
  .story-sticky { padding: 76px 12px 20px; }
  .story-stage { width: 100%; }
  .story-canvas { aspect-ratio: 3 / 4; }
  .plans { grid-template-columns: 1fr; max-width: 460px; margin: 0 auto; }
  .plan.hot { transform: none; }
}
@media (max-width: 560px) {
  .nav-cta .btn.primary { display: none; }
  .hero { padding-top: 120px; }
  .device-wrap { margin-top: 48px; }
  .device-bar .device-title { display: none; }
  .hscroll-track { gap: 14px; }
  .card { padding: 0 24px 24px; min-height: 440px; }
  .card-viz { width: calc(100% + 48px); margin: 0 -24px 20px; height: 210px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal, .reveal-now, .headline .w > span, .device { opacity: 1 !important; transform: none !important; filter: none !important; }
}
