:root {
  --bg: #f4f3f8;
  --surface: #ffffff;
  --surface-2: #eceaf5;
  --ink: #17152d;
  --muted: #6b6680;
  --line: #d8d3e6;
  --accent: #e94560;
  --accent-2: #533483;
  --danger: #bf2942;
  --good: #12815c;
  --focus: #168bd2;
  --shadow: 0 20px 60px rgba(26, 18, 70, .12);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0a1d;
    --surface: #15132d;
    --surface-2: #211c41;
    --ink: #f9f8ff;
    --muted: #b2add0;
    --line: #342e57;
    --accent: #ff5870;
    --accent-2: #8b4fd4;
    --danger: #ff7188;
    --good: #5ed3a4;
    --focus: #56ccff;
    --shadow: 0 20px 60px rgba(0, 0, 0, .36);
  }
}

:root[data-theme="dark"] {
  --bg: #0b0a1d;
  --surface: #15132d;
  --surface-2: #211c41;
  --ink: #f9f8ff;
  --muted: #b2add0;
  --line: #342e57;
  --accent: #ff5870;
  --accent-2: #8b4fd4;
  --danger: #ff7188;
  --good: #5ed3a4;
  --focus: #56ccff;
  --shadow: 0 20px 60px rgba(0, 0, 0, .36);
}

/* Match the TuneSwiper Collection home link. */
.site-footer a.footer-home {
  display: inline-flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 10px;
  margin: 0;
  padding: 10px 18px 10px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #1c1c19;
  color: #f4f3ed;
  font-size: .9rem;
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .06);
  transition: background .18s ease, border-color .18s ease;
}

.footer-home-logo {
  display: block;
  flex: 0 0 112px;
  width: 112px;
  height: 34px;
  overflow: hidden;
}

.footer-home-logo img {
  width: 175px;
  height: auto;
  max-width: none;
}

.footer-home-arrow {
  flex-shrink: 0;
}

.site-footer a.footer-home:hover,
.site-footer a.footer-home:focus-visible {
  background: #282824;
  border-color: var(--accent);
  color: #f4f3ed;
}

@media (max-width: 520px) {
  .site-footer .footer-home + p {
    margin-top: 8px;
  }
}

body {
  background:
    radial-gradient(circle at 4% 4%, color-mix(in srgb, var(--accent-2) 12%, transparent), transparent 28rem),
    var(--bg);
}

.site-header {
  height: 72px;
}

.brand {
  min-width: max-content;
  flex: 0 0 auto;
}

