/* ─────────────────────────────────────────
   Uber-Inspired Design System
   All tokens and component overrides
───────────────────────────────────────── */

/* ── Tokens ── */
:root {
    /* Core palette */
    --uber-black:       #000000;
    --uber-white:       #ffffff;
    --uber-body-gray:   #4b4b4b;
    --uber-muted-gray:  #afafaf;
    --uber-chip-gray:   #efefef;
    --uber-hover-gray:  #e2e2e2;
    --uber-hover-light: #f3f3f3;

    /* Shadows */
    --shadow-subtle:  rgba(0,0,0,.12) 0px 4px 16px 0px;
    --shadow-medium:  rgba(0,0,0,.16) 0px 4px 16px 0px;
    --shadow-float:   rgba(0,0,0,.16) 0px 2px 8px 0px;
    --shadow-pressed: inset rgba(0,0,0,.08) 0px 0px 0px 999px;

    /* Typography */
    --font-headline: 'Inter', system-ui, 'Helvetica Neue', Arial, sans-serif;
    --font-body:     'Inter', system-ui, 'Helvetica Neue', Arial, sans-serif;

    /* Border radius */
    --radius-card:     8px;
    --radius-featured: 12px;
    --radius-pill:     999px;
    --radius-circle:   50%;
    --radius-input:    8px;

    /* Spacing (8px base) */
    --space-1:  4px;
    --space-2:  8px;
    --space-3:  12px;
    --space-4:  16px;
    --space-5:  20px;
    --space-6:  24px;
    --space-8:  32px;
    --space-10: 40px;
    --space-12: 48px;

    /* Bootstrap overrides */
    --bs-body-font-family:   var(--font-body);
    --bs-body-color:         var(--uber-black);
    --bs-body-bg:            var(--uber-white);
    --bs-primary:            var(--uber-black);
    --bs-primary-rgb:        0, 0, 0;
    --bs-link-color:         var(--uber-black);
    --bs-link-hover-color:   var(--uber-black);
    --bs-border-radius:      var(--radius-card);
    --bs-card-border-radius: var(--radius-card);
    --bs-card-border-width:  0;
    --bs-card-box-shadow:    var(--shadow-subtle);
}

/* ── Base ── */
body {
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.5;
    color: var(--uber-black);
    background-color: var(--uber-white);
}

/* ── Typography ── */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: var(--font-headline);
    font-weight: 700;
    line-height: 1.25;
    color: var(--uber-black);
}

/* ── Links ── */
a {
    color: var(--uber-black);
    text-decoration: underline;
}
a:hover {
    color: var(--uber-black);
    text-decoration: none;
}

/* ── Primary Button (Black Pill CTA) ── */
.btn-primary {
    background-color: var(--uber-black);
    border-color: var(--uber-black);
    color: var(--uber-white);
    border-radius: var(--radius-pill);
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 16px;
    padding: 10px 12px;
    min-height: 44px;
    transition: background-color .15s ease, box-shadow .15s ease;
}
.btn-primary:hover,
.btn-primary:focus {
    background-color: #1a1a1a;
    border-color: #1a1a1a;
    color: var(--uber-white);
}
.btn-primary:focus-visible {
    box-shadow: rgb(255,255,255) 0px 0px 0px 2px inset;
    outline: none;
}
.btn-primary:active {
    box-shadow: var(--shadow-pressed);
}
.btn-lg {
    font-size: 16px;
    padding: 14px 16px;
    min-height: 52px;
}

/* ── Secondary Button (White Pill) ── */
.btn-secondary {
    background-color: var(--uber-white);
    border-color: var(--uber-white);
    color: var(--uber-black);
    border-radius: var(--radius-pill);
    font-weight: 500;
    padding: 10px 12px;
    min-height: 44px;
}
.btn-secondary:hover,
.btn-secondary:focus {
    background-color: var(--uber-hover-gray);
    border-color: var(--uber-hover-gray);
    color: var(--uber-black);
}

/* ── Chip / Filter Button ── */
.btn-chip {
    background-color: var(--uber-chip-gray);
    border: none;
    color: var(--uber-black);
    border-radius: var(--radius-pill);
    font-weight: 500;
    padding: 14px 16px;
    min-height: 44px;
}
.btn-chip.active,
.btn-chip:active {
    background-color: var(--uber-black);
    color: var(--uber-white);
    box-shadow: var(--shadow-pressed);
}

/* ── Inputs ── */
.form-control,
.form-select {
    background-color: var(--uber-white);
    border: 1px solid var(--uber-black);
    border-radius: var(--radius-input);
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    color: var(--uber-black);
    padding: 12px 14px;
    height: auto;
    min-height: 48px;
    transition: box-shadow .15s ease;
}
.form-control::placeholder {
    color: var(--uber-muted-gray);
}
.form-control:focus,
.form-select:focus {
    border-color: var(--uber-black);
    background-color: var(--uber-white);
    box-shadow: rgb(255,255,255) 0px 0px 0px 2px inset,
                var(--uber-black) 0px 0px 0px 3px;
    outline: none;
}
.form-control.is-invalid {
    border-color: #b00020;
    background-color: var(--uber-white);
    background-image: none;
}

/* ── Labels ── */
.form-label {
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 500;
    color: var(--uber-black);
    margin-bottom: 6px;
}

/* ── Cards ── */
.card {
    background-color: var(--uber-white);
    border: none;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-subtle);
}
.card-body {
    padding: var(--space-8);
}

/* ── Alerts ── */
.alert {
    border-radius: var(--radius-card);
    font-size: 14px;
    font-weight: 500;
}
.alert-success {
    background-color: #f0faf4;
    border: 1px solid #a3d9b1;
    color: #0d6b3a;
}
.alert-danger {
    background-color: #fef0f0;
    border: 1px solid #f5a5a5;
    color: #b00020;
}
.alert-overdue {
    background-color: #fef3c7;
    border: 1px solid #fcd34d;
    color: #b45309;
}

/* ── Form errors ── */
.invalid-feedback,
ul.form-error-message {
    font-size: 12px;
    font-weight: 400;
    color: #b00020;
    margin-top: 4px;
    list-style: none;
    padding: 0;
}

/* ── Checkbox ── */
.form-check-input {
    width: 20px;
    height: 20px;
    border: 2px solid var(--uber-black) !important;
    border-radius: 4px;
    cursor: pointer;
}
.form-check-input:checked {
    background-color: var(--uber-black) !important;
    border: 2px solid var(--uber-black) !important;
    box-shadow: inset 0 0 0 2px #ffffff;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 14px;
}
.form-check-input:focus {
    box-shadow: var(--uber-black) 0px 0px 0px 2px;
    outline: none;
}

/* ── Divider ── */
hr {
    border-color: #e5e5e5;
    opacity: 1;
}

/* ── Navbar dark dropdown ── */
.navbar .dropdown-item {
    color: #ffffff;
}
.navbar .dropdown-item:hover,
.navbar .dropdown-item:focus {
    background-color: #2a2a2a;
    color: #ffffff;
}
.navbar .dropdown-item:active {
    background-color: #3a3a3a;
    color: #ffffff;
}

/* ─────────────────────────────────────────
   Dark Mode - always on (the site has no light mode)
   Inverts the black/white duality:
   page → #000000, surface → #141414,
   text → #ffffff, buttons → white pill
───────────────────────────────────────── */
:root {
    /* Invert core palette */
    --uber-black:       #ffffff;
    --uber-white:       #000000;
    --uber-body-gray:   #afafaf;
    --uber-muted-gray:  #6b6b6b;
    --uber-chip-gray:   #1f1f1f;
    --uber-hover-gray:  #2a2a2a;
    --uber-hover-light: #1a1a1a;

    /* Softer shadows on dark bg */
    --shadow-subtle:  rgba(255,255,255,.06) 0px 4px 16px 0px;
    --shadow-medium:  rgba(255,255,255,.10) 0px 4px 16px 0px;
    --shadow-float:   rgba(255,255,255,.08) 0px 2px 8px 0px;
    --shadow-pressed: inset rgba(255,255,255,.08) 0px 0px 0px 999px;

    /* Bootstrap dark overrides */
    --bs-body-color:         #ffffff;
    --bs-body-bg:            #000000;
    --bs-primary:            #ffffff;
    --bs-primary-rgb:        255, 255, 255;
    --bs-link-color:         #ffffff;
    --bs-link-hover-color:   #ffffff;
    --bs-card-box-shadow:    rgba(255,255,255,.06) 0px 4px 16px 0px;
}

/* ── Base ── */
body {
    background-color: #000000;
    color: #ffffff;
}

/* ── Typography ── */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    color: #ffffff;
}
/* ── Links ── */
a {
    color: #ffffff;
}
a:hover {
    color: #ffffff;
}

/* ── Primary Button → white pill on dark bg ── */
.btn-primary {
    background-color: #ffffff;
    border-color: #ffffff;
    color: #000000;
}
.btn-primary:hover,
.btn-primary:focus {
    background-color: #e2e2e2;
    border-color: #e2e2e2;
    color: #000000;
}
.btn-primary:focus-visible {
    box-shadow: #000000 0px 0px 0px 2px inset;
}

