:root {
  --bg: #070c15;              /* deep space navy, from the app icon */
  --bg-2: #0d1523;
  --ink: #f2f4f8;
  --ink-dim: rgba(242, 244, 248, 0.62);
  --ink-faint: rgba(242, 244, 248, 0.38);
  --accent: #45a4ec;          /* faceted planet blue */
  --accent-2: #e0863c;        /* ring orange */
  --line: rgba(242, 244, 248, 0.1);
  --glass: rgba(255, 255, 255, 0.05);
  --radius: 20px;
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}

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

html { scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
em { font-style: normal; color: var(--accent); }

/* Fixed deep-space backdrop — everything scrolls over it */
#space-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; }

/* Wordmark is black-on-transparent — invert for the dark site */
.wordmark, .preloader-logo, .footer-logo { filter: invert(1); }

/* ---------- Split-word + reveal animations ---------- */
.split-words .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.split-words .w > span {
  display: inline-block;
  transform: translateY(110%);
  transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: calc(var(--wi, 0) * 55ms);
}
.split-words.in .w > span { transform: translateY(0); }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.22, 1, 0.36, 1); }
.reveal.in { opacity: 1; transform: translateY(0); }

/* Idle float — phones and the app icon breathe */
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-12px) rotate(-1.2deg); }
}

/* ---------- Preloader ---------- */
.preloader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--bg);
  display: grid; place-content: center; gap: 22px;
  text-align: center;
  transition: opacity 0.8s ease, visibility 0.8s;
}
.preloader.done { opacity: 0; visibility: hidden; }
.preloader-icon { width: 84px; border-radius: 20px; margin: 0 auto; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5); }
.preloader-logo { width: 160px; margin: 0 auto; }
.preloader-words { display: flex; gap: 18px; justify-content: center; font-family: var(--font-display); font-size: 12px; letter-spacing: 0.32em; text-transform: uppercase; color: var(--ink-faint); }
.preloader-num { font-family: var(--font-display); font-size: 15px; color: var(--accent); letter-spacing: 0.1em; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 32px;
  background: linear-gradient(180deg, rgba(7, 12, 21, 0.85), transparent);
}
.nav-brand { display: flex; align-items: center; gap: 12px; }
.brand-icon { height: 34px; border-radius: 9px; }
/* the PNG is trimmed to the letters, so this is the actual text height */
.nav-brand .wordmark { height: 26px; }
.nav-links { display: flex; gap: 28px; font-size: 13.5px; color: var(--ink-dim); }
.nav-links a { transition: color 0.25s; }
.nav-links a:hover { color: var(--ink); }

/* ---------- CTA pills ---------- */
.cta {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 26px;
  border-radius: 999px;
  background: var(--ink);
  color: #0a0f18;
  font-family: var(--font-display);
  font-weight: 600; font-size: 14.5px; letter-spacing: 0.01em;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), background 0.3s, box-shadow 0.3s, color 0.3s;
}
.cta:hover { transform: translateY(-2px); background: var(--accent); color: #06121f; box-shadow: 0 8px 32px rgba(69, 164, 236, 0.28); }
.cta.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.cta.ghost:hover { border-color: var(--accent); color: var(--accent); box-shadow: none; background: transparent; }
.nav-cta { padding: 10px 20px; font-size: 13px; }
.cta-note { font-size: 12.5px; color: var(--ink-faint); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex; align-items: stretch;
  overflow: hidden;
}
.hero-inner {
  position: relative; z-index: 2;
  width: 100%;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: clamp(90px, 12vh, 140px) clamp(20px, 4vw, 56px) 48px;
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(3rem, 10.5vw, 9.5rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  max-width: 12ch;
}
.hero-foot { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 28px; margin-top: 40px; }
.hero-intro { max-width: 460px; color: var(--ink-dim); font-size: 15.5px; }
.hero-actions { display: flex; flex-direction: column; gap: 10px; }
.hero-cards {
  position: absolute; right: clamp(20px, 4vw, 56px); bottom: 170px;
  display: flex; flex-direction: column; gap: 14px;
}
.glass-card {
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 20px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex; flex-direction: column; gap: 4px;
  min-width: 220px;
}
.gc-label { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-faint); }
.gc-value { font-family: var(--font-display); font-weight: 600; font-size: 17px; }
.gc-sub { font-size: 12.5px; color: var(--accent); }
.gc-bar { height: 4px; border-radius: 4px; background: rgba(255,255,255,0.12); margin-top: 8px; overflow: hidden; }
.gc-bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }

.scroll-hint {
  position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%);
  font-family: var(--font-display); font-size: 11px; letter-spacing: 0.45em;
  color: var(--ink-faint);
  animation: bob 2s ease-in-out infinite;
  transition: opacity 0.4s;
}
@keyframes bob { 0%, 100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(6px); } }

