/* ═══════════════════════════════════════════════════════════════
   ChildTales — Storybook Editorial Design System
   ═══════════════════════════════════════════════════════════════ */

/* ─── Design Tokens ─────────────────────────────────────────── */
:root {
  /* Core Palette */
  --indigo: #5B4DC7;
  --indigo-dark: #4A3BA8;
  --indigo-light: #7B6FD6;
  --indigo-soft: #EEEAFC;
  --indigo-glow: rgba(91, 77, 199, 0.35);

  /* Warm Neutrals */
  --cream: #FDF8F3;
  --cream-dark: #F5EDE4;
  --parchment: #FEFCF9;
  --sand: #E8DDD0;
  --linen: #F9F4EE;

  /* Text */
  --ink: #2D2438;
  --ink-light: #5C5168;
  --ink-muted: #8E849A;

  /* Accents */
  --peach: #FFB59E;
  --peach-soft: #FFF0EB;
  --sage: #9ABDA0;
  --sage-soft: #EDF5EE;
  --lavender: #C4B8E8;
  --honey: #FFD066;
  --sky: #8FC8E8;

  /* Typography */
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Outfit', -apple-system, sans-serif;

  /* Spacing Scale */
  --sp-2xs: 4px;
  --sp-xs: 8px;
  --sp-sm: 12px;
  --sp-md: 16px;
  --sp-lg: 24px;
  --sp-xl: 32px;
  --sp-2xl: 48px;
  --sp-3xl: 64px;
  --sp-4xl: 96px;

  /* Radii */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-2xl: 40px;
  --r-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(45, 36, 56, 0.06);
  --shadow-md: 0 8px 24px rgba(45, 36, 56, 0.08);
  --shadow-lg: 0 16px 48px rgba(45, 36, 56, 0.12);
  --shadow-glow: 0 8px 32px var(--indigo-glow);

  /* Transitions */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 150ms;
  --duration-med: 300ms;
  --duration-slow: 500ms;
}

/* ─── Reset & Base ──────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.2;
  color: var(--ink);
}

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

ul, ol {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

button {
  font: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

/* ─── Background Decorations ───────────────────────────────── */
.bg-decorations {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.deco-blob {
  position: absolute;
  opacity: 0.4;
  animation: blobFloat 20s ease-in-out infinite;
}

.blob-1 {
  width: 600px;
  height: 600px;
  top: -200px;
  right: -150px;
  color: var(--indigo-soft);
  animation-delay: 0s;
}

.blob-2 {
  width: 500px;
  height: 500px;
  bottom: 20%;
  left: -200px;
  color: var(--peach-soft);
  animation-delay: -10s;
}

@keyframes blobFloat {
  0%, 100% { transform: translate(0, 0) rotate(0deg) scale(1); }
  33% { transform: translate(30px, -30px) rotate(5deg) scale(1.05); }
  66% { transform: translate(-20px, 20px) rotate(-5deg) scale(0.95); }
}

.grain-overlay {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  opacity: 0.03;
  mix-blend-mode: multiply;
}

/* ─── Reading Progress ─────────────────────────────────────── */
.reading-progress {
  position: fixed;
  left: var(--sp-lg);
  top: 50%;
  transform: translateY(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-sm);
}

.progress-track {
  width: 3px;
  height: 120px;
  background: var(--sand);
  border-radius: var(--r-full);
  overflow: hidden;
}

.progress-fill {
  width: 100%;
  height: 0%;
  background: linear-gradient(180deg, var(--indigo) 0%, var(--indigo-light) 100%);
  border-radius: var(--r-full);
  transition: height var(--duration-fast) linear;
}

.progress-chapters {
  display: flex;
  flex-direction: column;
  gap: var(--sp-xs);
}

.chapter-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--sand);
  transition: all var(--duration-med) var(--ease-out);
}

.chapter-dot.active {
  background: var(--indigo);
  transform: scale(1.25);
  box-shadow: 0 0 12px var(--indigo-glow);
}

