/* 喵喵语音小屋 */

:root {
  --bg: #fff8fb;
  --panel: rgba(255,255,255,0.86);
  --text: #4b3f57;
  --muted: #8c7c99;
  --pink: #ff8fcb;
  --peach: #ffbc6d;
  --mint: #9ee7d8;
  --shadow: 0 18px 50px rgba(173, 120, 151, 0.18);
  --transition: cubic-bezier(.2,.85,.2,1);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: 'Nunito', sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top, #fff 0%, #fff5fa 35%, #ffeef7 100%);
  overflow-x: hidden;
}

.sky-bg {
  position: fixed; inset: 0; z-index: -2;
  background-color: #fff7fb;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  transition: background-image 0.35s ease, background-color 0.35s ease;
}
.sky-bg.bg-mode-intro {
  background-image: url('../assets/backgrounds/intro-play-bg.svg');
  background-color: #fff0f7;
}
.sky-bg.bg-mode-home {
  background-image: url('../assets/backgrounds/home-bg.svg');
  background-color: #fff9fc;
}
.sky-bg.bg-mode-chat {
  background-image: url('../assets/backgrounds/chat-bg.svg');
  background-color: #fffaf3;
}
.sky-bg.bg-mode-jump {
  background-image: url('../assets/backgrounds/jump-bg.svg');
  background-color: #fff8fc;
}
.sky-bg.bg-mode-default {
  background-image: linear-gradient(135deg, #fffdf8 0%, #ffeef7 45%, #eefaff 100%);
}

.floating-hearts::before, .floating-hearts::after {
  content: '🐾'; position: fixed; font-size: 22px; opacity: .18; animation: floaty 10s linear infinite;
}
.floating-hearts::after { left: 80%; top: 20%; animation-duration: 14s; }
@keyframes floaty { from { transform: translateY(110vh) rotate(0deg);} to { transform: translateY(-10vh) rotate(360deg);} }

.intro-overlay {
  position: fixed; inset: 0; z-index: 50;
  display: grid; place-items: center center;
  padding: clamp(24px, 6vh, 48px);
  background-image: url('../assets/backgrounds/intro-play-bg.svg');
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  background-color: #fff0f7;
  overflow: hidden;
}
.intro-overlay.hidden { display: none; }

/* 开场：猫咪屋内 + 地面玩耍 */
.intro-play-scene {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

/* ambient particles in sunbeam */
.intro-ambient { position: absolute; inset: 0; }
.dust {
  position: absolute; width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.75);
  box-shadow: 0 0 8px rgba(255, 244, 180, 0.8);
}
.dust-1 { left: 8%; top: 28%; animation: dustFloat 7s ease-in-out infinite; }
.dust-2 { left: 14%; top: 42%; animation: dustFloat 9s ease-in-out infinite 1s; }
.dust-3 { left: 6%; top: 55%; animation: dustFloat 8s ease-in-out infinite 2s; }
.dust-4 { left: 18%; top: 35%; animation: dustFloat 6s ease-in-out infinite 0.5s; width: 4px; height: 4px; }
.dust-5 { left: 12%; top: 48%; animation: dustFloat 10s ease-in-out infinite 1.5s; width: 5px; height: 5px; }
@keyframes dustFloat {
  0%, 100% { transform: translate(0, 0); opacity: 0.35; }
  50% { transform: translate(18px, -24px); opacity: 0.9; }
}

.room-prop { position: absolute; pointer-events: none; }
.room-lamp-glow {
  left: 62%; top: 14%; width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 244, 180, 0.35) 0%, transparent 70%);
  animation: lampGlow 3s ease-in-out infinite;
}
@keyframes lampGlow {
  0%, 100% { opacity: 0.6; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}
.room-fish-bowl {
  left: 42%; top: 36%; width: 56px; height: 40px;
}
.room-fish-bowl .fish {
  position: absolute; font-size: 0.85rem; opacity: 0.85;
}
.room-fish-bowl .fish-a { left: 4px; top: 12px; animation: fishSwim 4s ease-in-out infinite; }
.room-fish-bowl .fish-b { left: 22px; top: 18px; font-size: 0.7rem; animation: fishSwim 5s ease-in-out infinite reverse 0.8s; }
@keyframes fishSwim {
  0%, 100% { transform: translateX(0) scaleX(1); }
  50% { transform: translateX(14px) scaleX(-1); }
}
.room-hanging-toy {
  right: 22%; top: 18%; width: 40px; height: 100px;
  transform-origin: top center;
  animation: toySwing 2.2s ease-in-out infinite;
}
.toy-string {
  position: absolute; left: 50%; top: 0; width: 2px; height: 72px;
  background: #c89563; transform: translateX(-50%);
}
.toy-ball-hang {
  position: absolute; left: 50%; top: 68px; transform: translateX(-50%);
  font-size: 1.1rem;
}
@keyframes toySwing {
  0%, 100% { transform: rotate(-10deg); }
  50% { transform: rotate(10deg); }
}

.room-cat-cushion {
  left: 52%; top: 44%;
  width: clamp(50px, 7vw, 76px);
  animation: roomCatCushion 6s ease-in-out infinite;
}
@keyframes roomCatCushion {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-5px) rotate(2deg); }
}

.room-cat {
  position: absolute;
  filter: drop-shadow(0 10px 16px rgba(106, 80, 64, 0.18));
}
.room-cat img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}
.room-cat-tree {
  right: 14%;
  top: 28%;
  width: clamp(72px, 11vw, 110px);
  animation: roomCatPerch 4s ease-in-out infinite;
}
.room-cat-shelf {
  left: 26%;
  top: 22%;
  width: clamp(56px, 8vw, 84px);
  animation: roomCatShelf 5s ease-in-out infinite;
}

