:root {
  --bg: #fdfcf7;
  --surface: #ffffff;
  --text: #1c2333;
  --muted: #4b556c;
  --primary: #2f6fed;
  --secondary: #0fa968;
  --accent: #f5a524;
  --border: #e3e8f2;
  --shadow: rgba(28,35,51,0.12);
  --prompt-bg: #f0f4ff;
  --reflect-bg: #f2fbf6;
  --hint-bg: #fff7ea;
  --hero-bg: radial-gradient(circle at 8% 18%, rgba(90,158,255,0.4), transparent 55%), radial-gradient(circle at 92% 12%, rgba(44,211,255,0.28), transparent 50%), radial-gradient(circle at 50% 78%, rgba(181,210,255,0.5), transparent 60%);
  --glass-border: rgba(255,255,255,0.6);
  --glass-highlight: rgba(255,255,255,0.8);
  --glass-shadow: rgba(48,96,196,0.28);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

body.home {
  background: linear-gradient(150deg, rgba(236,244,255,0.95) 0%, rgba(226,244,255,0.95) 45%, rgba(214,229,255,0.95) 100%);
  --primary: #3369ff;
  --secondary: #22d1ee;
  --muted: rgba(16,38,84,0.7);
}

h1, h2, h3, h4 {
  font-family: 'Poppins', 'Segoe UI', system-ui, sans-serif;
  letter-spacing: -0.01em;
  color: var(--text);
  margin: 0 0 12px;
}

p {
  margin: 0 0 16px;
}

a {
  color: inherit;
  text-decoration: none;
}

.hero {
  background: linear-gradient(135deg, rgba(47,111,237,0.12), rgba(15,169,104,0.12));
  padding: 72px 24px 56px;
}

.top-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1080px;
  margin: 0 auto 48px;
  color: var(--muted);
  font-size: 0.95rem;
}

.nav-links a {
  margin-left: 24px;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.brand {
  font-weight: 600;
  color: var(--text);
}

.hero__content {
  max-width: 720px;
  margin: 0 auto;
}

.hero__content h1 {
  font-size: clamp(2.6rem, 5vw, 3.1rem);
  margin-bottom: 16px;
}

.hero__content p {
  font-size: 1.08rem;
  color: var(--muted);
}

.hero__actions {
  margin-top: 32px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.home .hero {
  position: relative;
  padding: 104px 24px 96px;
  overflow: hidden;
  background: linear-gradient(135deg, #94c9ff 0%, #5b89ff 45%, #1f3b85 100%);
}

.home .hero__backdrop {
  position: absolute;
  inset: 0;
  background: var(--hero-bg);
  opacity: 0.5;
}

.home .hero__shell {
  position: relative;
  max-width: 1160px;
  margin: 0 auto;
  backdrop-filter: blur(24px);
  border-radius: 44px;
  padding: 48px 52px 64px;
  border: 1px solid rgba(255,255,255,0.6);
  background: rgba(255,255,255,0.92);
  box-shadow: 0 60px 160px -90px rgba(34,78,180,0.35);
}

.home .top-nav {
  padding-bottom: 36px;
  margin-bottom: 36px;
  border-bottom: 1px solid rgba(54,132,255,0.16);
  color: rgba(20,46,96,0.78);
}

.home .brand {
  color: #14305c;
  letter-spacing: 0.03em;
}

.home .nav-links a {
  color: rgba(20,46,96,0.78);
}

.home .nav-links a:hover {
  color: #3369ff;
  text-decoration: none;
}

.home .hero__layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 48px;
  align-items: center;
}

.home .hero__content {
  margin: 0;
}

.home .hero__copy h1 {
  color: #0f2349;
  text-shadow: 0 14px 32px rgba(59,110,210,0.22);
}

.home .hero__copy p {
  color: rgba(16,38,84,0.74);
}

.home .hero__actions .cta {
  background: linear-gradient(135deg, #22d1ee, #3369ff);
  color: #fff;
  box-shadow: 0 24px 45px -25px rgba(43,112,255,0.6);
  font-size: 1.08rem;
}

.home .hero__actions .cta:hover {
  box-shadow: 0 28px 60px -26px rgba(43,112,255,0.72);
}

.home .hero__actions .ghost {
  border: 2px solid rgba(51,105,255,0.45);
  color: #1f3b85;
  background: rgba(255,255,255,0.82);
  box-shadow: 0 14px 32px -24px rgba(38,102,226,0.4);
}

.home .hero__actions .ghost:hover {
  background: rgba(255,255,255,0.95);
}

.home .checkout-status {
  color: rgba(16,38,84,0.6);
}

.home .hero__visual {
  position: relative;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1200px;
}

.home .hero__glass {
  position: absolute;
  width: clamp(200px, 32vw, 320px);
  height: clamp(200px, 32vw, 320px);
  border-radius: 30% 70% 60% 40% / 40% 60% 30% 70%;
  background: linear-gradient(145deg, rgba(255,255,255,0.75), rgba(167,206,255,0.32));
  border: 1px solid rgba(255,255,255,0.75);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.45), 0 30px 60px -24px rgba(63,116,226,0.4);
  backdrop-filter: blur(20px);
  transform: rotateX(16deg) rotateY(-12deg);
  animation: float 10s ease-in-out infinite;
}

.home .hero__glass--primary {
  animation-delay: -2s;
}

.home .hero__glass--secondary {
  width: clamp(180px, 28vw, 260px);
  height: clamp(180px, 28vw, 260px);
  background: linear-gradient(125deg, rgba(255,255,255,0.78), rgba(113,219,255,0.4));
  transform: translate3d(60px, 20px, -60px) rotateX(20deg) rotateY(8deg);
  animation-delay: -6s;
  opacity: 0.9;
}

.home .hero__glimmer {
  position: absolute;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.85), transparent 65%);
  filter: blur(0.6px);
  opacity: 0.8;
  animation: pulse 6s ease-in-out infinite;
}

