@font-face {
  font-family: Barlow;
  src: url(/fonts/barlow-latin-400-normal.woff2);
}
@font-face {
  font-family: Barlow;
  src: url(/fonts/barlow-latin-600-normal.woff2);
  font-weight: 600;
}
@font-face {
  font-family: Barlow;
  src: url(/fonts/barlow-latin-700-normal.woff2);
  font-weight: 700;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url(/fonts/barlow-condensed-latin-700-normal.woff2);
  font-weight: 700;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url(/fonts/barlow-condensed-latin-800-normal.woff2);
  font-weight: 800;
}
@font-face {
  font-family: 'Barlow Condensed';
  src: url(/fonts/barlow-condensed-latin-800-italic.woff2);
  font-weight: 800;
  font-style: italic;
}
@font-face {
  font-family: 'Space Mono';
  src: url(/fonts/space-mono-latin-400-normal.woff2);
}
:root {
  color-scheme: dark;
  --bg: #101318;
  --panel: #171b21;
  --inner: #12161b;
  --border: #31363e;
  --line: #282e35;
  --text: #f4f2eb;
  --muted: #a6acb5;
  --amber: #ffc349;
  --mint: #56deba;
  --display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --mono: 'Space Mono', monospace;
  font:
    16px Barlow,
    system-ui,
    sans-serif;
  background: var(--bg);
  color: var(--text);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(ellipse at 65% 0, #1b2026 0, transparent 58%), var(--bg);
  display: flex;
  flex-direction: column;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  touch-action: manipulation;
}
button {
  color: inherit;
  cursor: pointer;
}
button {
  background: none;
  border: none;
}
a {
  color: inherit;
  text-decoration: none;
}
button:disabled,
fieldset:disabled {
  opacity: 0.54;
  cursor: default;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}
h1,
h2,
h3,
p {
  margin: 0;
}
button svg,
.icon {
  flex-shrink: 0;
  vertical-align: middle;
}
h2 {
  font: 700 1.7rem/0.95 var(--display);
  letter-spacing: 0.004em;
}
small,
.tag,
.eyebrow,
.badge,
.live,
.color-id,
.preview-caption,
.rank,
.code,
.points,
.play-bar,
#metrics,
.site-foot {
  font-family: var(--mono);
}
.sr {
  position: absolute;
  clip-path: inset(50%);
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.top {
  background: #111419f5;
  border-bottom: 1px solid var(--border);
}
.top-inner,
main,
.site-foot {
  width: min(1240px, calc(100% - 96px));
  margin: 0 auto;
}
.top-inner {
  height: 72px;
  display: flex;
  align-items: center;
  gap: 54px;
}
.brand {
  font: italic 800 2rem/0.9 var(--display);
  letter-spacing: -0.035em;
  display: flex;
  align-items: center;
}
.brand img {
  width: 34px;
  height: 31px;
  margin-right: 9px;
}
.brand span {
  color: var(--amber);
}
nav,
.top-right {
  display: flex;
  align-items: center;
  gap: 27px;
}
nav {
  align-self: stretch;
}
nav a,
nav button,
.profile-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
}
nav a {
  border-bottom: 2px solid var(--amber);
  padding: 2px 4px 0;
  color: var(--amber);
}
nav button {
  color: #aab0b6;
  padding: 4px 0;
}
nav button:hover,
.profile-link:hover,
.site-foot button:hover {
  color: var(--amber);
}
.top-right {
  margin-left: auto;
  gap: 18px;
}
#status,
.live {
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  font: 0.75rem var(--mono);
}
#status:before,
.live b {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #e28373;
}
#status.online:before,
.live b {
  background: var(--mint);
  box-shadow: 0 0 8px #56deba44;
}
.profile-link {
  background: #20242a;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 8px 13px;
}
.profile-link span {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
main {
  flex: 1;
  padding: 32px 0 40px;
}
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 350px;
  display: grid;
  grid-template-columns: 43% 57%;
  align-items: stretch;
  border: 1px solid #373d44;
  border-radius: 7px;
  background:
    radial-gradient(ellipse at 76% 44%, #29383f 0, #1a232b 35%, transparent 66%),
    linear-gradient(120deg, #1c2027, #161b21 56%);
}
.hero:before,
.match-arena:before {
  content: '';
  position: absolute;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(#71838e50 0.8px, transparent 0.9px);
  background-size: 16px 16px;
  mask-image: linear-gradient(90deg, transparent, #000 55%);
}
.hero:after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 80px;
  height: 4px;
  background: repeating-linear-gradient(120deg, #e4ad46 0 7px, transparent 7px 12px);
}
.hero-copy {
  padding: 36px 0 36px 38px;
  position: relative;
  z-index: 2;
}
.eyebrow {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  font-weight: 400;
  color: #d0d3d6;
  display: flex;
  align-items: center;
  gap: 9px;
}
.slashes {
  font: 800 italic 1.05rem var(--display);
  letter-spacing: 0.13em;
  color: var(--amber);
}
.hero h1 {
  font: italic 800 clamp(4.4rem, 6.45vw, 6.6rem)/0.82 var(--display);
  letter-spacing: -0.017em;
  margin: 14px 0 15px;
}
.hero h1 em {
  color: var(--amber);
  font-style: inherit;
}
.hero-copy p {
  max-width: 355px;
  font-size: 1.04rem;
  line-height: 1.43;
  color: #bbc1c6;
}
.actions,
.inline,
.binding,
.form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero .actions {
  margin-top: 22px;
}
.btn,
.mini,
.text-btn,
.key-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  line-height: 1.2;
}
.btn {
  padding: 12px 18px;
  border-radius: 4px;
  min-height: 43px;
  border: 1px solid var(--border);
  background: #252b32;
}
.btn:hover,
.mini:hover,
.binding button:hover,
.key-btn:hover {
  background: #343c44;
}
.btn.primary {
  background: var(--amber);
  color: #191a16;
  border-color: #ffc349;
  box-shadow: inset 0 1px #ffe09a;
}
.btn.primary:hover {
  background: #ffd174;
}
.btn.ghost {
  background: #1c2229;
  border-color: #424851;
}
.btn.ghost:hover {
  background: #2c333b;
}
.compact {
  padding: 8px 13px;
  font-size: 0.9rem;
  min-height: 35px;
}
.mini {
  border: 1px solid var(--border);
  border-radius: 4px;
  min-width: 34px;
  min-height: 31px;
  padding: 5px 8px;
  color: #bfc5cb;
  font-size: 0.85rem;
}
.mini[aria-pressed='true'] {
  color: var(--amber);
}
.text-btn {
  color: var(--amber);
  padding: 4px 0;
}
.hero-visual {
  position: relative;
  margin: 0 4px 0 -64px;
  min-width: 0;
}
.hero-visual canvas {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  filter: drop-shadow(0 17px 12px #070b0e90);
}
.preview-caption {
  position: absolute;
  bottom: 14px;
  right: 17px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #afbabd;
  font-size: 0.62rem;
  letter-spacing: 0.13em;
}
.preview-caption span {
  width: 10px;
  height: 10px;
  border: 1px solid #77878c;
  position: relative;
}
.preview-caption span:after {
  content: '';
  position: absolute;
  inset: 2px;
  background: var(--amber);
}
.lobby-cols,
.room-cols {
  display: grid;
  grid-template-columns: minmax(0, 1.85fr) minmax(255px, 1fr);
  gap: 20px;
  margin-top: 24px;
  align-items: start;
}
.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
}
.panel-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 21px;
  border-bottom: 1px solid var(--line);
  min-height: 64px;
}
.section-icon {
  color: var(--amber);
  display: flex;
}
.tag,
.badge {
  border: 1px solid #414650;
  background: #22272d;
  color: #bcc3ca;
  border-radius: 3px;
  font-size: 0.7rem;
  padding: 2px 6px;
  line-height: 1.4;
}
.push {
  margin-left: auto;
}
.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 21px;
  border-bottom: 1px solid var(--line);
}
.filters {
  display: inline-flex;
  gap: 3px;
  border: 1px solid #30353d;
  background: #101419;
  padding: 3px;
  border-radius: 5px;
}
.filters button {
  font-size: 0.84rem;
  color: #a4aeb8;
  padding: 5px 11px;
  border-radius: 3px;
  font-weight: 600;
}
.filters [aria-pressed='true'] {
  background: #353b43;
  color: white;
  box-shadow: 0 1px 3px #0006;
}
.live {
  color: #adb8b9;
  font-size: 0.72rem;
}
.empty {
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  padding: 24px 16px;
  min-height: 112px;
  color: #b7c0c6;
}
.empty-icon {
  background: #22282e;
  border: 1px solid #363d45;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  color: #828c96;
}
.empty > div:not(.empty-icon) {
  text-align: left;
}
.empty h3,
.identity h3 {
  font: 700 1.38rem/1.2 var(--display);
  color: var(--text);
}
.empty p,
.help,
.room-identity small,
.score-row small {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.4;
}
.empty p {
  margin-top: 3px;
}
.pilot-body {
  padding: 18px 21px 16px;
}
.identity {
  display: flex;
  align-items: center;
  gap: 16px;
}
.helmet {
  color: var(--pilot);
  width: 66px;
  height: 66px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border: 1px solid #4b4c46;
  border-radius: 5px;
  background: repeating-linear-gradient(-50deg, transparent 0 5px, #818a8420 5px 6px), #272b2c;
}
.helmet svg {
  width: 54px;
  height: 54px;
}
.identity small,
.recap > small,
.countdown small {
  display: block;
  color: #a9b0b6;
  font-size: 0.65rem;
  letter-spacing: 0.11em;
}
.identity h3 {
  font-size: 1.55rem;
  margin: 2px 0 4px;
  overflow-wrap: anywhere;
}
.color-id {
  font-size: 0.7rem;
  color: #afb5bb;
  display: flex;
  align-items: center;
  gap: 6px;
}
.color-id b {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}
.pilot-controls {
  border-top: 1px solid var(--line);
  margin-top: 16px;
  padding-top: 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  color: #c2c7cd;
}
.pilot-controls > span {
  display: flex;
  gap: 8px;
  align-items: center;
}
.pilot-controls > div,
.key-btn {
  display: flex;
  gap: 5px;
}
kbd,
.key-btn kbd {
  font: 0.77rem var(--mono);
  display: inline-block;
  padding: 2px 7px;
  border: 1px solid #414750;
  border-bottom: 2px solid #4a535d;
  background: #242a31;
  border-radius: 3px;
  color: #d8dfe2;
}
.site-foot {
  border-top: 1px solid var(--line);
  padding: 19px 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.7rem;
  color: #919aa4;
}
.site-foot b {
  color: #565e66;
  margin: 0 5px;
}
.site-foot button {
  font: inherit;
  color: #abb3bb;
}
.room-row,
.rider,
.score-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 21px;
  border-bottom: 1px solid var(--line);
}
.room-row:last-child,
.score-row:last-child {
  border: 0;
}
.room-row .btn,
.rider-name + .badge {
  margin-left: auto;
}
.room-identity,
.rider-name,
.score-row > div {
  min-width: 0;
}
.room-identity strong,
.rider-name strong,
.score-row strong {
  overflow-wrap: anywhere;
}
.room-identity small,
.rider-name small,
.score-row small {
  display: block;
  font-family: Barlow, sans-serif;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.81rem;
}
.room-glyph {
  color: #caac73;
  width: 37px;
  height: 37px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 4px;
}
.crumb {
  color: var(--muted);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 16px;
}
.crumb a:hover {
  color: var(--amber);
}
.crumb b {
  color: #5b646d;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 12px 0 4px;
}
.page-heading h1 {
  font: italic 800 clamp(2.4rem, 5vw, 4.4rem)/1 var(--display);
  margin-top: 8px;
  overflow-wrap: anywhere;
}
.room-cols {
  margin-top: 22px;
}
.rider .color-bar,
.color-bar {
  width: 4px;
  min-height: 31px;
  border-radius: 3px;
  display: block;
  flex-shrink: 0;
}
.rider-name {
  margin-right: auto;
}
.key-btn {
  align-items: center;
  flex-wrap: wrap;
  background: none;
  padding: 4px;
  border-radius: 4px;
}
.on,
.badge.green {
  color: var(--mint);
}
.room-tools {
  padding: 16px 21px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
#add-bot[hidden] {
  display: none;
}
.driving-tools {
  border-top: 1px solid var(--line);
  padding: 10px 20px;
  font-size: 0.9rem;
  color: var(--muted);
}
.driving-tools summary {
  cursor: pointer;
}
.driving-tools p {
  margin: 9px 0;
}
.room-tools .inline {
  max-width: 100%;
}
.inline input {
  min-width: 0;
  flex: 1;
}
.inline button {
  flex-shrink: 0;
}
.chat #feed {
  height: 220px;
  overflow: auto;
  padding: 14px 16px;
  scrollbar-color: #535960 transparent;
  overflow-wrap: anywhere;
}
.chat form {
  padding: 10px 12px;
  border-top: 1px solid var(--border);
}
.message {
  font-size: 0.93rem;
  line-height: 1.45;
  margin-bottom: 8px;
}
.message time {
  font-size: 0.66rem;
  color: #9ba3ac;
}
.message .author {
  font-weight: 700;
  padding: 0;
}
.sys {
  font: 0.61rem var(--mono);
  color: var(--amber);
  margin-right: 3px;
}
input:not([type='checkbox']):not([type='range']):not([type='color']),
select {
  background: #101419;
  color: var(--text);
  border: 1px solid #414852;
  border-radius: 4px;
  padding: 10px 12px;
  font-size: 1rem;
  width: 100%;
}
input::placeholder {
  color: #959fa9;
}
input[type='range'],
input[type='checkbox'] {
  accent-color: var(--amber);
}
input[type='range'] {
  width: 100%;
}
dialog {
  max-width: min(540px, calc(100% - 28px));
  width: 100%;
  max-height: 88dvh;
  overflow: auto;
  color: var(--text);
  background: #191e25;
  border: 1px solid #414953;
  border-radius: 7px;
  padding: 0;
  box-shadow: 0 24px 85px #0008;
}
dialog::backdrop {
  background: #080c12c4;
  backdrop-filter: blur(4px);
}
.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
}
.dialog-content {
  padding: 21px 22px 24px;
}
.dialog-content label {
  display: block;
  font-weight: 600;
  margin-bottom: 9px;
}
.dialog-content label input:not([type='checkbox']),
.dialog-content label select {
  display: block;
  margin-top: 7px;
}
.dialog-content p {
  color: #bac1c8;
  line-height: 1.45;
  margin: 9px 0 17px;
}
.dialog-content form > .btn {
  margin-top: 6px;
}
.dialog-content a {
  color: var(--amber);
  text-decoration: underline;
}
.swatches,
.checks,
.field-row {
  display: flex;
  gap: 9px;
  align-items: center;
  margin-bottom: 17px;
}
.swatches button,
.swatches input {
  width: 32px;
  height: 32px;
  border-radius: 4px;
  border: 1px solid #ffffff33;
  background: var(--swatch);
  padding: 0;
  cursor: pointer;
}
.binding {
  margin-bottom: 7px;
}
.binding button {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  background: #242b32;
  border: 1px solid #414852;
  border-radius: 4px;
}
.checks {
  border-top: 1px solid var(--border);
  padding-top: 16px;
  margin: 18px 0 0;
  gap: 20px;
}
.checks label {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.92rem;
}
.form-actions {
  margin-top: 18px;
  justify-content: flex-end;
}
.field-row {
  align-items: start;
  gap: 15px;
  margin: 0;
}
.field-row > * {
  flex: 1;
}
.settings {
  border: 0;
  padding: 0;
  margin: 0;
}
.settings label {
  margin-bottom: 15px;
}
.code {
  background: #101419;
  padding: 4px 9px;
  color: var(--amber);
  letter-spacing: 0.12em;
}
.bonus-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.bonus-grid label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 400;
  margin: 0;
  background: #12171d;
  border-radius: 4px;
  padding: 5px;
}
.sprite {
  display: inline-block;
  width: 24px;
  height: 24px;
  background-image: url(/art/bonus.png);
  background-size: 72px 144px;
  background-position: calc(var(--col) * -24px) calc(var(--row) * -24px);
  flex-shrink: 0;
}
.bot-options {
  border: 0;
  margin: 0;
  padding: 0;
}
.bot-options legend {
  margin-bottom: 8px;
  color: var(--muted);
}
.dialog-content .bot-options label {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: var(--inner);
  cursor: pointer;
}
.bot-options label:has(:checked) {
  border-color: var(--amber);
}
.dialog-content .bot-options label input[type='radio'] {
  width: 16px;
  height: 16px;
  flex: none;
  padding: 0;
  margin: 0;
  accent-color: var(--amber);
}
.bot-options small {
  display: block;
  margin-top: 4px;
  font:
    0.91rem/1.35 Barlow,
    sans-serif;
  color: var(--muted);
}
dialog.field-guide {
  max-width: min(900px, calc(100% - 28px));
  max-height: min(92dvh, 760px);
  overscroll-behavior: contain;
  border-color: #454c52;
  background: #151a20;
}
.field-guide .dialog-head {
  position: sticky;
  top: 0;
  z-index: 1;
  gap: 12px;
  padding: 17px 22px;
  background: #1c2228;
}
.field-guide .dialog-head h2 {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-right: auto;
  font: italic 800 clamp(1.9rem, 4.2vw, 2.75rem)/1 var(--display);
  text-transform: uppercase;
}
.field-guide .dialog-head h2::before {
  content: '';
  width: 0.4em;
  height: 0.74em;
  flex-shrink: 0;
  transform: skewX(-15deg);
  background: linear-gradient(to right, var(--amber) 0 48%, transparent 48% 64%, var(--amber) 64%);
}
#guide-playback {
  font-size: 0.875rem;
  min-width: 102px;
  min-height: 36px;
}
.field-guide .dialog-content {
  padding: 20px;
}
.guide-lessons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.guide-lesson {
  overflow: hidden;
  border: 1px solid #353e46;
  border-radius: 5px;
  background: #1c2229;
}
.guide-stage {
  position: relative;
  aspect-ratio: 1.68;
  border-bottom: 1px solid #353e46;
  background:
    radial-gradient(circle, #78889040 0.8px, transparent 1px) 0 0 / 12px 12px,
    radial-gradient(ellipse at 50% 60%, #303d43, #192128 80%);
}
.guide-stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.guide-copy {
  padding: 16px;
}
.guide-lesson h3,
.guide-scoring h3 {
  font: 700 1.6rem/1 var(--display);
}
.field-guide .dialog-content p {
  margin: 8px 0 0;
  color: #c4cbd1;
  font-size: 1rem;
  line-height: 1.45;
}
.guide-keys,
.guide-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.875rem;
  color: #c7ced3;
}
.guide-keys span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.guide-keys kbd {
  color: var(--amber);
  overflow-wrap: anywhere;
}
.guide-legend {
  gap: 5px;
}
.guide-legend li {
  padding: 2px 7px;
  border: 1px solid #384249;
  border-radius: 3px;
  white-space: nowrap;
}
.guide-legend b {
  font-weight: 600;
}
.guide-legend li:nth-child(1) b {
  color: #76e69c;
}
.guide-legend li:nth-child(2) b {
  color: #ff9298;
}
.guide-legend li:nth-child(3) b {
  color: #fff;
}
.guide-scoring {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-top: 16px;
  padding: 16px 18px;
  border: 1px solid #454239;
  border-left: 3px solid var(--amber);
  border-radius: 4px;
  background: linear-gradient(105deg, #292921, #1e2328 62%);
}
.guide-scoring .icon {
  margin-top: 2px;
  color: var(--amber);
}
.guide-scoring h3 {
  font-size: 1.35rem;
}
.field-guide .guide-scoring p {
  margin-top: 4px;
}
@media (max-width: 700px) {
  .field-guide .dialog-head {
    padding: 14px 16px;
    gap: 8px;
  }
  .field-guide .dialog-head h2 {
    gap: 9px;
  }
  .field-guide .dialog-content {
    padding: 12px;
  }
  .guide-lessons {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .guide-lesson {
    display: grid;
    grid-template-columns: minmax(88px, 33%) minmax(0, 1fr);
  }
  .guide-stage {
    aspect-ratio: auto;
    border: 0;
    border-right: 1px solid #353e46;
  }
  .guide-copy {
    padding: 13px;
  }
  .guide-lesson h3 {
    font-size: 1.38rem;
  }
  .guide-keys,
  .guide-legend {
    margin-top: 8px;
  }
  .guide-scoring {
    margin-top: 10px;
    padding: 14px;
    gap: 10px;
  }
}
@media (max-width: 480px) {
  .guide-lesson {
    display: block;
  }
  .guide-stage {
    height: clamp(120px, 31vw, 148px);
    border: 0;
    border-bottom: 1px solid #353e46;
  }
  #guide-playback {
    min-width: 36px;
  }
  #guide-playback span {
    display: none;
  }
}
#toast {
  position: fixed;
  z-index: 20;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 10px);
  background: #f3d283;
  color: #211c12;
  font-weight: 600;
  padding: 10px 16px;
  border-radius: 4px;
  max-width: 90%;
  opacity: 0;
  visibility: hidden;
  transition: 0.16s;
  pointer-events: none;
}
#toast.show {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}
.play-page {
  width: min(1520px, calc(100% - 64px));
  padding-top: 19px;
}
.play-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 16px;
}
.play-panel {
  grid-column: 1 / -1;
}
.play-bar,
.play-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  gap: 8px;
  background: #191e24;
}
.play-bar {
  border-bottom: 1px solid var(--border);
  font-size: 0.7rem;
  color: var(--muted);
}
.play-bottom {
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}
.play-bottom > div {
  display: flex;
  gap: 6px;
}
.match-arena {
  position: relative;
  isolation: isolate;
  aspect-ratio: 1.58;
  max-height: max(280px, calc(100dvh - 190px));
  background: radial-gradient(ellipse at 50% 50%, #26333a, #151c23 65%);
  touch-action: none;
}
.match-arena:before {
  mask-image: none;
}
.match-arena canvas {
  position: absolute;
  width: 100%;
  height: 100%;
  inset: 0;
}
.play-layout .panel-heading {
  padding: 14px 16px;
  min-height: 51px;
}
.play-layout .chat #feed {
  height: 150px;
}
.score-row {
  padding: 10px 16px;
  gap: 9px;
}
.score-row .points {
  margin-left: auto;
  font-size: 1.1rem;
}
.score-row .points small {
  display: inline;
  color: var(--amber);
}
.score-row.eliminated > div {
  opacity: 0.7;
}
.rank,
#metrics,
#round-tag {
  font-size: 0.7rem;
  color: #b1bac1;
}
.active-effect {
  font-size: 0.71rem;
  color: var(--amber);
  margin-right: 5px;
}
.recap,
.countdown {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
}
.recap {
  background: #151b22ef;
  border: 1px solid #555e66;
  padding: 20px;
  min-width: min(230px, 85%);
  border-radius: 6px;
}
.recap small,
.countdown small {
  color: var(--amber);
  white-space: nowrap;
}
.recap h2 {
  margin: 7px 0 10px;
  font-size: 2.1rem;
}
.recap p {
  font-size: 0.86rem;
  color: var(--muted);
}
.countdown {
  pointer-events: none;
  text-shadow: 0 2px 10px #0a0d13;
}
.countdown strong {
  font: italic 800 4.8rem/1 var(--display);
}
.danger {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #f0b34a;
  color: #221a12;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 3px;
}
#kills {
  position: absolute;
  bottom: 9px;
  left: 13px;
  color: #c4cbd2;
  font-size: 0.77rem;
  text-shadow: 0 1px 3px #000;
  pointer-events: none;
}
#touch-pads {
  display: flex;
  gap: 1px;
}
#touch-pads button {
  flex: 1;
  padding: 12px;
  background: #2b3239;
  color: var(--amber);
  touch-action: none;
  user-select: none;
}
@media (min-width: 1500px) {
  .hero {
    min-height: 390px;
  }
  .hero-copy {
    padding: 44px 0 44px 44px;
  }
}
@media (max-width: 1000px) {
  .top-inner,
  main,
  .site-foot {
    width: calc(100% - 48px);
  }
  .top-inner {
    gap: 28px;
  }
  .top-right {
    gap: 12px;
  }
  .hero-copy {
    padding: 30px 0 30px 26px;
  }
  .hero h1 {
    font-size: 4.8rem;
  }
  .hero {
    min-height: 320px;
  }
  .lobby-cols,
  .room-cols {
    grid-template-columns: minmax(0, 1.6fr) minmax(220px, 1fr);
    gap: 14px;
  }
}
@media (max-width: 740px) {
  .top-inner,
  main,
  .site-foot {
    width: calc(100% - 30px);
  }
  .top-inner {
    height: 58px;
    gap: 18px;
  }
  .brand {
    font-size: 1.65rem;
  }
  .brand img {
    width: 27px;
    height: 25px;
    margin-right: 6px;
  }
  nav {
    gap: 12px;
  }
  nav a,
  nav button {
    font-size: 0.84rem;
  }
  .top-right #status {
    font-size: 0;
    gap: 0;
  }
  .top-right {
    gap: 10px;
  }
  .profile-link {
    padding: 7px;
  }
  .profile-link span {
    display: none;
  }
  main {
    padding: 18px 0 28px;
  }
  .hero {
    grid-template-columns: 1fr 1fr;
    min-height: 276px;
  }
  .hero-copy {
    padding: 23px 0 23px 20px;
  }
  .hero h1 {
    font-size: 3.8rem;
  }
  .hero-copy p {
    font-size: 0.93rem;
  }
  .hero .actions {
    gap: 6px;
    margin-top: 15px;
  }
  .hero .btn {
    padding: 8px 11px;
    min-height: 35px;
    font-size: 0.87rem;
  }
  .hero .btn svg {
    width: 15px;
  }
  .eyebrow {
    font-size: 0.62rem;
    letter-spacing: 0.07em;
  }
  .hero-visual {
    margin-left: -23px;
  }
  .lobby-cols,
  .room-cols {
    grid-template-columns: 1fr;
  }
  .lobby-cols {
    margin-top: 16px;
  }
  .pilot .pilot-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
  }
  .pilot-controls {
    border: none;
    margin: 0;
    padding: 0;
    gap: 12px;
  }
  .panel-heading {
    min-height: 51px;
    padding: 14px 16px;
  }
  .play-layout {
    gap: 10px;
  }
  .play-layout .chat #feed {
    height: 125px;
  }
  .page-heading {
    flex-wrap: wrap;
  }
  .site-foot {
    padding: 14px 0;
  }
  .play-page {
    width: calc(100% - 20px);
  }
}
@media (max-width: 540px) {
  .top-inner {
    gap: 15px;
  }
  .top nav {
    gap: 10px;
  }
  .top nav svg {
    display: none;
  }
  .top-right {
    gap: 8px;
  }
  .hero {
    display: flex;
    flex-direction: column;
  }
  .hero-copy {
    padding: 24px 22px 0;
  }
  .hero h1 {
    font-size: 4.6rem;
  }
  .hero-copy p {
    max-width: 290px;
  }
  .hero .actions {
    margin-top: 16px;
  }
  .hero-visual {
    height: 200px;
    margin: -3px 0 4px;
  }
  .preview-caption {
    font-size: 0.54rem;
    bottom: 4px;
    right: 10px;
  }
  .lobby-cols {
    gap: 13px;
  }
  .pilot .pilot-body {
    padding: 15px;
  }
  .pilot-controls {
    display: block;
    text-align: right;
  }
  .pilot-controls > div {
    justify-content: flex-end;
    margin-top: 5px;
  }
  .page-heading h1 {
    font-size: 2.8rem;
  }
  .rider {
    padding: 12px 11px;
    gap: 7px;
    flex-wrap: wrap;
  }
  .rider .key-btn svg {
    display: none;
  }
  .room-tools {
    padding: 12px;
  }
  .room-tools .inline {
    flex: 1;
  }
  .room-row {
    padding: 12px 14px;
  }
  .room-row .btn {
    font-size: 0.82rem;
  }
  .filter-bar {
    padding: 10px 14px;
  }
  .empty {
    min-height: 100px;
  }
  .play-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .play-layout .chat #feed {
    height: 120px;
  }
  .site-foot {
    font-size: 0.62rem;
  }
  .bonus-grid {
    gap: 4px;
  }
  .bonus-grid label {
    font-size: 0.78rem;
  }
  .swatches {
    gap: 7px;
  }
  .dialog-content {
    padding: 17px;
  }
  .play-bar,
  .play-bottom {
    padding: 8px;
  }
  .play-bottom {
    gap: 5px;
  }
  .play-bottom .mini {
    min-width: 27px;
  }
  .top .brand {
    font-size: 1.48rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