.play-cat {
  position: absolute;
  bottom: 14%;
  width: clamp(72px, 11vw, 108px);
  transform-origin: center bottom;
  filter: drop-shadow(0 10px 16px rgba(106, 80, 64, 0.2));
}
.play-cat img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
  pointer-events: none;
}
.play-cat-1 { left: 6%; animation: catRunLeft 4.2s ease-in-out infinite; }
.play-cat-2 { left: 26%; animation: catPounce 1.8s ease-in-out infinite; }
.play-cat-3 { left: 46%; animation: catRoll 3.6s ease-in-out infinite; }
.play-cat-4 { left: 64%; animation: catChase 5s linear infinite; }
.play-cat-5 { left: 82%; animation: catBat 1.2s ease-in-out infinite; }

@keyframes roomCatPerch {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-6px) rotate(-3deg); }
}
@keyframes roomCatShelf {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-4px) scale(1.02); }
}

.play-yarn {
  position: absolute; left: 72%; top: 58%; width: 22px; height: 22px;
  background: radial-gradient(circle at 35% 35%, #ffb8cc, #ff7d95);
  border-radius: 50%; border: 2px solid #e86b88;
  animation: yarnBounce 1.8s ease-in-out infinite;
}
.play-yarn-2 {
  left: 88%; top: 72%; width: 16px; height: 16px;
  background: radial-gradient(circle at 35% 35%, #b8e6ff, #6eb5ff);
  border-color: #4f97e6;
  animation: yarnBounce 2.2s ease-in-out infinite 0.4s;
}
.play-feather {
  position: absolute; right: -18px; top: 10%;
  font-size: 1.4rem;
  animation: featherFloat 2.2s ease-in-out infinite;
}
.play-toy {
  position: absolute; border-radius: 50%;
}
.play-toy-a {
  width: 18px; height: 18px; left: 22%; bottom: 22%;
  background: #6eb5ff; border: 2px solid #4f97e6;
  animation: toyRoll 6s linear infinite;
}
.play-toy-b {
  width: 16px; height: 16px; left: 55%; bottom: 20%;
  background: #ffd35a; border: 2px solid #efb73a;
  animation: toyRoll 4.5s linear infinite reverse;
}
.play-toy-c {
  width: 14px; height: 14px; left: 38%; bottom: 24%;
  background: #9ee7d8; border: 2px solid #58c9b0;
  animation: toyRoll 5.5s linear infinite;
}
.play-mouse {
  left: 72%; bottom: 26%; font-size: 1.2rem;
  animation: mouseScurry 3.5s ease-in-out infinite;
}
@keyframes mouseScurry {
  0%, 100% { transform: translate(0, 0); }
  40% { transform: translate(-40px, -6px); }
  60% { transform: translate(-60px, 0) scaleX(-1); }
}
.play-spark {
  position: absolute; font-size: 1.1rem; opacity: 0.55;
}
.play-spark-1 { left: 14%; bottom: 44%; animation: sparkPop 2.4s ease-in-out infinite; }
.play-spark-2 { left: 32%; bottom: 48%; animation: sparkPop 3s ease-in-out infinite 0.5s; }
.play-spark-3 { left: 58%; bottom: 42%; animation: sparkPop 2.8s ease-in-out infinite 1s; }
.play-spark-4 { left: 78%; bottom: 46%; animation: sparkPop 3.2s ease-in-out infinite 0.3s; }
.play-spark-5 { left: 90%; bottom: 38%; animation: sparkPop 2.6s ease-in-out infinite 1.2s; }

@keyframes catRunLeft {
  0%, 100% { transform: translate(0, 0) scaleX(1); }
  45% { transform: translate(120px, -8px) scaleX(1); }
  50% { transform: translate(130px, -8px) scaleX(-1); }
  95% { transform: translate(0, 0) scaleX(-1); }
}
@keyframes catPounce {
  0%, 100% { transform: translateY(0) scale(1); }
  20% { transform: translateY(-28px) scale(1.05); }
  40% { transform: translateY(0) scale(0.96); }
  55% { transform: translateY(-18px) scale(1.03); }
  70% { transform: translateY(0) scale(1); }
}
@keyframes catRoll {
  0%, 100% { transform: rotate(0deg) translateY(0); }
  25% { transform: rotate(-24deg) translateY(-6px); }
  50% { transform: rotate(0deg) translateY(0); }
  75% { transform: rotate(24deg) translateY(-6px); }
}
@keyframes catChase {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-80px, -12px); }
  50% { transform: translate(-40px, 4px) scaleX(-1); }
  75% { transform: translate(20px, -8px) scaleX(-1); }
  100% { transform: translate(0, 0) scaleX(1); }
}
@keyframes catBat {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-10px) scale(1.03); }
}
@keyframes yarnBounce {
  0%, 100% { transform: translate(0, 0); }
  30% { transform: translate(-8px, -14px); }
  60% { transform: translate(4px, 0); }
}
@keyframes featherFloat {
  0%, 100% { transform: translate(0, 0) rotate(-10deg); }
  50% { transform: translate(12px, -20px) rotate(15deg); }
}
@keyframes toyRoll {
  0% { transform: translateX(0) rotate(0deg); }
  100% { transform: translateX(160px) rotate(360deg); }
}
@keyframes sparkPop {
  0%, 100% { transform: scale(0.8); opacity: 0.25; }
  50% { transform: scale(1.15) translateY(-8px); opacity: 0.7; }
}