/* ── Secondary Button → black pill on dark bg ── */
.btn-secondary {
    background-color: #000000;
    border-color: #000000;
    color: #ffffff;
}
.btn-secondary:hover,
.btn-secondary:focus {
    background-color: #1a1a1a;
    border-color: #1a1a1a;
    color: #ffffff;
}

/* ── Chip ── */
.btn-chip {
    background-color: #1f1f1f;
    color: #ffffff;
}
.btn-chip.active,
.btn-chip:active {
    background-color: #ffffff;
    color: #000000;
}

/* ── Inputs ── */
.form-control,
.form-select {
    background-color: #000000;
    border-color: #ffffff;
    color: #ffffff;
}
.form-control::placeholder {
    color: #6b6b6b;
}
.form-control:focus,
.form-select:focus {
    background-color: #000000;
    border-color: #ffffff;
    box-shadow: #000000 0px 0px 0px 2px inset,
                #ffffff 0px 0px 0px 3px;
}
.form-control.is-invalid {
    border-color: #ff6b6b;
    background-color: #1a0000;
}

/* ── Labels ── */
.form-label {
    color: #ffffff;
}
.form-label--sm {
    color: #ffffff;
}

/* ── Cards ── */
.card {
    background-color: #141414;
    box-shadow: rgba(255,255,255,.06) 0px 4px 16px 0px;
}
/* WFBO admin panel stays light — keep cards white */
[data-layout="wfbo"] .card {
    background-color: #ffffff;
    box-shadow: rgba(0,0,0,.08) 0px 4px 16px 0px;
    color: #000000;
}

/* WFBO admin panel stays light — keep modals white too (e.g. Set Player Loose Rate) */
[data-layout="wfbo"] .modal-content {
    background-color: #ffffff;
    color: #000000;
}
[data-layout="wfbo"] .modal-content .modal-title {
    color: #000000;
}
/* WFBO cards stay white, so their labels must stay dark too - not the
   white .form-label the dark scheme sets above (invisible on white). */
[data-layout="wfbo"] .form-label,
[data-layout="wfbo"] .form-label--sm,
[data-layout="wfbo"] .modal-content .form-label,
[data-layout="wfbo"] .modal-content .form-label--sm {
    color: #000000;
}
/* Explicitly white card (e.g. deposit form) */
.card--white {
    background-color: #ffffff !important;
    color: #374151 !important;
}
.card--white .form-label--sm {
    color: #374151;
}
.card--white .form-control,
.card--white .form-select {
    background-color: #f9fafb;
    border-color: #d1d5db;
    color: #111827;
}
.card--white .form-control:focus,
.card--white .form-select:focus {
    background-color: #ffffff;
    border-color: #374151;
    box-shadow: none;
}

/* ── Alerts ── */
.alert-success {
    background-color: #0a2a18;
    border-color: #1a5c32;
    color: #6ee7a0;
}
.alert-danger {
    background-color: #2a0a0a;
    border-color: #7f1d1d;
    color: #fca5a5;
}

/* ── Form errors ── */
.invalid-feedback,
ul.form-error-message {
    color: #ff6b6b;
}

/* ── Checkbox ── */
.form-check-input {
    border-color: #ffffff;
    background-color: transparent;
}
.form-check-input:checked {
    background-color: #ffffff;
    border-color: #ffffff;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23000' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 14px;
}
.form-check-input:focus {
    box-shadow: #ffffff 0px 0px 0px 2px;
}
/* WFBO white panel — restore dark checkbox border */
[data-layout="wfbo"] .form-check-input {
    border-color: #374151 !important;
    background-color: #ffffff;
}
[data-layout="wfbo"] .form-check-input:checked {
    background-color: #374151 !important;
    border-color: #374151 !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
}
[data-layout="wfbo"] .form-check-input:focus {
    box-shadow: #374151 0px 0px 0px 2px;
}

/* ── Divider ── */
hr {
    border-color: #2a2a2a;
}

/* ─────────────────────────────────────────
   Responsive — Wallet Balance Card
───────────────────────────────────────── */
.wallet-balance-amount {
    font-size: clamp(28px, 8vw, 46px);
}

.wallet-card-body {
    padding: 28px 32px;
}

@media (max-width: 575.98px) {
    .wallet-card-body {
        padding: 20px 20px;
    }
}

/* ─────────────────────────────────────────
   Responsive — Tables (enforce min-width
   so overflow-x: auto actually scrolls)
───────────────────────────────────────── */
[data-testid="deposit-history-table"]      { min-width: 580px; }
[data-testid="transactions-table"]         { min-width: 650px; }
[data-testid="users-table"]                { min-width: 700px; }
[data-testid="user-transactions-table"]    { min-width: 700px; }
[data-testid="user-withdrawals-table"]     { min-width: 700px; }
[data-testid="user-bets-table"]            { min-width: 580px; }
[data-testid="user-commissions-table"]     { min-width: 780px; }
[data-testid="user-adjustments-table"]     { min-width: 500px; }
[data-testid="user-activity-table"]        { min-width: 380px; }

/* wfbo deposits table is very wide */
@media (max-width: 991.98px) {
    [data-testid="deposits-table"] { min-width: 800px; }
}

/* ─────────────────────────────────────────
   Responsive — Navbar flush on mobile
───────────────────────────────────────── */
@media (max-width: 575.98px) {
    /* Nav's own 16px side padding removed so logo sits flush left */
    .navbar--dark {
        padding-left: 0;
        padding-right: 0;
    }
    /* Tighten nav link pill padding on small screens */
    .nav-link--dark {
        padding: 6px 10px;
        font-size: 13px;
    }
}

/* ─────────────────────────────────────────
   Responsive — Pagination stack on xs
───────────────────────────────────────── */
@media (max-width: 479.98px) {
    [data-testid="deposit-pagination"],
    [data-testid="transactions-pagination"],
    [data-testid="pagination"] {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 12px;
    }
}

/* ─────────────────────────────────────────
   Responsive — WFBO Sidebar Collapse
───────────────────────────────────────── */
@media (max-width: 767.98px) {

    /* Outer wrapper: stack sidebar above main */
    [data-layout="wfbo"] {
        flex-direction: column;
    }

    /* Sidebar: becomes a full-width sticky top bar */
    [data-testid="wfbo-sidebar"] {
        width: 100% !important;
        min-width: 0 !important;
        height: auto !important;
        position: sticky !important;
        top: 0 !important;
        z-index: 100;
        overflow-y: visible !important;
        flex-direction: column !important;
    }

    /* Compact the brand row to a slim top-bar height */
    [data-testid="wfbo-sidebar"] > div:first-child {
        padding: 0 16px !important;
        height: 56px;
        flex-shrink: 0;
    }

    /* Hide nav and footer by default on mobile */
    [data-testid="wfbo-sidebar-nav"],
    [data-testid="wfbo-sidebar-footer"] {
        display: none !important;
    }

    /* Expand when hamburger is toggled */
    [data-testid="wfbo-sidebar"].is-open [data-testid="wfbo-sidebar-nav"],
    [data-testid="wfbo-sidebar"].is-open [data-testid="wfbo-sidebar-footer"] {
        display: flex !important;
        flex-direction: column;
    }

    /* Main: reduce padding */
    [data-testid="wfbo-main"] {
        overflow-y: visible !important;
    }

    [data-testid="wfbo-main"] > div:first-child {
        padding: 0 16px !important;
    }

    [data-testid="wfbo-main"] > div:last-child {
        padding: 16px !important;
    }
}

/* ─────────────────────────────────────────
   A. Loading Overlay
───────────────────────────────────────── */
@keyframes vk-pulse {
    0%, 100% { opacity: 1;   transform: scale(1);    }
    50%       { opacity: .5; transform: scale(.92);  }
}

#loading-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    background-color: rgba(0,0,0,.65);
    backdrop-filter: blur(3px);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 20px;
}

.loading-overlay__logo {
    height: 56px;
    width: auto;
    animation: vk-pulse 1.4s ease-in-out infinite;
}

.loading-overlay__label {
    color: #ffffff;
    font-size: 13px;
    font-weight: 500;
    margin: 0;
    letter-spacing: .04em;
}

/* ─────────────────────────────────────────
   B. Navbar — Public
───────────────────────────────────────── */
.navbar--dark {
    background-color: #000000;
    padding: 0 16px;
}

.navbar--dark .navbar-container {
    margin: 0 auto;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap;
    padding: 0;
}

.navbar--dark .navbar-brand-link {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0;
}

.navbar--dark .navbar-brand-logo {
    height: 44px;
    width: auto;
}

.navbar--dark .navbar-brand-name {
    color: #ffffff;
    font-weight: 700;
    font-size: 20px;
    letter-spacing: -.02em;
}

.nav-link--dark {
    color: #afafaf;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    display: inline-flex;
    align-items: center;
    background-color: transparent;
    white-space: nowrap;
}
.nav-link--dark.is-active {
    color: #ffffff;
    background-color: #1a1a1a;
}

