/* Wallet/Deposit overlay presentation only. No financial or route logic. */
:root {
  --winbet-wallet-overlay-z: 6200;
  --winbet-wallet-panel: #0d2934;
  --winbet-wallet-panel-strong: #102f3b;
  --winbet-wallet-line: rgba(116, 178, 201, 0.22);
  --winbet-wallet-scroll-track: rgba(3, 18, 25, 0.52);
  --winbet-wallet-scroll-thumb: rgba(93, 151, 174, 0.62);
  --winbet-wallet-scroll-hover: rgba(118, 184, 208, 0.78);
}

.wallet-surface:has(.quick-wallet-dialog),
.wallet-surface:has([role="dialog"][data-wallet-overlay-polished="true"]) {
  position: fixed !important;
  inset: 0 !important;
  z-index: var(--winbet-wallet-overlay-z) !important;
  isolation: isolate !important;
  display: grid !important;
  place-items: center !important;
  padding: clamp(12px, 2.5vh, 24px) !important;
  overflow: hidden !important;
  background: rgba(2, 13, 19, 0.68) !important;
  backdrop-filter: blur(2px) saturate(0.92) !important;
  -webkit-backdrop-filter: blur(2px) saturate(0.92) !important;
  pointer-events: auto !important;
}

.wallet-surface .quick-wallet-dialog,
.wallet-surface [role="dialog"][data-wallet-overlay-polished="true"] {
  position: relative !important;
  z-index: 1 !important;
  isolation: isolate !important;
  width: min(460px, calc(100vw - 32px)) !important;
  max-height: min(878px, calc(100dvh - 24px)) !important;
  overflow: hidden !important;
  color: #eef8fb !important;
  background: linear-gradient(180deg, rgba(17, 50, 62, 0.99), rgba(8, 33, 43, 0.995)) !important;
  border: 1px solid rgba(111, 178, 203, 0.3) !important;
  border-radius: 14px !important;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.48), 0 0 0 1px rgba(17, 69, 87, 0.26) !important;
  opacity: 1 !important;
  filter: none !important;
  pointer-events: auto !important;
}

.wallet-surface .quick-wallet-dialog .deposit-dialog__head,
.wallet-surface .quick-wallet-dialog .quick-wallet-tabs {
  background: rgba(12, 42, 53, 0.9) !important;
  border-color: var(--winbet-wallet-line) !important;
}

.wallet-surface .quick-wallet-dialog .sandbox-wallet__panel {
  min-height: 0 !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain !important;
  scrollbar-gutter: stable !important;
  scrollbar-width: thin !important;
  scrollbar-color: var(--winbet-wallet-scroll-thumb) var(--winbet-wallet-scroll-track) !important;
  background: rgba(6, 29, 38, 0.62) !important;
  border-color: rgba(92, 153, 176, 0.16) !important;
}

.wallet-surface .quick-wallet-dialog .sandbox-wallet__panel::-webkit-scrollbar {
  width: 4px !important;
  height: 4px !important;
}

.wallet-surface .quick-wallet-dialog .sandbox-wallet__panel::-webkit-scrollbar-track {
  background: var(--winbet-wallet-scroll-track) !important;
  border-radius: 999px !important;
}

.wallet-surface .quick-wallet-dialog .sandbox-wallet__panel::-webkit-scrollbar-thumb {
  min-height: 32px !important;
  background: var(--winbet-wallet-scroll-thumb) !important;
  border: 0 !important;
  border-radius: 999px !important;
}

.wallet-surface .quick-wallet-dialog .sandbox-wallet__panel::-webkit-scrollbar-thumb:hover {
  background: var(--winbet-wallet-scroll-hover) !important;
}

.wallet-surface .quick-wallet-dialog button,
.wallet-surface .quick-wallet-dialog input,
.wallet-surface .quick-wallet-dialog select,
.wallet-surface .quick-wallet-dialog textarea {
  border-radius: 10px !important;
}

.wallet-surface .quick-wallet-dialog :where(button, input, select, textarea, [tabindex]):focus-visible {
  outline: 2px solid #59bff0 !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 0 4px rgba(54, 156, 205, 0.22) !important;
}

@media (max-width: 720px) {
  .wallet-surface:has(.quick-wallet-dialog),
  .wallet-surface:has([role="dialog"][data-wallet-overlay-polished="true"]) {
    place-items: center !important;
    padding: 8px 6px calc(8px + env(safe-area-inset-bottom)) !important;
  }

  .wallet-surface .quick-wallet-dialog,
  .wallet-surface [role="dialog"][data-wallet-overlay-polished="true"] {
    width: min(100%, 430px) !important;
    max-height: calc(100dvh - 16px - env(safe-area-inset-bottom)) !important;
    border-radius: 12px !important;
  }

  .wallet-surface .quick-wallet-dialog .sandbox-wallet__panel::-webkit-scrollbar {
    width: 3px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wallet-surface .quick-wallet-dialog,
  .wallet-surface .quick-wallet-dialog * {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
