.lobby-screen,
.meta-screen {
  position: relative;
  width: 100%;
  overflow-x: hidden;
  background: #060a12;
}

.lobby-screen.active {
  display: block;
  padding: max(12px, var(--safe-t)) 16px max(14px, var(--safe-b));
}

.lobby-backdrop {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(circle at 68% 38%, rgba(17, 94, 70, 0.36), transparent 29%),
    radial-gradient(circle at 18% 78%, rgba(105, 25, 42, 0.22), transparent 30%),
    linear-gradient(130deg, #060912 0%, #111a2a 48%, #080b13 100%);
}

.lobby-backdrop::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.18;
  background-image:
    linear-gradient(rgba(229, 195, 122, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(229, 195, 122, 0.06) 1px, transparent 1px);
  background-size: 72px 72px;
  transform: perspective(550px) rotateX(58deg) scale(1.7) translateY(27%);
  transform-origin: bottom;
}

.ambient {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #f4d99b;
  box-shadow:
    90px 40px 0 rgba(244, 217, 155, 0.3),
    210px 170px 0 rgba(244, 217, 155, 0.18),
    -150px 120px 0 rgba(244, 217, 155, 0.22),
    300px -60px 0 rgba(244, 217, 155, 0.2);
  animation: lobby-drift 7s ease-in-out infinite alternate;
}
.ambient-one { left: 18%; top: 23%; }
.ambient-two { right: 18%; bottom: 20%; animation-delay: -3s; }

.float-card {
  position: absolute;
  width: clamp(58px, 7vw, 94px);
  opacity: 0.13;
  filter: blur(0.3px) drop-shadow(0 18px 18px #000);
}
.float-card-one { left: 5%; top: 36%; transform: rotate(-16deg); }
.float-card-two { right: 5%; top: 23%; transform: rotate(15deg); }

.lobby-shell {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
  min-height: calc(100dvh - max(26px, var(--safe-t)));
  margin: 0 auto;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 12px;
}

.lobby-topbar {
  min-height: 70px;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto 48px;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border: 1px solid rgba(229, 195, 122, 0.2);
  border-radius: 20px;
  background: rgba(7, 12, 22, 0.72);
  box-shadow: 0 15px 34px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(16px);
}

.player-summary {
  display: grid;
  grid-template-columns: 50px minmax(0, 160px);
  grid-template-rows: auto 5px;
  align-items: center;
  gap: 4px 10px;
  width: max-content;
  max-width: 100%;
  padding: 0;
  border: 0;
  color: var(--ink);
  text-align: left;
  background: none;
}

.top-avatar {
  grid-row: 1 / 3;
  width: 50px;
  aspect-ratio: 1;
  border: 2px solid #d8b76c;
  border-radius: 50%;
  overflow: hidden;
  background: #172033;
  box-shadow: 0 0 18px rgba(216, 183, 108, 0.2);
}
.top-avatar img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.player-copy { min-width: 0; }
.player-copy strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-copy small { color: #9aa5b8; font-size: 10px; letter-spacing: 0.14em; }
.player-copy b { color: #e4c37a; }
.level-track {
  width: 100%;
  height: 4px;
  border-radius: 99px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
}
.level-track i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #d9b66a;
  transition: width 0.35s ease;
}

.lobby-currency,
.meta-balance {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 126px;
  padding: 7px 13px 7px 7px;
  border: 1px solid rgba(229, 195, 122, 0.25);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}
.lobby-currency img,
.meta-balance img { width: 35px; height: 35px; object-fit: contain; }
.lobby-currency span { display: grid; }
.lobby-currency small { color: #8f9aad; font-size: 9px; letter-spacing: 0.13em; }
.lobby-currency strong,
.meta-balance b { color: #f1d697; }

.lobby-icon-button,
.back-circle {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 8px;
  border: 1px solid rgba(229, 195, 122, 0.25);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  color: var(--gold2);
}
.lobby-icon-button img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.lobby-hero {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(310px, 1.15fr) minmax(280px, 0.9fr);
  align-items: center;
  gap: clamp(12px, 3vw, 42px);
  padding: 8px clamp(8px, 3vw, 34px);
}

.lobby-brand { align-self: center; text-align: center; }
.lobby-logo {
  width: min(230px, 90%);
  margin: 0 auto;
  filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.48));
}
.lobby-brand p {
  margin: -8px 0 0;
  color: #c7cedb;
  font-family: Cinzel, serif;
  font-size: clamp(10px, 1.1vw, 13px);
  letter-spacing: 0.18em;
}

.hero-character-wrap {
  position: relative;
  align-self: stretch;
  min-height: 390px;
  display: grid;
  place-items: end center;
}
.hero-character {
  position: relative;
  z-index: 2;
  width: 100%;
  height: min(57dvh, 620px);
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 26px 24px rgba(0, 0, 0, 0.48));
  animation: hero-idle 4.5s ease-in-out infinite;
}
.hero-halo {
  position: absolute;
  z-index: 0;
  left: 50%;
  bottom: 8%;
  width: 83%;
  aspect-ratio: 1;
  transform: translateX(-50%);
  border: 1px solid rgba(229, 195, 122, 0.26);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(23, 113, 82, 0.34), transparent 68%);
  box-shadow: inset 0 0 40px rgba(229, 195, 122, 0.08);
}
.hero-chips {
  position: absolute;
  z-index: 3;
  right: 1%;
  bottom: 4%;
  width: 98px;
  filter: drop-shadow(0 14px 12px rgba(0, 0, 0, 0.5));
  animation: chip-float 3.4s ease-in-out infinite;
}

.hero-actions { display: grid; gap: 13px; }
.play-now,
.tournament-feature {
  width: 100%;
  border: 1px solid rgba(229, 195, 122, 0.48);
  border-radius: 18px;
  color: #171006;
  text-align: left;
}
.play-now {
  min-height: 88px;
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 13px 18px;
  background: #d7b465;
  box-shadow: 0 14px 30px rgba(199, 153, 61, 0.22), inset 0 1px rgba(255,255,255,.45);
}
.play-now small,
.tournament-feature small { display: block; font-size: 9px; letter-spacing: 0.16em; opacity: 0.72; }
.play-now strong { display: block; font-family: Cinzel, serif; font-size: clamp(20px, 2vw, 28px); letter-spacing: 0.06em; }
.play-now > b { font-size: 32px; font-weight: 400; }
.play-crown {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.tournament-feature {
  min-height: 106px;
  display: grid;
  grid-template-columns: 52px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: rgba(18, 24, 39, 0.9);
  color: var(--ink);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.24);
}
.tournament-seal {
  width: 52px;
  height: 52px;
  object-fit: contain;
}
.tournament-feature-copy { min-width: 0; }
.tournament-feature-copy strong {
  display: block;
  max-width: 100%;
  overflow-wrap: anywhere;
  font-family: Cinzel, serif;
  font-size: 15px;
}
.tournament-feature-copy em { color: #9da8ba; font-size: 11px; font-style: normal; }
.feature-status { color: #e4c37a; font-size: 11px; letter-spacing: 0.12em; }

.lobby-dock {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(229, 195, 122, 0.18);
  border-radius: 20px;
  background: rgba(7, 12, 22, 0.8);
  backdrop-filter: blur(14px);
}
.dock-button {
  min-height: 72px;
  display: grid;
  grid-template-columns: 38px auto;
  grid-template-rows: auto auto;
  align-content: center;
  justify-content: center;
  gap: 0 8px;
  border: 0;
  border-radius: 14px;
  color: #e9edf4;
  background: transparent;
}
.dock-button:hover,
.dock-button:focus-visible { background: rgba(229, 195, 122, 0.08); }
.dock-icon,
.dock-glyph {
  grid-row: 1 / 3;
  align-self: center;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  overflow: hidden;
  border: 1px solid rgba(229, 195, 122, 0.35);
  border-radius: 11px;
  color: #e5c57d;
  background: rgba(255,255,255,.04);
}
.dock-icon img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.dock-icon.premium-icon img { object-fit: contain; object-position: center; }
.dock-icon.reward-icon img { object-fit: contain; }
.dock-button strong { align-self: end; font-size: 12px; text-align: left; }
.dock-button small { color: #d4b56d; font-size: 9px; text-align: left; }

.play-now,
.tournament-feature,
.dock-button,
.player-summary,
.avatar-select,
.tournament-enter {
  touch-action: manipulation;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.play-now:hover,
.tournament-feature:hover,
.dock-button:hover,
.player-summary:hover,
.avatar-select:hover,
.tournament-enter:hover { transform: translateY(-2px); }
.play-now:active,
.tournament-feature:active,
.dock-button:active,
.player-summary:active,
.avatar-select:active,
.tournament-enter:active { transform: translateY(1px) scale(0.99); }

.meta-screen.active {
  display: block;
  padding: max(16px, var(--safe-t)) 16px max(20px, var(--safe-b));
  background:
    radial-gradient(circle at 50% 0%, rgba(28, 91, 72, 0.23), transparent 37%),
    #080c15;
}
.meta-shell {
  width: min(1120px, 100%);
  margin: 0 auto;
}
.meta-header {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}
.meta-header small { color: #aab2c2; letter-spacing: 0.16em; }
.meta-header h2 { margin: 2px 0 0; }
.back-circle { font-size: 32px; line-height: 1; padding-bottom: 11px; }
.meta-intro { color: #aab2c2; margin: -8px 0 20px 62px; }
.tournament-meta-player {
  display: flex;
  align-items: center;
  gap: 8px;
}
.tournament-meta-player > img {
  width: 44px;
  height: 44px;
  object-fit: cover;
  object-position: top;
  border: 1px solid #d8b76c;
  border-radius: 50%;
  background: #172033;
}

.profile-name-row {
  display: grid;
  grid-template-columns: auto minmax(180px, 320px) 84px;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  padding: 13px 16px;
  border: 1px solid rgba(229, 195, 122, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
}
.profile-name-row label { color: #aab2c2; }
.profile-name-row input {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid rgba(229, 195, 122, 0.28);
  border-radius: 10px;
  color: var(--ink);
  background: #0f1624;
}
.profile-name-row button {
  padding: 10px;
  border: 0;
  border-radius: 10px;
  color: #1e1608;
  font-weight: 700;
  background: #d8b76c;
}

.avatar-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.avatar-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(229, 195, 122, 0.18);
  border-radius: 20px;
  background: #101725;
  box-shadow: 0 14px 28px rgba(0,0,0,.26);
}
.avatar-card.selected {
  border-color: #e0bf73;
  box-shadow: 0 0 0 2px rgba(224, 191, 115, 0.14), 0 17px 35px rgba(0,0,0,.34);
}
.avatar-card.locked { filter: saturate(0.45); }
.avatar-art {
  height: 240px;
  display: grid;
  place-items: end center;
  background: radial-gradient(circle at 50% 55%, rgba(40, 115, 89, 0.38), transparent 62%);
}
.avatar-art img { width: 100%; height: 100%; object-fit: contain; object-position: center bottom; }
.avatar-info { padding: 13px; }
.avatar-info h3 { margin: 0; font-size: 14px; }
.avatar-info p { margin: 4px 0 11px; color: #96a0b2; font-size: 11px; }
.avatar-state {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.avatar-state small { color: #d7bb7d; }
.avatar-select {
  min-height: 34px;
  padding: 7px 12px;
  border: 1px solid #cfad61;
  border-radius: 9px;
  color: #181108;
  font-weight: 700;
  background: #d8b76c;
}
.avatar-select:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }

.tournament-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.tournament-card {
  position: relative;
  min-height: 420px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 20px;
  border: 1px solid rgba(229, 195, 122, 0.25);
  border-radius: 24px;
  background: #101824;
  box-shadow: 0 18px 42px rgba(0,0,0,.35);
}
.tournament-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 75% 16%, rgba(229, 195, 122, 0.13), transparent 34%),
    linear-gradient(160deg, transparent 50%, rgba(0,0,0,.28));
}
.tournament-card.green { background-color: #0d2823; }
.tournament-card.burgundy { background-color: #321521; }
.tournament-card.black { background-color: #11141b; }
.tournament-card.selected { border-color: #e1c176; box-shadow: 0 0 0 2px rgba(225,193,118,.12), 0 22px 48px #0008; }
.tournament-card.locked { filter: saturate(0.45); }
.tournament-card > * { position: relative; z-index: 1; }
.tournament-art {
  height: 105px;
  display: grid;
  place-items: center;
}
.tournament-art img { width: 105px; height: 105px; object-fit: contain; }
.tournament-card h3 { margin: 8px 0 4px; font-size: clamp(18px, 2vw, 23px); }
.tournament-card .tournament-kicker { min-height: 36px; margin: 0 0 14px; color: #abb4c4; font-size: 12px; }
.tournament-facts { display: grid; gap: 8px; margin-bottom: 18px; }
.tournament-facts div { display: flex; justify-content: space-between; gap: 8px; color: #9da7b8; }
.tournament-facts strong { color: #f0d594; }
.tournament-enter {
  width: 100%;
  min-height: 46px;
  margin-top: auto;
  border: 0;
  border-radius: 12px;
  color: #181108;
  font-weight: 800;
  background: #d8b76c;
}
.tournament-enter:disabled { opacity: .42; cursor: not-allowed; transform: none; }
.lock-copy { display: block; margin-top: 8px; color: #c7a65f; font-size: 10px; text-align: center; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.stat-card {
  min-height: 130px;
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 20px;
  border: 1px solid rgba(229,195,122,.18);
  border-radius: 18px;
  background: rgba(255,255,255,.035);
}
.stat-card span { color: #9fa9ba; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.stat-card strong { color: #eed18e; font-family: Cinzel, serif; font-size: 25px; overflow-wrap: anywhere; }

.reward-card > img { width: 122px; margin: -12px auto 4px; }
.reward-card > small,
.tournament-result-card > small { color: #d7b66d; letter-spacing: .17em; }
.reward-value,
#tournamentResultPrize { display: block; margin: 12px 0; color: #efcf83; font-family: Cinzel, serif; font-size: 22px; }
.tournament-result-card > img {
  width: 180px;
  height: 200px;
  margin: -12px auto 8px;
  object-fit: contain;
  object-position: center bottom;
}

.tournament-status {
  display: flex;
  align-items: center;
  gap: 8px;
}
.tournament-status strong { color: #efcf83; }
.result-avatar {
  width: 94px;
  height: 108px;
  margin: -4px auto 8px;
  object-fit: contain;
  object-position: center bottom;
  border-bottom: 1px solid rgba(229, 195, 122, 0.28);
}
.tournament-hand-summary {
  display: grid;
  gap: 4px;
  margin: 12px 0;
  padding: 10px;
  border: 1px solid rgba(229,195,122,.2);
  border-radius: 12px;
  color: #aab3c2;
  background: rgba(255,255,255,.035);
}
.tournament-hand-summary strong { color: #edd08b; }
.tournament-hand-summary em { color: #d28b93; font-size: 11px; font-style: normal; }

.felt-wrap.players-4 .seat-0 { bottom: 1%; left: 50%; }
.felt-wrap.players-4 .seat-1 { left: 1%; top: 45%; bottom: auto; }
.felt-wrap.players-4 .seat-2 { top: 0; left: 50%; transform: translateX(-50%); }
.felt-wrap.players-4 .seat-3 { right: 1%; top: 45%; left: auto; transform: none; }

.felt-wrap.players-8 .seat-0 { bottom: 1%; left: 50%; }
.felt-wrap.players-8 .seat-1 { bottom: 12%; left: 2%; }
.felt-wrap.players-8 .seat-2 { top: 35%; left: 0; bottom: auto; }
.felt-wrap.players-8 .seat-3 { top: 3%; left: 13%; }
.felt-wrap.players-8 .seat-4 { top: 0; left: 50%; right: auto; transform: translateX(-50%); }
.felt-wrap.players-8 .seat-5 { top: 3%; right: 13%; bottom: auto; }
.felt-wrap.players-8 .seat-6 { top: 35%; right: 0; }
.felt-wrap.players-8 .seat-7 { bottom: 12%; right: 2%; }

@keyframes lobby-drift {
  to { transform: translate(22px, -18px); opacity: .55; }
}
@keyframes hero-idle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}
@keyframes chip-float {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50% { transform: translateY(-8px) rotate(2deg); }
}

@media (max-width: 900px) {
  .lobby-hero {
    grid-template-columns: minmax(190px, .8fr) minmax(260px, 1fr);
    grid-template-areas:
      "brand character"
      "actions character";
    gap: 6px 18px;
  }
  .lobby-brand { grid-area: brand; align-self: end; }
  .hero-character-wrap { grid-area: character; min-height: 490px; }
  .hero-actions { grid-area: actions; align-self: start; }
  .tournament-feature { min-height: 92px; }
  .avatar-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tournament-cards { grid-template-columns: repeat(3, minmax(250px, 1fr)); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; }
  .tournament-card { scroll-snap-align: center; }
}

@media (min-width: 621px) and (max-height: 700px) {
  .lobby-screen.active { padding-top: 7px; padding-bottom: 7px; }
  .lobby-shell { min-height: calc(100svh - 14px); gap: 6px; }
  .lobby-topbar { min-height: 54px; padding-top: 4px; padding-bottom: 4px; }
  .top-avatar { width: 42px; }
  .player-summary { grid-template-columns: 42px minmax(0, 150px); }
  .lobby-hero { padding-top: 0; padding-bottom: 0; }
  .lobby-logo { width: min(160px, 82%); }
  .hero-character-wrap { min-height: 280px; }
  .hero-character { height: min(47svh, 360px); }
  .hero-chips { width: 72px; }
  .play-now { min-height: 66px; padding-top: 8px; padding-bottom: 8px; }
  .play-now strong { font-size: 20px; }
  .tournament-feature { min-height: 78px; padding-top: 8px; padding-bottom: 8px; }
  .lobby-dock { padding: 5px; }
  .dock-button { min-height: 58px; }
}

@media (max-width: 620px) {
  .lobby-screen.active { padding: max(8px, var(--safe-t)) 8px max(8px, var(--safe-b)); }
  .lobby-shell { min-height: calc(100svh - 16px); gap: 7px; }
  .lobby-topbar {
    min-height: 58px;
    grid-template-columns: minmax(0, 1fr) auto 40px;
    gap: 7px;
    padding: 6px;
    border-radius: 15px;
  }
  .player-summary { grid-template-columns: 40px minmax(0, 92px); gap: 2px 7px; }
  .top-avatar { width: 40px; }
  .player-copy strong { font-size: 12px; }
  .lobby-currency { min-width: 0; padding: 5px 8px 5px 4px; }
  .lobby-currency img { width: 28px; height: 28px; }
  .lobby-currency small { display: none; }
  .lobby-currency strong { font-size: 12px; }
  .lobby-icon-button { width: 40px; height: 40px; padding: 7px; }

  .lobby-hero {
    min-height: 0;
    grid-template-columns: .8fr 1.2fr;
    grid-template-rows: auto minmax(230px, 1fr) auto;
    grid-template-areas:
      "brand brand"
      "actions character"
      "actions character";
    gap: 3px 8px;
    padding: 0 3px;
  }
  .lobby-logo { width: 106px; }
  .lobby-brand p { display: none; }
  .hero-character-wrap { min-height: 250px; height: 100%; }
  .hero-character { height: min(40svh, 390px); }
  .hero-chips { width: 62px; right: -5%; }
  .hero-halo { width: 115%; }
  .hero-actions { gap: 8px; }
  .play-now {
    min-height: 68px;
    grid-template-columns: 29px 1fr;
    gap: 7px;
    padding: 10px;
    border-radius: 14px;
  }
  .play-now > b { display: none; }
  .play-crown { width: 30px; height: 30px; }
  .play-now strong { font-size: 17px; }
  .play-now small { font-size: 7px; }
  .tournament-feature {
    min-height: 88px;
    grid-template-columns: 34px 1fr;
    gap: 7px;
    padding: 9px;
    border-radius: 14px;
  }
  .tournament-seal { width: 34px; height: 34px; }
  .tournament-feature-copy strong {
    font-size: 9px;
    line-height: 1.2;
    letter-spacing: 0.01em;
  }
  .tournament-feature-copy em { display: block; line-height: 1.25; font-size: 9px; }
  .feature-status { display: none; }

  .lobby-dock {
    gap: 3px;
    padding: 5px;
    border-radius: 15px;
  }
  .dock-button {
    min-height: 62px;
    grid-template-columns: 1fr;
    grid-template-rows: 30px auto auto;
    justify-items: center;
    gap: 2px;
    padding: 4px 2px;
  }
  .dock-icon,
  .dock-glyph { grid-row: auto; width: 30px; height: 30px; }
  .dock-button strong { font-size: 9px; text-align: center; white-space: nowrap; }
  .dock-button small { font-size: 7px; text-align: center; }
  .float-card { display: none; }

  .meta-screen.active { padding: max(10px, var(--safe-t)) 10px max(14px, var(--safe-b)); }
  .meta-header { grid-template-columns: 42px minmax(0, 1fr) auto; gap: 8px; margin-bottom: 12px; }
  .meta-header h2 { font-size: 19px; }
  .meta-balance { min-width: 0; padding: 4px 7px 4px 3px; font-size: 11px; }
  .meta-balance img { width: 27px; height: 27px; }
  .tournament-meta-player { gap: 4px; }
  .tournament-meta-player > img { width: 35px; height: 35px; }
  .back-circle { width: 40px; height: 40px; }
  .meta-intro { margin: 0 0 14px; font-size: 12px; }
  .profile-name-row { grid-template-columns: 1fr auto; padding: 10px; }
  .profile-name-row label { grid-column: 1 / -1; font-size: 11px; }
  .avatar-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .avatar-art { height: 185px; }
  .avatar-info { padding: 10px; }
  .avatar-state { align-items: flex-end; }
  .avatar-select { padding: 6px 8px; font-size: 11px; }
  .tournament-cards { margin-right: -10px; padding-right: 10px; }
  .tournament-card { min-height: 390px; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .stat-card { min-height: 105px; padding: 14px; }
  .stat-card strong { font-size: 20px; }
  .felt-wrap.players-4 .seat-1 { top: 38%; }
  .felt-wrap.players-4 .seat-3 { top: 38%; }
  .felt-wrap.players-8 .seat { width: min(40vw, 142px); }
  .felt-wrap.players-8 .seat-1 { bottom: 18%; left: 0; }
  .felt-wrap.players-8 .seat-2 { top: 38%; left: 0; }
  .felt-wrap.players-8 .seat-3 { top: 10%; left: 1%; }
  .felt-wrap.players-8 .seat-5 { top: 10%; right: 1%; }
  .felt-wrap.players-8 .seat-6 { top: 38%; right: 0; }
  .felt-wrap.players-8 .seat-7 { bottom: 18%; right: 0; }
}

@media (max-width: 370px) {
  .lobby-hero { grid-template-columns: .88fr 1.12fr; }
  .hero-character { height: min(38svh, 330px); }
  .avatar-art { height: 165px; }
  .lobby-currency img { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .ambient,
  .hero-character,
  .hero-chips { animation: none; }
}

