.game-console {
  align-items: center;
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-float);
  display: flex;
  flex-direction: column;
  gap: 20px;
  left: 50%;
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
  padding: clamp(24px, 4.5vh, 36px) clamp(20px, 4vw, 36px);
  position: absolute;
  text-align: center;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(90vw, 440px);
  z-index: 10;
  font-family: var(--font-main);
  color: var(--text-primary);
}

.game-console > header h1 {
  font-size: clamp(1.4rem, 4vw, 1.9rem);
  font-weight: 900;
  letter-spacing: -0.3px;
  color: var(--text-primary);
}

.game-console > header p {
  color: var(--text-muted);
  font-size: clamp(0.85rem, 2vw, 1rem);
  font-weight: 600;
  margin: 6px 0 12px;
}

.play-hud {
  align-items: center;
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-card);
  color: var(--text-primary);
  display: flex;
  flex-direction: column;
  gap: 2px;
  left: 50%;
  max-width: min(92vw, 360px);
  padding: 10px 24px;
  pointer-events: none;
  position: absolute;
  text-align: center;
  top: max(12px, env(safe-area-inset-top));
  transform: translateX(-50%);
  width: max-content;
  z-index: 11;
  font-family: var(--font-main);
}

.play-hud strong {
  color: var(--badge-text);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.play-hud span {
  font-size: clamp(1.2rem, 3.5vw, 1.8rem);
  font-weight: 900;
  letter-spacing: -0.3px;
  color: var(--text-primary);
}

.play-hud small {
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.play-hud.hidden {
  display: none !important;
}

.play-hud:not(.hidden) {
  display: flex !important;
}

.play-hud.playing-visible {
  display: flex !important;
  min-width: min(72vw, 280px);
}

.play-hud-text-ready {
  border-color: var(--accent-yellow);
  box-shadow: 0 10px 24px var(--accent-yellow-glow);
}

.play-hud-text-ready span {
  color: var(--accent-yellow);
}

.play-hud-text-go {
  animation: play-hud-bounce 700ms ease-in-out infinite alternate;
  border-color: var(--accent-mint);
  box-shadow: 0 10px 28px var(--accent-mint-glow);
}

.play-hud-text-go span {
  color: var(--accent-mint);
}

.play-hud-text-error {
  border-color: var(--accent-pink);
  box-shadow: 0 10px 24px var(--accent-pink-glow);
}

.play-hud-text-error span {
  color: var(--accent-pink);
}

.play-hud-text-win span {
  color: var(--accent-blue);
}

@keyframes play-hud-bounce {
  from { transform: translateX(-50%) scale(1); }
  to { transform: translateX(-50%) scale(1.05); }
}

.console-view {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.game-status-msg {
  font-size: clamp(1.15rem, 3.8vw, 1.8rem);
  font-weight: 900;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
}

.sub-status-msg {
  font-size: clamp(0.85rem, 2.4vw, 1.05rem);
  font-weight: 600;
  color: var(--text-muted);
}

.console-view[hidden],
.hidden {
  display: none !important;
}

.launcher-button,
.launcher-link {
  align-items: center;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-full);
  color: var(--text-primary);
  cursor: pointer;
  display: inline-flex;
  font-family: inherit;
  font-size: 0.84rem;
  font-weight: 800;
  gap: 8px;
  justify-content: center;
  min-height: 54px;
  padding: 10px 22px;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.launcher-button:hover,
.launcher-button:focus-visible,
.launcher-link:hover,
.launcher-link:focus-visible {
  border-color: var(--accent-blue);
  box-shadow: 0 10px 24px var(--accent-blue-glow);
  outline: none;
  transform: translateY(-3px);
}

.launcher-button:active,
.launcher-link:active {
  transform: translateY(1px) scale(0.98);
}

.launcher-button > span,
.launcher-link > .launcher-icon {
  font-size: 1.25rem;
  line-height: 1;
  color: var(--accent-blue);
}

.result-content-centered {
  align-items: center;
  display: flex;
  flex-direction: column;
  gap: 14px;
  justify-content: center;
  margin: 0 auto;
  text-align: center;
  width: 100%;
}

.result-badge-hero {
  align-items: center;
  background: var(--badge-bg);
  border: 1px solid var(--badge-border);
  border-radius: var(--radius-full);
  color: var(--badge-text);
  display: inline-flex;
  font-size: 0.78rem;
  font-weight: 800;
  gap: 6px;
  justify-content: center;
  margin: 0 auto;
  padding: 6px 16px;
  width: fit-content;
}

.result-score-highlight {
  color: var(--text-primary);
  font-size: clamp(1.8rem, 4.5vw, 2.4rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 2px auto;
  text-align: center;
  width: 100%;
}

.result-submessage-text {
  color: var(--text-muted);
  font-size: clamp(0.85rem, 2.2vw, 1rem);
  font-weight: 700;
  margin: 0 auto;
  text-align: center;
  width: 100%;
}

.result-stats-row {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 0 auto;
  width: 100%;
}

.result-stat-chip {
  align-items: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex: 1 1 120px;
  flex-direction: column;
  gap: 2px;
  justify-content: center;
  max-width: 190px;
  padding: 8px 14px;
}

.result-stat-label {
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 700;
}

.result-stat-value {
  color: var(--text-primary);
  font-size: 1.15rem;
  font-weight: 900;
}

.result-actions {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 4px auto 0;
  width: 100%;
}

.result-actions .start-button,
.result-actions .btn {
  max-width: 320px;
  min-height: 52px;
  width: 100%;
}

@media (max-width: 640px) {
  .game-console {
    padding: 24px 20px;
    width: min(92vw, 420px);
  }
}

@media (max-height: 600px) {
  .game-console {
    gap: 12px;
    max-height: calc(100dvh - 12px);
    padding: 16px 20px;
  }
}

