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

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-tap-highlight-color: transparent;
}

button {
  font-family: inherit;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

button:focus-visible, a:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

/* Shared Top Bars */
.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 24px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}

.play-shell .brand-title {
  color: var(--accent);
}

.brand-group {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}

.brand-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.01em;
}

.brand-star {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  background: var(--accent);
  color: var(--surface);
  border-radius: var(--r-sm);
  font-size: 1.2rem;
}

.circle-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  display: inline-grid;
  place-items: center;
  font-size: 1.15rem;
  text-decoration: none;
  box-shadow: 0 2px 4px rgba(28, 25, 23, 0.05);
}

.circle-accent-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--r-pill);
  border: none;
  background: var(--accent);
  color: var(--surface);
  display: inline-grid;
  place-items: center;
  font-size: 1.2rem;
  text-decoration: none;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.wall-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  background: var(--play-yellow-soft);
  border: 1px solid var(--play-yellow);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.95rem;
  text-decoration: none;
}

.sticker-pill {
  background: linear-gradient(135deg, var(--play-yellow-soft) 0%, var(--play-yellow) 100%);
  border-color: var(--play-yellow-deep);
  box-shadow: 0 3px 8px rgba(217, 119, 6, 0.16);
}

.parents-pill {
  padding: 8px 16px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface-2);
  color: var(--ink-2);
  font-weight: 600;
  font-size: 0.92rem;
}

.parents-pill:hover { background: var(--line); }

.main-site-cta {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px 8px 12px;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, var(--accent) 0%, var(--play-orange) 100%);
  border: 1.5px solid rgba(255, 255, 255, 0.35);
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.94rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(194, 65, 12, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.32);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
}

.main-site-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 18px rgba(194, 65, 12, 0.36), inset 0 1px 0 rgba(255, 255, 255, 0.4);
  filter: brightness(1.04);
}

.main-site-cta:active {
  transform: translateY(0);
}

.main-site-cta-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 25%, rgba(255, 255, 255, 0.28) 50%, transparent 75%);
  transform: translateX(-120%);
  animation: shineSweep 4.8s ease-in-out infinite;
  pointer-events: none;
}

.main-site-cta-icon {
  display: inline-grid;
  place-items: center;
  color: var(--play-yellow-soft);
}

.main-site-cta-badge {
  padding: 2px 8px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.22);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0;
}

.main-site-cta-arrow {
  display: inline-grid;
  place-items: center;
  transition: transform 0.16s ease;
}

.main-site-cta:hover .main-site-cta-arrow {
  transform: translateX(3px);
}

/* Peach Header Band & Arcs */
.peach-band {
  position: relative;
  overflow: hidden;
  background: var(--accent-tint);
  border-radius: 0 0 var(--r-band) var(--r-band);
  padding: 16px 24px 26px;
  border-bottom: 1px solid var(--line);
}

.peach-band::before, .peach-band::after {
  content: "";
  position: absolute;
  bottom: -54px;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  border: 16px solid rgba(194, 65, 12, 0.12);
  box-shadow: inset 0 0 0 18px rgba(194, 65, 12, 0.08);
  pointer-events: none;
}

.peach-band::before { left: -65px; }
.peach-band::after { right: -65px; }

.peach-top {
  position: relative;
  z-index: 1;
  max-width: 1060px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-headline {
  position: relative;
  z-index: 1;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.75rem, 3.2vw, 2.35rem);
  margin: 14px 0 14px;
  color: var(--ink);
}

/* Home Sections */
.home-main {
  max-width: 1020px;
  margin: 0 auto;
  padding: 24px 20px 44px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.section-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
}

.group-pills {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

.group-pill {
  padding: 7px 15px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  box-shadow: 0 2px 4px rgba(28, 25, 23, 0.04);
}

.group-pill.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--surface);
}

.cards-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.game-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: var(--ink);
  background: var(--surface);
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.game-card:hover {
  transform: translateY(-3px);
}

.game-card.is-disabled {
  opacity: 0.72;
  cursor: default;
  pointer-events: none;
}

.card-banner {
  height: 156px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px;
}

.card-banner.banner-img-wrap { padding: 0; }

.card-banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stage-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
  pointer-events: none;
  z-index: 0;
}

.rocket-space-img {
  opacity: 0;
  transition: opacity 1.1s ease;
}

.rocket-space-img.is-space {
  opacity: 1;
  animation: spaceFadeIn 1.1s ease forwards;
}

.banner-num-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.banner-bg-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.banner-meadow { background: var(--play-sky-soft); }
.banner-rocket { background: var(--play-sky); }

.banner-freetype {
  background: linear-gradient(135deg, var(--play-yellow-soft) 0%, var(--play-yellow) 100%);
}

.banner-numbers {
  background: linear-gradient(135deg, var(--play-sky-soft) 0%, var(--accent-tint) 100%);
}

.banner-char-row, .banner-rocket-svg {
  position: relative;
  z-index: 1;
}

