.speak-app {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.speak-card {
  position: relative;
  width: min(100%, 700px);
  max-width: 700px;
  overflow: hidden;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 34px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.96), transparent 34%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.84), rgba(239, 246, 255, 0.46));
  backdrop-filter: blur(20px);
  box-shadow:
    0 28px 78px rgba(15, 23, 42, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.speak-card::before,
.speak-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
  border-radius: 999px;
}

.speak-card::before {
  width: 220px;
  height: 220px;
  top: -96px;
  right: -70px;
  background: radial-gradient(circle, rgba(96, 165, 250, 0.26), transparent 70%);
}

.speak-card::after {
  width: 240px;
  height: 240px;
  left: -110px;
  bottom: -110px;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.2), transparent 72%);
}

.speak-card > * {
  position: relative;
  z-index: 1;
}

.speak-sky {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.speak-star {
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #fef3c7;
  box-shadow: 0 0 18px rgba(250, 204, 21, 0.88);
  animation: speakTwinkle 1.8s infinite alternate;
}

.speak-star-one {
  top: 76px;
  left: 13%;
}

.speak-star-two {
  top: 145px;
  right: 10%;
  animation-delay: 0.4s;
}

.speak-star-three {
  bottom: 135px;
  left: 10%;
  animation-delay: 0.8s;
}

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

.speak-back {
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: #475569;
  padding: 9px 13px;
  font-size: 13px;
  font-weight: 950;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
}

.speak-credit-counter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid rgba(125, 211, 252, 0.74);
  border-radius: 999px;
  background: rgba(240, 249, 255, 0.9);
  color: #0369a1;
  padding: 9px 13px;
  font-size: 13px;
  font-weight: 950;
  line-height: 1;
  white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

#speechCreditsValue {
  min-width: 1.4em;
  text-align: center;
  color: #0f172a;
  font-size: 15px;
}

.speak-hero {
  text-align: center;
  margin: 4px auto 12px;
}

.speak-title {
  color: #0f172a;
  font-size: clamp(27px, 5vw, 43px);
  font-weight: 1000;
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.62);
}

.speak-progress-pill {
  width: fit-content;
  min-width: 58px;
  margin: 10px auto 0;
  border: 1px solid rgba(125, 211, 252, 0.62);
  border-radius: 999px;
  background: rgba(240, 249, 255, 0.82);
  color: #0369a1;
  padding: 6px 13px;
  font-size: 14px;
  font-weight: 1000;
  line-height: 1;
  box-shadow:
    0 8px 18px rgba(15, 23, 42, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.speak-prompt {
  max-width: 500px;
  margin: 12px auto 0;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.76);
  color: #1f2937;
  padding: 12px 16px;
  text-align: center;
  font-size: clamp(16px, 3vw, 21px);
  font-weight: 1000;
  line-height: 1.18;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.12);
}

.speak-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 0 0 12px;
}

.speak-stats .stat-pill {
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  color: #475569;
  padding: 9px 8px;
  text-align: center;
  font-size: 13px;
  font-weight: 950;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
}

.speak-play-stage {
  display: grid;
  grid-template-columns: 1fr;
  width: min(100%, 520px);
  margin: 0 auto;
}

.speak-word-row {
  display: flex;
  flex-direction: column-reverse;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
}

.speak-actions {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin: 18px 0 12px;
}

.speak-listen-btn,
.speak-mic-btn {
  width: 78px;
  height: 78px;
  border: 0;
  border-radius: 28px;
  color: #ffffff;
  font-size: 34px;
  cursor: pointer;
  transform: translateZ(0);
  transition: transform 0.16s ease, box-shadow 0.16s ease, opacity 0.16s ease;
  box-shadow:
    0 18px 34px rgba(15, 23, 42, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.34);
}

