:root {
  --bg: #050816;
  --panel: rgba(255, 255, 255, 0.065);
  --panel-strong: rgba(255, 255, 255, 0.105);
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(103, 232, 249, 0.42);
  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.68);
  --faint: rgba(255, 255, 255, 0.46);
  --cyan: #22d3ee;
  --blue: #60a5fa;
  --pink: #e879f9;
  --green: #34d399;
  --red: #fb7185;
  --yellow: #facc15;
  --radius: 24px;
  --radius-sm: 14px;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.36);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body {
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.app-shell {
  min-height: 100vh;
  background: #040615;
  overflow-x: hidden;
}

.loading-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  gap: 18px;
  color: var(--muted);
  text-align: center;
}

.loading-screen img {
  width: 96px;
  height: 96px;
  object-fit: contain;
  animation: pulse 2.4s ease-in-out infinite;
}

.loading-screen .brand-mark {
  width: 96px;
  height: 96px;
  font-size: 28px;
  border-radius: 26px;
  animation: pulse 2.4s ease-in-out infinite;
}

.page {
  min-height: 100vh;
  position: relative;
}

.page::before {
  content: "";
  position: fixed;
  inset: -18%;
  z-index: 0;
  background:
    radial-gradient(circle at 18% 18%, rgba(34, 211, 238, 0.18), transparent 28%),
    radial-gradient(circle at 76% 22%, rgba(232, 121, 249, 0.16), transparent 26%),
    radial-gradient(circle at 54% 78%, rgba(96, 165, 250, 0.11), transparent 30%),
    linear-gradient(180deg, #050716 0%, #07091a 46%, #03040d 100%);
  animation: ambientFlow 18s ease-in-out infinite alternate;
  pointer-events: none;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  min-height: 76px;
  padding: 14px clamp(18px, 4vw, 54px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(4, 6, 17, 0.9);
  backdrop-filter: blur(22px);
  animation: topbarDrop 0.6s ease both;
}

.brand {
  display: flex;
  align-items: center;
  gap: 13px;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  text-align: left;
}

.brand-mark {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 14px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: 0;
  box-shadow: none;
  animation: logoBreath 4.4s ease-in-out infinite;
}

img.brand-mark {
  object-fit: contain;
  padding: 0;
  background: none;
  filter: drop-shadow(0 0 14px rgba(34, 211, 238, 0.22));
}

.brand strong {
  display: block;
  font-size: 19px;
  line-height: 1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand-label,
.brand-label span {
  display: block;
  margin-top: 4px;
  color: var(--faint);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

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

.shell {
  width: min(1500px, calc(100% - 40px));
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(360px, 0.78fr) minmax(620px, 1.22fr);
  gap: 22px;
  align-items: stretch;
  padding: 24px 0 28px;
  min-height: calc(100svh - 76px);
  animation: pageRise 0.7s ease both;
}

.hero-copy {
  min-height: 640px;
  display: grid;
  align-content: center;
  gap: 24px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 26px;
  padding: clamp(26px, 4vw, 48px);
  background:
    radial-gradient(circle at 22% 22%, rgba(34, 211, 238, 0.16), transparent 34%),
    radial-gradient(circle at 86% 20%, rgba(232, 121, 249, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(8, 12, 31, 0.94), rgba(4, 7, 20, 0.96));
  box-shadow: var(--shadow);
  animation: pageRise 0.78s ease both;
}

.hero-copy::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(34, 211, 238, 0.18);
  box-shadow: inset 0 0 0 1px rgba(232, 121, 249, 0.08);
  pointer-events: none;
}

.hero-copy > * {
  position: relative;
  z-index: 1;
}

.hero-logo-lockup {
  display: grid;
  gap: 16px;
  align-items: start;
}

.hero-logo {
  width: clamp(96px, 9vw, 142px);
  height: clamp(96px, 9vw, 142px);
  object-fit: contain;
  filter: drop-shadow(0 0 26px rgba(34, 211, 238, 0.32));
  animation: logoFloat 5.5s ease-in-out infinite;
}

.eyebrow {
  width: fit-content;
  color: #b7f7ff;
  border: 1px solid rgba(34, 211, 238, 0.24);
  background: rgba(34, 211, 238, 0.1);
  border-radius: 999px;
  padding: 9px 13px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.title {
  margin: 0;
  max-width: 560px;
  font-size: clamp(38px, 3.8vw, 68px);
  line-height: 0.98;
  font-weight: 950;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.lead {
  display: none;
  color: rgba(255, 255, 255, 0.78);
  font-size: clamp(17px, 1.4vw, 21px);
  line-height: 1.55;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.56);
}

.hero-dashboard {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-width: 620px;
}

.hero-dashboard div {
  min-height: 92px;
  display: grid;
  align-content: end;
  gap: 4px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.055);
  padding: 14px;
  backdrop-filter: blur(14px);
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.hero-dashboard div:hover {
  transform: translateY(-3px);
  border-color: rgba(34, 211, 238, 0.34);
  background: rgba(34, 211, 238, 0.08);
}

.hero-dashboard strong {
  color: #fff;
  font-size: 30px;
  line-height: 1;
}

.hero-dashboard span {
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.stat-strip {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.stat-strip span,
.pill {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.82);
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 800;
}

.panel {
  border-radius: 24px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(11, 14, 34, 0.9), rgba(5, 8, 22, 0.94));
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.room-top,
.lobby-main,
.game-main,
.side-panel,
.join-room-panel,
.final-panel {
  background:
    linear-gradient(180deg, rgba(8, 11, 28, 0.95), rgba(5, 8, 22, 0.96));
}

.setup-panel {
  align-self: stretch;
  padding: clamp(20px, 2.2vw, 30px);
  display: grid;
  gap: 18px;
  background:
    linear-gradient(180deg, rgba(9, 12, 30, 0.96), rgba(5, 8, 22, 0.96));
  overflow: hidden;
  animation: pageRise 0.86s ease both;
  animation-delay: 0.08s;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.panel-head h2,
.panel-head h3 {
  margin: 0;
  font-size: clamp(24px, 2vw, 34px);
  letter-spacing: 0;
  line-height: 1.04;
}

.panel-head span {
  color: var(--faint);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

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

.setup-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.onboarding-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.onboarding-steps span {
  min-height: 56px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(34, 211, 238, 0.16);
  border-radius: 14px;
  background: rgba(34, 211, 238, 0.055);
  color: rgba(255, 255, 255, 0.78);
  padding: 12px;
  font-size: 13px;
  font-weight: 800;
}

.onboarding-steps b {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cyan), var(--pink));
  color: #04101c;
  font-size: 13px;
}

.setup-name,
.setup-mode,
.setup-age,
.setup-difficulty,
.setup-ranges,
.timer-choice-grid {
  grid-column: span 12;
}

.field span,
.block-title {
  color: rgba(255, 255, 255, 0.82);
  font-weight: 850;
}

.input {
  width: 100%;
  min-height: 56px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.075);
  color: var(--text);
  outline: none;
  padding: 0 16px;
}

.input::placeholder {
  color: rgba(255, 255, 255, 0.38);
}

.input:focus {
  border-color: rgba(34, 211, 238, 0.54);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

.setup-panel .field,
.setup-panel .range-grid,
.timer-choice-grid,
.setup-options,
.answer-mode-field,
.setup-panel .reveal-note,
.setup-panel .btn.primary {
  animation: controlIn 0.56s ease both;
}

.setup-panel .field:nth-child(1) { animation-delay: 0.08s; }
.setup-panel .field:nth-child(2) { animation-delay: 0.13s; }
.setup-panel .field:nth-child(3) { animation-delay: 0.18s; }
.setup-panel .field:nth-child(4) { animation-delay: 0.23s; }
.setup-panel .range-grid { animation-delay: 0.28s; }
.timer-choice-grid { animation-delay: 0.3s; }
.setup-options { animation-delay: 0.35s; }
.answer-mode-field { animation-delay: 0.4s; }
.setup-panel .reveal-note { animation-delay: 0.45s; }
.setup-panel .btn.primary { animation-delay: 0.5s; }

.difficulty-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

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

.choice-card,
.category-card,
.answer-button,
.player-row {
  border: 1px solid rgba(255, 255, 255, 0.11);
  background: rgba(255, 255, 255, 0.048);
  color: var(--text);
  border-radius: 14px;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.choice-card {
  min-height: 78px;
  display: grid;
  align-content: center;
  gap: 6px;
  text-align: left;
  padding: 14px 16px;
}

.choice-card strong {
  font-size: 17px;
  line-height: 1.15;
}

.choice-card span,
.category-card span,
.category-card em {
  color: var(--faint);
  font-size: 12px;
  font-style: normal;
}

.choice-card:hover,
.category-card:hover {
  transform: translateY(-3px);
  border-color: rgba(34, 211, 238, 0.42);
  background: rgba(34, 211, 238, 0.07);
  box-shadow: 0 14px 34px rgba(34, 211, 238, 0.08);
}

.is-muted {
  opacity: 0.62;
}

.choice-card.active,
.category-card.active {
  border-color: var(--line-strong);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.15), rgba(232, 121, 249, 0.12));
  box-shadow: 0 16px 44px rgba(34, 211, 238, 0.1);
  animation: selectedPulse 3.2s ease-in-out infinite;
}

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

.timer-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.range-box {
  display: grid;
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.045);
  border-radius: 14px;
  padding: 16px;
}

.range-box span {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-weight: 800;
}

.range-box strong {
  color: #b7f7ff;
}

.timer-off-box {
  align-content: center;
}

.timer-off-box p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

input[type="range"] {
  width: 100%;
  height: 28px;
  cursor: pointer;
  appearance: none;
  background: transparent;
  touch-action: pan-y;
}

input[type="range"]::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(34, 211, 238, 0.95), rgba(232, 121, 249, 0.8));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}

input[type="range"]::-webkit-slider-thumb {
  width: 24px;
  height: 24px;
  margin-top: -8px;
  appearance: none;
  border: 3px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 8px 24px rgba(34, 211, 238, 0.36);
}

input[type="range"]::-moz-range-track {
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(34, 211, 238, 0.95), rgba(232, 121, 249, 0.8));
}

input[type="range"]::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 8px 24px rgba(34, 211, 238, 0.36);
}