@media (max-width: 768px) {
  .play-cat { width: 58px; bottom: 16%; }
  .play-cat-1 { left: 0; }
  .play-cat-2 { left: 18%; }
  .play-cat-3 { left: 36%; }
  .play-cat-4 { left: 54%; }
  .play-cat-5 { left: 72%; }
  .room-cat-tree { right: 4%; top: 28%; width: 52px; }
  .room-cat-shelf { left: 14%; top: 22%; width: 44px; }
  .room-cat-cushion { left: 48%; top: 46%; width: 44px; }
  .room-fish-bowl { left: 38%; top: 38%; transform: scale(0.85); }
  .room-hanging-toy { right: 10%; top: 16%; transform: scale(0.85); }
  .intro-screen { padding: 18px 16px 22px; }
}

.intro-screen {
  position: relative;
  z-index: 1;
  width: min(92vw, 520px);
  text-align: center;
  padding: 22px 20px 28px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 18px 48px rgba(173, 120, 151, 0.18);
}
.intro-badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 143, 203, 0.15);
  color: #b07a93;
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 10px;
}
.intro-title {
  font-family: 'ZCOOL KuaiLe', cursive;
  font-size: clamp(34px, 7vw, 52px);
  color: #f07a3a;
  margin-bottom: 10px;
  text-shadow: 0 2px 0 #fff;
}
.intro-copy {
  color: var(--muted);
  margin: 0 0 14px;
  line-height: 1.65;
  font-size: 1rem;
}
.intro-mic-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 2px solid rgba(255, 143, 203, 0.45);
  background: rgba(255, 255, 255, 0.92);
  color: #b07a93;
  font-weight: 800;
  box-shadow: 0 8px 22px rgba(255, 143, 203, 0.18);
}
.intro-mic-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 143, 203, 0.75);
}
.intro-mic-btn.mic-granted {
  border-color: rgba(158, 231, 216, 0.85);
  background: rgba(232, 255, 248, 0.95);
  color: #4a9a86;
  box-shadow: 0 8px 22px rgba(158, 231, 216, 0.25);
}
.intro-mic-hint {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}
.intro-enter-btn {
  font-size: 1.15rem;
  padding: 16px 42px;
  box-shadow: 0 14px 32px rgba(255, 120, 80, 0.35);
}

body.intro-active .topbar,
body.intro-active .app-shell,
body.intro-active .floating-hearts,
body.intro-active .scene-particles {
  visibility: hidden;
  pointer-events: none;
}

.enter-btn, .primary-btn, .secondary-btn, .soft-btn, .nav-card, .back-btn, .mic-btn {
  border: none; cursor: pointer; transition: .22s ease; font: inherit;
}
.enter-btn, .primary-btn {
  background: linear-gradient(135deg, var(--pink), var(--peach)); color: white; border-radius: 999px; padding: 14px 22px;
  box-shadow: 0 10px 24px rgba(255, 143, 203, .35);
}
.enter-btn:hover, .primary-btn:hover, .nav-card:hover, .soft-btn:hover, .secondary-btn:hover, .back-btn:hover {
  transform: translateY(-2px) scale(1.02); filter: brightness(1.03);
}

.topbar {
  position: sticky; top: 0; z-index: 20; display: flex; justify-content: space-between; gap: 14px; align-items: center;
  padding: 14px 20px; background: rgba(255,255,255,.88); border-bottom: 1px solid rgba(255,255,255,.9);
  box-shadow: 0 4px 18px rgba(173, 120, 151, 0.08);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-mark { font-size: 1.7rem; }
.brand-title { font-weight: 800; }
.brand-subtitle, .hero-text, .module-status, .quiz-topline { color: var(--muted); }
.topbar-stats { display: flex; gap: 8px; flex-wrap: wrap; }
.stat-pill { background: rgba(255,255,255,.85); border-radius: 999px; padding: 8px 12px; box-shadow: 0 6px 18px rgba(0,0,0,.04); }
.stat-pill-intimacy {
  background: linear-gradient(135deg, rgba(255, 240, 248, 0.95), rgba(255, 232, 210, 0.95));
  color: #b07a93;
}

.app-shell { width: min(1180px, 94vw); margin: 22px auto 48px; }
.panel { display: none; background: var(--panel); border-radius: 28px; padding: 26px; box-shadow: var(--shadow); }
.panel-bg-home {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 12px 36px rgba(173, 120, 151, 0.12);
}
.panel-bg-home::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 214, 234, 0.28) 0%, transparent 42%),
    radial-gradient(circle at 82% 18%, rgba(255, 244, 201, 0.22) 0%, transparent 38%),
    radial-gradient(circle at 50% 88%, rgba(255, 184, 212, 0.18) 0%, transparent 45%);
  z-index: 0;
}
.panel-bg-home > * { position: relative; z-index: 1; }
.panel-bg-chat {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 36px rgba(173, 120, 151, 0.1);
}
.panel-bg-chat::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 20%, rgba(255, 214, 234, 0.26) 0%, transparent 42%),
    radial-gradient(circle at 88% 16%, rgba(255, 244, 201, 0.2) 0%, transparent 38%),
    radial-gradient(circle at 50% 92%, rgba(255, 184, 212, 0.16) 0%, transparent 45%);
  z-index: 0;
}
.panel-bg-chat > *:not(.chat-room-deco) { position: relative; z-index: 1; }

