/* Skybound UI. Palette from the key art: ink black + graphite, silver-white type, electric cyan
   neon and warm amber. Glow is used sparingly: primary buttons, focus rings and a few HUD accents. */

:root {
  --ink: #0d0f14;
  --ink-2: #141821;
  --graphite: #1f2430;
  --steel: #343b4a;
  --muted: #9aa6b8;
  --silver: #cfd6df;
  --white: #f4f7fa;
  --cyan: #1fb2ff;
  --cyan-hi: #7fdcff;
  --blue: #1a5cff;
  --amber: #ff9f1c;
  --amber-hi: #ffc15e;
  --good: #3ddc97;
  --glass: rgba(13, 15, 20, 0.74);
  --glass-2: rgba(20, 24, 33, 0.86);
  --line: rgba(127, 220, 255, 0.16);
  --line-strong: rgba(127, 220, 255, 0.42);
  --radius: 18px;
  --display: 'Rubik', 'Nunito', system-ui, sans-serif;
  --marker: 'Permanent Marker', 'Rubik', cursive;
  --body: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ts: 1;
  font-size: calc(16px * var(--ts));
}

* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: var(--ink);
  color: var(--white);
  font-family: var(--body);
  font-weight: 700;
  -webkit-font-smoothing: antialiased;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
#gl {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  outline: none;
}
#fade {
  position: fixed;
  inset: 0;
  background: #fff;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
  z-index: 5;
}
#fade.on {
  opacity: 0.85;
}
#fade.dark {
  background: #05070b;
}

/* ── Boot ───────────────────────────────────────────────────────────────────────────────── */
#boot {
  position: fixed;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 14px;
  background: radial-gradient(1200px 700px at 50% 30%, #16324a 0%, var(--ink) 70%);
  z-index: 50;
  transition: opacity 0.5s ease;
}
#boot.gone {
  opacity: 0;
  pointer-events: none;
}
/* Start screen: the key art as a framed hero, over a blurred, darkened copy of itself as wallpaper. */
#boot {
  grid-auto-flow: column;
  align-items: center;
  gap: clamp(20px, 5vw, 72px);
  padding: 16px;
  overflow: hidden;
}
#boot .boot-logo {
  font-size: clamp(40px, 6.4vw, 104px);
}
.boot-art {
  position: absolute;
  inset: -60px;
  background: #0d0f14 url('/img/azzy/poster-1-s.webp') center / cover no-repeat;
  filter: blur(30px) saturate(1.25) brightness(0.42);
  transform: scale(1.08);
  z-index: -1;
}
.boot-poster {
  display: block;
  height: min(78vh, 720px, 56vw);
  width: auto;
  aspect-ratio: 900 / 1125;
  border-radius: 14px;
  border: 2px solid rgba(31, 178, 255, 0.75);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.4), 0 0 32px rgba(31, 178, 255, 0.35), 0 24px 60px rgba(0, 0, 0, 0.55);
  object-fit: cover;
}
.boot-side {
  display: grid;
  justify-items: center;
  gap: 14px;
}
@media (max-width: 760px), (max-aspect-ratio: 4/5) {
  #boot {
    grid-auto-flow: row;
    gap: 16px;
  }
  .boot-poster {
    height: min(46vh, 520px, 110vw);
  }
  #boot .boot-logo {
    font-size: clamp(40px, 11vw, 80px);
  }
}
.boot-logo,
.logo {
  font-family: var(--display);
  font-weight: 900;
  font-style: italic;
  letter-spacing: 0.02em;
  line-height: 0.9;
}
.boot-logo {
  font-size: clamp(48px, 9vw, 108px);
}
/* "AZZY ZONE" graffiti lockup from the key art: white AZZY, cyan ZONE, a touch of glow. */
.brand-top {
  font-family: var(--marker);
  font-size: clamp(30px, 5vw, 60px);
  letter-spacing: 0.04em;
  line-height: 1;
  transform: rotate(-2deg);
  margin-bottom: 4px;
}
.brand-top .az-a {
  color: var(--white);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.35);
}
.brand-top .az-z {
  color: var(--cyan);
  text-shadow: 0 0 14px rgba(31, 178, 255, 0.35);
}
.menu-brand .brand-top {
  font-size: clamp(26px, 3.6vw, 48px);
  filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.45));
}
.logo-sky {
  color: var(--white);
  -webkit-text-stroke: 1px rgba(0, 0, 0, 0.25);
}
.logo-bound {
  color: var(--cyan);
  text-shadow: 0 0 18px rgba(31, 178, 255, 0.35);
}
.boot-tag,
.tag-marker {
  font-family: var(--marker);
  color: var(--amber);
  letter-spacing: 0.08em;
  transform: rotate(-3deg);
}
.boot-bar {
  width: min(360px, 70vw);
  height: 8px;
  border-radius: 99px;
  background: var(--graphite);
  overflow: hidden;
}
.boot-bar i {
  display: block;
  height: 100%;
  width: 4%;
  background: linear-gradient(90deg, var(--blue), var(--cyan));
  transition: width 0.25s ease;
}
#boot-msg {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0;
}
.nojs {
  position: fixed;
  inset: 0;
  display: grid;
  place-content: center;
}

