/* ==========================================================================
   页面层：首页 / 单元 / 学习 / 游戏 / 庆祝 / 贴纸册 / 家长中心
   ========================================================================== */

/* ============================ 首页 ============================ */
.home {
  gap: clamp(14px, 2.2vh, 26px);
}

.hello {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.hello__mascot {
  width: 74px;
  height: 74px;
  flex: none;
  border-radius: 50%;
  background: linear-gradient(180deg, #eefaf3, #d7f0e4);
  padding: 4px;
  box-shadow: var(--shadow-s);
}
.hello__text {
  min-width: 0;
}
.hello__hi {
  font-size: var(--f-head);
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hello__sub {
  font-size: var(--f-small);
  color: var(--muted);
  margin-top: 2px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(180px, 0.85fr);
  align-items: center;
  gap: clamp(10px, 2vw, 30px);
  padding: clamp(20px, 2.8vw, 36px);
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, #fff5e6 0%, #ffe9d6 48%, #ffdfe2 100%);
  box-shadow: var(--shadow-m);
  overflow: hidden;
  isolation: isolate;
}
.hero::before {
  content: "";
  position: absolute;
  inset: auto -60px -120px auto;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  z-index: -1;
}
.hero__copy {
  display: grid;
  gap: 10px;
  justify-items: start;
  min-width: 0;
}
.hero__kicker {
  font-size: var(--f-small);
  color: var(--coral);
  letter-spacing: 0.12em;
}
.hero__title {
  font-size: clamp(26px, 3.4vw, 44px);
  line-height: 1.24;
}
.hero__title em {
  font-style: normal;
  color: var(--green-deep);
}
.hero__sub {
  font-size: var(--f-body);
  color: var(--ink-soft);
  font-weight: 700;
}
.hero__cta {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.hero__art {
  position: relative;
  display: grid;
  place-items: center;
}
.hero__art img {
  width: clamp(140px, 17vw, 220px);
  filter: drop-shadow(0 18px 26px rgba(120, 96, 70, 0.16));
  animation: bob 3.4s ease-in-out infinite;
}
.hero__bubble {
  position: absolute;
  top: -4px;
  right: 4%;
  padding: 10px 18px;
  border-radius: 20px 20px 20px 4px;
  background: #fff;
  font-size: var(--f-body);
  color: var(--ink);
  box-shadow: var(--shadow-s);
  white-space: nowrap;
  animation: rise 0.5s 0.25s var(--ease-out) both;
}

.tabs {
  display: flex;
  gap: 10px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow-s);
  align-self: flex-start;
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 62px;
  padding: 0 26px;
  border-radius: 999px;
  font-size: var(--f-body);
  color: var(--ink-soft);
  white-space: nowrap;
  transition: background var(--fast), color var(--fast), transform var(--fast);
}
.tab img { width: 26px; height: 26px; opacity: 0.8; }
.tab[aria-selected="true"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-s);
}
.tab[data-status="planned"] { color: var(--muted); }
.tab__soon {
  font-style: normal;
  font-size: 10px;
  font-weight: 900;
  color: var(--muted);
  background: #f1e9df;
  padding: 2px 7px;
  border-radius: 99px;
  letter-spacing: 0.04em;
}
.tab:active { transform: scale(0.97); }

.section-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 4px;
}
.section-head h2 {
  font-size: var(--f-head);
}
.section-head span {
  font-size: var(--f-small);
  color: var(--muted);
  font-weight: 700;
}

.islands {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(clamp(210px, 22vw, 300px), 1fr));
  gap: var(--gap);
}

