/* ==========================================================
   KIDS LETTER POP — GAME WORKSPACE UI v17.10.83
   Scoped only to /kids/games/letter-pop.html
========================================================== */
body[data-kids-game="letter-pop"] .kids-pop-workspace {
  overflow: hidden;
  border: 1px solid var(--border, #dbe4f0);
  border-radius: 28px;
  background: var(--surface, #fff);
  box-shadow: 0 20px 48px rgba(15, 23, 42, .09);
}

body[data-kids-game="letter-pop"] .kids-pop-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid #dbe8f8;
  background:
    radial-gradient(circle at 85% 15%, rgba(253, 224, 71, .24), transparent 19%),
    radial-gradient(circle at 72% 85%, rgba(125, 211, 252, .20), transparent 28%),
    linear-gradient(135deg, #f8fbff, #eef7ff 55%, #fffdf4);
}

body[data-kids-game="letter-pop"] .kids-pop-title-wrap {
  display: flex;
  gap: 16px;
  align-items: center;
  min-width: 0;
}

body[data-kids-game="letter-pop"] .kids-pop-logo {
  position: relative;
  flex: 0 0 78px;
  width: 78px;
  height: 68px;
  border: 1px solid #bfe1ff;
  border-radius: 19px;
  background: linear-gradient(145deg, #dff6ff, #b8ecff);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .6);
}

body[data-kids-game="letter-pop"] .kids-pop-logo b {
  position: absolute;
  display: grid;
  place-items: center;
  width: 34px;
  height: 42px;
  border: 2px solid rgba(255, 255, 255, .72);
  border-radius: 52% 52% 48% 48%;
  color: #fff;
  font: 900 20px/1 Poppins, sans-serif;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .13);
  box-shadow: 0 7px 12px rgba(15, 23, 42, .13);
}

body[data-kids-game="letter-pop"] .kids-pop-logo b::after {
  content: "";
  position: absolute;
  top: 39px;
  width: 1px;
  height: 14px;
  background: #64748b;
}

body[data-kids-game="letter-pop"] .kids-pop-logo b:nth-child(1) { left: 6px; top: 17px; z-index: 2; background: linear-gradient(145deg, #ff6689, #ef164f); }
body[data-kids-game="letter-pop"] .kids-pop-logo b:nth-child(2) { left: 22px; top: 5px; z-index: 3; background: linear-gradient(145deg, #54dc79, #16a34a); }
body[data-kids-game="letter-pop"] .kids-pop-logo b:nth-child(3) { right: 5px; top: 18px; z-index: 2; background: linear-gradient(145deg, #48adff, #1671df); }

body[data-kids-game="letter-pop"] .kids-pop-hero h1 {
  margin: 7px 0 5px;
  color: #101b64;
  font-size: clamp(28px, 3.5vw, 42px);
  line-height: 1.06;
  letter-spacing: -.03em;
}

body[data-kids-game="letter-pop"] .kids-pop-hero p {
  margin: 0;
  color: #52627a;
  line-height: 1.5;
}

body[data-kids-game="letter-pop"] .kids-pop-hero [data-game-best] {
  display: block;
  margin-top: 6px;
  color: #1769ff;
  font-size: 13px;
}

body[data-kids-game="letter-pop"] .kids-pop-cheer {
  display: grid;
  grid-template-columns: auto auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 3px 10px;
  min-width: 250px;
  padding: 9px 14px;
  border: 1px solid #dbe8f8;
  border-radius: 22px;
  background: rgba(255, 255, 255, .72);
}

body[data-kids-game="letter-pop"] .kids-pop-cheer-stars { grid-column: 1 / 3; color: #f59e0b; font-size: 18px; letter-spacing: 2px; }
body[data-kids-game="letter-pop"] .kids-pop-cheer-face { grid-row: 2; font-size: 46px; }
body[data-kids-game="letter-pop"] .kids-pop-cheer strong { max-width: 160px; color: #1769ff; font-size: 18px; line-height: 1.12; }

body[data-kids-game="letter-pop"] .kids-pop-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 14px;
  padding: 14px;
  background: #f7fbff;
}

body[data-kids-game="letter-pop"] .kids-pop-main { min-width: 0; }

body[data-kids-game="letter-pop"] .kids-pop-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 9px;
  margin-bottom: 10px;
}

body[data-kids-game="letter-pop"] .kids-pop-stat {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  gap: 1px 9px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid rgba(203, 213, 225, .65);
  border-radius: 16px;
}

body[data-kids-game="letter-pop"] .kids-pop-stat > span { grid-row: 1 / 3; font-size: 27px; }
body[data-kids-game="letter-pop"] .kids-pop-stat small { color: #5b6c84; font-size: 10px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
body[data-kids-game="letter-pop"] .kids-pop-stat strong { color: #0f172a; font-size: 20px; white-space: nowrap; }
body[data-kids-game="letter-pop"] .kids-pop-stat.blue { background: #eaf4ff; }
body[data-kids-game="letter-pop"] .kids-pop-stat.green { background: #ebfaef; }
body[data-kids-game="letter-pop"] .kids-pop-stat.purple { background: #f3ecff; }
body[data-kids-game="letter-pop"] .kids-pop-stat.gold { background: #fff6dc; }
body[data-kids-game="letter-pop"] .kids-pop-stat.pink { background: #ffecef; }
body[data-kids-game="letter-pop"] .kids-pop-stat [data-game-lives] { color: #e11d48 !important; font-size: 17px; letter-spacing: 1px; }

body[data-kids-game="letter-pop"] .kids-pop-stage {
  position: relative;
  min-height: 410px;
  padding: 0;
  overflow: hidden;
  border-radius: 20px;
  background: linear-gradient(180deg, #55c9f5 0%, #9be7ff 46%, #a8e1a0 47%, #68c75f 77%, #58ac46 100%);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .28), inset 0 -16px 28px rgba(57, 126, 55, .14);
}

body[data-kids-game="letter-pop"] .kids-pop-stage::after {
  content: "";
  position: absolute;
  z-index: 4;
  right: 0;
  bottom: 0;
  left: 0;
  height: 24px;
  border-top: 6px solid #f0cf8a;
  background: linear-gradient(180deg, #d7a65c, #b97838);
}

body[data-kids-game="letter-pop"] .kids-pop-scenery { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
body[data-kids-game="letter-pop"] .kids-pop-cloud { position: absolute; width: 96px; height: 30px; border-radius: 999px; background: rgba(255, 255, 255, .76); filter: drop-shadow(0 5px 8px rgba(49, 114, 155, .08)); }
body[data-kids-game="letter-pop"] .kids-pop-cloud::before,
body[data-kids-game="letter-pop"] .kids-pop-cloud::after { content: ""; position: absolute; border-radius: 50%; background: inherit; }
body[data-kids-game="letter-pop"] .kids-pop-cloud::before { top: -17px; left: 14px; width: 42px; height: 42px; }
body[data-kids-game="letter-pop"] .kids-pop-cloud::after { top: -24px; right: 10px; width: 52px; height: 52px; }
body[data-kids-game="letter-pop"] .cloud-one { top: 20%; left: 7%; }
body[data-kids-game="letter-pop"] .cloud-two { top: 12%; left: 45%; transform: scale(.82); }
body[data-kids-game="letter-pop"] .cloud-three { top: 25%; right: 8%; transform: scale(.72); }
body[data-kids-game="letter-pop"] .kids-pop-sun { position: absolute; top: 5%; right: 6%; font-size: 62px; filter: drop-shadow(0 8px 10px rgba(245, 158, 11, .18)); }
body[data-kids-game="letter-pop"] .kids-pop-rainbow { position: absolute; right: -9px; bottom: 92px; font-size: 78px; opacity: .9; }
body[data-kids-game="letter-pop"] .kids-pop-hill { position: absolute; bottom: 52px; border-radius: 50% 50% 0 0; background: #43b16b; opacity: .84; }
body[data-kids-game="letter-pop"] .hill-one { left: -7%; width: 58%; height: 105px; transform: skewX(-12deg); }
body[data-kids-game="letter-pop"] .hill-two { right: -9%; width: 64%; height: 125px; background: #5fc276; transform: skewX(9deg); }
body[data-kids-game="letter-pop"] .kids-pop-tree { position: absolute; z-index: 2; bottom: 34px; font-size: 72px; }
body[data-kids-game="letter-pop"] .tree-one { left: 2%; }
body[data-kids-game="letter-pop"] .tree-two { right: 2%; transform: scale(.85); }
body[data-kids-game="letter-pop"] .kids-pop-flowers { position: absolute; z-index: 3; right: 12%; bottom: 33px; left: 12%; text-align: center; font-size: 23px; letter-spacing: 18px; }

body[data-kids-game="letter-pop"] .kids-pop-time-badge {
  position: absolute;
  z-index: 9;
  top: 12px;
  left: 12px;
  display: grid;
  min-width: 92px;
  padding: 7px 10px;
  border-radius: 12px;
  background: rgba(26, 77, 125, .84);
  color: #fff;
  box-shadow: 0 7px 18px rgba(15, 23, 42, .16);
}

body[data-kids-game="letter-pop"] .kids-pop-time-badge small { font-size: 9px; font-weight: 900; letter-spacing: .08em; }
body[data-kids-game="letter-pop"] .kids-pop-time-badge strong { font-size: 18px; }

body[data-kids-game="letter-pop"] .kids-pop-level-progress {
  position: absolute;
  z-index: 9;
  top: 12px;
  left: 50%;
  width: min(390px, 48%);
  padding: 8px 12px 10px;
  border: 1px solid rgba(255, 255, 255, .78);
  border-radius: 13px;
  background: rgba(255, 255, 255, .82);
  box-shadow: 0 7px 18px rgba(15, 23, 42, .08);
  transform: translateX(-50%);
  backdrop-filter: blur(5px);
}

body[data-kids-game="letter-pop"] .kids-pop-level-progress > div { display: flex; justify-content: space-between; gap: 12px; color: #173b6d; font-size: 10px; font-weight: 900; }
body[data-kids-game="letter-pop"] .kids-pop-level-progress > span { display: block; height: 9px; margin-top: 5px; overflow: hidden; border-radius: 999px; background: #dce8f5; }
body[data-kids-game="letter-pop"] .kids-pop-level-progress i { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #22c55e, #16a34a); transition: width .25s ease; }

body[data-kids-game="letter-pop"] .kids-pop-sign {
  position: absolute;
  z-index: 7;
  bottom: 38px;
  left: 3%;
  min-width: 122px;
  padding: 12px 13px;
  border: 4px solid #75451f;
  border-radius: 10px;
  background: #a96b31;
  color: #fff;
  text-align: center;
  font-weight: 900;
  line-height: 1.15;
  box-shadow: 0 9px 20px rgba(72, 42, 16, .18);
}

body[data-kids-game="letter-pop"] .kids-pop-sign b { color: #fff5a8; font-size: 22px; letter-spacing: 2px; }

body[data-kids-game="letter-pop"] .kids-pop-praise {
  position: absolute;
  z-index: 7;
  right: 4%;
  bottom: 45px;
  padding: 13px 16px;
  border: 3px solid rgba(255, 255, 255, .88);
  border-radius: 48% 52% 48% 52%;
  background: rgba(255, 255, 255, .9);
  color: #1769ff;
  font-size: 17px;
  transform: rotate(-4deg);
  box-shadow: 0 10px 22px rgba(15, 23, 42, .10);
}

body[data-kids-game="letter-pop"] .kids-pop-target-layer {
  position: absolute;
  z-index: 8;
  inset: 0;
  display: block;
  min-height: 0;
  pointer-events: none;
}

body[data-kids-game="letter-pop"] .kids-pop-target-layer:not(:has(.kids-pop-target)) {
  display: grid;
  place-items: center;
  color: #164a76;
  font-size: 28px;
  font-weight: 900;
}

body[data-kids-game="letter-pop"] .kids-pop-target {
  --pop-size: var(--pop-level-size, 142px);
  position: absolute;
  top: var(--pop-y, 52%);
  left: var(--pop-x, 50%);
  width: var(--pop-size);
  height: var(--pop-size);
  font-size: var(--pop-level-font, 65px);
  transform: translate(-50%, -50%);
  animation: kidsPopFloat 2.2s ease-in-out infinite;
}

body[data-kids-game="letter-pop"] .kids-pop-ring {
  position: absolute;
  inset: -13px;
  width: calc(100% + 26px);
  height: calc(100% + 26px);
  overflow: visible;
  transform: rotate(-90deg);
  filter: drop-shadow(0 4px 7px rgba(23, 105, 255, .18));
}

body[data-kids-game="letter-pop"] .kids-pop-ring-bg,
body[data-kids-game="letter-pop"] .kids-pop-ring-countdown { fill: none; stroke-width: 7; }
body[data-kids-game="letter-pop"] .kids-pop-ring-bg { stroke: rgba(255, 255, 255, .58); }
body[data-kids-game="letter-pop"] .kids-pop-ring-countdown {
  stroke: #1769ff;
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 0;
  animation: kidsPopCountdown var(--pop-duration, 4.8s) linear forwards;
}

body[data-kids-game="letter-pop"] .kids-pop-balloon {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border: 4px solid rgba(255, 255, 255, .64);
  border-radius: 52% 52% 48% 48%;
  background: linear-gradient(145deg, rgba(255, 255, 255, .40) 0 8%, transparent 9%), linear-gradient(150deg, var(--pop-light, #ff718f), var(--pop-color, #ef174f) 68%, var(--pop-dark, #b80835));
  color: #fff;
  font: 900 1em/1 Poppins, sans-serif;
  text-shadow: 0 3px 4px rgba(0, 0, 0, .16);
  box-shadow: inset -10px -14px 18px rgba(85, 10, 45, .13), inset 9px 12px 14px rgba(255, 255, 255, .20), 0 18px 28px rgba(23, 53, 89, .18);
}

body[data-kids-game="letter-pop"] .kids-pop-balloon::before {
  content: "";
  position: absolute;
  top: 11%;
  left: 21%;
  width: 18%;
  height: 28%;
  border-radius: 50%;
  background: rgba(255, 255, 255, .58);
  transform: rotate(28deg);
}

body[data-kids-game="letter-pop"] .kids-pop-balloon::after {
  content: "";
  position: absolute;
  bottom: -12px;
  left: 50%;
  width: 15px;
  height: 16px;
  background: var(--pop-dark, #b80835);
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  transform: translateX(-50%);
}

body[data-kids-game="letter-pop"] .kids-pop-string {
  position: absolute;
  top: calc(100% + 11px);
  left: 50%;
  width: 1px;
  height: 44px;
  background: #42526b;
  transform: translateX(-50%) rotate(4deg);
  transform-origin: top;
}

body[data-kids-game="letter-pop"] .kids-pop-sparkles {
  position: absolute;
  inset: -22px;
  display: grid;
  place-items: center;
  color: #fff59d;
  font-size: 26px;
  letter-spacing: 2.2em;
  opacity: 0;
}

body[data-kids-game="letter-pop"] .kids-pop-target.is-popped { animation: kidsPopBurst .22s ease-out forwards; }
body[data-kids-game="letter-pop"] .kids-pop-target.is-popped .kids-pop-ring-countdown { animation-play-state: paused; }
body[data-kids-game="letter-pop"] .kids-pop-target.is-popped .kids-pop-sparkles { animation: kidsPopSparkles .25s ease-out forwards; }
body[data-kids-game="letter-pop"] .kids-pop-stage.is-paused .kids-pop-target,
body[data-kids-game="letter-pop"] .kids-pop-stage.is-paused .kids-pop-ring-countdown { animation-play-state: paused; }

body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished::before {
  content: "";
  position: absolute;
  z-index: 5;
  inset: 0;
  background: linear-gradient(180deg, rgba(218, 246, 255, .54), rgba(238, 255, 224, .68));
  backdrop-filter: blur(2px);
}

body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished .kids-pop-scenery { opacity: .58; filter: saturate(.82); }
body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished .kids-pop-time-badge,
body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished .kids-pop-level-progress,
body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished .kids-pop-sign,
body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished .kids-pop-praise { visibility: hidden; opacity: 0; }
body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished + .kids-pop-controls { display: none; }
body[data-kids-game="letter-pop"] .kids-pop-message[hidden] { display: none !important; }

body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished .kids-pop-target-layer {
  z-index: 10;
  padding: 16px;
  pointer-events: auto;
}

body[data-kids-game="letter-pop"] .kids-pop-result-card {
  width: min(650px, calc(100% - 24px));
  padding: 16px 18px 18px;
  border: 3px solid rgba(255, 255, 255, .94);
  border-radius: 24px;
  background: rgba(255, 255, 255, .95);
  color: #173b6d;
  text-align: center;
  box-shadow: 0 20px 48px rgba(31, 85, 119, .24), inset 0 0 0 1px #d9eaff;
  backdrop-filter: blur(8px);
}

body[data-kids-game="letter-pop"] .kids-pop-result-card:focus { outline: none; }
body[data-kids-game="letter-pop"] .kids-pop-result-heading { display: flex; justify-content: center; gap: 12px; align-items: center; height: 42px; }
body[data-kids-game="letter-pop"] .kids-pop-result-star { color: #fbbf24; font-size: 22px; filter: drop-shadow(0 3px 4px rgba(180, 105, 0, .14)); }
body[data-kids-game="letter-pop"] .kids-pop-result-balloon { font-size: 43px; filter: drop-shadow(0 5px 7px rgba(23, 105, 255, .18)); }
body[data-kids-game="letter-pop"] .kids-pop-result-kicker { margin: 1px 0 0; color: #1769ff; font: 900 10px/1 Inter, sans-serif; letter-spacing: .14em; }
body[data-kids-game="letter-pop"] .kids-pop-result-card h2 { margin: 4px 0 3px; color: #102a72; font: 900 clamp(25px, 4vw, 34px)/1.08 Poppins, sans-serif; }
body[data-kids-game="letter-pop"] .kids-pop-result-copy { margin: 0 auto 10px; color: #46607e; font: 700 13px/1.35 Inter, sans-serif; }

body[data-kids-game="letter-pop"] .kids-pop-result-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 auto 9px;
}

body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 7px;
  align-items: center;
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid #dbe9fb;
  border-radius: 13px;
  background: #f3f8ff;
  text-align: left;
}

body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div:nth-child(2) { background: #f3edff; }
body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div:nth-child(3) { background: #fff4e1; }
body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div:nth-child(4) { background: #effbef; }
body[data-kids-game="letter-pop"] .kids-pop-result-metrics span { grid-row: 1 / 3; font-size: 24px; }
body[data-kids-game="letter-pop"] .kids-pop-result-metrics small { overflow: hidden; color: #64748b; font: 800 9px/1.1 Inter, sans-serif; text-overflow: ellipsis; white-space: nowrap; }
body[data-kids-game="letter-pop"] .kids-pop-result-metrics strong { color: #102a72; font: 900 18px/1.15 Poppins, sans-serif; }
body[data-kids-game="letter-pop"] .kids-pop-result-best { display: inline-block; margin: 0 0 10px; padding: 6px 12px; border-radius: 999px; background: #fff6ce; color: #8a4b08; font: 800 12px/1.2 Inter, sans-serif; }

body[data-kids-game="letter-pop"] .kids-pop-result-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
body[data-kids-game="letter-pop"] .kids-pop-result-actions .kids-button {
  display: flex;
  justify-content: center;
  gap: 6px;
  align-items: center;
  min-width: 0;
  min-height: 43px;
  margin: 0;
  padding: 9px 11px;
  border-radius: 12px;
  font-size: 12px;
  line-height: 1.15;
  white-space: normal;
}
body[data-kids-game="letter-pop"] .kids-pop-result-primary { box-shadow: 0 7px 16px rgba(23, 105, 255, .24); }
body[data-kids-game="letter-pop"] .kids-pop-result-next { background: #13a66a; box-shadow: 0 7px 16px rgba(19, 166, 106, .20); }
body[data-kids-game="letter-pop"] .kids-pop-result-next:hover { background: #0d8c59; }

@keyframes kidsPopCountdown { to { stroke-dashoffset: 100; } }
@keyframes kidsPopFloat { 50% { transform: translate(-50%, calc(-50% - 7px)) rotate(1.5deg); } }
@keyframes kidsPopBurst { to { opacity: 0; transform: translate(-50%, -50%) scale(1.32); filter: saturate(1.35); } }
@keyframes kidsPopSparkles { 35% { opacity: 1; transform: scale(1.12) rotate(7deg); } 100% { opacity: 0; transform: scale(1.45) rotate(12deg); } }

body[data-kids-game="letter-pop"] .kids-pop-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: stretch;
  margin-top: 10px;
}

body[data-kids-game="letter-pop"] .kids-pop-start { min-width: 142px; box-shadow: none; }
body[data-kids-game="letter-pop"] .kids-pop-control {
  min-height: 44px;
  padding: 10px 13px;
  border: 1px solid #cbd9ee;
  border-radius: 12px;
  background: #edf4ff;
  color: #173b6d;
  font: 800 13px/1 Inter, sans-serif;
  cursor: pointer;
}
body[data-kids-game="letter-pop"] .kids-pop-control:hover { border-color: #aec6e9; background: #e3efff; }
body[data-kids-game="letter-pop"] .kids-pop-control:focus-visible,
body[data-kids-game="letter-pop"] .kids-pop-start:focus-visible { outline: 3px solid rgba(23, 105, 255, .28); outline-offset: 2px; }

body[data-kids-game="letter-pop"] .kids-pop-motivation {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  gap: 0 8px;
  align-items: center;
  min-width: 225px;
  margin-left: auto;
  padding: 7px 11px;
  border: 1px solid #c9efd1;
  border-radius: 12px;
  background: #eefcf1;
}
body[data-kids-game="letter-pop"] .kids-pop-motivation > span { grid-row: 1 / 3; font-size: 28px; }
body[data-kids-game="letter-pop"] .kids-pop-motivation strong { color: #14532d; font-size: 13px; }
body[data-kids-game="letter-pop"] .kids-pop-motivation small { color: #4d735a; font-size: 10px; }

body[data-kids-game="letter-pop"] .kids-pop-message {
  min-height: 40px;
  margin: 8px 0 0;
  padding: 9px 12px;
  border: 1px solid #d6e8ff;
  border-radius: 12px;
  background: #eef6ff;
  color: #174ea6;
  font-weight: 800;
}

body[data-kids-game="letter-pop"] .kids-pop-keyboard-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); clip-path: inset(50%); white-space: nowrap; }

body[data-kids-game="letter-pop"] .kids-pop-side { display: grid; gap: 12px; align-content: start; }
body[data-kids-game="letter-pop"] .kids-pop-side-card { padding: 16px; border: 1px solid #dbe6f5; border-radius: 18px; background: #fff; box-shadow: 0 10px 24px rgba(15, 23, 42, .06); }
body[data-kids-game="letter-pop"] .kids-pop-side-card h2 { display: flex; gap: 8px; align-items: center; margin: 0 0 12px; font-size: 20px; }
body[data-kids-game="letter-pop"] .kids-pop-steps { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
body[data-kids-game="letter-pop"] .kids-pop-steps li { display: grid; grid-template-columns: 28px 42px 1fr; gap: 8px; align-items: center; padding: 9px; border-radius: 14px; background: #f1f7ff; color: #334155; font-size: 12px; font-weight: 700; }
body[data-kids-game="letter-pop"] .kids-pop-steps li > b { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #1769ff; color: #fff; }
body[data-kids-game="letter-pop"] .kids-pop-steps li:nth-child(2) > b { background: #10b981; }
body[data-kids-game="letter-pop"] .kids-pop-steps li:nth-child(3) > b { background: #f59e0b; }
body[data-kids-game="letter-pop"] .kids-pop-steps .step-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; color: #fff; font-size: 20px; font-weight: 900; }
body[data-kids-game="letter-pop"] .kids-pop-steps .step-icon.red { border-radius: 52%; background: #ef174f; }
body[data-kids-game="letter-pop"] .kids-pop-steps .step-icon.blue { background: #1684ef; }
body[data-kids-game="letter-pop"] .kids-pop-steps .step-icon.gold { background: #fbbf24; }
body[data-kids-game="letter-pop"] .kids-pop-tip { display: flex; gap: 9px; align-items: center; margin-top: 10px; padding: 10px; border-radius: 12px; background: linear-gradient(135deg, #fff7db, #fffdf3); color: #1d4ed8; font-size: 12px; line-height: 1.35; }
body[data-kids-game="letter-pop"] .kids-pop-tip > span { font-size: 27px; }
body[data-kids-game="letter-pop"] .kids-pop-side-heading { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
body[data-kids-game="letter-pop"] .kids-pop-side-heading h2 { margin: 0; }
body[data-kids-game="letter-pop"] .kids-pop-side-heading a { color: #1769ff; font-size: 11px; font-weight: 800; }
body[data-kids-game="letter-pop"] .kids-pop-progress-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 12px; }
body[data-kids-game="letter-pop"] .kids-pop-progress-grid > div { display: grid; justify-items: center; gap: 3px; padding: 10px 5px; border: 1px solid #e2ebf8; border-radius: 12px; background: #f8fbff; text-align: center; }
body[data-kids-game="letter-pop"] .kids-pop-progress-grid > div > span { font-size: 28px; }
body[data-kids-game="letter-pop"] .kids-pop-progress-grid > div > strong { color: #173b6d; font-size: 15px; }
body[data-kids-game="letter-pop"] .kids-pop-progress-grid > div > small { color: #64748b; font-size: 9px; line-height: 1.2; }

body[data-kids-game="letter-pop"] .kids-pop-related { padding: 14px 16px; border: 1px solid #dbe6f5; border-radius: 22px; background: #fff; box-shadow: 0 12px 28px rgba(15, 23, 42, .06); }
body[data-kids-game="letter-pop"] .kids-pop-related-heading { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 10px; }
body[data-kids-game="letter-pop"] .kids-pop-related-heading h2 { margin: 0; font-size: 20px; }
body[data-kids-game="letter-pop"] .kids-pop-related-heading a { color: #1769ff; font-size: 12px; font-weight: 800; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid > a { display: grid; grid-template-columns: 110px 1fr; min-width: 0; overflow: hidden; border: 1px solid #dbe6f5; border-radius: 16px; background: #f9fbff; color: #0f172a; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid > a:nth-child(2) { background: #fff8fb; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid > a:nth-child(3) { background: #fffbee; }
body[data-kids-game="letter-pop"] .kids-pop-related .related-visual { display: grid; place-items: center; min-height: 96px; background: linear-gradient(135deg, #c9eeff, #e8f9ff); font-size: 24px; }
body[data-kids-game="letter-pop"] .kids-pop-related .related-visual.race { background: linear-gradient(135deg, #dff6ff, #d8f9e2); }
body[data-kids-game="letter-pop"] .kids-pop-related .related-visual.stack { background: linear-gradient(135deg, #ecfdf5, #fff7d8); }
body[data-kids-game="letter-pop"] .kids-pop-related-grid > a > div { padding: 11px; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid strong { display: block; font-size: 15px; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid p { margin: 4px 0 8px; color: #64748b; font-size: 11px; line-height: 1.35; }
body[data-kids-game="letter-pop"] .kids-pop-related-grid b { color: #1769ff; font-size: 11px; }
body[data-kids-game="letter-pop"] .kids-pop-seo-copy { margin-top: 14px; }

html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-hero { border-color: #30425e; background: linear-gradient(135deg, #10203a, #111b2e 62%, #201c13); }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-hero h1 { color: #f8fafc; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-hero p { color: #cbd5e1; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-layout { background: #0e1727; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-side-card,
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-related { border-color: #30425e; background: #111c2f; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-steps li,
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-progress-grid > div { border-color: #30425e; background: #17243a; color: #dbeafe; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-progress-grid > div > strong { color: #dbeafe; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-control { border-color: #40516d; background: #17243a; color: #eaf2ff; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-message { border-color: #2d4f79; background: #132641; color: #bfdbfe; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-card { border-color: rgba(135, 171, 216, .56); background: rgba(15, 29, 51, .96); color: #eaf2ff; box-shadow: 0 20px 48px rgba(0, 0, 0, .35), inset 0 0 0 1px #304a6c; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-card h2 { color: #f8fafc; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-copy { color: #c7d7ea; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div { border-color: #355071; background: #172b46; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div:nth-child(2),
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div:nth-child(3),
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-metrics > div:nth-child(4) { background: #172b46; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-result-metrics strong { color: #fff; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-related-grid > a { border-color: #30425e; background: #162338; color: #f8fafc; }
html[data-theme="dark"] body[data-kids-game="letter-pop"] .kids-pop-related-grid p { color: #b8c7db; }

body[data-kids-game="letter-pop"] .kids-pop-workspace:fullscreen { overflow: auto; padding: 16px; background: #f7fbff; }
body[data-kids-game="letter-pop"] .kids-pop-workspace:fullscreen .kids-pop-stage { min-height: min(62vh, 650px); }

@media (max-width: 1120px) {
  body[data-kids-game="letter-pop"] .kids-pop-layout { grid-template-columns: 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-side { grid-template-columns: 1.25fr 1fr; }
}

@media (max-width: 850px) {
  body[data-kids-game="letter-pop"] .kids-pop-hero { grid-template-columns: 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-cheer { display: none; }
  body[data-kids-game="letter-pop"] .kids-pop-stats { grid-template-columns: repeat(3, 1fr); }
  body[data-kids-game="letter-pop"] .kids-pop-stat:nth-child(4),
  body[data-kids-game="letter-pop"] .kids-pop-stat:nth-child(5) { grid-column: span 1; }
  body[data-kids-game="letter-pop"] .kids-pop-stage { min-height: 360px; }
  body[data-kids-game="letter-pop"] .kids-pop-side { grid-template-columns: 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-related-grid { grid-template-columns: 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-target { --pop-size: min(var(--pop-level-size, 118px), 118px); font-size: min(var(--pop-level-font, 54px), 54px); }
}

@media (max-width: 620px) {
  body[data-kids-game="letter-pop"] .kids-pop-hero { padding: 15px; }
  body[data-kids-game="letter-pop"] .kids-pop-title-wrap { gap: 10px; align-items: flex-start; }
  body[data-kids-game="letter-pop"] .kids-pop-logo { flex-basis: 58px; width: 58px; height: 54px; transform: scale(.82); transform-origin: top left; }
  body[data-kids-game="letter-pop"] .kids-pop-layout { padding: 8px; }
  body[data-kids-game="letter-pop"] .kids-pop-stats { grid-template-columns: repeat(2, 1fr); }
  body[data-kids-game="letter-pop"] .kids-pop-stat:last-child { grid-column: 1 / -1; }
  body[data-kids-game="letter-pop"] .kids-pop-stage { min-height: 330px; border-radius: 16px; }
  body[data-kids-game="letter-pop"] .kids-pop-level-progress { top: 58px; width: calc(100% - 24px); }
  body[data-kids-game="letter-pop"] .kids-pop-sign,
  body[data-kids-game="letter-pop"] .kids-pop-praise,
  body[data-kids-game="letter-pop"] .kids-pop-rainbow { display: none; }
  body[data-kids-game="letter-pop"] .kids-pop-tree { font-size: 52px; }
  body[data-kids-game="letter-pop"] .kids-pop-sun { font-size: 47px; }
  body[data-kids-game="letter-pop"] .kids-pop-target { --pop-size: min(var(--pop-level-size, 88px), 88px); font-size: min(var(--pop-level-font, 40px), 40px); }
  body[data-kids-game="letter-pop"] .kids-pop-controls { display: grid; grid-template-columns: 1fr 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-start,
  body[data-kids-game="letter-pop"] .kids-pop-motivation { grid-column: 1 / -1; margin-left: 0; }
  body[data-kids-game="letter-pop"] .kids-pop-progress-grid { grid-template-columns: repeat(3, 1fr); }
  body[data-kids-game="letter-pop"] .kids-pop-related-grid > a { grid-template-columns: 88px 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished { min-height: 430px; }
  body[data-kids-game="letter-pop"] .kids-pop-result-card { width: calc(100% - 8px); padding: 14px; }
  body[data-kids-game="letter-pop"] .kids-pop-result-actions { grid-template-columns: 1fr 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-result-more { grid-column: 1 / -1; }
}

@media (max-width: 420px) {
  body[data-kids-game="letter-pop"] .kids-pop-stage { min-height: 300px; }
  body[data-kids-game="letter-pop"] .kids-pop-target { --pop-size: min(var(--pop-level-size, 72px), 72px); font-size: min(var(--pop-level-font, 33px), 33px); }
  body[data-kids-game="letter-pop"] .kids-pop-ring { inset: -9px; width: calc(100% + 18px); height: calc(100% + 18px); }
  body[data-kids-game="letter-pop"] .kids-pop-string { height: 30px; }
  body[data-kids-game="letter-pop"] .kids-pop-stage.is-finished { min-height: 500px; }
  body[data-kids-game="letter-pop"] .kids-pop-result-metrics { grid-template-columns: 1fr 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-result-actions { grid-template-columns: 1fr; }
  body[data-kids-game="letter-pop"] .kids-pop-result-more { grid-column: auto; }
}

@media (prefers-reduced-motion: reduce) {
  body[data-kids-game="letter-pop"] .kids-pop-target { animation: none; }
  body[data-kids-game="letter-pop"] .kids-pop-ring-countdown { animation-timing-function: steps(10, end); }
}
