:root {
  color-scheme: dark;
  --paper: #eaf0ef;
  --ink: #0b131d;
  --line: #354657;
  --gold: #eeb879;
  --muted: #a7b8c6;
  --phone-turn: 0deg;
  font-family: 'Barlow', 'Segoe UI', sans-serif;
  background: var(--ink);
  color: var(--paper);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
select {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
  opacity: 0.48;
}
button:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid #ffd093;
  outline-offset: 3px;
}
[hidden] {
  display: none !important;
}
button {
  border: 1px solid var(--line);
  background: #233242;
  border-radius: 6px;
  padding: 0.62em 0.85em;
  font-weight: 650;
}
button:hover:enabled {
  filter: brightness(1.13);
}
.quiet {
  background: transparent;
}
.primary {
  background: var(--gold);
  color: #18212a;
  border: 1px solid #ffd295;
  font-weight: 800;
  font-size: 1.09rem;
}
.primary b {
  float: right;
}
.link,
.utility button {
  border: 0;
  background: none;
  color: #b6c7d5;
  font-size: 0.86rem;
}
.link {
  text-decoration: underline;
  text-underline-offset: 4px;
}
h1,
h2,
p {
  margin: 0;
}
#lobby {
  height: 100dvh;
  min-height: 360px;
  max-width: 1740px;
  margin: auto;
  padding: 0 clamp(16px, 3vw, 58px) clamp(16px, 2.5vh, 34px);
  display: flex;
  flex-direction: column;
}
.mast,
.phone-shell header {
  display: flex;
  align-items: center;
  gap: 18px;
}
.mast {
  height: clamp(48px, 7.6vh, 82px);
  flex-shrink: 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
  font-size: 1.12rem;
  letter-spacing: -0.035em;
}
.brand img {
  width: 30px;
  height: 30px;
}
.mast-rule {
  flex: 1;
  border-top: 1px solid var(--line);
}
.top-label,
.eyeline,
label,
.roster-head span,
.match-clock span,
.overlay span,
.stick-side label {
  font:
    700 0.68rem/1.2 'Barlow Condensed',
    'Segoe UI',
    sans-serif;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.mast .quiet {
  padding: 0.4em 0.72em;
  font-size: 0.82rem;
}
.lobby-grid {
  min-height: 0;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(275px, 30%);
  gap: clamp(12px, 1.6vw, 28px);
}
.program {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(7px, 1.2vh, 15px);
  overflow: auto;
  scrollbar-width: thin;
}
.poster {
  position: relative;
  isolation: isolate;
  min-height: 182px;
  flex: 1 1 auto;
  border-radius: 9px;
  overflow: hidden;
  border: 1px solid #526173;
  background: #11202c url('/monstermash/assets/knellback-night.webp') center 40% / cover;
}
.poster:before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, #07121be8 1%, #101e2c8a 33%, transparent 69%),
    linear-gradient(0deg, #0a142077, transparent 35%);
}
.poster-copy {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(15px, 3.2vw, 52px);
  gap: clamp(8px, 1.4vh, 19px);
}
.eyeline {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
}
.eyeline i {
  width: 15px;
  height: 3px;
  background: currentColor;
}
.poster h1 {
  font-family: 'Archivo Black', 'Arial Black', Impact, sans-serif;
  font-weight: 1000;
  font-size: clamp(48px, min(7.5vw, 12vh), 135px);
  line-height: 0.84;
  letter-spacing: -0.065em;
  color: #edf3f3;
  text-shadow: 0 2px 0 #08111baa;
}
.poster h1 em {
  color: var(--gold);
  font-style: normal;
}
.poster p,
.join p {
  line-height: 1.4;
}
.poster p {
  font-size: clamp(0.82rem, 1.32vw, 1.25rem);
  font-weight: 560;
}
.district-panel,
.join,
.seat {
  border: 1px solid var(--line);
  border-radius: 8px;
}
.district-panel {
  padding: 9px;
  display: flex;
  align-items: center;
  gap: 14px;
  background: #142130;
}
.district-panel canvas {
  width: clamp(80px, 9vw, 155px);
  height: clamp(49px, 8.5vh, 90px);
  object-fit: fill;
  border-radius: 3px;
}
.map-copy {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 4px;
}
.map-copy label,
.roster-head span {
  color: var(--muted);
}
.map-copy select {
  border: 0;
  background: #142130;
  font-weight: 750;
  font-size: clamp(1rem, 1.4vw, 1.4rem);
  width: max-content;
  max-width: 100%;
}
.map-copy span {
  color: #acbdc9;
  font-size: 0.83rem;
}
.district-panel .quiet {
  font-size: 0.82rem;
}
.roster-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.roster-head h2 {
  font-size: 1.1rem;
}
.roster {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}
.seat {
  min-width: 0;
  position: relative;
  padding: 10px 7px;
  display: flex;
  align-items: center;
  gap: 6px;
  background: #14202c;
}
.seat img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}
.seat > b,
.seat-badge {
  color: var(--gold);
  font-size: 0.8rem;
}
.seat strong,
.seat small {
  display: block;
}
.seat strong {
  font-size: 0.87rem;
}
.seat small {
  color: var(--muted);
  font-size: 0.7rem;
}
.seat button {
  position: absolute;
  right: 1px;
  top: 0;
  padding: 0 0.28em;
  background: none;
  border: 0;
}
.join {
  background: #162535;
  color: #ecf2f1;
  display: flex;
  align-items: stretch;
  flex-direction: column;
  justify-content: space-between;
  gap: 6px;
  padding: clamp(15px, 2vw, 34px);
  overflow: hidden;
}
.join .eyeline {
  color: #e1b784;
}
.join h2 {
  font-size: clamp(1.8rem, 3vw, 3.7rem);
  letter-spacing: -0.055em;
  line-height: 1.05;
  margin: 0.22em 0 0.14em;
}
.join p {
  font-size: clamp(0.85rem, 1.13vw, 1.2rem);
  color: #bbcad4;
}
.qr-wrap {
  display: grid;
  place-items: center;
  min-height: 0;
  flex: 1;
}
.qr-wrap img {
  display: block;
  aspect-ratio: 1;
  width: min(100%, 39vh, 410px);
  max-height: 100%;
  object-fit: contain;
  background: white;
  border-radius: 4px;
}
.join .link,
.join .utility button {
  color: #c0cfda;
}
.launch {
  display: grid;
  gap: 10px;
}
.launch > span {
  font-size: 0.85rem;
  font-weight: 700;
}
.launch .primary {
  background: #e7b17b;
  color: #16202b;
  border: 0;
  text-align: left;
  padding: 0.82em 1em;
}
.utility {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid #405161;
}
.utility button {
  padding: 0.38em 0;
}
#arena {
  position: fixed;
  inset: 0;
  isolation: isolate;
  background: #142531;
  overflow: hidden;
}
#field {
  display: block;
  width: 100%;
  height: 100%;
}
#entrance {
  --accent: #e2b778;
  --progress: 0;
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  color: #fff3dc;
  background: linear-gradient(90deg, #060e1ab8, transparent 56%), linear-gradient(0deg, #050d16c9, transparent 38%);
}
#entrance::before, #entrance::after {
  content: '';
  position: absolute;
  inset: 0 0 auto;
  height: 5.1%;
  background: #070d13;
}
#entrance::after { inset: auto 0 0; }
.entrance-caption {
  position: absolute;
  left: 5.4%;
  bottom: 12%;
  max-width: 72%;
  padding-left: clamp(12px, 1.45vw, 29px);
  border-left: 3px solid var(--accent);
  text-shadow: 0 2px 18px #060c16;
}
.entrance-caption h2 {
  margin: .035em 0;
  font: 900 clamp(32px,6.55vw,114px)/1 'Archivo Black', 'Arial Black', 'Segoe UI', sans-serif;
  text-transform: uppercase;
  letter-spacing: -.055em;
  text-wrap: balance;
}
.entrance-seat {
  font-weight: 750;
  font-size: clamp(12px,1.3vw,25px);
  text-transform: uppercase;
  letter-spacing: .13em;
  color: var(--accent);
}
.entrance-caption p { margin: .35em 0 0; font-size: clamp(15px,1.65vw,31px); }
.entrance-caption p:empty, .entrance-seat:empty { display: none; }
#skip-entrance {
  position: absolute;
  right: 3%; top: 7%;
  pointer-events: auto;
  background: #0b1521d9;
  border: 1px solid #84939c8f;
  color: #f5eee3;
}
#arena:is([data-opening="district"],[data-opening="fighter"]) :is(#hud,#tags,.match-clock) { visibility: hidden; }
#arena:is([data-opening="district"],[data-opening="fighter"]) .battle-tools { left: auto; right: 3%; bottom: 7%; transform: none; }
#arena:is([data-opening="ready"],[data-opening="go"]) #entrance { background: transparent; }
#arena:is([data-opening="ready"],[data-opening="go"]) #entrance::before,
#arena:is([data-opening="ready"],[data-opening="go"]) #entrance::after { display: none; }
#arena:is([data-opening="ready"],[data-opening="go"]) .entrance-caption {
  top: 14%; bottom: auto; left: 50%; transform: translateX(-50%);
  text-align: center; border: 0; padding: 0;
}
#arena:is([data-opening="ready"],[data-opening="go"]) .entrance-caption h2 {
  font-size: clamp(32px,5.1vw,90px); color: #ffe2a8; text-shadow: 0 2px 6px #111c25,0 4px 25px #111c25;
}
@media (prefers-reduced-motion: no-preference) {
  #arena:is([data-opening="district"],[data-opening="fighter"]) .entrance-caption {
    transform: translateX(calc(min(0px, (var(--progress) - .18) * 90px)));
    opacity: clamp(0, calc(.22 + var(--progress) * 6), 1);
  }
}
.fight-card {
  border-radius: 5px;
  position: absolute;
  width: clamp(140px, 18vw, 320px);
  background: #0c1726ed;
  color: #eef3f5;
  border: 1px solid #fff3;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border-left: 4px solid var(--seat-color);
}
.fight-card img {
  width: clamp(35px, 4.5vw, 64px);
  height: clamp(35px, 4.5vw, 64px);
  object-fit: contain;
}
.fight-card > div {
  flex: 1;
  min-width: 0;
}
.fight-card strong,
.fight-card small {
  font-size: clamp(0.69rem, 1.05vw, 1.09rem);
}
.fight-card small {
  float: right;
}
.fight-card.stunned .hp {
  outline: 1px solid #f5ca9a;
  box-shadow: 0 0 8px #eba26280;
}
.fight-card.out {
  opacity: 0.55;
}
.p1 {
  left: 2%;
  top: 2%;
}
.p2 {
  right: 2%;
  top: 2%;
}
.p3 {
  left: 2%;
  bottom: 2%;
}
.p4 {
  right: 2%;
  bottom: 2%;
}
.hp,
.cells i {
  display: block;
  overflow: hidden;
  background: #334352;
}
.hp {
  height: 7px;
  margin: 4px 0;
}
.hp b,
.cells b {
  background: var(--seat-color, var(--gold));
  height: 100%;
  display: block;
}
.cells {
  display: flex;
  gap: 3px;
}
.cells i {
  flex: 1;
  height: 5px;
}
.cells b {
  background: var(--gold);
}
.match-clock,
#announcement,
.battle-tools,
#tags b {
  position: absolute;
}
.match-clock {
  top: 2%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  background: #101d2be8;
  padding: 6px 15px;
  border-radius: 6px;
}
.match-clock b,
.match-clock span {
  display: block;
}
.match-clock b {
  font-size: 1.45rem;
}
.match-clock span {
  font-size: 0.6rem;
}
.battle-tools {
  bottom: 2%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  z-index: 3;
}
#menu {
  display: grid;
  gap: 4px;
  padding: 6px;
  background: #10202c;
  border-radius: 6px;
}
#menu-toggle {
  margin-top: 4px;
}
#announcement {
  bottom: 12%;
  left: 50%;
  transform: translateX(-50%);
  background: #0d1827e8;
  padding: 5px 13px;
  border-radius: 6px;
  font-weight: 750;
  pointer-events: none;
}
#announcement:empty {
  display: none;
}
#tags b {
  transform: translate(-50%, -100%);
  background: #0c1726e8;
  border-bottom: 2px solid var(--seat-color);
  padding: 2px 5px;
  border-radius: 3px;
  font-size: clamp(0.68rem, 1.1vw, 1rem);
}
#tags .heavy-tell {
  display: inline-block; position: relative; margin-left: .4em; padding: .05em .35em .18em;
  color: #ffcf93; border-left: 2px solid currentColor; white-space: nowrap; text-transform: uppercase;
}
#tags .heavy-tell i {
  position: absolute; inset: auto 0 0; height: 3px; background: currentColor;
  transform: scaleX(var(--loaded)); transform-origin: left;
}
#tags .heavy-tell.release { color: #fff3d4; background: #8f481b; outline: 1px solid #ffd49a; }
#tags .heavy-tell[hidden] { display: none; }
.overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: #08142177;
  text-align: center;
  pointer-events: none;
}
.overlay div {
  background: #142332ee;
  border: 1px solid #647c91;
  border-radius: 8px;
  padding: 1rem 2rem;
}
.overlay button {
  pointer-events: auto;
  margin: 0.5em 0.3em 0;
}
.overlay h2 {
  font-size: clamp(2rem, 6vw, 5rem);
  line-height: 1.05;
}
.overlay span {
  color: var(--gold);
}
.loading {
  min-height: 90dvh;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 16px;
  text-align: center;
  padding: 25px;
}
#toast {
  position: fixed;
  left: 50%;
  bottom: 2%;
  transform: translateX(-50%);
  z-index: 9;
  background: #132537;
  color: #f0f2ef;
  padding: 0.7em 1em;
  border-radius: 6px;
  pointer-events: none;
}
#toast:empty {
  display: none;
}
.phone-page,
.phone-page body {
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: none;
}
.phone-shell {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 100dvw;
  height: 100dvh;
  transform: translate(-50%, -50%) rotate(var(--phone-turn));
  display: flex;
  flex-direction: column;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  padding: max(3px, var(--safe-top)) max(6px, var(--safe-right)) max(5px, var(--safe-bottom)) max(6px, var(--safe-left));
  container-type: size;
  background: radial-gradient(ellipse at 45% 100%, #233b50, #09121f 70%);
  touch-action: none;
  user-select: none;
}
/* Insets are supplied in screen coordinates, even when the controller itself rotates. */
.phone-shell[data-rotation="90"] {
  --safe-top: env(safe-area-inset-right, 0px);
  --safe-right: env(safe-area-inset-bottom, 0px);
  --safe-bottom: env(safe-area-inset-left, 0px);
  --safe-left: env(safe-area-inset-top, 0px);
}
.phone-shell[data-rotation="-90"] {
  --safe-top: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-right, 0px);
  --safe-left: env(safe-area-inset-bottom, 0px);
}
.phone-shell[data-rotation="-180"], .phone-shell[data-rotation="180"] {
  --safe-top: env(safe-area-inset-bottom, 0px);
  --safe-right: env(safe-area-inset-left, 0px);
  --safe-bottom: env(safe-area-inset-top, 0px);
  --safe-left: env(safe-area-inset-right, 0px);
}
.phone-shell header {
  flex: 0 0 auto;
  min-height: 44px;
  gap: clamp(5px, 1cqw, 12px);
  border-bottom: 1px solid var(--line);
  padding: 0 4px 2px;
}
.phone-shell .brand {
  font-size: 0.95rem;
}
.phone-shell .brand img {
  width: 24px;
  height: 24px;
}
.phone-shell #link-status {
  margin-left: auto;
  font-size: 0.8rem;
  color: var(--muted);
}
.phone-shell #flip {
  min-width: 56px;
  min-height: 44px;
  padding: 0.3em 0.6em;
  font-size: 0.83rem;
}
.phone-shell #phone-full {
  flex: 0 0 44px;
  min-height: 44px;
  padding: 0;
  font-size: 1.25rem;
}
#select-panel {
  min-height: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.selection-head,