.banner-char-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.banner-char-row svg { width: 88px; height: 96px; }
.banner-num-row svg { width: 80px; height: 88px; }
.banner-free-row svg { width: 68px; height: 74px; }
.banner-rocket-svg svg { width: 148px; height: 148px; }

.badge-sky { background: var(--play-sky); }
.badge-yellow { background: var(--play-yellow); }
.badge-green { background: var(--play-green); }

.ui-icon {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
}

.card-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.45rem;
}

.tag-pill {
  padding: 6px 12px;
  border-radius: var(--r-pill);
  background: var(--surface-2);
  color: var(--ink-2);
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
}

.tag-pill.is-soon {
  background: var(--accent-tint);
  color: var(--accent);
}

.free-num-badge {
  display: inline-grid;
  place-items: center;
  width: 64px;
  height: 76px;
  border-radius: var(--r-md);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2.3rem;
  color: var(--ink);
  border: 4px solid var(--surface);
  box-shadow: var(--shadow);
}

/* 26-Letter Wall */
.wall-main {
  max-width: 1040px;
  margin: 0 auto;
  padding: 24px 20px 44px;
}

.wall-board {
  background: var(--surface);
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 24px;
}

.wall-grid {
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 12px;
}

.wall-tile {
  position: relative;
  aspect-ratio: 1 / 1.08;
  border-radius: var(--r-md);
  border: 2px dashed var(--line-strong);
  background: var(--surface-2);
  color: var(--ink-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.5rem, 2.5vw, 2.2rem);
  padding: 6px;
  transition: transform 0.12s ease;
}

.wall-tile:hover { transform: scale(1.04); }

.wall-tile.is-found {
  border: 4px solid var(--surface);
  background: linear-gradient(180deg, color-mix(in srgb, var(--tile-color, var(--play-orange)) 86%, var(--surface)) 0%, var(--tile-color, var(--play-orange)) 100%);
  color: var(--ink);
  box-shadow: 0 5px 0 rgba(28, 25, 23, 0.08), var(--shadow);
  overflow: visible;
}

.wall-tile.is-found::before {
  content: "";
  position: absolute;
  inset: 4px 6px auto;
  height: 26%;
  border-radius: var(--r-sm);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.38) 0%, rgba(255, 255, 255, 0) 100%);
  pointer-events: none;
}

.wall-letter {
  line-height: 0.95;
  position: relative;
  z-index: 1;
}

.wall-star {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--play-yellow);
  display: grid;
  place-items: center;
  box-shadow: 0 2px 5px rgba(28, 25, 23, 0.14);
  z-index: 2;
}

.wall-face-svg {
  display: block;
  margin-top: 2px;
  position: relative;
  z-index: 1;
}

.wall-foot {
  margin-top: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.wall-hint {
  margin: 0;
  color: var(--ink-2);
  font-weight: 600;
}

.btn-primary, .btn-primary-sm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: var(--r-pill);
  background: var(--accent);
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 700;
  text-decoration: none;
}

.btn-primary { padding: 12px 24px; font-size: 1.05rem; }
.btn-primary-sm { padding: 9px 18px; font-size: 0.95rem; }
.btn-primary:hover, .btn-primary-sm:hover { background: var(--accent-hover); }

/* Gameplay Stage */
.play-shell {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.round-stars {
  display: flex;
  align-items: center;
  gap: 6px;
}

.round-star {
  font-size: 1.65rem;
  color: var(--line-strong);
  transition: transform 0.25s ease, color 0.25s ease;
}

.round-star.is-lit {
  color: var(--play-yellow);
  text-shadow: 0 1px 0 var(--accent);
  transform: scale(1.1);
}

.phone-tip-bar {
  background: var(--play-sky-soft);
  text-align: center;
  padding: 6px 12px;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--ink-2);
}

.play-stage {
  position: relative;
  flex: 1;
  min-height: 330px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px 24px 24px;
}

.stage-meadow { background: var(--play-sky-soft); }
.stage-sky { background: var(--play-sky); }

.stage-backdrop-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.rocket-backdrop-svg .space-overlay {
  opacity: 0;
  transition: opacity 1.1s ease;
}

.rocket-backdrop-svg.is-space .space-overlay {
  opacity: 1;
  animation: spaceFadeIn 1.1s ease forwards;
}

.rocket-backdrop-svg .twinkle-stars {
  opacity: 0.35;
  transition: opacity 0.8s ease;
}

.rocket-backdrop-svg.is-space .twinkle-stars { opacity: 1; }
.twinkle-star { animation: twinkle 2s ease-in-out infinite; }
.twinkle-star.s-1 { animation-delay: 0.6s; }
.twinkle-star.s-2 { animation-delay: 1.2s; }

.sun-rays-spin { transform-origin: 0 0; animation: sunSpin 28s linear infinite; }
.cloud-drift-1 { animation: cloudDrift 22s ease-in-out infinite; }
.cloud-drift-2 { animation: cloudDrift 28s ease-in-out infinite reverse; }
.cloud-drift-3 { animation: cloudDrift 18s ease-in-out infinite; }