.island {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 18px 18px 16px;
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow-s);
  text-align: left;
  overflow: hidden;
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
  isolation: isolate;
}
.island:active { transform: scale(0.975); box-shadow: var(--shadow-m); }
.island::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 62%;
  background: linear-gradient(180deg, var(--unit-soft), rgba(255, 255, 255, 0));
  z-index: -1;
}
.island__cover {
  height: clamp(96px, 11vw, 132px);
  border-radius: var(--r-md);
  display: grid;
  place-items: center;
  gap: 6px;
  overflow: hidden;
  background: var(--unit-soft);
}
.island__cover img {
  width: 74px;
  height: 74px;
  filter: drop-shadow(0 6px 10px rgba(90, 74, 60, 0.12));
}
.island__cover--row {
  display: flex;
  align-items: center;
  justify-content: center;
}
.island__cover--row img:nth-child(1) { transform: rotate(-8deg) translateY(6px); }
.island__cover--row img:nth-child(2) { transform: translateY(-6px) scale(1.08); }
.island__cover--row img:nth-child(3) { transform: rotate(8deg) translateY(6px); }
.island__dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  align-items: center;
}
.island__dots i {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #fff;
  box-shadow: inset 0 0 0 3px rgba(94, 78, 110, 0.12);
}
.island__dots i.is-on {
  background: var(--unit-main);
  box-shadow: 0 4px 10px rgba(94, 78, 110, 0.18);
}
.island__num {
  font-family: "Nunito", sans-serif;
  font-size: clamp(30px, 4vw, 46px);
  font-weight: 900;
  color: var(--unit-main);
  line-height: 1;
}
.island__title {
  font-size: clamp(19px, 2vw, 24px);
  margin-top: 2px;
}
.island__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--f-small);
  color: var(--muted);
  font-weight: 700;
}
.island__bar {
  height: 10px;
  border-radius: 99px;
  background: #f2ece4;
  overflow: hidden;
}
.island__bar span {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: var(--unit-main);
  transition: width 0.6s var(--ease-out);
}
.island__badge {
  position: absolute;
  top: 12px;
  right: 12px;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #fff;
  box-shadow: var(--shadow-s);
}
.island__badge img { width: 30px; height: 30px; }
.island__flag {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 6px 12px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.92);
  font-size: 13px;
  font-weight: 900;
  color: var(--unit-deep);
  letter-spacing: 0.04em;
}
.island--soon {
  opacity: 0.72;
  filter: saturate(0.55);
}
.island--soon .island__cover {
  background: repeating-linear-gradient(135deg, #f6f1ea 0 12px, #fbf7f2 12px 24px);
}

.tabbar {
  margin-top: auto;
  padding-top: clamp(10px, 2vh, 20px);
  display: flex;
  justify-content: center;
  gap: clamp(8px, 2vw, 24px);
}
.tabbar__item {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-width: 96px;
  padding: 8px 18px;
  border-radius: var(--r-md);
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  transition: background var(--fast), color var(--fast);
}
.tabbar__item img, .tabbar__item svg {
  width: 34px;
  height: 34px;
}
.tabbar__item[aria-current="page"] {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow-s);
}
.tabbar__item:active { transform: scale(0.95); }

/* ============================ 单元页 ============================ */
.unit {
  gap: clamp(14px, 2.4vh, 26px);
}
.unit__head {
  display: grid;
  align-content: center;
  min-height: clamp(190px, 26vh, 250px);
  gap: 8px;
  padding: clamp(22px, 3vw, 38px);
  border-radius: var(--r-xl);
  background:
    radial-gradient(120% 150% at 90% 0%, rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0) 60%),
    var(--unit-soft);
  box-shadow: var(--shadow-s);
  position: relative;
  overflow: hidden;
}
.unit__head h1 {
  font-size: clamp(30px, 4vw, 50px);
}
.unit__head p {
  font-size: var(--f-body);
  color: var(--unit-deep);
  font-weight: 700;
  opacity: 0.9;
}
.unit__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 6px;
}
.pill {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.85);
  font-size: var(--f-small);
  font-weight: 800;
  color: var(--ink-soft);
}
.pill img { width: 22px; height: 22px; }

.unit__cols {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr);
  gap: var(--gap);
  align-items: start;
}
@media (max-width: 900px) {
  .unit__cols { grid-template-columns: 1fr; }
}