@media (max-width: 1200px) {
  .reading-progress { display: none; }
}

/* ─── Navigation ────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--sp-md) var(--sp-xl);
  max-width: 1400px;
  margin: 0 auto;
  background: rgba(253, 248, 243, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--sp-sm);
}

.logo-mark {
  position: relative;
  font-size: 28px;
  line-height: 1;
}

.logo-sparkle {
  position: absolute;
  top: -4px;
  right: -8px;
  font-size: 14px;
  animation: sparkle 2s ease-in-out infinite;
}

@keyframes sparkle {
  0%, 100% { opacity: 1; transform: scale(1) rotate(0deg); }
  50% { opacity: 0.6; transform: scale(0.8) rotate(15deg); }
}

.logo-text {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  color: var(--ink);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--sp-xl);
}

.nav-links a {
  font-weight: 500;
  font-size: 15px;
  color: var(--ink-light);
  transition: color var(--duration-fast) var(--ease-out);
}

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

.nav-cta {
  padding: var(--sp-xs) var(--sp-lg) !important;
  background: var(--indigo);
  color: white !important;
  border-radius: var(--r-full);
  transition: all var(--duration-med) var(--ease-out) !important;
}

.nav-cta:hover {
  background: var(--indigo-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--sp-xs);
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: all var(--duration-med) var(--ease-out);
}

.nav-toggle.open span:first-child {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.open span:last-child {
  transform: rotate(-45deg) translate(5px, -5px);
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    inset: 0;
    flex-direction: column;
    justify-content: center;
    gap: var(--sp-2xl);
    background: var(--cream);
    opacity: 0;
    visibility: hidden;
    transition: all var(--duration-med) var(--ease-out);
  }

  .nav-links.open {
    opacity: 1;
    visibility: visible;
  }

  .nav-links a {
    font-size: 24px;
  }

  .nav-toggle {
    display: flex;
    z-index: 1001;
  }
}

/* ─── Reveal Animations ─────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 100ms; }
.reveal-delay-2 { transition-delay: 200ms; }
.reveal-delay-3 { transition-delay: 300ms; }

.feature-card.reveal,
.theme-card.reveal,
.step.reveal {
  transition-delay: calc(var(--delay, 0) * 100ms);
}

/* ─── Hero Section ──────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: var(--sp-3xl);
  padding: var(--sp-4xl) var(--sp-xl);
  max-width: 1400px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-xs);
  padding: var(--sp-xs) var(--sp-md);
  background: var(--parchment);
  border: 1px solid var(--sand);
  border-radius: var(--r-full);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-light);
  margin-bottom: var(--sp-lg);
}

.badge-icon {
  animation: moonGlow 3s ease-in-out infinite;
}

@keyframes moonGlow {
  0%, 100% { filter: drop-shadow(0 0 4px var(--honey)); }
  50% { filter: drop-shadow(0 0 12px var(--honey)); }
}

.hero-title {
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 500;
  line-height: 1.1;
  margin-bottom: var(--sp-lg);
}

.title-line {
  display: block;
}

.title-accent {
  color: var(--indigo);
  font-style: italic;
  position: relative;
}

.title-accent::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 8px;
  width: 100%;
  height: 12px;
  background: var(--indigo-soft);
  z-index: -1;
  transform: skewX(-5deg);
}

.hero-desc {
  font-size: 18px;
  color: var(--ink-light);
  max-width: 480px;
  margin-bottom: var(--sp-xl);
}

.hero-actions {
  display: flex;
  gap: var(--sp-md);
  flex-wrap: wrap;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-sm);
  padding: var(--sp-md) var(--sp-xl);
  font-weight: 600;
  font-size: 15px;
  border-radius: var(--r-lg);
  transition: all var(--duration-med) var(--ease-out);
}

.btn-icon {
  width: 20px;
  height: 20px;
}

.btn-primary {
  background: var(--ink);
  color: white;
}

.btn-primary:hover {
  background: var(--indigo);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--parchment);
  border: 2px solid var(--sand);
  color: var(--ink);
}

.btn-secondary:hover {
  border-color: var(--indigo);
  color: var(--indigo);
  transform: translateY(-3px);
}

.btn-white {
  background: white;
  color: var(--indigo);
}

.btn-white:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.btn-outline-white {
  background: transparent;
  border: 2px solid rgba(255,255,255,0.4);
  color: white;
}

.btn-outline-white:hover {
  background: rgba(255,255,255,0.15);
  border-color: white;
}

/* Hero Visual - Phone Mockup */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 500px;
}