.meadow-arena {
  position: relative;
  z-index: 1;
  flex: 1;
  max-width: 1060px;
  width: 100%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
}

.friends-cluster {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

.mini-friend { width: 84px; height: 90px; }

.hero-friend-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-friend-wrap .lf-svg { width: clamp(160px, 24vw, 230px); height: auto; }

.speech-bubble-row {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.speech-bubble {
  position: relative;
  padding: 12px 20px;
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.25rem, 2.5vw, 1.85rem);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  animation: popIn 0.25s ease;
}

.surprise-badge-circle {
  width: clamp(72px, 8vw, 96px);
  height: clamp(72px, 8vw, 96px);
  border-radius: 50%;
  background: radial-gradient(circle, var(--surface) 0%, var(--play-yellow-soft) 100%);
  border: 4px solid var(--play-yellow);
  box-shadow: 0 10px 24px rgba(250, 204, 21, 0.45);
  display: grid;
  place-items: center;
  animation: surpriseSpinPop 0.72s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.surprise-icon-pop {
  font-size: clamp(3.4rem, 5.4vw, 5.2rem);
  line-height: 1;
  filter: drop-shadow(0 6px 10px rgba(28, 25, 23, 0.16));
  animation: surpriseWiggle 0.9s ease-in-out infinite;
}

.hero-sunburst {
  position: absolute;
  width: clamp(230px, 32vw, 320px);
  height: clamp(230px, 32vw, 320px);
  border-radius: 50%;
  background: repeating-conic-gradient(
    from 0deg,
    rgba(250, 204, 21, 0.42) 0deg 15deg,
    rgba(255, 255, 255, 0) 15deg 30deg
  );
  -webkit-mask-image: radial-gradient(circle, rgba(0, 0, 0, 1) 25%, rgba(0, 0, 0, 0) 70%);
  mask-image: radial-gradient(circle, rgba(0, 0, 0, 1) 25%, rgba(0, 0, 0, 0) 70%);
  animation: sunSpin 10s linear infinite;
  pointer-events: none;
  z-index: 0;
}

.hero-friend-wrap .lf-svg, .freetype-hero .lf-svg { position: relative; z-index: 1; }
.freetype-hero { position: relative; display: grid; place-items: center; }

.finale-rainbow-arc {
  position: absolute;
  top: 6%;
  left: 50%;
  transform: translateX(-50%);
  width: min(86%, 720px);
  height: auto;
  pointer-events: none;
  z-index: 0;
  animation: popIn 0.55s ease;
}

.blastoff-banner {
  position: absolute;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  padding: 10px 26px;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, var(--play-yellow) 0%, var(--play-orange) 100%);
  border: 4px solid var(--surface);
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.35rem, 3.2vw, 2.2rem);
  text-shadow: 0 3px 0 rgba(154, 52, 10, 0.4);
  box-shadow: 0 12px 28px rgba(194, 65, 12, 0.35);
  white-space: nowrap;
  animation: blastBannerPop 0.55s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero-friend-wrap.is-hinted::before {
  content: "";
  position: absolute;
  inset: 10% 6%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(250, 204, 21, 0.62) 0%, rgba(250, 204, 21, 0) 72%);
  animation: hintHalo 1.3s ease-in-out infinite;
  pointer-events: none;
}

.fuel-bubble-wrap {
  position: relative;
  display: grid;
  place-items: center;
}

.rf-word-pop {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 4;
  pointer-events: none;
}

.rf-word-pop .speech-bubble-row {
  flex-direction: column;
  gap: 8px;
  margin-bottom: 0;
}

.rf-word-pop .speech-bubble {
  white-space: nowrap;
  padding: 10px 16px;
  font-size: clamp(1.05rem, 2.1vw, 1.45rem);
}

.fuel-bubble-wrap.is-hinted .fuel-bubble {
  box-shadow: 0 0 0 12px rgba(250, 204, 21, 0.5), 0 12px 30px rgba(28, 25, 23, 0.14);
  animation: hintHalo 1.2s ease-in-out infinite;
}

.bubble-orbit-star {
  position: absolute;
  color: var(--play-yellow);
  pointer-events: none;
  z-index: 2;
  animation: orbitFloat 2.8s ease-in-out infinite;
}

.bubble-orbit-star.s1 { top: -8px; left: 10px; }
.bubble-orbit-star.s2 { bottom: 6px; right: 6px; animation-delay: 1.2s; }

.prompt-pill-wrap {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
}

.prompt-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 22px;
  border-radius: var(--r-pill);
  background: var(--surface);
  box-shadow: var(--shadow);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1rem, 2vw, 1.25rem);
}

.prompt-replay {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: var(--accent);
  color: var(--surface);
  font-size: 1rem;
  display: inline-grid;
  place-items: center;
}

/* Rocket Fuel Stage */
.rocket-arena {
  position: relative;
  z-index: 1;
  flex: 1;
  max-width: 1020px;
  width: 100%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 20px;
}

.rocket-stage-left { display: flex; justify-content: center; }

