/* NIGHTFALL lobby. Fortnite-style layout: the scene fills the screen, glass
   panels float over it, one unmistakable PLAY button. */

@font-face {
  font-family: "Barlow Condensed";
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-600.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-700.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-weight: 800;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-800.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-weight: 800;
  font-style: italic;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-800-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow Condensed";
  font-weight: 900;
  font-style: italic;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-900-italic.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-weight: 500;
  font-display: swap;
  src: url("/assets/fonts/barlow-500.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/barlow-600.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/barlow-700.woff2") format("woff2");
}

:root {
  --ink: #050814;
  --text: #f3f6ff;
  --muted: #9dacd1;
  --faint: #6f7fa8;
  --lime: #c8ff3d;
  --lime-2: #a6ea00;
  --gold: #ffd54a;
  --ready: #54f29a;
  --danger: #ff5a7a;
  --cyan: #6fd8ff;
  --violet: #8c5cff;
  --violet-2: #c0a5ff;
  --mint: var(--lime);
  --line: rgba(172, 198, 255, 0.16);
  --line-strong: rgba(190, 212, 255, 0.34);
  --glass: linear-gradient(
    180deg,
    rgba(58, 82, 160, 0.46),
    rgba(20, 30, 70, 0.6)
  );
  --glass-dark: linear-gradient(
    180deg,
    rgba(18, 26, 58, 0.82),
    rgba(8, 12, 30, 0.88)
  );
  --shadow: 0 18px 46px rgba(0, 0, 0, 0.42);
  --radius: 14px;
  --ease: cubic-bezier(0.2, 0.75, 0.2, 1);
  --display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", sans-serif;
  --body:
    "Barlow", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-family: var(--body);
  font-weight: 600;
}
* {
  box-sizing: border-box;
}
html,
body {
  height: 100%;
  margin: 0;
  background: var(--ink);
  color: var(--text);
}
body {
  overflow: hidden;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
}
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
}
[hidden] {
  display: none !important;
}
.icon {
  width: 18px;
  height: 18px;
  flex: none;
}

/* ---------- scene ---------- */
.app-shell {
  position: fixed;
  inset: 0;
  /* clip, not hidden: focus or scrollIntoView must never pan the scene. */
  overflow: hidden;
  overflow: clip;
  background: var(--ink);
}
.scene-bg,
.bg,
.bg-vignette {
  position: absolute;
  inset: 0;
}
.bg {
  opacity: 0;
  transition:
    opacity 0.9s var(--ease),
    transform 1.2s var(--ease),
    filter 0.9s;
}
.bg-art {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 40%;
}
.app-shell[data-scene="play"] .bg-field,
.app-shell[data-scene="showcase"] .bg-field,
.app-shell[data-scene="shop"] .bg-field {
  opacity: 1;
}
.app-shell[data-scene="showcase"] .bg-field,
.app-shell[data-scene="shop"] .bg-field {
  filter: blur(6px) brightness(0.6) saturate(0.9);
  transform: scale(1.04);
}
.app-shell[data-scene="locker"] .bg-locker {
  opacity: 1;
}
.app-shell[data-scene="locker"] .bg-field {
  transform: scale(1.12);
}