/* ── Generic pieces ─────────────────────────────────────────────────────────────────────── */
#ui {
  position: fixed;
  inset: 0;
  z-index: 10;
  pointer-events: none;
}
#ui > * {
  pointer-events: auto;
}
.panel {
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: var(--graphite);
  color: var(--white);
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.95rem;
  cursor: pointer;
  transition:
    transform 0.12s ease,
    background 0.15s ease,
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}
.btn:hover {
  background: var(--steel);
  border-color: var(--line-strong);
}
.btn:active {
  transform: translateY(1px) scale(0.99);
}
.btn:focus-visible,
.chip:focus-visible,
.tile:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid var(--cyan-hi);
  outline-offset: 2px;
}
.btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
}
.btn-primary {
  background: linear-gradient(180deg, #38c2ff 0%, var(--cyan) 45%, #0b8fe0 100%);
  border-color: rgba(191, 238, 255, 0.55);
  color: #04121d;
  box-shadow:
    0 0 0 1px rgba(31, 178, 255, 0.25),
    0 8px 28px rgba(31, 178, 255, 0.28);
}
.btn-primary:hover {
  background: linear-gradient(180deg, #5ccfff 0%, #2fbaff 45%, #139ae8 100%);
}
.btn-amber {
  background: linear-gradient(180deg, var(--amber-hi), var(--amber));
  color: #1e1204;
  border-color: rgba(255, 220, 160, 0.6);
}
.btn-ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.14);
}
.btn-danger {
  background: #3a1b1f;
  border-color: #7a3440;
}
.btn-sm {
  min-height: 36px;
  padding: 6px 12px;
  font-size: 0.8rem;
  border-radius: 10px;
}
.row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.muted {
  color: var(--muted);
  font-weight: 600;
}
.small {
  font-size: 0.85rem;
}
.cyan {
  color: var(--cyan-hi);
}
.amber {
  color: var(--amber);
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 99px;
  background: var(--ink-2);
  border: 1px solid var(--line);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}