.navbar-user-chip {
    background-color: #1a1a1a;
    color: #ffffff;
    border: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    display: flex;
    align-items: center;
    gap: 8px;
}

.navbar-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: #ffffff;
    color: #000000;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

.navbar-user-name {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dropdown-menu--dark {
    background-color: #141414;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    padding: 6px;
    min-width: 200px;
    box-shadow: rgba(0,0,0,.4) 0px 8px 24px;
}

.dropdown-menu--dark .dropdown-user-label {
    font-size: 12px;
    color: #6b6b6b;
    padding: 6px 12px;
    display: block;
}

.dropdown-menu--dark .dropdown-divider--dark {
    border-color: #2a2a2a;
    margin: 4px 0;
}

.dropdown-item--dark {
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
    padding: 10px 12px;
    border-radius: 6px;
    text-decoration: none;
    display: block;
}

.dropdown-item--muted {
    color: #afafaf;
    font-size: 14px;
    font-weight: 500;
    padding: 10px 12px;
    border-radius: 6px;
    text-decoration: none;
    display: block;
}

/* ─────────────────────────────────────────
   C. WFBO Admin Sidebar Layout
───────────────────────────────────────── */
.wfbo-layout {
    display: flex;
    min-height: 100vh;
}

.wfbo-sidebar {
    width: 240px;
    min-width: 240px;
    background-color: #000000;
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.wfbo-sidebar__brand-row {
    padding: 20px 20px 18px;
    border-bottom: 1px solid #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.wfbo-sidebar__brand-link {
    text-decoration: none;
    display: block;
}

.wfbo-sidebar__brand-subtitle {
    font-size: 11px;
    font-weight: 500;
    color: #6b6b6b;
    text-transform: uppercase;
    letter-spacing: .1em;
    display: block;
    margin-bottom: 2px;
}

.wfbo-sidebar__brand-title {
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -.02em;
}

.wfbo-sidebar__hamburger {
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 6px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wfbo-sidebar__nav {
    padding: 12px 10px;
    flex: 1;
}

.wfbo-sidebar__nav-section-label {
    font-size: 11px;
    font-weight: 500;
    color: #6b6b6b;
    text-transform: uppercase;
    letter-spacing: .1em;
    padding: 8px 10px 4px;
    margin: 0;
}

.wfbo-sidebar__nav-section-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 2px;
    color: #afafaf;
    background-color: transparent;
    width: 100%;
    border: none;
    cursor: pointer;
    text-align: left;
}
.wfbo-sidebar__nav-section-toggle:hover {
    color: #d0d0d0;
    background-color: #0d0d0d;
}
.wfbo-sidebar__nav-section-toggle.is-active {
    color: #ffffff;
    background-color: #1a1a1a;
}
.wfbo-sidebar__nav-section-chevron {
    transition: transform 0.2s ease;
    flex-shrink: 0;
    margin-left: auto;
    opacity: 0.45;
}
.wfbo-sidebar__nav-section-toggle.is-active .wfbo-sidebar__nav-section-chevron {
    opacity: 0.65;
}
.wfbo-sidebar__nav-section-toggle.is-collapsed .wfbo-sidebar__nav-section-chevron {
    transform: rotate(-90deg);
}

.wfbo-sidebar__nav-section-body {
    overflow: hidden;
    max-height: 600px;
    transition: max-height 0.25s ease;
    margin-left: 14px;
    padding-left: 10px;
    border-left: 1px solid #1e1e1e;
    margin-bottom: 4px;
}
.wfbo-sidebar__nav-section-body.is-collapsed {
    max-height: 0;
    margin-bottom: 0;
}

.wfbo-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 2px;
    color: #afafaf;
    background-color: transparent;
}
.wfbo-nav-item.is-active {
    color: #ffffff;
    background-color: #1a1a1a;
}

.wfbo-nav-item--sub {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 1px;
    color: #afafaf;
    background-color: transparent;
}
.wfbo-nav-item--sub.is-active {
    color: #ffffff;
    background-color: #1a1a1a;
}

.wfbo-nav-subgroup {
    margin-left: 14px;
    border-left: 1px solid #2a2a2a;
    padding-left: 12px;
}

.wfbo-nav-group-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    font-size: 14px;
    font-weight: 500;
    color: #afafaf;
}
.wfbo-nav-group-header.is-active {
    color: #ffffff;
}

.wfbo-sidebar__footer {
    padding: 12px 10px;
    border-top: 1px solid #1a1a1a;
}

.wfbo-sidebar__back-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    color: #6b6b6b;
    margin-bottom: 8px;
}

.wfbo-sidebar__user-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
}

.wfbo-sidebar__avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #ffffff;
    color: #000000;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}

.wfbo-sidebar__user-info {
    overflow: hidden;
}

.wfbo-sidebar__user-name {
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wfbo-sidebar__user-email {
    font-size: 11px;
    color: #6b6b6b;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wfbo-main {
    flex: 1;
    background-color: #f8f8f8;
    overflow-y: auto;
    color: #000000;
}

.wfbo-main__topbar {
    background-color: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    padding: 0 32px;
    height: 56px;
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 10;
}

.wfbo-main__page-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    color: #000000;
}

.wfbo-main__content {
    padding: 32px;
}

