/* ============================================
   TRICKSFOR GAMING UI - MODERN THEME
   A modern, gaming-focused Bootstrap 5 theme
   ============================================ */

/* Import Google Fonts for gaming aesthetic */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Orbitron:wght@400;500;600;700;800;900&display=swap');

html, body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6, .display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
    font-family: 'Orbitron', 'Inter', sans-serif;
    font-weight: 600;
    letter-spacing: 0.5px;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #00d4ff;
    transition: all 0.2s ease;
}

a:hover {
    color: #ffd700;
}

/* Primary Button - Gaming Gold Gradient */
.btn-primary {
    color: #000;
    background: linear-gradient(135deg, #ffd700 0%, #ffaa00 50%, #ff8c00 100%);
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    color: #000;
    background: linear-gradient(135deg, #ffe44d 0%, #ffbb33 50%, #ff9d00 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 215, 0, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Secondary Button - Cyber Blue */
.btn-secondary {
    background: linear-gradient(135deg, #1e3a5f 0%, #0d2137 100%);
    border: 1px solid #00d4ff;
    color: #00d4ff;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
    color: #000;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}

/* Success Button - Neon Green */
.btn-success {
    background: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%);
    border: none;
    color: #000;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0, 255, 136, 0.3);
}

.btn-success:hover {
    background: linear-gradient(135deg, #33ff9f 0%, #00e676 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 255, 136, 0.4);
}

/* Danger Button - Red Alert */
.btn-danger {
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    border: none;
    box-shadow: 0 4px 15px rgba(255, 68, 68, 0.3);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #ff6666 0%, #e60000 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 68, 68, 0.4);
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 212, 255, 0.25);
}

.content {
    padding-top: 1.1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 2px solid #00ff88;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.2);
}

.invalid {
    outline: 2px solid #ff4444;
    box-shadow: 0 0 10px rgba(255, 68, 68, 0.2);
}

.validation-message {
    color: #ff4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

#blazor-error-ui {
    color-scheme: light only;
    background: linear-gradient(135deg, #ff4444, #cc0000);
    bottom: 0;
    box-shadow: 0 -4px 20px rgba(255, 68, 68, 0.4);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.75rem 1.5rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
    border-top: 2px solid #ff6666;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, linear-gradient(135deg, #ff4444, #cc0000);
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
    border-radius: 0.5rem;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

/* Modern Loading Animation */
.loading-progress {
    position: absolute;
    display: block;
    width: 8rem;
    height: 8rem;
    inset: 20vh 0 auto 0;
    margin: 0 auto 0 auto;
}

    .loading-progress circle {
        fill: none;
        stroke: rgba(0, 212, 255, 0.2);
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: url(#gradient) #00d4ff;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
            filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.5));
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: 700;
    font-family: 'Orbitron', sans-serif;
    color: #00d4ff;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #ff6b9d;
    background: rgba(255, 107, 157, 0.1);
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ============================================
   GAMING COLOR PALETTE
   ============================================ */
:root {
    /* Primary Gaming Colors */
    --gaming-gold: #ffd700;
    --gaming-gold-light: #ffe44d;
    --gaming-gold-dark: #cc9900;
    --gaming-cyan: #00d4ff;
    --gaming-cyan-light: #33ddff;
    --gaming-cyan-dark: #0099cc;
    --gaming-green: #00ff88;
    --gaming-green-light: #33ff9f;
    --gaming-green-dark: #00cc6a;
    --gaming-red: #ff4444;
    --gaming-red-light: #ff6666;
    --gaming-red-dark: #cc0000;
    --gaming-purple: #a855f7;
    --gaming-purple-light: #c084fc;
    --gaming-purple-dark: #7c3aed;
    
    /* Background Colors */
    --gaming-bg-primary: #0a0e17;
    --gaming-bg-secondary: #111827;
    --gaming-bg-card: #1a1f2e;
    --gaming-bg-elevated: #252b3d;
    
    /* Text Colors */
    --gaming-text-primary: #f8fafc;
    --gaming-text-secondary: #94a3b8;
    --gaming-text-muted: #64748b;
    
    /* Border Colors */
    --gaming-border: rgba(255, 255, 255, 0.1);
    --gaming-border-accent: rgba(0, 212, 255, 0.3);
    
    /* Gradients */
    --gaming-gradient-gold: linear-gradient(135deg, #ffd700 0%, #ffaa00 50%, #ff8c00 100%);
    --gaming-gradient-cyan: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
    --gaming-gradient-green: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%);
    --gaming-gradient-red: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    --gaming-gradient-purple: linear-gradient(135deg, #a855f7 0%, #7c3aed 100%);
    --gaming-gradient-dark: linear-gradient(180deg, #1a1f2e 0%, #0a0e17 100%);
    
    /* Legacy variables for backward compatibility */
    --app-primary-color: #00d4ff;
    --app-warning-darker: #ffd700;
    --app-danger-darker: #ff4444;
    --app-text-color: #f8fafc;
    --app-bg-color: #0a0e17;
    --app-card-bg: #1a1f2e;
    --app-border-color: rgba(255, 255, 255, 0.1);
}

/* ============================================
   DARK THEME - GAMING STYLE
   ============================================ */
[data-bs-theme="dark"] {
    --bs-body-bg: var(--gaming-bg-primary);
    --bs-body-color: var(--gaming-text-primary);
    --bs-card-bg: var(--gaming-bg-card);
    --bs-border-color: var(--gaming-border);
    --bs-secondary-bg: var(--gaming-bg-secondary);
    --bs-tertiary-bg: var(--gaming-bg-elevated);
}

[data-bs-theme="dark"] body {
    background: var(--gaming-gradient-dark);
}

/* ============================================
   LIGHT THEME
   ============================================ */
[data-bs-theme="light"] {
    --bs-body-bg: #f0f4f8;
    --bs-body-color: #1e293b;
    --bs-card-bg: #ffffff;
    --bs-border-color: #e2e8f0;
}

[data-bs-theme="light"] .navbar-dark {
    background: linear-gradient(135deg, #ffffff, #f8fafc) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

[data-bs-theme="light"] .navbar-dark .navbar-brand,
[data-bs-theme="light"] .navbar-dark .nav-link,
[data-bs-theme="light"] .navbar-dark h1 {
    color: #1e293b !important;
}

[data-bs-theme="light"] .bg-dark {
    background: linear-gradient(135deg, #ffffff, #f8fafc) !important;
}

[data-bs-theme="light"] .text-light {
    color: #1e293b !important;
}

[data-bs-theme="light"] .app-sidebar {
    background: linear-gradient(180deg, #ffffff, #f8fafc) !important;
}

[data-bs-theme="light"] .sidebar-nav .nav-link {
    color: #475569;
}

[data-bs-theme="light"] .sidebar-nav .nav-link:hover {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.1), rgba(168, 85, 247, 0.1));
    color: #0099cc;
}

[data-bs-theme="light"] .gaming-card {
    background: #ffffff;
    border-color: #e2e8f0;
}

[data-bs-theme="light"] .stat-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
}

/* ============================================
   THEME-AWARE COMPONENT STYLES
   ============================================ */

/* Main Container - respects theme */
.app-main-container {
    background: var(--bs-body-bg);
    transition: background 0.3s ease;
}

[data-bs-theme="dark"] .app-main-container {
    background: linear-gradient(180deg, #0a0e17 0%, #111827 100%);
}

[data-bs-theme="light"] .app-main-container {
    background: linear-gradient(180deg, #f0f4f8 0%, #e2e8f0 100%);
}

/* Navbar - theme aware */
.app-navbar-themed {
    border-bottom: 1px solid var(--bs-border-color);
    transition: all 0.3s ease;
}

[data-bs-theme="dark"] .app-navbar-themed {
    background: linear-gradient(135deg, #0a0e17 0%, #111827 100%);
    border-bottom-color: rgba(0, 212, 255, 0.2);
}

[data-bs-theme="light"] .app-navbar-themed {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-bottom-color: #e2e8f0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Sidebar toggle button */
.sidebar-toggle-btn {
    width: 40px;
    height: 40px;
    transition: all 0.3s ease;
}

[data-bs-theme="dark"] .sidebar-toggle-btn {
    border-color: rgba(0, 212, 255, 0.3);
}

[data-bs-theme="dark"] .sidebar-toggle-btn i {
    color: #00d4ff;
}

[data-bs-theme="light"] .sidebar-toggle-btn {
    border-color: #cbd5e1;
}

[data-bs-theme="light"] .sidebar-toggle-btn i {
    color: #475569;
}

/* Theme toggle button */
.theme-toggle-btn {
    width: 40px;
    height: 40px;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

[data-bs-theme="dark"] .theme-toggle-btn {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.1), rgba(168, 85, 247, 0.1));
    border: 1px solid rgba(0, 212, 255, 0.3);
}

[data-bs-theme="light"] .theme-toggle-btn {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.1), rgba(0, 212, 255, 0.1));
    border: 1px solid #cbd5e1;
}

/* Brand title */
.brand-title {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    background: linear-gradient(135deg, #00d4ff, #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Sidebar - theme aware */
.sidebar-themed {
    transition: all 0.3s ease;
}

[data-bs-theme="dark"] .sidebar-themed {
    background: linear-gradient(180deg, #0a0e17 0%, #111827 100%);
    border-right: 1px solid rgba(0, 212, 255, 0.1);
}

[data-bs-theme="light"] .sidebar-themed {
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    border-right: 1px solid #e2e8f0;
}

/* Footer - theme aware */
.app-footer-themed {
    transition: all 0.3s ease;
}

[data-bs-theme="dark"] .app-footer-themed {
    background: linear-gradient(135deg, #0a0e17 0%, #111827 100%);
    border-top: 1px solid rgba(0, 212, 255, 0.1);
}

[data-bs-theme="light"] .app-footer-themed {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-top: 1px solid #e2e8f0;
}

.footer-text {
    font-size: 0.875rem;
}

[data-bs-theme="dark"] .footer-text {
    color: #64748b;
}

[data-bs-theme="light"] .footer-text {
    color: #475569;
}

.footer-link {
    text-decoration: none;
    font-weight: 500;
}

[data-bs-theme="dark"] .footer-link {
    color: #00d4ff;
}

[data-bs-theme="light"] .footer-link {
    color: #0099cc;
}

/* Nav link text colors */
.sidebar-nav .nav-link {
    transition: all 0.2s ease;
}

[data-bs-theme="dark"] .sidebar-nav .nav-link {
    color: #94a3b8 !important;
}

[data-bs-theme="light"] .sidebar-nav .nav-link {
    color: #475569 !important;
}

[data-bs-theme="dark"] .sidebar-nav .nav-link.active,
[data-bs-theme="dark"] .sidebar-nav .nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff !important;
}

[data-bs-theme="light"] .sidebar-nav .nav-link.active,
[data-bs-theme="light"] .sidebar-nav .nav-link:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #1e293b !important;
}

/* Submenu text colors */
[data-bs-theme="dark"] .sidebar-nav .nav-link.small {
    color: #64748b !important;
}

[data-bs-theme="light"] .sidebar-nav .nav-link.small {
    color: #64748b !important;
}

/* Main content area */
.main-content {
    transition: background 0.3s ease;
}

[data-bs-theme="dark"] .main-content {
    color: #f8fafc;
}

[data-bs-theme="light"] .main-content {
    color: #1e293b;
}

/* App layout */
.app-layout {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.app-header {
    background-color: var(--bs-dark, #212529);
    border-bottom: 1px solid var(--bs-border-color);
}

.app-sidebar {
    background-color: var(--bs-dark, #212529);
    width: 250px;
    min-height: calc(100vh - 56px);
    transition: transform 0.3s ease;
}

.app-sidebar.collapsed {
    transform: translateX(-100%);
}

@media (max-width: 768px) {
    .app-sidebar {
        position: fixed;
        top: 56px;
        left: 0;
        z-index: 1030;
    }
    .app-sidebar.collapsed {
        transform: translateX(-100%);
    }
}

.app-body {
    flex: 1;
    padding: 1rem;
}

.app-footer {
    background-color: var(--bs-dark, #212529);
    border-top: 1px solid var(--bs-border-color);
    padding: 1rem;
    text-align: center;
}

/* Sidebar navigation */
.sidebar-nav {
    padding: 0;
    list-style: none;
}

.sidebar-nav .nav-item {
    margin-bottom: 0.25rem;
}

.sidebar-nav .nav-link {
    color: #d7d7d7;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: 0.375rem;
    text-decoration: none;
}

.sidebar-nav .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.sidebar-nav .nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.sidebar-nav .nav-item-dropdown .dropdown-menu {
    background-color: var(--bs-dark, #212529);
    border-color: var(--bs-border-color);
}

.sidebar-nav .nav-item-dropdown .dropdown-item {
    color: #d7d7d7;
}

.sidebar-nav .nav-item-dropdown .dropdown-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

/* Toast notifications */
.toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1100;
}

/* Modal/Dialog Styles for side panel */
.offcanvas-bottom {
    height: auto;
    max-height: 90vh;
}

/* Card and content styling */
.card-dark {
    background-color: var(--bs-dark, #212529);
    border-color: var(--bs-border-color);
}

/* Link styling */
.link-active {
    cursor: pointer;
    color: var(--bs-primary);
    text-decoration: underline;
}

.link-active:hover {
    color: var(--bs-info);
}

/* Text truncation */
.text-truncate-custom {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Game card images */
.game-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
}

.token-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.token-avatar-sm {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
}

/* DataList/Grid styling */
.data-list-item {
    padding: 0.75rem;
    border-bottom: 1px solid var(--bs-border-color);
}

.data-list-item:last-child {
    border-bottom: none;
}

/* Button light variant for dark theme */
.btn-outline-light {
    border-color: rgba(255, 255, 255, 0.3);
}

.btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Alert styling */
.alert-terminology {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: var(--bs-border-color);
    color: var(--bs-body-color);
}

/* Form field styling */
.form-field-with-icon {
    position: relative;
}

.form-field-with-icon .input-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
}

.form-field-with-icon input {
    padding-left: 2.5rem;
}

/* Color variations */
.text-warning-darker {
    color: var(--app-warning-darker) !important;
}

.text-danger-darker {
    color: var(--app-danger-darker) !important;
}

.text-primary-darker {
    color: var(--app-primary-color) !important;
}

/* Bootstrap Icons button styling */
.btn i.bi {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* Ensure icons in buttons are properly sized and positioned */
.navbar .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.navbar .btn i.bi {
    font-size: 1.25rem;
}

/* Fix sidebar nav icons alignment */
.sidebar-nav .nav-link i.bi {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.25rem;
    height: 1.25rem;
}

/* Mobile sidebar overlay */
@media (max-width: 767.98px) {
    .sidebar-spacer {
        display: none !important;
    }
    
    .app-sidebar {
        z-index: 1050 !important;
    }
    
    /* Semi-transparent overlay behind sidebar when open on mobile */
    .sidebar-overlay {
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 1040;
        display: none;
    }
    
    .sidebar-overlay.show {
        display: block;
    }
}

/* ============================================
   GAMING UI COMPONENTS
   ============================================ */

/* Gaming Card - Modern card with glow effects */
.gaming-card {
    background: var(--gaming-bg-card);
    border: 1px solid var(--gaming-border);
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.gaming-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gaming-gradient-cyan);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gaming-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 212, 255, 0.15);
    border-color: var(--gaming-border-accent);
}

.gaming-card:hover::before {
    opacity: 1;
}

/* Gaming Card Variants */
.gaming-card-gold::before {
    background: var(--gaming-gradient-gold);
}

.gaming-card-gold:hover {
    box-shadow: 0 12px 40px rgba(255, 215, 0, 0.15);
}

.gaming-card-green::before {
    background: var(--gaming-gradient-green);
}

.gaming-card-green:hover {
    box-shadow: 0 12px 40px rgba(0, 255, 136, 0.15);
}

.gaming-card-red::before {
    background: var(--gaming-gradient-red);
}

.gaming-card-red:hover {
    box-shadow: 0 12px 40px rgba(255, 68, 68, 0.15);
}

.gaming-card-purple::before {
    background: var(--gaming-gradient-purple);
}

.gaming-card-purple:hover {
    box-shadow: 0 12px 40px rgba(168, 85, 247, 0.15);
}

/* Stat Cards - Dashboard statistics display */
.stat-card {
    background: linear-gradient(135deg, var(--gaming-bg-card) 0%, var(--gaming-bg-elevated) 100%);
    border: 1px solid var(--gaming-border);
    border-radius: 1rem;
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.stat-card-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    font-size: 1.5rem;
    background: var(--gaming-gradient-cyan);
    color: #000;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
}

.stat-card-icon.gold {
    background: var(--gaming-gradient-gold);
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.stat-card-icon.green {
    background: var(--gaming-gradient-green);
    box-shadow: 0 4px 15px rgba(0, 255, 136, 0.3);
}

.stat-card-icon.red {
    background: var(--gaming-gradient-red);
    box-shadow: 0 4px 15px rgba(255, 68, 68, 0.3);
    color: #fff;
}

.stat-card-icon.purple {
    background: var(--gaming-gradient-purple);
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.3);
    color: #fff;
}

.stat-value {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--gaming-text-primary);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gaming-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 0.25rem;
}

/* Game Timer - Countdown display */
.game-timer {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    padding: 1rem 2rem;
    border-radius: 1rem;
    background: var(--gaming-bg-elevated);
    border: 2px solid var(--gaming-border);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}

.game-timer::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(0, 212, 255, 0.1), transparent);
    animation: timer-shimmer 2s infinite;
}

@keyframes timer-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.game-timer.warning {
    border-color: var(--gaming-gold);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.2);
}

.game-timer.danger {
    border-color: var(--gaming-red);
    box-shadow: 0 0 20px rgba(255, 68, 68, 0.2);
    animation: pulse-danger 1s infinite;
}

@keyframes pulse-danger {
    0%, 100% { box-shadow: 0 0 20px rgba(255, 68, 68, 0.2); }
    50% { box-shadow: 0 0 30px rgba(255, 68, 68, 0.4); }
}

/* Win/Lose Badges */
.badge-win {
    background: var(--gaming-gradient-green);
    color: #000;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-lose {
    background: var(--gaming-gradient-red);
    color: #fff;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-draw {
    background: linear-gradient(135deg, #64748b 0%, #475569 100%);
    color: #fff;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-pending {
    background: var(--gaming-gradient-gold);
    color: #000;
    font-weight: 600;
    padding: 0.375rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Gaming Glow Text */
.glow-text-cyan {
    color: var(--gaming-cyan);
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5), 0 0 20px rgba(0, 212, 255, 0.3);
}

.glow-text-gold {
    color: var(--gaming-gold);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5), 0 0 20px rgba(255, 215, 0, 0.3);
}

.glow-text-green {
    color: var(--gaming-green);
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.5), 0 0 20px rgba(0, 255, 136, 0.3);
}

.glow-text-red {
    color: var(--gaming-red);
    text-shadow: 0 0 10px rgba(255, 68, 68, 0.5), 0 0 20px rgba(255, 68, 68, 0.3);
}

/* Animated Progress Bars */
.progress-gaming {
    background: var(--gaming-bg-secondary);
    border-radius: 1rem;
    height: 0.75rem;
    overflow: hidden;
}

.progress-gaming .progress-bar {
    background: var(--gaming-gradient-cyan);
    border-radius: 1rem;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.progress-gaming .progress-bar::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: progress-shimmer 1.5s infinite;
}

@keyframes progress-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Betting Option Cards */
.bet-option-card {
    background: var(--gaming-bg-card);
    border: 2px solid var(--gaming-border);
    border-radius: 1rem;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.bet-option-card:hover {
    border-color: var(--gaming-cyan);
    transform: scale(1.02);
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.2);
}

.bet-option-card.selected {
    border-color: var(--gaming-gold);
    background: linear-gradient(135deg, var(--gaming-bg-card) 0%, rgba(255, 215, 0, 0.1) 100%);
    box-shadow: 0 8px 30px rgba(255, 215, 0, 0.2);
}

.bet-option-card.selected::before {
    content: '✓';
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 24px;
    height: 24px;
    background: var(--gaming-gradient-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 700;
    color: #000;
}

/* Modern Input Fields */
.form-control-gaming {
    background: var(--gaming-bg-secondary);
    border: 2px solid var(--gaming-border);
    border-radius: 0.75rem;
    color: var(--gaming-text-primary);
    padding: 0.875rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control-gaming:focus {
    background: var(--gaming-bg-elevated);
    border-color: var(--gaming-cyan);
    box-shadow: 0 0 0 4px rgba(0, 212, 255, 0.15);
    outline: none;
}

.form-control-gaming::placeholder {
    color: var(--gaming-text-muted);
}

/* Amount Input with Token */
.amount-input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.amount-input-group .form-control-gaming {
    padding-right: 5rem;
}

.amount-input-group .token-badge {
    position: absolute;
    right: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--gaming-text-secondary);
    font-weight: 500;
}

/* Quick Amount Buttons */
.quick-amount-btn {
    background: var(--gaming-bg-secondary);
    border: 1px solid var(--gaming-border);
    color: var(--gaming-text-secondary);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.quick-amount-btn:hover {
    background: var(--gaming-bg-elevated);
    border-color: var(--gaming-cyan);
    color: var(--gaming-cyan);
}

/* Rank Badge */
.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 0.875rem;
}

.rank-badge.gold {
    background: var(--gaming-gradient-gold);
    color: #000;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.rank-badge.silver {
    background: linear-gradient(135deg, #e2e8f0 0%, #94a3b8 100%);
    color: #1e293b;
    box-shadow: 0 4px 15px rgba(148, 163, 184, 0.3);
}

.rank-badge.bronze {
    background: linear-gradient(135deg, #f59e0b 0%, #b45309 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

/* Leaderboard Table */
.leaderboard-table {
    background: var(--gaming-bg-card);
    border-radius: 1rem;
    overflow: hidden;
}

.leaderboard-table thead {
    background: var(--gaming-bg-secondary);
}

.leaderboard-table th {
    color: var(--gaming-text-secondary);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    padding: 1rem;
    border: none;
}

.leaderboard-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--gaming-border);
    vertical-align: middle;
}

.leaderboard-table tbody tr {
    transition: background 0.2s ease;
}

.leaderboard-table tbody tr:hover {
    background: var(--gaming-bg-elevated);
}

.leaderboard-table tbody tr:last-child td {
    border-bottom: none;
}

/* User Avatar */
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gaming-gradient-cyan);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    color: #000;
}

/* Win Streak Counter */
.streak-counter {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2) 0%, rgba(255, 140, 0, 0.2) 100%);
    border: 1px solid var(--gaming-gold);
    border-radius: 2rem;
    padding: 0.375rem 0.75rem;
    font-family: 'Orbitron', sans-serif;
    font-weight: 600;
    color: var(--gaming-gold);
}

.streak-counter i {
    color: var(--gaming-gold);
}

/* Game Result Animation */
.result-reveal {
    animation: result-pop 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes result-pop {
    0% { transform: scale(0); opacity: 0; }
    80% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

/* Confetti Animation for Wins */
.win-celebration {
    position: relative;
}

.win-celebration::after {
    content: '🎉';
    position: absolute;
    top: -1rem;
    right: -1rem;
    font-size: 1.5rem;
    animation: celebration-bounce 0.5s ease infinite alternate;
}

@keyframes celebration-bounce {
    0% { transform: translateY(0) rotate(0deg); }
    100% { transform: translateY(-5px) rotate(15deg); }
}

/* Tooltip Gaming Style */
.tooltip-gaming {
    background: var(--gaming-bg-elevated);
    border: 1px solid var(--gaming-border-accent);
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--gaming-text-primary);
    font-size: 0.875rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

/* Notification Toast - Gaming Style */
.toast-gaming {
    background: var(--gaming-bg-card);
    border: 1px solid var(--gaming-border);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.toast-gaming.success {
    border-left: 4px solid var(--gaming-green);
}

.toast-gaming.error {
    border-left: 4px solid var(--gaming-red);
}

.toast-gaming.warning {
    border-left: 4px solid var(--gaming-gold);
}

.toast-gaming.info {
    border-left: 4px solid var(--gaming-cyan);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--gaming-bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--gaming-bg-elevated);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gaming-text-muted);
}

/* Selection Highlight */
::selection {
    background: rgba(0, 212, 255, 0.3);
    color: var(--gaming-text-primary);
}

/* Pulse Animation for Live Indicators */
.pulse-live {
    position: relative;
}

.pulse-live::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background: var(--gaming-green);
    border-radius: 50%;
    animation: pulse-live 1.5s infinite;
}

@keyframes pulse-live {
    0%, 100% { 
        box-shadow: 0 0 0 0 rgba(0, 255, 136, 0.7);
        opacity: 1;
    }
    50% { 
        box-shadow: 0 0 0 8px rgba(0, 255, 136, 0);
        opacity: 0.8;
    }
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--gaming-bg-card) 0%, var(--gaming-bg-primary) 100%);
    border-radius: 1.5rem;
    padding: 3rem 2rem;
    position: relative;
    overflow: hidden;
    margin-bottom: 2rem;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%2300d4ff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--gaming-cyan), var(--gaming-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.hero-subtitle {
    color: var(--gaming-text-secondary);
    font-size: 1.125rem;
    max-width: 600px;
}

/* CTA Button - Call to Action */
.btn-cta {
    background: var(--gaming-gradient-gold);
    color: #000;
    font-weight: 700;
    font-size: 1.125rem;
    padding: 1rem 2.5rem;
    border-radius: 3rem;
    border: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 30px rgba(255, 215, 0, 0.3);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s ease;
}

.btn-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(255, 215, 0, 0.4);
}

.btn-cta:hover::before {
    transform: translateX(100%);
}

/* Feature Cards */
.feature-card {
    background: var(--gaming-bg-card);
    border: 1px solid var(--gaming-border);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-8px);
    border-color: var(--gaming-border-accent);
    box-shadow: 0 20px 40px rgba(0, 212, 255, 0.1);
}

.feature-card-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--gaming-bg-secondary);
    border-radius: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

.feature-card-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gaming-text-primary);
    margin-bottom: 0.75rem;
}

.feature-card-description {
    color: var(--gaming-text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .hero-title {
        font-size: 1.75rem;
    }
    
    .stat-value {
        font-size: 1.25rem;
    }
    
    .game-timer {
        font-size: 1.5rem;
        padding: 0.75rem 1.5rem;
    }
    
    .btn-cta {
        font-size: 1rem;
        padding: 0.875rem 2rem;
    }
}

/* ============================================
   THEME-AWARE HOME PAGE CLASSES
   ============================================ */

/* Dashboard titles and text */
.dashboard-title {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    color: var(--gaming-text-primary);
}

.dashboard-subtitle {
    color: var(--gaming-text-secondary);
}

.section-title-themed {
    font-family: 'Orbitron', sans-serif;
    font-weight: 600;
    color: var(--gaming-text-primary);
}

.card-title-themed {
    color: var(--gaming-text-primary);
    margin-bottom: 0.5rem;
}

.card-text-muted {
    color: var(--gaming-text-secondary);
    margin-bottom: 0;
}

/* Token value display */
.token-value-small {
    color: var(--gaming-text-muted);
    font-size: 0.75rem;
}

/* Text colors for accents */
.text-gold {
    color: #ffd700 !important;
}

/* Clickable link styles with colors */
.link-active {
    cursor: pointer;
    text-decoration: none;
}

.link-active:hover {
    text-decoration: underline;
}

.link-cyan {
    color: #00d4ff !important;
}

.link-green {
    color: #00ff88 !important;
}

.link-red {
    color: #ff4444 !important;
}

.link-gold {
    color: #ffd700 !important;
}

.link-purple {
    color: #a855f7 !important;
}

/* Win rate value styling */
.win-rate-value {
    font-family: 'Orbitron', sans-serif;
    font-weight: 600;
}

.win-rate-value.positive {
    color: #00ff88;
}

.win-rate-value.negative {
    color: #ff4444;
}

/* Rank badge default style */
.rank-badge.default {
    background: rgba(0, 212, 255, 0.2);
    color: #00d4ff;
}

/* Game ladder row border */
.game-ladder-row {
    border-bottom: 1px solid var(--gaming-border);
}

/* Light theme adjustments */
[data-bs-theme="light"] .dashboard-title,
[data-bs-theme="light"] .section-title-themed,
[data-bs-theme="light"] .card-title-themed {
    color: #1e293b;
}

[data-bs-theme="light"] .dashboard-subtitle,
[data-bs-theme="light"] .card-text-muted {
    color: #64748b;
}

[data-bs-theme="light"] .token-value-small {
    color: #64748b;
}

[data-bs-theme="light"] .gaming-card {
    background: #ffffff;
    border-color: #e2e8f0;
}

[data-bs-theme="light"] .stat-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-color: #e2e8f0;
}

[data-bs-theme="light"] .game-ladder-row {
    border-bottom-color: #e2e8f0;
}

[data-bs-theme="light"] .stat-value {
    color: #1e293b;
}

[data-bs-theme="light"] .stat-label {
    color: #64748b;
}

/* Light theme - Hero Section */
[data-bs-theme="light"] .hero-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

[data-bs-theme="light"] .hero-subtitle {
    color: #64748b;
}

/* Light theme - Feature Cards */
[data-bs-theme="light"] .feature-card {
    background: #ffffff;
    border-color: #e2e8f0;
}

[data-bs-theme="light"] .feature-card:hover {
    border-color: #94a3b8;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

[data-bs-theme="light"] .feature-card-icon {
    background: #f1f5f9;
}

[data-bs-theme="light"] .feature-card-title {
    color: #1e293b;
}

[data-bs-theme="light"] .feature-card-description {
    color: #64748b;
}