.phone-mockup {
  position: relative;
  width: 300px;
  background: #1a1a2e;
  border-radius: 44px;
  padding: 14px;
  box-shadow:
    0 50px 100px -20px rgba(45, 36, 56, 0.25),
    0 30px 60px -30px rgba(45, 36, 56, 0.3),
    inset 0 1px 0 rgba(255,255,255,0.1);
  animation: phoneFloat 6s ease-in-out infinite;
}

@keyframes phoneFloat {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-15px) rotate(1deg); }
}

.phone-notch {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 90px;
  height: 26px;
  background: #1a1a2e;
  border-radius: 16px;
  z-index: 10;
}

.phone-notch::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 24px;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background: #333;
  border-radius: 50%;
}

.phone-screen {
  position: relative;
  background: linear-gradient(180deg, #FDF8F3 0%, #FEFCF9 100%);
  border-radius: 34px;
  height: 520px;
  padding: 48px 20px 24px;
  overflow: hidden;
}

.app-header {
  margin-bottom: 20px;
}

.app-greeting {
  display: block;
  font-size: 13px;
  font-weight: 400;
  color: #8E849A;
  margin-bottom: 4px;
  letter-spacing: 0.01em;
}

.app-title {
  display: block;
  font-family: 'Fraunces', Georgia, serif;
  font-size: 24px;
  font-weight: 600;
  color: #2D2438;
  letter-spacing: -0.02em;
}

.story-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.story-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
  padding: 14px;
  background: #FFFFFF;
  border-radius: 16px;
  border: 1px solid #E8DDD0;
  box-shadow: 0 2px 8px rgba(45, 36, 56, 0.04);
}

.story-thumb {
  width: 52px;
  height: 52px;
  min-width: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
}

.story-thumb-1 { background: linear-gradient(135deg, #FFE5D9 0%, #FFCAB8 100%); }
.story-thumb-2 { background: linear-gradient(135deg, #E8EAF6 0%, #C5CAE9 100%); }
.story-thumb-3 { background: linear-gradient(135deg, #E8F5E9 0%, #C8E6C9 100%); }

.story-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}

.story-name {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: #2D2438;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.story-meta {
  display: block;
  font-size: 12px;
  font-weight: 400;
  color: #8E849A;
}

.app-fab {
  position: absolute;
  bottom: 24px;
  right: 20px;
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, #5B4DC7 0%, #4A3BA8 100%);
  color: white;
  font-size: 32px;
  font-weight: 300;
  line-height: 1;
  font-weight: 300;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-glow);
}

/* Floating Elements */
.floating-elements {
  position: absolute;
  inset: -60px;
  pointer-events: none;
}

.float-el {
  position: absolute;
  font-size: 28px;
  animation: gentleFloat 6s ease-in-out infinite;
}

.float-star-1 {
  top: 10%;
  left: 5%;
  animation-delay: 0s;
}

.float-star-2 {
  top: 25%;
  right: 10%;
  animation-delay: 1.5s;
  font-size: 20px;
}

.float-moon {
  bottom: 20%;
  left: 0%;
  animation-delay: 3s;
  font-size: 36px;
}

.float-cloud {
  bottom: 35%;
  right: 5%;
  animation-delay: 4.5s;
  font-size: 24px;
  opacity: 0.7;
}

@keyframes gentleFloat {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-20px) rotate(8deg);
  }
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding: var(--sp-3xl) var(--sp-lg);
  }

  .hero-content {
    order: 1;
  }

  .hero-desc {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual {
    order: 2;
    min-height: 350px;
  }

  .phone-mockup {
    transform: scale(0.85);
  }
}

/* ─── Section Commons ───────────────────────────────────────── */
.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto var(--sp-3xl);
}

.section-tag {
  display: inline-block;
  padding: var(--sp-xs) var(--sp-md);
  background: var(--indigo-soft);
  color: var(--indigo);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--r-full);
  margin-bottom: var(--sp-md);
}