.chip.on {
  border-color: var(--cyan);
  color: var(--cyan-hi);
}
.chip.warn {
  border-color: rgba(255, 159, 28, 0.6);
  color: var(--amber-hi);
}
h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 900;
  margin: 0;
  letter-spacing: 0.01em;
}
h2 {
  font-size: 1.6rem;
}
h3 {
  font-size: 1.05rem;
  color: var(--silver);
}
input[type='text'],
input[type='number'],
input[type='password'],
select {
  background: var(--ink-2);
  border: 1px solid var(--steel);
  border-radius: 12px;
  padding: 10px 12px;
  min-height: 44px;
  color: var(--white);
}
input[type='range'] {
  accent-color: var(--cyan);
  width: 100%;
}
input[type='checkbox'] {
  accent-color: var(--cyan);
  width: 20px;
  height: 20px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* ── Main menu ──────────────────────────────────────────────────────────────────────────── */
.menu {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(250px, 330px) 1fr minmax(240px, 320px);
  grid-template-rows: auto 1fr auto;
  padding: clamp(16px, 3vw, 36px);
  gap: 16px;
  pointer-events: none;
}
.menu > * {
  pointer-events: auto;
}
.menu-brand {
  grid-column: 1 / 3;
}
.menu-brand .logo {
  font-size: clamp(42px, 6.2vw, 86px);
  filter: drop-shadow(0 4px 18px rgba(0, 0, 0, 0.45));
}
.menu-brand .tag-marker {
  display: inline-block;
  font-size: clamp(16px, 1.8vw, 24px);
  margin: 4px 0 0 6px;
}
.menu-invite {
  margin-top: 14px;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(15px, 1.35vw, 19px);
  color: var(--white);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.55);
  max-width: 34ch;
}
.menu-nav {
  grid-column: 1;
  grid-row: 2 / 4;
  align-self: end;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 300px;
}
.menu-nav .btn {
  justify-content: flex-start;
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.menu-nav .btn .ico {
  width: 22px;
  text-align: center;
  color: var(--cyan-hi);
}
.menu-side {
  grid-column: 3;
  grid-row: 1 / 3;
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
}
.profile-card {
  padding: 14px 16px;
}
.profile-card .name {
  font-family: var(--display);
  font-weight: 900;
  font-size: 1.15rem;
}
.milestone-card {
  padding: 14px 16px;
}
.feathers {
  display: flex;
  gap: 6px;
  margin: 8px 0;
}
.feather {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--ink-2);
  border: 1px solid var(--steel);
  color: var(--steel);
  font-size: 15px;
}
.feather.got {
  border-color: var(--cyan);
  color: var(--cyan-hi);
  background: rgba(31, 178, 255, 0.12);
}
.menu-play {
  grid-column: 2;
  grid-row: 3;
  justify-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.play-btn {
  min-width: 280px;
  min-height: 76px;
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 900;
  font-style: italic;
  letter-spacing: 0.08em;
  border-radius: 22px;
}
.join-inline {
  display: flex;
  gap: 8px;
}
.join-inline input {
  width: 150px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  text-align: center;
}
.trust {
  grid-column: 3;
  grid-row: 3;
  align-self: end;
  padding: 12px 14px;
  font-size: 0.78rem;
  color: var(--silver);
}
.trust ul {
  margin: 6px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 2px;
}

/* ── Sheets (full-screen overlays) ──────────────────────────────────────────────────────── */
.overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: clamp(10px, 2.5vw, 28px);
  background: rgba(5, 7, 11, 0.45);
}
.sheet {
  width: min(1100px, 100%);
  max-height: 100%;
  overflow: auto;
  padding: clamp(16px, 2.4vw, 28px);
}
.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}
.sheet-head .sub {
  color: var(--muted);
  font-weight: 700;
}
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}
.tile {
  position: relative;
  text-align: left;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--steel);
  background: var(--ink-2);
  cursor: pointer;
  min-height: 64px;
}
.tile:hover {
  border-color: var(--line-strong);
}
.tile.sel {
  border-color: var(--cyan);
  box-shadow: inset 0 0 0 1px var(--cyan);
}
.tile.locked {
  opacity: 0.55;
}
.tile .lock {
  position: absolute;
  top: 8px;
  right: 10px;
  font-size: 0.72rem;
  color: var(--amber-hi);
}
.swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.swatch {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  cursor: pointer;
}
.swatch.sel {
  border-color: var(--white);
  box-shadow: 0 0 0 2px var(--cyan);
}
.preview-box {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: radial-gradient(circle at 50% 35%, #1f3f5c, #0d1119 70%);
  border: 1px solid var(--line);
  min-height: 420px;
}
.preview-box canvas {
  width: 100%;
  height: 100%;
  display: block;
}
.tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.tabs .chip {
  cursor: pointer;
  font-size: 0.85rem;
  padding: 8px 14px;
}
.field {
  display: grid;
  gap: 6px;
}
.field label {
  font-size: 0.85rem;
  color: var(--silver);
}
.list {
  display: grid;
  gap: 8px;
}
.list-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--ink-2);
  border: 1px solid var(--graphite);
}
.list-row .grow {
  flex: 1;
  min-width: 0;
}
.stars {
  color: var(--amber);
  letter-spacing: 2px;
}
.kbd {
  display: inline-block;
  min-width: 26px;
  padding: 2px 7px;
  border-radius: 7px;
  background: var(--graphite);
  border: 1px solid var(--steel);
  border-bottom-width: 3px;
  font-size: 0.8rem;
  text-align: center;
  font-weight: 900;
}
.note {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(31, 178, 255, 0.07);
  border: 1px solid var(--line);
  color: var(--silver);
  font-weight: 600;
  font-size: 0.9rem;
}
.note.amber {
  background: rgba(255, 159, 28, 0.08);
  border-color: rgba(255, 159, 28, 0.35);
}