/* 对话页装饰：聊天气泡、麦克风、声波 */
.chat-room-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.chat-deco-bubble {
  position: absolute;
  max-width: 120px;
  padding: 8px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  border: 1.5px solid rgba(255, 184, 212, 0.55);
  color: #b07a93;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.4;
  box-shadow: 0 8px 20px rgba(255, 158, 198, 0.12);
  animation: chatDecoFloat 4.5s ease-in-out infinite;
}
.chat-deco-bubble-1 { top: 8%; left: 4%; animation-delay: 0s; }
.chat-deco-bubble-2 { top: 14%; right: 3%; animation-delay: 0.6s; }
.chat-deco-bubble-3 { bottom: 22%; left: 6%; animation-delay: 1.2s; font-size: 0.7rem; }
.chat-deco-icon {
  position: absolute;
  font-size: 1.35rem;
  opacity: 0.28;
  animation: chatDecoFloat 5s ease-in-out infinite;
}
.chat-deco-mic { top: 42%; right: 5%; animation-delay: 0.3s; opacity: 0.22; font-size: 1.6rem; }
.chat-deco-heart { bottom: 18%; right: 8%; animation-delay: 0.9s; }
.chat-deco-paw { top: 36%; left: 7%; animation-delay: 1.5s; }
.chat-deco-waves {
  position: absolute;
  bottom: 12%;
  right: 14%;
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 36px;
  opacity: 0.35;
}
.chat-deco-waves span {
  width: 5px;
  border-radius: 999px;
  background: linear-gradient(180deg, #ff8fcb, #ffb65b);
  animation: chatDecoWave 1.2s ease-in-out infinite;
}
.chat-deco-waves span:nth-child(1) { height: 12px; animation-delay: 0s; }
.chat-deco-waves span:nth-child(2) { height: 22px; animation-delay: 0.15s; }
.chat-deco-waves span:nth-child(3) { height: 32px; animation-delay: 0.3s; }
.chat-deco-waves span:nth-child(4) { height: 20px; animation-delay: 0.45s; }
.chat-deco-waves span:nth-child(5) { height: 14px; animation-delay: 0.6s; }
@keyframes chatDecoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
@keyframes chatDecoWave {
  0%, 100% { transform: scaleY(0.55); opacity: 0.45; }
  50% { transform: scaleY(1); opacity: 0.85; }
}

.hero-overlay {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 22px;
  padding: 18px 16px;
  margin-bottom: 8px;
  border: 1px solid rgba(255, 255, 255, 0.95);
}
.home-hero {
  margin-bottom: 4px;
  padding: 16px 16px 12px;
  background: rgba(255, 255, 255, 0.68);
}
.home-mode-hint {
  margin: 14px 0 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.55;
}

/* 主菜单：小猫撒娇邀请场景 */
.home-invite-scene {
  position: relative;
  width: 100%;
  min-height: clamp(200px, 32vw, 280px);
  margin: 8px 0 4px;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 248, 252, 0.55) 0%, rgba(255, 230, 244, 0.45) 100%);
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 10px 28px rgba(255, 158, 198, 0.1);
}
.home-invite-glow {
  position: absolute;
  inset: 8% 10% auto;
  height: 55%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 244, 201, 0.45) 0%, transparent 70%);
  pointer-events: none;
  animation: inviteGlow 4s ease-in-out infinite;
}
@keyframes inviteGlow {
  0%, 100% { opacity: 0.65; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.04); }
}
.home-invite-rug {
  position: absolute;
  left: 50%;
  bottom: 8%;
  width: min(88%, 680px);
  height: 38%;
  transform: translateX(-50%);
  border-radius: 50%;
  background:
    radial-gradient(ellipse at center, rgba(255, 217, 234, 0.75) 0%, rgba(255, 240, 248, 0.35) 68%, transparent 72%);
  pointer-events: none;
}
.home-invite-sparks {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.invite-spark {
  position: absolute;
  font-size: clamp(0.85rem, 2vw, 1.1rem);
  opacity: 0.45;
}
.invite-spark-1 { left: 8%; top: 18%; animation: inviteSpark 3.2s ease-in-out infinite; }
.invite-spark-2 { left: 22%; top: 62%; animation: inviteSpark 2.8s ease-in-out infinite 0.4s; }
.invite-spark-3 { left: 50%; top: 12%; animation: inviteSpark 3.5s ease-in-out infinite 0.8s; }
.invite-spark-4 { right: 18%; top: 24%; animation: inviteSpark 3s ease-in-out infinite 0.2s; }
.invite-spark-5 { right: 8%; top: 58%; animation: inviteSpark 2.6s ease-in-out infinite 1s; }
@keyframes inviteSpark {
  0%, 100% { transform: translateY(0) scale(0.85); opacity: 0.25; }
  50% { transform: translateY(-10px) scale(1.1); opacity: 0.75; }
}

.home-invite-cats {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: clamp(6px, 2.5vw, 28px);
  min-height: clamp(200px, 32vw, 280px);
  padding: 18px clamp(8px, 2vw, 24px) 16px;
}
.invite-cat {
  position: relative;
  flex: 0 1 clamp(72px, 16vw, 120px);
  display: flex;
  flex-direction: column;
  align-items: center;
  filter: drop-shadow(0 10px 16px rgba(106, 80, 64, 0.18));
}
.invite-cat img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}
.invite-bubble {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.95);
  border: 2px solid rgba(255, 184, 212, 0.65);
  color: #b07a93;
  font-size: clamp(0.68rem, 1.8vw, 0.82rem);
  font-weight: 700;
  box-shadow: 0 6px 16px rgba(255, 158, 198, 0.18);
  animation: inviteBubble 2.8s ease-in-out infinite;
}
.invite-bubble::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -7px;
  width: 10px;
  height: 10px;
  background: rgba(255, 255, 255, 0.95);
  border-right: 2px solid rgba(255, 184, 212, 0.65);
  border-bottom: 2px solid rgba(255, 184, 212, 0.65);
  transform: translateX(-50%) rotate(45deg);
}
.invite-bubble-1 { animation-delay: 0s; }
.invite-bubble-2 { animation-delay: 0.35s; }
.invite-bubble-3 { animation-delay: 0.7s; }
.invite-bubble-4 { animation-delay: 1.05s; }
@keyframes inviteBubble {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-6px); }
}

