/* Kids' Library Apps — modern playground design system */
:root {
  --teal: #008577;
  --teal-dark: #00574B;
  --teal-deep: #004852;
  --magenta: #D81B60;
  --mint: #C4DAD8;
  --mint-soft: #e8f3f1;
  --sun: #FFCF1E;
  --orange: #edba1f;
  --surface: #fdfefd;
  --surface-muted: #ECEFF1;
  --ink: #1a2e2c;
  --ink-soft: #3d5652;
  --white: #ffffff;
  --shadow: 0 12px 40px rgba(0, 87, 75, 0.12);
  --shadow-soft: 0 6px 20px rgba(0, 87, 75, 0.08);
  --radius: 24px;
  --radius-sm: 14px;
  --max: 1100px;
  --font-display: "Nunito", "Segoe UI", sans-serif;
  --font-body: "Quicksand", "Segoe UI", sans-serif;
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

  --theme-animals: #2e9b6a;
  --theme-birds: #3aa0c8;
  --theme-transport: #e0891a;
  --theme-math: #d4a017;
  --theme-abc: #D81B60;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background:
    radial-gradient(ellipse 80% 50% at 10% -10%, rgba(255, 207, 30, 0.28), transparent 55%),
    radial-gradient(ellipse 70% 45% at 95% 5%, rgba(216, 27, 96, 0.12), transparent 50%),
    linear-gradient(180deg, var(--mint) 0%, var(--mint-soft) 28%, var(--surface) 55%, var(--surface-muted) 100%);
  background-attachment: fixed;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--teal);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--magenta);
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.15;
  color: var(--teal-deep);
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.25rem; }

p {
  margin: 0 0 1em;
  color: var(--ink-soft);
}

ul {
  margin: 0 0 1em;
  padding-left: 1.2em;
  color: var(--ink-soft);
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Floating playground décor */
.playground-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.playground-bg .blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
  opacity: 0.45;
  animation: float-blob 12s ease-in-out infinite;
}

.playground-bg .blob-1 {
  width: 220px;
  height: 220px;
  background: rgba(255, 207, 30, 0.35);
  top: 12%;
  left: -40px;
}

.playground-bg .blob-2 {
  width: 180px;
  height: 180px;
  background: rgba(216, 27, 96, 0.18);
  top: 40%;
  right: -30px;
  animation-delay: -4s;
}

.playground-bg .blob-3 {
  width: 140px;
  height: 140px;
  background: rgba(0, 133, 119, 0.22);
  bottom: 10%;
  left: 20%;
  animation-delay: -7s;
}

.playground-bg .star-deco {
  position: absolute;
  width: 18px;
  height: 18px;
  background: var(--sun);
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  opacity: 0.55;
  animation: twinkle 3.5s ease-in-out infinite;
}

.playground-bg .star-deco:nth-child(4) { top: 18%; left: 22%; animation-delay: 0s; }
.playground-bg .star-deco:nth-child(5) { top: 28%; right: 18%; animation-delay: 1s; width: 14px; height: 14px; }
.playground-bg .star-deco:nth-child(6) { bottom: 22%; right: 30%; animation-delay: 2s; width: 12px; height: 12px; }

@keyframes float-blob {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-28px) scale(1.05); }
}

@keyframes twinkle {
  0%, 100% { transform: scale(1) rotate(0deg); opacity: 0.4; }
  50% { transform: scale(1.25) rotate(18deg); opacity: 0.85; }
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(14px);
  background: rgba(253, 254, 253, 0.82);
  border-bottom: 2px solid rgba(0, 133, 119, 0.08);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--teal-dark);
  letter-spacing: -0.02em;
}

.brand:hover { color: var(--teal); }

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  object-fit: contain;
  background: var(--white);
  box-shadow: 0 6px 16px rgba(0, 87, 75, 0.25);
  flex-shrink: 0;
  padding: 4px;
}

.nav-toggle {
  display: none;
  border: 0;
  background: var(--mint-soft);
  color: var(--teal-dark);
  width: 44px;
  height: 44px;
  border-radius: 12px;
  font-size: 1.4rem;
  cursor: pointer;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.site-nav a {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink-soft);
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s var(--ease-spring);
}