/* ---------- Pinned-phone sections ---------- */
.pin { position: relative; height: 320vh; }
.pin .sticky {
  position: sticky; top: 0;
  height: 100vh; width: 100%;
  overflow: hidden;
  perspective: 1200px; /* transparent: phones float in the fixed starfield */
}
.pin-phone {
  position: absolute; left: 50%; top: 50%;
  /* the 2nd term keeps the ~2.2:1-tall phone inside short viewports */
  width: min(300px, 36vh, 56vw);
  transform: translate(-50%, -50%);
  will-change: transform;
  z-index: 2;
  transform-style: preserve-3d;
}
.pin-float { animation: float 5.4s ease-in-out infinite; transform-style: preserve-3d; }
.phone-3d { position: relative; transform-style: preserve-3d; }
.phone-3d .phone-screen { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.phone-back {
  position: absolute; inset: 0;
  border-radius: 38px;
  transform: rotateY(180deg);
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  /* graphite glass with a soft diagonal sheen */
  background:
    radial-gradient(120% 90% at 20% 0%, rgba(255, 255, 255, 0.06), transparent 45%),
    linear-gradient(160deg, #222b3b 0%, #131a28 48%, #1a2231 100%);
  box-shadow: 0 0 0 6px #04060b;
  display: grid; place-content: center;
  overflow: hidden;
}
/* 3D camera bump: JS builds it inside .phone-3d, protruding past the back face
   (back surface sits at z=-15; the bump stacks out to ~-21, lens rings to ~-22.5) */
.cam-bump {
  position: absolute;
  top: 14px; right: 14px; /* right in front coords = top-left of the back face */
  width: 42%;
  aspect-ratio: 1;
  transform: translateZ(-15.4px);
  transform-style: preserve-3d;
  pointer-events: none;
}
.cam-slab, .cam-face {
  position: absolute;
  inset: 0;
  border-radius: 30%;
}
.cam-slab { background: linear-gradient(155deg, #2a3345, #141b28); }
.cam-face {
  transform: translateZ(-5.5px);
  transform-style: preserve-3d;
  background: linear-gradient(155deg, #1d2636, #0e1522);
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.07);
}
/* raised lens rings: protrude off the bump face, glass recessed inside the ring */
.cam-lens {
  position: absolute;
  width: 34%;
  aspect-ratio: 1;
  border-radius: 50%;
  transform: translateZ(-1.6px);
  background:
    radial-gradient(circle at 36% 32%, rgba(150, 180, 230, 0.4) 0 7%, transparent 13%),
    radial-gradient(circle, #04070e 0 55%, #303c58 58% 76%, #151c2b 78% 100%);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.65), 0 0 0 1.5px #0a0f18;
}
.cam-flash {
  position: absolute;
  top: 63%; left: 63%;
  width: 12%;
  aspect-ratio: 1;
  border-radius: 50%;
  transform: translateZ(-1px);
  background: radial-gradient(circle at 40% 35%, #ffe9c4, #caa25e 60%, #6e5528);
  box-shadow: 0 0 6px rgba(244, 214, 150, 0.35);
}
/* chrome ringed-planet emblem (inline SVG) — mirror-metal, Apple-logo style */
.chrome-logo {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: 44%;
  filter: drop-shadow(0 1px 1px rgba(255, 255, 255, 0.12)) drop-shadow(0 -1px 2px rgba(0, 0, 0, 0.55));
}
.pin-line {
  position: absolute; top: 50%;
  transform: translateY(-50%);
  max-width: 36vw;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.7rem, 4.2vw, 3.8rem);
  letter-spacing: -0.02em;
  line-height: 1.08;
  opacity: 0;
  will-change: opacity, transform;
  z-index: 3;
}
.pin-line.side-left { left: 7vw; }
.pin-line.side-right { right: 7vw; }

/* ---------- Editorial ---------- */
.editorial {
  max-width: 980px; margin: 0 auto;
  padding: clamp(90px, 14vh, 160px) 24px;
  display: flex; flex-direction: column; gap: clamp(48px, 8vh, 84px);
}
.ed-row { display: grid; grid-template-columns: 90px 1fr; gap: 20px; align-items: start; border-top: 1px solid var(--line); padding-top: 34px; }
.ed-num { font-family: var(--font-display); font-size: 13px; letter-spacing: 0.2em; color: var(--accent-2); }
.ed-body h3 { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.5rem, 3.4vw, 2.4rem); letter-spacing: -0.02em; margin-bottom: 12px; }
.ed-body p { color: var(--ink-dim); max-width: 56ch; }

/* ---------- Section titles ---------- */
.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 5.4vw, 4.2rem);
  letter-spacing: -0.025em;
  line-height: 1.05;
  text-align: center;
  max-width: 20ch;
  margin: 0 auto clamp(48px, 7vh, 80px);
}

/* ---------- Phone showcase ---------- */
.showcase { padding: clamp(90px, 14vh, 160px) 24px; }
.phones {
  display: flex; justify-content: center; align-items: flex-end;
  gap: clamp(18px, 3.5vw, 44px);
  flex-wrap: wrap;
}
.phone { width: min(250px, 78vw); text-align: center; }
.phone.is-hero { width: min(290px, 82vw); }
/* ---- realistic device: black bezel + gradient titanium band + side buttons ---- */
.phone-screen {
  aspect-ratio: 9 / 19.5;
  border-radius: 38px;
  /* 6px true-black bezel between the display and the metal band */
  box-shadow: 0 0 0 6px #04060b, 0 34px 80px rgba(0, 0, 0, 0.65);
  display: grid; place-content: center;
  font-family: var(--font-display); font-size: 13px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--ink-faint); text-align: center; line-height: 2;
  overflow: hidden;
  background-color: var(--bg-2);
}
.phone-screen img { width: 100%; height: 100%; object-fit: cover; }
/* titanium band: gradient ring drawn just outside the bezel (masked to a frame).
   Sits on the front rim of the device (translateZ = half thickness in pin sections). */
.phone-3d::after {
  content: "";
  position: absolute;
  inset: -11px;
  border-radius: 49px;
  padding: 5px;
  background: linear-gradient(160deg, #9ba4b6 0%, #4c5464 26%, #272e3d 52%, #596274 74%, #a9b2c4 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  pointer-events: none;
}
.pin .phone-3d::after { transform: translateZ(15px); }
/* device body: the front and back faces are pushed to ±half thickness, and
   JS stacks .phone-slab layers between them so the edge reads as solid metal */
.pin .phone-screen { transform: translateZ(15px); }
.pin .phone-back { transform: rotateY(180deg) translateZ(15px); }
.phone-slab {
  position: absolute;
  inset: -11px;
  border-radius: 49px;
  background: linear-gradient(160deg, #8d96a8 0%, #3f4756 40%, #2a303f 62%, #727b8e 100%);
}
/* physical side buttons: power right, volume pair left, on the mid-edge plane */
.phone-btn {
  position: absolute;
  width: 6px;
  border-radius: 3px;
  background: linear-gradient(180deg, #9aa3b5 0%, #4c5464 50%, #8b94a6 100%);
}
/* moving specular glare on the glass — swept by JS via --glare-x as the phone turns */
.phone-glare {
  position: absolute;
  inset: 0;
  border-radius: 38px;
  pointer-events: none;
  transform: translateZ(15.5px);
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  background: linear-gradient(115deg,
    transparent 38%, rgba(255, 255, 255, 0.16) 47%, rgba(255, 255, 255, 0.04) 53%, transparent 62%);
  background-size: 260% 100%;
  background-position: var(--glare-x, 50%) 0;
}
/* faces darken as they angle away from the light (JS drives --shade) */
.pin .phone-screen::after, .pin .phone-back::after {
  content: "";
  position: absolute;
  inset: 0;
  background: #000;
  opacity: var(--shade, 0);
  pointer-events: none;
}
/* float on the device, not the figure — .reveal animates the figure's transform */
.showcase .phone-3d { animation: float 6s ease-in-out infinite; }
.showcase .phone:nth-child(2) .phone-3d { animation-delay: -2s; }
.showcase .phone:nth-child(3) .phone-3d { animation-delay: -4s; }
.phone figcaption { margin-top: 26px; font-size: 13.5px; color: var(--ink-dim); max-width: 30ch; margin-inline: auto; }

/* shimmer placeholder — swapped out when real screenshots arrive */
.shimmer {
  background: linear-gradient(115deg, #0d1322 30%, #17223a 45%, #0d1322 60%);
  background-size: 240% 100%;
  animation: shimmer 2.6s linear infinite;
}
@keyframes shimmer { to { background-position: -240% 0; } }

/* ---------- Stats ---------- */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  max-width: 1100px; margin: 0 auto;
  padding: clamp(70px, 10vh, 120px) 24px;
  text-align: center;
}
.stat { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--line); padding-top: 26px; }
.stat-num { font-family: var(--font-display); font-weight: 700; font-size: clamp(2.6rem, 6vw, 4.4rem); letter-spacing: -0.03em; color: var(--accent); }
.stat-label { font-size: 13px; color: var(--ink-dim); }

/* ---------- Plans ---------- */
.plans { padding: clamp(90px, 14vh, 160px) 24px; }
.plan-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  max-width: 1060px; margin: 0 auto;
  align-items: stretch;
}
.plan {
  position: relative;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  padding: 34px 30px;
  /* frosted: opaque enough that space objects clearly pass BEHIND the cards */
  background-color: rgba(13, 21, 35, 0.78);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  display: flex; flex-direction: column; gap: 18px;
}
.plan.featured { border-color: rgba(69, 164, 236, 0.45); background-image: linear-gradient(180deg, rgba(69, 164, 236, 0.1), rgba(224, 134, 60, 0.06)); }
.plan-tag {
  position: absolute; top: -12px; left: 30px;
  font-family: var(--font-display); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  background: var(--accent-2); color: #1d0f03;
  padding: 4px 12px; border-radius: 999px;
}
.plan h3 { font-family: var(--font-display); font-size: 19px; font-weight: 600; }
.plan-price { font-family: var(--font-display); font-weight: 700; font-size: 44px; letter-spacing: -0.03em; }
.plan-price span { font-size: 16px; font-weight: 500; color: var(--ink-faint); letter-spacing: 0; }
.plan ul { list-style: none; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.plan li { color: var(--ink-dim); font-size: 14.5px; padding-left: 22px; position: relative; }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 600; }
.plan .cta { align-self: stretch; }

/* ---------- FAQ ---------- */
.faq { padding: clamp(90px, 14vh, 160px) 0; }
.faq-list { max-width: 760px; margin: 0 auto; padding: 0 24px; display: flex; flex-direction: column; gap: 14px; }
.faq-list details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 26px;
  /* frosted like the plan cards — space objects must read as background */
  background-color: rgba(13, 21, 35, 0.78);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.faq-list summary {
  cursor: pointer; list-style: none;
  font-family: var(--font-display); font-weight: 600; font-size: 18px;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-size: 24px; font-weight: 400; color: var(--accent); transition: transform 0.3s; flex-shrink: 0; }
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list details p { margin-top: 14px; color: var(--ink-dim); max-width: 60ch; }

/* ---------- Final CTA ---------- */
.get {
  min-height: 90vh;
  display: grid; place-content: center; gap: 26px;
  text-align: center;
  padding: 80px 24px;
  /* no section-scoped glow — it clips at the section edge as a hard half-circle;
     the fixed space canvas provides the ambient flares instead */
}
.get-icon {
  width: 96px; margin: 0 auto;
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}
.get-icon.in { animation: float 5s ease-in-out infinite; }
.get h2 { font-family: var(--font-display); font-weight: 600; font-size: clamp(2.6rem, 8vw, 6.5rem); letter-spacing: -0.03em; line-height: 1; }
.get p { color: var(--ink-dim); font-size: 17px; }
.get-actions { display: flex; align-items: center; justify-content: center; gap: 26px; flex-wrap: wrap; }
.appstore-badge {
  display: inline-flex; align-items: center; gap: 12px;
  border: 1px solid var(--line); border-radius: 14px;
  padding: 12px 22px;
  transition: border-color 0.3s, transform 0.3s;
  text-align: left;
}
.appstore-badge:hover { border-color: var(--accent); transform: translateY(-2px); }
.appstore-badge span { display: flex; flex-direction: column; line-height: 1.2; font-family: var(--font-display); font-weight: 600; font-size: 17px; }
.appstore-badge small { font-size: 10.5px; font-weight: 400; color: var(--ink-faint); letter-spacing: 0.04em; }
.qr-badge {
  display: block;
  width: 84px; height: 84px;
  padding: 7px;
  border-radius: 14px;
  background: #fff; /* QR needs light quiet zone to scan */
  transition: transform 0.3s;
}
.qr-badge:hover { transform: translateY(-2px); }
.qr-badge img { width: 100%; height: 100%; }

/* ---------- Footer ---------- */
.footer {
  display: flex; align-items: center; justify-content: center;
  padding: 34px clamp(20px, 4vw, 56px);
  border-top: 1px solid var(--line);
  font-size: 12.5px; color: var(--ink-faint);
}

/* ---------- Mobile ---------- */
@media (max-width: 760px) {
  .nav { padding: 16px 18px; }
  .nav-links { display: none; }
  .hero-cards { position: static; flex-direction: row; flex-wrap: wrap; margin-top: 34px; }
  .glass-card { min-width: 180px; flex: 1; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .plan-grid { grid-template-columns: 1fr; max-width: 440px; }
  .ed-row { grid-template-columns: 1fr; gap: 10px; }
  .pin { height: 300vh; }
  .pin-phone { width: 50vw; top: 62%; }
  .pin-line, .pin-line.side-left, .pin-line.side-right {
    left: 50%; right: auto; top: 16%;
    width: 88vw; max-width: 88vw;
    margin-left: -44vw;
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pin-float, .showcase .phone-3d, .get-icon.in, .shimmer { animation: none !important; }
}