/* ─────────────────────────────────────────
   D. Agent Portal Layout
───────────────────────────────────────── */
.agent-topbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #000000;
    border-bottom: 1px solid #1a1a1a;
    padding: 0 24px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.agent-topbar__brand {
    text-decoration: none;
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.agent-topbar__brand-main {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -.02em;
}

.agent-topbar__brand-sub {
    font-size: 11px;
    color: #6b6b6b;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .1em;
}

.agent-topbar__nav {
    display: flex;
    gap: 4px;
}

.agent-nav-link {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    background: transparent;
    color: #afafaf;
}
.agent-nav-link.is-active {
    background: #1a1a1a;
    color: #ffffff;
}

/* Grouped dropdown items in the agent topbar */
button.agent-nav-link {
    border: none;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
    line-height: 1.4;
}
.agent-topbar__nav .dropdown-toggle::after {
    margin-left: 3px;
    opacity: .55;
}
.agent-topbar__nav .dropdown-menu--dark .dropdown-item--dark {
    font-size: 13px;
    padding: 8px 12px;
}
.agent-topbar__nav .dropdown-menu--dark .dropdown-item--dark:hover,
.agent-topbar__nav .dropdown-menu--dark .dropdown-item--dark:focus {
    background-color: #1f1f1f;
    color: #ffffff;
}
.agent-topbar__nav .dropdown-menu--dark .dropdown-item--dark.active {
    background-color: #1a1a1a;
    color: #ffffff;
}

.agent-topbar__wallet-label {
    font-size: 10px;
    color: #6b6b6b;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.agent-topbar__wallet-amount {
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
}

.agent-topbar__back-link {
    font-size: 12px;
    color: #6b7280;
    text-decoration: none;
    font-weight: 500;
}

.agent-topbar__hamburger {
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.agent-mobile-nav {
    display: none;
    background: #111111;
    border-bottom: 1px solid #1a1a1a;
    padding: 8px 16px;
}

.agent-mobile-nav__link {
    display: block;
    padding: 10px 0;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1px solid #1a1a1a;
    color: #afafaf;
}
.agent-mobile-nav__link.is-active {
    color: #ffffff;
}

.agent-mobile-nav__wallet {
    padding: 10px 0;
    font-size: 13px;
    color: #6b7280;
}

.agent-page {
    min-height: calc(100vh - 56px);
    background-color: #0a0a0a;
    color: #ffffff;
}

.agent-page__inner {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 20px;
}

/* ─────────────────────────────────────────
   E. Stat Cards
───────────────────────────────────────── */
.stat-label {
    font-size: 12px;
    font-weight: 500;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 8px;
}

.stat-label--sm {
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .1em;
    margin-bottom: 6px;
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    line-height: 1;
    margin: 0;
}

.stat-value--lg {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin: 0 0 4px;
}

.stat-value--md {
    font-size: 24px;
    font-weight: 700;
    margin: 0;
}

.stat-value--pending {
    color: #854d0e;
}

.stat-sub {
    font-size: 11px;
    color: #9ca3af;
    margin: 0;
}

.stat-game-breakdown {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.stat-game-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    background-color: #f3f4f6;
    color: #6b7280;
    white-space: nowrap;
    flex-shrink: 0;
}

.stat-rate-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
}

.stat-rate-label {
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.stat-rate-value {
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
}

.stat-count-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    background-color: #fef9c3;
    color: #854d0e;
    white-space: nowrap;
    flex-shrink: 0;
}

.stat-review-link {
    font-size: 12px;
    font-weight: 500;
    color: #854d0e;
    text-decoration: none;
    margin-top: 6px;
    display: inline-block;
}

.stat-tooltip-icon {
    cursor: help;
    display: inline-flex;
    vertical-align: middle;
    margin-left: 4px;
    color: #9ca3af;
    transition: color .15s;
}
.stat-tooltip-icon:hover {
    color: #6b7280;
}

.stat-breakdown {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid #f3f4f6;
}

.stat-breakdown-bar {
    display: flex;
    height: 8px;
    border-radius: 9999px;
    overflow: hidden;
    background: #e5e7eb;
}

.stat-breakdown-seg {
    height: 100%;
    transition: opacity .15s;
    min-width: 4px;
}

.stat-breakdown-labels {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}

.stat-breakdown-label {
    font-size: 10px;
    color: #6b7280;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.stat-breakdown-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* ─────────────────────────────────────────
   F. Status & Role Badges
───────────────────────────────────────── */
.badge-status {
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    white-space: nowrap;
}

.badge-status--pending {
    background-color: #fef9c3;
    color: #854d0e;
}

.badge-status--approved,
.badge-status--won {
    background-color: #dcfce7;
    color: #15803d;
}

.badge-status--rejected,
.badge-status--lost {
    background-color: #fee2e2;
    color: #b00020;
}

.badge-status--neutral {
    background-color: #f3f4f6;
    color: #6b7280;
}

/* Neutral pill for the "Detail" column on the user bets tab. Same dimensions
   as .badge-status but NOT nowrap - a Live Racing per-leg summary is long and
   must wrap inside the cell. */
.badge-detail {
    display: inline-block;
    background-color: #f3f4f6;
    color: #374151;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    line-height: 1.6;
}

.badge-role {
    font-size: 11px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    white-space: nowrap;
}

.badge-role--admin {
    background-color: #000000;
    color: #ffffff;
}

.badge-role--agent {
    background-color: #4f46e5;
    color: #ffffff;
}

.badge-role--finance {
    background-color: #dbeafe;
    color: #1d4ed8;
}

.badge-role--operations {
    background-color: #fef3c7;
    color: #92400e;
}

.badge-role--default {
    background-color: #efefef;
    color: #000000;
}

.badge-role--agent-role {
    background-color: #d1fae5;
    color: #065f46;
}

.badge-role--sub-agent {
    background-color: #f0f4ff;
    color: #2563eb;
}

.badge-role--suspended {
    background-color: #fee2e2;
    color: #b00020;
}

.badge-role--active {
    background-color: #dcfce7;
    color: #15803d;
}

.filter-count-badge {
    font-size: 11px;
    font-weight: 700;
    border-radius: var(--radius-pill);
    padding: 1px 7px;
    margin-left: 4px;
}

/* Period toggle buttons in chart cards */
.period-btn {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 14px;
    border-radius: var(--radius-pill);
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #374151;
    cursor: pointer;
}
.period-btn.active {
    background: #000000;
    color: #ffffff;
    border-color: #000000;
}

.filter-count-badge--default {
    background-color: #000000;
    color: #ffffff;
}

.filter-count-badge--active {
    background-color: #ffffff;
    color: #000000;
}

.tab-count {
    font-size: 11px;
    font-weight: 700;
    padding: 1px 7px;
    border-radius: var(--radius-pill);
    background-color: #f0f0f0;
    color: #374151;
    margin-left: 4px;
}

.badge-agent-inline {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    background: #000000;
    color: #ffffff;
    letter-spacing: .05em;
    white-space: nowrap;
}

/* ─────────────────────────────────────────
   G. Filter Pills
───────────────────────────────────────── */
.filter-pill {
    font-size: 13px;
    font-weight: 500;
    padding: 6px 16px;
    border-radius: var(--radius-pill);
    text-decoration: none;
    background-color: #efefef;
    color: #000000;
}

.filter-pill.is-active {
    background-color: #000000;
    color: #ffffff;
}

/* ─────────────────────────────────────────
   H. Tab Navigation
───────────────────────────────────────── */
.tab-link {
    font-size: 13px;
    font-weight: 500;
    padding: 8px 16px;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    text-decoration: none;
    color: #9ca3af;
}

.tab-link:hover {
    color: #000000;
}

.tab-link.is-active {
    font-weight: 600;
    border-bottom-color: currentColor;
    color: inherit;
}

.tab-link--block {
    font-size: 13px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 6px 6px 0 0;
    text-decoration: none;
    color: #6b7280;
}

.tab-link--block:hover {
    color: #000000;
}

.tab-link--block.is-active {
    background-color: #000000;
    color: #ffffff;
}

/* ─────────────────────────────────────────
   I. Pagination Controls
───────────────────────────────────────── */
.pagination-info {
    font-size: 13px;
    color: #6b7280;
    margin: 0;
}

.btn-page-prev {
    font-size: 13px;
    font-weight: 500;
    padding: 7px 16px;
    border-radius: var(--radius-pill);
    background-color: #efefef;
    color: #000000;
    text-decoration: none;
}

.btn-page-next {
    font-size: 13px;
    font-weight: 500;
    padding: 7px 16px;
    border-radius: var(--radius-pill);
    background-color: #000000;
    color: #ffffff;
    text-decoration: none;
}

/* Light-theme numbered pager (WFBO) */
.wfbo-pager {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}

.wfbo-pager__item {
    min-width: 34px;
    height: 34px;
    padding: 0 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-pill);
    background-color: #efefef;
    color: #000000;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
}

.wfbo-pager__item.is-active {
    background-color: #000000;
    color: #ffffff;
    font-weight: 700;
}

.wfbo-pager__ellipsis {
    padding: 0 4px;
    color: #9ca3af;
    font-size: 13px;
}

/* ─────────────────────────────────────────
   J. Data Tables
───────────────────────────────────────── */
.table-card {
    background-color: #ffffff;
    color: #000000;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
}

.table-row {
    border-bottom: 1px solid #f0f0f0;
    background-color: #ffffff;
}

.table-row--gcash td  { background-color: #dbeafe; }  /* Blue */
.table-row--maya td   { background-color: #d1fae5; }  /* Green */
.table-row--gotyme td { background-color: #ccfbf1; }  /* Aqua  */
.table-row--other td  { background-color: #f3f4f6; }  /* Grey  */

/* Agent Insight — client-side per-table pager (agent_insight_controller.js) */
.insight-pager {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 8px 12px;
    border-top: 1px solid #f0f0f0;
    font-size: 12px;
    color: #6b7280;
}
.insight-pager[hidden] { display: none; }
.insight-pager__info { font-variant-numeric: tabular-nums; }
.insight-pager__btn {
    background: #1f2937;
    color: #e5e7eb;
    border: 1px solid #374151;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 12px;
    cursor: pointer;
}
.insight-pager__btn:hover:not(:disabled) { background: #374151; }
.insight-pager__btn:disabled { opacity: 0.4; cursor: default; }

.th-white {
    padding: 14px 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #6b7280;
    white-space: nowrap;
    background-color: #ffffff;
    text-align: left;
}

.th-gray {
    padding: 12px 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .07em;
    color: #6b7280;
    background-color: #f9fafb;
    white-space: nowrap;
    text-align: left;
}

.th-gray--right {
    text-align: right;
}

.td-cell {
    padding: 14px 20px;
    background-color: #ffffff;
}

.td-cell--id {
    color: #9ca3af;
}

.td-cell--muted {
    color: #6b7280;
}

.td-cell--dark {
    color: #374151;
}

.td-cell--nowrap {
    white-space: nowrap;
}

.td-empty {
    padding: 32px 20px;
    text-align: center;
    color: #9ca3af;
    background-color: #ffffff;
}

.td-empty--lg {
    padding: 40px 20px;
}

.thead-row--strong {
    border-bottom: 2px solid #000000;
}

.thead-row--light {
    border-bottom: 2px solid #e5e7eb;
    background-color: #f9fafb;
}

/* Stackable tables: add class="stack-table" to a <table> and data-label="..."
   (matching each column's header text) to every <td> to make it collapse into
   label/value rows on narrow screens instead of scrolling horizontally. */
@media (max-width: 480px) {
    .stack-table thead {
        display: none;
    }

    .stack-table tbody tr {
        display: block;
        margin: 12px;
        border: 1px solid #e5e7eb !important;
        border-radius: 8px;
        background-color: #ffffff;
    }

    .stack-table tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 12px;
        padding: 10px 12px !important;
        background-color: transparent !important;
        border: none !important;
        border-bottom: 1px solid #f3f4f6 !important;
        text-align: right;
    }

    .stack-table tbody td:last-child {
        border-bottom: none !important;
    }

    .stack-table tbody td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #6b7280;
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: .04em;
        flex-shrink: 0;
        text-align: left;
    }
}

/* ─────────────────────────────────────────
   K. Table Action Buttons
───────────────────────────────────────── */
.btn-actions-trigger {
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    background-color: #f3f4f6;
    color: #000000;
    border: 1px solid #e5e7eb;
}

.dropdown-menu--light {
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 6px;
    min-width: 190px;
    box-shadow: rgba(0,0,0,.12) 0px 4px 16px;
    max-height: min(60vh, 400px) !important;
    overflow-y: auto !important;
    overscroll-behavior: contain;
}

.dropdown-item--view {
    font-size: 13px;
    font-weight: 500;
    color: #1d4ed8;
    padding: 8px 12px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.dropdown-item--action {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    padding: 8px 12px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.dropdown-item--danger {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    font-size: 13px;
    font-weight: 500;
    color: #b00020;
    padding: 8px 12px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.dropdown-item--success {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    font-size: 13px;
    font-weight: 500;
    color: #15803d;
    padding: 8px 12px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.dropdown-divider--light {
    border-color: #f0f0f0;
    margin: 4px 0;
}

.btn-approve {
    font-size: 12px;
    font-weight: 500;
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    background-color: #000000;
    color: #ffffff;
    border: none;
    white-space: nowrap;
}

.btn-reject {
    font-size: 12px;
    font-weight: 500;
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    background-color: #fee2e2;
    color: #b00020;
    border: none;
    white-space: nowrap;
}

/* Approve/Reject "in flight" feedback (review_action_controller.js) */
tr.is-processing {
    opacity: 0.6;
    transition: opacity 0.15s ease;
}

.review-spinner {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-right: 6px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-top-color: currentColor;
    border-radius: 50%;
    vertical-align: middle;
    animation: review-spin 0.6s linear infinite;
}

@keyframes review-spin {
    to { transform: rotate(360deg); }
}

.btn-disable {
    font-size: 12px;
    font-weight: 500;
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    background-color: #fef3c7;
    color: #92400e;
    border: none;
    white-space: nowrap;
}

.table-input {
    font-size: 12px;
    border-radius: 6px;
    padding: 5px 10px;
    border: 1px solid #d1d5db;
    background-color: #ffffff;
    color: #000000;
}

/* ─────────────────────────────────────────
   L. Pill Action Links
───────────────────────────────────────── */
.pill-link--primary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    background-color: #000000;
    padding: 9px 20px;
    border-radius: var(--radius-pill);
    text-decoration: none;
}

.pill-link--secondary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #000000;
    background-color: #f0f0f0;
    padding: 9px 20px;
    border-radius: var(--radius-pill);
    text-decoration: none;
}

.pill-link--ghost {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    background-color: rgba(255,255,255,.15);
    padding: 9px 20px;
    border-radius: var(--radius-pill);
    text-decoration: none;
    border: 1px solid rgba(255,255,255,.3);
}

.btn-form-submit {
    width: 100%;
    padding: 12px;
    border-radius: var(--radius-pill);
    background-color: #000000;
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    border: none;
}

.btn-admin-save {
    padding: 10px 28px;
    border-radius: var(--radius-pill);
    background-color: #000000;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    border: none;
}

/* ─────────────────────────────────────────
   M. Back Navigation Link
───────────────────────────────────────── */
.back-link {
    font-size: 13px;
    font-weight: 500;
    color: #6b7280;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 10px;
}

/* ─────────────────────────────────────────
   N. Avatar / Initials Badge
───────────────────────────────────────── */
.avatar--lg {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: #000000;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    flex-shrink: 0;
}

.wallet-badge {
    background-color: #000000;
    color: #ffffff;
    border-radius: 8px;
    padding: 14px 20px;
    text-align: right;
    flex-shrink: 0;
}

.wallet-badge__label {
    font-size: 11px;
    font-weight: 500;
    color: #afafaf;
    text-transform: uppercase;
    letter-spacing: .1em;
    margin: 0 0 4px;
}

.wallet-badge__amount {
    font-size: 24px;
    font-weight: 700;
    margin: 0;
    color: #ffffff;
}

/* ─────────────────────────────────────────
   P. Period Filter Bar
───────────────────────────────────────── */
.period-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.period-pill {
    display: inline-block;
    padding: 6px 16px;
    border-radius: var(--radius-pill);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    background: #ffffff;
    color: #374151;
    border: 1px solid #d1d5db;
}
.period-pill:hover {
    color: #000000;
}

.period-pill.is-active {
    background: #000000;
    color: #ffffff;
    border-color: #000000;
}

.period-pill--dark {
    display: inline-block;
    padding: 6px 16px;
    border-radius: var(--radius-pill);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    background: #1a1a1a;
    color: #afafaf;
    border: 1px solid #2a2a2a;
}

.period-pill--dark.is-active {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

.period-filter-input {
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 13px;
}

.period-filter-input--light {
    border: 1px solid #d1d5db;
    background-color: #ffffff;
    color: #000000;
}

.period-filter-input--light.is-active {
    border-color: #000000;
}

.period-filter-input--dark {
    border: 1px solid #2a2a2a;
    background: #1a1a1a;
    color: #ffffff;
}

.period-filter-input--dark.is-active {
    border-color: #ffffff;
}

.period-filter-go {
    padding: 5px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.period-filter-go--light {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.period-filter-go--light.is-active {
    background: #000000;
    color: #ffffff;
    border-color: #000000;
}

.period-filter-go--dark {
    background: #1a1a1a;
    color: #afafaf;
    border: 1px solid #2a2a2a;
}

.period-filter-go--dark.is-active {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

/* ─────────────────────────────────────────
   Q. Split Stat Card
───────────────────────────────────────── */
.split-stat__divider {
    width: 1px;
    background: #f0f0f0;
    align-self: stretch;
    flex-shrink: 0;
}

.split-stat__label--success {
    font-size: 11px;
    font-weight: 600;
    color: #15803d;
    text-transform: uppercase;
    letter-spacing: .06em;
    margin: 0 0 4px;
}

.split-stat__label--danger {
    font-size: 11px;
    font-weight: 600;
    color: #b00020;
    text-transform: uppercase;
    letter-spacing: .06em;
    margin: 0 0 4px;
}

.split-stat__value--success {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin: 0;
    color: #15803d;
}

.split-stat__value--danger {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin: 0;
    color: #b00020;
}

.split-stat__sub--success {
    font-size: 13px;
    font-weight: 600;
    color: #15803d;
    margin: 3px 0 0;
}

.split-stat__sub--danger {
    font-size: 13px;
    font-weight: 600;
    color: #b00020;
    margin: 3px 0 0;
}

.split-stat__link--success {
    font-size: 12px;
    font-weight: 500;
    color: #15803d;
    text-decoration: none;
    margin-top: 6px;
    display: inline-block;
}

.split-stat__link--danger {
    font-size: 12px;
    font-weight: 500;
    color: #b00020;
    text-decoration: none;
    margin-top: 6px;
    display: inline-block;
}

/* ─────────────────────────────────────────
   R. Form Helpers
───────────────────────────────────────── */
.form-label--sm {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
    display: block;
}

.form-hint {
    font-size: 11px;
    color: #9ca3af;
    margin-top: 4px;
}

.form-section-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #6b7280;
    margin: 24px 0 16px;
    border-top: 1px solid #f0f0f0;
    padding-top: 20px;
}

.input-group-suffix {
    background-color: #f9fafb;
    border-left: none;
    color: #6b7280;
    font-size: 14px;
    font-weight: 600;
}

.input-group-prefix {
    background-color: #f9fafb;
    border-right: none;
    color: #6b7280;
    font-size: 14px;
    font-weight: 600;
}

/* ─────────────────────────────────────────
   S. WFBO Card Headings
───────────────────────────────────────── */
.wfbo-card-title {
    font-size: 15px;
    font-weight: 700;
    margin: 0 0 4px;
    color: #000000;
}

.wfbo-card-desc {
    font-size: 13px;
    color: #6b7280;
    margin: 0 0 24px;
}

/* Detail grid: a responsive label/value layout for read-only "show" cards
   (e.g. Event Details, Race Details). Wraps to a single column on narrow
   screens automatically via auto-fit, no separate breakpoint needed. */
.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px 24px;
}

.detail-item {
    min-width: 0;
}

.detail-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #6b7280;
    margin-bottom: 4px;
}

.detail-value {
    font-size: 14px;
    font-weight: 500;
    color: #111827;
    overflow-wrap: break-word;
}

/* ─────────────────────────────────────────
   T. Dividend Matrix Table
───────────────────────────────────────── */
.dividend-table th,
.dividend-table td {
    border: 1px solid #e5e5e5;
}

.dividend-table th {
    padding: 8px 12px;
    background: #f9fafb;
    font-weight: 600;
    color: #374151;
    text-align: center;
}

.dividend-table th.dividend-table__header-wide {
    padding: 8px 20px;
}

.dividend-table td {
    padding: 6px 8px;
    text-align: center;
    background: #ffffff;
}

.dividend-table td.dividend-table__empty {
    background: #f3f4f6;
}

.dividend-table td.dividend-table__view {
    padding: 10px 12px;
    text-align: right;
    font-size: 13px;
    color: #111827;
    font-weight: 500;
    min-width: 120px;
}

.dividend-input {
    width: 120px;
    text-align: right;
}

/* ─────────────────────────────────────────
   U. Miscellaneous
───────────────────────────────────────── */
.payment-detail-card {
    background-color: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    padding: 16px 20px;
    min-width: 220px;
    flex: 1;
}

.payment-detail-card[hidden] { display: none; }

/* /deposit bank filter: one pill per bank; scrolls sideways on a phone instead of wrapping. */
/* First deposit bonus offer on /deposit (shown until the first deposit is approved). */
.first-deposit-offer {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    border-radius: 12px;
    border: 1px solid rgba(250, 204, 21, .45);
    background: linear-gradient(135deg, rgba(234, 179, 8, .18), rgba(219, 39, 119, .14));
    color: #fef3c7;
}
.first-deposit-offer__icon { font-size: 28px; line-height: 1; }
.first-deposit-offer__title { font-weight: 800; font-size: 15px; color: #fde68a; letter-spacing: .02em; }
.first-deposit-offer__text { font-size: 13px; color: #fef3c7; }
.first-deposit-offer__text strong { color: #fff; }

.deposit-bank-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
}
.deposit-bank-tabs::-webkit-scrollbar { display: none; }
.deposit-bank-tabs .filter-pill {
    flex-shrink: 0;
    border: 0;
    white-space: nowrap;
    cursor: pointer;
}
.deposit-bank-tabs__count {
    display: inline-block;
    min-width: 18px;
    margin-left: 4px;
    padding: 0 6px;
    border-radius: 999px;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
    background: rgba(0, 0, 0, .08);
}
.deposit-bank-tabs .filter-pill.is-active .deposit-bank-tabs__count { background: rgba(255, 255, 255, .22); }

.payment-detail-card__label {
    font-size: 13px;
    font-weight: 700;
    color: #15803d;
    margin: 0 0 10px;
}

.payment-detail-card__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    font-size: 13px;
    color: #374151;
    margin: 0 0 4px;
}

.payment-detail-card__key {
    color: #6b7280;
}

.btn-copy {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 1px solid #bbf7d0;
    border-radius: 6px;
    background-color: #ffffff;
    color: #15803d;
    cursor: pointer;
    transition: background-color .15s, border-color .15s;
}

.btn-copy:hover {
    background-color: #f0fdf4;
    border-color: #15803d;
}

.btn-copy--copied,
.btn-copy--copied:hover {
    background-color: #15803d;
    border-color: #15803d;
    color: #ffffff;
}

.wallet-hint {
    display: flex;
    align-items: center;
    gap: 12px;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 14px 18px;
    margin-bottom: 28px;
}

.wallet-hint__text {
    font-size: 14px;
    font-weight: 500;
    margin: 0;
    color: #374151;
}

.withdrawal-schedule-box {
    background-color: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    padding: 14px 18px;
    margin-bottom: 28px;
}

.withdrawal-schedule-box__title {
    font-size: 13px;
    font-weight: 600;
    color: #0369a1;
    margin: 0 0 4px;
}

.withdrawal-schedule-box__body {
    font-size: 13px;
    color: #374151;
    margin: 0;
}

.unavailable-icon-circle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.txn-list-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 24px;
    border-bottom: 1px solid #f5f5f5;
}

.txn-list-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.txn-list-icon--deposit {
    background-color: #f0f0f0;
}

.txn-list-icon--withdrawal {
    background-color: #fef9c3;
}

.txn-list-item .amount-primary,
.txn-list-item .amount-approved,
.txn-list-item .amount-rejected,
.txn-list-item .amount-neutral {
    color: #ffffff;
}

.horse-position-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 700;
}

.horse-position-badge--top2 {
    background-color: #14532d;
    color: #4ade80;
    border: 1px solid #16a34a;
}

.horse-position-badge--other {
    background-color: #1a1a1a;
    color: #6b7280;
    border: 1px solid #2a2a2a;
}

.card--pending-warning {
    border: 1px solid #fde68a !important;
}

.card--pending-neutral {
    border: 1px solid #e5e7eb !important;
}

.user-name-heading {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    color: #ffffff;
}

.page-container {
    max-width: 860px;
    padding: 48px 16px 88px;
}

/* ─────────────────────────────────────────
   X. Game / Dark Page Shells
───────────────────────────────────────── */
.game-page {
    min-height: 100vh;
    background-color: #0a0a0a;
    color: #ffffff;
    padding: 24px 16px;
}

.game-page__inner {
    max-width: 900px;
    margin: 0 auto;
}

/* Dark card used in agent dashboard */
.dark-card {
    background: #141414;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
}

/* Dark-themed table card wrapper */
.dark-table-card {
    background-color: #141414;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    padding: 24px 28px;
}

/* Dark table header row */
.thead-dark-row {
    border-bottom: 1px solid #2a2a2a;
}

/* Dark table th */
.th-dark {
    padding: 8px 12px;
    text-align: left;
    color: #6b7280;
    font-weight: 600;
}

/* Dark table body row */
.tr-dark {
    border-bottom: 1px solid #1f1f1f;
}

/* Dark table td variants */
.td-dark {
    padding: 10px 12px;
    color: #4b5563;
}

.td-dark--muted {
    color: #6b7280;
    white-space: nowrap;
}

.td-dark--green {
    color: #4ade80;
    font-weight: 700;
}

.td-dark--bet {
    color: #9ca3af;
}

/* Dark pagination (numbered) */
.page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.page-btn--square {
    width: 36px;
    height: 36px;
}

.page-btn--wide {
    min-width: 36px;
    height: 36px;
    padding: 0 8px;
}

.page-btn--prev,
.page-btn--next {
    background: #1a1a1a;
    color: #afafaf;
    border: 1px solid #2a2a2a;
}

.page-btn--number {
    background: #1a1a1a;
    color: #afafaf;
    border: 1px solid #2a2a2a;
}

.page-btn--active {
    background: #ffffff;
    color: #000000;
    border-color: #ffffff;
}

.page-btn--ellipsis {
    color: #3f3f3f;
    font-size: 13px;
}

/* Wallet card inner text (on dark gradient background) */
.wallet-card__balance-label {
    font-size: 11px;
    font-weight: 600;
    color: #afafaf;
    text-transform: uppercase;
    letter-spacing: .12em;
    margin-bottom: 6px;
}

/* Txn list item detail text */
.txn-detail-title {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 2px;
}

.txn-detail-sub {
    font-size: 12px;
    font-weight: 400;
    color: #9ca3af;
}

/* ─────────────────────────────────────────
   W. Additional Layout Helpers
───────────────────────────────────────── */

/* Tab bar bottom border wrapper */
.tabs-border-bottom {
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 0;
    flex-wrap: wrap;
}

/* Table card variant for tabbed layout (rounded only on bottom) */
.table-card--tabbed {
    border-radius: 0 8px 8px 8px;
    overflow: hidden;
    background-color: #ffffff;
    color: #000000;
    border: 1px solid #e5e7eb;
}

/* Compact card body (smaller padding) */
.card-body--compact {
    padding: 16px 20px;
}

/* Green-colored stat value */
.stat-value--green {
    color: #15803d;
}

/* ─────────────────────────────────────────
   V. Table Utility Classes
───────────────────────────────────────── */

.table-card {
    /* overflow: hidden removed — was clipping absolutely-positioned dropdown menus.
       Border-radius clipping is handled by table-scroll instead. */
}

/* Horizontal scroll wrapper for tables */
.table-scroll {
    overflow-x: auto;
}

/* Base table reset */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    color: #000000;
}

/* Date display patterns (used in date/time cells) */
.date-primary {
    font-size: 13px;
    margin: 0;
    white-space: nowrap;
}

.date-secondary {
    font-size: 11px;
    color: #9ca3af;
    margin: 0;
}

/* Amount display patterns */
.amount-primary {
    font-weight: 700;
    margin: 0;
    color: #000000;
}

.amount-approved {
    font-weight: 700;
    margin: 0;
    color: #15803d;
}

.amount-rejected {
    font-weight: 700;
    margin: 0;
    color: #b00020;
}

.amount-neutral {
    font-weight: 700;
    margin: 0;
    color: #9ca3af;
}

.amount-sub {
    font-size: 11px;
    color: #9ca3af;
    margin: 2px 0 0;
}

/* Monospace amount/id cells */
.font-mono-sm {
    font-family: monospace;
    font-size: 13px;
}

/* Truncating text within a cell */
.text-truncate-cell {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ─────────────────────────────────────────
   Y. Home Page — Section Label
───────────────────────────────────────── */
.home-section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: #6b7280;
    margin: 0 0 12px;
}

/* ─────────────────────────────────────────
   Z. Sticky Wallet Bar
───────────────────────────────────────── */
.wallet-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    /* Never let the fixed bar exceed the viewport: if any page nudges the
       layout viewport wider than device-width, a left:0/right:0 fixed bar
       stretches with it and becomes horizontal dead space. */
    max-width: 100vw;
    overflow: hidden;
    z-index: 1050 !important;
    background-color: #0a0a0a;
    border-top: 2px solid #3f3f46;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    gap: 12px;
}

.wallet-bar__balance {
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    min-width: 0;
}

.wallet-bar__label {
    font-size: 9px;
    font-weight: 700;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .12em;
    margin: 0;
    line-height: 1;
}

.wallet-bar__amount {
    font-size: clamp(16px, 4vw, 22px);
    font-weight: 700;
    color: #ffffff;
    margin: 3px 0 0;
    line-height: 1;
    letter-spacing: -.02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wallet-bar__bonus {
    margin: 4px 0 0;
    font-size: 11px;
    font-weight: 700;
    color: #fde68a;
    line-height: 1;
    white-space: nowrap;
}
.wallet-bar__bonus[hidden] { display: none; }

.wallet-bar__actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

/* ─── Register page: welcome (registration) bonus banner ─────────────────── */
.signup-bonus {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 12px;
    background:
        radial-gradient(circle at 15% 20%, rgba(253, 224, 71, .25), transparent 55%),
        linear-gradient(135deg, #3b0764 0%, #7c2d12 55%, #a16207 100%);
    border: 1px solid rgba(253, 224, 71, .55);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, .4), 0 4px 14px rgba(234, 179, 8, .22);
    animation: signup-bonus-glow 2.4s ease-in-out infinite;
}
.signup-bonus__gift {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    font-size: 24px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(253, 224, 71, .35), rgba(253, 224, 71, 0) 70%);
    animation: signup-bonus-bounce 1.8s ease-in-out infinite;
}
.signup-bonus__body { position: relative; min-width: 0; }
.signup-bonus__eyebrow {
    margin: 0;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: #fde68a;
}
.signup-bonus__line {
    margin: 1px 0 0;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    column-gap: 8px;
}
.signup-bonus__amount {
    font-size: 24px;
    font-weight: 900;
    line-height: 1;
    background: linear-gradient(180deg, #fffbeb 0%, #fde047 45%, #f59e0b 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    filter: drop-shadow(0 1px 4px rgba(245, 158, 11, .45));
}
.signup-bonus__text {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
}
.signup-bonus__note {
    display: inline-block;
    margin-top: 4px;
    padding: 1px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    color: #fef3c7;
    background: rgba(0, 0, 0, .35);
    border: 1px solid rgba(253, 224, 71, .35);
}
.signup-bonus__shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, .22) 50%, transparent 65%);
    transform: translateX(-100%);
    animation: signup-bonus-shine 3.2s ease-in-out infinite;
    pointer-events: none;
}
.signup-bonus__spark {
    position: absolute;
    color: #fde68a;
    font-size: 12px;
    opacity: 0;
    animation: signup-bonus-twinkle 2.6s ease-in-out infinite;
    pointer-events: none;
}
.signup-bonus__spark--1 { top: 6px;    right: 12px; font-size: 10px; }
.signup-bonus__spark--2 { bottom: 6px; right: 44px; font-size: 8px; animation-delay: .9s; }
.signup-bonus__spark--3 { top: 18px;   right: 28px; font-size: 11px; animation-delay: 1.7s; }

@keyframes signup-bonus-glow {
    0%, 100% { box-shadow: 0 0 0 1px rgba(0, 0, 0, .4), 0 4px 14px rgba(234, 179, 8, .18); }
    50%      { box-shadow: 0 0 0 1px rgba(0, 0, 0, .4), 0 4px 20px rgba(234, 179, 8, .38); }
}
@keyframes signup-bonus-bounce {
    0%, 100% { transform: translateY(0) rotate(-4deg); }
    50%      { transform: translateY(-3px) rotate(4deg); }
}
@keyframes signup-bonus-shine {
    0%, 55% { transform: translateX(-100%); }
    100%    { transform: translateX(100%); }
}
@keyframes signup-bonus-twinkle {
    0%, 100% { opacity: 0; transform: scale(.6); }
    50%      { opacity: 1; transform: scale(1.1); }
}
@media (prefers-reduced-motion: reduce) {
    .signup-bonus, .signup-bonus__gift, .signup-bonus__shine, .signup-bonus__spark { animation: none; }
    .signup-bonus__spark { opacity: .7; }
}

/* ─── Auth split layout ──────────────────────────────────────────────────── */
.auth-split {
    display: flex;
    min-height: calc(100vh - 64px);
}

.auth-split__brand {
    flex: 0 0 45%;
    background-color: #000000;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 3rem;
}

.auth-split__logo {
    max-width: 320px;
    width: 80%;
    height: auto;
}

.auth-split__form {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 3rem;
    background-color: var(--uber-white);
}

.auth-split__inner {
    width: 100%;
    max-width: 400px;
}

.auth-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.auth-subtitle {
    color: var(--uber-body-gray);
    margin-bottom: 1.75rem;
}

/* ── Skeleton loader ── */
@keyframes skeleton-shimmer {
    0%   { background-position: -400px 0; }
    100% { background-position: 400px 0; }
}

.skeleton {
    background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
    background-size: 800px 100%;
    animation: skeleton-shimmer 1.4s ease-in-out infinite;
    border-radius: 4px;
    color: transparent !important;
    pointer-events: none;
    user-select: none;
}

.skeleton * { visibility: hidden !important; }

.skeleton-row {
    height: 20px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.skeleton-row--sm  { height: 12px; }
.skeleton-row--lg  { height: 32px; }
.skeleton-row--w50 { width: 50%; }
.skeleton-row--w75 { width: 75%; }

/* Player announcements - text bars shown right under the player navbar.
   Colour follows the audience: blue = all players, green = agent-targeted.
   Left-to-right gradient, dark to light; links render as pill buttons. */
.announcement-bar {
    --announcement-accent: #0a2f73;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 44px;
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
    text-align: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .25);
    overflow-wrap: anywhere;
}

.announcement-bar__viewport {
    min-width: 0;
    max-width: 960px;
}

.announcement-bar__close {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    padding: 0;
    border: 0;
    border-radius: var(--radius-circle);
    background: rgba(255, 255, 255, .25);
    color: var(--announcement-accent);
    cursor: pointer;
    transition: background .15s ease;
}

.announcement-bar__close:hover,
.announcement-bar__close:focus-visible {
    background: rgba(255, 255, 255, .6);
}

.announcement-bar--all {
    --announcement-accent: #0a2f73;
    background: linear-gradient(90deg, #0a2f73 0%, #1f5fd1 55%, #5c9cff 100%);
}

.announcement-bar--agents {
    --announcement-accent: #0a4d24;
    background: linear-gradient(90deg, #0a4d24 0%, #1a8a45 55%, #45c977 100%);
}

.announcement-link {
    display: inline-flex;
    align-items: center;
    margin: 2px 4px;
    padding: 3px 14px;
    border-radius: var(--radius-pill);
    background: #ffffff;
    color: var(--announcement-accent);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none;
    text-shadow: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .2);
    transition: transform .15s ease, box-shadow .15s ease;
    word-break: break-all;
}

.announcement-link:hover,
.announcement-link:focus-visible {
    color: var(--announcement-accent);
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, .25);
}

/* Pusoy Dos "you're at a table" banner (partials/_pusoy_away.html.twig). */
.announcement-bar--pusoy {
    --announcement-accent: #6b1010;
    flex-wrap: wrap;
    gap: 4px 10px;
    padding: 8px 16px;
    background: linear-gradient(90deg, #6b1010 0%, #b3261e 55%, #e8613c 100%);
}

.pusoy-away[hidden] {
    display: none;
}

.pusoy-away__players {
    opacity: .85;
}

.pusoy-away__leave {
    border: 0;
    cursor: pointer;
}

.pusoy-away__leave:disabled {
    opacity: .6;
    cursor: wait;
}

/* Mid-hand: the "go back to your hand?" popup. */
.pusoy-away-popup {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(0, 0, 0, .7);
}

.pusoy-away-popup[hidden] {
    display: none;
}

.pusoy-away-popup__card {
    width: min(380px, 100%);
    padding: 24px 20px 20px;
    border-radius: 16px;
    border: 1px solid rgba(233, 185, 73, .35);
    background: radial-gradient(120% 80% at 50% 0%, rgba(233, 185, 73, .14), transparent 60%), #0f1a16;
    color: #f3f4f6;
    text-align: center;
    box-shadow: 0 18px 50px rgba(0, 0, 0, .6);
}

.pusoy-away-popup__icon {
    font-size: 40px;
    line-height: 1;
}

.pusoy-away-popup__title {
    margin: 10px 0 4px;
    font-size: 20px;
    font-weight: 800;
    color: #e9b949;
}

.pusoy-away-popup__table {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 600;
    color: #d1d5db;
}

.pusoy-away-popup__text {
    margin: 0 0 6px;
    font-size: 15px;
}

.pusoy-away-popup__note {
    margin: 0 0 16px;
    font-size: 12px;
    color: #9ca3af;
}

.pusoy-away-popup__actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pusoy-away-popup__btn {
    display: block;
    width: 100%;
    padding: 12px;
    border-radius: 10px;
    font-weight: 800;
    letter-spacing: .04em;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.pusoy-away-popup__btn--return {
    border: 0;
    background: linear-gradient(180deg, #f4cf6a, #e9b949);
    color: #1a1206;
}

.pusoy-away-popup__btn--return:hover {
    color: #1a1206;
    filter: brightness(1.05);
}

.pusoy-away-popup__btn--leave {
    border: 1px solid rgba(255, 255, 255, .2);
    background: transparent;
    color: #d1d5db;
}

.pusoy-away-popup__btn--leave:disabled {
    opacity: .6;
    cursor: wait;
}

@media (max-width: 575.98px) {
    .announcement-bar {
        padding: 8px 40px 8px 12px;
        font-size: 13px;
    }

    .announcement-bar__close {
        right: 8px;
        width: 24px;
        height: 24px;
    }

    .announcement-link {
        font-size: 12px;
        padding: 2px 12px;
    }

    /* Mobile: one line per bar; overflowing messages scroll as a ticker
       (announcement_controller adds .is-ticker and sets --ticker-duration). */
    .announcement-bar__viewport {
        flex: 1;
        overflow: hidden;
    }

    .announcement-bar__text {
        display: inline-block;
        white-space: nowrap;
    }

    .announcement-bar__text br {
        display: none;
    }

    .announcement-bar.is-ticker .announcement-bar__viewport {
        text-align: left;
    }

    .announcement-bar.is-ticker .announcement-bar__text {
        padding-left: 100%;
        animation: announcement-ticker var(--ticker-duration, 12s) linear infinite;
    }

    .announcement-bar.is-ticker.is-paused .announcement-bar__text,
    .announcement-bar.is-ticker:hover .announcement-bar__text {
        animation-play-state: paused;
    }
}

@keyframes announcement-ticker {
    from { transform: translateX(0); }
    to   { transform: translateX(-100%); }
}

@media (max-width: 575.98px) and (prefers-reduced-motion: reduce) {
    .announcement-bar.is-ticker .announcement-bar__text {
        padding-left: 0;
        animation: none;
    }

    .announcement-bar.is-ticker .announcement-bar__viewport {
        overflow-x: auto;
    }
}

/* ─────────────────────────────────────────
   Seasonal theme (WFBO ▸ Settings ▸ Seasonal Theme)
   body.season--<theme>: accent colours, corner decorations and a
   drifting-particle layer. Nothing here takes a click, and everything sits
   under modals/toasts (1050+).
───────────────────────────────────────── */
.season {
    --season-a: #e9b949;
    --season-b: #ffffff;
}
.season--halloween  { --season-a: #f97316; --season-b: #a855f7; }
.season--christmas  { --season-a: #dc2626; --season-b: #16a34a; }
.season--new_year   { --season-a: #f5c542; --season-b: #e5e7eb; }
.season--valentines { --season-a: #f43f5e; --season-b: #f9a8d4; }

/* ── Seasonal navbar ──
   Each theme gives the navbar its own background, a garland hanging under it
   (::after, never takes a click), a small ornament on the logo and themed
   pills for the nav links / user chip. */
.season .navbar--dark {
    background: var(--season-nav);
    border-bottom: 2px solid var(--season-a);
}
.season .navbar--dark::after {
    content: var(--season-garland);
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 22px;
    overflow: hidden;
    white-space: nowrap;
    font-size: 14px;
    line-height: 22px;
    letter-spacing: 6px;
    text-align: center;
    pointer-events: none;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .35));
    animation: season-sway 3.2s ease-in-out infinite alternate;
    transform-origin: top center;
}
@keyframes season-sway { from { transform: rotate(-.4deg); } to { transform: rotate(.4deg); } }

/* Ornament on the logo. */
.season .navbar-brand-link { position: relative; }
.season .navbar-brand-link::after {
    content: var(--season-ornament);
    position: absolute;
    top: 2px;
    right: -14px;
    font-size: 18px;
    line-height: 1;
    pointer-events: none;
    animation: season-bob 2.4s ease-in-out infinite;
}
@keyframes season-bob { 50% { transform: translateY(-3px) rotate(8deg); } }

/* Nav links and the user chip pick up the theme. */
.season .nav-link--dark { color: rgba(255, 255, 255, .8); }
.season .nav-link--dark.is-active,
.season .navbar-user-chip {
    background: var(--season-pill);
    color: #fff;
    box-shadow: inset 0 0 0 1px var(--season-a), 0 0 10px -2px var(--season-a);
}

.season--halloween {
    --season-nav: linear-gradient(90deg, #12061f 0%, #2e1065 45%, #431407 100%);
    --season-pill: rgba(249, 115, 22, .22);
    --season-garland: '🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️ 🦇 🎃 🕸️';
    --season-ornament: '🕷️';
}
.season--christmas {
    --season-nav: linear-gradient(90deg, #052e16 0%, #14532d 45%, #7f1d1d 100%);
    --season-pill: rgba(220, 38, 38, .25);
    --season-garland: '🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵 🔴 🟡 🟢 🔵';
    --season-ornament: '🎅';
}
.season--new_year {
    --season-nav: linear-gradient(90deg, #0b1026 0%, #1e1b4b 50%, #0b1026 100%);
    --season-pill: rgba(245, 197, 66, .2);
    --season-garland: '✨ 🎉 ✨ 🎆 ✨ 🎊 ✨ 🥂 ✨ 🎉 ✨ 🎆 ✨ 🎊 ✨ 🥂 ✨ 🎉 ✨ 🎆 ✨ 🎊 ✨ 🥂 ✨ 🎉 ✨ 🎆 ✨ 🎊 ✨ 🥂 ✨ 🎉 ✨ 🎆 ✨ 🎊';
    --season-ornament: '✨';
}
.season--valentines {
    --season-nav: linear-gradient(90deg, #4c0519 0%, #9f1239 50%, #4c0519 100%);
    --season-pill: rgba(244, 63, 94, .25);
    --season-garland: '💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗 💕 💖 💘 💗';
    --season-ornament: '💘';
}

/* Christmas: snow piled on the navbar's top edge, and the lights twinkle. */
.season--christmas .navbar--dark::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 7px;
    pointer-events: none;
    background: radial-gradient(circle at 10px -2px, #fff 7px, transparent 8px) 0 0 / 22px 7px repeat-x;
    opacity: .9;
}
.season--christmas .navbar--dark::after { animation: season-sway 3.2s ease-in-out infinite alternate, season-twinkle 1.2s steps(2) infinite; }
@keyframes season-twinkle { 50% { opacity: .55; } }

/* New Year: a gold glint sweeps across the navbar. */
.season--new_year .navbar--dark {
    background: linear-gradient(110deg, transparent 40%, rgba(245, 197, 66, .22) 50%, transparent 60%) 0 0 / 250% 100%, var(--season-nav);
    animation: season-glint 6s linear infinite;
}
@keyframes season-glint { from { background-position: 150% 0, 0 0; } to { background-position: -100% 0, 0 0; } }

/* Corner decorations (emoji, no images). */
.season-decor { position: fixed; inset: 0; pointer-events: none; z-index: 1030; }
.season-decor__corner { position: absolute; bottom: 70px; font-size: 34px; line-height: 1; opacity: .9; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .3)); }
.season-decor__corner--left  { left: 8px; }
.season-decor__corner--right { right: 8px; }
.season--halloween  .season-decor__corner--left::after  { content: '🎃'; }
.season--halloween  .season-decor__corner--right::after { content: '🕸️'; }
.season--christmas  .season-decor__corner--left::after  { content: '🎄'; }
.season--christmas  .season-decor__corner--right::after { content: '🎁'; }
.season--new_year   .season-decor__corner--left::after  { content: '🥂'; }
.season--new_year   .season-decor__corner--right::after { content: '🎆'; }
.season--valentines .season-decor__corner--left::after  { content: '💝'; }
.season--valentines .season-decor__corner--right::after { content: '🌹'; }
@media (max-width: 640px) {
    .season-decor__corner { font-size: 24px; bottom: 78px; }
}

/* Particle layer. */
.season-effect { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 1029; }
.season-effect canvas { display: block; width: 100%; height: 100%; }
.season-particle {
    position: absolute;
    top: 0;
    will-change: transform;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    user-select: none;
}
.season--christmas .season-particle { color: #ffffff; text-shadow: 0 0 3px rgba(147, 197, 253, .6); }
.season-particle--fall    { animation-name: season-fall; }
.season-particle--rise    { animation-name: season-rise; top: auto; bottom: 0; }
.season-particle--flutter { animation-name: season-flutter; }
@keyframes season-fall {
    from { transform: translate3d(0, -40px, 0) rotate(0deg); }
    50%  { transform: translate3d(24px, 50vh, 0) rotate(180deg); }
    to   { transform: translate3d(-12px, 105vh, 0) rotate(360deg); }
}
@keyframes season-rise {
    from { transform: translate3d(0, 40px, 0) scale(.8); }
    50%  { transform: translate3d(-20px, -50vh, 0) scale(1); }
    to   { transform: translate3d(14px, -105vh, 0) scale(.9); }
}
/* Bats swoop side to side with a tilt (a scaleX flip squashes them edge-on). */
@keyframes season-flutter {
    0%   { transform: translate3d(0, -40px, 0) rotate(-12deg); }
    25%  { transform: translate3d(40px, 25vh, 0) rotate(14deg); }
    50%  { transform: translate3d(-30px, 50vh, 0) rotate(-12deg); }
    75%  { transform: translate3d(30px, 75vh, 0) rotate(14deg); }
    100% { transform: translate3d(0, 105vh, 0) rotate(-12deg); }
}
@media (prefers-reduced-motion: reduce) {
    .season-effect { display: none; }
    .season .navbar--dark,
    .season .navbar--dark::after,
    .season .navbar-brand-link::after { animation: none; }
}