.switch-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.host-start-form {
  margin: 0;
}

.host-start-form .btn {
  width: 100%;
}

.setup-options {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding-top: 2px;
}

.answer-mode-field {
  padding-top: 2px;
}

.setup-age .chip-btn {
  flex: 1 1 190px;
}

.answer-mode-field .chip-btn {
  flex: 1 1 220px;
}

.setup-panel .btn.primary {
  width: 100%;
}

.btn,
.chip-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  padding: 0 16px;
  font-weight: 900;
  line-height: 1.15;
  transition: transform 0.2s ease, opacity 0.18s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn {
  min-height: 54px;
  padding: 0 22px;
  border-radius: 14px;
}

.btn:hover,
.chip-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.32);
  box-shadow: 0 12px 30px rgba(34, 211, 238, 0.08);
}

.btn.primary {
  position: relative;
  overflow: hidden;
  border: 0;
  background: linear-gradient(90deg, var(--cyan), var(--blue) 48%, var(--pink));
  color: #04101c;
  box-shadow: 0 18px 44px rgba(96, 165, 250, 0.25);
}

.btn.primary::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.42) 46%, transparent 62%);
  transform: translateX(-120%);
  animation: buttonShine 3.6s ease-in-out infinite;
}

.btn.primary > *,
.btn.primary {
  isolation: isolate;
}

.chip-btn.active {
  border-color: rgba(34, 211, 238, 0.34);
  background: rgba(34, 211, 238, 0.12);
  box-shadow: inset 0 0 0 1px rgba(34, 211, 238, 0.1);
}