.speak-listen-inline-btn {
  width: 88px;
  height: 88px;
  border-radius: 30px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.8), transparent 34%),
    linear-gradient(135deg, rgba(224, 242, 254, 1), rgba(125, 211, 252, 0.94));
  border: 2px solid rgba(14, 165, 233, 0.58);
  box-shadow:
    0 18px 34px rgba(14, 165, 233, 0.26),
    0 0 0 7px rgba(186, 230, 253, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.94);
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.speak-sound-icon {
  width: 70px;
  height: 70px;
  object-fit: contain;
  display: block;
  filter:
    drop-shadow(0 9px 14px rgba(14, 165, 233, 0.28))
    drop-shadow(0 0 10px rgba(56, 189, 248, 0.34));
}

.speak-target-panel {
  width: min(100%, 520px);
  margin: 0 auto;
  padding: 16px 20px 18px;
  border: 1px solid rgba(125, 211, 252, 0.56);
  border-radius: 30px;
  background:
    radial-gradient(circle at 50% 0%, rgba(240, 249, 255, 0.92), transparent 42%),
    rgba(255, 255, 255, 0.54);
  box-shadow:
    0 18px 38px rgba(15, 23, 42, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  transform: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.speak-card:has(.speak-status.is-correct) .speak-target-panel {
  border-color: rgba(34, 197, 94, 0.48);
  box-shadow:
    0 22px 44px rgba(34, 197, 94, 0.14),
    0 0 0 6px rgba(34, 197, 94, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.speak-card:has(.speak-status.is-almost) .speak-target-panel {
  border-color: rgba(245, 158, 11, 0.42);
  box-shadow:
    0 20px 40px rgba(245, 158, 11, 0.1),
    0 0 0 6px rgba(245, 158, 11, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.speak-card:has(.speak-status.is-error),
.speak-card:has(.speak-status.is-try-again) {
  animation: speakSoftShake 0.24s ease;
}

.speak-label {
  width: fit-content;
  margin: 0 auto 10px;
  border: 1px solid rgba(14, 165, 233, 0.3);
  border-radius: 999px;
  background: rgba(240, 249, 255, 0.86);
  color: #0369a1;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 1000;
  letter-spacing: 0.02em;
  text-align: center;
}

.speak-label::before {
  content: "🎯 ";
}

.speak-word {
  min-height: 76px;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #166534;
  font-size: clamp(34px, 6vw, 58px);
  font-weight: 1000;
  line-height: 1;
  text-align: center;
  letter-spacing: -0.04em;
  white-space: nowrap;
  word-break: keep-all;
  overflow-wrap: normal;
  hyphens: none;
  transition: transform 0.18s ease, filter 0.18s ease, color 0.18s ease;
}

.speak-card:has(.speak-status.is-correct) .speak-word {
  color: #15803d;
  animation: speakWordSuccess 0.62s ease both;
}

.speak-card:has(.speak-status.is-checking) .speak-word {
  filter: saturate(1.08);
}

.speak-word-meaning {
  min-height: 34px;
  width: fit-content;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 12px auto 0;
  border: 1px solid rgba(100, 116, 139, 0.18);
  border-radius: 999px;
  background: rgba(248, 250, 252, 0.84);
  color: #64748b;
  padding: 6px 16px;
  font-size: clamp(18px, 3.6vw, 26px);
  font-weight: 1000;
  line-height: 1.1;
  text-align: center;
  overflow-wrap: anywhere;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.speak-word-meaning::before {
  content: "💡 ";
  font-size: 0.82em;
}

.speak-listen-btn {
  background: transparent;
  box-shadow: none;
}

.speak-listen-btn.is-auto-listening {
  opacity: 1;
  transform: scale(1.12);
}

.speak-listen-btn.is-auto-listening .speak-sound-icon {
  animation: speakPulse 0.55s ease-in-out infinite alternate;
  filter:
    drop-shadow(0 8px 16px rgba(14, 165, 233, 0.28))
    drop-shadow(0 0 14px rgba(56, 189, 248, 0.42));
}

.speak-mic-btn {
  position: relative;
  width: 104px;
  height: 104px;
  border-radius: 36px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.54), transparent 30%),
    linear-gradient(135deg, #e0f2fe, #bae6fd 48%, #93c5fd);
  box-shadow:
    0 20px 38px rgba(37, 99, 235, 0.22),
    0 0 0 8px rgba(186, 230, 253, 0.26),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
  overflow: visible;
}

.speak-mic-btn::before,
.speak-mic-btn::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 40px;
  pointer-events: none;
  opacity: 0;
}

.speak-mic-btn::before {
  border: 3px solid rgba(14, 165, 233, 0.34);
}

.speak-mic-btn::after {
  inset: -16px;
  border: 2px solid rgba(14, 165, 233, 0.18);
}

.speak-mic-icon {
  width: 78px;
  height: 78px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.speak-listen-btn:hover,
.speak-mic-btn:hover {
  transform: translateY(-2px) scale(1.04);
}

.speak-listen-btn:active,
.speak-mic-btn:active {
  transform: translateY(1px) scale(0.98);
}

.speak-listen-btn:disabled,
.speak-mic-btn:disabled {
  cursor: not-allowed;
  opacity: 0.56;
  transform: none;
}

.speak-mic-btn.is-recording {
  animation: speakPulse 0.7s infinite alternate;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.62), transparent 30%),
    linear-gradient(135deg, #fecdd3, #fb7185 52%, #f97316);
  box-shadow:
    0 0 0 10px rgba(251, 113, 133, 0.18),
    0 0 0 22px rgba(249, 115, 22, 0.12),
    0 22px 44px rgba(248, 113, 113, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.68);
}

.speak-mic-btn.is-recording::before,
.speak-mic-btn.is-recording::after {
  opacity: 1;
  animation: speakRecordRing 0.9s ease-out infinite;
  border-color: rgba(251, 113, 133, 0.42);
}

.speak-mic-btn.is-recording::after {
  animation-delay: 0.18s;
  border-color: rgba(249, 115, 22, 0.24);
}

.speak-mic-btn[aria-busy="true"] {
  cursor: wait;
}

.speak-card:has(.speak-status.is-checking) .speak-mic-btn:not(.is-recording) {
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.58), transparent 30%),
    linear-gradient(135deg, #ddd6fe, #c4b5fd 50%, #818cf8);
  box-shadow:
    0 0 0 10px rgba(129, 140, 248, 0.14),
    0 18px 38px rgba(99, 102, 241, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.68);
}

.speak-status {
  width: min(100%, 460px);
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 8px auto 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #475569;
  padding: 0 10px;
  text-align: center;
  font-size: clamp(14px, 2.7vw, 17px);
  font-weight: 900;
  line-height: 1.25;
  box-shadow: none;
}

.speak-status.is-recording {
  color: #be123c;
  background: linear-gradient(135deg, rgba(255, 241, 242, 0.98), rgba(255, 228, 230, 0.9));
  border-color: rgba(251, 113, 133, 0.88);
  box-shadow:
    0 0 0 8px rgba(251, 113, 133, 0.12),
    0 14px 30px rgba(190, 18, 60, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  animation: speakStatusPulse 0.7s infinite alternate;
}

.speak-status.is-recording::before {
  content: "🎙️ ";
}

.speak-status.is-checking {
  color: #4338ca;
  background: linear-gradient(135deg, rgba(238, 242, 255, 0.98), rgba(224, 231, 255, 0.9));
  border-color: rgba(129, 140, 248, 0.88);
  box-shadow:
    0 0 0 8px rgba(99, 102, 241, 0.1),
    0 14px 30px rgba(67, 56, 202, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.speak-status.is-checking::before {
  content: "✨ ";
  animation: speakSpinDot 0.9s linear infinite;
}

.speak-status.is-correct {
  color: #15803d;
  background: linear-gradient(135deg, rgba(240, 253, 244, 0.96), rgba(220, 252, 231, 0.88));
  border-color: rgba(134, 239, 172, 0.9);
  box-shadow:
    0 0 0 8px rgba(34, 197, 94, 0.1),
    0 14px 30px rgba(21, 128, 61, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.speak-status.is-correct::before {
  content: "⭐ ";
}

.speak-status.is-almost {
  color: #b45309;
  background: linear-gradient(135deg, rgba(255, 251, 235, 0.96), rgba(254, 243, 199, 0.88));
  border-color: rgba(253, 186, 116, 0.92);
  box-shadow:
    0 0 0 8px rgba(245, 158, 11, 0.1),
    0 14px 30px rgba(180, 83, 9, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.speak-status.is-almost::before {
  content: "🔁 ";
}

.speak-status.is-try-again,
.speak-status.is-error {
  color: #b91c1c;
  background: linear-gradient(135deg, rgba(255, 241, 242, 0.96), rgba(254, 226, 226, 0.88));
  border-color: rgba(252, 165, 165, 0.92);
  box-shadow:
    0 0 0 8px rgba(239, 68, 68, 0.1),
    0 14px 30px rgba(185, 28, 28, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.speak-status.is-try-again::before,
.speak-status.is-error::before {
  content: "🎧 ";
}

.speak-next-btn {
  display: block;
  margin: 14px auto 0;
  border: 0;
  border-radius: 999px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.32), transparent 28%),
    linear-gradient(135deg, #22c55e, #06b6d4 56%, #6366f1);
  color: #ffffff;
  padding: 13px 30px;
  font-size: 17px;
  font-weight: 1000;
  cursor: pointer;
  box-shadow:
    0 15px 32px rgba(14, 165, 233, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.38);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.speak-next-btn:hover {
  transform: translateY(-2px);
  box-shadow:
    0 20px 42px rgba(14, 165, 233, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.speak-next-btn:active {
  transform: translateY(1px);
}

.speak-upgrade-panel {
  width: min(100%, 500px);
  margin: 12px auto 0;
  border: 1px solid rgba(251, 191, 36, 0.72);
  border-radius: 26px;
  background:
    radial-gradient(circle at 12% 18%, rgba(254, 240, 138, 0.48), transparent 34%),
    linear-gradient(135deg, rgba(255, 251, 235, 0.96), rgba(255, 237, 213, 0.9));
  color: #7c2d12;
  padding: 14px;
  text-align: center;
  box-shadow: 0 18px 42px rgba(124, 45, 18, 0.16);
}

.speak-upgrade-message {
  font-size: 15px;
  font-weight: 1000;
  line-height: 1.34;
  margin-bottom: 11px;
}

.speak-upgrade-btn {
  border: 0;
  border-radius: 999px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.34), transparent 28%),
    linear-gradient(135deg, #fb923c, #ec4899 58%, #8b5cf6);
  color: #ffffff;
  cursor: pointer;
  font-size: 15px;
  font-weight: 1000;
  padding: 11px 18px;
  box-shadow: 0 14px 30px rgba(219, 39, 119, 0.24);
}

.speak-upgrade-btn:disabled {
  cursor: not-allowed;
  opacity: 0.62;
}

.speak-upgrade-error {
  color: #b91c1c;
  font-size: 14px;
  font-weight: 900;
  margin-top: 10px;
}

#activeAvatarContainer {
  position: fixed;
  right: max(14px, calc((100vw - 700px) / 2 + 18px));
  bottom: 14px;
  z-index: 4;
  pointer-events: none;
  transform-origin: bottom right;
}

#activeAvatarContainer .player-avatar-img {
  width: 118px;
  max-height: 150px;
  object-fit: contain;
  opacity: 1;
}

#activeAvatarContainer.speak-avatar-success {
  animation: speakAvatarSuccess 1.2s ease both;
}

@keyframes speakAvatarSuccess {
  0% {
    transform: scale(1);
  }

  35% {
    transform: scale(1.75) translateY(-18px);
  }

  70% {
    transform: scale(1.28) translateY(-6px);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes speakPulse {
  from {
    transform: scale(1);
  }

  to {
    transform: scale(1.08);
  }
}

@keyframes speakRecordRing {
  0% {
    transform: scale(0.9);
    opacity: 0.72;
  }

  100% {
    transform: scale(1.18);
    opacity: 0;
  }
}

@keyframes speakStatusPulse {
  from {
    transform: scale(1);
  }

  to {
    transform: scale(1.03);
  }
}

@keyframes speakWordSuccess {
  0% {
    transform: scale(1);
  }

  35% {
    transform: scale(1.08) translateY(-3px);
  }

  70% {
    transform: scale(0.98);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes speakSoftShake {
  0% {
    transform: translateX(0);
  }

  30% {
    transform: translateX(-3px);
  }

  60% {
    transform: translateX(3px);
  }

  100% {
    transform: translateX(0);
  }
}

@keyframes speakSpinDot {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes speakTwinkle {
  from {
    opacity: 0.35;
    transform: scale(0.78);
  }

  to {
    opacity: 1;
    transform: scale(1.15);
  }
}

@media (max-width: 560px) {
  .speak-app {
    align-items: flex-start;
    padding: 10px;
  }

  .speak-card {
    width: 100%;
    min-height: calc(100vh - 20px);
    padding: 13px;
    border-radius: 28px;
  }

  .speak-topbar {
    margin-bottom: 8px;
  }

  .speak-back {
    padding: 8px 11px;
    font-size: 12px;
  }

  .speak-credit-counter {
    padding: 8px 11px;
    font-size: 12px;
  }

  .speak-title {
    font-size: 29px;
  }

  .speak-prompt {
    margin-top: 10px;
    border-radius: 22px;
    padding: 11px 13px;
    font-size: 16px;
  }

  .speak-stats {
    gap: 7px;
    margin-bottom: 10px;
  }

  .speak-stats .stat-pill {
    padding: 8px 6px;
    font-size: 12px;
  }

  .speak-play-stage {
    gap: 0;
  }

  .speak-word-panel {
    border-radius: 28px;
    padding: 16px 12px 18px;
  }

  .speak-target-panel {
    width: min(100%, 360px);
    padding: 14px 12px 16px;
    border-radius: 26px;
    transform: none;
  }

  .speak-label {
    font-size: 12px;
    margin-bottom: 8px;
    padding: 5px 10px;
  }

  .speak-word {
    min-height: 66px;
    max-width: 100%;
    font-size: clamp(32px, 10.5vw, 50px);
    line-height: 1.04;
    word-break: normal;
    overflow-wrap: normal;
    hyphens: none;
  }

  .speak-word-meaning {
    min-height: 28px;
    margin-top: 8px;
    padding: 6px 13px;
    font-size: clamp(18px, 5.2vw, 24px);
  }

  .speak-actions {
    gap: 16px;
    margin: 14px 0 10px;
  }

  .speak-listen-btn {
    width: 62px;
    height: 62px;
    border-radius: 999px;
    font-size: 28px;
  }

  .speak-listen-inline-btn {
    width: 62px;
    height: 62px;
  }

  .speak-sound-icon {
    width: 52px;
    height: 52px;
  }

  .speak-mic-btn {
    width: 96px;
    height: 96px;
    border-radius: 34px;
    font-size: 30px;
  }

  .speak-mic-icon {
    width: 74px;
    height: 74px;
  }

  .speak-status {
    min-height: 50px;
    border-radius: 22px;
    padding: 11px 13px;
    font-size: 16px;
  }

  .speak-next-btn {
    margin-top: 12px;
    padding: 12px 26px;
    font-size: 16px;
  }

  #activeAvatarContainer {
    right: 12px;
    bottom: 10px;
  }

  #activeAvatarContainer .player-avatar-img {
    width: 104px;
    max-height: 132px;
  }
}

.speak-loading-overlay {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 20% 20%, rgba(254, 240, 138, 0.46), transparent 28%),
    radial-gradient(circle at 80% 18%, rgba(125, 211, 252, 0.42), transparent 30%),
    rgba(248, 250, 252, 0.78);
  backdrop-filter: blur(9px);
}

.speak-loading-overlay[hidden] {
  display: none;
}

.speak-loading-card {
  display: grid;
  justify-items: center;
  gap: 14px;
  width: min(100%, 260px);
  padding: 24px 22px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 30px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.96), transparent 42%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(224, 242, 254, 0.9));
  box-shadow:
    0 24px 58px rgba(15, 23, 42, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  text-align: center;
}

.speak-loading-orbit {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background:
    radial-gradient(circle, #ffffff 0 34%, transparent 36%),
    conic-gradient(from 0deg, #38bdf8, #a78bfa, #f97316, #22c55e, #38bdf8);
  animation: speakLoadingSpin 0.95s linear infinite;
  box-shadow:
    0 0 0 8px rgba(186, 230, 253, 0.28),
    0 16px 28px rgba(14, 165, 233, 0.22);
}

.speak-loading-orbit span {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 8px 14px rgba(15, 23, 42, 0.14);
}

.speak-loading-orbit span:nth-child(1) {
  top: 2px;
  left: 29px;
}

.speak-loading-orbit span:nth-child(2) {
  right: 4px;
  bottom: 14px;
}

.speak-loading-orbit span:nth-child(3) {
  left: 4px;
  bottom: 14px;
}

.speak-loading-title {
  color: #0f172a;
  font-size: 18px;
  font-weight: 1000;
  line-height: 1.18;
}

.speak-game-loading .speak-listen-btn,
.speak-game-loading .speak-mic-btn,
.speak-game-loading .speak-next-btn {
  pointer-events: none;
}

@keyframes speakLoadingSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.speak-play-stage {
  gap: 14px;
}

.speak-target-panel {
  position: relative;
  overflow: hidden;
  min-height: 250px;
  display: grid;
  align-content: center;
  gap: 12px;
  border: 2px solid rgba(56, 189, 248, 0.3);
  background:
    radial-gradient(circle at 18% 20%, rgba(254, 240, 138, 0.55), transparent 26%),
    radial-gradient(circle at 86% 22%, rgba(125, 211, 252, 0.48), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(240, 249, 255, 0.68));
}

.speak-target-panel::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 2px dashed rgba(56, 189, 248, 0.2);
  border-radius: 24px;
  pointer-events: none;
}

.speak-word {
  color: #166534;
  font-size: clamp(42px, 8vw, 72px);
  text-shadow:
    0 3px 0 rgba(255, 255, 255, 0.92),
    0 12px 22px rgba(22, 101, 52, 0.18);
}

.speak-actions {
  margin: 10px 0 6px;
}

.speak-mic-btn {
  width: 118px;
  height: 118px;
  border-radius: 42px;
  box-shadow:
    0 22px 42px rgba(37, 99, 235, 0.24),
    0 0 0 10px rgba(186, 230, 253, 0.28),
    0 0 0 22px rgba(125, 211, 252, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
  animation: speakMicInvite 1.6s ease-in-out infinite alternate;
}

.speak-mic-icon {
  width: 86px;
  height: 86px;
}

.speak-status {
  width: min(100%, 430px);
  min-height: 44px;
  margin-top: 8px;
  color: #334155;
  font-size: clamp(16px, 3vw, 20px);
  line-height: 1.2;
}

@keyframes speakMicInvite {
  from {
    transform: translateY(0) scale(1);
  }

  to {
    transform: translateY(-3px) scale(1.04);
  }
}

@media (max-width: 560px) {
  .speak-target-panel {
    min-height: 225px;
  }

  .speak-word {
    font-size: clamp(42px, 13vw, 62px);
  }

  .speak-actions {
    margin: 8px 0 4px;
  }

  .speak-mic-btn {
    width: 112px;
    height: 112px;
    border-radius: 40px;
  }

  .speak-mic-icon {
    width: 82px;
    height: 82px;
  }
}