.rocket-scene-wrap {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 8px;
}

.rocket-gauge-svg {
  width: clamp(54px, 6.8vw, 76px);
  height: auto;
  flex-shrink: 0;
}

.rocket-pad-col {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: clamp(168px, 21vw, 240px);
}

.rocket-craft {
  position: relative;
  width: 78%;
  z-index: 2;
  margin-bottom: -8px;
}

.rocket-sprite-img {
  position: relative;
  z-index: 2;
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 8px 16px rgba(28, 25, 23, 0.14));
}

.rocket-thruster-svg {
  position: absolute;
  left: 50%;
  top: 85%;
  transform: translateX(-50%);
  width: 82%;
  height: auto;
  z-index: 1;
  pointer-events: none;
  overflow: visible;
}

.rocket-smoke-svg {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: auto;
  z-index: 3;
  pointer-events: none;
  overflow: visible;
}

.rocket-pad-svg {
  position: relative;
  z-index: 1;
  width: 100%;
  height: auto;
  display: block;
}

.fuel-bubble-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.fuel-bubble {
  position: relative;
  width: clamp(175px, 23vw, 236px);
  height: clamp(175px, 23vw, 236px);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(4.8rem, 8.2vw, 6.6rem);
  color: var(--accent);
  animation: floatSlow 2.6s ease-in-out infinite;
}

.fuel-bubble-img {
  position: absolute;
  inset: -6%;
  width: 112%;
  height: 112%;
  object-fit: contain;
  pointer-events: none;
  filter: drop-shadow(0 12px 24px rgba(14, 165, 233, 0.25));
}

.fuel-bubble-char {
  position: relative;
  z-index: 1;
  -webkit-text-stroke: 6px var(--surface);
  paint-order: stroke fill;
  text-shadow: 0 5px 12px rgba(154, 52, 10, 0.22);
}

.fuel-bubble.is-popped {
  animation: bubblePop 0.45s ease forwards;
}

/* Free Type */
.freetype-arena {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.freetype-hero .lf-svg { width: clamp(180px, 26vw, 250px); height: auto; animation: heroJump 0.35s ease; }

.freetype-history {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
}

.history-chip {
  width: 46px;
  height: 46px;
  border-radius: var(--r-sm);
  background: var(--surface);
  border: 3px solid var(--chip-color, var(--line));
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  box-shadow: var(--shadow);
  animation: popIn 0.22s ease;
}

/* Touch Keyboards */
.touch-dock {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding: 12px 14px 18px;
}

.touch-kbd {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.touch-kbd-row {
  display: flex;
  justify-content: center;
  gap: 6px;
}

.touch-key {
  min-width: 52px;
  height: 54px;
  padding: 0 10px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  box-shadow: 0 4px 0 var(--key-lip), 0 6px 12px rgba(28, 25, 23, 0.08);
}

.touch-key:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 var(--key-lip);
}

.touch-key.key-highlight {
  background: linear-gradient(180deg, var(--play-yellow-soft) 0%, var(--play-yellow) 100%);
  border-color: var(--play-orange);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.25), 0 4px 0 var(--play-orange);
}

.phone-choices-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.phone-choice-tile {
  min-height: 76px;
  border-radius: var(--r-md);
  border: 4px solid var(--tile-color, var(--play-orange));
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
  color: var(--tile-color, var(--ink));
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2.3rem;
  box-shadow: 0 5px 0 var(--tile-color, var(--play-orange)), 0 10px 18px rgba(28, 25, 23, 0.12);
}

.phone-choice-tile:active {
  transform: translateY(3px);
  box-shadow: 0 2px 0 var(--tile-color, var(--play-orange));
}

.phone-free-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  max-height: 230px;
  overflow-y: auto;
}

.phone-free-tile {
  min-height: 56px;
  border-radius: var(--r-sm);
  border: 2px solid var(--tile-color, var(--line-strong));
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
}

/* Stop Screen & Bridge */
.rest-main {
  max-width: 680px;
  margin: 0 auto;
  padding: 20px 20px 44px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.rest-illustration {
  width: 100%;
  max-width: 390px;
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.stop-station-svg, .stop-station-img { display: block; width: 100%; height: auto; }

.rest-heading {
  margin: 6px 0 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.7rem, 3.2vw, 2.25rem);
}

.rest-subtitle {
  margin: 0;
  color: var(--ink-2);
  font-size: 1.05rem;
}

.rest-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-quiet {
  padding: 10px 20px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--accent-tint);
  color: var(--ink-2);
  font-weight: 600;
  font-size: 0.95rem;
}

.btn-link-quiet {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.bridge-card {
  width: 100%;
  margin-top: 10px;
  padding: 20px 22px;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 6px solid var(--accent);
  box-shadow: var(--shadow);
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.bridge-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  background: var(--accent-tint);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.8rem;
}

.bridge-card h2 {
  margin: 8px 0 4px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
}

.bridge-card p { margin: 0; color: var(--ink-2); font-size: 0.95rem; }

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(28, 25, 23, 0.42);
  display: grid;
  place-items: center;
  padding: 18px;
}