.section-title {
  font-size: clamp(32px, 4vw, 48px);
  margin-bottom: var(--sp-md);
}

.section-desc {
  font-size: 18px;
  color: var(--ink-light);
}

/* ─── Features Section ──────────────────────────────────────── */
.features {
  padding: var(--sp-4xl) var(--sp-xl);
  max-width: 1400px;
  margin: 0 auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--sp-lg);
}

.feature-card {
  position: relative;
  padding: var(--sp-xl);
  background: var(--parchment);
  border: 1px solid var(--sand);
  border-radius: var(--r-xl);
  transition: all var(--duration-med) var(--ease-out);
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 0%, var(--indigo-soft) 100%);
  opacity: 0;
  transition: opacity var(--duration-med) var(--ease-out);
}

.feature-card:hover {
  transform: translateY(-8px);
  border-color: var(--indigo-light);
  box-shadow: var(--shadow-lg);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon-wrap {
  position: relative;
  display: inline-block;
  margin-bottom: var(--sp-lg);
}

.feature-icon {
  position: relative;
  z-index: 1;
  font-size: 48px;
}

.feature-glow {
  position: absolute;
  inset: -10px;
  background: radial-gradient(circle, var(--honey) 0%, transparent 70%);
  opacity: 0.3;
  filter: blur(12px);
  animation: glowPulse 3s ease-in-out infinite;
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.1); }
}

.feature-card h3 {
  position: relative;
  font-family: var(--font-body);
  font-size: 20px;
  font-weight: 600;
  margin-bottom: var(--sp-sm);
}

.feature-card p {
  position: relative;
  font-size: 15px;
  color: var(--ink-light);
  line-height: 1.6;
}

/* ─── How It Works ──────────────────────────────────────────── */
.how-it-works {
  padding: var(--sp-4xl) var(--sp-xl);
  background: linear-gradient(180deg, var(--cream) 0%, var(--indigo-soft) 50%, var(--cream) 100%);
}

.how-it-works .section-header,
.how-it-works .steps-container {
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.steps-container {
  position: relative;
}

.steps-line {
  position: absolute;
  left: 39px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, var(--indigo) 0%, var(--lavender) 100%);
  opacity: 0.3;
}

.step {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: var(--sp-xl);
  align-items: center;
  padding: var(--sp-xl) 0;
}

.step-number {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--indigo) 0%, var(--indigo-dark) 100%);
  color: white;
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 600;
  border-radius: 50%;
  box-shadow: var(--shadow-glow);
  z-index: 1;
}

.step-content h3 {
  font-family: var(--font-body);
  font-size: 24px;
  font-weight: 600;
  margin-bottom: var(--sp-sm);
}

.step-content p {
  font-size: 16px;
  color: var(--ink-light);
  max-width: 400px;
}

.step-visual {
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-card {
  width: 100%;
  height: 100%;
  background: var(--parchment);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-xs);
  font-size: 32px;
  animation: cardFloat 4s ease-in-out infinite;
}

.step-card.generating {
  position: relative;
  overflow: hidden;
}

.magic-particles {
  display: flex;
  gap: var(--sp-sm);
}

.magic-particles span {
  animation: particlePop 1.5s ease-in-out infinite;
}

.magic-particles span:nth-child(2) { animation-delay: 0.3s; }
.magic-particles span:nth-child(3) { animation-delay: 0.6s; }

@keyframes particlePop {
  0%, 100% { transform: scale(1) translateY(0); opacity: 1; }
  50% { transform: scale(1.3) translateY(-10px); opacity: 0.7; }
}