.error {
  border: 1px solid rgba(251, 113, 133, 0.28);
  background: rgba(251, 113, 133, 0.1);
  color: #fecdd3;
  border-radius: 16px;
  padding: 13px 14px;
  line-height: 1.5;
}

.category-section {
  padding: 0 0 56px;
}

.category-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 20px;
}

.category-panel,
.join-panel {
  padding: 22px;
  display: grid;
  gap: 16px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(158px, 1fr));
  gap: 10px;
}

.category-card {
  min-height: 82px;
  display: grid;
  gap: 5px;
  padding: 13px;
  text-align: left;
  position: relative;
}

.category-card strong {
  font-size: 15px;
  line-height: 1.2;
}

.category-card .mark {
  position: absolute;
  right: 10px;
  top: 10px;
  color: var(--cyan);
}

.launch-panel {
  display: grid;
  grid-template-columns: 1fr minmax(240px, 340px);
  gap: 14px;
  align-items: center;
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: 18px;
  background:
    radial-gradient(circle at 20% 30%, rgba(34, 211, 238, 0.14), transparent 34%),
    rgba(255, 255, 255, 0.045);
  padding: 16px;
  animation: pageRise 0.7s ease both;
}

.launch-panel div {
  display: grid;
  gap: 6px;
}

.launch-panel strong {
  font-size: 18px;
}

.launch-panel span {
  color: rgba(255, 255, 255, 0.66);
  line-height: 1.5;
}

.join-panel {
  align-content: start;
}

.join-panel .panel-head h3,
.side-panel .panel-head h3 {
  font-size: 22px;
}

.room-page {
  min-height: 100vh;
  padding-bottom: 34px;
}

.room-shell {
  display: grid;
  gap: 16px;
  padding-top: 22px;
}

.room-top {
  padding: 16px 18px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}

.room-code {
  font-size: clamp(36px, 7vw, 84px);
  line-height: 0.92;
  font-weight: 950;
  letter-spacing: 0.02em;
}

.game-top {
  align-items: center;
}

.game-title {
  margin-top: 6px;
  font-size: clamp(28px, 4vw, 58px);
  line-height: 0.96;
  font-weight: 950;
  letter-spacing: 0;
}

.lobby-grid,
.game-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 16px;
  align-items: start;
}

.offline-lobby,
.offline-game {
  grid-template-columns: 1fr;
}

.lobby-main,
.game-main,
.side-panel,
.join-room-panel,
.final-panel {
  padding: 22px;
  display: grid;
  gap: 16px;
}

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

.share-grid .btn:only-child {
  grid-column: 1 / -1;
}

.invite-line {
  overflow-wrap: anywhere;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 12px;
}

.players-list {
  display: grid;
  gap: 10px;
}

.player-row {
  min-height: 58px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
}

.player-row.answer-answered {
  border-color: rgba(96, 165, 250, 0.34);
  background: rgba(96, 165, 250, 0.09);
}

.player-row.answer-correct {
  border-color: rgba(52, 211, 153, 0.62);
  background:
    linear-gradient(90deg, rgba(52, 211, 153, 0.18), rgba(34, 211, 238, 0.08)),
    rgba(255, 255, 255, 0.055);
  animation: correctPulse 1.1s ease-out;
}

.player-row.answer-wrong {
  border-color: rgba(251, 113, 133, 0.48);
  background: rgba(251, 113, 133, 0.1);
}

.player-row.answer-missed {
  opacity: 0.74;
}

.player-name {
  display: flex;
  gap: 9px;
  align-items: center;
  min-width: 0;
}

.player-name strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.player-score {
  min-width: 96px;
  display: grid;
  justify-items: end;
  gap: 2px;
  font-weight: 950;
}

.player-score span {
  color: var(--faint);
  font-size: 11px;
  white-space: nowrap;
}

.answer-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 5px 8px;
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.1);
}

.answer-status.correct {
  color: #06281d;
  background: var(--green);
}

.answer-status.wrong {
  color: #320710;
  background: var(--red);
}

.answer-status.answered {
  color: #06172c;
  background: var(--blue);
}

.answer-status.missed {
  color: rgba(255, 255, 255, 0.64);
  background: rgba(255, 255, 255, 0.08);
}

.dot {
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
}

.dot.online {
  background: var(--green);
  box-shadow: 0 0 16px rgba(52, 211, 153, 0.48);
}

.stage-card {
  min-height: 420px;
  display: grid;
  gap: 16px;
  align-content: start;
}

.focus-stage {
  min-height: calc(100vh - 220px);
}

.round-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
}

.timer-wrap {
  min-width: 170px;
  display: grid;
  gap: 8px;
}

.timer-line {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
}

.timer-fill {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--green), var(--cyan), var(--pink));
  transform-origin: left center;
  transition: transform 0.25s linear;
}

.timer-number {
  text-align: right;
  color: #b7f7ff;
  font-weight: 950;
  font-size: 24px;
}

.question-text {
  margin: 0;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(3, 5, 15, 0.86), rgba(8, 12, 32, 0.74));
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.26);
  padding: clamp(18px, 3vw, 30px);
  font-size: clamp(30px, 3.4vw, 54px);
  line-height: 1.08;
  letter-spacing: 0;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.72);
}

.media-box {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  background: rgba(0, 0, 0, 0.22);
}

.media-box.is-missing {
  display: none;
}

.media-visual {
  height: clamp(190px, 35vh, 390px);
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 45%, rgba(34, 211, 238, 0.12), transparent 44%),
    rgba(2, 4, 13, 0.9);
}

.media-box img,
.media-box video {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 100%;
  object-fit: contain;
}

