/* Game lobby — Stake-style catalog in the main stage area */

/* Parent player shell locks overflow; scroll the main column when lobby is tall */
.playground--lobby-active.showcase-shell {
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

.playground--lobby-active .showcase-main {
  overflow-x: hidden;
  overflow-y: auto;
  min-height: 0;
  max-height: 100vh;
  -webkit-overflow-scrolling: touch;
}

.playground--lobby-active .showcase-center--player {
  align-items: stretch;
  justify-content: flex-start;
  padding: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.playground--lobby-active .game-stage-card,
.playground--lobby-active .game-stage-frame,
.playground--lobby-active .game-stage-zoom-wrap {
  overflow: visible;
  flex: 1 1 auto;
  min-height: 0;
}

.playground--lobby-active .game-stage-aspect.game-stage-v2 {
  overflow: visible;
  height: auto;
  flex: 1 1 auto;
  min-height: 0;
}

.playground--slot-active .game-lobby {
  display: none !important;
}

.game-slot-view.hidden {
  display: none !important;
}

.playground--slot-active .game-slot-view {
  display: block;
  width: 100%;
  min-height: 0;
  flex: 1;
}

.game-lobby {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 1.25rem 1.5rem 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.game-lobby-hero {
  position: relative;
  border-radius: 20px;
  padding: 1.5rem 1.75rem;
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(56, 189, 248, 0.14), transparent 55%),
    radial-gradient(90% 120% at 100% 0%, rgba(251, 191, 36, 0.12), transparent 50%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.96), rgba(8, 12, 24, 0.98));
  border: 1px solid rgba(148, 163, 184, 0.14);
  overflow: hidden;
}

.game-lobby-hero-glow {
  position: absolute;
  inset: auto -10% -40% 30%;
  height: 70%;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.16), transparent 68%);
  pointer-events: none;
}

.game-lobby-kicker {
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #94a3b8;
}

.game-lobby-title {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #f8fafc;
}

.game-lobby-lead {
  margin: 0.55rem 0 0;
  max-width: 52ch;
  color: #cbd5e1;
  line-height: 1.55;
}

.game-lobby-tabs {
  display: flex;
  gap: 0.5rem;
  padding: 0.35rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.12);
  width: fit-content;
}

.game-lobby-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 6.25rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  color: #94a3b8;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.78rem;
  transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.game-lobby-tab:hover {
  color: #e2e8f0;
}

.game-lobby-tab.is-active {
  color: #0f172a;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  box-shadow: 0 8px 24px rgba(251, 191, 36, 0.28);
}

.game-lobby-panel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
}

.game-lobby-panel-head h2 {
  margin: 0;
  font-size: 1.25rem;
  color: #f8fafc;
}

.game-lobby-panel-head p {
  margin: 0.25rem 0 0;
  color: #94a3b8;
  flex: 1 1 100%;
}

.game-lobby-arcade-btn {
  flex-shrink: 0;
}

.game-lobby-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

.game-lobby-grid--slots {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.game-lobby-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 0;
  padding: 0;
  text-align: left;
  border-radius: 18px;
  overflow: hidden;
  cursor: pointer;
  background: rgba(15, 23, 42, 0.88);
  border: 1px solid rgba(148, 163, 184, 0.12);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    border-color 0.22s ease;
}

.game-lobby-card:hover:not([disabled]):not(.game-lobby-card--soon) {
  transform: translateY(-4px) scale(1.01);
  border-color: rgba(251, 191, 36, 0.42);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.38), 0 0 0 1px rgba(251, 191, 36, 0.12);
}

.game-lobby-card--soon {
  cursor: not-allowed;
  opacity: 0.72;
}

.game-lobby-card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0b1220;
}

.game-lobby-card-media--emoji {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--lobby-accent, #38bdf8) 28%, transparent), transparent 55%),
    linear-gradient(160deg, rgba(15, 23, 42, 0.95), rgba(8, 12, 24, 0.98));
}

.game-lobby-card-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform 0.35s ease;
}

.game-lobby-card:hover:not([disabled]) .game-lobby-card-poster {
  transform: scale(1.06);
}

