/* Learnimate landing. The page is the app's night sky: one family (Nunito, the app's face), the galaxy as the
   one bold element, real lesson scenes as the proof. */
:root {
  --sky: #04072a;
  --deep: #0d0b33;
  --violet: #6b4eff;
  --violet-edge: #4128b8;
  --lav: #dcd7ff;
  --gold: #ffd36e;
  --ink: #f4f2ff;
  --muted: rgba(220, 215, 255, 0.68);
  --faint: rgba(220, 215, 255, 0.42);
  --line: rgba(255, 255, 255, 0.1);
  --max: 1160px;
}

* { box-sizing: border-box; }
html { background: var(--sky); scroll-behavior: smooth; }
body {
  margin: 0;
  overflow-x: hidden;
  font-family: "Nunito", ui-rounded, system-ui, sans-serif;
  font-weight: 700;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
::selection { background: rgba(107, 78, 255, 0.55); color: #fff; }
:focus-visible { outline: 2px solid #9b82ff; outline-offset: 3px; border-radius: 6px; }
img { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; font-weight: 900; letter-spacing: -0.02em; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
a { color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

#sky { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }

/* ---- Nav */
.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--max); margin: 0 auto; padding: 16px 24px;
}
.nav::before {
  content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 100vw; translate: -50% 0; z-index: -1;
  background: linear-gradient(rgba(4, 7, 42, 0.9), rgba(4, 7, 42, 0));
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  mask: linear-gradient(#000 60%, transparent);
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 900; font-size: 20px; letter-spacing: -0.01em; }
.brand img { border-radius: 10px; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 6px 18px rgba(80, 60, 255, 0.35); }
.nav-cta {
  text-decoration: none; font-weight: 800; font-size: 15px; color: var(--lav);
  padding: 9px 16px; border-radius: 999px; border: 1px solid rgba(220, 215, 255, 0.22);
  transition: background 0.2s, border-color 0.2s;
}
.nav-cta:hover { background: rgba(107, 78, 255, 0.18); border-color: rgba(220, 215, 255, 0.4); }

/* ---- Hero */
.hero, .notify { overflow-x: clip; }
.hero { position: relative; max-width: var(--max); margin: 0 auto; padding: 56px 24px 40px; text-align: center; }
.hero .galaxy { position: absolute; left: 50%; top: 330px; width: min(1000px, 150vw); translate: -50% 0; z-index: -1; }
.hero::before { content: ""; position: absolute; left: 50%; top: 0; width: min(1100px, 120vw); height: 460px; translate: -50% 0; z-index: -1; background: radial-gradient(closest-side, rgba(4, 7, 42, 0.85), transparent); }
.hero-copy { position: relative; }
h1 span { display: block; text-wrap: balance; }
h1 { font-size: clamp(42px, 7.6vw, 96px); line-height: 0.98; letter-spacing: -0.035em; text-shadow: 0 4px 40px rgba(4, 7, 42, 0.8); }
.lede { max-width: 34em; margin: 26px auto 0; font-size: clamp(17px, 1.9vw, 21px); line-height: 1.5; color: var(--muted); }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 22px; margin-top: 34px; }

.store {
  display: inline-flex; align-items: center; gap: 12px;
  height: 58px; padding: 0 24px 0 20px; border-radius: 16px;
  background: #fff; color: #1c1a27; border-bottom: 5px solid #cecbf6;
}
.store svg { width: 24px; height: 28px; }
.store span { display: flex; flex-direction: column; text-align: left; line-height: 1; font-size: 20px; font-weight: 900; }
.store small { font-size: 12px; font-weight: 800; color: rgba(28, 26, 39, 0.6); margin-bottom: 4px; }
.text-link { font-weight: 800; color: var(--lav); text-underline-offset: 5px; text-decoration-color: rgba(220, 215, 255, 0.4); }
.text-link:hover { text-decoration-color: var(--lav); }

/* ---- Phones */
.phones { display: flex; justify-content: center; align-items: flex-end; gap: clamp(14px, 3vw, 40px); margin-top: 64px; }
.phone { position: relative; margin: 0; flex: none; width: 250px; }
.phone.main { width: 300px; }
.phone.side { margin-bottom: 26px; }
.phone.side:first-child { rotate: -4deg; }
.phone.side:last-child { rotate: 4deg; }
.phone.small { width: 210px; }
.phones-note { margin-top: 22px; font-size: 14px; color: var(--faint); }

.screen {
  position: relative; aspect-ratio: 9 / 19.5; overflow: hidden;
  border-radius: 40px; background: #05061a;
  box-shadow: 0 0 0 8px #0b0a1c, 0 0 0 9px rgba(255, 255, 255, 0.14), 0 40px 90px -30px rgba(80, 60, 255, 0.55);
}
.phone.small .screen { border-radius: 32px; box-shadow: 0 0 0 6px #0b0a1c, 0 0 0 7px rgba(255, 255, 255, 0.14), 0 30px 70px -30px rgba(80, 60, 255, 0.5); }
.frames { position: absolute; inset: 0; }
.frames img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 0.45s ease; }
.frames img.on { opacity: 1; }
.island { position: absolute; top: 9px; left: 50%; translate: -50% 0; width: 30%; height: 20px; border-radius: 99px; background: #000; }
.top { position: absolute; inset: 0 0 auto; padding: 36px 16px 0; }
.segs { filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.5)); }
.segs { display: flex; gap: 3px; }
.segs i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, 0.25); }
.segs i.done { background: #fff; }
.segs i.now { background: linear-gradient(90deg, #fff 55%, rgba(255, 255, 255, 0.25) 55%); }
.lesson-title { display: none; margin-top: 8px; font-size: 11px; font-weight: 800; color: rgba(255, 255, 255, 0.75); text-align: left; }
.line {
  position: absolute; inset: auto 0 0; padding: 56px 16px 22px; text-align: left;
  font-size: 14px; line-height: 1.38; font-weight: 800; color: #fff;
  background: linear-gradient(transparent, rgba(5, 6, 26, 0.86) 34%, #05061a);
}
.phone.main .line { font-size: 15.5px; }
.phone.small .line { font-size: 12.5px; padding: 44px 13px 18px; }
.phone.small .top { padding-top: 30px; }

/* ---- Section rhythm */
section:not(.hero) { max-width: var(--max); margin: 0 auto; padding: 120px 24px 0; }
h2 { font-size: clamp(32px, 4.4vw, 54px); line-height: 1.04; letter-spacing: -0.03em; }

/* ---- How it works: a real sequence, so numbered */
.how h2 { text-align: center; }
.steps { list-style: none; margin: 56px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; counter-reset: s; }
.steps li { position: relative; padding-top: 22px; border-top: 2px solid rgba(220, 215, 255, 0.14); }
.steps li::before { content: ""; position: absolute; top: -2px; left: 0; width: 40%; height: 2px; background: linear-gradient(90deg, var(--violet), transparent); }
.step-n {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  background: var(--violet); border-bottom: 3px solid var(--violet-edge); font-weight: 900; font-size: 16px;
}
.steps h3 { margin-top: 18px; font-size: 22px; letter-spacing: -0.015em; }
.steps p { margin-top: 10px; font-size: 16.5px; line-height: 1.55; color: var(--muted); }

/* ---- Reel */
.reel { display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); gap: 48px; align-items: center; max-width: none !important; padding-right: 0 !important; padding-left: max(24px, calc((100vw - var(--max)) / 2 + 24px)) !important; }
.reel-copy { max-width: 340px; }
.reel-copy p { margin-top: 18px; font-size: 18px; line-height: 1.55; color: var(--muted); }
.reel-row { min-width: 0; display: flex; gap: 26px; overflow-x: auto; padding: 24px 24px 40px 12px; scroll-snap-type: x mandatory; scrollbar-width: none; mask: linear-gradient(90deg, #000 80%, transparent); }
.reel-row::-webkit-scrollbar { display: none; }
.reel-row .phone { scroll-snap-align: start; }
.reel-row .phone:nth-child(even) { translate: 0 34px; }

/* ---- Questions */
.ask { text-align: center; max-width: none !important; padding-left: 0 !important; padding-right: 0 !important; }
.ask p { margin-top: 14px; font-size: 18px; color: var(--muted); }
.marquee { overflow: hidden; margin-top: 44px; display: grid; gap: 14px; mask: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.track { display: flex; width: max-content; animation: drift 70s linear infinite; }
.track.reverse { animation-direction: reverse; animation-duration: 80s; }
.track[data-track="2"] { animation-duration: 90s; }
.run { display: flex; gap: 12px; padding-right: 12px; }
.chip {
  white-space: nowrap; padding: 12px 20px; border-radius: 999px;
  font-size: 17px; font-weight: 800; color: var(--lav);
  background: rgba(107, 78, 255, 0.12); border: 1px solid rgba(220, 215, 255, 0.14);
}
.track[data-track="1"] .chip:nth-child(3n) { background: rgba(255, 211, 110, 0.1); color: #ffe7ad; border-color: rgba(255, 211, 110, 0.2); }
@keyframes drift { to { transform: translateX(-50%); } }

/* ---- Sources */
.sources { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.sources-art { display: flex; justify-content: center; padding: 10px 0 40px; }
.sources-art img { width: min(46%, 230px); height: auto; border-radius: 26px; box-shadow: 0 0 0 6px #0b0a1c, 0 0 0 7px rgba(255, 255, 255, 0.14), 0 30px 70px -30px rgba(0, 0, 0, 0.8); }
.sources-art img:first-child { rotate: -5deg; }
.sources-art img:last-child { rotate: 4deg; margin: 70px 0 0 -6%; }
.sources-copy p { margin-top: 18px; font-size: 18px; line-height: 1.6; color: var(--muted); max-width: 30em; }

/* ---- Notify */
.notify { position: relative; text-align: center; padding-top: 110px !important; }
.notify .galaxy { position: relative; width: min(440px, 92vw); margin: 0 auto 8px; }
.notify p { margin-top: 16px; font-size: 18px; color: var(--muted); }
.notify-form { display: flex; gap: 10px; justify-content: center; margin: 34px auto 0; max-width: 480px; }
.notify-form input[type="email"] {
  flex: 1; min-width: 0; height: 56px; padding: 0 20px; border-radius: 16px;
  border: 1px solid rgba(220, 215, 255, 0.24); background: rgba(13, 11, 51, 0.8); color: var(--ink);
  font: inherit; font-size: 17px;
}
.notify-form input::placeholder { color: rgba(220, 215, 255, 0.4); }
.notify-form input:focus { outline: none; border-color: #9b82ff; box-shadow: 0 0 0 3px rgba(107, 78, 255, 0.35); }
.notify-form button {
  height: 56px; padding: 0 24px; border: 0; border-radius: 16px; border-bottom: 5px solid var(--violet-edge);
  background: var(--violet); color: #fff; font: inherit; font-size: 17px; font-weight: 900; cursor: pointer;
  transition: filter 0.15s, translate 0.1s;
}
.notify-form button:hover { filter: brightness(1.1); }
.notify-form button:active { translate: 0 2px; border-bottom-width: 3px; }
.notify-form button:disabled { opacity: 0.6; cursor: default; }
.hp { position: absolute; left: -9999px; }
.form-status { min-height: 1.5em; margin-top: 16px !important; font-size: 16px !important; }
.form-status.ok { color: #8be07a !important; }
.form-status.err { color: #ff9a8a !important; }

/* ---- Footer */
.foot { max-width: var(--max); margin: 140px auto 0; padding: 28px 24px 40px; display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); color: var(--faint); font-size: 14px; }
.foot .brand { font-size: 16px; color: var(--muted); }
.foot .brand img { border-radius: 7px; }

/* ---- Galaxy (shared) */
.galaxy { aspect-ratio: 1; pointer-events: none; user-select: none; }
.galaxy .halo { position: absolute; inset: -12%; border-radius: 50%; background: radial-gradient(closest-side, rgba(122, 77, 255, 0.45), rgba(59, 59, 255, 0.14) 55%, transparent 75%); opacity: 0.6; }
.galaxy .disc { position: absolute; inset: 0; transform: rotate(-24deg) scaleY(0.56); }
.galaxy .glow { position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(closest-side, rgba(122, 77, 255, 0.55), rgba(59, 59, 255, 0.22) 55%, rgba(27, 42, 168, 0) 100%); }
.galaxy .disc img { position: absolute; inset: 0; width: 100%; height: 100%; will-change: transform; }
.galaxy .core { position: absolute; left: 39.5%; top: 39.5%; width: 21%; height: 21%; border-radius: 50%; background: radial-gradient(closest-side, #fff, #fff4c8 35%, rgba(255, 200, 90, 0.6) 70%, rgba(255, 138, 77, 0) 100%); animation: breathe 4s ease-in-out infinite; }
.galaxy .dot { position: absolute; left: 47.3%; top: 47.3%; width: 5.4%; height: 5.4%; border-radius: 50%; background: #fff; }
@keyframes breathe { 50% { opacity: 1; scale: 1.08; } 0%, 100% { opacity: 0.75; scale: 1; } }

/* ---- Small screens */
@media (max-width: 900px) {
  .steps { grid-template-columns: 1fr; gap: 34px; max-width: 520px; margin-inline: auto; }
  .reel { grid-template-columns: minmax(0, 1fr); gap: 30px; padding-right: 24px !important; }
  .reel-copy { justify-self: start; max-width: 520px; }
  .reel-row { margin: 0 -24px; padding-left: 24px; }
  .sources { grid-template-columns: 1fr; gap: 30px; }
  .sources-art { max-width: 440px; width: 100%; margin: 0 auto; }
}
@media (max-width: 640px) {
  .hero { padding-top: 34px; }
  .phones { margin-top: 48px; gap: 0; }
  .phone.main { width: 232px; z-index: 2; }
  .phone.side { width: 172px; margin: 0 -48px 18px; opacity: 0.85; }
  .phone.side .line, .phone.side .lesson-title { visibility: hidden; }
  .phone.small { width: 180px; }
  section:not(.hero) { padding-top: 96px; }
  .notify-form { flex-direction: column; }
  .notify-form input[type="email"] { flex: none; }
  .notify-form button { width: 100%; }
  .chip { font-size: 15px; padding: 10px 16px; }
  .foot { flex-direction: column; gap: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .track, .galaxy .core { animation: none; }
  .frames img { transition: none; }
}

/* ---- Thanks and 404 */
.simple { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 18px; padding: 24px; text-align: center; }
.simple img { border-radius: 22px; box-shadow: 0 10px 40px rgba(80, 60, 255, 0.45); margin-bottom: 8px; }
.simple h1 { font-size: clamp(36px, 6vw, 56px); }
.simple p { font-size: 18px; color: var(--muted); }