.media-error .media-visual::before {
  content: "";
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.media-error img,
.media-error video {
  display: none;
}

.media-error .media-caption::after {
  content: "";
  color: rgba(250, 204, 21, 0.72);
}

.media-caption {
  padding: 10px 14px 14px;
  color: var(--faint);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

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

.answer-button {
  min-height: 84px;
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 12px;
  align-items: center;
  padding: 14px;
  text-align: left;
  background: rgba(5, 8, 22, 0.78);
  cursor: pointer;
  transform: translateY(0);
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.answer-button:disabled {
  opacity: 1;
  cursor: default;
}

.answer-button.is-locked {
  cursor: default;
}

.answer-button:not(.is-locked):hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 14px 42px rgba(34, 211, 238, 0.1);
}

.answer-button strong {
  color: #fff;
  font-size: 16px;
  line-height: 1.35;
}

.answer-button.with-thumb {
  grid-template-columns: 36px 82px 1fr;
}

.answer-thumb {
  width: 82px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.07);
}

.answer-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.answer-letter {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  font-weight: 950;
}

.answer-button.selected {
  border-color: rgba(96, 165, 250, 0.6);
  background: rgba(96, 165, 250, 0.14);
}

.answer-button.correct {
  border-color: rgba(52, 211, 153, 0.72);
  background: rgba(52, 211, 153, 0.14);
}

.answer-button.wrong {
  border-color: rgba(251, 113, 133, 0.62);
  background: rgba(251, 113, 133, 0.12);
}

.answer-meta {
  display: grid;
  gap: 6px;
}

.answer-count {
  color: rgba(255, 255, 255, 0.64);
  font-size: 12px;
  font-weight: 800;
}

.reveal-note {
  border: 1px solid rgba(34, 211, 238, 0.2);
  background: rgba(5, 8, 22, 0.7);
  border-radius: 18px;
  padding: 14px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
}

.correct-reveal {
  position: relative;
  overflow: hidden;
  min-height: 86px;
  display: grid;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.06);
  padding: 18px;
}

.correct-reveal.has-winners {
  border-color: rgba(52, 211, 153, 0.58);
  background:
    radial-gradient(circle at 22% 24%, rgba(52, 211, 153, 0.24), transparent 34%),
    radial-gradient(circle at 76% 20%, rgba(232, 121, 249, 0.18), transparent 32%),
    rgba(6, 18, 22, 0.78);
  box-shadow: 0 20px 60px rgba(52, 211, 153, 0.14);
}

.correct-reveal span {
  color: var(--faint);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.correct-reveal strong {
  color: #fff;
  font-size: clamp(20px, 2.6vw, 34px);
  line-height: 1.12;
}

.rtc-panel {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: 18px;
  background:
    radial-gradient(circle at 18% 0%, rgba(34, 211, 238, 0.12), transparent 40%),
    rgba(255, 255, 255, 0.045);
  padding: 14px;
}

.rtc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.rtc-head > div:first-child {
  display: grid;
  gap: 3px;
}

.rtc-head strong {
  font-size: 17px;
}

.rtc-head span {
  color: var(--faint);
  font-size: 12px;
  font-weight: 800;
}

.rtc-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.rtc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 10px;
}

.rtc-tile {
  position: relative;
  overflow: hidden;
  min-height: 112px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background: rgba(4, 6, 17, 0.82);
}

.rtc-tile video {
  width: 100%;
  height: 112px;
  display: block;
  object-fit: cover;
  background: radial-gradient(circle at 50% 40%, rgba(34, 211, 238, 0.16), transparent 42%), #050816;
}

.rtc-tile.audio-only video {
  display: none;
}

.rtc-avatar {
  min-height: 112px;
  display: none;
  place-items: center;
  color: #04101c;
  background: linear-gradient(135deg, var(--cyan), var(--pink));
  font-size: 42px;
  font-weight: 950;
}

.rtc-tile.audio-only .rtc-avatar {
  display: grid;
}

.rtc-tile span {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  border-radius: 999px;
  background: rgba(4, 6, 17, 0.78);
  color: #fff;
  padding: 6px 8px;
  font-size: 11px;
  font-weight: 850;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.confetti i {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  left: 50%;
  top: 50%;
  animation: firework 1.1s ease-out forwards;
}

.confetti i:nth-child(2) { background: var(--pink); --x: 130px; --y: -54px; }
.confetti i:nth-child(3) { background: var(--green); --x: -120px; --y: -42px; }
.confetti i:nth-child(4) { background: #facc15; --x: 86px; --y: 66px; }
.confetti i:nth-child(5) { background: #60a5fa; --x: -86px; --y: 64px; }
.confetti i:nth-child(6) { background: #fb7185; --x: 34px; --y: -96px; }
.confetti i:nth-child(7) { background: #a78bfa; --x: -38px; --y: -88px; }
.confetti i:nth-child(8) { background: #34d399; --x: 158px; --y: 20px; }

.final-panel {
  min-height: 70vh;
  place-items: center;
  text-align: center;
}

.answer-key {
  width: min(980px, 100%);
  display: grid;
  gap: 10px;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  background: rgba(5, 8, 22, 0.72);
  padding: 18px;
}

.answer-key-row {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.045);
  padding: 14px;
}

.answer-key-round {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(34, 211, 238, 0.14);
  color: #b7f7ff;
  font-weight: 950;
}

.answer-key-main {
  display: grid;
  gap: 7px;
}

.answer-key-main strong {
  line-height: 1.4;
}

.answer-key-main span {
  color: #b7f7ff;
  font-weight: 900;
}

.answer-key-main em {
  color: rgba(255, 255, 255, 0.68);
  font-style: normal;
  line-height: 1.55;
}

.final-title {
  margin: 0;
  font-size: clamp(42px, 7vw, 92px);
  line-height: 0.94;
  letter-spacing: -0.05em;
}

.winner-name {
  color: #b7f7ff;
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.86;
  }
  50% {
    transform: scale(1.05);
    opacity: 1;
  }
}

@keyframes ambientFlow {
  0% {
    transform: translate3d(-1.5%, -1%, 0) scale(1);
    filter: hue-rotate(0deg);
  }
  50% {
    transform: translate3d(1%, 0.8%, 0) scale(1.025);
    filter: hue-rotate(8deg);
  }
  100% {
    transform: translate3d(1.5%, -0.4%, 0) scale(1.04);
    filter: hue-rotate(-6deg);
  }
}

@keyframes topbarDrop {
  from {
    opacity: 0;
    transform: translateY(-16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pageRise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes controlIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes logoBreath {
  0%,
  100% {
    transform: scale(1);
    filter: drop-shadow(0 0 12px rgba(34, 211, 238, 0.18));
  }
  50% {
    transform: scale(1.035);
    filter: drop-shadow(0 0 22px rgba(232, 121, 249, 0.24));
  }
}

@keyframes logoFloat {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-8px) rotate(1deg);
  }
}

@keyframes selectedPulse {
  0%,
  100% {
    box-shadow: 0 14px 38px rgba(34, 211, 238, 0.08);
  }
  50% {
    box-shadow: 0 18px 48px rgba(232, 121, 249, 0.16);
  }
}

@keyframes buttonShine {
  0%,
  54% {
    transform: translateX(-120%);
  }
  76% {
    transform: translateX(120%);
  }
  100% {
    transform: translateX(120%);
  }
}

@keyframes correctPulse {
  0% {
    transform: scale(0.985);
    box-shadow: 0 0 0 rgba(52, 211, 153, 0);
  }
  42% {
    transform: scale(1.015);
    box-shadow: 0 0 34px rgba(52, 211, 153, 0.36);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 rgba(52, 211, 153, 0);
  }
}

@keyframes firework {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(0.8);
  }
  78% {
    opacity: 1;
    transform: translate(calc(-50% + var(--x, 96px)), calc(-50% + var(--y, -72px))) scale(1.2);
  }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--x, 96px)), calc(-50% + var(--y, -72px) + 16px)) scale(0.4);
  }
}