.game-lobby-card-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 12, 24, 0.05), rgba(8, 12, 24, 0.82));
}

.game-lobby-card-emoji {
  font-size: clamp(2.8rem, 6vw, 4rem);
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.45));
}

.game-lobby-card-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 2;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #0f172a;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
}

.game-lobby-card-badge--farm {
  color: #ecfeff;
  background: linear-gradient(135deg, #22d3ee, #0891b2);
}

.game-lobby-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.95rem 1rem 1.1rem;
}

.game-lobby-card-tag {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
}

.game-lobby-card-title {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 800;
  color: #f8fafc;
}

.game-lobby-card-sub {
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.45;
  color: #94a3b8;
  min-height: 2.5em;
}

.game-lobby-card-cta {
  margin-top: 0.35rem;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fbbf24;
}

.game-lobby-back-btn {
  margin-right: 0.35rem;
}

.showcase-nav-item.is-active {
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.08);
}

.playground--embed-active .game-lobby,
.playground--embed-active .game-slot-view {
  display: none !important;
}

.playground--embed-active.showcase-shell {
  grid-template-columns: 1fr !important;
}

.playground--embed-active .showcase-sidebar,
.playground--embed-active .companion-oracle,
.playground--embed-active .player-mobile-dock {
  display: none !important;
}

.playground--embed-active .showcase-main {
  grid-column: 1 / -1;
  width: 100%;
  min-width: 0;
}

.playground--embed-active .showcase-center--player {
  align-items: stretch;
  flex: 1;
  min-height: 0;
  padding: 0;
  width: 100%;
  max-width: none;
}

.playground--embed-active .showcase-topbar-right .showcase-balance-chip,
.playground--embed-active .showcase-topbar-right .showcase-daily-btn,
.playground--embed-active .showcase-topbar-right .showcase-companion-hub-btn,
.playground--embed-active .showcase-topbar-right .showcase-profile-btn,
.playground--embed-active .showcase-topbar-right .showcase-beta-user,
.playground--embed-active .showcase-topbar-right .showcase-wallet-btn,
.playground--embed-active .showcase-topbar-right .showcase-account-btn,
.playground--embed-active .showcase-topbar-right .showcase-icon-btn,
.playground--embed-active .showcase-topbar-pill,
.playground--embed-active .showcase-mode-badge {
  display: none !important;
}

.game-embed-view.hidden {
  display: none !important;
}

.playground--embed-active .game-embed-view {
  display: flex;
  flex: 1;
  width: 100%;
  min-height: 0;
  min-width: 0;
  align-self: stretch;
  max-width: none;
  flex-direction: column;
}

.game-embed-toolbar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.5rem 0.5rem;
}

.game-embed-fullscreen-btn {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.playground--embed-active .game-embed-frame {
  flex: 1;
  min-height: calc(100vh - 52px);
  border-radius: 0;
}

.playground--embed-fullscreen .showcase-topbar,
.playground--embed-fullscreen .game-embed-toolbar {
  display: none !important;
}

.playground--embed-fullscreen .game-embed-view {
  min-height: 100vh;
}

.playground--embed-fullscreen .game-embed-frame {
  min-height: 100vh;
  border-radius: 0;
}

.game-embed-frame {
  flex: 1;
  width: 100%;
  min-height: min(72vh, 820px);
  border: 0;
  border-radius: 16px;
  background: #28346a;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35);
}

.game-lobby-card--featured {
  grid-column: span 2;
}

.game-lobby-card-badge--arcade {
  color: #eef2ff;
  background: linear-gradient(135deg, #6366f1, #4338ca);
}

.game-lobby-grid--games .game-lobby-card--featured .game-lobby-card-media {
  aspect-ratio: 21 / 9;
}

@media (max-width: 900px) {
  .game-lobby {
    padding: 0.85rem 0.85rem 2rem;
  }

  .game-lobby-hero {
    padding: 1.1rem 1rem;
  }

  .game-lobby-grid--slots,
  .game-lobby-grid--games {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  }

  .game-lobby-card--featured {
    grid-column: span 1;
  }

  .game-embed-frame {
    min-height: 58vh;
    border-radius: 12px;
  }
}