.home .hero__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.5;
}

.home .hero__blob--one {
  top: -140px;
  right: -60px;
  width: 360px;
  height: 360px;
  background: rgba(133,182,255,0.55);
}

.home .hero__blob--two {
  bottom: -160px;
  left: -90px;
  width: 420px;
  height: 420px;
  background: rgba(84,210,255,0.45);
}

.home .hero__blob--three {
  top: 28%;
  left: 45%;
  width: 300px;
  height: 300px;
  background: rgba(190,224,255,0.5);
}

@keyframes float {
  0%, 100% {
    transform: translate3d(-20px, -18px, 0) rotateX(16deg) rotateY(-12deg);
  }
  50% {
    transform: translate3d(20px, 24px, 30px) rotateX(14deg) rotateY(-6deg);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: translate3d(-40px, -10px, 0) scale(0.85);
    opacity: 0.65;
  }
  40% {
    transform: translate3d(30px, 36px, 0) scale(1.05);
    opacity: 0.9;
  }
  70% {
    transform: translate3d(16px, -12px, 0) scale(0.95);
    opacity: 0.5;
  }
}

.home .section {
  position: relative;
}

.home .section::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(120,182,255,0.12), transparent 40%);
  opacity: 0.65;
  z-index: -1;
}

.home .section.section--alt {
  background: rgba(255,255,255,0.94);
  border-radius: 36px;
  margin: 0 24px;
  border: 1px solid rgba(126,178,255,0.2);
  box-shadow: 0 38px 90px -68px rgba(62,116,214,0.32);
}

.home .section--glow {
  background: linear-gradient(135deg, rgba(255,255,255,0.96), rgba(223,239,255,0.86));
  border-radius: 40px;
  margin: 0 24px;
  border: 1px solid rgba(126,178,255,0.26);
  box-shadow: 0 52px 140px -82px rgba(59,120,220,0.34);
}

.home .testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 28px;
}