.play-grid {
  display: grid;
  gap: 12px;
}
.play {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: var(--shadow-s);
  text-align: left;
  transition: transform var(--fast) var(--ease);
}
.play:active { transform: scale(0.98); }
.play__ico {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  border-radius: 22px;
  background: var(--unit-soft);
  flex: none;
}
.play__ico img { width: 42px; height: 42px; }
.play__txt { display: grid; gap: 2px; min-width: 0; }
.play__txt b { font-size: var(--f-body); }
.play__txt span { font-size: var(--f-small); color: var(--muted); font-weight: 700; }
.play__go {
  margin-left: auto;
  font-size: 26px;
  color: var(--unit-main);
  flex: none;
}
.play--main {
  background: linear-gradient(135deg, var(--unit-main), var(--unit-deep));
  box-shadow: 0 8px 0 rgba(0, 0, 0, 0.09), 0 18px 30px rgba(94, 78, 110, 0.18);
  padding: 22px 24px;
}
.play--main .play__ico { background: rgba(255, 255, 255, 0.24); }
.play--main .play__txt b { color: #fff; font-size: clamp(22px, 2.4vw, 30px); }
.play--main .play__txt span { color: rgba(255, 255, 255, 0.85); }
.play--main .play__go { color: #fff; }

.words-strip {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 10px;
}
.chipword {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 12px 6px 10px;
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-s);
  transition: transform var(--fast) var(--ease), box-shadow var(--fast);
}
.chipword:active { transform: scale(0.94); }
.chipword .art--img { width: 46px; }
.chipword .art--color,
.chipword .art--number { width: 46px; border-radius: 14px; }
.chipword .art--number { font-size: 24px; text-shadow: none; }
.chipword b {
  font-size: 15px;
  font-family: "Nunito", sans-serif;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
}
.chipword.is-done::after {
  content: "★";
  position: absolute;
  margin-left: 60px;
  margin-top: -6px;
  color: var(--sun);
  font-size: 16px;
}
.chipword { position: relative; }

.mission {
  display: grid;
  gap: 12px;
  padding: 22px;
  border-radius: var(--r-md);
  background: linear-gradient(150deg, #fffdf7, #fff4dd);
  box-shadow: var(--shadow-s);
  border: 2px dashed #f3dcae;
}
.mission h3 {
  font-size: var(--f-body);
  color: #a9781a;
}
.mission p { font-size: var(--f-body); color: var(--ink-soft); font-weight: 700; line-height: 1.5; }
.mission small { color: var(--muted); font-weight: 700; }

/* ============================ 学习页 ============================ */
.learn {
  justify-content: flex-start;
}
.learn__bar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: none;
}
.learn__dots {
  display: flex;
  gap: 8px;
  flex: 1;
  justify-content: center;
}
.learn__dots i {
  width: 14px;
  height: 14px;
  border-radius: 99px;
  background: rgba(94, 78, 110, 0.14);
  transition: all 0.3s var(--ease);
}
.learn__dots i.is-done { background: var(--green); }
.learn__dots i.is-now { width: 40px; background: var(--sun); }

.learn__stage {
  flex: 1;
  display: grid;
  place-items: center;
  padding: clamp(10px, 2vh, 24px) 0;
  min-height: 0;
}
.word-card {
  width: min(980px, 94vw);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  justify-items: center;
  gap: clamp(14px, 2.4vw, 36px);
  padding: clamp(16px, 2.2vw, 30px);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--shadow-l);
  animation: pop-in 0.42s var(--ease-out) both;
}
.word-card__text {
  display: grid;
  justify-items: center;
  gap: clamp(6px, 1vh, 12px);
  min-width: 0;
}
.word-art {
  width: 100%;
  max-width: clamp(200px, 30vh, 360px);
  aspect-ratio: 1;
  border-radius: var(--r-lg);
  display: grid;
  place-items: center;
  background: var(--unit-soft);
  position: relative;
  overflow: hidden;
}
.word-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(70% 55% at 30% 20%, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0) 70%);
}
.word-art img {
  width: 78%;
  height: 78%;
  object-fit: contain;
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 14px 20px rgba(90, 74, 60, 0.16));
}
/* 通用配图（颜色块 / 数字 / 图片） */
.art {
  display: grid;
  place-items: center;
  flex: none;
}
.art--color,
.art--number {
  width: min(70%, 300px);
  aspect-ratio: 1;
  border-radius: 32%;
  background: var(--art, #eee);
  box-shadow: inset 0 -16px 0 rgba(0, 0, 0, 0.07), 0 18px 30px rgba(94, 78, 110, 0.16);
}
.art--number {
  font-family: "Nunito", sans-serif;
  font-size: clamp(76px, 13vh, 150px);
  font-weight: 900;
  line-height: 1;
  color: #fff;
  text-shadow: 0 8px 0 rgba(0, 0, 0, 0.08);
}
.art--img {
  width: 74%;
  height: auto;
}
.word-art .art--color,
.word-art .art--number {
  width: 62%;
}
.count-art {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  width: 76%;
  position: relative;
  z-index: 1;
}
.count-art img { width: 100%; height: auto; }

.word-en {
  font-family: "Nunito", sans-serif;
  font-size: clamp(56px, 9.5vw, 108px);
  font-weight: 900;
  letter-spacing: -0.01em;
  line-height: 1;
  color: var(--ink);
}
.word-ipa {
  font-size: var(--f-body);
  color: var(--muted);
  font-weight: 700;
  letter-spacing: 0.04em;
}
.word-zh {
  font-size: var(--f-body);
  color: var(--unit-deep);
  background: var(--unit-soft);
  padding: 6px 18px;
  border-radius: 99px;
}
.word-card .word-en.is-playing { animation: pulse-soft 0.7s ease-in-out; }

.learn__bottom {
  flex: none;
  display: grid;
  justify-items: center;
  min-height: clamp(104px, 14vh, 132px);
  align-content: center;
  padding-bottom: max(4px, var(--safe-b));
}
.learn__actions {
  display: flex;
  width: 100%;
  gap: clamp(10px, 1.6vw, 20px);
  justify-content: center;
  flex-wrap: wrap;
}
.learn__actions .btn { flex: 1 1 auto; max-width: 320px; }

/* 麦克风 / 跟读状态 */
.mic-panel {
  display: grid;
  justify-items: center;
  gap: 8px;
  width: 100%;
}
.wave {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 46px;
}
.wave i {
  width: 8px;
  height: 14px;
  border-radius: 99px;
  background: var(--green);
  opacity: 0.55;
}
.wave.is-live i {
  animation: wave 0.85s ease-in-out infinite;
  opacity: 1;
}
.wave.is-live i:nth-child(2) { animation-delay: 0.1s; }
.wave.is-live i:nth-child(3) { animation-delay: 0.2s; }
.wave.is-live i:nth-child(4) { animation-delay: 0.3s; }
.wave.is-live i:nth-child(5) { animation-delay: 0.4s; }
.wave.is-live i:nth-child(6) { animation-delay: 0.5s; }
.wave.is-live i:nth-child(7) { animation-delay: 0.6s; }
@keyframes wave {
  0%, 100% { height: 12px; }
  50% { height: 44px; }
}
.mic-hint {
  font-size: var(--f-small);
  color: var(--muted);
  text-align: center;
  font-weight: 700;
}

.mic-orb {
  position: relative;
  display: grid;
  place-items: center;
  width: clamp(150px, 19vh, 200px);
  height: clamp(150px, 19vh, 200px);
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%, #8fe0bb, #58b98f);
  box-shadow: 0 10px 0 #3f8f6c, 0 22px 40px rgba(63, 143, 108, 0.35);
  transition: transform var(--fast) var(--ease);
}
.mic-orb:active { transform: translateY(6px) scale(0.98); box-shadow: 0 4px 0 #3f8f6c; }
.mic-orb svg { width: 44%; height: 44%; color: #fff; filter: drop-shadow(0 3px 0 rgba(0,0,0,.14)); }
.mic-orb.is-live { animation: pulse-soft 1.1s ease-in-out infinite; }
.mic-orb.is-live::before,
.mic-orb.is-live::after {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 4px solid rgba(110, 199, 159, 0.5);
  animation: ripple 1.6s ease-out infinite;
}
.mic-orb.is-live::after { animation-delay: 0.8s; }
@keyframes ripple {
  from { transform: scale(1); opacity: 0.9; }
  to { transform: scale(1.35); opacity: 0; }
}

.verdict {
  display: grid;
  justify-items: center;
  gap: 6px;
  animation: rise 0.4s var(--ease-out) both;
}
.verdict__stars {
  display: flex;
  gap: 6px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1;
}
.verdict__stars span {
  animation: pop-in 0.45s var(--ease-out) both;
  filter: drop-shadow(0 4px 6px rgba(200, 150, 40, 0.25));
}
.verdict__stars span:nth-child(2) { animation-delay: 0.12s; }
.verdict__stars span:nth-child(3) { animation-delay: 0.24s; }
.verdict__text {
  font-size: var(--f-head);
  color: var(--green-deep);
}
.verdict__heard {
  font-size: var(--f-small);
  color: var(--muted);
  font-weight: 700;
}

.listen-big {
  display: grid;
  place-items: center;
  gap: 14px;
  padding: 8px;
}
.listen-big__btn {
  width: clamp(160px, 22vh, 230px);
  height: clamp(160px, 22vh, 230px);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 34% 28%, #ffe08a, #f2b93f);
  box-shadow: 0 10px 0 #cf9a31, 0 22px 40px rgba(207, 154, 49, 0.3);
  transition: transform var(--fast);
}
.listen-big__btn:active { transform: translateY(6px); box-shadow: 0 4px 0 #cf9a31; }
.listen-big__btn svg,
.listen-big__btn img { width: 46%; height: 46%; }
.listen-big__btn svg { color: #fff; filter: drop-shadow(0 3px 0 rgba(0,0,0,.12)); }
.listen-big__btn img { filter: brightness(0) invert(1); }
.listen-big__btn.is-live { animation: pulse-soft 1s ease-in-out infinite; }

/* ============================ 游戏页 ============================ */
.game {
  gap: clamp(10px, 1.8vh, 18px);
}
.game__prompt {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-height: clamp(96px, 13vh, 140px);
}
.game__prompt h2 {
  font-size: clamp(24px, 2.8vw, 34px);
  text-align: center;
}
.game__prompt-sub {
  font-size: var(--f-small);
  color: var(--muted);
  text-align: center;
  font-weight: 700;
}

.quiz {
  display: grid;
  gap: clamp(12px, 2vw, 20px);
  flex: 1;
  align-content: center;
}
.quiz__stage {
  display: grid;
  place-items: center;
}
.quiz__pic {
  width: clamp(190px, 28vh, 320px);
  aspect-ratio: 1;
  border-radius: var(--r-xl);
  display: grid;
  place-items: center;
  background: var(--surface);
  box-shadow: var(--shadow-l);
  padding: clamp(12px, 2vh, 22px);
  box-sizing: border-box;
}
.quiz__pic .art--img { width: 100%; height: 100%; object-fit: contain; }
.quiz__pic .art--color,
.quiz__pic .art--number { width: 82%; }

.choices {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(10px, 1.6vw, 20px);
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
}
.choice {
  position: relative;
  display: grid;
  place-items: center;
  gap: 4px;
  min-height: clamp(96px, 13vh, 140px);
  padding: 14px;
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: 0 5px 0 rgba(94, 78, 110, 0.09), 0 14px 26px rgba(94, 78, 110, 0.09);
  font-family: "Nunito", sans-serif;
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 900;
  color: var(--ink);
  transition: transform var(--fast) var(--ease), box-shadow var(--fast);
}
.choice:active { transform: translateY(4px); box-shadow: 0 1px 0 rgba(94, 78, 110, 0.09); }
.choice .art--img { width: clamp(56px, 8vh, 92px); }
.choice .art--color,
.choice .art--number { width: clamp(58px, 8vh, 84px); border-radius: 24px; }
.choice .art--number { font-size: clamp(28px, 4vh, 40px); }
.choice.is-right {
  background: linear-gradient(180deg, #d8f5e6, #b6e9cf);
  box-shadow: 0 5px 0 #7cc3a1, 0 14px 26px rgba(94, 78, 110, 0.1);
  animation: pop-in 0.4s var(--ease-out);
}
.choice.is-wrong {
  animation: wobble 0.5s var(--ease);
  background: #fdf1ee;
}
.choice.is-dim { opacity: 0.45; }

.memory {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 1.4vw, 16px);
  max-width: 760px;
  width: 100%;
  margin: 0 auto;
  flex: 1;
  align-content: center;
}
.mcard {
  position: relative;
  aspect-ratio: 1 / 1.06;
  border-radius: var(--r-md);
  perspective: 900px;
  background: none;
  box-shadow: none;
}
.mcard__inner {
  position: absolute;
  inset: 0;
  border-radius: var(--r-md);
  transform-style: preserve-3d;
  transition: transform 0.45s var(--ease);
  box-shadow: var(--shadow-s);
}
.mcard.is-open .mcard__inner { transform: rotateY(180deg); }
.mcard__face {
  position: absolute;
  inset: 0;
  border-radius: var(--r-md);
  display: grid;
  place-items: center;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  padding: 10%;
}
.mcard__back {
  background: linear-gradient(150deg, var(--unit-main), var(--unit-deep));
}
.mcard__back::after {
  content: "";
  width: 46%;
  height: 46%;
  background: rgba(255, 255, 255, 0.9);
  -webkit-mask: url("../../assets/art/sticker-sparkles.svg") center / contain no-repeat;
  mask: url("../../assets/art/sticker-sparkles.svg") center / contain no-repeat;
  opacity: 0.85;
}
.mcard__front {
  background: var(--surface);
  transform: rotateY(180deg);
}
.mcard__front .art--img { width: 100%; height: 100%; object-fit: contain; }
.mcard__front .art--color,
.mcard__front .art--number { width: 80%; border-radius: 26%; }
.mcard__front .art--number { font-size: clamp(26px, 4vw, 44px); }
.mcard.is-matched .mcard__front {
  background: linear-gradient(180deg, #e5f8ee, #cdf0dd);
}

/* ============================ 庆祝页 ============================ */
.celebrate {
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: clamp(12px, 2vh, 22px);
}
.celebrate__stage {
  position: relative;
  display: grid;
  place-items: center;
}
.celebrate__glow {
  position: absolute;
  width: clamp(260px, 42vh, 420px);
  height: clamp(260px, 42vh, 420px);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 226, 150, 0.9), rgba(255, 226, 150, 0) 68%);
  animation: pulse-soft 2.4s ease-in-out infinite;
}
.celebrate__sticker {
  position: relative;
  width: clamp(150px, 24vh, 230px);
  animation: rise 0.6s var(--ease-out) both;
  filter: drop-shadow(0 20px 30px rgba(120, 96, 70, 0.2));
}
.celebrate h1 {
  font-size: clamp(32px, 5vw, 56px);
}
.celebrate__sub {
  font-size: var(--f-head);
  color: var(--ink-soft);
  font-weight: 700;
}
.celebrate__stars {
  display: flex;
  gap: 8px;
  font-size: clamp(38px, 6vw, 64px);
}
.celebrate__stars span { animation: pop-in 0.5s var(--ease-out) both; }
.celebrate__actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 6px;
}
.celebrate__words {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  max-width: 720px;
}
.celebrate__words span {
  padding: 8px 16px;
  border-radius: 99px;
  background: var(--surface);
  box-shadow: var(--shadow-s);
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  color: var(--ink-soft);
}

/* ============================ 贴纸册 ============================ */
.album__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(clamp(120px, 15vw, 180px), 1fr));
  gap: var(--gap);
}
.sticker-card {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 18px 12px;
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: var(--shadow-s);
  position: relative;
  animation: pop-in 0.4s var(--ease-out) both;
}
.sticker-card img { width: clamp(64px, 9vw, 92px); height: auto; }
.sticker-card b { font-size: var(--f-small); color: var(--ink-soft); }
.sticker-card small { font-size: 12px; color: var(--muted); font-weight: 700; }
.sticker-card.is-locked {
  background: #f8f3ec;
  box-shadow: none;
  filter: grayscale(1);
  opacity: 0.5;
}
.sticker-card.is-locked img { opacity: 0.35; }
.sticker-card .spark {
  position: absolute;
  top: 8px;
  right: 10px;
  color: var(--sun);
  font-size: 18px;
}

.empty {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: clamp(30px, 6vh, 60px) 20px;
  text-align: center;
}
.empty img { width: clamp(90px, 12vw, 130px); opacity: 0.8; }
.empty p { color: var(--muted); font-size: var(--f-body); }

/* ============================ 家长中心 ============================ */
.parents {
  max-width: 980px;
}
.parents__head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.parents__head h1 { font-size: clamp(26px, 3.2vw, 38px); }
.badge-soft {
  padding: 6px 14px;
  border-radius: 99px;
  background: var(--green-soft);
  color: var(--green-deep);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.06em;
}

.seg {
  display: flex;
  gap: 6px;
  padding: 6px;
  border-radius: 999px;
  background: #f6efe6;
  align-self: flex-start;
  overflow-x: auto;
  max-width: 100%;
}
.seg button {
  padding: 12px 24px;
  border-radius: 999px;
  font-size: var(--f-small);
  color: var(--ink-soft);
  white-space: nowrap;
}
.seg button[aria-selected="true"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-s);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}
.stats--four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 820px) {
  .stats--four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.stat {
  display: grid;
  gap: 4px;
  padding: 18px;
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: var(--shadow-s);
}
.stat b {
  font-family: "Nunito", sans-serif;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1;
  color: var(--ink);
}
.stat b small { font-size: 15px; color: var(--muted); margin-left: 3px; }
.stat span { font-size: var(--f-small); color: var(--muted); font-weight: 700; }

.chart {
  display: grid;
  gap: 10px;
}
.chart__bars {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: clamp(8px, 1.6vw, 20px);
  height: 180px;
  padding-top: 22px;
}
.chart__col {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.chart__bar {
  width: 100%;
  max-width: 52px;
  min-height: 6px;
  border-radius: 12px 12px 6px 6px;
  background: linear-gradient(180deg, #a6e5c6, #6ec79f);
  position: relative;
  flex: none;
}
.chart__bar[data-zero="1"] { background: #efe7dc; }
.chart__bar b {
  position: absolute;
  top: -21px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  color: var(--muted);
  font-weight: 800;
}
.chart__x { font-size: 12px; color: var(--muted); font-weight: 700; flex: none; }

.unit-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.unit-row:last-child { border-bottom: 0; }
.unit-row__ico {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--unit-soft);
}
.unit-row__ico img { width: 26px; height: 26px; }
.unit-row__body { display: grid; gap: 6px; }
.unit-row__top { display: flex; justify-content: space-between; gap: 10px; font-size: var(--f-small); }
.unit-row__top b { font-size: 15px; }
.unit-row__top span { color: var(--muted); font-weight: 700; }
.unit-row__bar {
  height: 8px;
  border-radius: 99px;
  background: #f2ece4;
  overflow: hidden;
}
.unit-row__bar span {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: var(--unit-main);
}
.unit-row__pct {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  color: var(--ink-soft);
}

.word-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--f-small);
}
.word-table th {
  text-align: left;
  font-weight: 800;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.06em;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
}
.word-table td {
  padding: 12px 8px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
  font-weight: 700;
}
.word-table tr:last-child td { border-bottom: 0; }
.word-table .en {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  color: var(--ink);
  font-size: 16px;
}
.level {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 99px;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 900;
  white-space: nowrap;
}
.level--0 { background: #f4eee7; color: var(--muted); }
.level--1 { background: #fff2d6; color: #9b6f14; }
.level--2 { background: #dcf2e6; color: #2f7f5f; }
.level--3 { background: #cdeedd; color: #216a4d; }

.recent {
  display: grid;
  gap: 8px;
}
.recent__row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: var(--f-small);
  color: var(--ink-soft);
}
.recent__row:last-child { border-bottom: 0; }
.recent__row time { color: var(--muted); font-weight: 700; font-size: 12px; }

.form {
  display: grid;
  gap: 6px;
}
.form-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.form-row:last-child { border-bottom: 0; }
.form-row__label {
  display: grid;
  gap: 3px;
  flex: 1;
  min-width: 0;
}
.form-row__label b { font-size: var(--f-body); }
.form-row__label span { font-size: 13px; color: var(--muted); font-weight: 700; line-height: 1.4; }
.form-row__control { flex: none; display: flex; align-items: center; gap: 10px; }

.input,
.select {
  height: 52px;
  padding: 0 16px;
  border-radius: 14px;
  border: 2px solid var(--line);
  background: #fffdfa;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  min-width: 180px;
}
.input:focus,
.select:focus {
  outline: none;
  border-color: var(--green);
}

.switch {
  position: relative;
  width: 64px;
  height: 38px;
  border-radius: 99px;
  background: #e8dfd4;
  transition: background var(--fast);
  flex: none;
}
.switch::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.14);
  transition: transform var(--fast) var(--ease);
}
.switch[aria-checked="true"] { background: var(--green); }
.switch[aria-checked="true"]::after { transform: translateX(26px); }

.range {
  -webkit-appearance: none;
  appearance: none;
  width: 190px;
  height: 10px;
  border-radius: 99px;
  background: #eee4d8;
  outline: none;
}
.range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  border: 4px solid var(--green);
}

.hint-box {
  display: flex;
  gap: 12px;
  padding: 16px 18px;
  border-radius: var(--r-sm);
  background: #fff8e8;
  border: 1px solid #f6e2b4;
  font-size: 14px;
  color: #8a6a1d;
  line-height: 1.6;
  font-weight: 700;
}
.hint-box b { color: #6f5413; }

/* ============================ 家长门禁 & 休息提示 ============================ */
.gate {
  position: fixed;
  inset: 0;
  z-index: 75;
  display: grid;
  place-items: center;
  background: rgba(58, 48, 70, 0.42);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fade-in 0.25s var(--ease) both;
  padding: 20px;
}
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
.gate__card {
  width: min(460px, 92vw);
  display: grid;
  gap: 14px;
  padding: 26px;
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow-l);
  animation: pop-in 0.3s var(--ease-out) both;
  text-align: center;
}
.gate__q {
  font-size: clamp(24px, 3vw, 32px);
}
.gate__q b { color: var(--green-deep); }
.gate__display {
  height: 62px;
  border-radius: 16px;
  background: #f7f2ea;
  display: grid;
  place-items: center;
  font-family: "Nunito", sans-serif;
  font-size: 30px;
  font-weight: 900;
  letter-spacing: 0.18em;
  color: var(--ink);
}
.keypad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.keypad button {
  height: 62px;
  border-radius: 16px;
  background: #f7f2ea;
  font-family: "Nunito", sans-serif;
  font-size: 24px;
  font-weight: 900;
  color: var(--ink);
  transition: transform var(--fast);
}
.keypad button:active { transform: scale(0.95); background: #efe7db; }
.keypad button.is-fn { font-size: 16px; color: var(--ink-soft); }
.gate__err {
  color: var(--coral);
  font-size: 14px;
  font-weight: 800;
  min-height: 18px;
}

.break {
  position: fixed;
  inset: 0;
  z-index: 78;
  display: grid;
  place-items: center;
  background: linear-gradient(160deg, #fff8ef, #ffeedd);
  animation: fade-in 0.4s var(--ease) both;
  padding: 24px;
}
.break__card {
  display: grid;
  justify-items: center;
  gap: 16px;
  text-align: center;
  max-width: 560px;
}
.break__card img { width: clamp(130px, 20vh, 190px); animation: bob 3s ease-in-out infinite; }
.break__card h2 { font-size: clamp(28px, 4vw, 44px); }
.break__card p { color: var(--ink-soft); font-size: var(--f-body); font-weight: 700; }

/* ============================ 响应式 ============================ */
@media (orientation: portrait) {
  .hero { grid-template-columns: minmax(0, 1fr) auto; text-align: left; gap: 8px; }
  .hero__art img { width: clamp(92px, 17vw, 132px); }
  .hero__bubble { display: none; }
  .choices { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .memory { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .word-card {
    width: min(560px, 92vw);
    grid-template-columns: 1fr;
    padding: clamp(14px, 2vw, 24px);
    gap: clamp(6px, 1vh, 12px);
  }
  .word-art { max-width: clamp(170px, 30vh, 300px); }
  .learn__actions .btn { flex: 1 1 40%; max-width: none; }
}

@media (max-height: 620px) {
  .word-en { font-size: clamp(44px, 8vw, 72px); }
  .word-art { max-width: clamp(180px, 28vh, 300px); }
  .topbar { margin-bottom: 8px; }
}

@media (max-width: 760px) {
  .hello__hi { font-size: 20px; }
  .tabbar__item { min-width: 78px; padding: 8px 10px; }
  .stat b { font-size: 26px; }
}

/* ============================ 提示条 ============================ */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--safe-b) + 28px);
  transform: translateX(-50%);
  padding: 14px 24px;
  border-radius: 999px;
  background: rgba(69, 61, 84, 0.94);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
  animation: rise 0.3s var(--ease-out) both;
  z-index: 85;
  max-width: 86vw;
  text-align: center;
}
.toast.is-out { animation: fall-away 0.24s var(--ease) forwards; }

/* 数一数：物品网格 */
.quiz__pic--count {
  display: grid;
  place-items: center;
  gap: 6px;
  width: clamp(210px, 32vh, 360px);
  aspect-ratio: 1;
}
.count-art {
  display: grid;
  justify-content: center;
  align-content: center;
  gap: 4px;
  position: relative;
  z-index: 1;
}
.count-art img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 4px 6px rgba(90, 74, 60, 0.14));
}
.count-art__hint {
  font-size: 13px;
  font-weight: 800;
  color: var(--muted);
  letter-spacing: 0.16em;
}
.choice__num {
  font-family: "Nunito", sans-serif;
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 900;
}
