:root {
  color-scheme: light;
  --bg: #fff6d8;
  --surface: rgba(255, 255, 255, 0.58);
  --surface-strong: rgba(255, 255, 255, 0.84);
  --ink: #19315d;
  --muted: #52637e;
  --line: rgba(255, 255, 255, 0.76);
  --strawberry: #ff3d7f;
  --peach: #ff9f1c;
  --lemon: #ffe15a;
  --mint: #3edb93;
  --sky: #29b6f6;
  --grape: #8768ff;
  --berry: #d91666;
  --teal: #007f8a;
  --gold: #9b6200;
  --wrong: #e92f68;
  --correct: #078f70;
  --glass-edge: rgba(255, 255, 255, 0.92);
  --glass-line: rgba(26, 58, 104, 0.14);
  --glass-shine: rgba(255, 255, 255, 0.78);
  --shadow: rgba(63, 61, 130, 0.22);
  --candy-shadow: rgba(255, 61, 127, 0.22);
  --sky-shadow: rgba(41, 182, 246, 0.2);
  font-family:
    ui-rounded, "Nunito", "PingFang SC", "Microsoft YaHei", system-ui,
    -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  background:
    linear-gradient(118deg, rgba(255, 255, 255, 0.62), transparent 24% 68%, rgba(255, 255, 255, 0.46)),
    linear-gradient(142deg, rgba(255, 61, 127, 0.5) 0 15%, rgba(255, 159, 28, 0.42) 18% 33%, rgba(255, 225, 90, 0.44) 38% 52%, rgba(62, 219, 147, 0.42) 58% 73%, rgba(41, 182, 246, 0.46) 80% 100%),
    repeating-linear-gradient(128deg, rgba(255, 255, 255, 0.44) 0 3px, transparent 3px 22px),
    var(--bg);
  background-attachment: fixed;
  color: var(--ink);
  position: relative;
}

body::before {
  background:
    linear-gradient(105deg, transparent 0 10%, rgba(255, 255, 255, 0.54) 12% 16%, transparent 18% 42%, rgba(255, 255, 255, 0.42) 45% 50%, transparent 54%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.24) 0 1px, transparent 1px 42px);
  content: "";
  inset: 0;
  pointer-events: none;
  position: fixed;
  z-index: -1;
}

body::after {
  background:
    repeating-linear-gradient(0deg, transparent 0 42px, rgba(255, 255, 255, 0.28) 42px 45px, transparent 45px 96px),
    repeating-linear-gradient(90deg, transparent 0 70px, rgba(255, 225, 90, 0.3) 70px 82px, transparent 82px 152px),
    repeating-linear-gradient(135deg, transparent 0 52px, rgba(255, 61, 127, 0.18) 52px 60px, transparent 60px 132px),
    repeating-linear-gradient(45deg, transparent 0 66px, rgba(62, 219, 147, 0.2) 66px 78px, transparent 78px 148px);
  content: "";
  inset: 0;
  opacity: 0.42;
  pointer-events: none;
  position: fixed;
  z-index: -1;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

button {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.38)),
    var(--surface-strong);
  backdrop-filter: blur(18px) saturate(1.34);
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  transition:
    transform 140ms ease,
    border-color 140ms ease,
    box-shadow 140ms ease;
}

button:hover:not(:disabled) {
  border-color: rgba(255, 79, 139, 0.58);
  box-shadow:
    0 14px 30px var(--candy-shadow),
    0 10px 24px var(--sky-shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
  transform: translateY(-1px);
}

button:focus-visible,
input:focus-visible {
  outline: 3px solid rgba(124, 200, 255, 0.64);
  outline-offset: 3px;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

h1,
h2,
p {
  margin: 0;
}

.app-shell {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1fr) 330px;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 18px;
}

.lesson-area {
  display: grid;
  gap: 14px;
  grid-template-rows: auto minmax(0, 1fr);
  min-width: 0;
}

.hero,
.practice-panel,
.keyboard-panel,
.side-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.3) 46%, rgba(255, 255, 255, 0.52)),
    linear-gradient(122deg, rgba(255, 61, 127, 0.22), rgba(255, 225, 90, 0.24) 28%, rgba(62, 219, 147, 0.22) 58%, rgba(41, 182, 246, 0.24));
  border: 1px solid var(--glass-edge);
  border-radius: 8px;
  box-shadow:
    0 22px 50px var(--shadow),
    0 10px 26px rgba(255, 61, 127, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    inset 0 -1px 0 var(--glass-line);
  backdrop-filter: blur(24px) saturate(1.35);
}

.hero {
  align-items: center;
  display: flex;
  justify-content: space-between;
  min-height: 132px;
  overflow: hidden;
  padding: 24px;
  position: relative;
}

.hero::before {
  background:
    linear-gradient(105deg, rgba(255, 255, 255, 0.58) 0 15%, transparent 18% 56%, rgba(255, 255, 255, 0.34) 72%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.34) 0 2px, transparent 2px 13px),
    linear-gradient(100deg, rgba(255, 61, 127, 0.58), rgba(255, 159, 28, 0.42), rgba(255, 225, 90, 0.5), rgba(62, 219, 147, 0.42), rgba(41, 182, 246, 0.48), rgba(135, 104, 255, 0.34));
  content: "";
  inset: 0;
  opacity: 0.94;
  pointer-events: none;
  position: absolute;
}

.hero::after {
  background: linear-gradient(90deg, var(--strawberry), var(--peach), var(--lemon), var(--mint), var(--sky), var(--grape));
  bottom: 0;
  content: "";
  height: 5px;
  left: 0;
  position: absolute;
  right: 0;
}

.hero > * {
  min-width: 0;
  position: relative;
}

.eyebrow {
  color: var(--berry);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  color: #123262;
  font-size: clamp(36px, 7vw, 68px);
  line-height: 0.95;
  margin-top: 8px;
  text-shadow:
    0 2px 0 rgba(255, 255, 255, 0.72),
    0 12px 26px rgba(41, 182, 246, 0.18);
}

.hero__copy {
  color: #31506f;
  font-size: 15px;
  line-height: 1.6;
  margin-top: 12px;
  max-width: 520px;
  overflow-wrap: anywhere;
}

.page-link {
  align-items: center;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.3)),
    linear-gradient(135deg, rgba(255, 225, 90, 0.74), rgba(62, 219, 147, 0.48), rgba(41, 182, 246, 0.48));
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.76),
    0 10px 22px var(--shadow);
  border-radius: 8px;
  color: #b0145b;
  display: inline-flex;
  font-size: 14px;
  font-weight: 900;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  text-decoration: none;
}

.page-link:focus-visible {
  outline: 3px solid rgba(124, 200, 255, 0.64);
  outline-offset: 3px;
}

.hero-link {
  margin-top: 14px;
}

.hero-link-secondary {
  margin-left: 8px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.hero-action {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.26), transparent),
    linear-gradient(135deg, var(--strawberry), #ff6da5 42%, var(--peach));
  border-color: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 14px 24px rgba(255, 61, 127, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    inset 0 -4px 0 rgba(155, 35, 78, 0.16);
  color: #ffffff;
  min-height: 46px;
  text-shadow: 0 1px 0 rgba(116, 26, 70, 0.22);
}

.hero-action:nth-child(2) {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent),
    linear-gradient(135deg, var(--sky), #44d8ff 42%, var(--mint));
  box-shadow:
    0 14px 24px rgba(41, 182, 246, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    inset 0 -4px 0 rgba(0, 112, 138, 0.14);
}

.hero-action:nth-child(3) {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent),
    linear-gradient(135deg, var(--lemon), var(--peach) 58%, #ff76a5);
  box-shadow:
    0 14px 24px rgba(255, 159, 28, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.76),
    inset 0 -4px 0 rgba(155, 94, 0, 0.14);
  color: #793b00;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.36);
}

.mini-game-links {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-back-link {
  color: #006f84;
}

.hero__badge {
  align-items: center;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.34)),
    linear-gradient(135deg, rgba(255, 61, 127, 0.42), rgba(255, 225, 90, 0.46), rgba(62, 219, 147, 0.34));
  border: 1px solid rgba(255, 255, 255, 0.84);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  min-width: 124px;
  padding: 14px 16px;
  text-align: center;
}

.hero__badge span,
.score-strip span,
.typing-box span,
.current-target span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.hero__badge strong {
  color: var(--berry);
  font-size: 24px;
}

.practice-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0.28) 50%, rgba(255, 255, 255, 0.48)),
    linear-gradient(115deg, rgba(41, 182, 246, 0.24), rgba(62, 219, 147, 0.22) 34%, rgba(255, 225, 90, 0.25) 66%, rgba(255, 61, 127, 0.2));
  display: grid;
  gap: 16px;
  overflow: hidden;
  padding: 18px;
  position: relative;
}

.practice-panel::before,
.keyboard-panel::before,
.falling-game-panel::before,
.word-game-panel::before {
  background:
    linear-gradient(90deg, var(--strawberry), var(--peach), var(--lemon), var(--mint), var(--sky), var(--grape)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.56), transparent);
  content: "";
  height: 9px;
  left: 0;
  pointer-events: none;
  position: absolute;
  right: 0;
  top: 0;
}

.level-meta {
  align-items: start;
  display: flex;
  gap: 18px;
  justify-content: space-between;
}

.level-meta h2 {
  font-size: 22px;
  margin-top: 8px;
}

.level-meta p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  max-width: 420px;
  text-align: right;
}

.level-pill {
  background: linear-gradient(135deg, rgba(255, 225, 90, 0.96), rgba(255, 111, 165, 0.38));
  border: 1px solid rgba(255, 159, 28, 0.58);
  border-radius: 999px;
  color: var(--berry);
  display: inline-flex;
  font-size: 12px;
  font-weight: 900;
  padding: 5px 10px;
}

.prompt-board {
  align-items: stretch;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) 122px;
}

.prompt-text {
  align-content: center;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.34)),
    linear-gradient(105deg, rgba(255, 225, 90, 0.28), rgba(255, 61, 127, 0.18) 36%, rgba(41, 182, 246, 0.24) 72%);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  min-height: 116px;
  padding: 18px;
}

.prompt-char {
  align-items: center;
  border-radius: 6px;
  color: var(--ink);
  display: inline-flex;
  font-size: 28px;
  font-weight: 900;
  height: 42px;
  justify-content: center;
  min-width: 28px;
  padding: 0 6px;
}

.prompt-char.is-space {
  min-width: 34px;
}

.prompt-char.is-current {
  background:
    linear-gradient(180deg, rgba(255, 232, 95, 0.94), rgba(255, 159, 67, 0.42)),
    var(--lemon);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    inset 0 -4px 0 rgba(255, 159, 67, 0.34);
}

.prompt-char.is-done {
  background: linear-gradient(180deg, rgba(208, 255, 239, 0.94), rgba(171, 246, 226, 0.82));
  color: var(--teal);
}

.prompt-char.is-wrong {
  background: linear-gradient(180deg, rgba(255, 224, 237, 0.94), rgba(255, 179, 204, 0.78));
  color: var(--wrong);
}

.current-target {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(235, 250, 255, 0.4)),
    linear-gradient(180deg, rgba(255, 225, 90, 0.72), rgba(41, 182, 246, 0.42));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  justify-items: center;
  min-height: 116px;
  padding: 14px;
}

.current-target strong {
  color: #ee2d76;
  font-size: 52px;
  line-height: 1;
}

.star-goals {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.3)),
    linear-gradient(95deg, rgba(255, 61, 127, 0.2), rgba(255, 225, 90, 0.34), rgba(62, 219, 147, 0.24));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(96px, auto) 1fr;
  padding: 12px;
}

.star-goals div {
  display: grid;
  gap: 4px;
}

.star-goals span,
.star-goals li {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.star-goals strong {
  color: var(--berry);
  font-size: 24px;
}

.star-goals ul {
  display: grid;
  gap: 6px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
}

.star-goals li {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.36)),
    rgba(255, 225, 90, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.66);
  border-radius: 8px;
  padding: 8px;
  text-align: center;
}

.star-goals li.is-done {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.5), transparent),
    var(--lemon);
  color: var(--gold);
}

.practice-progress {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.34)),
    linear-gradient(100deg, rgba(255, 225, 90, 0.32), rgba(62, 219, 147, 0.24), rgba(41, 182, 246, 0.26));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  padding: 12px;
}

.practice-progress div:first-child {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
}

.practice-progress span {
  color: var(--berry);
  font-size: 18px;
  font-weight: 900;
}

.practice-progress strong {
  color: var(--ink);
  font-size: 14px;
  min-width: 0;
  overflow-wrap: anywhere;
}

.practice-progress__bar {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0.2)),
    repeating-linear-gradient(90deg, rgba(255, 225, 90, 0.34) 0 20px, rgba(62, 219, 147, 0.3) 20px 40px, rgba(41, 182, 246, 0.3) 40px 60px);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  height: 16px;
  overflow: hidden;
}

.practice-progress__bar span {
  background: linear-gradient(90deg, var(--mint), var(--sky), var(--lemon), var(--strawberry));
  display: block;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 160ms ease;
  width: 100%;
}

.typing-box {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0.3)),
    rgba(41, 182, 246, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  padding: 12px;
}

.typing-box input {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 249, 253, 0.78)),
    rgba(255, 255, 255, 0.64);
  border: 2px solid rgba(21, 168, 255, 0.36);
  border-radius: 8px;
  color: var(--ink);
  font-size: 22px;
  font-weight: 800;
  min-height: 48px;
  padding: 0 14px;
}

.actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.level-result {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.34)),
    linear-gradient(110deg, rgba(255, 225, 90, 0.42), rgba(255, 61, 127, 0.22), rgba(62, 219, 147, 0.26));
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 8px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.76),
    0 12px 24px rgba(255, 47, 134, 0.1);
  padding: 14px;
}

.level-result span {
  color: var(--berry);
  display: inline-flex;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 4px;
}

.level-result strong {
  color: var(--ink);
  display: block;
  font-size: 20px;
}

.level-result p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.55;
  margin-top: 6px;
}

.primary-button {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.3), transparent),
    linear-gradient(135deg, #ff2f7b, #ff7aa7 46%, var(--peach));
  border-color: rgba(255, 255, 255, 0.68);
  color: #ffffff;
  text-shadow: 0 1px 0 rgba(120, 40, 76, 0.22);
}

.ghost-button {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.36)),
    rgba(255, 255, 255, 0.4);
  color: #23436d;
  min-height: 34px;
  padding: 0 10px;
}

.keyboard-panel {
  align-content: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.26) 48%, rgba(255, 255, 255, 0.44)),
    linear-gradient(110deg, rgba(255, 61, 127, 0.24), rgba(255, 225, 90, 0.28) 32%, rgba(62, 219, 147, 0.24) 62%, rgba(41, 182, 246, 0.28));
  display: grid;
  overflow: hidden;
  min-height: 300px;
  padding: 18px;
  position: relative;
}

.keyboard {
  display: grid;
  gap: 8px;
}

.key-row {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.key-row--home {
  padding-left: 22px;
}

.key-row--bottom {
  padding-left: 52px;
}

.key {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.38)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 225, 90, 0.22), rgba(255, 61, 127, 0.16));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.84),
    inset 0 -5px 0 var(--glass-line),
    0 9px 18px rgba(72, 82, 126, 0.12);
  color: var(--ink);
  display: grid;
  font-size: clamp(14px, 2vw, 20px);
  font-weight: 900;
  height: clamp(42px, 6vw, 58px);
  justify-items: center;
  min-width: clamp(34px, 5.8vw, 58px);
  padding: 0 8px;
  position: relative;
  text-transform: uppercase;
  transition:
    background 120ms ease,
    box-shadow 120ms ease,
    transform 120ms ease;
}

.key-row:nth-child(1) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.34)),
    linear-gradient(180deg, rgba(255, 225, 90, 0.5), rgba(255, 159, 28, 0.24));
}

.key-row:nth-child(2) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.34)),
    linear-gradient(180deg, rgba(62, 219, 147, 0.44), rgba(41, 182, 246, 0.24));
}

.key-row:nth-child(3) .key,
.key-row:nth-child(4) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.34)),
    linear-gradient(180deg, rgba(255, 61, 127, 0.3), rgba(135, 104, 255, 0.18));
}

.key small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.key--wide {
  min-width: min(34vw, 280px);
}

.key.is-target {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), transparent),
    linear-gradient(180deg, #fff27a, #ffb12f 62%, #ff7aa7);
  box-shadow:
    inset 0 -5px 0 rgba(255, 159, 67, 0.42),
    0 14px 28px rgba(255, 159, 28, 0.32);
  transform: translateY(-3px);
}

.key.is-correct {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.6), transparent),
    linear-gradient(180deg, #d6ffef, #a8f4dc);
  color: var(--teal);
}

.key.is-wrong {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.62), transparent),
    linear-gradient(180deg, #ffe0ed, #ffb3cc);
  color: var(--wrong);
}

.side-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0.28) 48%, rgba(255, 255, 255, 0.46)),
    linear-gradient(160deg, rgba(255, 225, 90, 0.28), rgba(62, 219, 147, 0.22) 38%, rgba(41, 182, 246, 0.26) 70%, rgba(255, 61, 127, 0.22));
  display: grid;
  gap: 18px;
  grid-auto-rows: max-content;
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  padding: 16px;
  position: relative;
}

.score-strip {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, 1fr);
}

.today-card {
  display: grid;
  gap: 12px;
}

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

.today-metrics div {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.34)),
    linear-gradient(135deg, rgba(255, 225, 90, 0.28), rgba(41, 182, 246, 0.2));
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  padding: 9px;
}

.today-metrics span,
.parent-summary dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.today-metrics strong,
.parent-summary dd {
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
  margin: 0;
}

.score-strip div {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.34)),
    linear-gradient(135deg, rgba(41, 182, 246, 0.3), rgba(62, 219, 147, 0.22));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  text-align: center;
}

.score-strip strong {
  color: #007b89;
  font-size: 18px;
}

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

.section-head h2,
.tips h2 {
  font-size: 16px;
}

.section-head h2,
.tips h2 {
  align-items: center;
  display: inline-flex;
  gap: 8px;
}

.section-head h2::before,
.tips h2::before {
  background: linear-gradient(180deg, var(--strawberry), var(--lemon), var(--mint));
  border-radius: 999px;
  content: "";
  height: 18px;
  width: 6px;
}

.level-map {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(4, 1fr);
}

.level-button {
  aspect-ratio: 1;
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(41, 182, 246, 0.26), rgba(255, 225, 90, 0.2));
  border-color: rgba(255, 255, 255, 0.7);
  box-shadow:
    0 8px 18px rgba(56, 74, 128, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    inset 0 -4px 0 rgba(26, 58, 104, 0.08);
  color: var(--ink);
  display: grid;
  font-weight: 900;
  gap: 2px;
  min-height: 0;
  padding: 6px;
}

.level-button:nth-child(4n + 1) {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(255, 225, 90, 0.54), rgba(255, 159, 28, 0.26));
}

.level-button:nth-child(4n + 2) {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(62, 219, 147, 0.42), rgba(41, 182, 246, 0.28));
}

.level-button:nth-child(4n + 3) {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(41, 182, 246, 0.42), rgba(135, 104, 255, 0.24));
}

.level-button:nth-child(4n) {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(255, 61, 127, 0.36), rgba(255, 225, 90, 0.26));
}

.level-button span {
  font-size: 16px;
  line-height: 1;
}

.level-button small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  line-height: 1.15;
}

.level-button em {
  color: var(--gold);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

.level-button.is-current {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.56), transparent),
    linear-gradient(180deg, #fff27a, #ffae2a 58%, #ff6e9f);
  border-color: rgba(255, 159, 28, 0.82);
  box-shadow:
    0 12px 24px rgba(255, 159, 28, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    inset 0 -4px 0 rgba(155, 94, 0, 0.14);
}

.level-button.is-complete {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.54), transparent),
    linear-gradient(180deg, #d6ffef, #a8f4dc);
}

.level-button.is-locked {
  background: rgba(255, 255, 255, 0.28);
  color: rgba(38, 54, 74, 0.45);
}

.tips {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(235, 250, 255, 0.32)),
    linear-gradient(135deg, rgba(255, 61, 127, 0.18), rgba(255, 225, 90, 0.24), rgba(62, 219, 147, 0.18));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  padding: 14px;
}

.tips p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
  margin-top: 8px;
}

.tips .page-link {
  margin-top: 12px;
  width: 100%;
}

.wrong-key-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.wrong-key-chip {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.34)),
    linear-gradient(135deg, rgba(255, 61, 127, 0.34), rgba(255, 225, 90, 0.28));
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  color: var(--berry);
  font-size: 12px;
  font-weight: 900;
  padding: 7px 10px;
}

.wrong-key-chip.is-empty {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.22)),
    linear-gradient(135deg, rgba(0, 214, 155, 0.18), rgba(21, 168, 255, 0.14));
  color: var(--teal);
}

.parent-summary dl {
  display: grid;
  gap: 10px;
  margin: 12px 0 0;
}