/* ── Lobby / room panel ─────────────────────────────────────────────────────────────────── */
.room-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 18px;
}
.code-box {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.code {
  font-family: var(--display);
  font-weight: 900;
  font-size: 2rem;
  letter-spacing: 0.22em;
  color: var(--cyan-hi);
}
.player-row .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--good);
}
.player-row .dot.off {
  background: var(--amber);
}
.player-row .portrait {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--graphite);
  object-fit: cover;
}

/* ── HUD ────────────────────────────────────────────────────────────────────────────────── */
#hud {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 8;
  font-family: var(--body);
}
#hud[hidden] {
  display: none;
}
.hud-top {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  align-items: center;
}
.pill {
  padding: 7px 14px;
  border-radius: 99px;
  background: var(--glass);
  border: 1px solid var(--line);
  font-weight: 900;
  letter-spacing: 0.04em;
  font-size: 0.9rem;
  white-space: nowrap;
}
.pill.timer {
  font-family: var(--display);
  font-size: 1.25rem;
  min-width: 92px;
  text-align: center;
}
.pill.cyan {
  border-color: var(--cyan);
  color: var(--cyan-hi);
}
.pill.amber {
  border-color: var(--amber);
  color: var(--amber-hi);
}
.it-banner {
  position: absolute;
  top: 62px;
  left: 50%;
  transform: translateX(-50%);
  padding: 8px 18px;
  border-radius: 14px;
  background: rgba(255, 159, 28, 0.16);
  border: 2px solid var(--amber);
  color: var(--amber-hi);
  font-family: var(--display);
  font-weight: 900;
  font-size: 1.1rem;
}
.hud-score {
  position: absolute;
  top: 14px;
  right: 14px;
  min-width: 200px;
  padding: 10px 12px;
  font-size: 0.85rem;
}
.hud-score .r {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 2px 0;
}
.hud-score .r.me {
  color: var(--cyan-hi);
}
.hud-score .r.it {
  color: var(--amber-hi);
}
.combo {
  position: absolute;
  left: 50%;
  bottom: 118px;
  transform: translateX(-50%);
  text-align: center;
  pointer-events: none;
}
.combo .chain {
  font-family: var(--display);
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
}
.combo .chain .arrow {
  color: var(--cyan);
  margin: 0 6px;
}
.combo .bank {
  margin-top: 4px;
  font-family: var(--marker);
  font-size: 1.5rem;
  color: var(--amber-hi);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.6);
  transition: opacity 0.4s ease;
}
.combo .bank .pts {
  font-family: var(--display);
  font-weight: 900;
  color: var(--white);
  margin-left: 8px;
}
.hints {
  position: absolute;
  left: 16px;
  bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
}
.hint {
  padding: 6px 10px;
  border-radius: 10px;
  background: var(--glass);
  border: 1px solid var(--line);
  font-size: 0.85rem;
  display: flex;
  gap: 8px;
  align-items: center;
}
.hud-br {
  position: absolute;
  right: 16px;
  bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-end;
}
.energy {
  width: 220px;
  padding: 8px 10px;
}
.energy .bar {
  height: 10px;
  border-radius: 99px;
  background: var(--graphite);
  overflow: hidden;
  margin-top: 5px;
}
.energy .bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--cyan-hi));
}
.energy.glide .bar i {
  background: linear-gradient(90deg, var(--amber), var(--amber-hi));
}
.center-msg {
  position: absolute;
  top: 34%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(34px, 6vw, 72px);
  text-shadow: 0 4px 22px rgba(0, 0, 0, 0.6);
}
.center-msg small {
  display: block;
  font-size: 0.32em;
  font-family: var(--body);
  color: var(--silver);
  margin-top: 6px;
}
.up-cue {
  position: absolute;
  top: 110px;
  right: 18px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--glass);
  border: 1px solid var(--line);
}
.up-cue span {
  display: block;
  font-size: 0.7rem;
  font-weight: 900;
  color: var(--cyan-hi);
}
.voice-hud {
  position: absolute;
  left: 16px;
  top: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.speaking {
  box-shadow: 0 0 0 2px var(--good);
}
.scoreboard {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}
.scoreboard .panel {
  min-width: min(560px, 92vw);
  padding: 18px;
}
.wheel {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 360px;
  height: 360px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--glass);
  border: 1px solid var(--line);
}
.wheel .slot {
  position: absolute;
  width: 104px;
  margin-left: -52px;
  margin-top: -20px;
  text-align: center;
  font-weight: 900;
  font-size: 0.85rem;
  padding: 8px 4px;
  border-radius: 12px;
}
.wheel .slot.sel {
  background: rgba(31, 178, 255, 0.2);
  color: var(--cyan-hi);
  outline: 1px solid var(--cyan);
}
.crosshair-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 4px;
  height: 4px;
  margin: -2px 0 0 -2px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
}
.nameplates {
  position: absolute;
  inset: 0;
}
.nameplate {
  position: absolute;
  transform: translate(-50%, -100%);
  padding: 3px 9px;
  border-radius: 99px;
  background: rgba(13, 15, 20, 0.62);
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
  display: flex;
  gap: 6px;
  align-items: center;
}
.nameplate.it {
  border: 2px solid var(--amber);
  color: var(--amber-hi);
}
.nameplate .pop {
  color: var(--amber-hi);
  font-family: var(--display);
}
.pause-note {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
}