.site-nav a:hover,
.site-nav a.is-active {
  background: rgba(0, 133, 119, 0.12);
  color: var(--teal-dark);
}

.site-nav a:hover { transform: translateY(-2px); }

.lang-switch {
  display: inline-flex;
  gap: 0.25rem;
  margin-left: 0.5rem;
  padding: 0.25rem;
  background: var(--mint-soft);
  border-radius: 999px;
}

.lang-switch a {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.8rem;
  padding: 0.4rem 0.65rem;
  border-radius: 999px;
  color: var(--ink-soft);
}

.lang-switch a.is-active {
  background: var(--teal);
  color: var(--white);
}

/* Main shell */
.site-main {
  position: relative;
  z-index: 1;
}

/* Hero */
.hero {
  position: relative;
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(2rem, 4vw, 3rem);
  overflow: hidden;
}

.hero-inner {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.hero-brand {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(2.8rem, 7vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  background: linear-gradient(120deg, var(--teal-dark) 0%, var(--teal) 45%, var(--magenta) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 0.75rem;
  animation: hero-in 0.9s var(--ease-out) both;
}

.hero-lead {
  font-size: clamp(1.05rem, 2.2vw, 1.3rem);
  color: var(--ink-soft);
  max-width: 34ch;
  margin: 0 auto 1.5rem;
  animation: hero-in 0.9s 0.12s var(--ease-out) both;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  animation: hero-in 0.9s 0.22s var(--ease-out) both;
}

@keyframes hero-in {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  padding: 0.85rem 1.4rem;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  transition: transform 0.25s var(--ease-spring), box-shadow 0.25s ease, background 0.2s ease;
  text-decoration: none;
}

.btn:hover { transform: translateY(-3px) scale(1.03); }

.btn-primary {
  background: linear-gradient(135deg, var(--teal), var(--teal-dark));
  color: var(--white);
  box-shadow: 0 10px 24px rgba(0, 133, 119, 0.35);
}

.btn-primary:hover { color: var(--white); }

.btn-accent {
  background: linear-gradient(135deg, var(--magenta), #b0144e);
  color: var(--white);
  box-shadow: 0 10px 24px rgba(216, 27, 96, 0.3);
}

.btn-accent:hover { color: var(--white); }

.btn-ghost {
  background: rgba(255, 255, 255, 0.75);
  color: var(--teal-dark);
  border: 2px solid rgba(0, 133, 119, 0.2);
}

.btn-ghost:hover { color: var(--teal-dark); }

.btn-sun {
  background: linear-gradient(135deg, var(--sun), var(--orange));
  color: var(--teal-deep);
  box-shadow: 0 10px 24px rgba(237, 186, 31, 0.35);
}

.btn-sun:hover { color: var(--teal-deep); }

/* Store badges */
.store-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  align-items: center;
}

.store-row a img,
.store-badge {
  height: 52px;
  width: auto;
  transition: transform 0.25s var(--ease-spring);
}

.store-row a:hover img {
  transform: translateY(-4px) scale(1.05);
}

/* Sections */
.section {
  padding: clamp(2.5rem, 5vw, 4rem) 0;
}

.section-head {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 2rem;
}

.section-head p {
  margin-bottom: 0;
}

.panel {
  background: rgba(255, 255, 255, 0.78);
  border: 2px solid rgba(0, 133, 119, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  padding: clamp(1.25rem, 3vw, 2rem);
  backdrop-filter: blur(8px);
}

/* Star Hunt game */
.game-section {
  padding-top: 0.5rem;
}

.game-panel {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 207, 30, 0.25), transparent 40%),
    radial-gradient(circle at 80% 70%, rgba(216, 27, 96, 0.12), transparent 35%),
    linear-gradient(160deg, #f7fcfb, #eef7f5);
}

.game-hud {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.star-meter {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--teal-deep);
  background: rgba(255, 207, 30, 0.25);
  padding: 0.55rem 1rem;
  border-radius: 999px;
}

.star-meter .stars {
  display: inline-flex;
  gap: 0.25rem;
}

.star-meter .pip {
  width: 16px;
  height: 16px;
  background: rgba(0, 87, 75, 0.15);
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  transition: background 0.3s ease, transform 0.3s var(--ease-spring);
}

.star-meter .pip.filled {
  background: var(--sun);
  transform: scale(1.15);
}

.game-hint {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink-soft);
  margin: 0;
}

.game-arena {
  position: relative;
  min-height: 320px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.75rem;
  align-items: end;
  padding: 1rem 0 0.5rem;
}

@media (max-width: 800px) {
  .game-arena {
    grid-template-columns: repeat(3, 1fr);
    min-height: 360px;
  }
}

@media (max-width: 520px) {
  .game-arena {
    grid-template-columns: repeat(2, 1fr);
  }
}

.game-char {
  appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem;
  animation: char-float 3.8s ease-in-out infinite;
  transition: transform 0.3s var(--ease-spring), opacity 0.4s ease, filter 0.3s ease;
}

.game-char:nth-child(1) { animation-delay: 0s; }
.game-char:nth-child(2) { animation-delay: -0.6s; }
.game-char:nth-child(3) { animation-delay: -1.2s; }
.game-char:nth-child(4) { animation-delay: -1.8s; }
.game-char:nth-child(5) { animation-delay: -2.4s; }

.game-char img {
  width: clamp(72px, 12vw, 110px);
  height: clamp(72px, 12vw, 110px);
  object-fit: contain;
  border-radius: 28px;
  background: var(--white);
  padding: 0.5rem;
  box-shadow: var(--shadow);
  transition: box-shadow 0.25s ease, transform 0.25s var(--ease-spring);
}

.game-char span {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--teal-deep);
  background: rgba(255, 255, 255, 0.85);
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
}

.game-char:hover img,
.game-char:focus-visible img {
  transform: scale(1.08) rotate(-3deg);
  box-shadow: 0 16px 32px rgba(0, 87, 75, 0.22);
}

.game-char.is-collected {
  pointer-events: none;
  opacity: 0.35;
  filter: grayscale(0.4);
  animation: none;
  transform: scale(0.9);
}

.game-char.is-pop {
  animation: char-pop 0.55s var(--ease-spring) both;
}

@keyframes char-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

@keyframes char-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.25) rotate(8deg); }
  100% { transform: scale(0.9); opacity: 0.35; }
}