.invite-cat-1 { animation: inviteHeadTilt 3.2s ease-in-out infinite; padding-top: 34px; }
.invite-cat-2 { animation: inviteBeg 2.6s ease-in-out infinite 0.3s; padding-top: 38px; }
.invite-cat-3 { animation: invitePawWave 2.4s ease-in-out infinite 0.15s; padding-top: 36px; }
.invite-cat-4 { animation: inviteStretch 3s ease-in-out infinite 0.5s; padding-top: 40px; }

@keyframes inviteHeadTilt {
  0%, 100% { transform: rotate(0deg) translateY(0); }
  35% { transform: rotate(-8deg) translateY(-4px); }
  65% { transform: rotate(6deg) translateY(-2px); }
}
@keyframes inviteBeg {
  0%, 100% { transform: rotate(0deg) translateY(0) scale(1); }
  30% { transform: rotate(-12deg) translateY(6px) scale(0.96); }
  55% { transform: rotate(8deg) translateY(-8px) scale(1.03); }
}
@keyframes invitePawWave {
  0%, 100% { transform: translateY(0); }
  40% { transform: translateY(-10px) rotate(-2deg); }
  60% { transform: translateY(-6px) rotate(2deg); }
}
@keyframes inviteStretch {
  0%, 100% { transform: translateY(0) scale(1); }
  45% { transform: translateY(-12px) scale(1.04); }
}

.invite-paw {
  position: absolute;
  font-size: clamp(0.9rem, 2.2vw, 1.15rem);
  opacity: 0.85;
  pointer-events: none;
}
.invite-paw-1 {
  right: -4px;
  top: 48%;
  animation: invitePawPop 1.6s ease-in-out infinite;
}
.invite-paw-2 {
  left: -2px;
  top: 42%;
  animation: invitePawPop 1.8s ease-in-out infinite 0.5s;
}
@keyframes invitePawPop {
  0%, 100% { transform: rotate(0deg) scale(0.85); opacity: 0.35; }
  50% { transform: rotate(-18deg) scale(1.15); opacity: 1; }
}

.home-invite-toys {
  position: absolute;
  inset: auto 0 10px;
  height: 36px;
  pointer-events: none;
}
.invite-toy {
  position: absolute;
  bottom: 0;
}
.invite-toy-yarn {
  left: 12%;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #ffb8cc, #ff7d95);
  border: 2px solid #e86b88;
  animation: inviteToyRoll 5s linear infinite;
}
.invite-toy-fish {
  left: 50%;
  transform: translateX(-50%);
  font-size: 1rem;
  animation: inviteFishWiggle 2.2s ease-in-out infinite;
}
.invite-toy-ball {
  right: 14%;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #6eb5ff;
  border: 2px solid #4f97e6;
  animation: inviteToyRoll 4s linear infinite reverse;
}
@keyframes inviteToyRoll {
  0% { transform: translateX(0) rotate(0deg); }
  100% { transform: translateX(48px) rotate(360deg); }
}
@keyframes inviteFishWiggle {
  0%, 100% { transform: translateX(-50%) rotate(-8deg); }
  50% { transform: translateX(-50%) rotate(8deg) translateY(-4px); }
}

.panel-bg-home .nav-grid { margin-top: 18px; }
.chat-hero-text {
  background: rgba(255, 255, 255, 0.78);
  border-radius: 18px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 22px rgba(255, 158, 198, 0.08);
}
.panel.active { display: block; animation: panelIn .7s var(--transition); }
@keyframes panelIn { from{ opacity:0; transform: translateY(20px) scale(.985)} to {opacity:1; transform: translateY(0) scale(1)} }

.hero, .module-hero { display: grid; gap: 10px; text-align: center; justify-items: center; }
.module-hero.compact {
  grid-template-columns: auto 1fr; justify-items: start; text-align: left; align-items: center; gap: 16px;
}
.hero-cat-wrap { display: grid; place-items: center; margin-bottom: 4px; }
.hero-title, .module-hero h1 { font-family: 'ZCOOL KuaiLe', cursive; font-size: clamp(28px, 5vw, 44px); margin: 0; }

.cat-avatar {
  width: 200px; height: 200px; position: relative; display: grid; place-items: center;
  animation: catFloat 4.8s ease-in-out infinite;
}
.cat-avatar.small { width: 88px; height: 88px; animation: none; }
.cat-avatar .cat-emoji { font-size: clamp(72px, 14vw, 108px); line-height: 1; z-index: 1; filter: drop-shadow(0 12px 20px rgba(255,143,203,.25)); }
.cat-avatar.small .cat-emoji { font-size: 52px; }
.cat-avatar .cat-glow {
  position: absolute; inset: 8px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.9) 0%, rgba(255,224,240,.35) 55%, transparent 72%);
}
.cat-avatar.cat-spin { animation: catFloat 4.8s ease-in-out infinite; }
@keyframes catFloat { 0%,100%{ transform: translateY(0) } 50%{ transform: translateY(-10px) } }
.cat-avatar.cat-listening .cat-emoji { animation: catListen 0.9s ease-in-out infinite; }
.cat-avatar.cat-recording .cat-emoji { animation: catRecord 0.7s ease-in-out infinite; }
.cat-avatar.cat-happy .cat-emoji { animation: catHappy 0.55s ease-in-out infinite; }
.cat-avatar.cat-sad .cat-emoji { filter: grayscale(0.2) brightness(0.92); }
.cat-avatar.cat-angry .cat-emoji { animation: catAngry 0.35s ease-in-out infinite; }
@keyframes catListen { 0%,100%{ transform: translateY(0) rotate(0deg);} 50%{ transform: translateY(-4px) rotate(-1deg);} }
@keyframes catRecord { 0%,100%{ transform: scale(1);} 50%{ transform: scale(1.03);} }
@keyframes catHappy { 0%,100%{ transform: translateY(0) scale(1);} 50%{ transform: translateY(-5px) scale(1.03);} }
@keyframes catAngry { 0%,100%{ transform: rotate(0); } 25%{ transform: rotate(-6deg); } 75%{ transform: rotate(6deg); } }