.parent-summary dl div {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.32)),
    rgba(255, 255, 255, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.66);
  border-radius: 8px;
  display: grid;
  gap: 4px;
  padding: 10px;
}

.sticker-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 10px;
}

.sticker {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.86), rgba(255, 225, 90, 0.42), rgba(255, 61, 127, 0.2)),
    rgba(255, 255, 255, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 8px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  padding: 10px;
  text-align: center;
}

.sticker.is-locked {
  color: rgba(38, 54, 74, 0.44);
}

.stacked-link {
  margin-top: 8px !important;
}

.falling-shell {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1fr) 320px;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 18px;
}

.word-shell {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1fr) 320px;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 18px;
}

.word-main {
  display: grid;
  gap: 14px;
  grid-template-rows: auto minmax(560px, 1fr);
  min-width: 0;
}

.word-game-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.28) 48%, rgba(255, 255, 255, 0.48)),
    linear-gradient(115deg, rgba(255, 61, 127, 0.24), rgba(255, 225, 90, 0.24) 32%, rgba(62, 219, 147, 0.26) 62%, rgba(41, 182, 246, 0.26));
  border: 1px solid var(--glass-edge);
  border-radius: 8px;
  box-shadow:
    0 18px 44px var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    inset 0 -1px 0 var(--glass-line);
  backdrop-filter: blur(24px) saturate(1.35);
  display: grid;
  gap: 12px;
  grid-template-rows: auto auto auto minmax(320px, 1fr) auto;
  min-height: 0;
  overflow: hidden;
  padding: 14px;
  position: relative;
}

.word-group-tabs {
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.3)),
    linear-gradient(135deg, rgba(255, 225, 90, 0.38), rgba(41, 182, 246, 0.3), rgba(255, 61, 127, 0.18));
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 94px;
  overflow-y: auto;
  padding: 6px;
}

.word-stage {
  background:
    linear-gradient(110deg, rgba(255, 255, 255, 0.58), transparent 22% 72%, rgba(255, 255, 255, 0.32)),
    linear-gradient(180deg, rgba(62, 219, 147, 0.42), rgba(41, 182, 246, 0.26) 44%, rgba(255, 61, 127, 0.22)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.5) 0 1px, transparent 1px 52px);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    inset 0 -1px 0 var(--glass-line);
  min-height: 320px;
  overflow: hidden;
  position: relative;
}

.falling-word-card {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(255, 255, 255, 0.38)),
    rgba(255, 255, 255, 0.56);
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 8px;
  box-shadow:
    0 14px 30px var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
  color: var(--ink);
  display: grid;
  gap: 4px;
  left: 0;
  padding: 10px 12px;
  position: absolute;
  text-align: center;
  top: 0;
  will-change: transform;
}

.falling-word-card strong {
  color: #bd1e68;
  font-size: 22px;
  line-height: 1.05;
}

.falling-word-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.falling-word-card small,
.falling-letter small {
  background: rgba(255, 255, 255, 0.76);
  border-radius: 999px;
  color: var(--gold);
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  padding: 4px 6px;
}

.falling-word-card.has-power,
.falling-letter.has-power {
  border-color: rgba(255, 232, 95, 0.94);
  box-shadow:
    0 14px 30px rgba(255, 159, 67, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.word-falling-letter {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.5), transparent 38%),
    linear-gradient(180deg, #42c8ff, var(--mint) 54%, #20cde8);
  box-shadow: 0 14px 28px rgba(47, 215, 167, 0.3);
}

.word-falling-letter.is-distractor {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.48), transparent 38%),
    linear-gradient(180deg, rgba(244, 236, 255, 0.92), rgba(219, 240, 255, 0.88));
  border-color: rgba(255, 255, 255, 0.7);
  box-shadow: 0 10px 20px rgba(143, 134, 180, 0.14);
  color: rgba(93, 86, 121, 0.72);
  opacity: 0.72;
}

.word-target-card {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(235, 250, 255, 0.36)),
    linear-gradient(135deg, rgba(255, 225, 90, 0.42), rgba(255, 61, 127, 0.24), rgba(62, 219, 147, 0.3));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(150px, 0.8fr) minmax(160px, 1fr) minmax(160px, 1.2fr) auto;
  padding: 12px;
}

.word-target-card div:first-child {
  display: grid;
  gap: 3px;
}

.word-target-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.word-target-card strong {
  color: var(--berry);
  font-size: 28px;
  line-height: 1;
}

.word-target-card strong.is-hidden-word {
  color: var(--teal);
  font-size: 22px;
}

.word-target-card em {
  color: var(--teal);
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
}

.word-target-card p {
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.4;
}

.word-letter-slots {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.word-letter-slots span {
  align-items: center;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 8px;
  color: var(--teal);
  display: inline-flex;
  font-size: 18px;
  font-weight: 900;
  height: 34px;
  justify-content: center;
  min-width: 30px;
  text-transform: uppercase;
}

.word-letter-slots span.is-current {
  background:
    linear-gradient(180deg, rgba(255, 232, 95, 0.92), rgba(255, 255, 255, 0.46)),
    var(--lemon);
  color: var(--gold);
}

.word-letter-slots span.is-filled {
  background: linear-gradient(180deg, rgba(208, 255, 239, 0.94), rgba(171, 246, 226, 0.82));
}

.word-sound-button {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.34)),
    linear-gradient(135deg, rgba(41, 182, 246, 0.5), rgba(62, 219, 147, 0.42));
  color: #006b82;
  min-width: 96px;
}

.word-input-box {
  background: rgba(255, 255, 255, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  padding: 12px;
}

.word-input-box span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.word-input-box input {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.46)),
    rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 8px;
  color: var(--ink);
  font-size: 24px;
  font-weight: 900;
  min-height: 52px;
  padding: 0 14px;
}

.falling-main {
  display: grid;
  gap: 14px;
  grid-template-rows: auto minmax(420px, 1fr) auto;
  min-width: 0;
}

.falling-hero h1 {
  font-size: clamp(34px, 6vw, 62px);
}

.falling-game-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.28) 48%, rgba(255, 255, 255, 0.48)),
    linear-gradient(115deg, rgba(255, 61, 127, 0.24), rgba(255, 225, 90, 0.24) 32%, rgba(62, 219, 147, 0.26) 62%, rgba(41, 182, 246, 0.26));
  border: 1px solid var(--glass-edge);
  border-radius: 8px;
  box-shadow:
    0 18px 44px var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    inset 0 -1px 0 var(--glass-line);
  backdrop-filter: blur(24px) saturate(1.35);
  display: grid;
  gap: 12px;
  grid-template-rows: auto auto auto minmax(280px, 1fr);
  min-height: 0;
  overflow: hidden;
  padding: 14px;
  position: relative;
}

.falling-toolbar {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.mode-tabs {
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.3)),
    linear-gradient(135deg, rgba(255, 61, 127, 0.3), rgba(255, 225, 90, 0.34), rgba(41, 182, 246, 0.3));
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 8px;
  display: grid;
  gap: 6px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 6px;
}

.mode-tab {
  background: transparent;
  border-color: transparent;
  min-height: 38px;
  padding: 0 10px;
}

.mode-tab.is-active {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.5), transparent),
    linear-gradient(180deg, var(--lemon), rgba(255, 159, 67, 0.5));
  border-color: rgba(255, 255, 255, 0.78);
  color: var(--gold);
}

.falling-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

.game-control {
  box-shadow:
    0 10px 20px rgba(55, 88, 117, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    inset 0 -4px 0 rgba(72, 104, 126, 0.08);
  gap: 8px;
  min-width: 82px;
  overflow: hidden;
  position: relative;
}

.game-control::before {
  align-items: center;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 8px;
  display: inline-grid;
  flex: 0 0 24px;
  font-size: 12px;
  font-weight: 900;
  height: 24px;
  justify-content: center;
  width: 24px;
}

.game-control::after {
  background: linear-gradient(110deg, transparent 0 35%, rgba(255, 255, 255, 0.42) 48%, transparent 62%);
  content: "";
  inset: 0;
  opacity: 0.55;
  pointer-events: none;
  position: absolute;
  transform: translateX(-70%);
  transition: transform 220ms ease;
}

.game-control:hover:not(:disabled)::after {
  transform: translateX(70%);
}

.game-control--start {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent),
    linear-gradient(135deg, var(--mint), var(--sky) 42%, var(--strawberry) 76%, var(--peach));
  border-color: rgba(255, 255, 255, 0.76);
  color: #ffffff;
  text-shadow: 0 1px 0 rgba(25, 88, 94, 0.24);
}

.game-control--start::before {
  color: var(--teal);
  content: "▶";
}

.game-control--pause {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.36)),
    linear-gradient(135deg, rgba(72, 184, 255, 0.38), rgba(143, 107, 255, 0.18));
  color: #2d6078;
}

.game-control--pause::before {
  color: #2d6078;
  content: "Ⅱ";
}

.game-control--end {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.36)),
    linear-gradient(135deg, rgba(255, 79, 139, 0.34), rgba(255, 232, 95, 0.26));
  color: var(--berry);
}

.game-control--end::before {
  color: var(--berry);
  content: "■";
}

.falling-stats {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(4, 1fr);
}

.falling-stats div {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.34)),
    linear-gradient(135deg, rgba(41, 182, 246, 0.3), rgba(62, 219, 147, 0.22));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  gap: 3px;
  padding: 9px 10px;
  text-align: center;
}

.falling-stats span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.falling-stats strong {
  color: #006f84;
  font-size: 20px;
}

.quest-panel {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.8), rgba(255, 246, 210, 0.32)),
    linear-gradient(135deg, rgba(255, 61, 127, 0.24), rgba(255, 225, 90, 0.36), rgba(62, 219, 147, 0.24), rgba(41, 182, 246, 0.22));
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(180px, 1.1fr) minmax(180px, 1fr) minmax(116px, auto);
  padding: 12px;
}

.quest-title {
  color: var(--teal);
  display: block;
  font-size: 15px;
  font-weight: 900;
}

.quest-panel p {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
  margin-top: 5px;
}

.candy-jar {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.58), rgba(255, 255, 255, 0.1)),
    repeating-linear-gradient(90deg, rgba(47, 215, 167, 0.2) 0 18px, rgba(255, 232, 95, 0.2) 18px 36px, rgba(255, 79, 139, 0.16) 36px 54px),
    rgba(255, 255, 255, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 999px;
  height: 22px;
  overflow: hidden;
}

.candy-jar span {
  background:
    linear-gradient(90deg, var(--mint), var(--sky), var(--lemon), var(--peach), var(--strawberry)),
    var(--mint);
  display: block;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 160ms ease;
  width: 100%;
}

.quest-meta {
  display: grid;
  gap: 4px;
  justify-items: end;
  text-align: right;
}

.quest-meta strong {
  color: var(--berry);
  font-size: 20px;
}

.quest-meta span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.quest-meta span.is-flashing {
  color: var(--teal);
}

.falling-stage {
  background:
    linear-gradient(110deg, rgba(255, 255, 255, 0.58), transparent 22% 72%, rgba(255, 255, 255, 0.32)),
    linear-gradient(180deg, rgba(41, 182, 246, 0.42), rgba(62, 219, 147, 0.28) 44%, rgba(255, 61, 127, 0.22)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.5) 0 1px, transparent 1px 52px);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 8px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    inset 0 -1px 0 var(--glass-line);
  min-height: 280px;
  overflow: hidden;
  position: relative;
}

.falling-layer {
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.falling-letter {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.5), transparent 38%),
    linear-gradient(180deg, var(--strawberry), #ff75a7 52%, var(--peach));
  border: 2px solid rgba(255, 255, 255, 0.78);
  border-radius: 8px;
  box-shadow: 0 14px 28px rgba(255, 61, 127, 0.3);
  color: #ffffff;
  display: grid;
  font-size: 30px;
  font-weight: 900;
  justify-items: center;
  left: 0;
  position: absolute;
  text-transform: uppercase;
  top: 0;
  will-change: transform;
}

.falling-letter span {
  line-height: 1;
}

.falling-letter.has-power {
  font-size: 24px;
}

.catch-line {
  background:
    linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), transparent),
    repeating-linear-gradient(90deg, rgba(47, 215, 167, 0.62) 0 16px, rgba(72, 184, 255, 0.58) 16px 32px, rgba(255, 232, 95, 0.64) 32px 48px, rgba(255, 79, 139, 0.52) 48px 64px);
  bottom: 62px;
  height: 8px;
  left: 0;
  position: absolute;
  right: 0;
  z-index: 2;
}

.game-overlay {
  align-items: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0.3)),
    linear-gradient(135deg, rgba(255, 217, 31, 0.22), rgba(255, 47, 134, 0.18), rgba(21, 168, 255, 0.18));
  backdrop-filter: blur(18px) saturate(1.3);
  display: none;
  gap: 8px;
  inset: 0;
  justify-content: center;
  padding: 24px;
  position: absolute;
  text-align: center;
  z-index: 3;
}

.game-overlay.is-visible {
  display: grid;
}

.game-overlay strong {
  color: var(--berry);
  font-size: 28px;
}

.game-overlay span {
  color: var(--muted);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.6;
}

.falling-keyboard-panel {
  min-height: 210px;
}

/* Candy game-board refresh inspired by the supplied reference. */
body {
  background:
    radial-gradient(circle at 8% 18%, rgba(255, 255, 255, 0.9) 0 32px, transparent 34px),
    radial-gradient(circle at 17% 12%, rgba(255, 255, 255, 0.86) 0 22px, transparent 24px),
    radial-gradient(circle at 88% 9%, rgba(255, 255, 255, 0.72) 0 34px, transparent 36px),
    linear-gradient(180deg, #62d8ff 0 28%, #b9fff1 47%, #fff0b7 100%);
}

body::before {
  background:
    radial-gradient(circle at 4% 74%, rgba(255, 126, 167, 0.4) 0 88px, transparent 90px),
    radial-gradient(circle at 98% 42%, rgba(133, 105, 255, 0.32) 0 110px, transparent 112px),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0 2px, transparent 2px 18px);
  opacity: 0.9;
}

body::after {
  background:
    linear-gradient(180deg, transparent 0 66%, rgba(0, 176, 218, 0.16) 66% 72%, transparent 72%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.3) 0 18px, rgba(255, 139, 179, 0.2) 18px 36px, rgba(255, 230, 90, 0.2) 36px 54px, rgba(75, 219, 160, 0.18) 54px 72px);
  opacity: 0.38;
}

.app-shell {
  gap: 20px;
  grid-template-columns: minmax(0, 1fr) 388px;
  padding: 18px;
}

.hero,
.practice-panel,
.keyboard-panel,
.side-panel,
.tips,
.score-strip div,
.today-metrics div {
  border-color: rgba(255, 255, 255, 0.86);
  box-shadow:
    0 18px 36px rgba(78, 74, 124, 0.16),
    inset 0 2px 0 rgba(255, 255, 255, 0.82),
    inset 0 -2px 0 rgba(80, 115, 146, 0.08);
}

.hero {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.18), transparent 42%),
    radial-gradient(circle at 8% 74%, #ffd66d 0 28px, transparent 30px),
    radial-gradient(circle at 12% 66%, #ff79ad 0 30px, transparent 32px),
    radial-gradient(circle at 23% 72%, #9ff17d 0 26px, transparent 28px),
    linear-gradient(180deg, #25b6ff 0%, #59dcff 48%, #8af2ff 100%);
  border-radius: 8px;
  min-height: 232px;
  padding: 22px 340px 20px 34px;
}

.hero::before {
  background:
    radial-gradient(circle at 5% 78%, #fff 0 24px, transparent 25px),
    radial-gradient(circle at 8% 70%, #ffd66d 0 48px, transparent 50px),
    linear-gradient(180deg, transparent 0 67%, rgba(255, 255, 255, 0.6) 67% 69%, rgba(0, 149, 214, 0.28) 69% 100%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.22) 0 2px, transparent 2px 16px);
  opacity: 1;
}

.hero::after {
  background:
    linear-gradient(90deg, #ff3e7f, #ff9f1c, #ffe15a, #3edb93, #29b6f6, #8768ff),
    linear-gradient(180deg, rgba(255, 255, 255, 0.5), transparent);
  border-radius: 999px;
  bottom: 0;
  height: 8px;
  left: 0;
  right: 0;
}

.hero h1 {
  color: #ff3f77;
  font-size: clamp(44px, 6.2vw, 72px);
  letter-spacing: 0;
  line-height: 0.92;
  -webkit-text-stroke: 3px #ffffff;
  text-shadow:
    0 5px 0 #be2f70,
    0 9px 0 rgba(255, 212, 70, 0.7),
    0 18px 30px rgba(57, 72, 128, 0.28);
}

.hero__copy {
  background: linear-gradient(180deg, #ff668c, #f63470);
  border: 2px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  box-shadow: 0 10px 16px rgba(238, 45, 100, 0.24), inset 0 2px 0 rgba(255, 255, 255, 0.44);
  color: #ffffff;
  display: inline-flex;
  font-weight: 900;
  margin-top: 10px;
  padding: 7px 14px;
  text-shadow: 0 1px 0 rgba(139, 18, 70, 0.18);
}

.hero-actions {
  gap: 16px;
  margin-top: 16px;
}

.hero-action {
  border-radius: 999px;
  font-size: 20px;
  min-height: 56px;
  min-width: 176px;
}

.hero-action::before {
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.08);
  content: "▶";
  display: inline-grid;
  height: 34px;
  margin-right: 10px;
  place-items: center;
  width: 34px;
}

.hero-action:nth-child(2)::before {
  content: "↻";
}

.hero-action:nth-child(3)::before {
  content: "★";
}

.mini-game-links .page-link {
  border-radius: 999px;
  min-height: 38px;
  padding: 0 16px;
}

.hero__scene {
  bottom: 12px;
  height: 170px;
  pointer-events: none;
  position: absolute;
  right: 210px;
  width: 218px;
  z-index: 1;
}

.hero__island,
.hero__boat,
.hero__candy {
  position: absolute;
}

.hero__island {
  background:
    radial-gradient(circle at 42% 14%, #ff7fad 0 26px, transparent 28px),
    radial-gradient(circle at 64% 20%, #ffd76d 0 24px, transparent 26px),
    linear-gradient(180deg, #ffe889 0 48%, #54d97b 49% 70%, #d88e41 71% 100%);
  border: 4px solid rgba(255, 255, 255, 0.85);
  border-radius: 48% 52% 45% 55% / 55% 55% 45% 45%;
  box-shadow: 0 18px 28px rgba(24, 118, 168, 0.22);
  height: 112px;
  left: 0;
  top: 60px;
  width: 120px;
}

.hero__boat {
  background:
    radial-gradient(circle at 58% 22%, #ff648c 0 24px, transparent 25px),
    radial-gradient(circle at 72% 18%, #ffe15a 0 13px, transparent 14px),
    linear-gradient(150deg, transparent 0 20%, #ffbf31 21% 100%);
  border: 4px solid rgba(255, 255, 255, 0.82);
  border-radius: 52% 48% 58% 42% / 50% 52% 48% 50%;
  box-shadow: 0 18px 24px rgba(24, 118, 168, 0.24);
  height: 120px;
  right: 0;
  top: 36px;
  width: 150px;
}

.hero__candy {
  background:
    radial-gradient(circle, #ffffff 0 18%, transparent 20%),
    repeating-conic-gradient(from 20deg, #ff3f77 0 18deg, #ffffff 18deg 34deg, #ffe15a 34deg 50deg, #ffffff 50deg 66deg);
  border: 3px solid rgba(255, 255, 255, 0.8);
  border-radius: 999px;
  box-shadow: 0 8px 14px rgba(75, 70, 130, 0.18);
  height: 54px;
  width: 54px;
}

.hero__candy--one {
  right: 12px;
  top: 0;
}

.hero__candy--two {
  height: 38px;
  left: 116px;
  top: 24px;
  width: 38px;
}

.hero__badge {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.62)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(191, 245, 255, 0.7));
  border-radius: 8px;
  bottom: 34px;
  box-shadow: 0 18px 32px rgba(51, 94, 138, 0.18), inset 0 2px 0 #fff;
  min-width: 190px;
  padding: 18px;
  position: absolute;
  right: 28px;
  top: auto;
}

.hero__badge strong {
  color: #ef2f78;
  font-size: 30px;
}

.practice-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(255, 252, 235, 0.82)),
    linear-gradient(135deg, rgba(255, 235, 142, 0.5), rgba(160, 248, 229, 0.5));
  border: 3px solid rgba(255, 255, 255, 0.82);
  border-radius: 8px;
  gap: 10px;
  padding: 16px;
}

.practice-panel::before,
.keyboard-panel::before {
  height: 10px;
}

.level-meta {
  align-items: center;
  background: rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  padding: 0 8px 4px 0;
}

.level-meta h2 {
  color: #17356a;
  font-size: 24px;
}

.level-pill {
  background: linear-gradient(180deg, #ff7a94, #f33676);
  border: 2px solid rgba(255, 255, 255, 0.8);
  color: #ffffff;
  font-size: 16px;
  padding: 7px 14px;
}

.star-goals {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 249, 230, 0.72));
  border-color: rgba(255, 204, 87, 0.44);
  grid-template-columns: minmax(150px, auto) 1fr;
  padding: 8px;
}

.star-goals strong {
  color: #f2256e;
  font-size: 28px;
}

.star-goals li {
  align-items: center;
  background: transparent;
  border-width: 0 0 0 1px;
  border-color: rgba(255, 202, 100, 0.45);
  display: flex;
  justify-content: center;
  min-height: 36px;
  position: relative;
}

.star-goals li::after {
  color: #ffc33f;
  content: "☆";
  font-size: 24px;
  margin-left: 14px;
  text-shadow: 0 2px 0 #fff;
}

.practice-progress {
  display: none;
}

.prompt-board {
  grid-template-columns: minmax(0, 1fr) 112px;
}

.prompt-text {
  background: #ffffff;
  border: 2px solid rgba(165, 221, 255, 0.8);
  box-shadow: 0 10px 22px rgba(62, 104, 150, 0.12), inset 0 2px 0 #ffffff;
  min-height: 82px;
}

.prompt-char {
  color: #101a55;
  font-size: 30px;
}

.prompt-char.is-current {
  background: linear-gradient(180deg, #fff676, #ffbe35);
  border: 3px solid #ffffff;
  border-radius: 8px;
  box-shadow: 0 5px 0 rgba(235, 143, 32, 0.45);
}

.current-target {
  background:
    radial-gradient(circle at 50% 42%, rgba(255, 255, 255, 0.9) 0 42%, rgba(255, 224, 239, 0.86) 43% 100%),
    repeating-conic-gradient(from 18deg, rgba(255, 255, 255, 0.75) 0 10deg, rgba(255, 209, 229, 0.62) 10deg 20deg);
  border: 4px solid rgba(255, 255, 255, 0.82);
  border-radius: 999px;
  box-shadow: 0 12px 24px rgba(255, 74, 135, 0.18);
  min-height: 82px;
}

.current-target strong {
  color: #f2256e;
  font-size: 46px;
}

.typing-box {
  height: 1px;
  opacity: 0;
  overflow: hidden;
  padding: 0;
  pointer-events: none;
  position: absolute;
  width: 1px;
}

.keyboard-panel {
  background: rgba(255, 255, 255, 0.72);
  border: 3px solid rgba(255, 255, 255, 0.82);
  border-radius: 8px;
  min-height: 232px;
  padding: 16px;
}

.keyboard {
  gap: 9px;
}

.key-row {
  gap: 9px;
}

.key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.74), transparent 38%),
    linear-gradient(180deg, #fff68e, #ffd35d);
  border: 2px solid rgba(255, 183, 57, 0.55);
  border-radius: 8px;
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.8),
    inset 0 -5px 0 rgba(222, 144, 22, 0.18),
    0 7px 0 rgba(224, 153, 45, 0.18);
  color: #be2f37;
  font-size: clamp(15px, 1.65vw, 19px);
  height: clamp(40px, 4.8vw, 50px);
  min-width: clamp(38px, 4.8vw, 54px);
}

.key-row:nth-child(1) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), transparent 38%),
    linear-gradient(180deg, #ffd8e9, #ff9cc3);
  border-color: rgba(255, 125, 172, 0.52);
}

.key-row:nth-child(2) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), transparent 38%),
    linear-gradient(180deg, #fff68e, #ffd35d);
}

.key-row:nth-child(3) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), transparent 38%),
    linear-gradient(180deg, #fff6a3, #ffe26c);
}