.burst {
  position: absolute;
  pointer-events: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  animation: burst-out 0.7s var(--ease-out) forwards;
  z-index: 5;
}

@keyframes burst-out {
  to {
    transform: translate(var(--dx), var(--dy)) scale(0.2);
    opacity: 0;
  }
}

.confetti-piece {
  position: absolute;
  width: 10px;
  height: 14px;
  top: 20%;
  left: 50%;
  border-radius: 2px;
  pointer-events: none;
  animation: confetti-fall 1.4s var(--ease-out) forwards;
  z-index: 6;
}

@keyframes confetti-fall {
  0% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  100% { transform: translate(var(--cx), var(--cy)) rotate(var(--rot)) ; opacity: 0; }
}

.game-complete-banner {
  display: none;
  text-align: center;
  margin-top: 1rem;
  padding: 1rem;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(255, 207, 30, 0.35), rgba(0, 133, 119, 0.15));
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--teal-deep);
  font-size: 1.15rem;
}

.game-panel.is-complete .game-complete-banner {
  display: block;
  animation: hero-in 0.5s var(--ease-out) both;
}

/* App worlds grid */
.worlds {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.world-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
  padding: 1.25rem 1rem;
  border-radius: var(--radius);
  background: var(--white);
  border: 2px solid transparent;
  box-shadow: var(--shadow-soft);
  color: var(--ink);
  transition: transform 0.3s var(--ease-spring), box-shadow 0.3s ease, border-color 0.2s ease;
}

.world-tile img {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 22px;
}

.world-tile h3 {
  margin: 0;
  font-size: 1.05rem;
}