.intro-screen {
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  background: #02030c;
}

.intro-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.intro-start,
.intro-actions {
  position: absolute;
  left: 0;
  right: 0;
  bottom: clamp(24px, 7vh, 72px);
  z-index: 1;
  display: flex;
  justify-content: center;
  padding: 0 20px;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.42s ease, transform 0.42s ease;
}

.intro-start {
  opacity: 1;
  transform: translateY(0);
}

.intro-start[hidden],
.intro-actions[hidden] {
  display: none;
}

.intro-actions.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.intro-start .btn,
.intro-actions .btn {
  min-width: min(360px, 100%);
  min-height: 58px;
}

.wizard-page {
  position: relative;
  min-height: calc(100svh - 76px);
  display: grid;
  place-items: center;
  padding: clamp(14px, 2.5vw, 34px);
  overflow: hidden;
  isolation: isolate;
}

.wizard-page::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(3, 5, 18, 0.78), rgba(3, 5, 18, 0.28) 48%, rgba(3, 5, 18, 0.82)),
    url("/assets/images/landing_hero_4k.png") center / cover no-repeat;
  transform: scale(1.035);
  filter: saturate(1.08) contrast(1.03);
}

.wizard-page::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 22% 22%, rgba(34, 211, 238, 0.13), transparent 26%),
    radial-gradient(circle at 78% 32%, rgba(232, 121, 249, 0.13), transparent 30%),
    linear-gradient(180deg, rgba(2, 3, 12, 0.12), rgba(2, 3, 12, 0.42));
}

.wizard-stage {
  width: min(1180px, 100%);
  display: grid;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.wizard-progress {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.mobile-stepbar {
  display: none;
}

.wizard-dot {
  min-width: 0;
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.045);
  color: rgba(255, 255, 255, 0.68);
  font-weight: 900;
  padding: 8px 10px;
}

.wizard-dot b {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.76);
  font-size: 12px;
}

.wizard-dot span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.wizard-dot.active {
  border-color: rgba(34, 211, 238, 0.44);
  background: rgba(34, 211, 238, 0.12);
  color: #fff;
  box-shadow: 0 16px 42px rgba(34, 211, 238, 0.12);
}

.wizard-dot.done b,
.wizard-dot.active b {
  background: linear-gradient(135deg, var(--cyan), var(--pink));
  color: #04101c;
}

.wizard-card {
  min-height: min(690px, calc(100svh - 158px));
  max-height: calc(100svh - 128px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto auto;
  gap: 18px;
  padding: clamp(18px, 2.8vw, 34px);
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(5, 7, 20, 0.74), rgba(3, 5, 16, 0.82));
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 110px rgba(0, 0, 0, 0.44);
  animation: pageRise 0.58s ease both;
}

.wizard-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: start;
}

.wizard-kicker {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 10px;
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.09);
  color: #b7f7ff;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.wizard-head h1 {
  margin: 0;
  font-size: clamp(38px, 5vw, 76px);
  line-height: 0.96;
  letter-spacing: 0;
}

.wizard-head p,
.wizard-hint {
  max-width: 850px;
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.5;
}

.wizard-body {
  min-height: 0;
  overflow: auto;
  padding-right: 4px;
}

.wizard-body::-webkit-scrollbar {
  width: 8px;
}

.wizard-body::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.32);
}

.wizard-footer {
  display: grid;
  grid-template-columns: minmax(150px, 220px) minmax(220px, 1fr);
  gap: 12px;
  align-items: center;
}

.name-step {
  min-height: 100%;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 18px;
}

.legal-step {
  min-height: 100%;
  display: grid;
  align-content: center;
  gap: 14px;
}

.legal-card {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  padding: 18px;
}

.legal-card strong {
  font-size: clamp(20px, 2vw, 28px);
  line-height: 1.1;
}

.legal-card span {
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.5;
}

.legal-check {
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 16px;
  background: rgba(34, 211, 238, 0.07);
  padding: 14px;
}

.name-step .field {
  width: min(620px, 100%);
}

.big-input {
  min-height: 74px;
  border-radius: 20px;
  font-size: clamp(22px, 3vw, 36px);
  font-weight: 900;
  text-align: center;
}

.join-inline {
  width: min(860px, 100%);
  display: grid;
  grid-template-columns: 1fr 1.4fr auto;
  gap: 10px;
  align-items: end;
  margin-top: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.045);
  padding: 14px;
}