/* Painted night stadium (used until menu art is supplied). */
.bg-field {
  background:
    radial-gradient(
      ellipse 38% 26% at 12% 6%,
      rgba(206, 226, 255, 0.55),
      transparent 70%
    ),
    radial-gradient(
      ellipse 38% 26% at 88% 6%,
      rgba(206, 226, 255, 0.5),
      transparent 70%
    ),
    radial-gradient(
      ellipse 80% 40% at 50% 46%,
      rgba(64, 110, 255, 0.28),
      transparent 70%
    ),
    linear-gradient(180deg, #0a1030 0%, #151c52 30%, #1a1446 44%, #050814 60%);
}
.bg-field::before {
  /* Stands: a dark band of crowd flecked with phone lights and flags. */
  content: "";
  position: absolute;
  left: -5%;
  right: -5%;
  top: 20%;
  height: 32%;
  background:
    radial-gradient(circle at 20% 30%, #fff8 0 1px, transparent 2px) 0 0 / 23px
      17px,
    radial-gradient(circle at 60% 70%, #c8ff3d66 0 1px, transparent 2px) 0 0 /
      37px 29px,
    radial-gradient(circle at 40% 50%, #8fb2ff55 0 1.5px, transparent 2.5px) 0
      0 / 19px 13px,
    repeating-linear-gradient(
      90deg,
      #0e1236 0 9px,
      #121848 9px 14px,
      #0b0f2c 14px 22px
    ),
    linear-gradient(180deg, #151b4c, #080b22);
  clip-path: polygon(0 26%, 100% 26%, 100% 100%, 0 100%);
  opacity: 0.9;
  mask-image: linear-gradient(180deg, #000 60%, transparent);
}
.bg-field::after {
  /* The pitch, receding to the far touchline. */
  content: "";
  position: absolute;
  left: -40%;
  right: -40%;
  top: 46%;
  bottom: -30%;
  background:
    linear-gradient(90deg, transparent 49.8%, #ffffff55 50%, transparent 50.2%),
    repeating-linear-gradient(90deg, #1f6b2c 0 7%, #25793a 7% 14%), #1f6b2c;
  transform: perspective(520px) rotateX(58deg);
  transform-origin: 50% 0;
  filter: brightness(0.62) saturate(1.1);
  mask-image: linear-gradient(180deg, transparent, #000 12%);
}
/* Painted locker room. */
.bg-locker {
  background:
    radial-gradient(
      ellipse 30% 22% at 50% 0%,
      rgba(255, 238, 205, 0.55),
      transparent 72%
    ),
    radial-gradient(
      ellipse 20% 18% at 18% 2%,
      rgba(255, 238, 205, 0.35),
      transparent 70%
    ),
    radial-gradient(
      ellipse 20% 18% at 82% 2%,
      rgba(255, 238, 205, 0.35),
      transparent 70%
    ),
    linear-gradient(180deg, #121b33 0%, #0d1428 58%, #070a16 100%);
}
.bg-locker::before {
  /* Lockers along the back wall. */
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 14%;
  height: 50%;
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0 calc(7.14% - 3px),
      rgba(0, 0, 0, 0.55) calc(7.14% - 3px) 7.14%
    ),
    repeating-linear-gradient(
      180deg,
      transparent 0 12px,
      rgba(255, 255, 255, 0.025) 12px 14px
    ),
    linear-gradient(180deg, #243258, #1a2444 70%, #121a33);
  box-shadow: inset 0 -40px 60px rgba(0, 0, 0, 0.5);
}
.bg-locker::after {
  /* Floor with a sheen, and the club crest glowing on the wall. */
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      ellipse 12% 14% at 50% 30%,
      rgba(200, 255, 61, 0.2),
      transparent 70%
    ),
    radial-gradient(
      ellipse 60% 18% at 50% 76%,
      rgba(140, 170, 255, 0.12),
      transparent 70%
    ),
    linear-gradient(180deg, transparent 63%, #0a0f22 64%, #05070f 100%);
}
.bg-vignette {
  background:
    radial-gradient(
      ellipse 75% 70% at 50% 45%,
      transparent 55%,
      rgba(2, 4, 12, 0.55)
    ),
    linear-gradient(180deg, rgba(2, 4, 12, 0.5), transparent 16%),
    linear-gradient(0deg, rgba(2, 4, 12, 0.7), transparent 24%);
  pointer-events: none;
}
.stage-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  outline: none;
  touch-action: none;
}
.app-shell[data-scene="showcase"] .stage-canvas {
  cursor: grab;
}
.plates {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}
.plates > * {
  position: absolute;
  left: 0;
  top: 0;
  will-change: transform;
}

/* ---------- name plates ---------- */
.plate-play {
  display: grid;
  justify-items: center;
  gap: 5px;
}
.plate-tag {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 9px;
  border-radius: 10px;
  background: rgba(8, 12, 30, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
  white-space: nowrap;
}
.plate-tag strong {
  font: italic 900 22px/1 var(--display);
  letter-spacing: 0.01em;
  color: var(--lime);
}
.plate-play.is-friend .plate-tag strong {
  color: #fff;
}
.platform-badge {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  color: #dfe8ff;
}
.platform-badge .icon {
  width: 16px;
  height: 16px;
}
.plate-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 6px;
  font: 800 13px/1.2 var(--display);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.plate-status .icon {
  width: 13px;
  height: 13px;
}
.plate-status.ready {
  background: rgba(84, 242, 154, 0.9);
  color: #04200f;
}
.plate-status.not-ready {
  background: rgba(255, 90, 122, 0.9);
  color: #2a0510;
}
.plate-status.leader {
  background: rgba(255, 213, 74, 0.92);
  color: #2a2000;
}
.plate-locker {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 4px 10px 4px 4px;
  border-radius: 8px;
  background: rgba(8, 12, 30, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  white-space: nowrap;
  transition:
    background 0.2s,
    border-color 0.2s;
}
.plate-locker.is-selected {
  background: rgba(200, 255, 61, 0.92);
  color: #0d1600;
  border-color: transparent;
}
.plate-number {
  display: grid;
  place-items: center;
  min-width: 28px;
  height: 26px;
  padding: 0 4px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  font: italic 900 18px/1 var(--display);
}
.plate-locker.is-selected .plate-number {
  background: rgba(0, 0, 0, 0.14);
}
.plate-copy {
  display: grid;
  line-height: 1;
}
.plate-copy strong {
  font: italic 800 16px/1 var(--display);
}
.plate-copy small {
  font: 700 10px/1.2 var(--body);
  letter-spacing: 0.1em;
  opacity: 0.7;
}
.plate-crown {
  width: 15px;
  height: 15px;
  color: var(--gold);
}
.plate-locker.is-selected .plate-crown {
  color: #3b3000;
}
.slot-bubble {
  display: grid;
  justify-items: center;
  gap: 4px;
  width: 190px;
  padding: 14px 14px 12px;
  border-radius: 14px;
  background: var(--glass);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  text-align: center;
  pointer-events: auto;
  animation: bubble-in 0.5s var(--ease);
}
.slot-bubble::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -9px;
  width: 16px;
  height: 16px;
  background: rgba(24, 36, 82, 0.9);
  border-right: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
  transform: translateX(-50%) rotate(45deg);
}
.slot-bubble strong {
  font: italic 900 21px/1 var(--display);
  text-transform: uppercase;
}
.slot-bubble span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
}
.bubble-button {
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 0;
  border-radius: 8px;
  background: var(--lime);
  color: #0d1600;
  font: italic 900 17px/1 var(--display);
  text-transform: uppercase;
  box-shadow: 0 6px 18px rgba(200, 255, 61, 0.3);
}
.bubble-button:hover {
  filter: brightness(1.08);
}
@keyframes bubble-in {
  from {
    opacity: 0;
    margin-top: 10px;
  }
}

/* ---------- top bar ---------- */
.topbar {
  position: absolute;
  z-index: 10;
  top: 16px;
  left: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: none;
}
.topbar > * {
  pointer-events: auto;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 52px;
  padding: 0 16px 0 12px;
  border-radius: 12px;
  background: var(--glass-dark);
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
}
.brand-word {
  font: italic 900 24px/1 var(--display);
  letter-spacing: 0.04em;
}
.brand-mark {
  position: relative;
  width: 24px;
  height: 27px;
  transform: skewX(-8deg);
}
.brand-mark i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 10px;
  background: var(--lime);
  clip-path: polygon(0 0, 100% 0, 56% 100%, 0 100%);
}
.brand-mark i:last-child {
  left: 12px;
  background: var(--violet-2);
  clip-path: polygon(44% 0, 100% 0, 100% 100%, 0 100%);
}
.tabs {
  display: flex;
  gap: 6px;
  padding: 6px;
  border-radius: 14px;
  background: var(--glass-dark);
  border: 1px solid var(--line);
}
.tab {
  height: 40px;
  padding: 0 20px;
  border: 0;
  border-radius: 9px;
  background: rgba(120, 150, 230, 0.16);
  color: #e8eeff;
  font: italic 900 21px/1 var(--display);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition:
    background 0.15s,
    color 0.15s,
    transform 0.15s;
}
.tab:hover {
  background: rgba(140, 170, 250, 0.3);
}
.tab.is-active {
  background: #fff;
  color: #0a1230;
  box-shadow: 0 6px 18px rgba(255, 255, 255, 0.18);
}
.topbar-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.season-chip {
  display: grid;
  justify-items: end;
  padding: 0 6px;
  line-height: 1;
}
.season-chip strong {
  font: italic 900 22px/1 var(--display);
  color: var(--lime);
  text-transform: uppercase;
}
.season-chip small {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.currency-pill {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 52px;
  padding: 0 18px 0 10px;
  border-radius: 12px;
  background: var(--glass-dark);
  border: 1px solid var(--line);
}
.coin {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: radial-gradient(
    circle at 35% 30%,
    #efff9e,
    var(--lime) 45%,
    #6d9800
  );
  color: #1c2800;
  font: italic 900 18px/1 var(--display);
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.2);
}
.currency-pill strong {
  font: italic 900 24px/1 var(--display);
}
.profile-tile {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 52px;
  padding: 0 12px 0 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--glass-dark);
  text-align: left;
}
.profile-tile:hover {
  border-color: var(--line-strong);
}
.avatar {
  position: relative;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--violet), #3b2a8a);
  font: italic 900 20px/1 var(--display);
}
.avatar::after {
  content: "";
  position: absolute;
  right: -3px;
  bottom: -3px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--ready);
  border: 2px solid #0b1026;
}
.profile-copy {
  display: grid;
  line-height: 1.1;
}
.profile-copy strong {
  font: 800 16px/1 var(--display);
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.profile-copy small {
  color: var(--muted);
  font-size: 11px;
}
.esc-hint {
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--muted);
  font: 700 10px/1.2 var(--body);
  text-transform: uppercase;
}

/* ---------- layout ---------- */
.main-shell,
.lobby {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}
.boot-state {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 13px;
  text-align: center;
  pointer-events: auto;
  background: radial-gradient(circle at 50% 40%, #1b2560, var(--ink) 65%);
}
.boot-state h1 {
  margin: 3px 0 0;
  font: italic 900 clamp(38px, 5vw, 64px) / 1 var(--display);
  text-transform: uppercase;
}
.boot-state p {
  margin: 0;
  color: var(--muted);
}
.spinner {
  width: 30px;
  height: 30px;
  border: 3px solid rgba(255, 255, 255, 0.13);
  border-top-color: var(--lime);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.left-rail,
.right-rail,
.bottom-dock,
.page {
  pointer-events: auto;
}
.left-rail {
  position: absolute;
  left: 20px;
  top: 88px;
  bottom: 78px;
  width: min(350px, 27vw);
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  scrollbar-width: none;
}
.left-rail::-webkit-scrollbar,
.right-rail::-webkit-scrollbar {
  display: none;
}
.left-rail:empty,
.right-rail:empty {
  display: none;
}
.right-rail {
  position: absolute;
  right: 20px;
  bottom: 20px;
  width: min(390px, 30vw);
  max-height: calc(100% - 108px);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  overflow-y: auto;
  scrollbar-width: none;
}
.app-shell[data-tab="locker"] .right-rail,
.app-shell[data-tab="shop"] .right-rail {
  top: 88px;
  bottom: 78px;
  justify-content: flex-start;
}
.app-shell[data-tab="locker"] .left-rail {
  width: min(300px, 22vw);
}
.bottom-dock {
  position: absolute;
  left: 20px;
  bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: calc(100% - 460px);
}
.app-shell[data-tab="locker"] .bottom-dock {
  left: 20px;
  right: 20px;
  max-width: none;
}
.bottom-dock:empty {
  display: none;
}
.dock-spacer {
  flex: 1;
}
.page {
  position: absolute;
  left: 20px;
  top: 88px;
  bottom: 20px;
  width: min(58vw, 940px);
  overflow-y: auto;
  padding: 4px 8px 40px 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

/* ---------- panels ---------- */
.panel,
.card {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--glass);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    var(--shadow);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
}
.card {
  padding: 16px;
}
.card h3,
.panel h3 {
  margin: 0;
  font: italic 900 22px/1.05 var(--display);
  text-transform: uppercase;
}
.card p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}
.section-kicker {
  margin: 0;
  color: var(--lime);
  font: 800 13px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.section-title {
  margin: 6px 0 0;
  font: italic 900 38px/1 var(--display);
  text-transform: uppercase;
}
.section-copy {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}
.season-card {
  padding: 12px 18px 10px;
  text-align: center;
}
.season-card small {
  display: block;
  color: var(--cyan);
  font: italic 800 17px/1 var(--display);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.season-card h2 {
  margin: 4px 0 0;
  font: italic 900 50px/0.95 var(--display);
  text-transform: uppercase;
  text-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
}
.news-card {
  display: block;
  padding: 0;
  overflow: hidden;
  text-align: left;
  aspect-ratio: 16 / 7;
  flex: none;
}
.news-art {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      circle at 78% 30%,
      rgba(200, 255, 61, 0.55),
      transparent 32%
    ),
    radial-gradient(
      circle at 20% 90%,
      rgba(140, 92, 255, 0.7),
      transparent 45%
    ),
    linear-gradient(135deg, #2a1a6e, #151f5a 55%, #0a0f2a);
  background-size: cover;
  background-position: center;
  transition: transform 0.5s var(--ease);
}
.news-art::after {
  /* Two party silhouettes facing off. */
  content: "";
  position: absolute;
  right: 8%;
  bottom: 0;
  width: 46%;
  height: 86%;
  background:
    radial-gradient(circle at 30% 18%, #0b1030 0 11%, transparent 11.5%),
    radial-gradient(circle at 72% 22%, #0b1030 0 10%, transparent 10.5%),
    radial-gradient(ellipse 22% 60% at 30% 70%, #0b1030 0 98%, transparent),
    radial-gradient(ellipse 20% 56% at 72% 72%, #0b1030 0 98%, transparent);
  opacity: 0.75;
}
.news-card:hover .news-art {
  transform: scale(1.04);
}
.news-copy {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  gap: 2px;
  padding: 26px 16px 13px;
  background: linear-gradient(0deg, rgba(4, 7, 20, 0.85), transparent);
}
.news-tag {
  position: absolute;
  top: -110px;
  right: 12px;
  color: rgba(255, 255, 255, 0.65);
  font: italic 900 18px/1 var(--display);
  text-transform: uppercase;
}
.news-copy strong {
  font: italic 900 34px/1 var(--display);
  text-transform: uppercase;
}
.news-copy small {
  color: #d5def7;
  font-size: 13px;
}
.twin {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 10px;
  flex: none;
}
.level-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
}
.level-ring-wrap {
  position: relative;
  width: 62px;
  height: 62px;
  flex: none;
}
.level-ring {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.level-ring circle {
  fill: none;
  stroke-width: 4.5;
}
.level-ring .track {
  stroke: rgba(255, 255, 255, 0.14);
}
.level-ring .fill {
  stroke: var(--lime);
  stroke-linecap: round;
}
.level-number {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: italic 900 30px/1 var(--display);
}
.level-copy {
  display: grid;
  gap: 3px;
}
.level-copy small {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.level-copy strong {
  font: 800 17px/1.05 var(--display);
}
.rank-card {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 2px;
  padding: 10px;
  text-align: center;
}
.rank-medal {
  width: 30px;
  height: 30px;
  color: var(--gold);
  filter: drop-shadow(0 4px 10px rgba(255, 213, 74, 0.4));
}
.rank-card strong {
  font: italic 900 18px/1 var(--display);
  text-transform: uppercase;
}
.rank-card small {
  color: var(--muted);
  font-size: 11px;
}
.challenges {
  padding: 12px 12px 10px;
  flex: none;
}
.challenges h3 {
  text-align: center;
  margin-bottom: 8px;
}
.challenge {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 7px 10px;
  border-radius: 10px;
  background: rgba(6, 10, 28, 0.35);
}
.challenge + .challenge {
  margin-top: 5px;
}
.challenge-copy strong {
  display: block;
  font-size: 14px;
}
.challenge-bar {
  height: 6px;
  margin-top: 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}
.challenge-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--ready), var(--lime));
}
.challenge-reward {
  display: grid;
  justify-items: end;
  line-height: 1.05;
}
.challenge-reward small {
  color: var(--muted);
  font-size: 11px;
}
.challenge-reward strong {
  font: italic 900 20px/1 var(--display);
}
.challenge.is-done {
  opacity: 0.6;
}
.challenge.is-done .challenge-reward small {
  color: var(--ready);
}
.challenge-group {
  display: block;
  margin: 8px 0 2px;
  color: var(--lime);
  font: 800 11px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.challenge-note {
  margin: 8px 0 0;
  color: var(--faint);
  font-size: 11px;
  text-align: center;
}

/* ---------- play cluster ---------- */
.play-cluster {
  display: grid;
  /* The rail's width, never the widest child's. */
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
}
.play-cluster > * {
  min-width: 0;
}
.mode-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  text-align: left;
  transition:
    border-color 0.15s,
    transform 0.15s;
}
.mode-card:not(:disabled):hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
}
.mode-card-copy {
  display: grid;
  gap: 4px;
}
.mode-card-copy strong {
  font: italic 900 46px/0.9 var(--display);
  text-transform: uppercase;
  letter-spacing: -0.005em;
}
.mode-card-copy small {
  color: var(--lime);
  font: 800 16px/1 var(--display);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.mode-change {
  display: grid;
  justify-items: center;
  gap: 4px;
  color: var(--muted);
  font: 800 12px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.mode-change .icon {
  width: 22px;
  height: 22px;
  color: #fff;
}
.ranked-row {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
  padding: 10px;
  border-radius: 12px;
  background: rgba(150, 160, 190, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}
.ranked-row strong {
  font: italic 900 22px/1 var(--display);
  text-transform: uppercase;
  color: #c9d1e8;
}
.ranked-row small {
  color: var(--faint);
  font-size: 12px;
}
.play-button {
  position: relative;
  display: grid;
  place-items: center;
  gap: 2px;
  min-height: 104px;
  padding: 12px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(
    180deg,
    #e3ff7a 0%,
    var(--lime) 45%,
    var(--lime-2)
  );
  color: #0e1800;
  box-shadow:
    inset 0 -5px 0 rgba(0, 0, 0, 0.14),
    inset 0 2px 0 rgba(255, 255, 255, 0.55),
    0 14px 40px rgba(200, 255, 61, 0.28);
  overflow: hidden;
  transition:
    transform 0.12s var(--ease),
    filter 0.12s,
    box-shadow 0.2s;
}
.play-button strong {
  font: italic 900 62px/0.9 var(--display);
  text-transform: uppercase;
  letter-spacing: 0.01em;
}
.play-button small {
  font: 800 15px/1 var(--display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.72;
}
.play-button::after {
  /* Sheen sweep. */
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    transparent 35%,
    rgba(255, 255, 255, 0.4) 50%,
    transparent 65%
  );
  transform: translateX(-120%);
  animation: sheen 4.5s ease-in-out infinite 1s;
  pointer-events: none;
}
.play-button:not(:disabled):hover {
  transform: translateY(-2px) scale(1.01);
  filter: brightness(1.05);
}
.play-button:not(:disabled):active {
  transform: translateY(1px) scale(0.995);
}
.play-button.is-waiting,
.play-button:disabled {
  background: linear-gradient(180deg, #5b6583, #3c4462);
  color: #d5dbee;
  box-shadow: inset 0 -5px 0 rgba(0, 0, 0, 0.18);
}
.play-button.is-waiting::after,
.play-button:disabled::after {
  display: none;
}
.play-button.is-cancel {
  background: linear-gradient(180deg, #ff8aa0, var(--danger) 55%, #d63355);
  color: #2a0510;
  box-shadow:
    inset 0 -5px 0 rgba(0, 0, 0, 0.14),
    0 14px 40px rgba(255, 90, 122, 0.25);
}
.play-button.is-searching small::after {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-left: 8px;
  border-radius: 50%;
  background: currentColor;
  animation: pulse 1s ease-in-out infinite;
}
@keyframes sheen {
  0%,
  70% {
    transform: translateX(-120%);
  }
  100% {
    transform: translateX(120%);
  }
}
@keyframes pulse {
  50% {
    opacity: 0.2;
  }
}
.quick-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}
.chip-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 46px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--glass-dark);
  color: #fff;
  font: italic 900 19px/1 var(--display);
  text-transform: uppercase;
  white-space: nowrap;
  backdrop-filter: blur(12px);
  transition:
    border-color 0.15s,
    background 0.15s;
}
.chip-button:hover {
  border-color: var(--line-strong);
  background: rgba(40, 56, 110, 0.85);
}
.chip-button.icon-only {
  width: 46px;
  padding: 0;
  justify-content: center;
}
.party-chip {
  flex: 1;
  justify-content: center;
}
.chip-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  display: grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 10px;
  background: var(--danger);
  font: 800 12px/1 var(--body);
  font-style: normal;
}
.status-chip {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  border-radius: 9px;
  background: rgba(8, 12, 30, 0.7);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}
.status-chip.good {
  color: var(--ready);
}
.status-chip.warn {
  color: var(--gold);
}

/* ---------- buttons & forms ---------- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 20px;
  border: 0;
  border-radius: 11px;
  background: linear-gradient(180deg, #e3ff7a, var(--lime) 50%, var(--lime-2));
  color: #0e1800;
  font: italic 900 20px/1 var(--display);
  text-transform: uppercase;
  box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.14);
}
.button:not(:disabled):hover {
  filter: brightness(1.06);
}
.button:disabled {
  opacity: 0.45;
}
.button-secondary {
  background: rgba(20, 30, 70, 0.85);
  border: 1px solid var(--line-strong);
  color: #fff;
  box-shadow: none;
}
.button-danger {
  background: var(--danger);
  color: #2a0510;
}
.button-small {
  min-height: 36px;
  padding: 0 14px;
  font-size: 16px;
}
.button-wide {
  width: 100%;
}
.icon-button {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.06);
}
.icon-button:hover {
  border-color: var(--line-strong);
}
.icon-button.tiny {
  width: 28px;
  height: 28px;
}
.icon-button.tiny .icon {
  width: 14px;
  height: 14px;
}
.icon-button.is-confirm {
  background: var(--danger);
  color: #2a0510;
}
.text-button {
  border: 0;
  background: none;
  color: var(--lime);
  text-decoration: underline;
}
.small-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: var(--lime);
  color: #0e1800;
  font: italic 900 16px/1 var(--display);
  text-transform: uppercase;
  white-space: nowrap;
}
.small-button .icon {
  width: 15px;
  height: 15px;
}
.small-button.ghost {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: 1px solid var(--line);
}
.small-button.wide {
  width: 100%;
  justify-content: center;
  margin-top: 8px;
}
.small-button:hover {
  filter: brightness(1.08);
}
.inline-action {
  display: flex;
  gap: 8px;
}
.inline-action input,
.field input,
.field select {
  flex: 1;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(4, 8, 22, 0.6);
  color: var(--text);
  font-weight: 700;
}
.inline-action input::placeholder {
  color: var(--faint);
}
.inline-action.wide {
  margin: 16px 0 6px;
}
.inline-action .small-button {
  height: 40px;
}
.inline-form {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}
.field {
  display: grid;
  gap: 5px;
}
.field label {
  color: var(--muted);
  font: 800 12px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.hair-field {
  margin-top: 10px;
}
.hair-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: 6px;
  margin-top: 6px;
  max-height: 188px;
  overflow-y: auto;
  padding-right: 2px;
}
.hair-chip {
  position: relative;
  padding: 8px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  font: 700 12px/1.15 var(--body, inherit);
  text-align: left;
  cursor: pointer;
}
.hair-chip:hover {
  border-color: var(--line-strong);
}
.hair-chip.is-selected {
  border-color: var(--lime);
  background: rgba(200, 255, 61, 0.12);
}
.hair-chip.is-locked {
  color: var(--muted);
}
.hair-chip .chip-lock {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 11px;
  height: 11px;
}
.color-field {
  display: flex;
  align-items: center;
  gap: 7px;
}
.color-field input[type="color"] {
  flex: none;
  width: 46px;
  padding: 4px;
}
.seg-tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 11px;
  background: rgba(4, 8, 22, 0.5);
  overflow-x: auto;
  scrollbar-width: none;
}
.seg-tabs button {
  flex: 1;
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font: italic 900 18px/1 var(--display);
  text-transform: uppercase;
  white-space: nowrap;
}
.seg-tabs button.is-active {
  background: #fff;
  color: #0a1230;
}
.error-box {
  padding: 10px 12px;
  border: 1px solid rgba(255, 90, 122, 0.3);
  border-radius: 10px;
  background: rgba(255, 90, 122, 0.1);
  color: #ffc0d0;
  font-size: 12px;
}

/* ---------- mode picker ---------- */
.scrim {
  position: absolute;
  inset: 0;
  z-index: 40;
  background: rgba(3, 6, 18, 0.55);
  backdrop-filter: blur(4px);
  animation: fade-in 0.2s;
}
.mode-picker {
  position: absolute;
  z-index: 45;
  left: 50%;
  top: 50%;
  width: min(980px, calc(100vw - 40px));
  max-height: calc(100% - 60px);
  overflow: auto;
  padding: 22px;
  border-radius: 18px;
  background: var(--glass-dark);
  border: 1px solid var(--line-strong);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6);
  transform: translate(-50%, -50%);
  animation: pop-in 0.28s var(--ease);
}
.picker-head {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 16px;
}
.picker-head small {
  display: block;
  color: var(--lime);
  font: 800 14px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.picker-head h2 {
  margin: 4px 0 0;
  flex: 1;
  font: italic 900 42px/1 var(--display);
  text-transform: uppercase;
}
.picker-head .icon-button {
  margin-left: auto;
  align-self: flex-start;
}
.mode-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.mode-tile {
  position: relative;
  display: grid;
  grid-template-rows: 130px auto;
  padding: 0;
  overflow: hidden;
  border: 2px solid transparent;
  border-radius: 14px;
  background: rgba(20, 30, 70, 0.8);
  text-align: left;
  transition:
    transform 0.15s var(--ease),
    border-color 0.15s;
}
.mode-tile:not(:disabled):hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.5);
}
.mode-tile.is-selected {
  border-color: var(--lime);
}
.mode-tile-art {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #3a2a9a, #16205a);
}
.mode-tile-art .icon {
  width: 64px;
  height: 64px;
  stroke-width: 1.4;
  color: #fff;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.4));
}
.mode-vs-ai .mode-tile-art {
  background:
    radial-gradient(circle at 70% 30%, #6bd4ff66, transparent 50%),
    linear-gradient(135deg, #1a5c8a, #10224f);
}
.mode-friendly .mode-tile-art {
  background:
    radial-gradient(circle at 30% 30%, #c8ff3d66, transparent 50%),
    linear-gradient(135deg, #3e6a10, #15300c);
}
.mode-quick .mode-tile-art {
  background:
    radial-gradient(circle at 70% 30%, #ffd54a66, transparent 50%),
    linear-gradient(135deg, #8a4a12, #3a1a08);
}
.mode-ranked .mode-tile-art {
  background:
    radial-gradient(circle at 50% 30%, #ffd54a55, transparent 50%),
    linear-gradient(135deg, #5a3a9a, #1e1447);
}
.mode-tile-copy {
  display: grid;
  gap: 4px;
  padding: 12px 14px 14px;
}
/* Training is the way in for new players: a banner above the six modes. */
.mode-tile.mode-training {
  grid-column: 1 / -1;
  grid-template-rows: none;
  grid-template-columns: minmax(100px, 28%) 1fr;
  min-height: 96px;
}
.mode-training .mode-tile-art {
  background:
    radial-gradient(circle at 30% 40%, #c8ff3d55, transparent 60%),
    linear-gradient(135deg, #2f6a1c, #13301a);
}
.mode-training .mode-tile-copy {
  align-content: center;
  padding: 14px 120px 14px 20px;
}
.mode-training .mode-tile-tag {
  left: auto;
  right: 12px;
}
.mode-tile-copy strong {
  font: italic 900 30px/1 var(--display);
  text-transform: uppercase;
}
.mode-tile-copy small {
  color: var(--muted);
  font-size: 13px;
}
.mode-tile-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.55);
  color: #d8def0;
  font: 800 12px/1 var(--display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.mode-tile-tag.ok {
  background: var(--lime);
  color: #0e1800;
}
.mode-tile.is-blocked .mode-tile-art,
.mode-tile.is-blocked .mode-tile-copy {
  filter: grayscale(0.8) brightness(0.7);
}
@keyframes pop-in {
  from {
    opacity: 0;
    transform: translate(-50%, -48%) scale(0.97);
  }
}
@keyframes fade-in {
  from {
    opacity: 0;
  }
}

/* ---------- party & friends drawer ---------- */
.drawer {
  position: absolute;
  z-index: 50;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(410px, 100vw);
  display: flex;
  flex-direction: column;
  background: linear-gradient(
    180deg,
    rgba(14, 20, 48, 0.97),
    rgba(6, 9, 24, 0.98)
  );
  border-left: 1px solid var(--line-strong);
  box-shadow: -30px 0 80px rgba(0, 0, 0, 0.5);
  transform: translateX(100%);
  transition: transform 0.32s var(--ease);
}
.drawer.is-open {
  transform: none;
}
.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 20px 12px;
}
.drawer-head h2 {
  margin: 0;
  font: italic 900 32px/1 var(--display);
  text-transform: uppercase;
}
.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 0 20px 30px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}
.you-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
}
.you-copy {
  flex: 1;
  display: grid;
  min-width: 0;
}
.you-copy strong {
  font: italic 900 24px/1 var(--display);
  color: var(--lime);
  overflow: hidden;
  text-overflow: ellipsis;
}
.you-copy small {
  color: var(--muted);
  font-size: 12px;
}
.drawer-section {
  margin-top: 18px;
}
.drawer-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 8px;
}
.drawer-section-head h3 {
  margin: 0;
  font: italic 900 20px/1 var(--display);
  text-transform: uppercase;
}
.drawer-section-head small {
  color: var(--muted);
  font-size: 12px;
}
.drawer-note {
  margin: 6px 0 0;
  color: var(--faint);
  font-size: 13px;
  line-height: 1.4;
}
.party-code {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 8px;
  border-radius: 12px;
  border: 1px dashed rgba(200, 255, 61, 0.45);
  background: rgba(200, 255, 61, 0.07);
}
.party-code small {
  color: var(--muted);
  font: 800 12px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.party-code strong {
  flex: 1;
  color: var(--lime);
  font: italic 900 32px/1 var(--display);
  letter-spacing: 0.12em;
}
.member-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
}
.member-row + .member-row {
  margin-top: 6px;
}
.member-copy {
  flex: 1;
  display: grid;
  min-width: 0;
}
.member-copy strong {
  font: 800 17px/1.1 var(--display);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.member-copy small {
  color: var(--muted);
  font-size: 12px;
}
.leader-crown {
  width: 18px;
  height: 18px;
  color: var(--gold);
}
.presence {
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #4a5370;
}
.presence.menu {
  background: var(--ready);
  box-shadow: 0 0 8px var(--ready);
}
.presence.match {
  background: var(--gold);
}
.friend:not(.is-online) .member-copy strong {
  color: #b8c2de;
}

/* ---------- invites ---------- */
.invites {
  position: absolute;
  z-index: 30;
  top: 88px;
  left: 50%;
  display: grid;
  gap: 8px;
  transform: translateX(-50%);
}
.invite-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 10px 10px 14px;
  border-radius: 12px;
  background: var(--glass-dark);
  border: 1px solid rgba(200, 255, 61, 0.5);
  box-shadow: var(--shadow);
  animation: bubble-in 0.35s var(--ease);
}
.invite-card > .icon {
  color: var(--lime);
  width: 22px;
  height: 22px;
}
.invite-copy {
  display: grid;
}
.invite-copy strong {
  font: italic 900 20px/1 var(--display);
}
.invite-copy small {
  color: var(--muted);
  font-size: 12px;
}

/* ---------- locker ---------- */
.locker-head {
  padding: 14px;
  flex: none;
}
.locker-head small {
  color: var(--cyan);
  font: italic 800 15px/1 var(--display);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.locker-head h2 {
  margin: 2px 0 10px;
  font: italic 900 38px/1 var(--display);
  text-transform: uppercase;
}
.roster {
  padding: 6px;
  flex: none;
}
.roster-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 7px 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  text-align: left;
}
.roster-row:hover {
  background: rgba(255, 255, 255, 0.06);
}
.roster-row.is-active {
  background: var(--lime);
  color: #0e1800;
}
.roster-number {
  display: grid;
  place-items: center;
  width: 30px;
  height: 26px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.1);
  font: italic 900 18px/1 var(--display);
}
.roster-row.is-active .roster-number {
  background: rgba(0, 0, 0, 0.12);
}
.roster-row strong {
  flex: 1;
  font: italic 800 19px/1 var(--display);
  text-transform: uppercase;
}
.roster-row small {
  font: 700 11px/1 var(--body);
  letter-spacing: 0.1em;
  opacity: 0.7;
}
.roster-crown {
  width: 16px;
  height: 16px;
  color: var(--gold);
}
.roster-row.is-active .roster-crown {
  color: #3b3000;
}
.kit-panel {
  padding: 10px;
  flex: none;
}
.slot-tabs button {
  font-size: 15px;
  padding: 0 8px;
}
.locker-hint h3 {
  font-size: 26px;
}
.editor-actions {
  display: grid;
  gap: 6px;
}

/* ---------- pages ---------- */
.page-head {
  margin: 4px 0 16px;
}
.page-head small {
  color: var(--lime);
  font: 800 15px/1 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.page-head h1 {
  margin: 4px 0 6px;
  font: italic 900 clamp(48px, 6vw, 78px) / 0.92 var(--display);
  text-transform: uppercase;
  text-shadow: 0 6px 30px rgba(0, 0, 0, 0.4);
}
.page-head p {
  margin: 0;
  max-width: 620px;
  color: #c9d3ee;
  font-size: 15px;
  line-height: 1.45;
}
.page > .panel,
.page > .card,
.page > section {
  margin-bottom: 12px;
}
.pass-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px 20px;
}
.pass-level {
  display: grid;
  justify-items: center;
  padding: 8px 16px;
  border-radius: 12px;
  background: var(--lime);
  color: #0e1800;
  line-height: 1;
}
.pass-level small {
  font: 800 13px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.pass-level strong {
  font: italic 900 48px/1 var(--display);
}
.pass-copy {
  flex: 1;
  display: grid;
  gap: 8px;
}
.pass-copy strong {
  font: italic 900 26px/1 var(--display);
}
.pass-copy small {
  color: var(--muted);
}
.pass-bar,
.progress {
  height: 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}
.pass-bar i,
.progress > i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--ready), var(--lime));
  border-radius: inherit;
}
.pass-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin: 14px 2px 6px;
}
.pass-section-head h3 {
  margin: 0;
  font: italic 900 22px/1 var(--display);
  text-transform: uppercase;
}
.pass-section-head small {
  color: var(--muted);
  font-size: 12px;
}
.season-bar {
  height: 6px;
  margin: 0 2px 10px;
}
.pass-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 158px;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 2px 12px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}
.pass-tier {
  position: relative;
  display: grid;
  gap: 4px;
  padding: 10px 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(
    180deg,
    rgba(40, 58, 120, 0.6),
    rgba(12, 18, 44, 0.8)
  );
  text-align: left;
  transition:
    transform 0.15s,
    border-color 0.15s;
}
.pass-tier:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
}
.pass-tier.is-owned {
  border-color: rgba(200, 255, 61, 0.55);
}
.pass-tier.is-previewing {
  border-color: #fff;
}
.pass-tier .item-art {
  width: 100%;
  height: 86px;
}
.tier-number {
  color: var(--muted);
  font: 800 12px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.pass-tier strong {
  font: italic 800 18px/1.05 var(--display);
}
.pass-tier small {
  color: var(--muted);
  font-size: 12px;
}
.pass-tier.is-owned small {
  color: var(--lime);
}
.tier-lock {
  position: absolute;
  top: 9px;
  right: 9px;
  width: 16px;
  height: 16px;
  color: var(--muted);
}
.shop-section h3 {
  margin: 18px 0 0;
  font: italic 900 26px/1 var(--display);
  text-transform: uppercase;
}
.stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.stat-tile {
  display: grid;
  gap: 2px;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--glass);
  backdrop-filter: blur(14px);
}
.stat-tile strong {
  font: italic 900 42px/1 var(--display);
}
.stat-tile small {
  color: var(--muted);
  font: 800 13px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ---------- collection cards ---------- */
.grid-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(138px, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.cosmetic-card {
  position: relative;
  min-height: 112px;
  padding: 10px 12px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(
    180deg,
    rgba(40, 58, 120, 0.5),
    rgba(12, 18, 44, 0.75)
  );
  overflow: hidden;
  text-align: left;
}
.cosmetic-card:hover {
  border-color: var(--line-strong);
}
.cosmetic-card.is-equipped {
  border-color: rgba(200, 255, 61, 0.6);
}
.cosmetic-card.is-previewing {
  border-color: #fff;
  box-shadow: inset 0 0 0 1px #fff;
}
.cosmetic-card .item-art {
  width: 100%;
  height: 86px;
  display: block;
  margin: 4px 0 6px;
  filter: drop-shadow(0 8px 12px #0006);
}
.item-rarity {
  color: var(--violet-2);
  font: 800 11px/1 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.item-name {
  display: block;
  margin-top: 3px;
  font: italic 800 18px/1.05 var(--display);
}
.item-meta {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}
/* Rarity: colour-coded frames, epics glow, legendaries shimmer gold. */
.cosmetic-card.rarity-uncommon {
  border-color: rgba(74, 222, 128, 0.35);
}
.cosmetic-card.rarity-rare {
  border-color: rgba(96, 165, 250, 0.5);
  background: linear-gradient(
    180deg,
    rgba(37, 78, 160, 0.55),
    rgba(12, 18, 44, 0.8)
  );
}
.cosmetic-card.rarity-epic {
  border-color: rgba(192, 132, 252, 0.7);
  background: linear-gradient(
    180deg,
    rgba(109, 40, 217, 0.5),
    rgba(24, 10, 52, 0.85)
  );
  box-shadow: 0 0 18px rgba(168, 85, 247, 0.25);
}
.cosmetic-card.rarity-legendary {
  border-color: rgba(251, 191, 36, 0.85);
  background: linear-gradient(
    180deg,
    rgba(146, 96, 12, 0.55),
    rgba(38, 22, 4, 0.9)
  );
  box-shadow: 0 0 22px rgba(251, 191, 36, 0.3);
}
.cosmetic-card.rarity-legendary::after,
.featured-item.rarity-legendary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    115deg,
    transparent 30%,
    rgba(255, 240, 190, 0.28) 45%,
    transparent 60%
  );
  background-size: 250% 100%;
  animation: nf-shimmer 3.2s ease-in-out infinite;
  pointer-events: none;
}
@keyframes nf-shimmer {
  0% {
    background-position: 120% 0;
  }
  60%,
  100% {
    background-position: -120% 0;
  }
}
.item-rarity.rarity-uncommon,
.rarity-uncommon .item-rarity {
  color: #4ade80;
}
.item-rarity.rarity-rare,
.rarity-rare .item-rarity {
  color: #60a5fa;
}
.item-rarity.rarity-epic,
.rarity-epic .item-rarity {
  color: #c084fc;
}
.item-rarity.rarity-legendary,
.rarity-legendary .item-rarity {
  color: #fbbf24;
}
.item-description {
  margin: 6px 0 2px;
  color: #e7ebf8;
  font-size: 14px;
  line-height: 1.35;
}
.slot-tabs {
  flex-wrap: wrap;
}
.featured-strip {
  display: grid;
  gap: 6px;
}
.featured-label {
  color: #fbbf24;
  font: 800 11px/1 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.featured-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}
.featured-item {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 6px 4px 8px;
  border: 1px solid rgba(192, 132, 252, 0.6);
  border-radius: 10px;
  background: linear-gradient(
    180deg,
    rgba(109, 40, 217, 0.45),
    rgba(24, 10, 52, 0.85)
  );
  overflow: hidden;
  color: inherit;
  cursor: pointer;
}
.featured-item.rarity-legendary {
  border-color: rgba(251, 191, 36, 0.85);
  background: linear-gradient(
    180deg,
    rgba(146, 96, 12, 0.5),
    rgba(38, 22, 4, 0.9)
  );
}
.featured-item.is-previewing {
  border-color: #fff;
}
.featured-item .item-art {
  width: 100%;
  height: 52px;
}
.featured-item strong {
  font: italic 800 13px/1.05 var(--display);
  text-align: center;
}
.lock-overlay {
  position: absolute;
  right: 8px;
  top: 8px;
  padding: 3px 6px;
  border-radius: 5px;
  background: rgba(4, 8, 22, 0.8);
  color: #d4dbef;
  font: 800 11px/1 var(--display);
  letter-spacing: 0.08em;
}
.swatches {
  display: flex;
  gap: 4px;
}
.swatch {
  width: 24px;
  height: 6px;
  border-radius: 8px;
  background: var(--swatch);
}
.preview-card .item-art {
  width: 100%;
  height: 140px;
  display: block;
  margin: 10px 0;
  background: radial-gradient(
    ellipse,
    rgba(200, 255, 61, 0.12),
    transparent 70%
  );
}
.preview-card .button {
  margin-top: 10px;
}
.preview-card .preview-unlock {
  color: var(--lime);
  font-weight: 700;
}
.leaderboard {
  display: grid;
  gap: 5px;
  margin-top: 12px;
}
.leader-row {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 9px;
  background: rgba(4, 8, 22, 0.4);
}
.leader-row.is-me {
  background: rgba(200, 255, 61, 0.14);
}
.leader-row > span:first-child {
  font: italic 900 18px/1 var(--display);
  color: var(--muted);
}
.leader-row strong {
  font: 800 16px/1 var(--display);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.leader-row span {
  color: var(--muted);
  font-size: 12px;
}
.empty-state {
  padding: 18px 10px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
  border: 1px dashed var(--line);
  border-radius: 10px;
}
.room-code {
  margin: 12px 0;
  padding: 12px;
  border: 1px dashed rgba(200, 255, 61, 0.4);
  border-radius: 12px;
  text-align: center;
  font: italic 900 30px/1 var(--display);
  letter-spacing: 0.14em;
  color: var(--lime);
}

/* ---------- toasts, modal, match overlay ---------- */
.toast-region {
  position: fixed;
  z-index: 300;
  left: 50%;
  bottom: 22px;
  display: grid;
  gap: 8px;
  width: min(420px, calc(100vw - 36px));
  transform: translateX(-50%);
  pointer-events: none;
}
.toast {
  padding: 12px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: rgba(8, 12, 30, 0.95);
  box-shadow: var(--shadow);
  font-size: 14px;
  text-align: center;
  animation: toast-in 0.25s var(--ease);
}
.toast.error {
  border-color: rgba(255, 90, 122, 0.55);
  color: #ffd0da;
}
@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}
.modal {
  width: min(760px, calc(100vw - 28px));
  max-height: min(86dvh, 820px);
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  color: var(--text);
  background: linear-gradient(
    180deg,
    rgba(18, 26, 60, 0.98),
    rgba(7, 10, 26, 0.98)
  );
  box-shadow: 0 32px 120px #000;
}
.modal::backdrop {
  background: rgba(2, 4, 12, 0.7);
  backdrop-filter: blur(6px);
}
.modal-frame {
  position: relative;
  margin: 0;
  padding: 24px;
  max-height: inherit;
  overflow: auto;
}
.modal-close {
  position: absolute;
  z-index: 2;
  right: 14px;
  top: 12px;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.05);
  font-size: 22px;
}
.modal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 16px;
}
.modal .card {
  backdrop-filter: none;
  box-shadow: none;
}
.setting-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.setting-row strong {
  display: block;
  font-size: 14px;
}
.setting-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}
.select-setting {
  min-width: 128px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #151a2c;
  color: inherit;
  font: inherit;
  font-size: 13px;
}
.switch {
  appearance: none;
  width: 44px;
  height: 24px;
  padding: 2px;
  border: 0;
  border-radius: 99px;
  background: #39415e;
  cursor: pointer;
  transition: background 0.2s;
}
.switch::before {
  content: "";
  display: block;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s;
}
.switch:checked {
  background: var(--lime-2);
}
.switch:checked::before {
  transform: translateX(20px);
}
.result-score {
  margin: 16px 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  font: italic 900 64px/1 var(--display);
}
.result-score i {
  color: var(--muted);
  font-style: normal;
  font-size: 22px;
}
.game-layer {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: #03050d;
}
.game-layer iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}
.game-toolbar {
  position: absolute;
  z-index: 3;
  top: 14px;
  left: 14px;
  right: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}
.game-toolbar > * {
  pointer-events: auto;
}
.game-quit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
}
.game-quit .quit-x {
  font-size: 16px;
  line-height: 1;
}
.game-quit .quit-label {
  display: none;
  white-space: nowrap;
}
.game-quit.is-confirm {
  border-color: transparent;
  background: var(--danger);
  color: #fff;
}
.game-quit.is-confirm .quit-label {
  display: inline;
}
/* On touch screens the match's own pause button sits in that corner. */
@media (pointer: coarse) {
  #game-settings {
    display: none;
  }
}
.game-toolbar span {
  flex: 1;
  text-align: center;
  color: #d2dcf3;
  font: 800 13px/1 var(--display);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-shadow: 0 2px 10px #000;
  pointer-events: none;
  transition: opacity 0.6s ease;
}
.game-toolbar span.is-quiet {
  opacity: 0;
}
.game-wait {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 9px;
  background: radial-gradient(circle at 50% 40%, #1b2560, #04060f 60%);
  text-align: center;
}
.game-wait strong {
  font: italic 900 34px/1 var(--display);
  text-transform: uppercase;
}
.game-wait span {
  color: var(--muted);
  font-size: 13px;
}

html[data-reduced-motion="true"] *,
html[data-reduced-motion="true"] *::before,
html[data-reduced-motion="true"] *::after {
  animation-duration: 0.001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
}

/* ---------- smaller screens ---------- */
@media (max-width: 1180px) {
  .tab {
    padding: 0 13px;
    font-size: 18px;
  }
  .season-chip {
    display: none;
  }
  .mode-card-copy strong {
    font-size: 38px;
  }
  .play-button strong {
    font-size: 52px;
  }
}
@media (max-width: 860px) {
  .topbar {
    top: 10px;
    left: 10px;
    right: 10px;
    flex-wrap: wrap;
  }
  .brand-word,
  .profile-copy,
  .esc-hint {
    display: none;
  }
  .tabs {
    order: 3;
    width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .left-rail {
    display: none;
  }
  .app-shell:not([data-tab="play"]) .left-rail {
    display: flex;
    top: auto;
    left: 10px;
    right: 10px;
    bottom: 10px;
    width: auto;
    max-height: 44%;
  }
  .app-shell:not([data-tab="play"]) .right-rail {
    top: 130px;
    bottom: auto;
    max-height: 30%;
  }
  .right-rail,
  .app-shell[data-tab="locker"] .right-rail {
    top: auto;
    left: 10px;
    right: 10px;
    bottom: 10px;
    width: auto;
    max-height: 48%;
  }
  .bottom-dock {
    display: none;
  }
  .page {
    left: 10px;
    right: 10px;
    top: 130px;
    width: auto;
  }
  .app-shell[data-scene="showcase"] .stage-canvas {
    opacity: 0.25;
  }
  .mode-grid {
    grid-template-columns: 1fr 1fr;
  }
  .mode-training .mode-tile-copy {
    padding: 34px 14px 14px;
  }
  .stat-grid {
    grid-template-columns: 1fr 1fr;
  }
  .invites {
    top: 128px;
  }
  .slot-bubble {
    width: 140px;
    padding: 10px;
  }
  .slot-bubble span {
    display: none;
  }
  .slot-bubble strong {
    font-size: 17px;
  }
}
.news-art.has-art::after {
  display: none;
}
.bg-art:not([style]) {
  display: none;
}
.mode-tile-art.has-art {
  background-size: cover;
  background-position: center;
}
.bg.has-art::before,
.bg.has-art::after {
  display: none;
}

/* ---------- result screen ---------- */
.result-layer {
  position: fixed;
  inset: 0;
  z-index: 260;
  display: grid;
  place-items: center;
  padding: 24px;
  overflow-y: auto;
  background:
    radial-gradient(
      ellipse 70% 60% at 50% 30%,
      rgba(40, 60, 140, 0.55),
      transparent 70%
    ),
    rgba(3, 5, 14, 0.82);
  backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}
.result-layer.is-open {
  opacity: 1;
}
.result-card {
  width: min(640px, 100%);
  display: grid;
  gap: 16px;
  padding: 26px 26px 22px;
  border-radius: 20px;
  border: 1px solid var(--line-strong);
  background: var(--glass-dark);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6);
  text-align: center;
  animation: pop-in-flat 0.45s var(--ease);
}
@keyframes pop-in-flat {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }
}
.result-kicker,
.result-section-title {
  color: var(--muted);
  font: 800 14px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.result-outcome {
  margin: -6px 0 0;
  font: italic 900 clamp(64px, 11vw, 104px) / 0.9 var(--display);
  text-transform: uppercase;
  letter-spacing: 0.01em;
}
.is-win .result-outcome {
  color: var(--lime);
  text-shadow: 0 0 40px rgba(200, 255, 61, 0.35);
}
.is-training .result-outcome {
  font-size: clamp(46px, 7.4vw, 76px);
}
.result-drills {
  margin: 0;
  color: #d8def5;
  font-size: 17px;
  line-height: 1.45;
}
.is-loss .result-outcome {
  color: #ff8aa0;
}
.is-draw .result-outcome,
.is-abandoned .result-outcome {
  color: #e6ecff;
}
.result-scoreline {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
}
.result-side {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.result-side small {
  color: var(--muted);
  font: 800 12px/1 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.result-side strong {
  font: italic 900 24px/1.05 var(--display);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.result-score {
  display: flex;
  align-items: center;
  gap: 12px;
  font: italic 900 72px/1 var(--display);
}
.result-score i {
  color: var(--faint);
  font-size: 40px;
  font-style: normal;
}
.result-stats {
  display: grid;
  gap: 8px;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
}
.result-stat {
  display: grid;
  grid-template-columns: 56px 1fr 56px;
  align-items: center;
  gap: 4px 10px;
}
.result-stat span {
  font: italic 900 20px/1 var(--display);
}
.result-stat span:first-child {
  text-align: left;
}
.result-stat span:nth-child(3) {
  text-align: right;
}
.result-stat small {
  color: var(--muted);
  font: 800 12px/1 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.result-stat-bar {
  grid-column: 1 / -1;
  height: 5px;
  border-radius: 5px;
  background: rgba(255, 110, 140, 0.35);
  overflow: hidden;
}
.result-stat-bar i {
  display: block;
  height: 100%;
  background: var(--lime);
  border-radius: inherit;
  transition: width 0.8s var(--ease);
}
.ranked-result {
  display: grid;
  justify-items: center;
  gap: 2px;
  margin: 4px 0 10px;
}
.ranked-result strong {
  font: italic 900 34px/1 var(--display);
}
.ranked-result .is-up {
  color: var(--lime);
}
.ranked-result .is-down {
  color: #ff7a7a;
}
.ranked-result small {
  color: var(--muted);
}
.ranked-panel {
  margin-top: 12px;
}
.ranked-panel h4 {
  margin: 14px 0 6px;
  font: 800 13px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.ranked-stats {
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  margin-top: 10px;
}
.ranked-stats .stat-tile {
  padding: 12px;
}
.ranked-stats .stat-tile strong {
  font-size: 26px;
  white-space: nowrap;
}
.result-badge {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  font-weight: 900;
}
.result-badge.is-W {
  background: var(--lime);
  color: #0e1800;
}
.result-badge.is-D {
  background: #475069;
}
.result-badge.is-L {
  background: #b4233a;
}
.result-rewards {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(200, 255, 61, 0.25);
  background: rgba(200, 255, 61, 0.05);
}
.reward-row {
  display: flex;
  justify-content: center;
  gap: 12px;
}
.reward-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
}
.reward-chip strong {
  font: italic 900 36px/1 var(--display);
  color: var(--lime);
}
.reward-chip.credits strong {
  color: #fff;
}
.reward-chip small {
  color: var(--muted);
  font: 800 13px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.coin.small {
  width: 22px;
  height: 22px;
  font-size: 13px;
  align-self: center;
}
.result-level {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 4px 12px;
  text-align: left;
}
.result-level .pass-bar i {
  transition: width 1.2s var(--ease) 0.3s;
}
.result-level small {
  grid-column: 2;
  color: var(--muted);
  font-size: 12px;
}
.result-level-badge {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--lime);
  color: #0e1800;
  font: italic 900 24px/1 var(--display);
}
.level-up {
  justify-self: center;
  padding: 6px 16px;
  border-radius: 8px;
  background: var(--gold);
  color: #2a2000;
  font: italic 900 20px/1.1 var(--display);
  text-transform: uppercase;
  animation: pop-in-flat 0.5s var(--ease) 0.6s both;
}
.reward-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}
.reward-pill {
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.08);
}
.reward-pill.unlock {
  background: rgba(200, 255, 61, 0.16);
  color: var(--lime);
}
.reward-pill.challenge {
  background: rgba(255, 213, 74, 0.16);
  color: var(--gold);
}
.result-note {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.result-actions {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 10px;
}
.play-button.compact {
  min-height: 60px;
}
.play-button.compact strong {
  font-size: 34px;
}
.item-rarity.rare,
.cosmetic-card .item-rarity:is(.rare) {
  color: var(--gold);
}

/* ---------- account ---------- */
.account-box {
  display: grid;
  gap: 10px;
  margin: 16px 0;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}
.account-kicker {
  color: var(--lime);
  font: 800 13px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.account-email {
  font: italic 900 26px/1 var(--display);
  word-break: break-all;
}
.account-box .section-copy {
  margin: 0;
}
.account-form {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 8px;
}
.account-form input {
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(4, 8, 22, 0.6);
  color: var(--text);
  font-weight: 700;
}
.account-form .small-button {
  height: 40px;
}
.account-signin summary {
  cursor: pointer;
  color: var(--muted);
  font-weight: 700;
}
.account-signin[open] {
  display: grid;
  gap: 8px;
}
.account-warn {
  margin: 0;
  color: var(--gold);
  font-size: 13px;
}
.account-status {
  margin: 0;
  min-height: 1em;
  color: var(--ready);
  font-size: 13px;
}
.account-status.error {
  color: #ff9db1;
}
.result-nudge {
  justify-self: center;
  font-size: 13px;
}
@media (max-width: 640px) {
  .account-form {
    grid-template-columns: 1fr;
  }
}

.maintenance-bar {
  position: absolute;
  z-index: 20;
  top: 78px;
  left: 50%;
  transform: translateX(-50%);
  max-width: min(720px, calc(100% - 40px));
  padding: 9px 16px;
  border-radius: 10px;
  background: rgba(255, 213, 74, 0.94);
  color: #2a2000;
  font-weight: 700;
  font-size: 14px;
  text-align: center;
  box-shadow: var(--shadow);
}
.legal-links {
  display: flex;
  gap: 14px;
  margin: 14px 0 0;
}
.legal-links a {
  color: var(--muted);
  font-size: 13px;
}

/* Controller navigation: a clear focus ring on whatever A will press. */
.pad-nav :focus {
  outline: 3px solid var(--lime);
  outline-offset: 3px;
}

.controls-tabs {
  display: flex;
  gap: 6px;
  margin-top: 12px;
}
.controls-tab {
  flex: 1;
  padding: 8px 6px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(4, 8, 22, 0.4);
  color: var(--muted);
  font: 800 13px/1 var(--display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}
.controls-tab.is-active {
  border-color: var(--lime);
  color: var(--text);
}
.controls-card .controls-list {
  margin-top: 10px;
  gap: 4px;
}
.controls-list .leader-row {
  grid-template-columns: minmax(130px, 42%) 1fr;
  padding: 6px 10px;
}
.controls-list kbd {
  justify-self: start;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-bottom-width: 3px;
  background: rgba(255, 255, 255, 0.06);
  font: 700 13px/1.4 var(--body, inherit);
  white-space: nowrap;
}
.controls-card > .button {
  margin-top: 14px;
}

/* Phones held sideways (the way matches are played): one compact top row,
   the captain in the middle, the PLAY column on the right. */
@media (max-height: 520px) and (orientation: landscape) {
  .topbar {
    top: 8px;
    left: 10px;
    right: 10px;
    flex-wrap: nowrap;
    gap: 8px;
  }
  .brand,
  .currency-pill,
  .profile-tile {
    height: 40px;
  }
  .tabs {
    order: 0;
    width: auto;
    flex: 0 1 auto;
    min-width: 0;
    overflow-x: auto;
  }
  .tab {
    height: 32px;
    padding: 0 10px;
    font-size: 16px;
  }
  .topbar-right {
    margin-left: auto;
  }
  .avatar {
    width: 30px;
    height: 30px;
  }
  .left-rail {
    display: none;
  }
  .right-rail,
  .app-shell[data-tab="locker"] .right-rail {
    top: 58px;
    bottom: 8px;
    left: auto;
    right: 10px;
    width: min(360px, 44vw);
    max-height: none;
    justify-content: flex-end;
  }
  /* Eleven name plates do not fit a phone's height; the list names them. */
  .app-shell[data-tab="locker"] .plates {
    display: none;
  }
  .quick-actions .chip-button {
    height: 40px;
    padding: 0 10px;
    font-size: 15px;
  }
  .quick-actions .chip-button.icon-only {
    width: 40px;
    padding: 0;
  }
  .quick-actions .party-chip {
    min-width: 0;
  }
  .game-toolbar {
    top: 12px;
    left: 12px;
  }
  .game-quit {
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
  }
  .app-shell:not([data-tab="play"]) .left-rail {
    display: flex;
    top: 58px;
    bottom: 8px;
    left: 10px;
    right: auto;
    width: min(300px, 36vw);
    max-height: none;
  }
  .app-shell:not([data-tab="play"]) .right-rail {
    top: 58px;
    bottom: 8px;
    max-height: none;
    justify-content: flex-start;
  }
  .page {
    top: 58px;
    left: 10px;
    right: 10px;
    bottom: 8px;
  }
  .mode-card {
    padding: 8px 12px;
  }
  .mode-card-copy strong {
    font-size: 26px;
  }
  .mode-card-copy small {
    font-size: 12px;
  }
  .ranked-row,
  .slot-bubble {
    display: none;
  }
  .play-button {
    min-height: 0;
    padding: 8px;
  }
  .play-button strong {
    font-size: 40px;
  }
  .play-button small {
    font-size: 11px;
  }
  .bottom-dock {
    display: flex;
    left: 10px;
    bottom: 8px;
    max-width: calc(100% - 360px);
  }
  .invites {
    top: 56px;
  }
  /* After the generic rail rule above: leave room for the bottom bar. */
  .app-shell[data-tab="locker"] .left-rail,
  .app-shell[data-tab="shop"] .left-rail {
    bottom: 60px;
  }
}

/* VS AI match options under the mode card. */
.match-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.match-option {
  display: grid;
  gap: 5px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(8, 12, 30, 0.55);
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
}
.match-option small {
  color: var(--muted);
  font: 800 11px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.seg-mini {
  display: flex;
  gap: 4px;
}
.seg-mini button {
  flex: 1;
  padding: 6px 4px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font: italic 900 15px/1 var(--display);
  text-transform: uppercase;
  cursor: pointer;
}
.seg-mini button.is-active {
  background: var(--lime);
  color: #0e1800;
}

/* Ultimate Football on WEVIUM: the two-line brand, the WEVIUM pill, WEV on the result card. */
.brand-word {
  display: flex;
  flex-direction: column;
  line-height: 0.92;
}
.brand-word small {
  font: 800 9.5px/1 var(--display);
  font-style: normal;
  letter-spacing: 0.42em;
  color: var(--lime);
  margin-top: 3px;
}
.wev-pill {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 52px;
  padding: 0 14px;
  border-radius: 12px;
  background:
    linear-gradient(120deg, rgba(217, 183, 110, 0.2), rgba(217, 183, 110, 0.03)),
    var(--glass-dark);
  border: 1px solid rgba(217, 183, 110, 0.45);
  color: #f6e2a8;
  text-decoration: none;
  font: 700 13px/1 var(--display);
  white-space: nowrap;
}
.wev-pill[hidden] {
  display: none;
}
.wev-pill b {
  font: italic 900 14px/1 var(--display);
  letter-spacing: 0.12em;
}
.wev-pill span {
  color: var(--text);
}
.wev-pill .wev-tier {
  color: #f6e2a8;
  opacity: 0.9;
}
.reward-wevium {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: 12px;
  background: linear-gradient(120deg, rgba(217, 183, 110, 0.2), rgba(0, 0, 0, 0.25));
  border: 1px solid rgba(217, 183, 110, 0.45);
}
.reward-wevium small {
  font: italic 900 12px/1 var(--display);
  letter-spacing: 0.14em;
  color: #f6e2a8;
}
.reward-wevium strong {
  font: italic 900 20px/1 var(--display);
  color: #f6e2a8;
}
.reward-wevium span {
  color: var(--text);
  opacity: 0.85;
}
@media (max-width: 900px) {
  .wev-pill .wev-tier {
    display: none;
  }
}
.wev-pass-card {
  padding: 20px 22px;
  border-radius: 16px;
  border: 1px solid rgba(217, 183, 110, 0.5);
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  margin-bottom: 14px;
  border-color: rgba(217, 183, 110, 0.5);
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(92, 15, 12, 0.55), transparent 60%),
    radial-gradient(90% 120% at 100% 100%, rgba(18, 48, 107, 0.5), transparent 60%),
    var(--glass-dark);
}
.wev-pass-copy {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-width: 640px;
}
.wev-pass-copy .wev-kicker {
  font: italic 900 12px/1 var(--display);
  letter-spacing: 0.16em;
  color: #f6e2a8;
  text-transform: uppercase;
}
.wev-pass-copy strong {
  font: italic 900 26px/1 var(--display);
}
.wev-pass-copy p {
  opacity: 0.85;
  line-height: 1.45;
}
.wev-pass-copy > small:last-child {
  color: #f6e2a8;
  font-weight: 700;
}
a.small-button,
a.button {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