.modal-card {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 22px 24px;
  box-shadow: var(--shadow);
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.modal-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.3rem;
}

.modal-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface-2);
  font-size: 1.2rem;
}

.math-question { font-size: 1.15rem; margin: 8px 0 16px; text-align: center; }

.math-choices {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.math-pill {
  padding: 12px 10px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface-2);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
}

.math-pill:hover { background: var(--accent); color: var(--surface); border-color: var(--accent); }

.modal-caption {
  margin: 14px 0 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--ink-2);
}

.setting-block { margin-bottom: 14px; }
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.setting-label { display: block; font-weight: 600; margin-bottom: 6px; }
.setting-row .setting-label { margin-bottom: 0; }

.setting-pills { display: flex; flex-wrap: wrap; gap: 6px; }

.seg-pill, .toggle-pill, .danger-pill {
  padding: 7px 13px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-strong);
  background: var(--surface-2);
  font-weight: 600;
  font-size: 0.88rem;
}

.seg-pill.is-active, .toggle-pill.is-on {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--surface);
}

.danger-pill { width: 100%; margin-top: 8px; color: var(--accent); background: var(--accent-tint); }

.settings-footer {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.bridge-link { color: var(--accent); font-weight: 700; text-decoration: none; }

.round-done-card {
  position: relative;
  z-index: 5;
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 26px 28px;
  box-shadow: var(--shadow);
  text-align: center;
  max-width: 380px;
  margin: auto;
}

.round-done-actions { display: flex; justify-content: center; gap: 10px; margin-top: 16px; flex-wrap: wrap; }

.finale-row {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.finale-friend {
  width: clamp(100px, 14vw, 145px);
  animation: waveDance 0.6s cubic-bezier(0.22, 1, 0.36, 1) infinite alternate;
  animation-delay: calc(var(--wave-idx, 0) * 100ms);
}

.round-done-stars {
  display: flex;
  justify-content: center;
  gap: 6px;
  color: var(--play-yellow);
  margin-bottom: 6px;
}

.btn-link-quiet {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

/* Interactive Wall & Sticker Album */
.wall-board { position: relative; }
.wall-tile.is-bouncing, .sticker-slot.is-bouncing { animation: wallJump 0.68s cubic-bezier(0.22, 1, 0.36, 1); }
.wall-tile.is-sleepy-wobble { animation: wiggle 0.35s ease; }

.wall-tooltip {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: var(--surface);
  font-family: var(--font-body);
  font-size: 0.74rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  white-space: nowrap;
  z-index: 6;
  animation: popIn 0.18s ease;
}

.sticker-shelf {
  position: relative;
  margin-top: 24px;
  background: var(--surface);
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: 22px 24px;
}

.sticker-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.sticker-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 8px;
  border-radius: var(--r-md);
  border: 2px dashed var(--line-strong);
  background: var(--surface-2);
  text-align: center;
}

.sticker-slot.is-unlocked {
  position: relative;
  overflow: hidden;
  border: 3px solid var(--play-yellow);
  background: linear-gradient(180deg, var(--surface) 0%, var(--play-yellow-soft) 100%);
  box-shadow: 0 5px 14px rgba(217, 119, 6, 0.14);
  transition: transform 0.16s ease;
}

.sticker-slot.is-unlocked:hover { transform: scale(1.06); }
.sticker-svg { width: 76px; height: 76px; display: block; }
.sticker-slot.is-unlocked .sticker-svg { animation: stickerBreathe 3.8s ease-in-out infinite; }

.sticker-shine {
  position: absolute;
  inset: -25%;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0) 36%, rgba(255, 255, 255, 0.52) 50%, rgba(255, 255, 255, 0) 64%);
  animation: shineSweep 4.4s ease-in-out infinite;
  pointer-events: none;
  z-index: 2;
}

.sticker-locked-dot {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.65rem;
  color: var(--ink-2);
  background: var(--line);
}

.sticker-name { font-size: 0.82rem; font-weight: 700; color: var(--ink-2); }
.sticker-slot.is-unlocked .sticker-name { color: var(--ink); }

.sticker-reward-pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px 8px 10px;
  margin-top: 12px;
  border-radius: var(--r-pill);
  background: var(--play-yellow-soft);
  border: 2px solid var(--play-yellow);
  animation: popIn 0.35s ease;
  text-align: left;
}

.sticker-reward-pill strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.92rem;
  color: var(--accent);
}

.sticker-reward-pill span { font-size: 0.88rem; font-weight: 700; color: var(--ink); }
.sticker-reward-badge .sticker-svg { width: 48px; height: 48px; }

/* Full-screen Sticker Award Ceremony */
.award-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  background: radial-gradient(circle at center, rgba(254, 240, 138, 0.92) 0%, rgba(28, 25, 23, 0.72) 100%);
  display: grid;
  place-items: center;
  padding: 18px;
  animation: popIn 0.25s ease;
}