.nav-grid, .quiz-options { display: grid; gap: 14px; }
.nav-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 26px; }
.nav-grid-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.nav-card {
  background: rgba(255,255,255,.9); border-radius: 24px; padding: 22px; text-align: left; box-shadow: 0 12px 34px rgba(183, 123, 159, .13);
  min-height: 180px; position: relative; overflow: hidden;
}
.nav-card-main { min-height: 220px; }
.nav-card::after { content: '✨'; position: absolute; right: 16px; top: 16px; opacity: .42; }
.nav-card:hover { box-shadow: 0 16px 40px rgba(255,143,203,.22); transform: translateY(-3px) scale(1.03); }
.nav-card:hover .nav-emoji { transform: scale(1.12); filter: drop-shadow(0 0 10px rgba(255,143,203,.5)); }
.nav-emoji { font-size: 2rem; transition: .22s ease; }
.nav-card h2 { margin: 12px 0 8px; font-size: 1.15rem; }
.nav-card p { margin: 0; color: var(--muted); }
.nav-tag {
  display: inline-block; margin-top: 14px; padding: 6px 12px; border-radius: 999px;
  background: linear-gradient(135deg, rgba(255,143,203,.15), rgba(255,182,91,.15));
  color: var(--muted); font-size: .85rem; font-weight: 700;
}

.module-screen { margin-top: 18px; }
.back-btn { background: rgba(255,255,255,.8); border-radius: 999px; padding: 10px 14px; margin-bottom: 16px; }
.module-hero { margin-bottom: 18px; }
.chat-hero { margin-bottom: 10px; }

/* 对话页小猫场景 */
.cat-scene {
  position: relative;
  width: min(320px, 78vw);
  height: min(320px, 78vw);
  margin: 0 auto 8px;
}
.cat-character {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
}
.cat-main-image {
  width: 78%;
  height: auto;
  object-fit: contain;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 14px 24px rgba(255, 170, 120, 0.22));
  animation: catIdleFloat 4.5s ease-in-out infinite;
  transform-origin: 68% 88%;
}
@keyframes catIdleFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-6px) rotate(0deg); }
}

/* 长按麦克风：小猫左右摇摆 + 回声波纹 */
.cat-echo-ripples {
  position: absolute;
  inset: -10%;
  display: grid;
  place-items: center;
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.cat-scene.cat-listening .cat-echo-ripples {
  opacity: 1;
}
.echo-ring {
  position: absolute;
  width: 62%;
  aspect-ratio: 1.12;
  border-radius: 50%;
  border: 3px solid rgba(255, 143, 203, 0.68);
  background: radial-gradient(circle, rgba(255, 190, 220, 0.14) 0%, rgba(255, 190, 220, 0.04) 45%, transparent 72%);
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.45),
    0 0 32px rgba(255, 143, 203, 0.38),
    0 0 64px rgba(255, 176, 210, 0.22);
  opacity: 0;
  animation: echoRipple var(--echo-speed, 2.2s) ease-out infinite;
}
.echo-ring-1 { animation-delay: 0s; }
.echo-ring-2 { animation-delay: calc(var(--echo-speed, 2.2s) * 0.28); }
.echo-ring-3 { animation-delay: calc(var(--echo-speed, 2.2s) * 0.56); }
.echo-ring-4 { animation-delay: calc(var(--echo-speed, 2.2s) * 0.84); }
@keyframes echoRipple {
  0% {
    transform: scale(0.52) scaleX(0.94);
    opacity: 0.9;
  }
  100% {
    transform: scale(2.05) scaleX(1.15);
    opacity: 0;
  }
}

.hint-bubbles {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
}
.hint-bubble {
  position: absolute;
  max-width: 118px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 16px;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--text);
  box-shadow: 0 10px 24px rgba(173, 120, 151, 0.16);
  border: 1px solid rgba(255, 143, 203, 0.25);
  animation: hintFloat 3.2s ease-in-out infinite;
}
.hint-bubble::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  background: inherit;
  transform: rotate(45deg);
  border: inherit;
  border-top: none;
  border-left: none;
}
.hint-bubble-1 { top: 4%; left: -4%; animation-delay: 0s; }
.hint-bubble-1::after { right: 18px; bottom: -5px; }
.hint-bubble-2 { top: 8%; right: -6%; animation-delay: 0.4s; }
.hint-bubble-2::after { left: 18px; bottom: -5px; }
.hint-bubble-3 { bottom: 18%; left: -8%; animation-delay: 0.8s; }
.hint-bubble-3::after { right: 20px; top: -5px; }
.hint-bubble-4 { bottom: 14%; right: -8%; animation-delay: 1.2s; }
.hint-bubble-4::after { left: 20px; top: -5px; }
@keyframes hintFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
.hint-bubbles.hidden { display: none; }

.cat-scene.cat-listening .cat-main-image {
  animation: catListenSway var(--listen-sway-speed, 1.1s) ease-in-out infinite;
}
@keyframes catListenSway {
  0%, 100% {
    transform: rotate(calc(-1 * var(--sway-deg, 7deg))) translateX(-8px);
  }
  50% {
    transform: rotate(var(--sway-deg, 7deg)) translateX(8px);
  }
}
.cat-scene.cat-happy .cat-main-image {
  animation: catHappyBounce 0.55s ease-in-out infinite;
}
@keyframes catHappyBounce {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-8px) scale(1.03); }
}

