/* Neon Poker v0.93.8.7 — fixed game rails, themed statistics/history drawers and refined auth sliders. */

/* Singleplayer Roulette owns a Statistics action in its right-side player rail. */
#rouletteApp .roulette-singleplayer-statistics-tools {
  display: block;
}
#rouletteApp.roulette-multiplayer-active .roulette-singleplayer-statistics-tools {
  display: none !important;
}
#rouletteApp:not(.roulette-multiplayer-active) .roulette-multiplayer-tools {
  display: none !important;
}

/* --------------------------------------------------------------------------
   Desktop game rails are fixed to the viewport by v09387-fixes.js. The
   placeholder keeps the original grid column occupied, so the table never
   grows, shifts or slides under the rail.
   -------------------------------------------------------------------------- */
@media (min-width: 1181px) {
  .v09387-rail-placeholder {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 1px !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
  #gameApp > .side-panel.v09387-viewport-rail,
  #rouletteApp > .roulette-info.v09387-viewport-rail,
  #multiplayerApp .multi-sidebar.v09387-viewport-rail {
    position: fixed !important;
    top: var(--v09387-rail-top) !important;
    left: var(--v09387-rail-left) !important;
    right: auto !important;
    bottom: auto !important;
    width: var(--v09387-rail-width) !important;
    max-width: var(--v09387-rail-width) !important;
    height: auto !important;
    max-height: var(--v09387-rail-max-height) !important;
    margin: 0 !important;
    align-self: auto !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    z-index: 58 !important;
  }
}

/* --------------------------------------------------------------------------
   All game Statistics and History drawers inherit the current site theme.
   No hard-coded dark-green surface remains when another theme is active.
   -------------------------------------------------------------------------- */