.brand > span.brand-wordmark {
  display: inline-flex;
  align-items: center;
  flex-wrap: nowrap;
  color: var(--ink);
  font-size: .86rem;
  font-weight: 900;
  letter-spacing: .14em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.brand-wordmark strong {
  color: var(--accent);
  margin-right: .55em;
  font: inherit;
  text-shadow: 0 0 18px color-mix(in srgb, var(--accent) 28%, transparent);
}

.avatar,
.floating-chat {
  background: linear-gradient(135deg, #533483, #e94560);
  color: #fff;
}

.room-badge strong {
  color: var(--accent);
}

.button-primary {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  box-shadow: 0 8px 24px color-mix(in srgb, var(--accent) 26%, transparent);
}

.button-primary:hover {
  border-color: var(--accent-2);
  background: var(--accent-2);
  color: #fff;
}

.landing-main {
  grid-template-columns: minmax(0, 1.4fr) minmax(340px, .6fr);
  gap: 24px;
  align-items: stretch;
  min-height: calc(100vh - 205px);
  padding: 34px 0 52px;
}

.landing-hero {
  position: relative;
  isolation: isolate;
  display: flex;
  min-height: 660px;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: clamp(38px, 5vw, 76px);
  border: 1px solid rgba(152, 137, 255, .24);
  border-radius: 24px;
  background-color: #0f0c29;
  background-image:
    linear-gradient(90deg, rgba(10, 9, 32, .99) 0%, rgba(10, 9, 32, .94) 40%, rgba(10, 9, 32, .5) 66%, rgba(10, 9, 32, .12) 100%),
    url("../images/hero-music-game.webp");
  background-position: center;
  background-size: cover;
  box-shadow: 0 28px 80px rgba(15, 12, 41, .26);
  color: #fff;
}

.landing-hero::after {
  position: absolute;
  z-index: -1;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: inherit;
  content: "";
  pointer-events: none;
}

.landing-hero .eyebrow,
.hero-panel .eyebrow {
  color: #ff7188;
}

.hero-brand-lockup {
  position: relative;
  width: min(760px, 100%);
  margin: 2px 0 18px;
  padding-bottom: 18px;
}

.hero-brand-lockup::after {
  position: absolute;
  right: 3%;
  bottom: 0;
  left: 0;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, #56ccff, #8b4fd4 48%, #e94560 82%, transparent);
  box-shadow: 0 0 24px rgba(86, 204, 255, .3);
  content: "";
}

.hero-brand-logo {
  display: block;
  width: min(330px, 48%);
  height: auto;
  margin: -28px 0 18px -34px;
  filter: drop-shadow(0 14px 30px rgba(0, 0, 0, .35));
}

.hero-game-title {
  display: flex;
  align-items: baseline;
  gap: .13em;
  width: max-content;
  max-width: 100%;
  margin: 0;
  color: #fff;
  font-size: clamp(3.7rem, 7.1vw, 7.7rem);
  font-weight: 950;
  letter-spacing: -.075em;
  line-height: .78;
  text-transform: uppercase;
  text-shadow: 0 12px 34px rgba(0, 0, 0, .4);
  white-space: nowrap;
}

.hero-title-hit {
  color: #ff5870;
  text-shadow: 0 0 34px rgba(233, 69, 96, .33), 0 12px 34px rgba(0, 0, 0, .4);
}

.hero-title-or {
  position: relative;
  top: -.2em;
  padding: .28em .42em;
  border: 1px solid rgba(86, 204, 255, .48);
  border-radius: 999px;
  background: rgba(15, 12, 41, .72);
  color: #8edfff;
  font-size: .24em;
  letter-spacing: .08em;
  line-height: 1;
}

.landing-hero h1 {
  max-width: 720px;
  text-shadow: 0 10px 34px rgba(0, 0, 0, .35);
}

.landing-hero h1 em {
  color: #fff;
  text-decoration-color: #e94560;
}

.landing-hero .lede {
  max-width: 610px;
  color: #d3cfea;
}

.landing-hero .button:not(.button-primary) {
  border-color: rgba(255, 255, 255, .28);
  background: rgba(16, 13, 46, .72);
  color: #fff;
  backdrop-filter: blur(10px);
}

.landing-hero .button:not(.button-primary):hover {
  border-color: #56ccff;
}

.landing-hero .access-note {
  max-width: 590px;
  color: #aba5cc;
}

.rules-card {
  align-self: stretch;
  padding: 12px 12px 26px;
  border-color: #342e57;
  border-radius: 24px;
  background: #15132d;
  box-shadow: 0 24px 70px rgba(15, 12, 41, .25);
  color: #fff;
}

.rules-art {
  display: block;
  aspect-ratio: 4 / 3;
  margin-bottom: 26px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 16px;
  background: #0f0c29 url("../images/rules-game-art.webp") center / cover no-repeat;
}

.rules-art span {
  display: none;
}

.rules-card ol {
  gap: 22px;
  padding: 0 14px;
}

.rules-card li {
  grid-template-columns: 34px 1fr;
}

.rules-card li::before {
  color: #ff5870;
  font-size: .78rem;
}

.rules-card li span {
  color: #aaa5c9;
  font-size: .86rem;
}

.hero-panel {
  min-height: 560px;
  border: 1px solid rgba(152, 137, 255, .22);
  background-color: #0f0c29;
  background-image:
    linear-gradient(90deg, rgba(10, 9, 32, .99) 0%, rgba(10, 9, 32, .92) 45%, rgba(10, 9, 32, .44) 72%, rgba(10, 9, 32, .1) 100%),
    url("../images/hero-music-game.webp");
  background-position: center;
  background-size: cover;
  box-shadow: var(--shadow);
  color: #fff;
}

.hero-panel::after {
  content: none;
}

.hero-panel > p:not(.eyebrow) {
  color: #c7c2e2;
}

.hero-panel .entry-actions > span {
  color: #aaa5c9;
}

.hero-panel .entry-actions input {
  border-color: rgba(255, 255, 255, .25);
  background: rgba(10, 9, 32, .78);
  color: #fff;
}

.hero-panel .entry-actions input::placeholder {
  color: #8f89b6;
}

.hero-panel .button:not(.button-primary) {
  border-color: rgba(255, 255, 255, .28);
  background: rgba(16, 13, 46, .72);
  color: #fff;
}

.panel,
.quiz-card,
.chat-panel {
  box-shadow: 0 14px 44px color-mix(in srgb, #533483 9%, transparent);
}

.playlist-choice.selected {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

@media (hover: hover) {
  .playlist-choice:hover {
    border-color: var(--accent);
    background: var(--accent);
    color: #fff;
  }
}

.toggle-card input {
  accent-color: var(--accent);
}

.cover-wrap {
  border: 1px solid color-mix(in srgb, var(--accent-2) 58%, var(--line));
  background: radial-gradient(circle at 50% 45%, #533483, #0f0c29 66%);
}

.sound-mark i {
  background: linear-gradient(180deg, #56ccff, #533483 52%, #e94560);
}

.timer circle:last-child {
  stroke: var(--accent);
}

.choice:hover:not(:disabled),
.choice.selected {
  border-color: var(--accent);
}

.choice.selected {
  background: color-mix(in srgb, var(--accent-2) 16%, var(--surface));
}

.seat.finished {
  box-shadow: inset 4px 0 0 var(--accent);
}

.podium-row strong {
  width: 44px;
  height: 44px;
  background-position: center;
  background-size: contain;
  background-repeat: no-repeat;
  color: transparent;
  font-size: 0;
}

.podium-row:nth-child(1) strong { background-image: url("../brand/crown-gold.svg"); }
.podium-row:nth-child(2) strong { background-image: url("../brand/crown-silver.svg"); }
.podium-row:nth-child(3) strong { background-image: url("../brand/crown-bronze.svg"); }

.podium-row:first-child {
  background: linear-gradient(135deg, #533483, #e94560);
  color: #fff;
}

@media (min-width: 821px) {
  .track-stage {
    grid-template-columns: minmax(240px, min(32vw, 430px)) minmax(0, 1fr);
    grid-template-rows: auto clamp(132px, 12vw, 158px);
    column-gap: clamp(28px, 6vw, 80px);
    row-gap: 0;
    align-items: start;
  }

  .track-stage > .cover-wrap {
    grid-column: 1;
    grid-row: 1;
  }

  .track-stage > .question-copy {
    grid-column: 2;
    grid-row: 1;
    align-self: center;
  }

  .track-stage > .reveal {
    grid-column: 1;
    grid-row: 2;
    align-self: start;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 20px 4px 0;
    overflow: hidden;
    border-top: 0;
  }

  .track-stage > .reveal h2 {
    overflow: hidden;
    font-size: clamp(1.9rem, 3vw, 3.2rem);
    line-height: .96;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .track-stage > .reveal > p:last-child {
    margin: 7px 0 0;
    overflow: hidden;
    font-size: 1rem;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

@media (max-width: 1120px) {
  .landing-main {
    grid-template-columns: minmax(0, 1fr) minmax(320px, .58fr);
    gap: 18px;
  }

  .landing-hero {
    min-height: 620px;
  }
}

@media (max-width: 820px) {
  .site-header {
    height: 68px;
  }

  .landing-main {
    display: block;
    padding: 22px 0 44px;
  }

  .landing-hero {
    min-height: 620px;
    background-image:
      linear-gradient(90deg, rgba(10, 9, 32, .99) 0%, rgba(10, 9, 32, .91) 55%, rgba(10, 9, 32, .3) 100%),
      url("../images/hero-music-game.webp");
    background-position: 58% center;
  }

  .rules-card {
    margin-top: 20px;
  }
}

@media (max-width: 520px) {
  .site-header {
    height: 64px;
  }

  .brand-wordmark {
    font-size: .72rem;
    letter-spacing: .11em;
  }

  .brand-wordmark strong {
    margin-right: .45em;
  }

  .hero-brand-lockup {
    margin-bottom: 16px;
    padding-bottom: 15px;
  }

  .hero-brand-logo {
    width: min(245px, 72%);
    margin: -18px 0 14px -20px;
  }

  .hero-game-title {
    gap: .11em;
    font-size: clamp(3rem, 15.2vw, 4.25rem);
    letter-spacing: -.07em;
  }

  .landing-hero {
    min-height: 610px;
    padding: 34px 24px;
    border-radius: 20px;
    background-image:
      linear-gradient(180deg, rgba(10, 9, 32, .93) 0%, rgba(10, 9, 32, .97) 58%, rgba(10, 9, 32, .82) 100%),
      url("../images/hero-music-game.webp");
    background-position: 70% center;
  }

  .rules-card {
    border-radius: 20px;
  }

  .rules-card ol {
    padding-inline: 8px;
  }

  .hero-panel {
    background-position: 68% center;
  }
}


@media (max-width: 820px) {
  body.is-playing {
    height: 100dvh;
    overflow: hidden;
  }

  body.is-playing .game-shell {
    height: calc(100dvh - 68px);
    padding: 8px 0 10px;
    overflow: hidden;
  }

  body.is-playing .game-column,
  body.is-playing #gameView {
    min-height: 0;
    height: 100%;
  }

  body.is-playing #gameView {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
  }

  body.is-playing .score-strip {
    min-height: 0;
    margin: 0 0 6px;
  }

  body.is-playing .score-player {
    min-width: 108px;
    padding: 6px 8px;
  }

  body.is-playing .quiz-card {
    display: grid;
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr) auto;
    padding: 12px 14px;
    overflow: hidden;
  }

  body.is-playing .round-top {
    min-height: 42px;
  }

  body.is-playing .round-top .eyebrow {
    margin-bottom: 0;
  }

  body.is-playing .timer {
    width: 42px;
    height: 42px;
  }

  body.is-playing .track-stage {
    position: relative;
    display: block;
    min-height: 0;
    margin-top: 6px;
  }

  body.is-playing .cover-wrap {
    position: absolute;
    top: -50px;
    right: 52px;
    width: 42px;
    margin: 0;
    border-radius: 10px;
    box-shadow: none;
  }

  body.is-playing .sound-mark {
    height: 38px;
    gap: 2px;
  }

  body.is-playing .sound-mark i {
    width: 4px;
  }

  body.is-playing .audio-unlock {
    inset: 0;
    min-height: 0;
    padding: 0;
    border: 0;
    border-radius: 9px;
    font-size: .58rem;
  }

  body.is-playing .playback-status {
    margin: 0 0 2px;
  }

  body.is-playing .quiz-card h1 {
    font-size: clamp(1.8rem, 8vw, 2.6rem);
    line-height: .94;
  }

  body.is-playing .choices {
    gap: 6px;
    margin-top: 10px;
  }

  body.is-playing .choice {
    min-height: clamp(42px, 7dvh, 54px);
    padding: 6px 10px;
    grid-template-columns: 30px minmax(0, 1fr);
    line-height: 1.2;
  }

  body.is-playing .choice span {
    width: 26px;
    height: 26px;
  }

  body.is-playing #gameView.is-revealed .choices {
    display: none;
  }

  body.is-playing .reveal {
    margin-top: 12px;
    padding-top: 12px;
  }

  body.is-playing .reveal .eyebrow {
    margin-bottom: 5px;
  }

  body.is-playing .reveal h2 {
    font-size: clamp(1.8rem, 9vw, 3rem);
  }

  body.is-playing .reveal > p:last-child {
    margin: 5px 0 0;
    font-size: .95rem;
  }

  body.is-playing .quiz-actions {
    min-height: 40px;
    margin-top: 8px;
    flex-direction: row;
    align-items: center;
    gap: 6px;
  }

  body.is-playing .quiz-actions .button,
  body.is-playing .quiz-actions .text-button {
    min-height: 36px;
    padding: 6px 9px;
    font-size: .76rem;
  }

  body.is-playing .host-round-actions {
    margin-left: auto;
    flex-wrap: nowrap;
    gap: 4px;
  }
}

@media (max-width: 820px) and (max-height: 600px) {
  body.is-playing .score-strip {
    display: none;
  }

  body.is-playing .choices {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.is-playing .choice {
    min-height: 42px;
  }

  body.is-playing .quiz-card h1 {
    font-size: 1.7rem;
  }
}

@media (max-width: 520px) {
  body.is-playing .game-shell {
    height: calc(100dvh - 64px);
  }
}