.wizard-choice-grid {
  margin-top: 6px;
}

.age-grid,
.answers-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.age-card,
.answer-setup-card {
  min-height: 168px;
  display: grid;
  align-content: center;
  gap: 10px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.048);
  color: var(--text);
  text-align: left;
  padding: 22px;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.age-card strong {
  font-size: clamp(42px, 6vw, 72px);
  line-height: 0.9;
}

.answer-setup-card strong {
  font-size: clamp(22px, 2vw, 30px);
  line-height: 1.05;
}

.age-card span,
.answer-setup-card span {
  color: rgba(255, 255, 255, 0.66);
  line-height: 1.45;
}

.age-card:hover,
.answer-setup-card:hover {
  transform: translateY(-3px);
  border-color: rgba(34, 211, 238, 0.42);
  background: rgba(34, 211, 238, 0.07);
}

.age-card.active,
.answer-setup-card.active {
  border-color: var(--line-strong);
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.15), rgba(232, 121, 249, 0.12));
  box-shadow: 0 18px 48px rgba(34, 211, 238, 0.1);
}

.category-tools {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 16px;
  background: rgba(5, 8, 22, 0.88);
  padding: 12px;
  backdrop-filter: blur(14px);
}

.category-tools strong {
  color: #b7f7ff;
}

.wizard-category-grid {
  grid-template-columns: repeat(auto-fit, minmax(172px, 1fr));
}

.launch-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.launch-summary div {
  min-height: 112px;
  display: grid;
  align-content: end;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.05);
  padding: 16px;
}

.launch-summary span {
  color: rgba(255, 255, 255, 0.5);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.launch-summary strong {
  font-size: clamp(20px, 2.2vw, 31px);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.launch-help {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.1), rgba(232, 121, 249, 0.08)),
    rgba(5, 8, 22, 0.68);
  padding: 16px;
  color: rgba(255, 255, 255, 0.86);
}

.launch-help strong {
  color: #b7f7ff;
  font-size: 18px;
  line-height: 1.2;
}

.launch-help span {
  line-height: 1.55;
}

.account-card {
  width: min(760px, 100%);
  display: grid;
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 20px;
  background: rgba(5, 8, 22, 0.72);
  padding: 16px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.22);
}

.account-card.account-ready {
  grid-template-columns: 1fr auto;
  align-items: center;
  border-color: rgba(52, 211, 153, 0.32);
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.12), rgba(34, 211, 238, 0.08));
}

.account-card strong {
  display: block;
  font-size: 18px;
  line-height: 1.2;
}

.account-card span,
.account-message,
.contact-line {
  color: rgba(255, 255, 255, 0.66);
  line-height: 1.45;
}

.account-form {
  display: grid;
  gap: 10px;
}

.check-line {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 14px;
  line-height: 1.4;
}

.check-line input {
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  accent-color: var(--cyan);
}

.contact-line a {
  color: #b7f7ff;
  text-decoration: none;
}

.cookie-panel {
  position: fixed;
  left: max(16px, env(safe-area-inset-left));
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 80;
  width: min(980px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 22px;
  background: rgba(5, 8, 22, 0.94);
  box-shadow: 0 26px 90px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(22px);
  padding: 18px;
}

.cookie-panel strong {
  display: block;
  margin-bottom: 6px;
  font-size: 18px;
}

.cookie-panel p {
  margin: 0 0 10px;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.45;
}

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

.round-intro {
  min-height: min(560px, 62svh);
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: end start;
  border-radius: 22px;
  background: #030614;
  border: 1px solid rgba(34, 211, 238, 0.18);
  animation: pageRise 0.44s ease both;
}

.round-intro-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.round-intro-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(3, 5, 16, 0.72), rgba(3, 5, 16, 0.12) 58%, rgba(3, 5, 16, 0.68)),
    linear-gradient(0deg, rgba(3, 5, 16, 0.78), transparent 58%);
}

.round-intro-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  padding: clamp(22px, 4vw, 42px);
}

.round-intro-copy span {
  width: fit-content;
  border: 1px solid rgba(34, 211, 238, 0.34);
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.13);
  color: #b7f7ff;
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.round-intro-copy strong {
  max-width: 900px;
  font-size: clamp(44px, 7vw, 104px);
  line-height: 0.92;
  text-shadow: 0 8px 34px rgba(0, 0, 0, 0.46);
}

.round-intro-copy em {
  color: rgba(255, 255, 255, 0.72);
  font-style: normal;
  font-size: clamp(18px, 2.2vw, 30px);
  font-weight: 900;
}

.final-video-screen {
  min-height: calc(100svh - 76px);
  position: relative;
  z-index: 1;
  overflow: hidden;
  display: grid;
  place-items: end center;
  background: #02030c;
}

.final-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.final-video-actions {
  position: relative;
  z-index: 1;
  width: min(420px, calc(100% - 32px));
  padding: 0 0 max(24px, env(safe-area-inset-bottom));
}

.final-video-actions .btn {
  width: 100%;
  min-height: 58px;
}

.leaderboard-panel {
  width: min(860px, 100%);
  display: grid;
  gap: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.045);
  padding: 16px;
}

.leaderboard-hit {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(52, 211, 153, 0.36);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.16), rgba(34, 211, 238, 0.1));
  padding: 16px;
}

.leaderboard-hit span,
.leaderboard-note {
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.45;
}

.leaderboard-hit strong {
  font-size: clamp(22px, 3vw, 36px);
  line-height: 1.05;
}

.leaderboard-list {
  display: grid;
  gap: 8px;
}

.leaderboard-row {
  display: grid;
  grid-template-columns: 70px 1fr 110px 100px;
  gap: 10px;
  align-items: center;
  min-height: 54px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: rgba(3, 5, 16, 0.42);
  padding: 10px 12px;
}

.leaderboard-row.is-me {
  border-color: rgba(52, 211, 153, 0.36);
  background: rgba(52, 211, 153, 0.1);
}