.award-stage {
  position: relative;
  width: 100%;
  max-width: 520px;
  min-height: 430px;
  background: var(--surface);
  border-radius: var(--r-band);
  border: 6px solid var(--play-yellow);
  box-shadow: 0 24px 60px rgba(28, 25, 23, 0.32);
  padding: 28px 24px;
  display: grid;
  place-items: center;
  text-align: center;
  overflow: hidden;
}

.award-halo {
  position: absolute;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(250, 204, 21, 0.42) 0%, rgba(254, 240, 138, 0.18) 50%, rgba(255, 255, 255, 0) 72%);
  animation: calmHaloPulse 3.6s ease-in-out infinite;
  pointer-events: none;
}

.award-gift-wrap, .award-reveal { position: relative; z-index: 2; }
.is-hidden { display: none !important; }
.gift-box-svg { width: 150px; height: 150px; cursor: pointer; animation: giftWiggle 0.36s ease-in-out infinite; }
.award-gift-tip { font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; color: var(--accent); margin: 8px 0 0; }

.award-headline-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, var(--play-yellow) 0%, var(--play-orange) 100%);
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.15rem, 2.8vw, 1.45rem);
  box-shadow: 0 6px 16px rgba(234, 88, 12, 0.25);
}

.award-sticker-hero {
  position: relative;
  display: grid;
  place-items: center;
  margin: 16px auto 10px;
  width: 176px;
  height: 176px;
  border: none;
  border-radius: 50%;
  background: radial-gradient(circle, var(--play-yellow-soft) 0%, rgba(255, 255, 255, 0) 72%);
  overflow: hidden;
  animation: awardPop 0.65s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.award-sticker-hero .sticker-svg { width: 165px; height: 165px; animation: stickerBreathe 3.8s ease-in-out infinite; }
.award-sticker-hero.is-friendly-wave { animation: friendlyWave 0.6s ease; }

.award-name-badge {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.55rem;
  color: var(--ink);
}

.award-tap-hint { margin: 2px 0 16px; color: var(--ink-2); font-size: 0.92rem; font-weight: 600; }
.award-actions { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.award-collect-btn { font-size: 1.18rem; padding: 14px 28px; box-shadow: 0 5px 0 var(--accent-hover); }

/* DOM Particle FX */
.fx-confetti {
  position: absolute;
  z-index: 8;
  font-size: 1.75rem;
  font-weight: 800;
  pointer-events: none;
  animation: confettiBurst 1.15s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.fx-fuel-spark {
  position: absolute;
  z-index: 8;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--surface) 0%, var(--play-yellow) 52%, var(--play-orange) 100%);
  box-shadow: 0 0 16px var(--play-yellow), 0 0 6px var(--surface);
  pointer-events: none;
  animation: fuelStreak 0.65s cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
}

.fx-shockwave {
  position: absolute;
  z-index: 7;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 5px solid var(--play-yellow);
  box-shadow: 0 0 16px var(--play-yellow);
  pointer-events: none;
  animation: shockwaveExpand 0.65s ease-out forwards;
}

.fx-fly-star {
  position: fixed;
  z-index: 50;
  font-size: 2.35rem;
  color: var(--play-yellow);
  text-shadow: 0 2px 8px rgba(194, 65, 12, 0.5);
  pointer-events: none;
  animation: flyStar 0.64s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.fx-wrong-badge {
  position: absolute;
  bottom: 76px;
  left: 50%;
  z-index: 9;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 9px;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 3px solid var(--badge-color, var(--play-purple));
  box-shadow: var(--shadow);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  pointer-events: none;
  animation: badgePopFloat 2.2s ease forwards;
}

.fx-wrong-char {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--badge-color, var(--play-purple));
  color: var(--surface);
  display: grid;
  place-items: center;
  font-size: 1rem;
}

.fx-balloon, .fx-float-star {
  position: absolute;
  z-index: 7;
  pointer-events: none;
  animation: balloonRise 1.75s ease-out forwards;
}

.fx-balloon {
  width: 44px;
  height: 54px;
  border-radius: 50% 50% 46% 46%;
  background: var(--balloon-color, var(--play-coral));
  border: 3px solid var(--surface);
  box-shadow: inset -5px -6px 0 rgba(28, 25, 23, 0.14);
}

.fx-float-star {
  font-size: 2.1rem;
  color: var(--balloon-color, var(--play-yellow));
}

/* Animations */
@keyframes popIn { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes squashJump {
  0% { transform: scale(1, 1) translateY(0); }
  16% { transform: scale(1.32, 0.72) translateY(14px); }
  46% { transform: scale(0.84, 1.24) translateY(-92px) rotate(-6deg); }
  74% { transform: scale(1.22, 0.8) translateY(6px); }
  100% { transform: scale(1, 1) translateY(0); }
}
@keyframes wallJump {
  0% { transform: scale(1) translateY(0); }
  35% { transform: scale(1.32) translateY(-16px) rotate(-4deg); }
  70% { transform: scale(0.95) translateY(3px); }
  100% { transform: scale(1) translateY(0); }
}
@keyframes heroJump {
  0% { transform: scale(0.18); }
  52% { transform: scale(1.26) translateY(-28px); }
  76% { transform: scale(0.92) translateY(4px); }
  100% { transform: scale(1.04) translateY(0); }
}
@keyframes sleepyBreathe { 0%, 100% { transform: scaleY(1) translateY(0); } 50% { transform: scaleY(0.94) translateY(4px); } }
@keyframes awakeBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@keyframes zzzFloat { 0% { transform: translateY(6px) scale(0.85); opacity: 0; } 35% { opacity: 1; } 100% { transform: translateY(-18px) scale(1.15); opacity: 0; } }
@keyframes sunSpin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes cloudDrift { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(34px); } }
@keyframes twinkle { 0%, 100% { opacity: 0.45; transform: scale(0.9); } 50% { opacity: 1; transform: scale(1.25); } }
@keyframes floatSlow { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes orbitFloat { 0%, 100% { transform: translateY(0) rotate(-6deg); } 50% { transform: translateY(-10px) rotate(12deg); } }
@keyframes bubblePop { 0% { transform: scale(1); opacity: 1; } 60% { transform: scale(1.3); opacity: 0.95; } 100% { transform: scale(0.2); opacity: 0; } }
@keyframes wiggle { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-8px); } 75% { transform: translateX(8px); } }
@keyframes giftWiggle { 0%, 100% { transform: rotate(-6deg) scale(1); } 50% { transform: rotate(6deg) scale(1.08); } }
@keyframes awardPop { 0% { transform: scale(0.15) rotate(-18deg); opacity: 0; } 65% { transform: scale(1.14) rotate(3deg); opacity: 1; } 100% { transform: scale(1) rotate(0deg); opacity: 1; } }
@keyframes calmHaloPulse { 0%, 100% { transform: scale(0.95); opacity: 0.75; } 50% { transform: scale(1.06); opacity: 1; } }
@keyframes stickerBreathe { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-3px) rotate(1.5deg); } }
@keyframes friendlyWave { 0% { transform: scale(1) rotate(0deg); } 35% { transform: scale(1.12) rotate(-6deg); } 70% { transform: scale(1.1) rotate(6deg); } 100% { transform: scale(1) rotate(0deg); } }
@keyframes shineSweep { 0% { transform: translateX(-120%); } 35%, 100% { transform: translateX(130%); } }
@keyframes flameFlicker { 0%, 100% { transform: scaleY(1) scaleX(1); } 50% { transform: scaleY(1.18) scaleX(0.94); } }
@keyframes rocketShake { 0%, 100% { transform: translate(0, 0); } 25% { transform: translate(-4px, -3px); } 75% { transform: translate(4px, 2px); } }
@keyframes rocketLaunch { 0% { transform: translateY(0); } 18% { transform: translateY(10px) scale(1.04, 0.96); } 100% { transform: translateY(-460px); } }
@keyframes waveDance { 0% { transform: translateY(0) rotate(-5deg) scale(1); } 100% { transform: translateY(-38px) rotate(5deg) scale(1.12); } }
@keyframes surpriseSpinPop { 0% { transform: scale(0.15) rotate(-30deg); opacity: 0; } 60% { transform: scale(1.24) rotate(8deg); opacity: 1; } 100% { transform: scale(1) rotate(0deg); opacity: 1; } }
@keyframes surpriseWiggle { 0%, 100% { transform: rotate(-6deg) scale(1); } 50% { transform: rotate(6deg) scale(1.1); } }
@keyframes blastBannerPop { 0% { transform: translateX(-50%) scale(0.3); opacity: 0; } 65% { transform: translateX(-50%) scale(1.12); opacity: 1; } 100% { transform: translateX(-50%) scale(1); opacity: 1; } }
@keyframes hintHalo { 0%, 100% { transform: scale(0.95); opacity: 0.7; } 50% { transform: scale(1.1); opacity: 1; } }
@keyframes starPop { 0% { transform: scale(1); } 50% { transform: scale(1.55); } 100% { transform: scale(1.12); } }
@keyframes confettiBurst { 0% { transform: translate(0, 0) scale(0.6) rotate(0deg); opacity: 1; } 100% { transform: translate(var(--dx), var(--dy)) scale(1.25) rotate(var(--rot)); opacity: 0; } }
@keyframes fuelStreak {
  0% { transform: translate(0, 0) scale(1.2); opacity: 1; }
  50% { transform: translate(calc(var(--dx) * 0.5), calc(var(--dy) * 0.5 + var(--arc, -50px))) scale(1.35); opacity: 1; }
  100% { transform: translate(var(--dx), var(--dy)) scale(0.5); opacity: 0.15; }
}
@keyframes shockwaveExpand { 0% { transform: translate(-50%, -50%) scale(0.4); opacity: 1; } 100% { transform: translate(-50%, -50%) scale(4.2); opacity: 0; } }
@keyframes flyStar { 0% { transform: translate(0, 0) scale(1.35); opacity: 1; } 100% { transform: translate(var(--dx), var(--dy)) scale(0.8); opacity: 0.2; } }
@keyframes badgePopFloat { 0% { transform: translate(-50%, 12px) scale(0.75); opacity: 0; } 20% { transform: translate(-50%, 0) scale(1.05); opacity: 1; } 80% { transform: translate(-50%, -6px) scale(1); opacity: 1; } 100% { transform: translate(-50%, -14px) scale(0.92); opacity: 0; } }
@keyframes balloonRise { 0% { transform: translateY(0) scale(0.7); opacity: 0.95; } 100% { transform: translateY(-290px) scale(1.18); opacity: 0; } }
@keyframes spaceFadeIn { from { opacity: 0; } to { opacity: 1; } }