.key-row:nth-child(4) .key {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), transparent 38%),
    linear-gradient(180deg, #f3d6ff, #cda2ff);
  border-color: rgba(160, 105, 255, 0.44);
  color: #4f32a5;
}

.key--wide {
  background:
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.38) 0 14px, transparent 14px 28px),
    linear-gradient(180deg, #ffd8e9, #ff9ec6) !important;
  min-width: min(34vw, 330px);
}

.key.is-target {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.75), transparent 36%),
    linear-gradient(180deg, #b9ff62, #7edf2f) !important;
  border-color: rgba(117, 194, 32, 0.72);
  color: #122c68;
  transform: translateY(-4px);
}

.side-panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(255, 245, 222, 0.7));
  border: 3px solid rgba(255, 255, 255, 0.8);
  border-radius: 8px;
  gap: 16px;
  padding: 18px;
}

.today-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(244, 251, 255, 0.72)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(189, 245, 255, 0.55));
}

.today-card .section-head h2::before {
  background: radial-gradient(circle, #ffd84d 0 35%, #ffae2b 36% 100%);
  border-radius: 999px;
  height: 18px;
  width: 18px;
}

.today-metrics strong,
.score-strip strong {
  color: #17356a;
}

.level-map {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 246, 236, 0.72));
  border: 2px solid rgba(255, 255, 255, 0.74);
  border-radius: 8px;
  gap: 18px 20px;
  padding: 24px;
  position: relative;
}

.level-button {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #ff789d, #f43977);
  border: 3px solid rgba(255, 255, 255, 0.75);
  border-radius: 999px;
  box-shadow:
    inset 0 4px 6px rgba(255, 255, 255, 0.42),
    inset 0 -8px 12px rgba(145, 34, 86, 0.14),
    0 12px 20px rgba(118, 76, 138, 0.18);
  color: #ffffff;
  padding: 4px;
}

.level-button:nth-child(4n + 1) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #ff789d, #f43977);
}

.level-button:nth-child(4n + 2) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffb342, #ff7e1f);
}

.level-button:nth-child(4n + 3) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffe86c, #ffc531);
  color: #7f4c00;
}

.level-button:nth-child(4n) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #9cff68, #4ecb42);
}

.level-button span {
  font-size: 24px;
  text-shadow: 0 2px 0 rgba(74, 44, 80, 0.18);
}

.level-button small {
  display: none;
}

.level-button em {
  color: #fff453;
  font-size: 13px;
  text-shadow: 0 1px 0 rgba(123, 67, 0, 0.28);
}

.level-button.is-current {
  outline: 4px solid rgba(255, 93, 142, 0.28);
  transform: translateY(-3px);
}

.level-button.is-locked {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.7) 0 18%, transparent 20%),
    linear-gradient(180deg, #f2f2f2, #c7c7c7);
  color: #555;
  opacity: 1;
}

.wrong-key-chip,
.sticker {
  border-radius: 999px;
}

.app-shell {
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 18px;
  min-height: 100vh;
  padding: 18px;
}

.lesson-area {
  gap: 12px;
}