.leaderboard-row span,
.leaderboard-row em {
  color: rgba(255, 255, 255, 0.54);
  font-style: normal;
  font-weight: 850;
}

.leaderboard-row b {
  text-align: right;
}

@keyframes introCardIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (min-width: 1260px) {
  .setup-name {
    grid-column: span 5;
  }

  .setup-mode {
    grid-column: span 7;
  }

  .setup-age,
  .setup-ranges {
    grid-column: span 12;
  }

  .setup-difficulty {
    grid-column: span 12;
  }
}

@media (max-width: 1160px) {
  .home-hero,
  .category-layout,
  .lobby-grid,
  .game-grid {
    grid-template-columns: 1fr;
  }

  .wizard-progress {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .join-inline,
  .launch-summary {
    grid-template-columns: 1fr 1fr;
  }

  .hero-copy {
    min-height: 420px;
  }

  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  html,
  body {
    font-size: 15px;
  }

  .page::before {
    inset: -8%;
    background:
      radial-gradient(circle at 18% 8%, rgba(34, 211, 238, 0.18), transparent 30%),
      radial-gradient(circle at 84% 18%, rgba(232, 121, 249, 0.14), transparent 28%),
      linear-gradient(180deg, #050716 0%, #060817 54%, #03040d 100%);
  }

  .topbar {
    min-height: 62px;
    align-items: center;
    gap: 8px;
    padding: 9px 10px;
  }

  .brand-label {
    display: none;
  }

  .brand {
    flex: 0 0 auto;
  }

  .brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 12px;
  }

  .top-actions {
    flex: 1 1 auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 7px;
    min-width: 0;
  }

  .btn,
  .chip-btn {
    min-height: 46px;
    padding: 0 13px;
    font-size: 14px;
  }

  .top-actions .chip-btn {
    min-height: 40px;
    padding: 0 10px;
    font-size: 13px;
    white-space: nowrap;
  }

  .shell {
    width: min(100% - 20px, 1500px);
  }

  .home-hero {
    min-height: auto;
    padding-top: 12px;
  }

  .hero-copy {
    min-height: 390px;
    padding: 18px;
    border-radius: 20px;
  }

  .hero-logo-lockup {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .hero-dashboard {
    grid-template-columns: 1fr;
  }

  .intro-start,
  .intro-actions {
    bottom: calc(24px + env(safe-area-inset-bottom));
    padding: 0 14px;
  }

  .intro-start .btn,
  .intro-actions .btn {
    width: 100%;
    min-width: 0;
    min-height: 56px;
    border-radius: 16px;
  }

  .difficulty-grid,
  .mode-grid,
  .range-grid,
  .timer-choice-grid,
  .answers-grid,
  .age-grid,
  .join-inline,
  .launch-summary,
  .share-grid,
  .onboarding-steps,
  .launch-panel {
    grid-template-columns: 1fr;
  }

  .wizard-page {
    min-height: calc(100svh - 62px);
    align-items: start;
    place-items: start center;
    padding: 10px;
    overflow: visible;
  }

  .wizard-page::before {
    background:
      linear-gradient(180deg, rgba(3, 5, 18, 0.78), rgba(3, 5, 18, 0.5) 48%, rgba(3, 5, 18, 0.88)),
      url("/assets/images/landing_hero_4k.png") center / cover no-repeat;
    transform: scale(1.02);
  }

  .wizard-stage {
    gap: 10px;
  }

  .wizard-card {
    width: 100%;
    min-height: auto;
    max-height: none;
    gap: 14px;
    padding: 16px;
    border-radius: 20px;
    overflow: visible;
    background:
      linear-gradient(180deg, rgba(5, 7, 20, 0.88), rgba(3, 5, 16, 0.94));
  }

  .wizard-progress {
    display: none;
  }

  .mobile-stepbar {
    position: sticky;
    bottom: 0;
    z-index: 5;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    min-height: 34px;
    margin-top: -2px;
    padding: 7px 12px calc(7px + env(safe-area-inset-bottom));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px 14px 0 0;
    background: rgba(4, 6, 17, 0.96);
    backdrop-filter: blur(18px);
  }

  .mobile-stepbar span {
    color: rgba(255, 255, 255, 0.72);
    font-size: 11px;
    font-weight: 950;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
  }

  .mobile-stepbar-track {
    height: 5px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
  }

  .mobile-stepbar-track b {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--cyan), var(--blue), var(--pink));
    transition: width 0.28s ease;
  }

  .wizard-head {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .wizard-kicker {
    margin-bottom: 8px;
    padding: 7px 10px;
    font-size: 10px;
  }

  .wizard-head h1 {
    font-size: clamp(34px, 10vw, 50px);
    line-height: 1;
  }

  .wizard-head p,
  .wizard-hint {
    margin-top: 8px;
    font-size: 14px;
    line-height: 1.45;
  }

  .wizard-body {
    overflow: visible;
    padding-right: 0;
  }

  .name-step {
    min-height: auto;
    align-content: start;
    gap: 14px;
  }

  .legal-step {
    align-content: start;
  }

  .legal-card,
  .legal-check,
  .account-card {
    border-radius: 16px;
    padding: 14px;
  }

  .account-card.account-ready {
    grid-template-columns: 1fr;
  }

  .cookie-panel {
    grid-template-columns: 1fr;
    left: 10px;
    right: 10px;
    bottom: 10px;
    width: calc(100% - 20px);
    padding: 14px;
    border-radius: 18px;
  }

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

  .big-input {
    min-height: 62px;
    border-radius: 18px;
    font-size: clamp(24px, 8vw, 34px);
  }

  .field span,
  .block-title {
    font-size: 14px;
  }

  .input {
    min-height: 52px;
    border-radius: 14px;
    font-size: 16px;
  }

  .choice-card {
    min-height: 72px;
    padding: 13px 14px;
  }

  .choice-card strong {
    font-size: 16px;
  }

  .age-card,
  .answer-setup-card {
    min-height: 104px;
    padding: 16px;
    border-radius: 16px;
  }

  .age-card strong {
    font-size: 42px;
  }

  .answer-setup-card strong {
    font-size: 21px;
  }

  .range-box {
    padding: 14px;
  }

  .category-tools {
    position: static;
    display: grid;
    align-items: stretch;
    gap: 10px;
  }

  .category-tools .switch-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .wizard-category-grid,
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }

  .category-card {
    min-height: 86px;
    padding: 12px;
  }

  .category-card strong {
    font-size: 14px;
  }

  .launch-summary div {
    min-height: 82px;
    padding: 14px;
    border-radius: 16px;
  }

  .launch-help {
    padding: 14px;
    border-radius: 16px;
  }

  .launch-help strong {
    font-size: 17px;
  }

  .wizard-footer {
    position: sticky;
    bottom: 34px;
    z-index: 4;
    grid-template-columns: 1fr;
    gap: 9px;
    margin: 0 -16px -16px;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: linear-gradient(180deg, rgba(5, 7, 20, 0.55), rgba(5, 7, 20, 0.98));
    backdrop-filter: blur(18px);
  }

  .wizard-footer .btn {
    width: 100%;
  }

  .room-shell {
    gap: 12px;
    padding-top: 12px;
    padding-bottom: 18px;
  }

  .room-top {
    padding: 14px;
    gap: 12px;
    border-radius: 20px;
  }

  .room-code {
    font-size: clamp(38px, 14vw, 58px);
    line-height: 0.95;
  }

  .game-title {
    font-size: clamp(26px, 8vw, 38px);
    line-height: 1;
  }

  .stat-strip {
    gap: 7px;
  }

  .stat-strip span,
  .pill {
    min-height: 32px;
    padding: 7px 10px;
    font-size: 12px;
  }

  .lobby-main,
  .game-main,
  .side-panel,
  .join-room-panel,
  .final-panel {
    padding: 14px;
    gap: 12px;
    border-radius: 20px;
  }

  .panel-head {
    gap: 8px;
  }

  .panel-head h2,
  .panel-head h3 {
    font-size: clamp(22px, 7vw, 30px);
    line-height: 1.08;
  }

  .invite-line {
    padding: 12px;
    font-size: 14px;
    border-radius: 14px;
  }

  .share-grid {
    grid-template-columns: 1fr;
  }

  .stage-card,
  .focus-stage {
    min-height: auto;
  }

  .round-header {
    gap: 8px;
  }

  .timer-wrap {
    min-width: 0;
    width: 100%;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 10px;
  }

  .timer-number {
    min-width: 46px;
    text-align: left;
    font-size: 22px;
  }

  .timer-line {
    height: 9px;
  }

  .question-text {
    border-radius: 18px;
    padding: 16px;
    font-size: clamp(24px, 7.2vw, 34px);
    line-height: 1.12;
    overflow-wrap: anywhere;
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.64);
  }

  .media-box {
    border-radius: 18px;
  }

  .round-intro {
    min-height: min(430px, 54svh);
    border-radius: 18px;
  }

  .round-intro-copy {
    padding: 22px;
  }

  .round-intro-copy strong {
    font-size: clamp(38px, 13vw, 64px);
  }

  .final-video-screen {
    min-height: calc(100svh - 62px);
  }

  .leaderboard-row {
    grid-template-columns: 48px 1fr 80px;
  }

  .leaderboard-row em {
    grid-column: 2 / -1;
  }

  .media-visual {
    height: clamp(160px, 30vh, 280px);
  }

  .media-caption {
    padding: 8px 12px 11px;
    font-size: 11px;
  }

  .answers-grid {
    gap: 9px;
  }

  .answer-button {
    min-height: 64px;
    grid-template-columns: 34px 1fr;
    gap: 10px;
    padding: 12px;
    border-radius: 16px;
  }

  .answer-button strong {
    font-size: 15px;
  }

  .answer-letter {
    width: 34px;
    height: 34px;
    border-radius: 11px;
  }

  .answer-button.with-thumb {
    grid-template-columns: 34px 58px 1fr;
  }

  .answer-thumb {
    width: 58px;
    border-radius: 12px;
  }

  .player-row {
    min-height: 58px;
    grid-template-columns: 1fr;
    gap: 7px;
    padding: 11px 12px;
  }

  .player-name {
    align-items: flex-start;
  }

  .player-name strong {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }

  .player-score {
    min-width: 0;
    justify-items: start;
  }

  .player-score span {
    white-space: normal;
  }

  .panel,
  .choice-card,
  .category-card,
  .answer-button,
  .player-row,
  .answer-key,
  .answer-key-row {
    border-radius: 16px;
  }

  .host-panel .btn,
  .join-room-panel .btn,
  .final-panel .btn {
    width: 100%;
  }
}

@media (max-width: 440px) {
  .shell {
    width: min(100% - 16px, 1500px);
  }

  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .hero-logo {
    width: 72px;
    height: 72px;
  }

  .topbar {
    padding: 8px;
    gap: 6px;
  }

  .top-actions {
    gap: 5px;
  }

  .top-actions .chip-btn {
    min-height: 38px;
    padding: 0 8px;
    font-size: 12px;
  }

  .wizard-card {
    padding: 14px;
  }

  .wizard-head h1 {
    font-size: clamp(32px, 11vw, 46px);
  }

  .category-tools .switch-row {
    grid-template-columns: 1fr;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .wizard-category-grid {
    grid-template-columns: 1fr;
  }

  .question-text {
    font-size: clamp(22px, 7.4vw, 30px);
    padding: 14px;
  }

  .media-visual {
    height: clamp(150px, 27vh, 240px);
  }

  .answer-button.with-thumb {
    grid-template-columns: 32px 52px 1fr;
  }

  .answer-thumb {
    width: 52px;
  }

  .answer-letter {
    width: 32px;
    height: 32px;
  }

  .answer-key-row {
    grid-template-columns: 1fr;
  }
}