.video-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(30, 20, 35, 0.72);
  display: grid;
  place-items: center;
  padding: 20px;
}
.video-modal {
  width: min(92vw, 440px);
  margin: 0 auto;
  background: #fff;
  border-radius: 22px;
  padding: 16px;
  box-shadow: var(--shadow);
  position: relative;
}
.video-square {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
}
.video-square video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}
.video-close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  z-index: 2;
  line-height: 1;
}
.video-caption {
  margin-top: 10px;
  text-align: center;
  color: var(--muted);
  font-size: 0.95rem;
}

.mic-ready { box-shadow: 0 0 0 3px rgba(158, 231, 216, 0.55), 0 16px 30px rgba(255,127,181,.35); }
.mic-denied { opacity: 0.75; }

/* 声音闯关 */
.panel-bg-jump {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 36px rgba(173, 120, 151, 0.1);
}
.panel-bg-jump::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 14% 18%, rgba(255, 214, 234, 0.24) 0%, transparent 42%),
    radial-gradient(circle at 86% 14%, rgba(255, 244, 201, 0.22) 0%, transparent 38%),
    radial-gradient(circle at 50% 95%, rgba(255, 200, 150, 0.18) 0%, transparent 45%);
  z-index: 0;
}
.panel-bg-jump > *:not(.jump-room-deco) { position: relative; z-index: 1; }

.jump-room-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.jump-deco-badge {
  position: absolute;
  top: 10%;
  left: 4%;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  border: 1.5px solid rgba(255, 184, 212, 0.55);
  color: #f07a3a;
  font-size: 0.75rem;
  font-weight: 800;
  animation: jumpDecoFloat 4s ease-in-out infinite;
}
.jump-deco-fish {
  position: absolute;
  font-size: 1.5rem;
  opacity: 0.32;
  animation: jumpDecoFloat 3.8s ease-in-out infinite;
}
.jump-deco-fish-1 { top: 18%; right: 6%; animation-delay: 0.2s; }
.jump-deco-fish-2 { bottom: 24%; left: 5%; font-size: 1.25rem; animation-delay: 0.8s; }
.jump-deco-icon {
  position: absolute;
  font-size: 1.3rem;
  opacity: 0.26;
  animation: jumpDecoFloat 5s ease-in-out infinite;
}
.jump-deco-star { top: 38%; left: 6%; animation-delay: 0.4s; }
.jump-deco-trophy { top: 12%; right: 18%; animation-delay: 1s; }
.jump-deco-paw { bottom: 16%; right: 8%; animation-delay: 1.4s; }
.jump-deco-hint {
  position: absolute;
  bottom: 10%;
  right: 5%;
  padding: 6px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 184, 212, 0.45);
  color: #b07a93;
  font-size: 0.72rem;
  font-weight: 700;
  animation: jumpDecoFloat 4.2s ease-in-out infinite 0.5s;
}
.jump-deco-waves {
  position: absolute;
  top: 42%;
  right: 4%;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 32px;
  opacity: 0.38;
}
.jump-deco-waves span {
  width: 5px;
  border-radius: 999px;
  background: linear-gradient(180deg, #ff8fcb, #ffd35a);
  animation: jumpDecoWave 1s ease-in-out infinite;
}
.jump-deco-waves span:nth-child(1) { height: 10px; }
.jump-deco-waves span:nth-child(2) { height: 18px; animation-delay: 0.12s; }
.jump-deco-waves span:nth-child(3) { height: 28px; animation-delay: 0.24s; }
.jump-deco-waves span:nth-child(4) { height: 16px; animation-delay: 0.36s; }
.jump-deco-waves span:nth-child(5) { height: 12px; animation-delay: 0.48s; }
@keyframes jumpDecoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}
@keyframes jumpDecoWave {
  0%, 100% { transform: scaleY(0.5); opacity: 0.4; }
  50% { transform: scaleY(1); opacity: 0.9; }
}

.jump-header {
  text-align: center;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, 0.72);
  border-radius: 18px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 20px rgba(255, 158, 198, 0.08);
}
.jump-header h1 { font-family: 'ZCOOL KuaiLe', cursive; margin: 0 0 8px; }
.jump-header p { color: var(--muted); margin: 0; }
.jump-hud {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  background: rgba(255,255,255,0.88); border-radius: 16px; padding: 12px 16px; margin-bottom: 12px;
}
.volume-bar {
  flex: 1; min-width: 120px; height: 14px; background: #ffe8f3; border-radius: 999px; overflow: hidden;
}
.volume-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, #9ee7d8, #ff8fcb, #ffbc6d);
  transition: width 0.08s linear;
  border-radius: 999px;
}
.jump-stage-wrap {
  background: rgba(255, 255, 255, 0.55);
  border-radius: 20px;
  padding: 10px;
  overflow: hidden;
  box-shadow:
    inset 0 0 0 1px rgba(255, 143, 203, 0.18),
    0 10px 28px rgba(255, 158, 198, 0.1);
}
#jumpCanvas {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 14px;
}
.jump-controls { display: flex; justify-content: center; gap: 10px; margin-top: 14px; flex-wrap: wrap; }

.win-overlay {
  position: fixed; inset: 0; z-index: 110;
  background: rgba(30, 20, 35, 0.72);
  display: grid; place-items: center; padding: 20px;
}
.win-card {
  width: min(92vw, 520px);
  background: #fff;
  border-radius: 24px;
  padding: 24px;
  text-align: center;
  box-shadow: var(--shadow);
}
.win-card h2 { font-family: 'ZCOOL KuaiLe', cursive; margin: 0 0 8px; }
.win-card p { color: var(--muted); margin: 0 0 16px; }
.win-video-wrap {
  width: min(100%, 320px);
  margin: 0 auto;
  aspect-ratio: 1 / 1;
  border-radius: 18px;
  overflow: hidden;
  background: #fff8fb;
  box-shadow: 0 12px 28px rgba(255,143,203,0.18);
}
.win-video-wrap video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}
.win-actions { display: flex; justify-content: center; gap: 10px; margin-top: 16px; flex-wrap: wrap; }