/* ── Results ────────────────────────────────────────────────────────────────────────────── */
.results .winner {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(26px, 3.4vw, 40px);
}
.results .crown {
  color: var(--amber);
}
.standing {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  gap: 12px;
  align-items: center;
}
.standing .pos {
  font-family: var(--display);
  font-weight: 900;
  font-size: 1.2rem;
  color: var(--muted);
  text-align: center;
}
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 99px;
  font-size: 0.72rem;
  background: rgba(255, 159, 28, 0.12);
  color: var(--amber-hi);
  border: 1px solid rgba(255, 159, 28, 0.35);
  margin: 2px 4px 0 0;
}
.combo-line {
  font-size: 0.85rem;
  color: var(--silver);
}
.combo-line b {
  color: var(--cyan-hi);
}

/* ── Toasts ─────────────────────────────────────────────────────────────────────────────── */
#toasts {
  position: fixed;
  top: 64px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 40;
  pointer-events: none;
}
.toast {
  padding: 10px 16px;
  border-radius: 14px;
  background: var(--glass-2);
  border: 1px solid var(--line);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  font-weight: 800;
  max-width: min(560px, 92vw);
  text-align: center;
  animation: toast-in 0.25s ease;
}
.toast.feather {
  border-color: var(--cyan);
  font-size: 1.1rem;
}
.toast.warn {
  border-color: var(--amber);
}
@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
}

/* ── Editor ─────────────────────────────────────────────────────────────────────────────── */
.editor-bar {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  padding: 10px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 96vw;
  pointer-events: auto;
}
.editor-help {
  position: absolute;
  right: 16px;
  top: 70px;
  width: 260px;
  padding: 12px 14px;
  font-size: 0.8rem;
  pointer-events: auto;
}
.editor-errors {
  color: var(--amber-hi);
}

/* ── Accessibility modes ────────────────────────────────────────────────────────────────── */
body.high-contrast {
  --glass: rgba(0, 0, 0, 0.92);
  --glass-2: rgba(0, 0, 0, 0.95);
  --line: rgba(255, 255, 255, 0.55);
  --muted: #d7dde6;
}
body.reduced-motion *,
body.reduced-motion *::before,
body.reduced-motion *::after {
  animation: none !important;
  transition: none !important;
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

@media (max-width: 900px) {
  .menu {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto 1fr auto auto;
  }
  .menu-brand,
  .menu-nav,
  .menu-side,
  .menu-play,
  .trust {
    grid-column: 1;
    grid-row: auto;
  }
  .menu-nav {
    flex-direction: row;
    flex-wrap: wrap;
    max-width: none;
  }
  .grid-2,
  .room-grid {
    grid-template-columns: 1fr;
  }
  .grid-3 {
    grid-template-columns: 1fr 1fr;
  }
  .hud-score {
    display: none;
  }
}