.is-wiggle, .modal-wiggle { animation: wiggle 0.32s ease; }
.lf-mood-jumping { transform-origin: center bottom; animation: squashJump 0.85s cubic-bezier(0.22, 1, 0.36, 1); }
.lf-mood-sleepy .lf-body { transform-origin: 80px 130px; animation: sleepyBreathe 2.8s ease-in-out infinite; }
.lf-mood-awake .lf-body, .lf-mood-mini-awake .lf-body { transform-origin: 80px 130px; animation: awakeBob 2.2s ease-in-out infinite; }
.lf-zzz .zzz-1 { animation: zzzFloat 2.4s ease-in-out infinite; }
.lf-zzz .zzz-2 { animation: zzzFloat 2.4s ease-in-out 0.45s infinite; }
.lf-zzz .zzz-3 { animation: zzzFloat 2.4s ease-in-out 0.9s infinite; }
.round-star.star-pop { animation: starPop 0.45s cubic-bezier(0.22, 1, 0.36, 1); }
.rocket-flame { transform-box: fill-box; transform-origin: center top; animation: flameFlicker 0.22s ease-in-out infinite; }
.rocket-shake { animation: rocketShake 0.12s linear infinite; }
.rocket-launch { animation: rocketLaunch 2s cubic-bezier(0.3, 0, 0.7, 1) forwards; }

