:root {
  color-scheme: light;
  font-family: "Trebuchet MS", "Arial Rounded MT Bold", Arial, sans-serif;
  --ink: #294f4b;
  --muted: #69817c;
  --paper: #fffdf7;
  --line: #ded5b8;
  --green: #62b78b;
  --green-dark: #34775e;
  --gold: #f4bd4d;
  --coral: #ef756b;
  --blue: #65acd3;
  --purple: #8b76bd;
  --shadow: 0 18px 44px rgba(60, 82, 75, .14);
  --soft-shadow: 0 9px 23px rgba(60, 82, 75, .1);
}

* { box-sizing: border-box; }

html {
  min-width: 320px;
  min-height: 100%;
  background: #f3f9ed;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: clip;
  color: var(--ink);
  background:
    radial-gradient(circle at 7% 8%, rgba(246, 193, 71, .2) 0 118px, transparent 120px),
    radial-gradient(circle at 94% 9%, rgba(100, 173, 215, .17) 0 152px, transparent 154px),
    linear-gradient(145deg, #f3f9ed 0%, #fffaf1 53%, #f3effc 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: .14;
  background-image: radial-gradient(#6f9186 1px, transparent 1px);
  background-size: 26px 26px;
  content: '';
  pointer-events: none;
}

button { color: inherit; font: inherit; }
button:not(:disabled) { cursor: pointer; }
button:focus-visible { outline: 4px solid rgba(241, 185, 67, .7); outline-offset: 4px; }
h1, h2, h3, p { margin-top: 0; }

.app {
  width: min(1120px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  padding: 22px 0 50px;
}

.loading-card {
  display: grid;
  width: min(410px, 100%);
  min-height: 250px;
  margin: 20vh auto 0;
  place-items: center;
  align-content: center;
  gap: 10px;
  text-align: center;
  background: var(--paper);
  border: 3px solid var(--line);
  border-radius: 37px;
  box-shadow: var(--shadow);
}

.loading-card span { font-size: 64px; animation: float 1.3s ease-in-out infinite alternate; }
.loading-card p { margin: 0; font-size: 19px; font-weight: 900; }

.topbar,
.topbar-actions,
.brand,
.collection-button,
.sound-button,
.section-heading,
.level-top,
.level-footer,
.game-heading,
.mission-strip,
.answer-heading,
.feedback-card,
.result-actions,
.result-stats {
  display: flex;
  align-items: center;
}

.topbar {
  position: relative;
  z-index: 30;
  min-height: 66px;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.brand {
  min-width: 0;
  gap: 12px;
  padding: 0;
  text-align: left;
  background: none;
  border: 0;
}

.brand-mark {
  display: grid;
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  place-items: center;
  padding-bottom: 2px;
  color: #39775f;
  font-size: 29px;
  font-weight: 1000;
  background: #fff6cd;
  border: 3px solid #dfd2a8;
  border-radius: 19px;
  box-shadow: 0 7px 16px rgba(67, 87, 78, .12);
  transform: rotate(-4deg);
}

.brand strong,
.brand small,
.collection-button strong,
.collection-button small { display: block; }
.brand strong { overflow: hidden; font-size: 24px; font-weight: 1000; line-height: 1.05; text-overflow: ellipsis; white-space: nowrap; }
.brand small { margin-top: 3px; color: var(--muted); font-size: 10px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.topbar-actions { flex: 0 0 auto; gap: 9px; }
.top-spark { color: var(--gold); font-size: 27px; animation: twinkle 2s ease-in-out infinite; }

.collection-button,
.sound-button,
.back-button {
  min-height: 49px;
  color: var(--ink);
  font-weight: 900;
  background: rgba(255, 253, 247, .94);
  border: 2px solid var(--line);
  border-radius: 17px;
  box-shadow: 0 7px 16px rgba(65, 83, 76, .08);
}

.collection-button { gap: 9px; padding: 5px 13px; text-align: left; }
.collection-button > span:first-child { font-size: 21px; }
.collection-button strong { font-size: 12px; line-height: 1.05; }
.collection-button small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.sound-button { gap: 8px; padding: 0 14px; font-size: 12px; }
.back-button { width: 49px; padding: 0 0 3px; font-size: 23px; }

.eyebrow {
  margin: 0 0 8px;
  color: #397b62;
  font-family: Georgia, serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.primary-button,
.secondary-button,
.hint-button {
  display: inline-flex;
  min-height: 53px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 21px;
  font-weight: 1000;
  border-radius: 17px;
  transition: transform 150ms ease, box-shadow 150ms ease, opacity 150ms ease;
}

.primary-button { color: #fff; background: #3e9875; border: 0; box-shadow: 0 8px 0 #2f785e, 0 16px 27px rgba(49, 122, 94, .2); }
.secondary-button { color: var(--ink); background: #fffdf6; border: 2px solid #d7d2b9; box-shadow: 0 6px 0 #ddd7c4; }
.hint-button { min-height: 46px; color: #715418; background: #fff3c5; border: 2px solid #e7bd50; box-shadow: 0 5px 0 #d8aa39; }
.primary-button.compact { min-height: 46px; padding-inline: 17px; box-shadow: 0 5px 0 #2f785e; }
.primary-button:not(:disabled):hover,
.secondary-button:not(:disabled):hover,
.hint-button:not(:disabled):hover,
.collection-button:not(:disabled):hover,
.sound-button:not(:disabled):hover { transform: translateY(-2px); }
.primary-button:not(:disabled):active,
.secondary-button:not(:disabled):active,
.hint-button:not(:disabled):active { transform: translateY(3px); box-shadow: none; }
button:disabled { cursor: default; opacity: .72; }

.hero {
  position: relative;
  display: grid;
  min-height: 408px;
  grid-template-columns: minmax(0, .93fr) minmax(430px, 1.07fr);
  align-items: center;
  gap: 28px;
  overflow: hidden;
  padding: 47px 50px;
  background:
    radial-gradient(circle at 96% 10%, rgba(105, 177, 216, .18) 0 104px, transparent 106px),
    radial-gradient(circle at 70% -12%, rgba(245, 188, 70, .21) 0 114px, transparent 116px),
    linear-gradient(120deg, #fffaf0, #f3f0fd 68%, #ebf8ef);
  border: 3px solid #ded6ba;
  border-radius: 40px;
  box-shadow: var(--shadow);
}

.hero::after {
  position: absolute;
  right: -43px;
  bottom: -71px;
  width: 190px;
  height: 190px;
  background: rgba(99, 184, 139, .15);
  border-radius: 50%;
  content: '';
}

.hero-copy { position: relative; z-index: 3; }
.hero h1 { margin: 0 0 16px; font-size: clamp(48px, 5.4vw, 72px); font-weight: 1000; line-height: .95; letter-spacing: -.045em; }
.hero-copy > p:not(.eyebrow) { max-width: 540px; margin-bottom: 25px; color: var(--muted); font-size: 17px; font-weight: 700; line-height: 1.5; }
.hero-scene { position: relative; z-index: 2; min-height: 285px; }

.hero-book {
  position: absolute;
  inset: 24px 8px 27px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  filter: drop-shadow(0 21px 20px rgba(63, 78, 72, .16));
  transform: rotate(2deg);
}

.book-page {
  position: relative;
  overflow: hidden;
  min-width: 0;
  padding: 25px;
  background: #fffdfa;
  border: 4px solid #d9cfaa;
}

.book-page.left { border-right: 0; border-radius: 27px 4px 4px 27px; }
.book-page.right { border-left: 0; border-radius: 4px 27px 27px 4px; }
.book-page.left small { display: block; color: #6c827a; font-family: Georgia, serif; font-size: 10px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.book-page.left > strong { display: block; margin-top: 14px; color: #3d8c6f; font-size: 62px; line-height: 1; }
.book-spine { position: absolute; z-index: 4; top: 6px; bottom: 6px; left: calc(50% - 5px); width: 10px; background: linear-gradient(90deg, #d5c8a3, #fffdf7 50%, #cfc29e); border-radius: 50%; }
.hero-picture { position: absolute; right: 10px; bottom: 5px; width: 130px; height: 130px; }
.hero-picture .picture-emoji { font-size: 76px; }

.hero-letter-card {
  position: absolute;
  display: grid;
  width: 91px;
  height: 103px;
  place-items: center;
  align-content: center;
  gap: 3px;
  color: #fff;
  background: var(--card-color);
  border: 4px solid rgba(42, 78, 72, .25);
  border-radius: 22px;
  box-shadow: 0 8px 12px rgba(53, 74, 68, .14);
}
.hero-letter-card b { font-size: 35px; line-height: 1; }
.hero-letter-card i { font-family: "Segoe UI Emoji", sans-serif; font-size: 28px; font-style: normal; }
.hero-letter-card.card-0 { top: 34px; left: 30px; transform: rotate(-8deg); }
.hero-letter-card.card-1 { top: 85px; left: 117px; transform: rotate(7deg); }
.hero-letter-card.card-2 { right: 15px; bottom: 12px; transform: rotate(-4deg); }
.hero-note { position: absolute; right: 40px; bottom: 2px; padding: 9px 14px; color: #fff; font-size: 12px; font-weight: 900; background: #477e71; border-radius: 14px; box-shadow: var(--soft-shadow); transform: rotate(-2deg); }

.how-section,
.levels-section,
.collection-section { margin-top: 54px; scroll-margin-top: 22px; }
.section-heading { justify-content: space-between; gap: 25px; margin-bottom: 20px; }
.section-heading h2 { margin: 0; font-size: 39px; font-weight: 1000; line-height: 1; letter-spacing: -.035em; }
.section-heading > p { max-width: 410px; margin: 0; color: var(--muted); font-size: 13px; font-weight: 800; line-height: 1.45; text-align: right; }
.steps-grid,
.levels-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }

.step-card {
  display: flex;
  min-width: 0;
  min-height: 130px;
  align-items: center;
  gap: 16px;
  padding: 23px;
  background: rgba(255, 253, 247, .92);
  border: 2px solid var(--line);
  border-radius: 29px;
  box-shadow: var(--soft-shadow);
}

.step-number {
  display: grid;
  flex: 0 0 auto;
  width: 62px;
  height: 62px;
  place-items: center;
  padding-bottom: 3px;
  color: #fff;
  font-family: Georgia, serif;
  font-size: 27px;
  font-weight: 900;
  background: #66b98e;
  border: 8px solid #dcf1e5;
  border-radius: 50%;
}
.step-card:nth-child(2) .step-number { background: #f3b944; border-color: #fff0c7; }
.step-card:nth-child(3) .step-number { background: #ed756b; border-color: #fde2df; }
.step-card strong,
.step-card small { display: block; }
.step-card strong { margin-bottom: 7px; font-size: 19px; font-weight: 1000; }
.step-card small { color: var(--muted); font-size: 13px; font-weight: 700; line-height: 1.45; }

.level-card {
  min-width: 0;
  min-height: 370px;
  padding: 22px;
  text-align: left;
  background: rgba(255, 253, 247, .96);
  border: 3px solid color-mix(in srgb, var(--accent) 35%, #ddd2b4);
  border-radius: 31px;
  box-shadow: var(--soft-shadow);
  transition: transform 170ms ease, box-shadow 170ms ease;
}
.level-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.level-top { justify-content: space-between; gap: 10px; }
.level-icon { display: grid; width: 50px; height: 50px; place-items: center; font-size: 25px; background: color-mix(in srgb, var(--accent) 22%, #fff); border-radius: 17px; }
.level-best { color: #d69f2b; font-size: 12px; font-weight: 1000; }
.level-preview { display: flex; justify-content: center; gap: 8px; margin: 23px 0 20px; }
.preview-letter {
  display: grid;
  width: 76px;
  height: 88px;
  place-items: center;
  align-content: center;
  gap: 4px;
  color: #fff;
  background: var(--preview-color);
  border: 4px solid rgba(42, 76, 70, .22);
  border-radius: 21px;
  box-shadow: 0 7px 12px rgba(55, 75, 69, .12);
}
.preview-letter:nth-child(1) { transform: rotate(-5deg); }
.preview-letter:nth-child(3) { transform: rotate(5deg); }
.preview-letter b { font-size: 27px; line-height: 1; }
.preview-letter i { font-family: "Segoe UI Emoji", sans-serif; font-size: 22px; font-style: normal; }
.level-copy { display: block; }
.level-copy small,
.level-copy strong,
.level-copy > span { display: block; }
.level-copy small { color: color-mix(in srgb, var(--accent) 72%, #345d56); font-family: Georgia, serif; font-size: 10px; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.level-copy strong { margin: 7px 0 8px; font-size: 27px; font-weight: 1000; line-height: 1.05; }
.level-copy > span { min-height: 42px; color: var(--muted); font-size: 13px; font-weight: 700; line-height: 1.45; }
.level-footer { justify-content: space-between; gap: 9px; margin-top: 18px; padding-top: 16px; font-size: 12px; border-top: 2px dashed #ded8c5; }
.level-footer span { color: var(--muted); font-weight: 900; }
.level-footer b { color: color-mix(in srgb, var(--accent) 76%, #24594e); }

.collection-section {
  padding: 30px;
  background: rgba(255, 253, 248, .77);
  border: 3px solid #ded6ba;
  border-radius: 37px;
  box-shadow: var(--shadow);
}
.alphabet-grid { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 8px; }
.alphabet-tile {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 135px;
  place-items: center;
  align-content: center;
  gap: 4px;
  overflow: hidden;
  padding: 17px 4px 8px;
  background: #f4f2ed;
  border: 2px dashed #cbc8bd;
  border-radius: 19px;
  filter: grayscale(.8);
}
.alphabet-tile.learned { background: color-mix(in srgb, var(--tile-color) 15%, #fff); border: 2px solid color-mix(in srgb, var(--tile-color) 45%, #bfc7bd); filter: none; }
.tile-number { position: absolute; top: 6px; left: 7px; display: grid; width: 19px; height: 19px; place-items: center; padding-bottom: 1px; color: #7d827d; font-family: Georgia, serif; font-size: 9px; font-weight: 900; background: #fff; border: 1px solid #d4d0c6; border-radius: 50%; }
.alphabet-tile > strong { display: flex; align-items: baseline; gap: 2px; color: #7a827e; font-size: 28px; line-height: 1; }
.alphabet-tile.learned > strong { color: color-mix(in srgb, var(--tile-color) 70%, #294f4b); }
.alphabet-tile > strong small { font-size: 13px; }
.tile-picture { height: 37px; color: #aeb2ae; font-family: "Segoe UI Emoji", sans-serif; font-size: 29px; line-height: 37px; }
.alphabet-tile p { width: 100%; margin: 0; overflow: hidden; color: #898e89; font-size: 9px; font-weight: 900; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.alphabet-tile.learned p { color: #526f67; }

.parent-tip {
  display: flex;
  align-items: center;
  gap: 17px;
  margin-top: 22px;
  padding: 18px 24px;
  background: rgba(222, 242, 228, .92);
  border: 2px solid #b7d7c2;
  border-radius: 24px;
}
.parent-tip > span { font-size: 28px; }
.parent-tip p { margin: 0; color: #507169; font-size: 13px; font-weight: 700; line-height: 1.5; }

.game-shell { padding: 28px; background: rgba(255, 253, 247, .78); border: 3px solid #ded6ba; border-radius: 37px; box-shadow: var(--shadow); }
.game-heading { justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.game-heading h1 { margin: 0 0 6px; font-size: 41px; font-weight: 1000; line-height: 1; letter-spacing: -.035em; }
.game-heading > div > p:last-child { margin: 0; color: var(--muted); font-size: 13px; font-weight: 900; }
.round-badge { display: grid; flex: 0 0 auto; width: 75px; height: 75px; place-items: center; align-content: center; color: #fff; background: var(--level-accent); border: 8px solid color-mix(in srgb, var(--level-accent) 25%, #fff); border-radius: 50%; }
.round-badge strong { font-family: Georgia, serif; font-size: 25px; line-height: .9; }
.round-badge span { font-size: 9px; font-weight: 900; }
.mission-strip { justify-content: space-between; gap: 15px; margin-bottom: 16px; padding: 12px 16px; background: #f2f0e9; border-radius: 18px; }
.mission-strip > span { color: var(--muted); font-size: 11px; font-weight: 900; }
.progress-dots { display: flex; flex: 1 1 auto; gap: 6px; }
.progress-dot { width: 100%; max-width: 52px; height: 9px; background: #d9d6cd; border-radius: 20px; }
.progress-dot.done { background: #65b78b; }
.progress-dot.current { background: var(--level-accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--level-accent) 18%, transparent); }

.lesson-card {
  display: grid;
  min-height: 364px;
  grid-template-columns: minmax(250px, .72fr) minmax(0, 1.28fr);
  overflow: hidden;
  background: #fffdfa;
  border: 3px solid color-mix(in srgb, var(--letter-color) 30%, #ddd2b8);
  border-radius: 33px;
}
.letter-panel,
.picture-panel { position: relative; display: grid; min-width: 0; place-items: center; align-content: center; padding: 25px; text-align: center; }
.letter-panel { background: color-mix(in srgb, var(--letter-color) 13%, #fff); border-right: 3px dashed color-mix(in srgb, var(--letter-color) 31%, #d7d2c2); }
.panel-label { position: absolute; top: 18px; left: 20px; margin: 0; color: #69817c; font-family: Georgia, serif; font-size: 10px; font-weight: 900; letter-spacing: .13em; text-transform: uppercase; }
.big-letter {
  display: flex;
  width: 183px;
  height: 191px;
  align-items: baseline;
  justify-content: center;
  padding-top: 30px;
  color: #fff;
  background: var(--letter-color);
  border: 9px solid rgba(255, 255, 255, .55);
  border-radius: 52px 72px 49px 70px;
  box-shadow: 0 14px 0 color-mix(in srgb, var(--letter-color) 72%, #345a53), 0 23px 29px rgba(52, 77, 69, .15);
  transform: rotate(-2deg);
}
.big-letter strong { font-size: 103px; line-height: .9; }
.big-letter small { margin-left: 4px; font-size: 39px; font-weight: 1000; }
.letter-panel > p:last-child { max-width: 250px; margin: 31px 0 0; color: var(--muted); font-size: 12px; font-weight: 800; line-height: 1.45; }
.picture-panel { overflow: hidden; background: radial-gradient(circle at 48% 45%, color-mix(in srgb, var(--letter-color) 14%, #fff) 0 130px, transparent 132px); }
.picture-sticker { position: relative; display: grid; width: 190px; height: 185px; place-items: center; }
.picture-blob { position: absolute; inset: 23px 14px 8px; background: color-mix(in srgb, var(--picture-color) 24%, #fff); border: 4px solid color-mix(in srgb, var(--picture-color) 45%, #fff); border-radius: 46% 54% 52% 48% / 45% 44% 56% 55%; box-shadow: 0 15px 19px rgba(65, 82, 76, .12); transform: rotate(-5deg); }
.picture-emoji { position: relative; z-index: 2; font-family: "Segoe UI Emoji", "Apple Color Emoji", sans-serif; font-size: 105px; line-height: 1; filter: drop-shadow(0 8px 6px rgba(49, 66, 61, .19)); }
.picture-sticker > b { position: absolute; z-index: 3; top: 13px; right: 11px; color: #f0b837; font-size: 26px; animation: twinkle 1.7s ease-in-out infinite; }
.picture-panel h2 { margin: -2px 0 6px; font-size: 38px; font-weight: 1000; line-height: 1; }
.picture-panel h2 mark { padding: 0 3px 2px; color: #fff; background: var(--letter-color); border-radius: 8px; }
.word-line { color: var(--muted); font-size: 12px; font-weight: 900; }

.answer-card { margin-top: 16px; padding: 21px; background: #fffdf8; border: 3px solid #ded6ba; border-radius: 29px; }
.answer-heading { justify-content: space-between; gap: 16px; margin-bottom: 17px; }
.answer-heading h2 { margin: 0; font-size: 27px; font-weight: 1000; line-height: 1; }
.letters-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.letter-choice {
  position: relative;
  min-width: 0;
  min-height: 122px;
  overflow: hidden;
  color: var(--ink);
  background: #f7f5ee;
  border: 3px solid #d9d4c4;
  border-radius: 27px;
  box-shadow: 0 7px 0 #d9d4c4;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease;
}
.letter-choice:not(:disabled):hover { border-color: var(--letter-color); transform: translateY(-3px); }
.letter-choice > strong { display: flex; align-items: baseline; justify-content: center; gap: 5px; font-size: 65px; font-weight: 1000; line-height: 1; }
.letter-choice > strong small { font-size: 27px; }
.choice-number { position: absolute; top: 9px; left: 10px; display: grid; width: 27px; height: 27px; place-items: center; padding-bottom: 2px; color: #71827d; font-family: Georgia, serif; font-size: 12px; font-weight: 900; background: #fff; border: 2px solid #d5d1c5; border-radius: 50%; }
.choice-check { position: absolute; right: 13px; bottom: 8px; opacity: 0; color: #fff; font-size: 23px; font-weight: 1000; }
.letter-choice.wrong { background: #fff0ed; border-color: #ef756b; animation: shake .35s ease; }
.letter-choice.hinted { background: #fff5c9; border-color: #efb83f; animation: pulse 1s ease-in-out infinite; }
.letter-choice.correct { color: #fff; background: #55ae80; border-color: #397f61; box-shadow: 0 7px 0 #397f61; }
.letter-choice.correct .choice-number { color: #397f61; border-color: #fff; }
.letter-choice.correct .choice-check { opacity: 1; }

.feedback-card { min-height: 78px; gap: 13px; margin-top: 15px; padding: 13px 17px; background: #edf6f0; border: 2px solid #bfd9c8; border-radius: 24px; }
.feedback-card > p { flex: 1 1 auto; margin: 0; }
.feedback-card strong,
.feedback-card small { display: block; }
.feedback-card strong { margin-bottom: 4px; font-size: 16px; font-weight: 1000; }
.feedback-card small { color: var(--muted); font-size: 12px; font-weight: 800; line-height: 1.35; }
.feedback-icon { flex: 0 0 auto; font-size: 28px; }
.feedback-card.wrong { background: #fff0ed; border-color: #f3b8b1; }
.feedback-card.hint { background: #fff8d9; border-color: #ead28b; }
.feedback-card.correct { background: #e8f7ed; border-color: #9ed0b0; }

.result-card { position: relative; overflow: hidden; padding: 44px 34px; text-align: center; background: rgba(255, 253, 247, .96); border: 3px solid #ded6ba; border-radius: 39px; box-shadow: var(--shadow); }
.result-icon { display: grid; width: 86px; height: 86px; margin: 0 auto 15px; place-items: center; font-size: 49px; background: color-mix(in srgb, var(--level-accent) 23%, #fff); border: 4px solid color-mix(in srgb, var(--level-accent) 42%, #fff); border-radius: 29px; animation: pop .55s ease both; }
.result-card h1 { margin: 0 0 9px; font-size: 52px; font-weight: 1000; line-height: 1; letter-spacing: -.04em; }
.result-lead { max-width: 600px; margin: 0 auto 12px; color: var(--muted); font-size: 15px; font-weight: 800; line-height: 1.45; }
.result-stars { color: #f0b83e; font-size: 37px; letter-spacing: 5px; }
.result-stars span { color: #d9d6cb; }
.result-letters { display: grid; max-width: 880px; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 8px; margin: 24px auto; }
.result-letter { display: grid; min-width: 0; height: 82px; place-items: center; align-content: center; color: #fff; background: var(--result-color); border: 4px solid rgba(43, 76, 70, .24); border-radius: 19px; animation: pop .45s var(--delay) ease both; }
.result-letter strong { font-size: 27px; line-height: 1; }
.result-letter i { font-family: "Segoe UI Emoji", sans-serif; font-size: 20px; font-style: normal; }
.result-stats { max-width: 650px; justify-content: center; margin: 0 auto 27px; overflow: hidden; background: #f3f1e9; border-radius: 22px; }
.result-stats > span { flex: 1 1 0; padding: 14px 8px; border-right: 2px solid #ded9ca; }
.result-stats > span:last-child { border-right: 0; }
.result-stats strong,
.result-stats small { display: block; }
.result-stats strong { font-size: 21px; }
.result-stats small { color: var(--muted); font-size: 9px; font-weight: 900; text-transform: uppercase; }
.result-actions { justify-content: center; gap: 13px; }
.result-confetti i { position: absolute; color: var(--level-accent); font-size: 26px; font-style: normal; font-weight: 1000; opacity: .35; }
.result-confetti i:nth-child(1) { top: 9%; left: 8%; transform: rotate(-12deg); }
.result-confetti i:nth-child(2) { top: 18%; right: 9%; transform: rotate(15deg); }
.result-confetti i:nth-child(3) { bottom: 13%; left: 12%; transform: rotate(8deg); }
.result-confetti i:nth-child(4) { right: 14%; bottom: 12%; transform: rotate(-9deg); }
.result-confetti i:nth-child(5) { top: 45%; right: 4%; transform: rotate(18deg); }

.motion-bounce { animation: pictureBounce 2.1s ease-in-out infinite; }
.motion-rock { animation: pictureRock 2.5s ease-in-out infinite; }
.motion-float { animation: pictureFloat 2.4s ease-in-out infinite; }
.motion-wiggle { animation: pictureWiggle 2.3s ease-in-out infinite; }
.motion-spin { animation: pictureSpin 5.5s linear infinite; }
.motion-pulse { animation: picturePulse 2s ease-in-out infinite; }
.motion-sway { animation: pictureSway 2.6s ease-in-out infinite; }
.motion-nod { animation: pictureNod 2.2s ease-in-out infinite; }
.motion-hop { animation: pictureHop 2.1s ease-in-out infinite; }
.motion-roll { animation: pictureRoll 3.5s ease-in-out infinite; }
.motion-beat,
.motion-grow,
.motion-hug,
.motion-shine { animation: picturePulse 2s ease-in-out infinite; }
.motion-ride { animation: pictureRoll 3.5s ease-in-out infinite; }
.motion-peek,
.motion-roar { animation: pictureNod 2.2s ease-in-out infinite; }
.motion-walk,
.motion-stretch { animation: pictureSway 2.6s ease-in-out infinite; }
.motion-launch { animation: pictureFloat 2.4s ease-in-out infinite; }
.motion-brush { animation: pictureWiggle 2.3s ease-in-out infinite; }
.celebrate .picture-emoji { animation: celebrate .65s ease both; }
.big-letter.celebrate { animation: celebrate .65s ease both; }

@keyframes float { to { transform: translateY(-9px); } }
@keyframes twinkle { 50% { opacity: .35; transform: scale(.72) rotate(18deg); } }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(240, 184, 63, .18); } }
@keyframes pop { from { opacity: 0; transform: scale(.7) translateY(12px); } }
@keyframes celebrate { 35% { transform: scale(1.14) rotate(-5deg); } 65% { transform: scale(.96) rotate(4deg); } }
@keyframes pictureBounce { 50% { transform: translateY(-8px); } }
@keyframes pictureRock { 25% { transform: rotate(-5deg); } 75% { transform: rotate(5deg); } }
@keyframes pictureFloat { 50% { transform: translateY(-9px) rotate(2deg); } }
@keyframes pictureWiggle { 35% { transform: rotate(-5deg); } 65% { transform: rotate(5deg); } }
@keyframes pictureSpin { to { transform: rotate(360deg); } }
@keyframes picturePulse { 50% { transform: scale(1.08); } }
@keyframes pictureSway { 50% { transform: translateX(7px) rotate(3deg); } }
@keyframes pictureNod { 50% { transform: rotate(5deg) translateY(3px); } }
@keyframes pictureHop { 45% { transform: translateY(-11px); } 55% { transform: translateY(-11px) rotate(4deg); } }
@keyframes pictureRoll { 50% { transform: translateX(7px) rotate(9deg); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; }
}

@media (max-width: 900px) {
  .hero { min-height: 380px; grid-template-columns: minmax(0, 1fr) minmax(330px, .9fr); padding: 38px 32px; }
  .hero h1 { font-size: 51px; }
  .hero-book { inset-inline: 0; }
  .hero-letter-card { width: 77px; height: 91px; }
  .hero-letter-card.card-1 { left: 97px; }
  .steps-grid { grid-template-columns: 1fr; }
  .step-card { min-height: 105px; }
  .levels-grid { grid-template-columns: 1fr 1fr; }
  .levels-grid .level-card:last-child { grid-column: 1 / -1; min-height: 330px; }
  .alphabet-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .alphabet-tile { min-height: 145px; }
}

@media (max-width: 720px) {
  .app { width: min(100% - 22px, 1120px); padding-top: 12px; }
  .topbar { align-items: flex-start; margin-bottom: 14px; }
  .brand-mark { width: 48px; height: 48px; font-size: 24px; border-radius: 16px; }
  .brand strong { max-width: 190px; font-size: 18px; white-space: normal; }
  .brand small { display: none; }
  .topbar-actions { gap: 6px; }
  .sound-button { width: 48px; min-height: 46px; justify-content: center; padding: 0; }
  .sound-button span:last-child { display: none; }
  .collection-button { min-height: 46px; padding-inline: 10px; }
  .collection-button strong { font-size: 11px; }
  .back-button { width: 46px; min-height: 46px; }
  .top-spark { display: none; }
  .hero { min-height: 670px; grid-template-columns: 1fr; align-content: start; padding: 33px 26px; }
  .hero-copy { text-align: center; }
  .hero-copy > p:not(.eyebrow) { margin-inline: auto; }
  .hero-scene { min-height: 286px; }
  .hero-book { inset: 10px 0 25px; }
  .section-heading { align-items: flex-end; }
  .section-heading h2 { font-size: 34px; }
  .section-heading > p { max-width: 240px; }
  .levels-grid { grid-template-columns: 1fr; }
  .levels-grid .level-card:last-child { grid-column: auto; }
  .level-card { min-height: 340px; }
  .collection-section { padding: 23px; }
  .lesson-card { grid-template-columns: 1fr; }
  .letter-panel { min-height: 330px; border-right: 0; border-bottom: 3px dashed color-mix(in srgb, var(--letter-color) 31%, #d7d2c2); }
  .picture-panel { min-height: 343px; }
  .letters-grid { gap: 9px; }
  .letter-choice { min-height: 110px; }
  .letter-choice > strong { font-size: 55px; }
  .result-letters { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}

@media (max-width: 520px) {
  .app { width: calc(100% - 18px); }
  .topbar { min-height: 52px; gap: 7px; }
  .brand { gap: 7px; }
  .brand-mark { width: 43px; height: 43px; font-size: 22px; border-width: 2px; }
  .brand strong { max-width: 128px; font-size: 15px; }
  .collection-button > span:first-child { display: none; }
  .collection-button { padding-inline: 8px; }
  .collection-button small { font-size: 9px; }
  .back-button,
  .sound-button { width: 41px; min-height: 41px; }
  .hero { min-height: 625px; padding: 28px 18px; border-radius: 30px; }
  .hero h1 { font-size: 44px; }
  .hero-copy > p:not(.eyebrow) { font-size: 14px; }
  .hero-scene { min-height: 264px; }
  .book-page { padding: 17px; }
  .book-page.left > strong { font-size: 48px; }
  .hero-picture { width: 104px; height: 104px; }
  .hero-picture .picture-emoji { font-size: 61px; }
  .hero-letter-card { width: 63px; height: 78px; border-width: 3px; border-radius: 17px; }
  .hero-letter-card b { font-size: 28px; }
  .hero-letter-card i { font-size: 22px; }
  .hero-letter-card.card-0 { left: 15px; }
  .hero-letter-card.card-1 { left: 66px; }
  .hero-letter-card.card-2 { right: 5px; }
  .hero-note { right: 12px; font-size: 10px; }
  .how-section, .levels-section, .collection-section { margin-top: 42px; }
  .section-heading { display: block; }
  .section-heading h2 { font-size: 31px; }
  .section-heading > p { max-width: none; margin-top: 10px; text-align: left; }
  .step-card { min-height: 114px; gap: 12px; padding: 17px; border-radius: 24px; }
  .step-number { width: 54px; height: 54px; border-width: 7px; }
  .step-card strong { font-size: 17px; }
  .level-card { min-height: 350px; padding: 18px; }
  .preview-letter { width: 69px; }
  .collection-section { padding: 17px 12px; border-radius: 29px; }
  .alphabet-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
  .alphabet-tile { min-height: 128px; }
  .parent-tip { align-items: flex-start; padding: 16px; }
  .game-shell { padding: 15px 12px; border-radius: 29px; }
  .game-heading h1 { font-size: 33px; }
  .round-badge { width: 63px; height: 63px; border-width: 7px; }
  .round-badge strong { font-size: 21px; }
  .mission-strip { display: block; }
  .mission-strip > span { display: block; margin-top: 11px; text-align: center; }
  .lesson-card { border-radius: 27px; }
  .letter-panel { min-height: 310px; padding: 20px 14px; }
  .big-letter { width: 163px; height: 172px; padding-top: 27px; }
  .big-letter strong { font-size: 91px; }
  .picture-panel { min-height: 324px; padding: 20px 12px; }
  .picture-sticker { width: 173px; height: 168px; }
  .picture-emoji { font-size: 94px; }
  .picture-panel h2 { font-size: 33px; }
  .answer-card { padding: 16px 10px; }
  .answer-heading h2 { font-size: 23px; }
  .hint-button { min-height: 42px; padding-inline: 11px; font-size: 11px; }
  .letters-grid { gap: 6px; }
  .letter-choice { min-height: 101px; border-radius: 21px; }
  .letter-choice > strong { font-size: 44px; }
  .letter-choice > strong small { font-size: 20px; }
  .choice-number { top: 6px; left: 6px; width: 23px; height: 23px; font-size: 10px; }
  .feedback-card { align-items: flex-start; flex-wrap: wrap; }
  .feedback-card .primary-button { width: 100%; }
  .result-card { padding: 34px 14px; border-radius: 30px; }
  .result-card h1 { font-size: 39px; }
  .result-letters { gap: 5px; }
  .result-letter { height: 68px; border-width: 3px; }
  .result-stats { display: grid; grid-template-columns: 1fr 1fr; }
  .result-stats > span:nth-child(2) { border-right: 0; }
  .result-stats > span:nth-child(-n+2) { border-bottom: 2px solid #ded9ca; }
  .result-actions { flex-direction: column; }
  .result-actions button { width: 100%; }
}

@media (max-width: 350px) {
  .brand strong { max-width: 99px; font-size: 14px; }
  .collection-button strong { font-size: 10px; }
  .alphabet-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