.hero {
  background:
    radial-gradient(circle at 8% 78%, #ffe45f 0 26px, transparent 28px),
    radial-gradient(circle at 13% 70%, #ff80aa 0 34px, transparent 36px),
    radial-gradient(circle at 18% 80%, #63de75 0 28px, transparent 30px),
    linear-gradient(180deg, #1dafff 0 58%, #62e8ff 59% 100%);
  height: 270px;
  min-height: 0;
  padding: 24px 360px 18px 32px;
}

.hero::before {
  background:
    radial-gradient(circle at 7% 24%, #ffffff 0 10px, transparent 11px),
    radial-gradient(circle at 10% 19%, #ffffff 0 16px, transparent 17px),
    radial-gradient(circle at 14% 23%, #ffffff 0 12px, transparent 13px),
    linear-gradient(180deg, transparent 0 63%, rgba(255, 255, 255, 0.52) 64% 66%, rgba(0, 139, 205, 0.28) 67% 100%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0 2px, transparent 2px 18px);
}

.hero > div:first-child {
  max-width: 660px;
}

.hero h1 {
  color: #ff4b78;
  font-size: clamp(52px, 6.6vw, 88px);
  line-height: 0.82;
  margin-top: 8px;
  position: relative;
  text-shadow:
    0 0 0 #ffffff,
    0 4px 0 #ffffff,
    0 8px 0 #c72c73,
    0 12px 0 rgba(255, 211, 83, 0.82),
    0 20px 34px rgba(34, 82, 137, 0.28);
}

.hero h1::before {
  color: #fff;
  content: "糖果打字岛";
  filter: blur(1px);
  left: 0;
  opacity: 0.78;
  position: absolute;
  top: 0;
  transform: translate(-5px, -5px);
  z-index: -1;
}

.hero__copy {
  font-size: 15px;
  margin-left: 122px;
  margin-top: 14px;
  padding: 8px 18px;
}

.hero-actions {
  margin-left: 190px;
  margin-top: 18px;
}

.hero-actions #heroReviewButton,
.mini-game-links {
  display: none;
}

.mini-game-links {
  margin-left: 0;
  margin-top: 8px;
}

.hero__scene {
  bottom: 24px;
  height: 218px;
  right: 210px;
  width: 300px;
}

.hero__island {
  border-width: 5px;
  height: 150px;
  left: 0;
  top: 48px;
  width: 158px;
}

.hero__island::before {
  background:
    linear-gradient(180deg, #ff8fbd, #ff5e9d);
  border: 4px solid #ffffff;
  border-radius: 42% 42% 18% 18%;
  box-shadow:
    38px 18px 0 -4px #ffc86a,
    72px -8px 0 -2px #ff7bae;
  content: "";
  height: 66px;
  left: 22px;
  position: absolute;
  top: -58px;
  width: 48px;
}

.hero__island::after {
  background: #ffffff;
  border-radius: 999px;
  box-shadow:
    24px -8px 0 4px #ffffff,
    48px 2px 0 1px #ffffff;
  content: "";
  height: 20px;
  left: 18px;
  position: absolute;
  top: -76px;
  width: 36px;
}

.hero__boat {
  height: 146px;
  right: 0;
  top: 36px;
  width: 178px;
}

.hero__boat::before {
  background:
    radial-gradient(circle at 36% 38%, #482a38 0 5px, transparent 6px),
    radial-gradient(circle at 63% 38%, #482a38 0 5px, transparent 6px),
    radial-gradient(circle at 50% 62%, #9a274b 0 12px, transparent 13px),
    linear-gradient(180deg, #ff7f91, #ff4c7c);
  border: 4px solid rgba(255, 255, 255, 0.88);
  border-radius: 47% 53% 45% 55%;
  box-shadow: 0 8px 0 rgba(179, 51, 90, 0.16);
  content: "";
  height: 72px;
  left: 42px;
  position: absolute;
  top: -18px;
  width: 72px;
}

.hero__boat::after {
  background:
    linear-gradient(100deg, transparent 0 35%, #ffffff 36% 42%, transparent 43%),
    linear-gradient(180deg, #ffcb48, #ffae2d);
  border: 4px solid #ffffff;
  border-radius: 20% 70% 48% 48%;
  content: "";
  height: 72px;
  left: 4px;
  position: absolute;
  top: 72px;
  width: 164px;
}

.hero__badge {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr 1fr;
  min-width: 230px;
  padding: 18px 20px 42px;
}

.hero__badge::before {
  color: #19315d;
  content: "今日进度";
  font-weight: 900;
  grid-column: 1 / -1;
}

.hero__badge::after {
  background:
    linear-gradient(90deg, #22bdf3 0 64%, #e8edf2 64% 100%);
  border-radius: 999px;
  bottom: 18px;
  content: "";
  height: 9px;
  left: 22px;
  position: absolute;
  right: 22px;
}

.hero__badge span,
.hero__badge strong {
  align-items: center;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  display: grid;
  min-height: 68px;
  place-items: center;
}

.practice-panel {
  min-height: 590px;
  padding: 16px 20px 14px;
}

.level-meta {
  min-height: 54px;
}

.prompt-board {
  grid-template-columns: minmax(0, 1fr) 118px;
}

.prompt-text {
  min-height: 84px;
  padding: 16px 22px;
}

.keyboard-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.78));
  border-radius: 8px;
  min-height: 226px;
  padding: 10px 14px 12px;
}

.keyboard {
  gap: 7px;
}

.key-row {
  gap: 7px;
}

.key {
  height: 36px;
  min-width: 53px;
}

.key--wide {
  min-width: 410px;
}

.key-row--home {
  padding-left: 52px;
}

.key-row--bottom {
  padding-left: 108px;
}

.actions {
  bottom: 68px;
  position: absolute;
  right: 22px;
  z-index: 2;
}

.score-strip {
  align-items: center;
  background: transparent;
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr 1fr 1fr;
  margin-top: 2px;
  padding: 0 8px;
}

.score-strip div {
  align-items: center;
  background: transparent;
  border: 0;
  box-shadow: none;
  display: flex;
  gap: 10px;
  justify-content: center;
  min-height: 42px;
  padding: 0;
  text-align: left;
}

.score-strip div::before {
  background:
    radial-gradient(circle at 44% 38%, #ffdf72 0 22%, #ffc22f 23% 60%, #f59a20 61% 100%);
  border: 3px solid #ffffff;
  border-radius: 999px;
  box-shadow: 0 5px 12px rgba(149, 89, 0, 0.18);
  content: "";
  height: 44px;
  width: 44px;
}

.score-strip div:first-child::before {
  background:
    radial-gradient(circle at 50% 40%, #8a5a2b 0 16%, transparent 17%),
    radial-gradient(circle at 38% 54%, #ffffff 0 7%, transparent 8%),
    radial-gradient(circle at 62% 54%, #ffffff 0 7%, transparent 8%),
    linear-gradient(180deg, #ffbf67, #d67838);
}

.score-strip div:nth-child(3)::before {
  background:
    radial-gradient(circle at 45% 45%, #ffffff 0 14%, transparent 15%),
    repeating-conic-gradient(#ff4d8a 0 26deg, #ffffff 26deg 52deg, #ffdc4c 52deg 78deg, #ffffff 78deg 104deg);
}

.score-strip strong {
  font-size: 18px;
}

.side-panel {
  max-height: calc(100vh - 36px);
  overflow: hidden;
}

.map-card {
  display: grid;
  gap: 12px;
}

.map-card .section-head {
  justify-content: center;
  margin-bottom: -3px;
  position: relative;
  z-index: 2;
}

.map-card .section-head h2 {
  background: linear-gradient(180deg, #ff6f9a, #f33573);
  border: 3px solid rgba(255, 255, 255, 0.75);
  border-radius: 8px;
  box-shadow: 0 8px 14px rgba(230, 45, 105, 0.26);
  color: #ffffff;
  font-size: 18px;
  padding: 8px 22px;
}

.map-card .section-head h2::before {
  display: none;
}

.map-card .ghost-button {
  position: absolute;
  right: 0;
  top: 2px;
}

.level-map {
  gap: 16px 22px;
  min-height: 418px;
  padding: 34px 28px 18px;
}

.level-map::before {
  background:
    repeating-linear-gradient(90deg, transparent 0 47px, rgba(255, 168, 75, 0.62) 47px 54px, transparent 54px 96px),
    repeating-linear-gradient(180deg, transparent 0 72px, rgba(255, 193, 56, 0.42) 72px 78px, transparent 78px 130px);
  content: "";
  inset: 40px 40px 30px;
  opacity: 0.7;
  pointer-events: none;
  position: absolute;
}

.level-button {
  position: relative;
  z-index: 1;
}

.level-button.is-locked::after {
  bottom: -13px;
  color: #555;
  content: "锁";
  font-size: 12px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
}

.side-duo {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr 1fr;
}

.side-duo .tips {
  min-height: 154px;
}

.mistake-card {
  background:
    radial-gradient(circle at 46% 62%, rgba(255, 211, 75, 0.72) 0 44px, transparent 46px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 242, 224, 0.78));
  position: relative;
}

.mistake-card::after {
  background:
    radial-gradient(circle at 50% 40%, #ff7fab 0 12%, transparent 13%),
    radial-gradient(circle at 40% 54%, #ffe15a 0 15%, transparent 16%),
    radial-gradient(circle at 62% 56%, #ff4b78 0 13%, transparent 14%),
    linear-gradient(180deg, #c16b20, #a75117);
  border-radius: 999px 999px 35% 35%;
  bottom: 28px;
  content: "";
  height: 86px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
  width: 118px;
}

.mistake-card .section-head,
.today-card .section-head,
.mistake-card p,
.wrong-key-list {
  position: relative;
  z-index: 1;
}

.today-card {
  background:
    radial-gradient(circle at 66% 78%, rgba(255, 73, 131, 0.28) 0 36px, transparent 38px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 250, 225, 0.78));
}

.today-metrics {
  display: none;
}

.today-card p {
  color: #25436d;
  font-size: 13px;
  line-height: 1.55;
}

.sticker-grid {
  grid-template-columns: repeat(5, 1fr);
}

.sticker {
  align-items: center;
  aspect-ratio: 1;
  display: grid;
  font-size: 0;
  justify-items: center;
  padding: 0;
}

.sticker::before {
  background:
    radial-gradient(circle at 50% 44%, #ffffff 0 14%, transparent 15%),
    repeating-conic-gradient(#ff4d8a 0 36deg, #ffffff 36deg 72deg, #42c8ff 72deg 108deg, #ffffff 108deg 144deg);
  border: 4px solid rgba(255, 255, 255, 0.86);
  border-radius: 999px;
  box-shadow: 0 6px 10px rgba(83, 70, 130, 0.16);
  content: "";
  height: 48px;
  width: 48px;
}

.sticker:first-child::before {
  background: linear-gradient(180deg, #ffbf67, #d67838);
}

.sticker:nth-child(2)::before {
  background:
    radial-gradient(circle at 50% 50%, #fff169 0 36%, #ffc32d 37% 100%);
  clip-path: polygon(50% 0, 62% 35%, 100% 35%, 69% 56%, 82% 96%, 50% 72%, 18% 96%, 31% 56%, 0 35%, 38% 35%);
}

.sticker:nth-child(4)::before {
  background:
    radial-gradient(circle at 50% 18%, #ff77a6 0 18%, transparent 19%),
    linear-gradient(180deg, #fff2c4, #ffbfdb);
  border-radius: 40% 40% 18% 18%;
}

.sticker:nth-child(5)::before {
  background:
    radial-gradient(circle at 30% 70%, #ffffff 0 20%, transparent 21%),
    radial-gradient(circle at 48% 62%, #ffffff 0 24%, transparent 25%),
    radial-gradient(circle at 66% 70%, #ffffff 0 20%, transparent 21%),
    linear-gradient(90deg, #ff4d8a, #ffe15a, #42c8ff);
  border-radius: 999px;
}

.utility-tip {
  display: none;
}

@media (max-width: 980px) {
  .app-shell,
  .falling-shell,
  .word-shell {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-right: 260px;
  }

  .hero__scene {
    right: 24px;
    transform: scale(0.82);
    transform-origin: right bottom;
  }

  .side-panel {
    max-height: none;
  }
}

@media (max-width: 680px) {
  .app-shell,
  .falling-shell,
  .word-shell {
    padding: 10px;
    width: 100%;
  }

  .lesson-area,
  .hero,
  .practice-panel,
  .keyboard-panel,
  .side-panel,
  .falling-main,
  .word-main,
  .falling-game-panel,
  .word-game-panel {
    max-width: calc(100vw - 20px);
    min-width: 0;
    width: 100%;
  }

  .hero-link-secondary {
    margin-left: 0;
  }

  .hero,
  .level-meta,
  .prompt-board {
    grid-template-columns: 1fr;
  }

  .hero {
    align-items: start;
    display: grid;
    gap: 14px;
    min-height: 330px;
    padding: 24px;
  }

  .hero__scene {
    bottom: 74px;
    left: 24px;
    right: auto;
    transform: scale(0.58);
    transform-origin: left bottom;
  }

  .hero__badge {
    bottom: 18px;
    left: 24px;
    min-width: 0;
    right: 24px;
    width: auto;
  }

  .hero h1 {
    font-size: clamp(42px, 17vw, 64px);
    -webkit-text-stroke: 2px #ffffff;
  }

  .hero__copy {
    border-radius: 8px;
  }

  .hero-action {
    flex: 1 1 100%;
    font-size: 18px;
    min-width: 0;
  }

  .prompt-board {
    gap: 14px;
  }

  .level-meta {
    display: grid;
  }

  .level-meta p {
    text-align: left;
  }

  .prompt-board {
    display: grid;
  }

  .star-goals,
  .star-goals ul {
    grid-template-columns: 1fr;
  }

  .actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .keyboard-panel {
    overflow-x: auto;
  }

  .keyboard {
    min-width: 620px;
  }

  .score-strip {
    grid-template-columns: 1fr;
  }

  .falling-main {
    grid-template-rows: auto minmax(520px, 1fr) auto;
  }

  .word-main {
    grid-template-rows: auto minmax(620px, 1fr);
  }

  .falling-toolbar {
    align-items: stretch;
    display: grid;
  }

  .word-game-panel {
    grid-template-rows: auto auto auto minmax(320px, 1fr) auto;
  }

  .word-target-card {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .mode-tabs {
    grid-template-columns: repeat(2, 1fr);
  }

  .falling-actions,
  .falling-stats {
    grid-template-columns: 1fr 1fr;
  }

  .falling-actions,
  .falling-stats {
    display: grid;
  }

  .quest-panel {
    grid-template-columns: 1fr;
  }

  .quest-meta {
    justify-items: start;
    text-align: left;
  }

  .falling-keyboard-panel {
    overflow-x: auto;
  }
}

/* Keep the main hero readable when the right progress rail leaves a medium-width play area. */
.hero {
  padding: 24px clamp(240px, 26vw, 330px) 18px 32px;
}

.hero > div:first-child {
  max-width: min(520px, 100%);
  min-width: 340px;
  position: relative;
  z-index: 2;
}

.hero h1 {
  font-size: clamp(44px, 4.8vw, 66px);
  line-height: 0.92;
  max-width: 100%;
  white-space: nowrap;
}

.hero__copy,
.hero-actions {
  margin-left: 0;
}

.hero__copy {
  max-width: 420px;
}

.hero-actions {
  max-width: 440px;
}

.hero__scene {
  right: clamp(145px, 16vw, 210px);
  transform: scale(0.78);
  transform-origin: right bottom;
  z-index: 1;
}

.hero__badge {
  right: 22px;
  z-index: 3;
}

@media (max-width: 980px) {
  .hero {
    padding-right: 236px;
  }

  .hero > div:first-child {
    min-width: 320px;
  }

  .hero__scene {
    right: 112px;
    transform: scale(0.68);
  }

  .hero__badge {
    min-width: 188px;
  }
}

@media (max-width: 680px) {
  .hero {
    min-height: 560px;
    padding: 24px;
  }

  .hero > div:first-child {
    min-width: 0;
    width: 100%;
  }

  .hero h1 {
    font-size: clamp(42px, 15vw, 62px);
    white-space: normal;
  }

  .hero__copy,
  .hero-actions {
    max-width: none;
  }

  .hero__scene {
    bottom: 190px;
    left: 18px;
    right: auto;
    transform: scale(0.48);
    transform-origin: left bottom;
  }

  .hero-actions {
    position: relative;
    z-index: 4;
  }

  .hero__badge {
    bottom: 18px;
    top: auto;
  }
}

/* Reference-inspired candy island skin for the main practice screen. */
.visually-hidden {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

@media (min-width: 981px) {
  body {
    background:
      radial-gradient(circle at 3% 14%, rgba(255, 255, 255, 0.9) 0 22px, transparent 23px),
      radial-gradient(circle at 0 72%, rgba(255, 144, 185, 0.34) 0 140px, transparent 142px),
      radial-gradient(circle at 98% 6%, rgba(157, 165, 255, 0.45) 0 130px, transparent 132px),
      linear-gradient(180deg, #22b8ff 0 23%, #76e8ff 24% 40%, #d5fff1 41% 100%);
  }

  .app-shell {
    gap: 14px;
    grid-template-columns: minmax(760px, 1fr) 340px;
    height: 100vh;
    min-height: 700px;
    overflow: hidden;
    padding: 12px;
  }

  .lesson-area {
    gap: 10px;
    grid-template-rows: 198px minmax(0, 1fr);
    overflow: hidden;
  }

  .hero {
    background:
      radial-gradient(circle at 4% 18%, rgba(255, 255, 255, 0.86) 0 11px, transparent 12px),
      radial-gradient(circle at 8% 20%, rgba(255, 255, 255, 0.82) 0 18px, transparent 19px),
      radial-gradient(circle at 13% 18%, rgba(255, 255, 255, 0.8) 0 12px, transparent 13px),
      radial-gradient(circle at 6% 50%, #ffd15d 0 54px, transparent 56px),
      radial-gradient(circle at 10% 45%, #ff74a8 0 64px, transparent 66px),
      radial-gradient(circle at 15% 52%, #66de75 0 52px, transparent 54px),
      linear-gradient(180deg, #26b7ff 0 58%, #65e5ff 59% 100%);
    border: 2px solid rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    box-shadow:
      0 18px 34px rgba(38, 107, 164, 0.18),
      inset 0 2px 0 rgba(255, 255, 255, 0.74);
    height: 198px;
    min-height: 0;
    padding: 22px 295px 18px 34px;
  }

  .hero::before {
    background:
      linear-gradient(180deg, transparent 0 61%, rgba(255, 255, 255, 0.62) 62% 64%, rgba(0, 138, 208, 0.28) 65% 100%),
      repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.24) 0 2px, transparent 2px 18px);
  }

  .hero > div:first-child {
    max-width: 560px;
    min-width: 0;
    z-index: 4;
  }

  .eyebrow {
    color: #0d7ba7;
    font-size: 11px;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
  }

  .hero h1 {
    color: #ff477b;
    font-size: clamp(54px, 5.8vw, 78px);
    letter-spacing: 0;
    line-height: 0.86;
    margin-top: 4px;
    max-width: none;
    text-shadow:
      0 3px 0 #ffffff,
      0 7px 0 #ffffff,
      0 10px 0 rgba(190, 45, 113, 0.9),
      0 14px 0 rgba(255, 209, 79, 0.78),
      0 18px 24px rgba(35, 94, 141, 0.22);
    white-space: nowrap;
    -webkit-text-stroke: 0;
  }

  .hero h1::before {
    color: #ffffff;
    filter: none;
    opacity: 0.85;
    transform: translate(-4px, -4px);
  }

  .hero__copy {
    background: linear-gradient(180deg, #ff789c, #f63f7a);
    border: 2px solid rgba(255, 255, 255, 0.82);
    border-radius: 999px;
    box-shadow:
      0 8px 14px rgba(227, 55, 113, 0.22),
      inset 0 2px 0 rgba(255, 255, 255, 0.38);
    color: #ffffff;
    display: inline-flex;
    font-size: 14px;
    font-weight: 900;
    line-height: 1.35;
    margin-top: 8px;
    max-width: 520px;
    padding: 7px 18px;
    text-shadow: 0 1px 0 rgba(139, 18, 70, 0.18);
  }

  .hero-actions {
    gap: 14px;
    margin-top: 14px;
    max-width: none;
  }

  .hero-action {
    border-radius: 999px;
    border-width: 2px;
    font-size: 20px;
    min-height: 52px;
    min-width: 170px;
  }

  .hero__scene {
    bottom: 18px;
    height: 182px;
    right: 205px;
    transform: scale(0.74);
    width: 260px;
    z-index: 2;
  }

  .hero__badge {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(246, 252, 255, 0.74));
    border: 2px solid rgba(255, 255, 255, 0.78);
    border-radius: 8px;
    bottom: auto;
    box-shadow:
      0 14px 28px rgba(39, 91, 144, 0.18),
      inset 0 2px 0 #ffffff;
    display: grid;
    gap: 7px;
    grid-template-columns: 1fr 1fr;
    min-width: 216px;
    padding: 12px;
    right: 22px;
    top: 24px;
    z-index: 5;
  }

  .hero__badge::before,
  .hero__badge::after {
    content: none;
  }

  .hero__badge-title {
    align-items: center;
    color: #19315d;
    display: flex;
    font-size: 13px;
    font-weight: 900;
    gap: 7px;
    grid-column: 1 / -1;
  }

  .hero__badge span,
  .hero__badge strong {
    background: transparent;
    border-radius: 0;
    display: inline;
    min-height: 0;
    place-items: initial;
  }

  .hero__badge .visually-hidden {
    display: block;
    min-height: 1px;
  }

  .hero__badge-title::before {
    background:
      radial-gradient(circle at 42% 38%, #fff8c4 0 20%, transparent 21%),
      radial-gradient(circle, #ffd845 0 58%, #ff9e2f 59% 100%);
    border: 2px solid #fff;
    border-radius: 999px;
    box-shadow: 0 3px 6px rgba(179, 110, 0, 0.18);
    content: "";
    height: 22px;
    width: 22px;
  }

  .hero__metric {
    align-items: center;
    background: rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    display: grid;
    grid-template-columns: auto 1fr;
    min-height: 56px;
    padding: 8px 9px;
  }

  .hero__metric strong {
    color: #19315d;
    font-size: 25px;
    line-height: 1;
  }

  .hero__metric span {
    color: #52637e;
    font-size: 12px;
    font-weight: 900;
    margin-left: 3px;
  }

  .hero__metric em {
    color: #52637e;
    font-size: 12px;
    font-style: normal;
    font-weight: 800;
    grid-column: 1 / -1;
    margin-top: 2px;
  }

  .hero__metric--accuracy {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .hero__metric--accuracy::before {
    color: #ffbd27;
    content: "★";
    font-size: 25px;
    line-height: 0.8;
    text-shadow:
      0 2px 0 #ffffff,
      0 4px 8px rgba(249, 164, 0, 0.28);
  }

  .hero__metric--accuracy strong {
    color: #19315d;
    font-size: 17px;
    margin-top: 0;
  }

  .hero__badge-progress {
    align-items: center;
    display: grid;
    gap: 6px;
    grid-column: 1 / -1;
    grid-template-columns: auto auto;
  }

  .hero__badge-progress span,
  .hero__badge-progress strong {
    color: #405372;
    font-size: 13px;
    font-weight: 900;
  }

  .hero__badge-progress strong {
    justify-self: end;
  }

  .hero__badge-bar {
    background: #e7edf4;
    border-radius: 999px;
    grid-column: 1 / -1;
    height: 9px;
    overflow: hidden;
  }

  .hero__badge-bar i {
    background: linear-gradient(90deg, #20c7ff, #39dba1);
    border-radius: inherit;
    display: block;
    height: 100%;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 180ms ease;
    width: 100%;
  }

  .practice-panel {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 252, 238, 0.86)),
      linear-gradient(135deg, rgba(255, 233, 153, 0.54), rgba(168, 247, 231, 0.48));
    border: 3px solid rgba(255, 255, 255, 0.82);
    display: grid;
    gap: 10px;
    grid-template-rows: auto auto auto auto minmax(0, 1fr) auto;
    min-height: 0;
    overflow: hidden;
    padding: 16px 18px 14px;
  }

  .level-meta {
    align-items: center;
    min-height: 32px;
  }

  .level-meta h2 {
    color: #142c59;
    font-size: 20px;
    margin-top: 0;
  }

  .level-meta p {
    font-size: 14px;
    max-width: 520px;
  }

  .level-pill {
    background: linear-gradient(180deg, #ff6c98, #f33675);
    border: 2px solid rgba(255, 255, 255, 0.78);
    color: #ffffff;
    font-size: 14px;
    padding: 7px 14px;
  }

  .star-goals {
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(255, 204, 126, 0.78);
    grid-template-columns: 170px 1fr;
    min-height: 40px;
    padding: 0;
  }

  .star-goals > div {
    border-right: 1px solid rgba(255, 202, 132, 0.55);
    padding: 6px 16px;
  }

  .star-goals strong {
    color: #f02f76;
    font-size: 22px;
  }

  .star-goals ul {
    gap: 0;
    grid-template-columns: repeat(3, 1fr);
    margin: 0;
    padding: 0;
  }

  .star-goals li {
    align-items: center;
    background: transparent;
    border: 0;
    border-radius: 0;
    border-right: 1px solid rgba(255, 202, 132, 0.55);
    color: #26385c;
    display: grid;
    font-size: 13px;
    grid-template-columns: 1fr auto;
    min-height: 46px;
    padding: 6px 14px;
  }

  .star-goals li:last-child {
    border-right: 0;
  }

  .star-goals li::after {
    color: #ffc93e;
    content: "☆";
    font-size: 24px;
    text-shadow: 0 2px 0 #ffffff;
  }

  .star-goals li.is-done::after {
    content: "★";
  }

  .practice-progress {
    display: none;
  }

  .prompt-board {
    gap: 16px;
    grid-template-columns: minmax(0, 1fr) 104px;
  }

  .prompt-text {
    background: #ffffff;
    border: 1px solid rgba(130, 213, 255, 0.72);
    box-shadow:
      inset 0 1px 0 #ffffff,
      0 8px 18px rgba(33, 74, 126, 0.08);
    gap: 8px;
    min-height: 58px;
    padding: 8px 16px;
  }

  .prompt-char {
    color: #071449;
    font-size: 25px;
    height: 38px;
    min-width: 29px;
  }

  .prompt-char.is-current {
    background: #ffffff;
    border: 3px solid #ffc23e;
    box-shadow:
      0 0 0 4px rgba(255, 235, 142, 0.72),
      inset 0 -4px 0 rgba(255, 210, 90, 0.22);
    color: #f13477;
  }

  .current-target {
    background:
      radial-gradient(circle at 52% 48%, rgba(255, 255, 255, 0.84) 0 44%, rgba(255, 230, 230, 0.84) 45% 100%);
    border: 3px solid rgba(255, 255, 255, 0.86);
    border-radius: 999px;
    box-shadow:
      0 8px 16px rgba(244, 68, 125, 0.16),
      inset 0 1px 0 #ffffff;
    min-height: 72px;
    padding: 8px;
  }

  .current-target strong {
    color: #f02f76;
    font-size: 38px;
  }

  .keyboard-panel {
    align-content: center;
    background: #ffffff;
    border: 2px solid rgba(255, 226, 202, 0.82);
    border-radius: 8px;
    box-shadow:
      inset 0 1px 0 #ffffff,
      0 8px 18px rgba(55, 80, 120, 0.08);
    min-height: 174px;
    overflow: hidden;
    padding: 8px 12px;
  }

  .keyboard-panel::before {
    height: 0;
  }

  .keyboard {
    gap: 4px;
  }

  .key-row {
    gap: 5px;
  }

  .key-row--home {
    padding-left: 40px;
  }

  .key-row--bottom {
    padding-left: 78px;
  }

  .key {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.64), transparent),
      linear-gradient(180deg, #fff7bc, #ffd56b);
    border: 2px solid rgba(255, 192, 62, 0.7);
    box-shadow:
      inset 0 2px 0 rgba(255, 255, 255, 0.74),
      inset 0 -4px 0 rgba(220, 147, 30, 0.18),
      0 4px 8px rgba(113, 80, 45, 0.12);
    color: #bb2b2b;
    font-size: 16px;
    height: 28px;
    min-height: 28px;
    min-width: clamp(39px, 4.8vw, 54px);
    padding: 0 8px;
  }

  .key-row:nth-child(1) .key,
  .key-row:nth-child(5) .key {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.64), transparent),
      linear-gradient(180deg, #ffdbe7, #ff9fbd);
    border-color: rgba(255, 133, 174, 0.74);
  }

  .key-row:nth-child(5) .key {
    background:
      repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.48) 0 12px, transparent 12px 24px),
      linear-gradient(180deg, #ffdbe8, #ff9fbd);
  }

  .key.is-target {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.52), transparent),
      linear-gradient(180deg, #b7f26a, #70d845);
    border-color: #88d83f;
    color: #143157;
    transform: translateY(-2px);
  }

  .key--wide {
    min-width: min(42vw, 360px);
  }

  .typing-box {
    height: 1px;
    margin: 0;
    opacity: 0;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
  }

  .actions {
    display: none;
  }

  .score-strip {
    align-items: center;
    display: grid;
    gap: 18px;
    grid-template-columns: 1fr 1fr 1fr;
    margin-top: 0;
    min-height: 48px;
    padding: 0 8px;
  }

  .score-strip div {
    background: transparent;
    border: 0;
    box-shadow: none;
    display: flex;
    gap: 10px;
    justify-content: center;
    padding: 0;
  }

  .score-strip div::before {
    flex: 0 0 auto;
    height: 34px;
    width: 34px;
  }

  .side-panel {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.68), rgba(255, 248, 226, 0.6)),
      linear-gradient(135deg, rgba(255, 119, 164, 0.2), rgba(255, 219, 93, 0.3), rgba(105, 226, 197, 0.2));
    border: 0;
    box-shadow: none;
    display: grid;
    gap: 12px;
    grid-template-rows: minmax(0, 1fr) 150px 104px;
    max-height: none;
    min-height: 0;
    overflow: hidden;
    padding: 0;
  }

  .map-card,
  .tips {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 250, 238, 0.86));
    border: 2px solid rgba(255, 255, 255, 0.78);
    border-radius: 8px;
    box-shadow: 0 12px 24px rgba(79, 83, 132, 0.12);
  }

  .map-card {
    min-height: 0;
    overflow: hidden;
    padding: 12px;
  }

  .map-card .section-head {
    margin-bottom: 0;
  }

  .map-card .section-head h2 {
    border-radius: 8px;
    font-size: 16px;
    padding: 8px 18px;
  }

  .map-card .ghost-button {
    min-height: 32px;
    right: 8px;
  }

  .level-map {
    align-content: start;
    gap: 12px 18px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    min-height: 0;
    padding: 18px 12px 8px;
    position: relative;
  }

  .level-map::before {
    background:
      repeating-linear-gradient(90deg, transparent 0 54px, rgba(255, 188, 93, 0.42) 54px 59px, transparent 59px 84px),
      repeating-linear-gradient(180deg, transparent 0 56px, rgba(255, 207, 90, 0.34) 56px 61px, transparent 61px 98px);
    inset: 44px 30px 20px;
  }

  .level-button {
    align-content: center;
    aspect-ratio: 1;
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #ff6f93 0 0, #f43b76 68%, #be245b 100%);
    border: 0;
    border-radius: 999px;
    box-shadow:
      inset 0 4px 8px rgba(255, 255, 255, 0.45),
      inset 0 -8px 10px rgba(110, 35, 77, 0.22),
      0 8px 14px rgba(85, 70, 118, 0.16);
    color: #ffffff;
    gap: 0;
    height: auto;
    min-height: 0;
    padding: 4px;
  }

  .level-button span {
    color: inherit;
    font-size: 19px;
    text-shadow: 0 2px 0 rgba(107, 39, 74, 0.22);
  }

  .level-button small {
    display: none;
  }

  .level-button em {
    color: #ffe45f;
    font-size: 11px;
    margin-top: 0;
    text-shadow: 0 1px 0 rgba(126, 78, 0, 0.28);
  }

  .level-button:nth-child(2),
  .level-button:nth-child(11) {
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #ffbc4d 0 0, #ff842f 68%, #c64f17 100%);
  }

  .level-button:nth-child(3),
  .level-button:nth-child(12) {
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #ffe86a 0 0, #ffc83e 68%, #c68512 100%);
  }

  .level-button:nth-child(4),
  .level-button:nth-child(8) {
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #b8f56f 0 0, #70d846 68%, #36a02e 100%);
  }

  .level-button:nth-child(5),
  .level-button:nth-child(9) {
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #b980ff 0 0, #8748ea 68%, #5a28b6 100%);
  }

  .level-button:nth-child(6),
  .level-button:nth-child(7) {
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #94e8ff 0 0, #43bff0 68%, #1b7dbd 100%);
  }

  .level-button:nth-child(n + 13) {
    background:
      radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.72) 0 14%, transparent 15%),
      radial-gradient(circle at 50% 54%, #f8f8f8 0 0, #d1d1d1 68%, #999999 100%);
    color: #444;
  }

  .level-button.is-locked::after {
    bottom: -13px;
  }

  .level-button:nth-child(1) { order: 1; }
  .level-button:nth-child(2) { order: 2; }
  .level-button:nth-child(3) { order: 3; }
  .level-button:nth-child(4) { order: 4; }
  .level-button:nth-child(8) { order: 5; }
  .level-button:nth-child(7) { order: 6; }
  .level-button:nth-child(6) { order: 7; }
  .level-button:nth-child(5) { order: 8; }
  .level-button:nth-child(9) { order: 9; }
  .level-button:nth-child(10) { order: 10; }
  .level-button:nth-child(11) { order: 11; }
  .level-button:nth-child(12) { order: 12; }
  .level-button:nth-child(16) { order: 13; }
  .level-button:nth-child(15) { order: 14; }
  .level-button:nth-child(14) { order: 15; }
  .level-button:nth-child(13) { order: 16; }
  .level-button:nth-child(17) { order: 17; }
  .level-button:nth-child(18) { order: 18; }
  .level-button:nth-child(19) { order: 19; }
  .level-button:nth-child(20) { order: 20; }
  .level-button:nth-child(24) { order: 21; }
  .level-button:nth-child(23) { order: 22; }
  .level-button:nth-child(22) { order: 23; }
  .level-button:nth-child(21) { order: 24; }

  .side-duo {
    gap: 10px;
    grid-template-columns: 1fr 1fr;
    min-height: 0;
  }

  .side-duo .tips {
    min-height: 0;
    overflow: hidden;
    padding: 12px;
  }

  .section-head h2,
  .tips h2 {
    color: #e7286c;
    font-size: 15px;
  }

  .section-head h2::before,
  .tips h2::before {
    display: none;
  }

  .mistake-card::after {
    bottom: 24px;
    height: 76px;
    width: 100px;
  }

  .mistake-card p {
    display: none;
  }

  .wrong-key-list {
    display: none;
  }

  .today-card p {
    margin-top: 8px;
  }

  .sticker-grid {
    gap: 10px;
    grid-template-columns: repeat(5, 1fr);
    margin-top: 8px;
  }

  .sticker::before {
    height: 42px;
    width: 42px;
  }
}

@media (max-width: 980px) {
  .score-strip {
    order: 18;
  }

  .actions {
    bottom: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 2px;
    order: 19;
    position: static;
    right: auto;
    z-index: auto;
  }
}

/* Polish the two arcade mini games so the whole project shares one candy-island art direction. */
.falling-shell,
.word-shell {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 250, 230, 0.12)),
    radial-gradient(circle at 8% 10%, rgba(255, 255, 255, 0.78) 0 34px, transparent 35px),
    radial-gradient(circle at 86% 16%, rgba(255, 255, 255, 0.7) 0 28px, transparent 29px);
}

.falling-hero {
  background:
    radial-gradient(circle at 10% 18%, rgba(255, 255, 255, 0.92) 0 24px, transparent 25px),
    radial-gradient(circle at 16% 15%, rgba(255, 255, 255, 0.82) 0 36px, transparent 37px),
    radial-gradient(circle at 86% 74%, rgba(255, 125, 174, 0.18) 0 46px, transparent 47px),
    radial-gradient(circle at 92% 70%, rgba(255, 221, 95, 0.2) 0 30px, transparent 31px),
    linear-gradient(180deg, #bcefff 0%, #ddf8ff 58%, #fff0c4 59%, #ffe5ad 100%);
  border: 2px solid rgba(255, 255, 255, 0.92);
  box-shadow:
    0 18px 36px rgba(79, 123, 170, 0.16),
    inset 0 2px 0 rgba(255, 255, 255, 0.86);
  overflow: hidden;
}

.falling-hero > div:first-child {
  align-items: center;
  display: grid;
  justify-items: center;
  max-width: 620px;
  min-width: 0;
  text-align: center;
}

.falling-hero h1 {
  color: #ff4a75;
  font-size: clamp(46px, 5vw, 68px);
  line-height: 0.94;
  text-shadow:
    0 3px 0 #ffffff,
    0 6px 0 #ffffff,
    0 9px 0 rgba(210, 58, 104, 0.68),
    0 12px 18px rgba(69, 112, 162, 0.16);
  -webkit-text-stroke: 0;
}

.falling-hero .hero__copy {
  background: transparent;
  border: 0;
  box-shadow: none;
  color: #263a5f;
  display: block;
  font-size: 15px;
  line-height: 1.5;
  margin-top: 8px;
  max-width: 480px;
  padding: 0;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.falling-hero .hero-back-link {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(244, 252, 255, 0.64)),
    linear-gradient(135deg, rgba(77, 205, 255, 0.28), rgba(255, 215, 90, 0.18));
  border: 2px solid rgba(255, 255, 255, 0.86);
  box-shadow:
    0 8px 16px rgba(65, 112, 156, 0.12),
    inset 0 2px 0 rgba(255, 255, 255, 0.76);
  margin-top: 14px;
}

.falling-hero .hero__badge {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px) saturate(1.2);
  border: 2px solid rgba(255, 255, 255, 0.94);
  box-shadow:
    0 14px 26px rgba(75, 124, 170, 0.16),
    inset 0 2px 0 rgba(255, 255, 255, 0.88);
}

.falling-game-panel,
.word-game-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 251, 240, 0.9));
  border: 2px solid rgba(255, 255, 255, 0.94);
  border-radius: 8px;
  box-shadow:
    0 18px 34px rgba(117, 113, 96, 0.12),
    inset 0 2px 0 rgba(255, 255, 255, 0.9);
}

.falling-toolbar {
  background: rgba(255, 255, 255, 0.46);
  border: 1px solid rgba(255, 226, 176, 0.7);
  border-radius: 8px;
  padding: 8px;
}

.mode-tabs,
.word-group-tabs {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 247, 226, 0.64));
  border-color: rgba(255, 224, 171, 0.74);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.82);
}

.mode-tab {
  border-radius: 8px;
  color: #20365d;
  font-weight: 900;
}

.mode-tab.is-active {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.38), transparent),
    linear-gradient(180deg, #ff7aa1, #f23776);
  border-color: rgba(255, 255, 255, 0.9);
  box-shadow:
    0 7px 12px rgba(231, 58, 112, 0.18),
    inset 0 2px 0 rgba(255, 255, 255, 0.58),
    inset 0 -4px 0 rgba(151, 41, 83, 0.16);
  color: #ffffff;
}

.falling-stats div,
.falling-side .score-strip div {
  background:
    linear-gradient(180deg, #ffffff, #f8fdff);
  border: 1px solid rgba(225, 235, 246, 0.96);
  box-shadow: 0 8px 16px rgba(64, 89, 132, 0.06);
}

.falling-stats strong,
.falling-side .score-strip strong {
  color: #17356a;
}

.quest-panel,
.word-target-card {
  background:
    linear-gradient(180deg, #fffdf8, #fff7df);
  border: 1px solid rgba(246, 210, 146, 0.9);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.75);
}

.quest-title {
  color: #f23776;
}

.candy-jar {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.36)),
    repeating-linear-gradient(90deg, rgba(255, 126, 166, 0.22) 0 18px, rgba(255, 224, 92, 0.24) 18px 36px, rgba(72, 200, 255, 0.22) 36px 54px),
    rgba(255, 255, 255, 0.48);
}

.falling-stage,
.word-stage {
  background:
    radial-gradient(circle at 12% 18%, rgba(255, 255, 255, 0.72) 0 24px, transparent 25px),
    radial-gradient(circle at 82% 20%, rgba(255, 255, 255, 0.62) 0 32px, transparent 33px),
    radial-gradient(circle at 28% 86%, rgba(255, 126, 166, 0.18) 0 42px, transparent 43px),
    radial-gradient(circle at 70% 88%, rgba(255, 224, 92, 0.2) 0 36px, transparent 37px),
    linear-gradient(180deg, #dff8ff 0%, #f2fdff 44%, #fff7df 100%);
  border: 2px solid rgba(162, 221, 255, 0.72);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.94),
    0 8px 18px rgba(71, 108, 150, 0.08);
}

.falling-stage::before,
.word-stage::before {
  background:
    radial-gradient(ellipse at 20% 72%, rgba(116, 223, 131, 0.34) 0 48px, transparent 49px),
    radial-gradient(ellipse at 78% 76%, rgba(255, 214, 109, 0.28) 0 58px, transparent 59px);
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.catch-line {
  background:
    linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9), transparent),
    repeating-linear-gradient(90deg, #ff7aa1 0 18px, #ffe25d 18px 36px, #4ecfff 36px 54px, #77dc87 54px 72px);
  box-shadow: 0 4px 10px rgba(88, 116, 145, 0.12);
}

.falling-letter,
.word-falling-letter {
  border-radius: 999px;
  box-shadow:
    inset 0 4px 8px rgba(255, 255, 255, 0.48),
    inset 0 -8px 12px rgba(145, 34, 86, 0.16),
    0 12px 18px rgba(118, 76, 138, 0.18);
}

.game-overlay {
  background:
    rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(12px) saturate(1.2);
}

.falling-keyboard-panel {
  background:
    linear-gradient(180deg, #ffffff, #fffaf2);
  border-color: rgba(255, 227, 190, 0.95);
}

.falling-side {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 248, 226, 0.68)),
    linear-gradient(135deg, rgba(255, 119, 164, 0.18), rgba(255, 219, 93, 0.28), rgba(105, 226, 197, 0.18));
  border: 0;
  box-shadow: none;
}

.falling-side .score-strip {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 250, 238, 0.86));
  border: 2px solid rgba(255, 255, 255, 0.94);
  border-radius: 8px;
  align-items: stretch;
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr;
  height: auto;
  min-height: 0;
  padding: 14px;
}

.falling-side .tips {
  background:
    radial-gradient(circle at 84% 18%, rgba(255, 216, 91, 0.18) 0 34px, transparent 35px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 250, 238, 0.86));
  border: 2px solid rgba(255, 255, 255, 0.94);
  border-radius: 8px;
  min-height: 0;
}

.falling-side .tips h2 {
  color: #f23776;
  font-size: 18px;
}

.falling-side .tips p {
  color: #34445f;
  font-weight: 800;
}

.word-target-card strong,
.word-letter-slots span {
  text-transform: uppercase;
}

.word-sound-button {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.32), transparent),
    linear-gradient(180deg, #57c9ff, #208fe9);
  border: 2px solid rgba(255, 255, 255, 0.82);
  box-shadow:
    0 8px 14px rgba(37, 137, 216, 0.18),
    inset 0 2px 0 rgba(255, 255, 255, 0.62);
  color: #ffffff;
}

@media (min-width: 981px) {
  .falling-shell,
  .word-shell {
    align-items: start;
    gap: 16px;
    grid-template-columns: minmax(760px, 1fr) 350px;
    height: auto;
    min-height: 100vh;
    overflow: visible;
    padding: 14px;
  }

  .falling-main,
  .word-main {
    gap: 10px;
    grid-template-rows: 220px auto auto;
  }

  .word-main {
    grid-template-rows: 220px auto;
  }

  .falling-hero {
    height: 220px;
    min-height: 0;
    padding: 20px 248px 16px 200px;
  }

  .falling-hero::before {
    background:
      radial-gradient(circle at 50% 28%, #3b2114 0 5px, transparent 6px),
      radial-gradient(circle at 66% 30%, #3b2114 0 5px, transparent 6px),
      radial-gradient(circle at 58% 54%, #fff3d5 0 19px, transparent 20px),
      radial-gradient(circle at 58% 60%, #3b2114 0 4px, transparent 5px),
      radial-gradient(circle at 30% 33%, #e19a55 0 20px, #9b541d 21px 27px, transparent 28px),
      radial-gradient(circle at 78% 29%, #e19a55 0 19px, #9b541d 20px 26px, transparent 27px),
      radial-gradient(circle at 57% 46%, #c87831 0 58px, #9b541d 59px 67px, transparent 68px),
      linear-gradient(180deg, transparent 0 72%, rgba(255, 211, 113, 0.38) 73% 100%);
    border-radius: 0;
    height: auto;
    left: 0;
    opacity: 1;
    right: auto;
    width: 220px;
  }

  .falling-hero .hero__badge {
    bottom: auto;
    min-width: 210px;
    padding: 16px;
    right: 20px;
    top: 34px;
  }

  .falling-game-panel {
    grid-template-rows: auto auto auto minmax(260px, 1fr);
    padding: 14px 18px 16px;
  }

  .word-game-panel {
    grid-template-rows: auto auto auto minmax(260px, 1fr) auto;
    padding: 14px 18px 16px;
  }

  .falling-stage {
    min-height: 260px;
  }

  .word-stage {
    min-height: 270px;
  }

  .falling-keyboard-panel {
    min-height: 170px;
    padding: 12px;
  }

  .falling-keyboard-panel .keyboard {
    gap: 8px;
  }

  .falling-keyboard-panel .key {
    height: 38px;
    min-width: 44px;
  }

  .falling-side {
    align-content: start;
    display: grid;
    gap: 12px;
    grid-template-rows: auto auto auto;
    max-height: none;
    min-height: calc(100vh - 28px);
    overflow: visible;
    position: sticky;
    top: 14px;
  }

  .falling-side .score-strip div {
    justify-content: start;
  }
}

@media (max-width: 980px) {
  .falling-shell,
  .word-shell {
    padding: 10px;
  }

  .falling-side {
    min-height: 0;
    position: static;
  }

  .falling-side .score-strip {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .falling-hero {
    min-height: 360px;
    padding: 24px;
  }

  .falling-hero > div:first-child {
    max-width: 100%;
  }

  .falling-hero h1 {
    font-size: clamp(40px, 15vw, 58px);
    white-space: normal;
  }

  .falling-hero .hero__badge {
    bottom: 18px;
    left: 24px;
    right: 24px;
    top: auto;
  }

  .word-group-tabs {
    max-height: 126px;
  }

  .falling-stats {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 980px) {
  .hero__badge-title,
  .hero__metric,
  .hero__badge-progress {
    position: relative;
    z-index: 1;
  }

  .hero__badge {
    gap: 10px;
  }

  .hero__badge::before,
  .hero__badge::after {
    content: none;
  }
}

@media (max-width: 680px) {
  .hero__badge {
    grid-template-columns: 1fr 1fr;
    padding-bottom: 18px;
  }

  .hero__badge-title,
  .hero__badge-progress {
    grid-column: 1 / -1;
  }

  .hero__metric {
    background: rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    align-items: center;
    display: grid;
    grid-template-columns: auto 1fr;
    min-height: 72px;
    padding: 10px;
  }

  .hero__metric--accuracy {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .hero__metric strong {
    color: #19315d;
    font-size: 28px;
  }

  .hero__metric em,
  .hero__metric span,
  .hero__badge-title,
  .hero__badge-progress span,
  .hero__badge-progress strong {
    color: #52637e;
    font-size: 12px;
    font-style: normal;
    font-weight: 900;
  }

  .hero__badge-bar {
    background: #e7edf4;
    border-radius: 999px;
    height: 9px;
    overflow: hidden;
  }

  .hero__badge-bar i {
    background: linear-gradient(90deg, #20c7ff, #39dba1);
    display: block;
    height: 100%;
    transform-origin: left center;
    width: 100%;
  }
}

@media (min-width: 981px) {
  .score-strip {
    height: 40px;
    min-height: 40px;
  }

  .score-strip div {
    min-height: 40px;
  }

  .score-strip div::before {
    height: 34px;
    width: 34px;
  }
}

@media (max-width: 680px) {
  .hero {
    min-height: 620px;
  }

  .hero > div:first-child {
    z-index: 6;
  }

  .hero__badge {
    bottom: 18px;
    height: auto;
    top: auto;
    z-index: 4;
  }

  .hero__badge span,
  .hero__badge strong {
    background: transparent;
    border-radius: 0;
    display: inline;
    min-height: 0;
    place-items: initial;
  }

  .hero__badge .visually-hidden {
    display: block;
    min-height: 1px;
  }

  .hero-actions {
    z-index: 7;
  }
}

/* /type/ upload polish: soft finished children's game interface. */
body.type-polish-ready,
body {
  background:
    radial-gradient(circle at 7% 10%, rgba(255, 255, 255, 0.95) 0 18px, transparent 19px),
    radial-gradient(circle at 12% 8%, rgba(255, 255, 255, 0.82) 0 30px, transparent 31px),
    radial-gradient(circle at 92% 14%, rgba(255, 255, 255, 0.86) 0 34px, transparent 35px),
    radial-gradient(circle at 5% 88%, rgba(255, 161, 190, 0.28) 0 130px, transparent 132px),
    linear-gradient(180deg, #ecf9ff 0%, #e3f8ff 34%, #fff8e8 70%, #fff3d7 100%);
}

body::before {
  background:
    linear-gradient(180deg, transparent 0 74%, rgba(255, 218, 125, 0.28) 74% 100%),
    radial-gradient(circle at 94% 92%, rgba(113, 213, 100, 0.28) 0 34px, transparent 35px),
    radial-gradient(circle at 97% 91%, rgba(80, 185, 83, 0.22) 0 24px, transparent 25px);
  opacity: 1;
}

body::after {
  background:
    radial-gradient(circle at 4% 31%, rgba(255, 128, 170, 0.2) 0 20px, transparent 21px),
    radial-gradient(circle at 8% 34%, rgba(255, 216, 86, 0.22) 0 16px, transparent 17px),
    radial-gradient(circle at 88% 78%, rgba(67, 200, 255, 0.16) 0 36px, transparent 37px);
  opacity: 1;
}

@media (min-width: 981px) {
  .app-shell {
    background: rgba(255, 255, 255, 0.18);
    gap: 16px;
    grid-template-columns: minmax(760px, 1fr) 350px;
    height: 100vh;
    min-height: 720px;
    overflow: hidden;
    padding: 14px;
  }

  .lesson-area {
    gap: 12px;
    grid-template-rows: 230px minmax(0, 1fr);
  }

  .hero {
    background:
      radial-gradient(circle at 10% 16%, rgba(255, 255, 255, 0.9) 0 22px, transparent 23px),
      radial-gradient(circle at 16% 13%, rgba(255, 255, 255, 0.82) 0 35px, transparent 36px),
      radial-gradient(circle at 86% 76%, rgba(255, 155, 190, 0.22) 0 42px, transparent 43px),
      radial-gradient(circle at 92% 72%, rgba(255, 218, 86, 0.24) 0 28px, transparent 29px),
      linear-gradient(180deg, #bcefff 0%, #dff8ff 58%, #fff1c7 59%, #ffe7af 100%);
    border: 2px solid rgba(255, 255, 255, 0.92);
    border-radius: 8px;
    box-shadow:
      0 18px 38px rgba(79, 123, 170, 0.18),
      inset 0 2px 0 rgba(255, 255, 255, 0.86);
    height: 230px;
    overflow: hidden;
    padding: 22px 248px 18px 220px;
  }

  .hero::before {
    background:
      radial-gradient(circle at 9% 92%, #ffb6d0 0 18px, transparent 19px),
      radial-gradient(circle at 13% 89%, #ffe36c 0 15px, transparent 16px),
      radial-gradient(circle at 17% 94%, #74df83 0 19px, transparent 20px),
      linear-gradient(180deg, transparent 0 72%, rgba(255, 211, 113, 0.35) 73% 100%);
  }

  .hero > div:first-child {
    align-items: center;
    display: grid;
    justify-items: center;
    max-width: 560px;
    min-width: 0;
    text-align: center;
    z-index: 7;
  }

  .eyebrow {
    color: #2c8cbd;
    font-size: 11px;
    letter-spacing: 0.08em;
  }

  .hero h1 {
    color: #ff4a75;
    font-size: clamp(48px, 5.1vw, 70px);
    line-height: 0.92;
    margin-top: 6px;
    text-shadow:
      0 3px 0 #ffffff,
      0 6px 0 #ffffff,
      0 9px 0 rgba(210, 58, 104, 0.72),
      0 12px 18px rgba(69, 112, 162, 0.18);
  }

  .hero h1::first-letter {
    color: #ff557e;
  }

  .hero h1::before {
    content: none;
  }

  .hero__copy {
    background: transparent;
    border: 0;
    box-shadow: none;
    color: #263a5f;
    display: block;
    font-size: 15px;
    font-weight: 800;
    line-height: 1.55;
    margin-top: 6px;
    max-width: 420px;
    padding: 0;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
  }

  .hero-actions {
    gap: 14px;
    justify-content: center;
    margin-top: 18px;
  }

  .hero-action {
    border: 3px solid rgba(255, 255, 255, 0.82);
    border-radius: 999px;
    box-shadow:
      0 12px 20px rgba(224, 72, 126, 0.22),
      inset 0 2px 0 rgba(255, 255, 255, 0.62),
      inset 0 -5px 0 rgba(171, 42, 83, 0.2);
    font-size: 19px;
    min-height: 54px;
    min-width: 166px;
  }

  .hero-action:nth-child(2) {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.32), transparent),
      linear-gradient(180deg, #57c9ff, #208fe9);
    box-shadow:
      0 12px 20px rgba(37, 137, 216, 0.2),
      inset 0 2px 0 rgba(255, 255, 255, 0.66),
      inset 0 -5px 0 rgba(20, 103, 178, 0.22);
  }

  .hero-action:nth-child(3) {
    display: inline-flex;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.32), transparent),
      linear-gradient(180deg, #73df90, #29b95f);
    color: #ffffff;
  }

  .mini-game-links {
    display: none;
  }

  .hero__scene {
    bottom: 12px;
    height: 208px;
    left: 28px;
    right: auto;
    transform: none;
    width: 236px;
    z-index: 4;
  }

  .hero__bear,
  .hero__bear::before,
  .hero__bear::after {
    position: absolute;
  }

  .hero__bear {
    background:
      radial-gradient(circle at 36% 36%, #3b2114 0 5px, transparent 6px),
      radial-gradient(circle at 64% 36%, #3b2114 0 5px, transparent 6px),
      radial-gradient(circle at 50% 58%, #fff3d5 0 20px, transparent 21px),
      radial-gradient(circle at 50% 64%, #3b2114 0 5px, transparent 6px),
      radial-gradient(circle, #c87831 0 68%, #9b541d 100%);
    border: 4px solid rgba(255, 255, 255, 0.78);
    border-radius: 52% 48% 46% 54%;
    box-shadow: 0 14px 22px rgba(126, 78, 39, 0.18);
    height: 108px;
    left: 58px;
    top: 30px;
    width: 116px;
    z-index: 3;
  }

  .hero__bear::before {
    background:
      radial-gradient(circle at 50% 50%, #e19a55 0 42%, #9b541d 43% 100%);
    border: 3px solid rgba(255, 255, 255, 0.7);
    border-radius: 999px;
    box-shadow: 82px 3px 0 -1px #b86d2d;
    content: "";
    height: 38px;
    left: -12px;
    top: -12px;
    width: 38px;
  }

  .hero__bear::after {
    background:
      linear-gradient(180deg, #fff4df, #ffd796);
    border: 3px solid #ffffff;
    border-radius: 0 0 18px 18px;
    box-shadow:
      0 42px 0 -6px #f8f4ee,
      34px 42px 0 -6px #f8f4ee,
      68px 42px 0 -6px #f8f4ee,
      102px 42px 0 -6px #f8f4ee;
    content: "";
    height: 36px;
    left: -18px;
    top: 98px;
    width: 152px;
  }

  .hero__island {
    background:
      radial-gradient(circle at 40% 22%, #ff7ead 0 18px, transparent 19px),
      radial-gradient(circle at 58% 12%, #ffe36c 0 15px, transparent 16px),
      linear-gradient(180deg, #ffe19a 0 52%, #7ddd6b 53% 75%, #d89142 76% 100%);
    bottom: 0;
    border-width: 4px;
    height: 58px;
    left: 12px;
    top: auto;
    width: 196px;
    z-index: 1;
  }

  .hero__boat,
  .hero__candy {
    display: none;
  }

  .hero__badge {
    background: rgba(255, 255, 255, 0.86);
    backdrop-filter: blur(14px) saturate(1.2);
    border: 2px solid rgba(255, 255, 255, 0.92);
    bottom: auto;
    box-shadow:
      0 16px 28px rgba(75, 124, 170, 0.16),
      inset 0 2px 0 rgba(255, 255, 255, 0.86);
    min-width: 210px;
    padding: 12px;
    right: 20px;
    top: 28px;
  }

  .hero__metric {
    background: #ffffff;
    border: 1px solid rgba(230, 236, 244, 0.96);
    box-shadow: 0 6px 12px rgba(64, 89, 132, 0.06);
  }

  .practice-panel {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 251, 240, 0.92));
    border: 2px solid rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    box-shadow:
      0 18px 34px rgba(117, 113, 96, 0.12),
      inset 0 2px 0 rgba(255, 255, 255, 0.9);
    padding: 16px 18px 12px;
  }

  .practice-panel::before {
    background: linear-gradient(90deg, #ff5d8a, #ffcf5f, #67d66f, #40c7ff, #8d70ff);
    height: 6px;
  }

  .level-meta {
    align-items: center;
  }

  .level-meta h2 {
    color: #1f3157;
    font-size: 21px;
  }

  .level-meta p {
    color: #52637e;
    font-weight: 800;
  }

  .star-goals {
    background: #fffdf8;
    border: 1px solid rgba(246, 210, 146, 0.9);
    border-radius: 8px;
    overflow: hidden;
  }

  .star-goals li {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.72), transparent),
      linear-gradient(180deg, #fff5c2, #ffe179);
  }

  .prompt-text {
    background:
      linear-gradient(180deg, #ffffff, #fffefa);
    border-color: rgba(162, 221, 255, 0.72);
    border-radius: 8px;
    box-shadow:
      inset 0 2px 0 rgba(255, 255, 255, 0.94),
      0 8px 18px rgba(71, 108, 150, 0.08);
  }

  .prompt-char.is-current {
    animation: candyPulse 1.15s ease-in-out infinite;
  }

  .current-target {
    background:
      radial-gradient(circle at 50% 45%, #ffffff 0 42%, #ffe8ef 43% 100%);
    border-color: rgba(255, 255, 255, 0.96);
  }

  .keyboard-panel {
    background:
      linear-gradient(180deg, #ffffff, #fffaf2);
    border-color: rgba(255, 227, 190, 0.95);
    box-shadow:
      inset 0 2px 0 #ffffff,
      0 10px 22px rgba(95, 90, 78, 0.09);
  }

  .key {
    border-radius: 8px;
    box-shadow:
      inset 0 2px 0 rgba(255, 255, 255, 0.85),
      inset 0 -4px 0 rgba(191, 126, 42, 0.16),
      0 3px 7px rgba(100, 82, 62, 0.12);
  }

  .key.is-target {
    animation: keyGlow 1.05s ease-in-out infinite;
  }

  .side-panel {
    gap: 12px;
    grid-template-rows: minmax(0, 1fr) 142px 98px;
  }

  .map-card {
    background:
      radial-gradient(circle at 16% 18%, rgba(255, 255, 255, 0.88) 0 22px, transparent 23px),
      radial-gradient(circle at 72% 12%, rgba(255, 255, 255, 0.8) 0 28px, transparent 29px),
      linear-gradient(180deg, #bff1ff 0 34%, #92e59b 35% 67%, #fff1c4 68% 100%);
    overflow: hidden;
    position: relative;
  }

  .map-card::before {
    background:
      radial-gradient(ellipse at 50% 50%, rgba(102, 198, 92, 0.45) 0 55%, transparent 56%),
      radial-gradient(circle at 80% 28%, #ff9fc4 0 11px, transparent 12px),
      radial-gradient(circle at 22% 72%, #ffe05e 0 9px, transparent 10px);
    content: "";
    inset: 62px 18px 18px;
    pointer-events: none;
    position: absolute;
  }

  .level-map {
    padding-top: 24px;
  }

  .level-map::before {
    background:
      repeating-linear-gradient(32deg, transparent 0 34px, rgba(255, 255, 255, 0.88) 34px 43px, transparent 43px 72px);
    border-radius: 999px;
    filter: drop-shadow(0 5px 0 rgba(138, 115, 55, 0.08));
    inset: 70px 34px 44px;
    opacity: 0.85;
  }

  .level-button {
    border: 3px solid rgba(255, 255, 255, 0.88);
    box-shadow:
      inset 0 4px 8px rgba(255, 255, 255, 0.5),
      inset 0 -8px 10px rgba(110, 35, 77, 0.2),
      0 9px 14px rgba(67, 91, 124, 0.16);
  }

  .level-button.is-current {
    box-shadow:
      0 0 0 5px rgba(255, 230, 93, 0.75),
      inset 0 4px 8px rgba(255, 255, 255, 0.5),
      inset 0 -8px 10px rgba(110, 35, 77, 0.2),
      0 10px 18px rgba(255, 181, 42, 0.28);
  }

  .tips {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(255, 255, 255, 0.95);
  }
}

@keyframes candyPulse {
  0%, 100% {
    box-shadow:
      0 0 0 4px rgba(255, 235, 142, 0.65),
      inset 0 -4px 0 rgba(255, 210, 90, 0.22);
    transform: translateY(0);
  }
  50% {
    box-shadow:
      0 0 0 7px rgba(255, 211, 83, 0.3),
      0 7px 14px rgba(255, 164, 46, 0.22),
      inset 0 -4px 0 rgba(255, 210, 90, 0.22);
    transform: translateY(-1px);
  }
}

@keyframes keyGlow {
  0%, 100% {
    box-shadow:
      inset 0 2px 0 rgba(255, 255, 255, 0.8),
      inset 0 -4px 0 rgba(67, 138, 42, 0.16),
      0 5px 10px rgba(84, 183, 52, 0.18);
  }
  50% {
    box-shadow:
      inset 0 2px 0 rgba(255, 255, 255, 0.8),
      inset 0 -4px 0 rgba(67, 138, 42, 0.16),
      0 0 0 5px rgba(136, 235, 83, 0.26),
      0 8px 16px rgba(84, 183, 52, 0.25);
  }
}

/* Keep the candy dashboard polished on shorter laptop viewports. */
@media (min-width: 981px) {
  body {
    overflow-x: hidden;
    overflow-y: auto;
  }

  .app-shell {
    align-items: start;
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }

  .lesson-area {
    gap: 10px;
    grid-template-rows: 220px auto;
  }

  .hero {
    height: 220px;
    padding-bottom: 14px;
    padding-top: 18px;
  }

  .practice-panel {
    min-height: 0;
    padding-bottom: 10px;
    padding-top: 14px;
  }

  .prompt-text {
    min-height: 60px;
  }

  .keyboard-panel {
    padding-bottom: 9px;
    padding-top: 9px;
  }

  .side-panel {
    max-height: none;
    min-height: calc(100vh - 28px);
    overflow: visible;
    position: sticky;
    top: 14px;
  }
}

/* Final mini-game overrides must follow the shared dashboard rules above. */
@media (min-width: 981px) {
  .falling-side {
    align-content: start;
    display: grid;
    gap: 12px;
    grid-template-rows: auto auto auto;
  }

  .falling-side > .score-strip {
    align-items: stretch;
    align-self: start;
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr;
    grid-template-rows: repeat(3, 58px);
    height: auto;
    min-height: 0;
  }

  .falling-side > .score-strip div {
    min-height: 58px;
  }
}

@media (max-width: 680px) {
  .falling-hero {
    height: auto;
    min-height: 430px;
  }

  .falling-hero .hero__badge {
    bottom: 18px;
    left: 24px;
    right: 24px;
    top: auto;
  }
}

/* Expose the two mini games from the main island without competing with the main quest. */
.hero .mini-game-links {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 10px;
  position: relative;
  z-index: 8;
}

.hero .mini-game-link {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 250, 235, 0.62)),
    linear-gradient(135deg, rgba(255, 125, 174, 0.28), rgba(255, 224, 92, 0.24), rgba(76, 207, 255, 0.24));
  border: 2px solid rgba(255, 255, 255, 0.88);
  border-radius: 999px;
  box-shadow:
    0 8px 14px rgba(68, 105, 148, 0.12),
    inset 0 2px 0 rgba(255, 255, 255, 0.7);
  color: #24406d;
  font-size: 14px;
  font-weight: 900;
  min-height: 34px;
  padding: 0 14px;
  text-shadow: none;
}

.hero .mini-game-link::before {
  align-items: center;
  background: #ffffff;
  border-radius: 999px;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.06);
  content: "A";
  display: inline-grid;
  font-size: 12px;
  height: 22px;
  margin-right: 7px;
  place-items: center;
  width: 22px;
}

.hero .mini-game-link--words::before {
  content: "W";
}

@media (min-width: 981px) {
  .hero .hero-actions {
    gap: 10px;
    margin-top: 10px;
  }

  .hero .hero-action {
    font-size: 17px;
    min-height: 46px;
  }

  .lesson-area {
    grid-template-rows: 270px auto;
  }

  .hero {
    height: 270px;
  }

  .hero > div:first-child {
    align-content: center;
    align-self: center;
  }

  .hero h1 {
    font-size: clamp(42px, 4.4vw, 62px);
  }

  .hero .mini-game-links {
    margin-top: 2px;
  }
}

@media (max-width: 680px) {
  .hero .mini-game-links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
  }

  .hero .mini-game-link {
    justify-content: center;
    min-width: 0;
  }
}

/* Map state colors: unfinished stays pearl-gray; completed levels become candy-colored. */
.map-card .level-map .level-button {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.92) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffffff, #d9dde4) !important;
  border-color: rgba(255, 255, 255, 0.9);
  box-shadow:
    inset 0 4px 8px rgba(255, 255, 255, 0.64),
    inset 0 -8px 12px rgba(98, 112, 132, 0.12),
    0 8px 13px rgba(67, 91, 124, 0.12);
  color: #4c596b;
  filter: saturate(0.55);
}

.map-card .level-map .level-button em {
  color: #c4cad4;
  text-shadow: 0 1px 0 #ffffff;
}

.map-card .level-map .level-button.is-current:not(.is-complete) {
  box-shadow:
    0 0 0 5px rgba(255, 230, 93, 0.72),
    inset 0 4px 8px rgba(255, 255, 255, 0.64),
    inset 0 -8px 12px rgba(98, 112, 132, 0.12),
    0 10px 18px rgba(255, 181, 42, 0.22);
  color: #26364f;
  filter: saturate(0.72);
}

.map-card .level-map .level-button.is-locked {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.88) 0 18%, transparent 20%),
    linear-gradient(180deg, #f7f8fa, #c9ced6) !important;
  color: #626a76;
  filter: grayscale(1) saturate(0.25);
  opacity: 0.9;
}

.map-card .level-map .level-button.is-complete {
  filter: none;
  opacity: 1;
}

.map-card .level-map .level-button.is-complete em {
  color: #fff453;
  text-shadow: 0 1px 0 rgba(123, 67, 0, 0.28);
}

.map-card .level-map .level-button.is-complete:nth-child(4n + 1) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #ff789d, #f43977) !important;
  color: #ffffff;
}

.map-card .level-map .level-button.is-complete:nth-child(4n + 2) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffb342, #ff7e1f) !important;
  color: #ffffff;
}

.map-card .level-map .level-button.is-complete:nth-child(4n + 3) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.82) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffe86c, #ffc531) !important;
  color: #7f4c00;
}

.map-card .level-map .level-button.is-complete:nth-child(4n) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.8) 0 18%, transparent 20%),
    linear-gradient(180deg, #9cff68, #4ecb42) !important;
  color: #ffffff;
}

.map-card .level-map .level-button.is-current.is-complete {
  box-shadow:
    0 0 0 5px rgba(255, 230, 93, 0.75),
    inset 0 4px 8px rgba(255, 255, 255, 0.5),
    inset 0 -8px 10px rgba(110, 35, 77, 0.2),
    0 10px 18px rgba(255, 181, 42, 0.28);
}

/* Compact hero pass: calmer, shorter, and easier to scan. */
@media (min-width: 981px) {
  .lesson-area {
    grid-template-rows: 208px auto;
  }

  .hero {
    height: 208px;
    padding: 14px 226px 12px 174px;
  }

  .hero > div:first-child {
    align-content: center;
    justify-items: center;
    max-width: 440px;
    min-width: 0;
    text-align: center;
  }

  .eyebrow {
    font-size: 10px;
    letter-spacing: 0.08em;
  }

  .hero h1 {
    font-size: clamp(38px, 4vw, 54px);
    line-height: 0.98;
    margin-top: 2px;
    text-shadow:
      0 2px 0 #ffffff,
      0 4px 0 rgba(255, 255, 255, 0.9),
      0 7px 0 rgba(210, 58, 104, 0.56),
      0 10px 14px rgba(69, 112, 162, 0.14);
  }

  .hero__copy {
    font-size: 14px;
    line-height: 1.35;
    margin-top: 5px;
    max-width: 380px;
  }

  .hero .hero-actions {
    gap: 10px;
    margin-top: 9px;
  }

  .hero .hero-action {
    border-width: 2px;
    font-size: 16px;
    min-height: 42px;
    min-width: 142px;
    padding: 0 18px;
  }

  .hero-action::before {
    height: 28px;
    margin-right: 8px;
    width: 28px;
  }

  .hero .mini-game-links {
    gap: 8px;
    margin-top: 7px;
  }

  .hero .mini-game-link {
    font-size: 13px;
    min-height: 30px;
    padding: 0 12px;
  }

  .hero .mini-game-link::before {
    height: 20px;
    margin-right: 6px;
    width: 20px;
  }

  .hero__scene {
    bottom: 8px;
    height: 184px;
    left: 18px;
    width: 206px;
  }

  .hero__bear {
    height: 88px;
    left: 52px;
    top: 24px;
    width: 96px;
  }

  .hero__bear::before {
    box-shadow: 68px 3px 0 -1px #b86d2d;
    height: 32px;
    width: 32px;
  }

  .hero__bear::after {
    height: 30px;
    left: -15px;
    top: 82px;
    width: 128px;
  }

  .hero__island {
    height: 48px;
    width: 168px;
  }

  .hero__badge {
    min-width: 188px;
    padding: 10px;
    right: 16px;
    top: 22px;
  }

  .hero__badge-title {
    font-size: 13px;
  }

  .hero__metric {
    min-height: 58px;
    padding: 8px;
  }

  .hero__metric strong {
    font-size: 25px;
  }

  .hero__metric em,
  .hero__metric span,
  .hero__badge-progress span,
  .hero__badge-progress strong {
    font-size: 11px;
  }

  .practice-panel {
    padding-top: 14px;
  }
}

@media (max-width: 680px) {
  .app-shell .hero {
    min-height: 490px;
    padding: 22px;
  }

  .app-shell .hero h1 {
    font-size: clamp(38px, 14vw, 56px);
    line-height: 1;
  }

  .app-shell .hero__copy {
    font-size: 14px;
    line-height: 1.45;
  }

  .app-shell .hero-actions {
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr 1fr;
    margin-top: 12px;
  }

  .app-shell .hero-action {
    font-size: 15px;
    min-height: 46px;
    min-width: 0;
    padding: 0 10px;
  }

  .app-shell .hero-action::before {
    height: 26px;
    margin-right: 6px;
    width: 26px;
  }

  .app-shell .mini-game-links {
    margin-top: 4px;
  }

  .app-shell .hero__scene {
    bottom: 112px;
    opacity: 0.78;
    transform: scale(0.48);
  }

  .app-shell .hero__badge {
    bottom: 16px;
    left: 22px;
    right: 22px;
  }
}

/* Cohesive soft-candy palette pass: calmer sky, cream cards, and softer rewards. */
:root {
  --bg: #fff8ec;
  --surface: rgba(255, 255, 255, 0.76);
  --surface-strong: rgba(255, 255, 255, 0.94);
  --ink: #26324d;
  --muted: #61708a;
  --line: rgba(214, 228, 239, 0.86);
  --strawberry: #ff6d8b;
  --peach: #ffb16a;
  --lemon: #ffd76c;
  --mint: #78d79e;
  --sky: #56bce8;
  --grape: #a69ae6;
  --berry: #d94e73;
  --teal: #247f8f;
  --gold: #8b651d;
  --wrong: #d94e73;
  --correct: #278a67;
  --glass-edge: rgba(255, 255, 255, 0.9);
  --glass-line: rgba(67, 104, 136, 0.12);
  --glass-shine: rgba(255, 255, 255, 0.78);
  --shadow: rgba(71, 96, 128, 0.14);
  --candy-shadow: rgba(217, 78, 115, 0.15);
  --sky-shadow: rgba(86, 188, 232, 0.16);
}

body {
  background:
    radial-gradient(circle at 12% 9%, rgba(255, 255, 255, 0.86) 0 42px, transparent 43px),
    radial-gradient(circle at 88% 12%, rgba(255, 255, 255, 0.72) 0 54px, transparent 55px),
    linear-gradient(180deg, #d8f4ff 0%, #eefaff 31%, #fff8ec 68%, #fff2d7 100%);
  color: var(--ink);
}

body::before {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.3), transparent 42%),
    radial-gradient(ellipse at 23% 18%, rgba(255, 255, 255, 0.58) 0 8%, transparent 9%),
    radial-gradient(ellipse at 76% 22%, rgba(255, 255, 255, 0.44) 0 9%, transparent 10%);
  opacity: 0.82;
}

body::after {
  background:
    linear-gradient(90deg, rgba(255, 244, 215, 0.54), transparent 24% 76%, rgba(215, 244, 255, 0.48)),
    repeating-linear-gradient(90deg, transparent 0 88px, rgba(255, 255, 255, 0.22) 88px 90px, transparent 90px 176px);
  opacity: 0.28;
}

button {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 250, 242, 0.78)),
    var(--surface-strong);
  border-color: rgba(204, 222, 234, 0.9);
  box-shadow:
    0 10px 22px rgba(71, 96, 128, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

button:hover:not(:disabled) {
  border-color: rgba(255, 109, 139, 0.42);
  box-shadow:
    0 14px 28px rgba(71, 96, 128, 0.14),
    0 9px 18px rgba(255, 109, 139, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.hero,
.practice-panel,
.keyboard-panel,
.side-panel,
.falling-game-panel,
.word-game-panel {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.88), rgba(255, 251, 244, 0.66)),
    linear-gradient(180deg, rgba(216, 244, 255, 0.34), rgba(255, 244, 219, 0.3));
  border-color: rgba(255, 255, 255, 0.94);
  box-shadow:
    0 20px 44px rgba(71, 96, 128, 0.14),
    0 8px 18px rgba(255, 177, 106, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(67, 104, 136, 0.08);
}

.hero {
  background:
    linear-gradient(110deg, rgba(255, 255, 255, 0.76), transparent 42%),
    linear-gradient(180deg, #c9f0ff 0%, #e9fbff 46%, #fff2cf 100%);
}

.hero::before,
.falling-hero::before {
  background:
    radial-gradient(ellipse at 18% 18%, rgba(255, 255, 255, 0.7) 0 9%, transparent 10%),
    radial-gradient(ellipse at 78% 28%, rgba(255, 255, 255, 0.58) 0 12%, transparent 13%),
    linear-gradient(90deg, rgba(255, 214, 108, 0.18), rgba(86, 188, 232, 0.18));
  opacity: 0.78;
}

.hero::after,
.falling-hero::after {
  background: linear-gradient(90deg, #ff8aa0, #ffc17c, #ffe088, #95ddb0, #74c8eb);
  height: 4px;
  opacity: 0.86;
}

.eyebrow {
  color: #b94a68;
}

h1,
.falling-hero h1 {
  color: #ff6d8b;
  text-shadow:
    0 2px 0 #ffffff,
    0 5px 0 rgba(255, 255, 255, 0.82),
    0 8px 12px rgba(185, 74, 104, 0.18);
}

.hero__copy,
.falling-hero .hero__copy {
  color: #394967;
}

.hero__badge,
.map-card,
.today-card,
.mistake-card,
.tips,
.falling-side .tips,
.falling-stats div,
.falling-side .score-strip div,
.word-target-card,
.word-letter-slots span,
.word-input-box,
.stat-card,
.continue-card,
.sticker-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 250, 241, 0.86));
  border-color: rgba(217, 231, 240, 0.9);
  box-shadow:
    0 12px 26px rgba(71, 96, 128, 0.11),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.hero__metric {
  background: rgba(255, 255, 255, 0.72);
  border-color: rgba(217, 231, 240, 0.86);
}

.hero-action,
.primary-button,
.result-actions .primary-button {
  background:
    linear-gradient(180deg, #ff86a0, #ff5f80);
  border-color: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 13px 22px rgba(217, 78, 115, 0.2),
    inset 0 2px 0 rgba(255, 255, 255, 0.52),
    inset 0 -3px 0 rgba(173, 45, 83, 0.2);
  color: #ffffff;
}

.hero-action:nth-child(2),
.secondary-button,
.page-link.hero-link-secondary {
  background:
    linear-gradient(180deg, #75cef2, #43aee0);
  border-color: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 13px 22px rgba(67, 174, 224, 0.2),
    inset 0 2px 0 rgba(255, 255, 255, 0.54),
    inset 0 -3px 0 rgba(45, 126, 171, 0.18);
  color: #ffffff;
}

.hero-action:nth-child(3),
.mini-game-link,
.ghost-button,
.stacked-link {
  background:
    linear-gradient(180deg, #ffffff, #f3fbff);
  border-color: rgba(194, 220, 235, 0.92);
  box-shadow:
    0 9px 18px rgba(71, 96, 128, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: #2a5b7e;
}

.hero__scene {
  opacity: 0.94;
}

.hero__island {
  background:
    radial-gradient(circle at 28% 24%, #9ee1ad 0 13px, transparent 14px),
    radial-gradient(circle at 70% 15%, #ffca80 0 11px, transparent 12px),
    linear-gradient(180deg, #94dca5, #55b878 56%, #ffd59b 57% 100%);
  box-shadow: 0 20px 24px rgba(71, 96, 128, 0.14);
}

.hero__bear {
  filter: saturate(0.9) brightness(1.04);
}

.practice-panel::before,
.keyboard-panel::before,
.falling-game-panel::before,
.word-game-panel::before {
  background: linear-gradient(90deg, #ff86a0, #ffd76c, #78d79e, #56bce8);
  opacity: 0.9;
}

.level-pill,
.section-head h2::before,
.today-card .section-head h2::before,
.map-card .section-head h2::before {
  background:
    linear-gradient(180deg, #ff8aa0, #ff6484);
  box-shadow: 0 8px 15px rgba(217, 78, 115, 0.18);
  color: #ffffff;
}

.star-goals {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(255, 250, 239, 0.72));
  border-color: rgba(236, 210, 152, 0.55);
}

.star-goals li {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 248, 224, 0.76));
  border-color: rgba(239, 213, 158, 0.62);
  color: #46566f;
}

.star-goals li.is-done {
  background:
    linear-gradient(180deg, #fff1b7, #ffd86b);
  border-color: rgba(255, 193, 94, 0.72);
  color: #7a5319;
}

.prompt-stream {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 253, 255, 0.84));
  border-color: rgba(208, 226, 238, 0.92);
  box-shadow:
    0 14px 26px rgba(71, 96, 128, 0.11),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.prompt-char {
  color: #26324d;
}

.prompt-char.is-current {
  background:
    linear-gradient(180deg, #ffffff, #fff1c9);
  border-color: rgba(255, 193, 94, 0.92);
  box-shadow:
    0 0 0 4px rgba(255, 216, 108, 0.26),
    0 10px 20px rgba(255, 177, 106, 0.18);
  color: #d94e73;
}

.prompt-char.is-done {
  color: rgba(94, 112, 136, 0.38);
}

.prompt-char.is-wrong {
  background:
    linear-gradient(180deg, #ffe4ea, #ffc4d0);
  color: #be3e61;
}

.next-key-bubble {
  background:
    linear-gradient(180deg, #ffffff, #fff3dc);
  border-color: rgba(239, 213, 158, 0.72);
  box-shadow:
    0 13px 24px rgba(71, 96, 128, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.next-key-bubble strong {
  color: #d94e73;
}

.keyboard {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 247, 231, 0.76));
  border-color: rgba(207, 226, 239, 0.94);
}

.key {
  background:
    linear-gradient(180deg, #ffffff, #fff1d0);
  border-color: rgba(234, 204, 142, 0.74);
  box-shadow:
    0 5px 0 rgba(226, 187, 114, 0.42),
    0 9px 14px rgba(71, 96, 128, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  color: #8d4d27;
}

.key.hand-left {
  background:
    linear-gradient(180deg, #ffffff, #ffe3ec);
  border-color: rgba(239, 173, 195, 0.75);
}

.key.hand-right {
  background:
    linear-gradient(180deg, #ffffff, #e5f6ff);
  border-color: rgba(170, 214, 235, 0.76);
}

.key.is-home {
  background:
    linear-gradient(180deg, #efffdd, #b9eb75);
  border-color: rgba(116, 190, 82, 0.68);
  color: #2c7047;
}

.key.is-target {
  background:
    linear-gradient(180deg, #fffbe5, #ffd86b) !important;
  border-color: rgba(255, 193, 94, 0.86) !important;
  box-shadow:
    0 0 0 4px rgba(255, 216, 108, 0.24),
    0 6px 0 rgba(221, 165, 63, 0.52),
    0 12px 20px rgba(255, 177, 106, 0.16) !important;
  color: #85591a !important;
}

.key.is-home.is-target {
  background:
    linear-gradient(180deg, #fffbe5, #ffd86b) !important;
  border-color: rgba(255, 193, 94, 0.86) !important;
  color: #85591a !important;
}

.key.is-correct {
  background:
    linear-gradient(180deg, #efffe9, #95dfad);
  border-color: rgba(86, 185, 120, 0.7);
  color: #246947;
}

.key.is-wrong {
  background:
    linear-gradient(180deg, #ffe8ee, #ff9db3);
  border-color: rgba(222, 91, 127, 0.66);
  color: #8f304b;
}

.map-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(245, 253, 255, 0.72)),
    linear-gradient(145deg, rgba(157, 222, 177, 0.28), rgba(255, 242, 199, 0.36) 42%, rgba(135, 207, 238, 0.34));
}

.map-card::before {
  opacity: 0.54;
}

.map-card .level-map .level-button {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.9) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffffff, #d9dde4) !important;
  border-color: rgba(203, 211, 222, 0.82);
  color: #667181;
  box-shadow:
    inset 0 4px 8px rgba(255, 255, 255, 0.72),
    inset 0 -8px 12px rgba(98, 112, 132, 0.12),
    0 8px 14px rgba(71, 96, 128, 0.1);
}

.map-card .level-map .level-button.is-current:not(.is-complete) {
  box-shadow:
    0 0 0 5px rgba(255, 216, 108, 0.5),
    inset 0 4px 8px rgba(255, 255, 255, 0.72),
    inset 0 -8px 12px rgba(98, 112, 132, 0.1),
    0 10px 18px rgba(255, 177, 106, 0.18);
  color: #26324d;
}

.map-card .level-map .level-button.is-locked {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.92) 0 18%, transparent 20%),
    linear-gradient(180deg, #f9fafb, #cfd5dd) !important;
  color: #687281;
}

.map-card .level-map .level-button.is-complete:nth-child(4n + 1) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.82) 0 18%, transparent 20%),
    linear-gradient(180deg, #ff8aa0, #ed5d7d) !important;
  color: #ffffff;
}

.map-card .level-map .level-button.is-complete:nth-child(4n + 2) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.82) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffc17c, #f18c49) !important;
  color: #ffffff;
}

.map-card .level-map .level-button.is-complete:nth-child(4n + 3) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.84) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffe58f, #efc85d) !important;
  color: #77521b;
}

.map-card .level-map .level-button.is-complete:nth-child(4n) {
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.82) 0 18%, transparent 20%),
    linear-gradient(180deg, #9de1ad, #61bf78) !important;
  color: #ffffff;
}

.map-card .level-map .level-button.is-current.is-complete {
  box-shadow:
    0 0 0 5px rgba(255, 216, 108, 0.58),
    inset 0 4px 8px rgba(255, 255, 255, 0.56),
    inset 0 -8px 10px rgba(110, 35, 77, 0.14),
    0 10px 18px rgba(255, 177, 106, 0.22);
}

.sticker-slot {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(245, 253, 255, 0.78));
  border-color: rgba(207, 226, 239, 0.84);
}

.progress-track,
.hero__badge-track {
  background: rgba(211, 225, 235, 0.64);
}

.progress-bar,
.hero__badge-bar {
  background:
    linear-gradient(90deg, #78d79e, #56bce8);
}

.falling-stage,
.word-stage {
  background:
    linear-gradient(180deg, rgba(226, 248, 255, 0.82), rgba(255, 250, 239, 0.88));
  border-color: rgba(207, 226, 239, 0.92);
}

.falling-stage::before,
.word-stage::before {
  background:
    radial-gradient(circle at 20% 28%, rgba(255, 216, 108, 0.58) 0 5px, transparent 6px),
    radial-gradient(circle at 74% 35%, rgba(86, 188, 232, 0.42) 0 7px, transparent 8px),
    radial-gradient(circle at 52% 70%, rgba(255, 109, 139, 0.3) 0 5px, transparent 6px);
}

.falling-letter,
.word-falling-letter {
  background:
    linear-gradient(180deg, #ffffff, #ffe2e9);
  border-color: rgba(239, 173, 195, 0.72);
  color: #d94e73;
  box-shadow:
    0 10px 18px rgba(71, 96, 128, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.falling-letter.has-power,
.falling-word-card.has-power {
  background:
    linear-gradient(180deg, #fff8ce, #ffd86b);
  border-color: rgba(255, 193, 94, 0.76);
  color: #80591c;
}

.word-falling-letter.is-distractor {
  background:
    linear-gradient(180deg, #f7fbff, #dce9f2);
  color: #6b7888;
}

.word-target-card strong,
.word-letter-slots span.is-current {
  color: #d94e73;
}

.word-letter-slots span.is-current {
  border-color: rgba(255, 193, 94, 0.86);
  box-shadow: 0 0 0 4px rgba(255, 216, 108, 0.2);
}

@media (min-width: 981px) {
  .hero h1,
  .falling-hero h1 {
    text-shadow:
      0 2px 0 #ffffff,
      0 5px 0 rgba(255, 255, 255, 0.82),
      0 9px 13px rgba(185, 74, 104, 0.18);
  }
}

/* Generated image asset skin: real illustration layers, HTML keeps all text and state. */
.hero {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 247, 226, 0.22)),
    #d9f6ff;
}

.hero::before {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.42) 42%, rgba(255, 255, 255, 0.22) 76%),
    image-set(
      url("assets/hero-candy-island.webp") type("image/webp"),
      url("assets/hero-candy-island.png") type("image/png")
    );
  background-position:
    center,
    left center;
  background-repeat: no-repeat;
  background-size:
    cover,
    auto 100%;
  opacity: 1;
}

.hero__scene {
  display: none;
}

.hero h1,
.falling-hero h1 {
  color: #ff5f84;
  text-shadow:
    0 2px 0 #ffffff,
    0 5px 0 rgba(255, 255, 255, 0.88),
    0 8px 0 rgba(199, 65, 104, 0.28),
    0 12px 18px rgba(62, 113, 154, 0.18);
}

.hero__copy {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 243, 220, 0.66));
  border: 1px solid rgba(255, 255, 255, 0.76);
  box-shadow: 0 10px 20px rgba(75, 107, 138, 0.1);
  color: #2e4364;
}

.map-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 246, 224, 0.12)),
    image-set(
      url("assets/map-candy-island.webp") type("image/webp"),
      url("assets/map-candy-island.png") type("image/png")
    );
  background-position: center 46%;
  background-size: 112% auto;
  overflow: hidden;
}

.map-card::before {
  display: none;
}

.map-card .section-head,
.map-card .level-map,
.map-card .map-legend {
  position: relative;
  z-index: 1;
}

.map-card .level-map {
  background: rgba(255, 255, 255, 0.02);
  border-color: rgba(255, 255, 255, 0.28);
}

.map-card .level-map::before {
  opacity: 0.22;
}

.mistake-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 248, 232, 0.6)),
    image-set(
      url("assets/reward-candy-basket.webp") type("image/webp"),
      url("assets/reward-candy-basket.png") type("image/png")
    );
  background-position: 38% 84%;
  background-size: 168% auto;
}

.mistake-card::after {
  content: none;
}

.sticker-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 249, 236, 0.78)),
    image-set(
      url("assets/reward-candy-basket.webp") type("image/webp"),
      url("assets/reward-candy-basket.png") type("image/png")
    );
  background-position: 58% 88%;
  background-size: 122% auto;
}

.sticker-card .section-head,
.sticker-card .sticker-grid {
  position: relative;
  z-index: 1;
}

@media (min-width: 981px) {
  .hero > div:first-child {
    justify-items: start;
    margin-left: clamp(170px, 10vw, 230px);
    max-width: 410px;
    padding-top: 8px;
    text-align: left;
  }

  .hero h1 {
    font-size: clamp(36px, 3.7vw, 50px);
    line-height: 0.98;
  }

  .hero .hero-actions,
  .hero .mini-game-links {
    display: flex !important;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: flex-start;
  }

  .hero .hero-actions {
    gap: 10px;
    margin-top: 8px;
  }

  .hero .hero-action {
    font-size: 14px;
    min-height: 38px;
    min-width: 132px;
    padding: 0 16px;
    white-space: nowrap;
  }

  .hero .hero-action:nth-child(2) {
    min-width: 154px;
  }

  .hero .mini-game-links {
    gap: 8px;
    margin-top: 7px;
  }

  .hero .mini-game-link {
    font-size: 12px;
    min-height: 28px;
    padding: 0 12px;
  }

  .hero__badge {
    background: rgba(255, 255, 255, 0.84);
    backdrop-filter: blur(16px) saturate(1.12);
  }

  .practice-panel {
    min-height: 0;
  }

  .keyboard-panel {
    min-height: 188px;
  }

  .prompt-board {
    margin-bottom: 10px;
  }

  .keyboard-panel {
    min-height: 202px;
    padding: 10px 12px 8px;
  }

  .keyboard {
    gap: 6px;
  }

  .key-row {
    gap: 6px;
  }

  .key-row--home {
    padding-left: 48px;
  }

  .key-row--bottom {
    padding-left: 92px;
  }

  .key {
    font-size: 17px;
    height: 31px;
    min-height: 31px;
    min-width: clamp(45px, 4.1vw, 64px);
  }

  .key--wide {
    min-width: min(44vw, 430px);
  }
}

@media (max-width: 980px) {
  .hero::before {
    background-position:
      center,
      left center;
    background-size:
      cover,
      auto 100%;
  }
}

@media (max-width: 680px) {
  .app-shell .hero {
    background: #daf6ff;
  }

  .app-shell .hero::before {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.26), rgba(255, 247, 226, 0.12)),
      image-set(
        url("assets/hero-candy-island.webp") type("image/webp"),
        url("assets/hero-candy-island.png") type("image/png")
      );
    background-position: 24% center;
    background-size: cover;
  }

  .app-shell .hero > div:first-child {
    background: rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    padding: 0;
  }

  .app-shell .hero h1 {
    text-shadow:
      0 2px 0 #ffffff,
      0 5px 0 rgba(255, 255, 255, 0.9),
      0 8px 14px rgba(185, 74, 104, 0.24);
  }
}

/* Final production polish: make the practice surface feel like a finished game board. */
.practice-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 251, 242, 0.76)),
    radial-gradient(circle at 8% 100%, rgba(255, 166, 118, 0.18) 0 120px, transparent 122px),
    radial-gradient(circle at 92% 98%, rgba(86, 188, 232, 0.14) 0 150px, transparent 152px);
  border-color: rgba(255, 255, 255, 0.92);
  box-shadow:
    0 18px 38px rgba(73, 96, 130, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
  overflow: hidden;
}

.practice-panel::after {
  background:
    radial-gradient(circle at 12% 50%, rgba(255, 138, 160, 0.2) 0 16px, transparent 17px),
    radial-gradient(circle at 28% 70%, rgba(255, 216, 108, 0.22) 0 10px, transparent 11px),
    radial-gradient(circle at 82% 64%, rgba(120, 215, 158, 0.18) 0 18px, transparent 19px);
  bottom: -42px;
  content: "";
  height: 96px;
  left: 0;
  pointer-events: none;
  position: absolute;
  right: 0;
}

.level-meta {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 249, 236, 0.45));
  border: 1px solid rgba(224, 238, 247, 0.8);
  border-radius: 8px;
  padding: 10px 14px;
}

.level-meta p {
  background: rgba(255, 255, 255, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 999px;
  padding: 8px 14px;
}

.star-goals {
  box-shadow:
    0 10px 18px rgba(139, 100, 28, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.prompt-board {
  align-items: stretch;
}

.prompt-text {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(250, 254, 255, 0.92));
  border-color: rgba(171, 219, 247, 0.86);
  box-shadow:
    0 12px 24px rgba(63, 95, 129, 0.1),
    inset 0 1px 0 #ffffff;
}

.current-target {
  background:
    radial-gradient(circle at 50% 44%, rgba(255, 255, 255, 0.98) 0 42%, rgba(255, 224, 235, 0.92) 43% 100%);
  box-shadow:
    0 14px 24px rgba(244, 68, 125, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.98);
}

.keyboard-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 249, 236, 0.84));
  border-color: rgba(255, 222, 185, 0.78);
  box-shadow:
    0 16px 30px rgba(73, 96, 130, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.98),
    inset 0 -14px 24px rgba(255, 218, 170, 0.18);
}

.keyboard {
  position: relative;
  z-index: 1;
}

.keyboard::before {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.35), rgba(255, 225, 170, 0.18));
  border-radius: 8px;
  bottom: -8px;
  content: "";
  left: 50%;
  pointer-events: none;
  position: absolute;
  top: -8px;
  transform: translateX(-50%);
  width: min(840px, 86%);
  z-index: -1;
}

.score-strip {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(255, 249, 235, 0.44));
  border: 1px solid rgba(224, 238, 247, 0.68);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

.score-strip div {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.28));
  border: 1px solid rgba(255, 255, 255, 0.64);
  border-radius: 999px;
  min-height: 52px;
}

.side-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 250, 240, 0.68));
}

.today-card,
.mistake-card,
.sticker-card {
  min-height: 132px;
}

.today-card p,
.mistake-card p {
  background: rgba(255, 255, 255, 0.54);
  border-radius: 8px;
  padding: 8px 10px;
}

@media (min-width: 981px) {
  .practice-panel {
    padding-bottom: 12px;
  }

  .level-meta {
    min-height: 58px;
  }

  .prompt-board {
    gap: 14px;
  }

  .score-strip {
    margin-top: 10px;
    padding: 8px 14px;
  }
}

@media (max-width: 680px) {
  .level-meta p {
    border-radius: 8px;
  }

  .score-strip div {
    border-radius: 8px;
  }
}

/* Final correction: keep the game-board polish without making the work area heavy. */
.practice-panel::after {
  opacity: 0.34;
}

.level-meta {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 249, 236, 0.28));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.level-meta p {
  background: rgba(255, 255, 255, 0.34);
  font-size: 14px;
  line-height: 1.35;
}

.today-card p,
.mistake-card p {
  font-size: 12px;
  line-height: 1.45;
  padding: 6px 8px;
}

.score-strip {
  overflow: visible;
}

.score-strip div {
  box-shadow:
    0 7px 14px rgba(73, 96, 130, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

@media (min-width: 981px) {
  .level-meta {
    min-height: 64px;
    padding: 8px 14px;
  }

  .practice-panel {
    padding-top: 10px;
  }

  .score-strip {
    min-height: 52px;
  }

  .score-strip div {
    min-height: 44px;
  }
}

/* Hero secondary games: keep them inside the banner, not sitting on the divider. */
@media (min-width: 981px) {
  .hero .mini-game-links {
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(255, 255, 255, 0.74);
    border-radius: 999px;
    box-shadow:
      0 10px 20px rgba(64, 112, 148, 0.1),
      inset 0 1px 0 rgba(255, 255, 255, 0.82);
    gap: 6px;
    left: clamp(430px, 30vw, 610px);
    margin: 0;
    padding: 4px;
    position: absolute;
    top: 92px;
    width: max-content;
    z-index: 5;
  }

  .hero .mini-game-link {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(245, 253, 255, 0.82));
    border: 1px solid rgba(194, 220, 235, 0.72);
    border-radius: 999px;
    box-shadow: none;
    color: #285170;
    min-height: 26px;
    min-width: 92px;
    padding: 0 12px;
  }

  .hero .mini-game-link:nth-child(2) {
    background:
      linear-gradient(180deg, #73cff2, #42aad9);
    color: #ffffff;
  }

  .hero .mini-game-link::before {
    height: 18px;
    margin-right: 5px;
    width: 18px;
  }
}

/* Mini-game entry cards: two playful side quests instead of plain text buttons. */
.hero .mini-game-title {
  align-items: center;
  background:
    linear-gradient(180deg, #ff7ca1, #f04c7d);
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 8px;
  box-shadow:
    0 7px 14px rgba(216, 70, 120, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
  color: #ffffff;
  display: inline-flex;
  font-size: 12px;
  font-weight: 900;
  justify-content: center;
  min-height: 34px;
  padding: 0 10px;
  text-shadow: 0 1px 0 rgba(143, 30, 77, 0.16);
  white-space: nowrap;
}

.hero .mini-game-link strong,
.hero .mini-game-link small {
  display: block;
  line-height: 1.12;
}

.hero .mini-game-link small {
  font-size: 10px;
  font-weight: 800;
  opacity: 0.82;
}

@media (min-width: 981px) {
  .hero .mini-game-links {
    align-items: stretch;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.76), rgba(241, 253, 255, 0.56));
    border-radius: 8px;
    display: grid !important;
    gap: 6px;
    grid-template-columns: 62px 112px 112px;
    left: clamp(402px, 28vw, 560px);
    padding: 7px;
    top: 82px;
  }

  .hero .mini-game-link {
    align-items: center;
    border-radius: 8px;
    display: grid;
    font-size: 13px;
    grid-template-columns: 25px minmax(0, 1fr);
    grid-template-rows: auto auto;
    justify-items: start;
    min-height: 44px;
    min-width: 0;
    padding: 5px 8px 5px 7px;
    text-align: left;
  }

  .hero .mini-game-link::before {
    grid-row: 1 / 3;
    height: 22px;
    margin-right: 0;
    width: 22px;
  }

  .hero .mini-game-link--letters,
  .hero .mini-game-link:nth-child(2) {
    background:
      linear-gradient(180deg, #fff5fb, #ffe0ec);
    border-color: rgba(255, 171, 204, 0.66);
    color: #c93d6a;
  }

  .hero .mini-game-link--letters::before {
    background:
      radial-gradient(circle at 38% 30%, #ffffff 0 18%, transparent 20%),
      linear-gradient(180deg, #ff8bae, #f15384);
    color: #ffffff;
    content: "A";
  }

  .hero .mini-game-link--words {
    background:
      linear-gradient(180deg, #effbff, #cfefff);
    border-color: rgba(128, 201, 235, 0.66);
    color: #21769d;
  }

  .hero .mini-game-link--words::before {
    background:
      radial-gradient(circle at 38% 30%, #ffffff 0 18%, transparent 20%),
      linear-gradient(180deg, #76d1f2, #42aee0);
    color: #ffffff;
    content: "W";
  }
}

@media (max-width: 680px) {
  .hero .mini-game-title {
    min-height: 30px;
  }

  .hero .mini-game-link {
    display: inline-grid;
    grid-template-columns: 24px minmax(0, 1fr);
    grid-template-rows: auto auto;
    text-align: left;
  }

  .hero .mini-game-link::before {
    grid-row: 1 / 3;
  }
}

/* Overall polish pass: calmer surfaces, cleaner hierarchy, stronger candy-game finish. */
body {
  background:
    radial-gradient(circle at 6% 9%, rgba(255, 255, 255, 0.88) 0 26px, transparent 27px),
    radial-gradient(circle at 96% 8%, rgba(255, 255, 255, 0.72) 0 42px, transparent 44px),
    radial-gradient(circle at 0 86%, rgba(255, 165, 185, 0.22) 0 170px, transparent 172px),
    linear-gradient(180deg, #caf3ff 0 24%, #e9fff8 42%, #fff6df 100%);
  color: #24375b;
}

@media (min-width: 981px) {
  .app-shell {
    gap: 16px;
    grid-template-columns: minmax(900px, 1fr) 352px;
    padding: 14px;
  }

  .lesson-area {
    gap: 11px;
    grid-template-rows: 200px minmax(0, 1fr);
  }

  .hero {
    border: 2px solid rgba(255, 255, 255, 0.86);
    box-shadow:
      0 16px 32px rgba(59, 119, 154, 0.14),
      inset 0 1px 0 rgba(255, 255, 255, 0.86);
    height: 200px;
    overflow: hidden;
  }

  .hero::after {
    background:
      linear-gradient(90deg, #ff8aa7 0 16%, #ffd569 16% 33%, #7bdc9c 33% 52%, #5fc4e8 52% 72%, #a48bff 72% 100%);
    border-radius: 999px;
    bottom: 8px;
    content: "";
    height: 5px;
    left: 0;
    opacity: 0.92;
    position: absolute;
    right: 0;
  }

  .hero > div:first-child {
    padding-top: 6px;
  }

  .hero h1 {
    color: #f95580;
    font-size: clamp(38px, 3.9vw, 54px);
    text-shadow:
      0 2px 0 #ffffff,
      0 5px 0 rgba(255, 255, 255, 0.78),
      0 8px 12px rgba(195, 65, 105, 0.18);
  }

  .hero__copy {
    background: rgba(255, 255, 255, 0.58);
    border-color: rgba(255, 255, 255, 0.72);
    box-shadow: none;
    color: #294064;
    font-size: 13px;
    padding: 5px 13px;
  }

  .hero .hero-actions {
    gap: 9px;
    margin-top: 9px;
  }

  .hero .hero-action {
    box-shadow:
      0 8px 14px rgba(65, 98, 136, 0.12),
      inset 0 2px 0 rgba(255, 255, 255, 0.5);
    min-height: 38px;
  }

  .hero .mini-game-links {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(244, 253, 255, 0.62));
    border: 1px solid rgba(255, 255, 255, 0.82);
    box-shadow:
      0 10px 18px rgba(61, 105, 146, 0.1),
      inset 0 1px 0 rgba(255, 255, 255, 0.92);
    grid-template-columns: 56px 106px 106px;
    left: clamp(300px, 20vw, 380px);
    top: 76px;
  }

  .hero .mini-game-title {
    background:
      linear-gradient(180deg, #ff769b, #ef4d79);
    border-radius: 7px;
    min-height: 42px;
    padding: 0 8px;
  }

  .hero .mini-game-link {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.88);
  }

  .hero__badge {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(250, 254, 255, 0.82));
    border-color: rgba(213, 235, 246, 0.74);
    box-shadow:
      0 12px 22px rgba(60, 104, 143, 0.12),
      inset 0 1px 0 #ffffff;
    right: 18px;
    top: 22px;
  }

  .practice-panel {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 251, 241, 0.82));
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow:
      0 18px 34px rgba(72, 105, 130, 0.12),
      inset 0 1px 0 rgba(255, 255, 255, 0.96);
    padding: 12px 18px 14px;
  }

  .level-meta,
  .star-goals,
  .prompt-text,
  .keyboard-panel,
  .score-strip {
    border-color: rgba(218, 236, 246, 0.78);
    box-shadow:
      0 8px 16px rgba(79, 111, 139, 0.07),
      inset 0 1px 0 rgba(255, 255, 255, 0.9);
  }

  .level-meta {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(249, 254, 255, 0.44));
    min-height: 60px;
  }

  .level-meta p {
    background: transparent;
    color: #52637e;
    font-size: 13px;
  }

  .star-goals {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 248, 222, 0.58));
  }

  .prompt-text {
    background:
      linear-gradient(180deg, #ffffff, #f8fdff);
  }

  .keyboard-panel {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(255, 248, 229, 0.76));
    min-height: 190px;
  }

  .keyboard::before {
    opacity: 0.55;
  }

  .key {
    box-shadow:
      0 4px 0 rgba(214, 181, 119, 0.34),
      0 7px 12px rgba(75, 103, 128, 0.08),
      inset 0 1px 0 rgba(255, 255, 255, 0.92);
  }

  .score-strip {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 251, 239, 0.58));
    margin-top: 8px;
  }

  .score-strip div {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.5));
    min-height: 46px;
  }

  .side-panel {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 250, 235, 0.7));
    border: 1px solid rgba(255, 255, 255, 0.88);
    box-shadow:
      0 18px 34px rgba(70, 111, 141, 0.12),
      inset 0 1px 0 rgba(255, 255, 255, 0.96);
    gap: 12px;
    padding: 12px;
  }

  .map-card,
  .today-card,
  .mistake-card,
  .sticker-card {
    border-color: rgba(218, 236, 246, 0.78);
    box-shadow:
      0 9px 17px rgba(74, 106, 132, 0.08),
      inset 0 1px 0 rgba(255, 255, 255, 0.88);
  }

  .map-card .section-head h2 {
    border-radius: 7px;
    box-shadow: 0 7px 13px rgba(230, 45, 105, 0.18);
  }

  .level-map {
    padding: 32px 25px 18px;
  }

  .level-button {
    box-shadow:
      0 7px 13px rgba(72, 97, 126, 0.1),
      inset 0 3px 7px rgba(255, 255, 255, 0.72);
  }
}

@media (max-width: 980px) {
  .hero .mini-game-links {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(244, 253, 255, 0.62));
    border: 1px solid rgba(255, 255, 255, 0.82);
    border-radius: 8px;
    padding: 7px;
  }
}

/* Achievement reward rail: make stickers explain themselves on hover/focus. */
.achievement-card {
  overflow: visible;
  position: relative;
}

.achievement-card .section-head {
  align-items: center;
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.achievement-card__intro {
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 8px;
  color: #49627e;
  font-size: 12px;
  line-height: 1.45;
  margin: 7px 0 0;
  padding: 7px 9px;
}

.achievement-count {
  background:
    linear-gradient(180deg, #ffffff, #eaf8ff);
  border: 1px solid rgba(181, 219, 239, 0.86);
  border-radius: 999px;
  color: #2b6f92;
  font-size: 12px;
  font-weight: 900;
  min-width: 42px;
  padding: 4px 9px;
  text-align: center;
  white-space: nowrap;
}

.achievement-card .sticker-grid {
  gap: 8px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-top: 9px;
  overflow: visible;
  position: relative;
  z-index: 3;
}

.achievement-card .sticker {
  align-items: center;
  aspect-ratio: 1;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 248, 226, 0.74));
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: 8px;
  box-shadow:
    0 8px 13px rgba(71, 96, 128, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  color: #c75274;
  cursor: help;
  display: grid;
  font-size: 11px;
  font-weight: 900;
  justify-items: center;
  min-width: 0;
  outline: none;
  padding: 6px 4px;
  position: relative;
  text-align: center;
  transition:
    transform 140ms ease,
    box-shadow 140ms ease,
    border-color 140ms ease;
}

.achievement-card .sticker::before {
  content: none;
}

.achievement-card .sticker:hover,
.achievement-card .sticker:focus-visible {
  border-color: rgba(255, 139, 174, 0.82);
  box-shadow:
    0 12px 20px rgba(71, 96, 128, 0.16),
    0 0 0 4px rgba(255, 219, 111, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  transform: translateY(-3px);
  z-index: 20;
}

.achievement-card .sticker.is-locked {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(226, 232, 238, 0.72));
  color: #78828c;
  filter: grayscale(0.15);
}

.sticker__icon {
  align-items: center;
  background:
    radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.95) 0 18%, transparent 20%),
    linear-gradient(180deg, #ffcf69, #f39a42);
  border: 3px solid rgba(255, 255, 255, 0.88);
  border-radius: 999px;
  box-shadow: 0 5px 9px rgba(83, 70, 130, 0.14);
  color: #ffffff;
  display: grid;
  font-size: 14px;
  height: 38px;
  line-height: 1;
  place-items: center;
  text-shadow: 0 1px 0 rgba(110, 68, 20, 0.18);
  width: 38px;
}

.achievement-card .sticker:nth-child(2) .sticker__icon {
  background:
    radial-gradient(circle at 50% 50%, #fff169 0 36%, #ffc32d 37% 100%);
  clip-path: polygon(50% 0, 62% 35%, 100% 35%, 69% 56%, 82% 96%, 50% 72%, 18% 96%, 31% 56%, 0 35%, 38% 35%);
}

.achievement-card .sticker:nth-child(3) .sticker__icon {
  background:
    repeating-conic-gradient(#ff4d8a 0 36deg, #ffffff 36deg 72deg, #42c8ff 72deg 108deg, #ffffff 108deg 144deg);
}

.achievement-card .sticker:nth-child(4) .sticker__icon {
  background:
    radial-gradient(circle at 50% 18%, #ff77a6 0 18%, transparent 19%),
    linear-gradient(180deg, #fff2c4, #ffbfdb);
  border-radius: 40% 40% 18% 18%;
}

.achievement-card .sticker:nth-child(5) .sticker__icon {
  background:
    radial-gradient(circle at 30% 70%, #ffffff 0 20%, transparent 21%),
    radial-gradient(circle at 48% 62%, #ffffff 0 24%, transparent 25%),
    radial-gradient(circle at 66% 70%, #ffffff 0 20%, transparent 21%),
    linear-gradient(90deg, #ff4d8a, #ffe15a, #42c8ff);
}

.achievement-card .sticker.is-locked .sticker__icon {
  background:
    radial-gradient(circle at 38% 28%, rgba(255, 255, 255, 0.82) 0 18%, transparent 20%),
    linear-gradient(180deg, #f6f8fa, #cfd7df);
  color: #7d8791;
}

.sticker__label {
  display: block;
  font-size: 10px;
  line-height: 1.15;
  margin-top: 4px;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.achievement-tooltip {
  background:
    linear-gradient(180deg, #ffffff, #fff8e8);
  border: 1px solid rgba(238, 207, 150, 0.82);
  border-radius: 8px;
  bottom: calc(100% + 10px);
  box-shadow:
    0 12px 22px rgba(70, 92, 120, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  color: #31445f;
  font-size: 12px;
  font-weight: 900;
  left: 12px;
  line-height: 1.38;
  opacity: 0;
  padding: 8px 10px;
  pointer-events: none;
  position: absolute;
  right: 12px;
  text-align: left;
  transform: translateY(6px);
  transition:
    opacity 140ms ease,
    transform 140ms ease;
  visibility: hidden;
  z-index: 60;
}

.achievement-tooltip::after {
  background: #fff8e8;
  border-bottom: 1px solid rgba(238, 207, 150, 0.82);
  border-right: 1px solid rgba(238, 207, 150, 0.82);
  bottom: -5px;
  content: "";
  height: 9px;
  left: var(--achievement-arrow-x, 50%);
  position: absolute;
  transform: translateX(-50%) rotate(45deg);
  width: 9px;
}

.achievement-tooltip.is-visible {
  opacity: 1;
  transform: translateY(0);
  visibility: visible;
}

.sticker__tooltip {
  background:
    linear-gradient(180deg, #ffffff, #fff8e8);
  border: 1px solid rgba(238, 207, 150, 0.82);
  border-radius: 8px;
  bottom: calc(100% + 8px);
  box-shadow:
    0 12px 22px rgba(70, 92, 120, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  color: #31445f;
  font-size: 12px;
  font-weight: 900;
  left: 50%;
  line-height: 1.38;
  opacity: 0;
  padding: 8px 9px;
  pointer-events: none;
  position: absolute;
  transform: translate(-50%, 6px);
  transition:
    opacity 140ms ease,
    transform 140ms ease;
  visibility: hidden;
  width: 154px;
  z-index: 40;
}

.sticker__tooltip::after {
  background: #fff8e8;
  border-bottom: 1px solid rgba(238, 207, 150, 0.82);
  border-right: 1px solid rgba(238, 207, 150, 0.82);
  bottom: -5px;
  content: "";
  height: 9px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%) rotate(45deg);
  width: 9px;
}

.achievement-card .sticker:hover .sticker__tooltip,
.achievement-card .sticker:focus-visible .sticker__tooltip {
  opacity: 1;
  transform: translate(-50%, 0);
  visibility: visible;
}

.achievement-card .sticker:first-child .sticker__tooltip {
  left: 0;
  transform: translate(0, 6px);
}

.achievement-card .sticker:first-child:hover .sticker__tooltip,
.achievement-card .sticker:first-child:focus-visible .sticker__tooltip {
  transform: translate(0, 0);
}

.achievement-card .sticker:last-child .sticker__tooltip {
  left: auto;
  right: 0;
  transform: translate(0, 6px);
}

.achievement-card .sticker:last-child:hover .sticker__tooltip,
.achievement-card .sticker:last-child:focus-visible .sticker__tooltip {
  transform: translate(0, 0);
}

@media (max-width: 680px) {
  .achievement-card .sticker-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .sticker__tooltip {
    bottom: auto;
    left: 50%;
    top: calc(100% + 8px);
    transform: translate(-50%, -6px);
  }

  .sticker__tooltip::after {
    bottom: auto;
    top: -5px;
    transform: translateX(-50%) rotate(225deg);
  }

  .achievement-card .sticker:hover .sticker__tooltip,
  .achievement-card .sticker:focus-visible .sticker__tooltip {
    transform: translate(-50%, 0);
  }
}

@media (min-width: 981px) {
  .achievement-card {
    display: grid;
    grid-template-rows: auto 1fr;
    min-height: 104px;
    overflow: visible;
    padding: 10px 12px;
  }

  .achievement-card__intro {
    display: none;
  }

  .achievement-card .sticker-grid {
    gap: 7px;
    margin-top: 8px;
    position: static;
  }

  .achievement-card .sticker {
    aspect-ratio: auto;
    box-sizing: border-box;
    height: 44px;
    padding: 4px;
    position: static;
  }

  .sticker__icon {
    border-width: 2px;
    font-size: 12px;
    height: 28px;
    width: 28px;
  }

  .sticker__label {
    font-size: 0;
    line-height: 0;
    margin-top: 0;
  }

  .achievement-card .sticker__tooltip {
    bottom: calc(100% + 8px);
    left: 0;
    right: 0;
    text-align: left;
    transform: translateY(8px);
    width: auto;
  }

  .achievement-card .sticker:first-child .sticker__tooltip,
  .achievement-card .sticker:last-child .sticker__tooltip {
    left: 0;
    right: 0;
    transform: translateY(8px);
  }

  .achievement-card .sticker:hover .sticker__tooltip,
  .achievement-card .sticker:focus-visible .sticker__tooltip,
  .achievement-card .sticker:first-child:hover .sticker__tooltip,
  .achievement-card .sticker:first-child:focus-visible .sticker__tooltip,
  .achievement-card .sticker:last-child:hover .sticker__tooltip,
  .achievement-card .sticker:last-child:focus-visible .sticker__tooltip {
    transform: translateY(0);
  }

  .achievement-card .sticker__tooltip::after {
    left: var(--achievement-arrow-x, 50%);
  }

  .achievement-card .sticker:nth-child(1) {
    --achievement-arrow-x: 10%;
  }

  .achievement-card .sticker:nth-child(2) {
    --achievement-arrow-x: 30%;
  }

  .achievement-card .sticker:nth-child(3) {
    --achievement-arrow-x: 50%;
  }

  .achievement-card .sticker:nth-child(4) {
    --achievement-arrow-x: 70%;
  }

  .achievement-card .sticker:nth-child(5) {
    --achievement-arrow-x: 90%;
  }
}

/* Global hover/floating polish: keep the page stable and avoid jumpy overlays. */
@media (hover: hover) and (pointer: fine) {
  button:hover:not(:disabled),
  .page-link:hover,
  .hero-action:hover,
  .mini-game-link:hover,
  .ghost-button:hover,
  .game-control:hover:not(:disabled) {
    border-color: rgba(255, 139, 174, 0.46);
    box-shadow:
      0 8px 16px rgba(71, 96, 128, 0.11),
      0 3px 8px rgba(255, 109, 139, 0.08),
      inset 0 1px 0 rgba(255, 255, 255, 0.88);
    transform: none;
  }

  .level-button:hover,
  .level-button.is-current {
    filter: brightness(1.03) saturate(1.03);
    transform: none !important;
  }

  .level-button:hover {
    box-shadow:
      0 8px 14px rgba(72, 97, 126, 0.12),
      inset 0 3px 7px rgba(255, 255, 255, 0.72);
  }

  .key:hover,
  .key.is-target {
    transform: none !important;
  }

  .key.is-target {
    box-shadow:
      0 0 0 4px rgba(255, 216, 108, 0.22),
      0 5px 0 rgba(221, 165, 63, 0.38),
      0 9px 16px rgba(255, 177, 106, 0.12) !important;
  }

  .achievement-card .sticker:hover,
  .achievement-card .sticker:focus-visible {
    transform: none;
  }
}

@media (min-width: 981px) {
  .achievement-card .sticker:hover,
  .achievement-card .sticker:focus-visible {
    transform: none !important;
  }

  .achievement-tooltip {
    bottom: calc(100% + 10px);
    left: 12px;
    right: 12px;
    width: auto;
  }

  .achievement-card .sticker .sticker__tooltip {
    bottom: calc(100% + 10px) !important;
    left: 12px !important;
    right: 12px !important;
    text-align: left;
    transform: translateY(6px) !important;
    width: auto !important;
  }

  .achievement-card .sticker:hover .sticker__tooltip,
  .achievement-card .sticker:focus-visible .sticker__tooltip,
  .achievement-card .sticker:first-child:hover .sticker__tooltip,
  .achievement-card .sticker:first-child:focus-visible .sticker__tooltip,
  .achievement-card .sticker:last-child:hover .sticker__tooltip,
  .achievement-card .sticker:last-child:focus-visible .sticker__tooltip {
    transform: translateY(0) !important;
  }

  .achievement-card .sticker .sticker__tooltip::after {
    left: var(--achievement-arrow-x, 50%) !important;
  }
}
