:root {
  --bg: #050507;
  --bg-2: #0a0c12;
  --surface: #0e111a;
  --ink: #f4f5f9;
  --ink-dim: rgba(235, 238, 250, 0.58);
  --ink-faint: rgba(235, 238, 250, 0.34);
  --glow: #5b7fff;
  --glow-soft: #7a96ff;
  --line: rgba(235, 238, 250, 0.09);
  --radius: 22px;
  --maxw: 1180px;
  --font-display: "Clash Display", ui-serif, Georgia, serif;
  --font-body: "Satoshi", ui-sans-serif, system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
em { font-style: normal; color: var(--glow-soft); }

/* Film grain overlay */
.grain {
  position: fixed; inset: 0; z-index: 9999; pointer-events: none; opacity: 0.04;
  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='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── Nav ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px clamp(20px, 5vw, 56px);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  background: linear-gradient(180deg, rgba(5,5,7,0.85), rgba(5,5,7,0));
  transition: background 0.3s;
}
.nav.scrolled { background: rgba(5,5,7,0.9); border-bottom: 1px solid var(--line); }
.nav-logo { display: flex; align-items: center; gap: 11px; font-family: var(--font-display); font-weight: 600; font-size: 19px; letter-spacing: 0.01em; }
.logo-mark {
  position: relative; width: 26px; height: 26px; border-radius: 50%;
  background: radial-gradient(circle at 38% 30%, #1a1f30, #06070b);
  border: 1.5px solid rgba(122,150,255,0.7);
  box-shadow: 0 0 14px rgba(91,127,255,0.5);
  display: grid; place-items: center;
}
.logo-mark.tiny { width: 20px; height: 20px; }
.logo-ring { width: 9px; height: 9px; border-radius: 50%; background: var(--glow-soft); box-shadow: 0 0 8px var(--glow); }
.nav-right { display: flex; align-items: center; gap: 18px; }
.lang-toggle {
  background: none; border: 1px solid var(--line); color: var(--ink-dim);
  font-family: var(--font-body); font-size: 13px; font-weight: 700; letter-spacing: 0.06em;
  padding: 7px 12px; border-radius: 999px; cursor: pointer; transition: 0.25s;
}
.lang-toggle:hover { border-color: rgba(122,150,255,0.5); color: var(--ink); }
.lang-toggle [data-lang-opt].active { color: var(--glow-soft); }
.lang-sep { opacity: 0.4; margin: 0 3px; }
.nav-cta {
  background: var(--glow); color: #fff; font-weight: 700; font-size: 14px;
  padding: 10px 20px; border-radius: 999px; transition: 0.25s;
  box-shadow: 0 6px 24px rgba(91,127,255,0.35);
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: 0 10px 32px rgba(91,127,255,0.5); }

/* ── Hero ── */
.hero {
  position: relative; min-height: 100svh;
  display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: 40px;
  padding: 140px clamp(20px, 5vw, 56px) 80px; max-width: var(--maxw); margin: 0 auto;
}
.hero::before {
  content: ""; position: absolute; top: -10%; left: 50%; transform: translateX(-50%);
  width: 900px; height: 900px; pointer-events: none;
  background: radial-gradient(circle, rgba(91,127,255,0.16), transparent 62%);
  filter: blur(20px);
}
.hero-kicker {
  text-transform: uppercase; letter-spacing: 0.32em; font-size: 12px; font-weight: 700;
  color: var(--glow-soft); margin-bottom: 22px;
}
.hero-title {
  font-family: var(--font-display); font-weight: 600; line-height: 1.02;
  font-size: clamp(42px, 6.4vw, 84px); letter-spacing: -0.02em; margin-bottom: 26px;
}
.hero-title .line { display: block; }
.hero-sub { font-size: clamp(16px, 1.4vw, 19px); color: var(--ink-dim); max-width: 30em; margin-bottom: 34px; }

.store-badges { display: flex; gap: 14px; flex-wrap: wrap; }
.store-badges.center { justify-content: center; }
.badge {
  display: inline-flex; align-items: center; gap: 12px;
  background: var(--surface); border: 1px solid var(--line); color: var(--ink);
  padding: 11px 20px 11px 18px; border-radius: 15px; transition: 0.25s; cursor: pointer;
}
.badge:hover { border-color: rgba(122,150,255,0.55); transform: translateY(-2px); box-shadow: 0 10px 30px rgba(0,0,0,0.4); }
.badge svg { color: var(--ink); }
.badge span { display: flex; flex-direction: column; line-height: 1.15; }
.badge small { font-size: 11px; color: var(--ink-dim); }
.badge strong { font-size: 17px; font-weight: 700; letter-spacing: 0.01em; }

/* Phone mockups */
.hero-phone { position: relative; display: grid; place-items: center; }
.phone {
  position: relative; width: min(280px, 74vw); aspect-ratio: 390/844;
  border-radius: 42px; padding: 9px; background: linear-gradient(155deg, #23283a, #0b0d14 60%);
  box-shadow: 0 40px 90px rgba(0,0,0,0.6), 0 0 0 1px rgba(122,150,255,0.16), inset 0 0 0 1px rgba(255,255,255,0.04);
}
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 34px; }
.phone-notch { position: absolute; top: 16px; left: 50%; transform: translateX(-50%); width: 92px; height: 26px; background: #05060a; border-radius: 999px; z-index: 2; }
.phone.tilt { transform: rotate(-4deg); animation: floaty 7s ease-in-out infinite; }
.phone.small { width: min(210px, 60vw); }
.phone.tilt-l { transform: rotate(-7deg); animation: floaty 8s ease-in-out infinite; }
.phone.tilt-r { transform: rotate(6deg) translateY(26px); animation: floaty 8s ease-in-out infinite 0.6s; }
.phone-glow { position: absolute; inset: -12% ; z-index: -1; background: radial-gradient(circle, rgba(91,127,255,0.28), transparent 60%); filter: blur(24px); }
@keyframes floaty { 0%,100% { translate: 0 0; } 50% { translate: 0 -14px; } }

/* Orbit system (hero background) */
.orbit-system {
  position: absolute; top: 50%; right: 6%; transform: translateY(-50%);
  width: 520px; height: 520px; pointer-events: none; opacity: 0.5; z-index: -1;
}
.dl-orbit { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 460px; height: 460px; opacity: 0.35; pointer-events: none; }
.orbit { position: absolute; inset: 0; margin: auto; border-radius: 50%; border: 1px solid var(--line); }
.orbit-1 { width: 46%; height: 46%; animation: spin 26s linear infinite; }
.orbit-2 { width: 72%; height: 72%; animation: spin 40s linear infinite reverse; }
.orbit-3 { width: 100%; height: 100%; animation: spin 60s linear infinite; }
.node { position: absolute; width: 11px; height: 11px; border-radius: 50%; background: var(--glow-soft); box-shadow: 0 0 12px var(--glow); }
.n1 { top: -5px; left: 50%; } .n2 { bottom: 10%; right: -4px; } .n3 { bottom: 6%; left: 8%; }
.n4 { top: 12%; right: 4%; } .n5 { bottom: -5px; left: 44%; } .n6 { top: 30%; left: -5px; }
.core {
  position: absolute; inset: 0; margin: auto; width: 34%; height: 34%; border-radius: 50%;
  background: radial-gradient(circle at 38% 30%, #181c2c, #06070b);
  border: 1px solid rgba(122,150,255,0.5); box-shadow: 0 0 50px rgba(91,127,255,0.4);
  display: grid; place-items: center;
}
.core.small { width: 26%; height: 26%; }
.core-inner { width: 78%; height: 78%; border-radius: 50%; background: #0a0c14; border: 1px solid rgba(235,238,250,0.08); }
.pulse { position: absolute; inset: 0; margin: auto; width: 34%; height: 34%; border-radius: 50%; border: 1.5px solid var(--glow); animation: pulse 3.6s ease-out infinite; }
@keyframes pulse { 0% { transform: scale(0.8); opacity: 0.6; } 100% { transform: scale(2.4); opacity: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }

.scroll-hint { position: absolute; bottom: 34px; left: 50%; transform: translateX(-50%); width: 26px; height: 42px; border: 1.5px solid var(--ink-faint); border-radius: 999px; }
.scroll-hint span { position: absolute; top: 8px; left: 50%; transform: translateX(-50%); width: 4px; height: 8px; background: var(--glow-soft); border-radius: 999px; animation: scroll 1.8s ease-in-out infinite; }
@keyframes scroll { 0% { opacity: 0; top: 8px; } 40% { opacity: 1; } 80% { opacity: 0; top: 24px; } }

/* ── Sections ── */
.section { position: relative; max-width: var(--maxw); margin: 0 auto; padding: clamp(80px, 12vh, 150px) clamp(20px, 5vw, 56px); }
.section-kicker { text-transform: uppercase; letter-spacing: 0.28em; font-size: 12px; font-weight: 700; color: var(--glow-soft); margin-bottom: 18px; }
.section h2 { font-family: var(--font-display); font-weight: 600; font-size: clamp(30px, 4.2vw, 52px); line-height: 1.08; letter-spacing: -0.02em; margin-bottom: 20px; }
.section-copy p { color: var(--ink-dim); font-size: clamp(15px, 1.3vw, 18px); max-width: 34em; }
.section-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 6vw, 90px); align-items: center; }
.section-grid.flip .section-copy { order: 2; }
.section-head { text-align: center; margin-bottom: 60px; }
.section-head h2 { max-width: 16em; margin: 0 auto; }

.trust-list { list-style: none; margin-top: 30px; display: flex; flex-direction: column; gap: 16px; }
.trust-list li { display: flex; gap: 13px; align-items: flex-start; color: var(--ink); font-size: 15.5px; }
.tick { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; margin-top: 1px; background: rgba(91,127,255,0.14); position: relative; }
.tick::after { content: ""; position: absolute; left: 7px; top: 5px; width: 5px; height: 9px; border: solid var(--glow-soft); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Privacy cipher rail */
.privacy { overflow: hidden; }
.cipher-rail { position: absolute; top: 40px; left: 0; right: 0; overflow: hidden; opacity: 0.10; pointer-events: none; }
.cipher-track { white-space: nowrap; font-family: ui-monospace, monospace; font-size: 15px; color: var(--glow-soft); animation: marquee 40s linear infinite; }
@keyframes marquee { to { transform: translateX(-50%); } }

.terminal { background: #0a0c13; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: 0 30px 70px rgba(0,0,0,0.5); }
.terminal-bar { display: flex; align-items: center; gap: 7px; padding: 13px 16px; border-bottom: 1px solid var(--line); }
.terminal-bar i { width: 11px; height: 11px; border-radius: 50%; background: #2a2f3d; }
.terminal-bar span { margin-left: 10px; font-size: 12px; color: var(--ink-faint); letter-spacing: 0.04em; }
.terminal pre { padding: 22px; font-family: ui-monospace, "SF Mono", monospace; font-size: 13.5px; line-height: 2; overflow-x: auto; }
.c-dim { color: var(--ink-faint); } .c-key { color: #8fa3c9; } .c-cipher { color: #3ddc97; opacity: 0.85; } .c-none { color: #ffb224; } .c-plain { color: var(--glow-soft); }

/* Powers phones */
.phones-duo { position: relative; display: grid; place-items: center; min-height: 480px; }
.phones-duo .phone.small { position: absolute; }
.phones-duo .tilt-l { left: 6%; z-index: 2; }
.phones-duo .tilt-r { right: 6%; }

/* Intros flow */
.flow { display: flex; align-items: center; justify-content: center; gap: 0; margin: 0 auto 70px; max-width: 800px; flex-wrap: wrap; }
.flow-node { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; width: 150px; }
.fn-avatar { width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display); font-weight: 600; font-size: 20px; background: radial-gradient(circle at 38% 30%, #1c2butter, #0b0d14); background: radial-gradient(circle at 38% 30%, #1c2233, #0b0d14); border: 1.5px solid rgba(122,150,255,0.5); box-shadow: 0 0 24px rgba(91,127,255,0.3); }
.flow-node.you .fn-avatar { border-color: var(--glow); color: var(--glow-soft); }
.flow-node.target.locked .fn-avatar { border-style: dashed; border-color: var(--ink-faint); color: var(--ink-faint); box-shadow: none; }
.fn-label { font-size: 13px; color: var(--ink-dim); }
.flow-line { flex: 1; min-width: 50px; height: 2px; background: linear-gradient(90deg, rgba(122,150,255,0.5), rgba(122,150,255,0.15)); position: relative; }
.flow-dot { position: absolute; top: 50%; left: 0; width: 8px; height: 8px; border-radius: 50%; background: var(--glow-soft); box-shadow: 0 0 10px var(--glow); transform: translateY(-50%); animation: travel 3s ease-in-out infinite; }
.l2 .flow-dot { animation-delay: 1.5s; }
@keyframes travel { 0% { left: 0; opacity: 0; } 20% { opacity: 1; } 80% { opacity: 1; } 100% { left: 100%; opacity: 0; } }

/* Download */
.download { text-align: center; overflow: hidden; }
.download h2 { font-size: clamp(34px, 5vw, 62px); }
.download > p { color: var(--ink-dim); font-size: 18px; margin: 16px auto 40px; }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 40px clamp(20px, 5vw, 56px); }
.footer-inner { max-width: var(--maxw); margin: 0 auto; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; color: var(--ink-faint); font-size: 14px; }
.footer-inner nav { margin-left: auto; display: flex; gap: 22px; }
.footer-inner nav a:hover { color: var(--ink); }

/* Reveal animations */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s cubic-bezier(0.2,0.7,0.2,1), transform 0.7s cubic-bezier(0.2,0.7,0.2,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal-load { opacity: 0; transform: translateY(20px); animation: rise 0.8s cubic-bezier(0.2,0.7,0.2,1) forwards; }
.reveal-load.d1 { animation-delay: 0.08s; } .reveal-load.d2 { animation-delay: 0.16s; } .reveal-load.d3 { animation-delay: 0.28s; }
.reveal-load.d4 { animation-delay: 0.4s; } .reveal-load.d5 { animation-delay: 0.3s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ── Responsive ── */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 120px; gap: 50px; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .store-badges { justify-content: center; }
  .orbit-system { display: none; }
  .hero::before { width: 600px; height: 600px; }
  .section-grid, .section-grid.flip { grid-template-columns: 1fr; gap: 44px; }
  .section-grid.flip .section-copy { order: 0; }
  .phones-duo { min-height: 420px; }
  .flow-node { width: 120px; }
}
@media (max-width: 560px) {
  .nav-cta { display: none; }
  .hero-title { font-size: clamp(38px, 11vw, 56px); }
  .flow { gap: 8px; }
  .flow-line { min-width: 30px; }
  .flow-node { width: 90px; }
  .fn-avatar { width: 52px; height: 52px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-inner nav { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