.step-card.reading {
  position: relative;
}

.step-card.reading span {
  font-size: 48px;
}

.zzz {
  position: absolute;
  top: 0;
  right: 10px;
  font-size: 18px;
  animation: zzz 2s ease-in-out infinite;
}

@keyframes zzz {
  0%, 100% { opacity: 0; transform: translateY(0) scale(0.8); }
  50% { opacity: 1; transform: translateY(-15px) scale(1); }
}

@keyframes cardFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@media (max-width: 768px) {
  .step {
    grid-template-columns: 60px 1fr;
    gap: var(--sp-lg);
  }

  .step-number {
    width: 60px;
    height: 60px;
    font-size: 24px;
  }

  .steps-line {
    left: 29px;
  }

  .step-visual {
    display: none;
  }
}

/* ─── Themes Section ────────────────────────────────────────── */
.themes {
  padding: var(--sp-4xl) var(--sp-xl);
  overflow: hidden;
}

.themes .section-header {
  max-width: 1400px;
}

.themes-carousel {
  max-width: 100%;
  overflow-x: auto;
  padding: var(--sp-lg) 0;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.themes-carousel::-webkit-scrollbar {
  display: none;
}

.theme-track {
  display: flex;
  gap: var(--sp-lg);
  padding: 0 var(--sp-xl);
  width: max-content;
}

.theme-card {
  flex-shrink: 0;
  width: 180px;
  padding: var(--sp-xl);
  border-radius: var(--r-xl);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-sm);
  cursor: pointer;
  transition: all var(--duration-med) var(--ease-bounce);
}

.theme-card:hover {
  transform: translateY(-12px) scale(1.05);
}

.theme-emoji {
  font-size: 56px;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.15));
  transition: transform var(--duration-med) var(--ease-bounce);
}

.theme-card:hover .theme-emoji {
  transform: scale(1.15) rotate(-5deg);
}

.theme-name {
  font-weight: 600;
  font-size: 16px;
  color: var(--ink);
}

.theme-count {
  font-size: 13px;
  color: var(--ink-muted);
}