#gameStatsOverlay .game-stats-drawer,
#blackjackHistoryOverlay .blackjack-history-drawer,
#pokerHistoryOverlay .poker-history-drawer {
  color: var(--theme-text, var(--text, #f6fff9)) !important;
  background: var(--theme-panel-bg,
    linear-gradient(160deg,
      var(--theme-panel-a, var(--panel-strong, rgba(13,35,29,.98))),
      var(--theme-panel-b, var(--panel, rgba(4,15,12,.98))))) !important;
  border-color: var(--theme-line, var(--line, rgba(255,255,255,.12))) !important;
  border-left-width: 1px !important;
  box-shadow: var(--theme-panel-shadow,
    -18px 0 46px var(--theme-shadow, rgba(0,0,0,.48))) !important;
  backdrop-filter: blur(18px) !important;
  -webkit-backdrop-filter: blur(18px) !important;
}
#gameStatsOverlay .social-head h2,
#gameStatsOverlay .social-head .eyebrow,
#blackjackHistoryOverlay .social-head h2,
#blackjackHistoryOverlay .social-head .eyebrow,
#pokerHistoryOverlay .poker-history-head h2,
#pokerHistoryOverlay .poker-history-head .eyebrow,
#gameStatsOverlay .panel-heading h3,
#gameStatsOverlay .panel-heading span,
#gameStatsOverlay .blackjack-stats-heading-actions span {
  color: var(--theme-text, var(--text, #fff)) !important;
}
#gameStatsOverlay .social-head p,
#blackjackHistoryOverlay .social-head p,
#pokerHistoryOverlay .poker-history-head p,
#gameStatsOverlay .poker-history-empty,
#blackjackHistoryOverlay .poker-history-empty,
#pokerHistoryOverlay .poker-history-empty {
  color: var(--theme-muted, var(--muted, #b8c8c0)) !important;
  opacity: 1 !important;
}
#gameStatsOverlay .roulette-summary-stats > div,
#gameStatsOverlay .blackjack-extended-stats > div,
#gameStatsOverlay .roulette-frequency-cell,
#blackjackHistoryOverlay .blackjack-history-entry,
#blackjackHistoryOverlay .blackjack-history-dealer,
#blackjackHistoryOverlay .blackjack-history-hand,
#pokerHistoryOverlay .poker-history-entry,
#pokerHistoryOverlay .poker-history-player,
#pokerHistoryOverlay .poker-history-board-wrap {
  color: var(--theme-text, var(--text, #fff)) !important;
  background: var(--theme-item-bg,
    linear-gradient(145deg,
      color-mix(in srgb, var(--theme-panel-a, var(--panel-strong)) 82%, var(--theme-accent, var(--gold)) 18%),
      color-mix(in srgb, var(--theme-panel-b, var(--panel)) 94%, #000 6%))) !important;
  border-color: var(--theme-line, var(--line, rgba(255,255,255,.12))) !important;
  box-shadow: inset 0 1px color-mix(in srgb, var(--theme-text, #fff) 7%, transparent),
    0 8px 20px color-mix(in srgb, var(--theme-shadow, #000) 35%, transparent) !important;
}
#gameStatsOverlay .roulette-summary-stats span,
#gameStatsOverlay .blackjack-extended-stats span,
#gameStatsOverlay .roulette-frequency-cell span,
#blackjackHistoryOverlay .blackjack-history-entry footer,
#blackjackHistoryOverlay .blackjack-history-hand small,
#pokerHistoryOverlay .poker-history-player-head small {
  color: var(--theme-muted, var(--muted, #c5d1cb)) !important;
  opacity: 1 !important;
}
#gameStatsOverlay .roulette-summary-stats strong,
#gameStatsOverlay .blackjack-extended-stats strong,
#gameStatsOverlay .roulette-frequency-cell strong,
#blackjackHistoryOverlay .blackjack-history-entry strong,
#blackjackHistoryOverlay .blackjack-history-entry b,
#blackjackHistoryOverlay .blackjack-history-dealer span,
#blackjackHistoryOverlay .blackjack-history-hand span,
#pokerHistoryOverlay .poker-history-entry,
#pokerHistoryOverlay .poker-history-entry header,
#pokerHistoryOverlay .poker-history-entry p,
#pokerHistoryOverlay .poker-history-player,
#pokerHistoryOverlay .poker-history-player-head span,
#pokerHistoryOverlay .poker-history-player > b,
#pokerHistoryOverlay .poker-history-board-wrap > strong {
  color: var(--theme-text, var(--text, #fff)) !important;
}
#blackjackHistoryOverlay .poker-history-meta,
#pokerHistoryOverlay .poker-history-meta {
  color: var(--theme-text, var(--text, #fff)) !important;
  background: linear-gradient(135deg,
    color-mix(in srgb, var(--theme-accent, var(--gold)) 28%, var(--theme-panel-a, var(--panel-strong))),
    color-mix(in srgb, var(--theme-accent-2, var(--mint)) 18%, var(--theme-panel-b, var(--panel)))) !important;
  border-color: var(--theme-line, var(--line)) !important;
}
#blackjackHistoryOverlay .poker-history-meta strong,
#pokerHistoryOverlay .poker-history-meta strong {
  color: var(--theme-button-text, var(--theme-text, var(--text, #fff))) !important;
  background: var(--theme-button-bg,
    color-mix(in srgb, var(--theme-accent, var(--gold)) 24%, var(--theme-panel-b, var(--panel)))) !important;
  border-color: color-mix(in srgb, var(--theme-accent, var(--gold)) 56%, var(--theme-line, var(--line))) !important;
}
#gameStatsOverlay .roulette-frequency-cell.hottest {
  box-shadow: inset 0 0 0 1px var(--theme-accent, var(--gold)),
    0 0 18px color-mix(in srgb, var(--theme-accent, var(--gold)) 30%, transparent) !important;
}
#gameStatsOverlay #resetStats,
#gameStatsOverlay .drawer-close,
#blackjackHistoryOverlay .drawer-close,
#pokerHistoryOverlay .drawer-close {
  color: var(--theme-text, var(--text, #fff)) !important;
}

/* Keep the page fully visible behind every game drawer. */
#gameStatsOverlay,
#blackjackHistoryOverlay,
#pokerHistoryOverlay,
#gameStatsOverlay .social-backdrop,
#blackjackHistoryOverlay .social-backdrop,
#pokerHistoryOverlay .poker-history-backdrop {
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  filter: none !important;
}

/* --------------------------------------------------------------------------
   Authentication mode control: only the slider moves. The Username half is
   deliberately narrower on both Login and Register controls.
   -------------------------------------------------------------------------- */
.developer-auth-mode-tabs {
  grid-template-columns: minmax(0, 1.18fr) minmax(0, .82fr) !important;
}
.developer-auth-mode-tabs::before {
  left: 5px !important;
  width: calc(59% - 8px) !important;
  transform: none !important;
  transition: left .28s cubic-bezier(.2,.8,.2,1), width .28s cubic-bezier(.2,.8,.2,1), background .2s ease !important;
}
.developer-auth-mode-tabs.selects-name::before,
.developer-auth-mode-tabs:has([data-auth-mode-value="name"].active)::before {
  left: calc(59% + 3px) !important;
  width: calc(41% - 8px) !important;
  transform: none !important;
}
.developer-auth-mode-tabs button,
.developer-auth-mode-tabs button:hover,
.developer-auth-mode-tabs button:focus,
.developer-auth-mode-tabs button:focus-visible,
.developer-auth-mode-tabs button:active,
.developer-auth-mode-tabs button.active,
.developer-auth-mode-tabs button[aria-selected="true"] {
  animation: none !important;
  transition: none !important;
  transform: none !important;
  filter: none !important;
  box-shadow: none !important;
  background: transparent !important;
}

@media (max-width: 1180px) {
  #gameApp > .side-panel,
  #rouletteApp > .roulette-info,
  #multiplayerApp .multi-sidebar {
    position: relative !important;
    inset: auto !important;
    width: auto !important;
    max-width: none !important;
    max-height: none !important;
    overflow: visible !important;
  }
  .v09387-rail-placeholder {
    display: none !important;
  }
}

/* The multiplayer entrance animation kept a transform matrix on the app and
   turned fixed descendants into container-fixed elements. Removing that
   completed transform is what makes the multiplayer player rail truly
   viewport-fixed. */
@media (min-width: 1181px) {
  body.multiplayer-live #multiplayerApp {
    animation: none !important;
    transform: none !important;
  }
}