.world-tile p {
  margin: 0;
  font-size: 0.9rem;
}

.world-tile:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: var(--shadow);
  color: var(--ink);
}

.world-tile[data-theme="animals"]:hover { border-color: var(--theme-animals); }
.world-tile[data-theme="birds"]:hover { border-color: var(--theme-birds); }
.world-tile[data-theme="transport"]:hover { border-color: var(--theme-transport); }
.world-tile[data-theme="math"]:hover { border-color: var(--theme-math); }
.world-tile[data-theme="abc"]:hover { border-color: var(--theme-abc); }

.worlds.is-locked .world-tile {
  filter: grayscale(0.7);
  opacity: 0.55;
  pointer-events: none;
}

.worlds.is-revealed .world-tile {
  animation: world-bounce 0.7s var(--ease-spring) both;
}

.worlds.is-revealed .world-tile:nth-child(1) { animation-delay: 0.05s; }
.worlds.is-revealed .world-tile:nth-child(2) { animation-delay: 0.12s; }
.worlds.is-revealed .world-tile:nth-child(3) { animation-delay: 0.19s; }
.worlds.is-revealed .world-tile:nth-child(4) { animation-delay: 0.26s; }
.worlds.is-revealed .world-tile:nth-child(5) { animation-delay: 0.33s; }

@keyframes world-bounce {
  0% { opacity: 0; transform: translateY(30px) scale(0.85); filter: grayscale(0.7); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: none; }
}

/* Feature list for SEO (always in DOM) */
.seo-features {
  display: grid;
  gap: 1.25rem;
}

.seo-feature {
  display: grid;
  gap: 0.5rem;
}

.seo-feature h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
}

.seo-feature h3::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--magenta);
  flex-shrink: 0;
}

.feature-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 0;
}

.feature-chips li {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  background: var(--mint-soft);
  color: var(--teal-deep);
}

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.step {
  text-align: center;
  padding: 1.5rem 1rem;
}

.step-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-size: 1.6rem;
  background: linear-gradient(145deg, var(--mint), var(--white));
  box-shadow: var(--shadow-soft);
  animation: char-float 4s ease-in-out infinite;
}