.theme-dino { background: linear-gradient(135deg, #E8F5E9 0%, #A5D6A7 100%); }
.theme-space { background: linear-gradient(135deg, #E8EAF6 0%, #9FA8DA 100%); }
.theme-forest { background: linear-gradient(135deg, #FFF3E0 0%, #FFCC80 100%); }
.theme-ocean { background: linear-gradient(135deg, #E1F5FE 0%, #81D4FA 100%); }
.theme-magic { background: linear-gradient(135deg, #F3E5F5 0%, #CE93D8 100%); }
.theme-animals { background: linear-gradient(135deg, #FBE9E7 0%, #FFAB91 100%); }

/* ─── CTA Section ───────────────────────────────────────────── */
.cta {
  padding: var(--sp-4xl) var(--sp-xl);
  background: linear-gradient(135deg, var(--indigo) 0%, var(--indigo-dark) 100%);
  position: relative;
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 0l30 30-30 30L0 30z' fill='%23ffffff' fill-opacity='0.03'/%3E%3C/svg%3E");
  background-size: 60px 60px;
}

.cta-content {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.cta-decoration {
  display: flex;
  justify-content: center;
  gap: var(--sp-lg);
  margin-bottom: var(--sp-xl);
  font-size: 40px;
}

.cta-decoration span {
  animation: ctaBounce 2s ease-in-out infinite;
}

.cta-decoration span:nth-child(2) { animation-delay: 0.2s; }
.cta-decoration span:nth-child(3) { animation-delay: 0.4s; }

@keyframes ctaBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.cta h2 {
  color: white;
  font-size: clamp(28px, 4vw, 40px);
  margin-bottom: var(--sp-md);
}

.cta p {
  color: rgba(255,255,255,0.85);
  font-size: 18px;
  margin-bottom: var(--sp-xl);
}

.cta-buttons {
  display: flex;
  gap: var(--sp-md);
  justify-content: center;
  flex-wrap: wrap;
}

/* ─── Privacy Section ───────────────────────────────────────── */
.privacy {
  padding: var(--sp-4xl) var(--sp-xl);
  background: var(--linen);
}

.privacy-header {
  text-align: center;
  margin-bottom: var(--sp-3xl);
}

.privacy-date {
  color: var(--ink-muted);
  font-size: 14px;
}

.privacy-content {
  max-width: 800px;
  margin: 0 auto;
}

.privacy-section {
  background: var(--parchment);
  padding: var(--sp-xl);
  border-radius: var(--r-lg);
  margin-bottom: var(--sp-lg);
  border: 1px solid var(--sand);
}

.privacy-section h3 {
  font-family: var(--font-body);
  font-size: 20px;
  font-weight: 600;
  margin-bottom: var(--sp-md);
  color: var(--ink);
}

.privacy-section h4 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  margin: var(--sp-lg) 0 var(--sp-sm);
  color: var(--ink-light);
}

.privacy-section p {
  color: var(--ink-light);
  margin-bottom: var(--sp-md);
}

.privacy-section ul {
  list-style: disc;
  padding-left: var(--sp-xl);
  color: var(--ink-light);
}

.privacy-section li {
  margin-bottom: var(--sp-sm);
}

.privacy-section li strong {
  color: var(--ink);
}

/* ─── Footer ────────────────────────────────────────────────── */
.footer {
  background: var(--ink);
  color: var(--sand);
  padding: var(--sp-3xl) var(--sp-xl) var(--sp-xl);
}

.footer-main {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--sp-3xl);
  max-width: 1200px;
  margin: 0 auto var(--sp-2xl);
  flex-wrap: wrap;
}

.footer-brand .logo-text {
  color: white;
}

.footer-brand p {
  margin-top: var(--sp-md);
  font-size: 15px;
  color: var(--ink-muted);
  max-width: 280px;
}

.footer-nav {
  display: flex;
  gap: var(--sp-3xl);
}

.footer-col h4 {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: white;
  margin-bottom: var(--sp-md);
}

.footer-col a {
  display: block;
  font-size: 15px;
  color: var(--ink-muted);
  padding: var(--sp-xs) 0;
  transition: color var(--duration-fast) var(--ease-out);
}

.footer-col a:hover {
  color: white;
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: var(--sp-xl);
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
  font-size: 14px;
  color: var(--ink-muted);
}

@media (max-width: 600px) {
  .footer-main {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-brand p {
    max-width: none;
  }

  .footer-nav {
    gap: var(--sp-2xl);
  }
}

/* ─── Privacy Page ──────────────────────────────────────────── */
.privacy-page {
  background: var(--linen);
}

.privacy-page .nav {
  background: rgba(249, 244, 238, 0.9);
}

.privacy-main {
  max-width: 800px;
  margin: 0 auto;
  padding: var(--sp-3xl) var(--sp-xl) var(--sp-4xl);
}

.privacy-main .privacy-header {
  text-align: left;
  margin-bottom: var(--sp-2xl);
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-xs);
  font-size: 14px;
  font-weight: 500;
  color: var(--indigo);
  margin-bottom: var(--sp-lg);
  transition: color var(--duration-fast) var(--ease-out);
}

.back-link:hover {
  color: var(--indigo-dark);
}

.privacy-main h1 {
  font-size: clamp(36px, 5vw, 48px);
  margin-bottom: var(--sp-sm);
}

.privacy-main .privacy-content {
  max-width: none;
}

.privacy-main .privacy-section {
  margin-bottom: var(--sp-lg);
}

.privacy-main .privacy-section h2 {
  font-family: var(--font-body);
  font-size: 22px;
  font-weight: 600;
  margin-bottom: var(--sp-md);
  color: var(--ink);
}

.privacy-main .privacy-section h3 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  margin: var(--sp-lg) 0 var(--sp-sm);
  color: var(--ink-light);
}

/* ─── Utilities ─────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