@media (prefers-reduced-motion: reduce) {
  .sun-rays-spin, .cloud-drift-1, .cloud-drift-2, .cloud-drift-3, .twinkle-star,
  .lf-mood-sleepy .lf-body, .lf-mood-awake .lf-body, .lf-mood-mini-awake .lf-body,
  .lf-zzz text, .fuel-bubble, .bubble-orbit-star, .rocket-flame, .rocket-shake,
  .finale-friend, .hero-sunburst, .award-halo, .sticker-shine, .main-site-cta-shine, .sticker-slot.is-unlocked .sticker-svg, .award-sticker-hero .sticker-svg, .gift-box-svg {
    animation: none !important;
  }
}

@media (max-width: 900px) {
  .wall-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .sticker-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 679px) {
  .cards-grid-2 { grid-template-columns: 1fr; }
  .wall-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
  .sticker-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .wall-board, .sticker-shelf { padding: 14px; }
  .top-bar { padding: 10px 12px; flex-wrap: wrap; row-gap: 6px; }
  .top-actions { gap: 6px; }
  .wall-pill { padding: 6px 10px; font-size: 0.85rem; }
  .play-stickers-pill .pill-word { display: none; }
  .brand-title { font-size: 1.08rem; }
  .circle-icon-btn, .circle-accent-btn { width: 36px; height: 36px; font-size: 1rem; }
  .parents-pill { padding: 6px 12px; font-size: 0.85rem; }
  .main-site-cta { padding: 6px 11px 6px 10px; font-size: 0.84rem; gap: 5px; }
  .main-site-cta-badge { display: none; }
  .round-stars { order: 3; width: 100%; justify-content: center; gap: 5px; }
  .round-star { font-size: 1.35rem; }
  .meadow-arena { grid-template-columns: 1fr; }
  .friends-cluster { display: none; }
  .rocket-arena { grid-template-columns: 1fr 1fr; gap: 6px; }
  .rocket-stage-left, .fuel-bubble-col { min-width: 0; }
  .rocket-scene-wrap { gap: 4px; }
  .rocket-gauge-svg { width: 38px; }
  .rocket-pad-col { width: 118px; }
  .fuel-bubble { width: 112px; height: 112px; font-size: 3.1rem; }
  .fuel-bubble-char { -webkit-text-stroke: 4px var(--surface); }
  .rf-word-pop .speech-bubble { white-space: normal; text-align: center; font-size: 0.92rem; padding: 7px 10px; }
  .rf-word-pop .surprise-badge-circle { width: 54px; height: 54px; }
  .rf-word-pop .surprise-icon-pop { font-size: 2.3rem; }
  .fuel-bubble-col { gap: 10px; }
  .fuel-bubble-col .prompt-pill { padding: 8px 12px; font-size: 0.9rem; max-width: 100%; }
  .phone-choice-tile { min-height: 68px; }
  .touch-dock { padding: 10px 12px 14px; }
  .play-stage { min-height: 240px; padding: 12px 14px; }
}