.phone-ready {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.selection-head {
  padding-top: 6px;
}
.selection-head h1 {
  font-size: clamp(1.15rem, 4.9vh, 2.15rem);
  letter-spacing: -0.04em;
}
.selection-head span,
.phone-ready span {
  font-size: 0.82rem;
  color: #b9c9d6;
}
#choices {
  display: flex;
  flex: 1;
  min-height: 0;
  gap: 8px;
}
.choice {
  width: 25%;
  flex: 1;
  min-width: 0;
  position: relative;
  padding: 0 0 5px;
  overflow: hidden;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.choice.chosen {
  border: 2px solid var(--gold);
}
.choice img {
  width: 100%;
  height: 0;
  flex: 1;
  min-height: 22px;
  object-fit: cover;
  filter: saturate(0.83) brightness(0.88);
}
.choice strong,
.choice small {
  padding: 0 6px;
}
.choice small {
  color: var(--muted);
  font-size: 0.65rem;
}
.phone-ready .primary {
  min-width: 115px;
}
.phone-shell #phone-retry {
  align-self: center;
  font-size: 0.72rem;
  padding: 2px;
}
.phone-shell[data-phase]:not([data-phase="lobby"]) header .brand { display: none; }
#fighter-status {
  display: flex;
  align-items: center;
  gap: clamp(4px, 0.9cqw, 10px);
  white-space: nowrap;
}
#self-icon { width: 36px; height: 36px; object-fit: contain; }
#self-name { font-size: clamp(12px, 2.1cqw, 17px); }
#self-hp, #phone-note { font-size: clamp(11px, 1.7cqw, 14px); }
#self-hp { color: #d0dce5; font-variant-numeric: tabular-nums; }
#phone-cells { width: clamp(35px, 6cqw, 65px); }
#phone-note { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #ffd5a1; }
.phone-shell #controller {
  flex: 1 1 0;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 43fr) minmax(0, 57fr);
  padding-top: 3px;
}
#stick {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  container-type: size;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
}
#stick::before {
  content: ''; position: absolute; inset: 3px; z-index: -1;
  border: 1px solid #405769; border-radius: 14px;
  background: radial-gradient(ellipse at 50% 46%, #23394a, #142332 64%, #101c28);
}
.stick-dial {
  position: relative;
  width: min(84cqw, 79cqh, 420px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 2px solid #64798b;
  box-shadow: 0 0 0 5px #142330, 0 0 0 6px #334858, inset 0 3px 14px #080f18;
  background: radial-gradient(circle, #253a49 0 40%, #465c69 40.4% 41%, #1b303f 41.5% 62%, #324959 62.4% 63%, #132431 63.5%);
  pointer-events: none;
}
.bearing { position: absolute; width: 9px; height: 6px; background: #8ca0ac; clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.bearing.north { top: 3.5%; }
.bearing.south { bottom: 3.5%; transform: rotate(180deg); }
.bearing.west { left: 3%; transform: rotate(-90deg); }
.bearing.east { right: 3%; transform: rotate(90deg); }
#knob {
  width: 39%;
  aspect-ratio: 1;
  border-radius: 50%;
  border: 2px solid #edd1a0;
  background: radial-gradient(circle at 42% 29%, #f1c88d, #d2995e 72%, #aa7449);
  box-shadow: inset 0 0 0 4px #cc965c, inset 0 -5px 8px #905f3b, 0 4px 8px #08121ac7;
  pointer-events: none;
}
.move-label {
  position: absolute; bottom: 2.4%; color: #bdcfd8;
  font-size: clamp(10px, 4cqh, 15px); font-weight: 720; letter-spacing: .14em;
  text-transform: uppercase; pointer-events: none;
}
.action-side {
  min-height: 0; display: grid;
  grid-template: repeat(2, minmax(0, 1fr)) / repeat(2, minmax(0, 1fr));
}
.action-side button {
  --key: #2c4054;
  --rim: #6e8498;
  --accent: #d5e6f2;
  position: relative; isolation: isolate;
  min-width: 0; min-height: 0; margin: 0;
  border: 0; border-radius: 0; background: transparent; color: #f0f4f7;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: clamp(2px, .85cqh, 7px); padding: 6px;
  touch-action: none; -webkit-tap-highlight-color: transparent;
}
.action-side button::before {
  content: ''; position: absolute; z-index: -1; inset: 3px;
  background: linear-gradient(155deg, #ffffff0a, #00000022), var(--key);
  border: 1px solid var(--rim); border-radius: 12px;
  box-shadow: inset 0 2px 0 #ffffff18, inset 0 -4px 0 #00000035;
}
.action-side button:focus-visible { outline-offset: -5px; border-radius: 12px; }
.action-side .heavy { --key: #694631; --rim: #b78b63; --accent: #ffd299; }
.action-side [data-action="pickup"] { --key: #24494d; --rim: #548488; --accent: #a9e0d4; }
.action-side [data-action="block"] { --key: #353d5a; --rim: #757e9a; --accent: #c5cdea; }
.action-side strong { font-size: clamp(17px, 6.4cqh, 29px); line-height: 1.08; letter-spacing: -.025em; }
.action-side small { color: var(--accent); font-size: clamp(10px, 3.2cqh, 14px); line-height: 1.1; }
.key-symbol {
  display: block; width: clamp(20px, 8.7cqh, 39px); aspect-ratio: 1; background: var(--accent);
  clip-path: polygon(81% 4%, 46% 55%, 15% 68%, 47% 21%);
}
.heavy .key-symbol { clip-path: polygon(60% 6%, 37% 53%, 7% 76%, 34% 16%, 60% 6%, 94% 21%, 67% 75%, 36% 95%, 64% 35%, 94% 21%); }
[data-action="pickup"] .key-symbol { clip-path: polygon(50% 2%, 79% 33%, 60% 33%, 60% 66%, 40% 66%, 40% 33%, 21% 33%, 50% 2%, 13% 67%, 24% 67%, 24% 82%, 76% 82%, 76% 67%, 87% 67%, 87% 95%, 13% 95%, 13% 67%); }
[data-action="block"] .key-symbol { clip-path: polygon(50% 4%, 87% 17%, 83% 55%, 72% 75%, 50% 94%, 28% 75%, 17% 55%, 13% 17%); }
.action-side .pressed::before { inset: 4px 3px 2px; border: 3px solid var(--accent); filter: brightness(1.32); box-shadow: inset 0 2px 5px #0005; }
.action-side .charged::before { border-color: #f5c67f; box-shadow: inset 0 0 0 1px #e4ab63, inset 0 -4px 0 #0003; }
.phone-ready .primary { min-height: 44px; }
@media (orientation: portrait) {
  .phone-shell { width: 100dvh; height: 100dvw; }
  .phone-shell .selection-head h1 { font-size: 1.15rem; }
}
@media (max-height: 570px) and (min-width: 651px) {
  #lobby {
    padding-bottom: 8px;
  }
  .mast {
    height: 40px;
  }
  .poster {
    min-height: 140px;
  }
  .poster p {
    display: none;
  }
  .district-panel {
    padding: 5px;
  }
  .join {
    padding: 10px 16px;
  }
  .join .qr-wrap img {
    width: min(100%, 48vh);
  }
  .launch {
    gap: 4px;
  }
  .join h2 {
    font-size: 1.6rem;
  }
  .seat {
    padding: 5px;
  }
  .roster-head h2 {
    font-size: 0.9rem;
  }
}
@media (max-width: 760px) {
  .roster {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .map-copy span {
    display: none;
  }
  .lobby-grid {
    grid-template-columns: minmax(0, 1fr) minmax(220px, 37%);
  }
}
@media (max-width: 550px) and (orientation: portrait) {
  #lobby {
    height: auto;
    min-height: 100dvh;
  }
  .lobby-grid {
    display: flex;
    flex-direction: column;
  }
  .poster {
    min-height: 220px;
  }
  .join {
    gap: 12px;
  }
  .join .qr-wrap img {
    width: 245px;
  }
  .roster {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}