@media (max-width: 900px) {
  .hint-bubble { max-width: 100px; font-size: 0.72rem; padding: 8px 10px; }
  .hint-bubble-1 { left: 0; }
  .hint-bubble-2 { right: 0; }
  .hint-bubble-3 { left: 0; }
  .hint-bubble-4 { right: 0; }
}

.chat-log {
  max-height: 320px; overflow-y: auto; display: grid; gap: 12px; padding: 8px 4px 16px;
  margin-bottom: 8px;
  background: rgba(255, 255, 255, 0.45);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.75);
}
.chat-bubble { display: flex; gap: 10px; align-items: flex-start; animation: bubbleIn .35s ease; }
@keyframes bubbleIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.chat-bubble.user-bubble { flex-direction: row-reverse; }
.bubble-avatar { font-size: 1.6rem; flex-shrink: 0; }
.bubble-body {
  max-width: min(78%, 520px); background: #fff; padding: 12px 16px; border-radius: 18px;
  box-shadow: 0 8px 22px rgba(0,0,0,.05);
}
.user-bubble .bubble-body { background: linear-gradient(135deg, #fff0f8, #fff8ef); }
.bubble-body p { margin: 0; line-height: 1.55; }

.game-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 8px; }
.game-card {
  border: none; cursor: pointer; text-align: left; background: rgba(255,255,255,.92);
  border-radius: 22px; padding: 22px; box-shadow: 0 12px 30px rgba(183,123,159,.12);
  transition: .22s ease; font: inherit; color: inherit;
}
.game-card:hover { transform: translateY(-3px); box-shadow: 0 16px 36px rgba(255,143,203,.2); }
.game-icon { font-size: 2rem; display: block; margin-bottom: 10px; }
.game-card h3 { margin: 0 0 8px; font-size: 1.1rem; }
.game-card p { margin: 0; color: var(--muted); font-size: .94rem; }

.recording-rings { display: flex; justify-content: center; gap: 12px; margin: 14px 0 10px; }
.recording-rings span { width: 14px; height: 14px; border-radius: 50%; background: var(--pink); animation: ring 1s infinite ease-in-out; }
.recording-rings span:nth-child(2){ animation-delay:.15s } .recording-rings span:nth-child(3){ animation-delay:.3s }
@keyframes ring { 0%,100%{ transform: scale(.7); opacity:.4 } 50%{ transform: scale(1.4); opacity:1 } }

.voice-stage {
  display: grid; place-items: center; gap: 10px; margin: 18px 0;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 24px;
  padding: 8px 12px 4px;
  border: 1px solid rgba(255, 220, 235, 0.6);
}
.mic-btn {
  width: 106px; height: 106px; border-radius: 50%; font-size: 2.5rem; color: white;
  background: linear-gradient(135deg, #ff7fb5, #ffb65b); box-shadow: 0 16px 30px rgba(255,127,181,.35);
}
.mic-btn.recording { animation: micPulse .9s ease-in-out infinite; box-shadow: 0 0 0 0 rgba(255,143,203,.35), 0 16px 30px rgba(255,127,181,.45); }
@keyframes micPulse { 0%,100%{ transform: scale(1) } 50%{ transform: scale(1.08) } }
.mic-tip { color: var(--muted); }

.result-card, .quiz-card, .command-card { background: rgba(255,255,255,.92); border-radius: 24px; padding: 22px; }
.quiz-topline { margin-bottom: 14px; text-align: center; }
.quiz-controls, .command-controls { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 16px; }
.quiz-options { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.quiz-option {
  border: 2px solid rgba(255,143,203,.18); background: #fff; padding: 14px 12px; border-radius: 16px; font-weight: 700;
}
.quiz-feedback { margin-top: 14px; padding: 14px; border-radius: 16px; }
.quiz-feedback.success { background: rgba(158,231,216,.22); }
.quiz-feedback.fail { background: rgba(255,140,140,.15); }

.command-card { text-align: center; }
.command-prompt { font-family: 'ZCOOL KuaiLe', cursive; font-size: 1.35rem; margin-bottom: 10px; }
.command-hint { color: var(--muted); margin-bottom: 16px; }
.command-timer {
  width: 72px; height: 72px; margin: 0 auto 16px; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.8rem; font-weight: 800;
  background: linear-gradient(135deg, #ff8fcb, #ffbc6d); color: white;
  box-shadow: 0 10px 24px rgba(255,143,203,.35);
}

.soft-btn, .secondary-btn { background: #fff5fb; padding: 11px 16px; border-radius: 14px; }
.secondary-btn { background: #eef8ff; }

.scene-particles { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 1; }
.scene-particles span { position: absolute; border-radius: 50%; opacity: .7; background: radial-gradient(circle, rgba(255,255,255,.9), rgba(255,182,91,.25)); animation: drift 12s linear infinite; }
@keyframes drift { from{ transform: translateY(110vh) translateX(0) scale(.8)} to { transform: translateY(-10vh) translateX(28px) scale(1.2)} }

.hidden { display: none !important; }
.module-status { margin-top: 14px; text-align: center; }

@media (max-width: 900px) {
  .nav-grid, .nav-grid-two, .game-picker { grid-template-columns: 1fr; }
  .topbar { flex-direction: column; align-items: flex-start; }
  .home-invite-cats { gap: 4px; padding-inline: 6px; }
  .invite-cat { flex-basis: 22%; }
  .invite-bubble { font-size: 0.62rem; padding: 5px 8px; white-space: normal; text-align: center; max-width: 72px; }
  .invite-cat-1, .invite-cat-2, .invite-cat-3, .invite-cat-4 { padding-top: 52px; }
}