.home .testimonial-card {
  position: relative;
  padding: 32px 28px 36px;
  border-radius: 28px;
  background: linear-gradient(160deg, rgba(255,255,255,0.92), rgba(227,239,255,0.88));
  border: 1px solid rgba(126,178,255,0.32);
  box-shadow: 0 40px 90px -70px rgba(53,112,214,0.32);
  backdrop-filter: blur(12px);
}

.home .testimonial-card__avatar {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #22d1ee, #3369ff);
  color: #fff;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 18px;
}

.home .testimonial-card__quote {
  color: rgba(16,38,84,0.9);
  font-size: 1.05rem;
  margin-bottom: 20px;
}

.home .testimonial-card__name {
  font-weight: 600;
  color: rgba(37,90,180,0.75);
}

.home .module-card {
  background: rgba(255,255,255,0.95);
  border-color: rgba(126,178,255,0.3);
  box-shadow: 0 32px 70px -52px rgba(60,118,216,0.28);
}

.home .module-card:hover {
  box-shadow: 0 34px 74px -50px rgba(60,118,216,0.36);
}

.home .feature-card {
  background: linear-gradient(160deg, rgba(244,250,255,0.92), rgba(224,239,255,0.9));
  border-color: rgba(126,178,255,0.26);
  box-shadow: 0 30px 80px -60px rgba(63,116,214,0.28);
}

.home .footer {
  background: linear-gradient(135deg, rgba(232,242,255,0.95), rgba(212,232,255,0.95));
  border-color: rgba(126,178,255,0.28);
  color: rgba(16,38,84,0.72);
}

.home .faq {
  max-width: 840px;
  margin: 0 auto;
}

.home .faq-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  margin-top: 24px;
  text-align: left;
}

.home .faq-item {
  background: linear-gradient(160deg, rgba(255,255,255,0.92), rgba(224,239,255,0.88));
  border-radius: 18px;
  padding: 24px;
  border: 1px solid rgba(126,178,255,0.28);
  box-shadow: 0 32px 80px -64px rgba(63,116,214,0.3);
}

.home .faq-item h5 {
  margin: 0 0 12px;
  font-size: 1.05rem;
  color: #3369ff;
}

.home .faq-item p {
  margin: 0;
  color: rgba(16,38,84,0.72);
}

.home .footer h4 {
  color: #3369ff;
}

@media (max-width: 720px) {
  .home .hero {
    padding: 72px 18px 64px;
  }

  .home .hero__shell {
    padding: 28px 24px 48px;
  }

  .home .top-nav {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }

  .home .hero__layout {
    gap: 32px;
  }

  .home .hero__visual {
    min-height: 260px;
  }

  .home .section.section--alt,
  .home .section--glow {
    margin: 0;
    border-radius: 28px;
  }

  .home .testimonial-card,
  .home .faq-item {
    padding: 24px;
  }
}

.cta,
.ghost {
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.cta {
  border: none;
  background: var(--primary);
  color: #fff;
  box-shadow: 0 14px 28px -18px rgba(47,111,237,0.9);
}

.cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -16px rgba(47,111,237,0.7);
}

.ghost {
  border: 2px solid var(--primary);
  color: var(--primary);
  background: transparent;
}

.ghost:hover {
  transform: translateY(-2px);
  background: rgba(47,111,237,0.08);
}

.checkout-status {
  margin-top: 16px;
  min-height: 1.2em;
  color: var(--muted);
  font-size: 0.95rem;
}

.checkout-status--error {
  color: #d64545;
  font-weight: 600;
}

.checkout-status--success {
  color: var(--secondary);
  font-weight: 600;
}

.section {
  padding: 88px 24px;
}

.section--alt {
  background: var(--surface);
}

.section h2 {
  font-size: clamp(2rem, 4vw, 2.4rem);
  margin-bottom: 16px;
}

.lead {
  max-width: 640px;
  color: var(--muted);
  margin-bottom: 48px;
}

.module-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.module-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 18px 36px -28px var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.module-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 42px -24px rgba(28,35,51,0.22);
}