.step:nth-child(2) .step-icon { animation-delay: -1s; background: linear-gradient(145deg, #ffe9a8, var(--white)); }
.step:nth-child(3) .step-icon { animation-delay: -2s; background: linear-gradient(145deg, #f8cfe0, var(--white)); }
.step:nth-child(4) .step-icon { animation-delay: -3s; background: linear-gradient(145deg, #d4efe9, var(--white)); }

/* App page theme */
body[data-app="animals"] { --app-accent: var(--theme-animals); }
body[data-app="birds"] { --app-accent: var(--theme-birds); }
body[data-app="transport"] { --app-accent: var(--theme-transport); }
body[data-app="math"] { --app-accent: var(--theme-math); }
body[data-app="abc"] { --app-accent: var(--theme-abc); }

.app-hero {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1.5rem;
  align-items: center;
  padding: 2.5rem 0 1.5rem;
}

.app-hero-logo {
  width: 140px;
  height: 140px;
  object-fit: contain;
  border-radius: 32px;
  background: var(--white);
  padding: 0.75rem;
  box-shadow: var(--shadow);
  animation: char-float 5s ease-in-out infinite;
}

.app-hero h1 {
  color: var(--app-accent, var(--teal-deep));
  margin-bottom: 0.4rem;
}

.app-hero .hero-lead {
  margin: 0;
  text-align: left;
  max-width: none;
}

.app-cover {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  margin: 1.5rem 0;
}

.app-cover img {
  width: 100%;
  display: block;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}

.chips li {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--app-accent, var(--teal)) 16%, white);
  color: var(--teal-deep);
  border: 1px solid color-mix(in srgb, var(--app-accent, var(--teal)) 28%, transparent);
}

.gallery {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 0.5rem 0 1rem;
  -webkit-overflow-scrolling: touch;
}

.gallery img {
  flex: 0 0 auto;
  width: min(220px, 70vw);
  border-radius: 18px;
  scroll-snap-align: start;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s var(--ease-spring);
}

.gallery img:hover {
  transform: translateY(-6px) scale(1.03);
}

.howto-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.game-panel.is-complete [data-skip-game] {
  display: none;
}

.howto-list li {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 0.75rem;
  align-items: start;
  padding: 0.85rem 1rem;
  background: var(--white);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-soft);
  color: var(--ink-soft);
}

.howto-list .num {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  background: var(--app-accent, var(--teal));
  color: var(--white);
}

/* Forms */
.form-panel {
  max-width: 640px;
  margin: 0 auto;
}

.form-grid {
  display: grid;
  gap: 1rem;
}

.form-row {
  display: grid;
  gap: 0.4rem;
}

.form-row label {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--teal-deep);
  font-size: 0.95rem;
}

.form-row input,
.form-row select,
.form-row textarea {
  font: inherit;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  border: 2px solid rgba(0, 133, 119, 0.18);
  background: var(--white);
  color: var(--ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 4px rgba(0, 133, 119, 0.15);
}

.form-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-status {
  margin: 0.75rem 0 0;
  font-weight: 600;
  min-height: 1.25em;
}

.form-status.is-success {
  color: var(--teal-deep);
}

.form-status.is-error {
  color: #c0392b;
}

/* Donate / contacts tiles */
.action-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.action-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
  padding: 1.5rem 1.25rem;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  border: 2px solid transparent;
  transition: transform 0.3s var(--ease-spring), border-color 0.2s ease;
  color: var(--ink);
}

.action-tile:hover {
  transform: translateY(-6px);
  border-color: var(--teal);
  color: var(--ink);
}

.action-tile img {
  width: 64px;
  height: 64px;
  object-fit: contain;
}

.action-tile h3 {
  margin: 0;
}

.action-tile p {
  margin: 0;
  font-size: 0.95rem;
}

/* Legal / prose */
.prose {
  max-width: 720px;
  margin: 0 auto;
}

.prose h2 {
  margin-top: 1.75rem;
  font-size: 1.35rem;
}

.prose a {
  font-weight: 700;
}

.privacy-date {
  color: var(--ink-soft);
  font-weight: 600;
  margin-top: -0.5rem;
}

/* Share */
.share-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.share-row a {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  background: var(--white);
  color: var(--teal-deep);
  box-shadow: var(--shadow-soft);
}

.share-row a:hover {
  background: var(--teal);
  color: var(--white);
}

/* Footer */
.site-footer {
  position: relative;
  z-index: 1;
  margin-top: 2rem;
  padding: 2.5rem 0 1.5rem;
  background: linear-gradient(180deg, transparent, rgba(0, 87, 75, 0.08));
  border-top: 2px solid rgba(0, 133, 119, 0.1);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.footer-grid h4 {
  font-size: 1rem;
  margin-bottom: 0.6rem;
  color: var(--teal-dark);
}

.footer-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-grid li {
  margin-bottom: 0.35rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.copyright {
  display: block;
  text-align: center;
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-weight: 600;
}

/* Page title for secondary */
.page-hero {
  padding: 2.5rem 0 1rem;
  text-align: center;
}

.page-hero p {
  max-width: 40ch;
  margin: 0 auto;
}

/* Reveal on scroll helper */
[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* Mobile nav */
@media (max-width: 860px) {
  .nav-toggle { display: grid; place-items: center; }

  .site-nav {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 1rem;
    left: 1rem;
    flex-direction: column;
    align-items: stretch;
    background: rgba(255, 255, 255, 0.96);
    border-radius: var(--radius);
    padding: 0.75rem;
    box-shadow: var(--shadow);
    display: none;
  }

  .site-nav.is-open { display: flex; }

  .site-nav a {
    border-radius: 12px;
  }

  .lang-switch {
    margin: 0.5rem 0 0;
    justify-content: center;
  }

  .app-hero {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
  }

  .app-hero .hero-lead { text-align: center; }

  .form-split { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .playground-bg .blob,
  .playground-bg .star-deco,
  .game-char,
  .step-icon,
  .app-hero-logo {
    animation: none !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