.module-card__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  font-weight: 600;
  color: #0d1c37;
}

.module-card__link::after {
  content: "→";
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--prompt-bg);
  border-radius: 18px;
  padding: 28px;
  border: 1px solid rgba(47,111,237,0.2);
}

.footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 56px 24px;
  display: grid;
  gap: 24px;
  justify-items: center;
  text-align: center;
  color: var(--muted);
}

.footer--compact {
  padding: 32px 24px;
}

.footer__legal {
  font-size: 0.85rem;
}

body.module {
  background: var(--bg);
}

.module-hero {
  padding: 64px 24px 48px;
  max-width: 820px;
  margin: 0 auto;
  text-align: left;
}

.module-back {
  display: inline-flex;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 16px;
}

.module-main {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 24px 88px;
}

.lesson {
  background: var(--surface);
  border-radius: 24px;
  border: 1px solid var(--border);
  padding: 32px;
  margin-bottom: 32px;
  box-shadow: 0 16px 40px -30px rgba(28,35,51,0.45);
}

.lesson-intro {
  color: var(--muted);
}

.prompt-card {
  background: var(--prompt-bg);
  border-radius: 20px;
  padding: 24px;
  border: 1px solid rgba(47,111,237,0.25);
  margin: 24px 0;
}

.prompt-card__title {
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 12px;
}

.prompt-card pre {
  background: transparent;
  border-radius: 12px;
  padding: 16px;
  margin: 0;
  overflow-x: auto;
  font-family: 'Source Code Pro', 'Courier New', monospace;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--text);
  border: 1px dashed rgba(47,111,237,0.3);
}

.prompt-card__button {
  margin-top: 16px;
  padding: 10px 18px;
  border-radius: 999px;
  border: none;
  background: var(--secondary);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.prompt-card__button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px -20px rgba(15,169,104,0.7);
}

.reflect-card {
  background: var(--reflect-bg);
  border-radius: 16px;
  padding: 20px 24px;
  border: 1px solid rgba(15,169,104,0.2);
}

.hint {
  margin-top: 20px;
  background: var(--hint-bg);
  padding: 16px 20px;
  border-radius: 14px;
  border: 1px solid rgba(245,165,36,0.35);
}

.module-nav {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 48px;
}

.module-nav .cta,
.module-nav .ghost {
  flex: 1 1 auto;
  text-align: center;
}

.success-hero,
.locked-hero {
  padding: 72px 24px 32px;
  text-align: center;
}

.success-main,
.locked-main {
  max-width: 520px;
  margin: 0 auto;
  padding: 0 24px 96px;
}

.access-card {
  background: var(--surface);
  border-radius: 24px;
  border: 1px solid var(--border);
  box-shadow: 0 18px 38px -28px rgba(28,35,51,0.4);
  padding: 32px;
  margin-top: 24px;
  text-align: left;
}

.access-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 16px;
}

.access-form label {
  font-weight: 600;
  color: var(--text);
}

.access-form input[type="email"] {
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--border);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.access-form input[type="email"]:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(15,169,104,0.18);
}

.access-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.access-note {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--muted);
}

.locked-card {
  margin-top: 24px;
  background: var(--surface);
  border-radius: 20px;
  border: 1px solid rgba(47,111,237,0.2);
  padding: 28px;
  box-shadow: 0 18px 34px -26px rgba(28,35,51,0.35);
}

.locked-card p {
  margin-bottom: 12px;
  color: var(--muted);
}

.locked-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 20px;
  flex-wrap: wrap;
}

@media (max-width: 720px) {
  .top-nav {
    flex-direction: column;
    gap: 12px;
  }

  .nav-links a {
    margin: 0 12px;
  }

  .hero__content {
    text-align: center;
  }

  .section {
    padding: 64px 20px;
  }

  .module-main {
    padding: 0 20px 64px;
  }

  .module-nav {
    flex-direction: column;
  }

  .access-card {
    padding: 24px;
  }
}
