:root {
    /* Modern Font Stack */
    --primary-font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --secondary-font: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --mono-font: "JetBrains Mono", "Fira Code", "SF Mono", Monaco, Inconsolata, "Roboto Mono", "Courier New", monospace;
    --gaming-font: "Orbitron", "Inter", sans-serif;
    
    /* Enhanced Gaming Theme Colors */
    --theme-color: #ca2124;
    --theme-color-rgb: 202, 33, 36;
    --theme-secondary: #f59e0b;
    --theme-dark: #0f1419;
    --theme-darker: #0a0e13;

    /* Gaming Gradients */
    --gaming-gradient: linear-gradient(135deg, #ca2124, #f59e0b);
    --dark-gradient: linear-gradient(135deg, #0f1419, #1a202c);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    
    /* Surface Colors */
    --surface-primary: #ffffff;
    --surface-secondary: #f8fafc;
    --surface-dark: #1e293b;
    --surface-darker: #0f172a;
    
    /* Border & Shadow */
    --border-light: rgba(0, 0, 0, 0.08);
    --border-dark: rgba(255, 255, 255, 0.1);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-gaming: 0 0 20px rgba(202, 33, 36, 0.3);

    /* Typography Scale */
    --font-size-xs: 0.75rem;    /* 12px */
    --font-size-sm: 0.875rem;   /* 14px */
    --font-size-base: 1rem;     /* 16px */
    --font-size-lg: 1.125rem;   /* 18px */
    --font-size-xl: 1.25rem;    /* 20px */
    --font-size-2xl: 1.5rem;    /* 24px */
    --font-size-3xl: 1.875rem;  /* 30px */
    --font-size-4xl: 2.25rem;   /* 36px */
    
    /* Line Heights */
    --line-height-tight: 1.25;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.75;
    
    /* Letter Spacing */
    --letter-spacing-tight: -0.025em;
    --letter-spacing-normal: 0;
    --letter-spacing-wide: 0.025em;
}

/* Base Typography */
body, .modern-typography {
    font-family: var(--primary-font);
    font-weight: 400;
    line-height: var(--line-height-normal);
    letter-spacing: var(--letter-spacing-normal);
    font-feature-settings: "kern" 1, "liga" 1, "cv01" 1, "cv02" 1;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Enhanced Button Styling */
.btn {
    padding: 0.5rem 1.5rem;
    font-family: var(--primary-font);
    font-weight: 500;
    font-size: var(--font-size-sm);
    line-height: 1.4;
    letter-spacing: 0.025em;
    border-radius: 0.5rem;
    transition: all 0.15s ease-in-out;
    text-transform: none;
}

.btn-lg {
    padding: 0.75rem 2rem;
    font-size: var(--font-size-base);
    font-weight: 600;
}

.btn-sm {
    padding: 0.375rem 1rem;
    font-size: var(--font-size-xs);
}

/* Form Controls */
.form-control, .form-select {
    font-family: var(--primary-font);
    font-size: var(--font-size-sm);
    line-height: var(--line-height-normal);
    border-radius: 0.5rem;
    border: 1.5px solid #e2e8f0;
    padding: 0.625rem 1rem;
    transition: all 0.15s ease-in-out;
}

.form-control:focus, .form-select:focus {
    border-color: var(--theme-color);
    box-shadow: 0 0 0 3px rgba(202, 33, 36, 0.1);
    outline: none;
}

.form-label {
    font-family: var(--primary-font);
    font-weight: 500;
    font-size: var(--font-size-sm);
    color: #374151;
    margin-bottom: 0.5rem;
}

.form-text {
    font-size: var(--font-size-xs);
    color: #6b7280;
}

/* Modern Gaming Navigation */
.modern-nav {
    background: var(--dark-gradient);
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-lg);
    border-bottom: 1px solid var(--border-dark);
    padding: 0.75rem 0;
    transition: all 0.3s ease;
}

.gaming-brand {
    display: flex;
    align-items: center;
    text-decoration: none !important;
    transition: transform 0.2s ease;
}

.gaming-brand:hover {
    transform: scale(1.05);
}

.brand-logo {
    width: 40px;
    height: 40px;
    margin-right: 0.75rem;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.brand-text {
    font-family: var(--gaming-font);
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 0 10px rgba(202, 33, 36, 0.5);
}

.text-theme {
    color: var(--theme-color);
}

/* Enhanced Navigation Items */
.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
    position: relative;
}

/* Main Header Navigation Fixes */
.header-nav {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 20, 25, 0.98)) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.header-nav .navbar-brand {
    color: white !important;
}

.header-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    transition: all 0.2s ease;
}

.header-nav .nav-link:hover,
.header-nav .nav-link:focus {
    color: white !important;
    transform: translateY(-1px);
}

.header-nav .btn {
    border-radius: 25px;
    padding: 8px 20px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.header-nav .btn-custom-theme {
    background: var(--gaming-gradient) !important;
    border: none;
    color: white !important;
    box-shadow: 0 4px 15px rgba(202, 33, 36, 0.3);
}

.header-nav .btn-custom-theme:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(202, 33, 36, 0.4);
    color: white !important;
}

.header-nav .btn-outline-dark {
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white !important;
    background: transparent;
}

.header-nav .btn-outline-dark:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
    color: white !important;
    transform: translateY(-1px);
}

/* Dark Mode Toggle Button */
.header-nav .btn-dark {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white !important;
}

.header-nav .btn-dark:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    color: white !important;
    transform: translateY(-1px);
}

/* Search Input Styling */
.header-nav .form-control {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: 25px;
    padding: 10px 15px;
}

.header-nav .form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.header-nav .form-control:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--theme-color);
    color: white;
    box-shadow: 0 0 0 3px rgba(202, 33, 36, 0.2);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: white !important;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    transform: translateY(-1px);
}

.navbar-nav .nav-link.active::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 2px;
    background: var(--theme-color);
    border-radius: 1px;
}

/* Modern Dropdown */
.modern-dropdown {
    background: var(--surface-dark);
    border: 1px solid var(--border-dark);
    border-radius: 0.75rem;
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
    margin-top: 0.5rem;
    backdrop-filter: blur(20px);
}

.modern-dropdown .dropdown-item {
    color: rgba(255, 255, 255, 0.9);
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
    margin-bottom: 0.25rem;
}

.modern-dropdown .dropdown-item:hover {
    background: var(--glass-bg);
    color: white;
    transform: translateX(4px);
}

.modern-dropdown .dropdown-header {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.5rem 1rem 0.25rem;
}

/* Enhanced Search */
.navbar-search {
    position: relative;
    min-width: 320px;
}

.search-input {
    background: var(--glass-bg);
    border: 1px solid var(--border-dark);
    color: white;
    padding: 0.75rem 3rem 0.75rem 1rem;
    border-radius: 2rem;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.search-input:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--theme-color);
    box-shadow: 0 0 0 3px rgba(202, 33, 36, 0.2);
    color: white;
}

.search-btn {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: var(--theme-color);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.search-btn:hover {
    background: var(--theme-secondary);
    transform: translateY(-50%) scale(1.1);
}

/* Search Results Dropdown */
.search-results-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--surface-dark);
    border: 1px solid var(--border-dark);
    border-radius: 0.75rem;
    box-shadow: var(--shadow-lg);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    opacity: 0;
    transform: translateY(-10px);
    visibility: hidden;
    transition: all 0.2s ease;
    backdrop-filter: blur(20px);
    margin-top: 0.5rem;
}

.search-results-dropdown.show {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    color: rgba(255, 255, 255, 0.9);
}

.search-result-item:hover,
.search-result-item.highlighted {
    background: var(--glass-bg);
    color: white;
}

.search-result-item .game-icon {
    width: 32px;
    height: 32px;
    background: var(--theme-color);
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.75rem;
    color: white;
    font-size: 0.9rem;
}

.search-result-item .game-name {
    font-weight: 500;
    font-size: 0.9rem;
}

.search-loading,
.search-no-results {
    padding: 1rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

.search-loading .spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: var(--theme-color);
    animation: spin 1s ease-in-out infinite;
    margin-right: 0.5rem;
}

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

/* Wallet Indicator */
.wallet-indicator {
    display: flex;
    align-items: center;
    background: var(--glass-bg);
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-dark);
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

.wallet-balance {
    color: var(--theme-secondary);
}

/* User Menu */
.user-menu-btn {
    background: var(--glass-bg);
    border: 1px solid var(--border-dark);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    display: flex;
    align-items: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.user-menu-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    transform: translateY(-1px);
}

.user-avatar {
    width: 32px;
    height: 32px;
    background: var(--theme-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    margin-right: 0.5rem;
}

.user-name {
    font-weight: 500;
    font-size: 0.9rem;
}

/* Auth Buttons */
.auth-buttons .btn {
    padding: 0.5rem 1.5rem;
    border-radius: 2rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-theme {
    background: var(--gaming-gradient);
    border: none;
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-theme:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg), var(--shadow-gaming);
    color: white;
}

.navbar-brand {
    color: #000;
    font-family: var(--secondary-font);
    font-weight: 700;
    font-size: var(--font-size-xl);
}

.nav-link {
    color: #000;
    font-family: var(--primary-font);
    font-weight: 500;
    font-size: var(--font-size-sm);
    letter-spacing: 0.025em;
    transition: all 0.15s ease-in-out;
}

.nav-link:hover,
.nav-link:focus {
    color: var(--theme-color) !important;
    transform: translateY(-1px);
}

/* Enhanced Card Styling */
.card {
    border-radius: 0.75rem;
    border: none;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    transition: all 0.15s ease-in-out;
}

.card:hover {
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
}

.card-title {
    font-family: var(--secondary-font);
    font-weight: 600;
    color: #1f2937;
}

.card-body {
    padding: 1.5rem;
}

.footer-container {
    background: linear-gradient(135deg, #1a202c, #2d3748);
}

.my-10 {
    margin-top: 6rem;
    margin-bottom: 6rem;
}

.marquee {
    position: relative;
    width: 100vw;
    max-width: 100%;
    height: 3rem;
    overflow-x: hidden;
}

.track {
    position: absolute;
    align-self: anchor-center;
    white-space: nowrap;
    will-change: transform;
    animation: marquee 20s linear infinite;
}

.track.reverse {
    animation: marquee-reverse 20s linear infinite;
    text-align: right;
}

@keyframes marquee {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

@keyframes marquee-reverse {
    from {
        transform: translateX(-50%);
    }
    to {
        transform: translateX(0);
    }
}

/* THEME */
.bg-custom-theme {
    background-color: var(--theme-color);
}

.btn-custom-theme {
    background-color: var(--theme-color);
    color: #ffffff;
}

.text-custom-theme {
    color: var(--theme-color) !important;
}

/* Typography Classes */
.font-primary {
    font-family: var(--primary-font);
}

.font-secondary {
    font-family: var(--secondary-font);
}

.font-mono {
    font-family: var(--mono-font);
}

.font-gaming {
    font-family: var(--gaming-font);
    font-weight: 600;
    letter-spacing: var(--letter-spacing-wide);
}

/* Headings with better typography */
h1, .h1 {
    font-family: var(--secondary-font);
    font-weight: 700;
    line-height: var(--line-height-tight);
    letter-spacing: var(--letter-spacing-tight);
    font-size: var(--font-size-4xl);
}

h2, .h2 {
    font-family: var(--secondary-font);
    font-weight: 600;
    line-height: var(--line-height-tight);
    letter-spacing: var(--letter-spacing-tight);
    font-size: var(--font-size-3xl);
}

h3, .h3 {
    font-family: var(--secondary-font);
    font-weight: 600;
    line-height: var(--line-height-tight);
    font-size: var(--font-size-2xl);
}

h4, .h4 {
    font-family: var(--primary-font);
    font-weight: 600;
    line-height: var(--line-height-normal);
    font-size: var(--font-size-xl);
}

h5, .h5 {
    font-family: var(--primary-font);
    font-weight: 600;
    line-height: var(--line-height-normal);
    font-size: var(--font-size-lg);
}

h6, .h6 {
    font-family: var(--primary-font);
    font-weight: 500;
    line-height: var(--line-height-normal);
    font-size: var(--font-size-base);
    text-transform: uppercase;
    letter-spacing: var(--letter-spacing-wide);
}

/* Enhanced text utilities */
.text-lg {
    font-size: var(--font-size-lg);
    line-height: var(--line-height-relaxed);
}

.text-sm {
    font-size: var(--font-size-sm);
    line-height: var(--line-height-normal);
}

.text-xs {
    font-size: var(--font-size-xs);
    line-height: var(--line-height-normal);
}

.font-weight-light { font-weight: 300; }
.font-weight-normal { font-weight: 400; }
.font-weight-medium { font-weight: 500; }
.font-weight-semibold { font-weight: 600; }
.font-weight-bold { font-weight: 700; }
.font-weight-black { font-weight: 800; }

.letter-spacing-tight { letter-spacing: var(--letter-spacing-tight); }
.letter-spacing-normal { letter-spacing: var(--letter-spacing-normal); }
.letter-spacing-wide { letter-spacing: var(--letter-spacing-wide); }

/* Legacy support */
.font-dark-theme {
    font-family: var(--gaming-font);
    font-weight: 600;
    letter-spacing: var(--letter-spacing-wide);
}

.text-dark-theme {
    color: var(--dark-theme-color4);
}

.btn-dark-theme {
    background-color: var(--dark-theme-color3);
    color: #ffffff;
}

.bg-dark-theme4 {
    background: var(--dark-theme-color4);
}

.bg-dark-theme-gradient {
    background: linear-gradient(
        90deg,
        var(--dark-theme-color3) 0%,
        var(--dark-theme-color4) 100%
    );
}

.img-filter-dark-theme-gradient {
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0) 0%,
        var(--dark-theme-color4) 100%
    );
}

/* DARK MODE */
body.dark-mode {
    background-color: var(--dark-theme-color2);
    color: #fff;
}

body.dark-mode .header-nav {
    background: linear-gradient(135deg, rgba(15, 20, 25, 0.98), rgba(30, 41, 59, 0.95)) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

body.dark-mode .header-nav .navbar-brand {
    color: #fff !important;
}

body.dark-mode .header-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
}

body.dark-mode .header-nav .nav-link:hover {
    color: white !important;
}

body.dark-mode .footer-container {
    background: linear-gradient(135deg, #0f1419, #1a202c) !important;
}

body.dark-mode #register_btn {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 2px solid rgba(255, 255, 255, 0.3) !important;
    color: #fff !important;
}

body.dark-mode #register_btn:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    border-color: rgba(255, 255, 255, 0.5) !important;
}

/* .card.dark-mode {
    background-color: #23272b;
    color: #e0e0e0;
} */

/* Enhanced Alert Styling */
.alert {
    border-radius: 0.75rem;
    border: none;
    font-family: var(--primary-font);
    font-size: var(--font-size-sm);
    padding: 1rem 1.25rem;
}

.alert-success {
    background-color: #dcfce7;
    color: #166534;
}

.alert-danger {
    background-color: #fef2f2;
    color: #dc2626;
}

.alert-info {
    background-color: #dbeafe;
    color: #1d4ed8;
}

.alert-warning {
    background-color: #fef3c7;
    color: #d97706;
}

/* Enhanced Badge Styling */
.badge {
    font-family: var(--primary-font);
    font-weight: 500;
    font-size: var(--font-size-xs);
    letter-spacing: 0.025em;
    padding: 0.375rem 0.75rem;
    border-radius: 0.5rem;
}

/* Gaming/Special Elements */
.gaming-element {
    font-family: var(--gaming-font);
    font-weight: 600;
    letter-spacing: var(--letter-spacing-wide);
    text-transform: uppercase;
}

.price-display {
    font-family: var(--mono-font);
    font-weight: 600;
    font-size: var(--font-size-lg);
    letter-spacing: -0.025em;
}

.balance-display {
    font-family: var(--mono-font);
    font-weight: 700;
    font-size: var(--font-size-2xl);
    letter-spacing: -0.025em;
    color: var(--theme-color);
}

/* Table Styling */
.table {
    font-family: var(--primary-font);
    font-size: var(--font-size-sm);
}

.table th {
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: var(--font-size-xs);
    color: #6b7280;
    border-bottom: 2px solid #e5e7eb;
}

.table td {
    font-weight: 400;
    color: #374151;
    border-bottom: 1px solid #f3f4f6;
}

/* Enhanced Footer Styling */
.footer-container {
    font-family: var(--primary-font);
    background: linear-gradient(135deg, #1a202c, #2d3748) !important;
    position: relative;
    overflow: hidden;
}

.footer-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(202, 33, 36, 0.5), transparent);
}

.footer-container::after {
    content: '';
    position: absolute;
    top: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, 
        rgba(202, 33, 36, 0.1) 0%,
        rgba(202, 33, 36, 0.3) 25%,
        rgba(245, 158, 11, 0.3) 50%,
        rgba(202, 33, 36, 0.3) 75%,
        rgba(202, 33, 36, 0.1) 100%);
    filter: blur(1px);
}

.footer-container h5 {
    font-family: var(--secondary-font);
    font-weight: 600;
    font-size: var(--font-size-lg);
    margin-bottom: 1rem;
    color: white !important;
    position: relative;
}

.footer-container h5::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--gaming-gradient);
    border-radius: 1px;
}

.footer-container .text-white {
    color: rgba(255, 255, 255, 0.9) !important;
}

.footer-container .nav-link {
    color: rgba(255, 255, 255, 0.8) !important;
    transition: all 0.2s ease;
    padding: 0.25rem 0;
}

.footer-container .nav-link:hover {
    color: white !important;
    transform: translateX(5px);
}

.footer-container .text-custom-theme {
    color: var(--theme-secondary) !important;
    font-weight: 600;
}

/* Payment Icons Styling */
.footer-container .nav-link img {
    border-radius: 8px;
    transition: all 0.2s ease;
    filter: grayscale(0.2) brightness(0.9);
}

.footer-container .nav-link:hover img {
    filter: grayscale(0) brightness(1);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* Footer Bottom */
.footer-container .border-bottom {
    border-color: rgba(255, 255, 255, 0.1) !important;
}

.footer-container p:last-child {
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* Search Results Dropdown Styling */
.search-results-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 0.5rem;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    z-index: 1050;
    max-height: 400px;
    overflow-y: auto;
    display: none;
}

.search-results-dropdown.show {
    display: block;
}

.search-result-item {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f8f9fa;
    cursor: pointer;
    transition: background-color 0.2s ease;
    font-family: var(--primary-font);
    display: flex;
    align-items: center;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-item.highlighted {
    background-color: var(--theme-color);
    color: white;
}

.search-result-item .game-icon {
    width: 32px;
    height: 32px;
    background: #f8f9fa;
    border-radius: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.75rem;
    color: #6c757d;
}

.search-result-item.highlighted .game-icon {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.search-result-item .game-info {
    flex: 1;
}

.search-result-item .game-name {
    font-weight: 600;
    font-size: var(--font-size-sm);
    margin: 0;
}

.search-no-results {
    padding: 1rem;
    text-align: center;
    color: #6c757d;
    font-style: italic;
    font-family: var(--primary-font);
}

.search-loading {
    padding: 1rem;
    text-align: center;
    color: #6c757d;
    font-family: var(--primary-font);
}

.search-loading .spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--theme-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 0.5rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Search input focus styling */
#search-input:focus {
    border-color: var(--theme-color);
    box-shadow: 0 0 0 0.25rem rgba(var(--theme-color-rgb), 0.25);
}

/* Dark mode search styling */
.dark-mode .search-results-dropdown {
    background: #2d3748;
    border-color: #4a5568;
    color: white;
}

.dark-mode .search-result-item {
    border-color: #4a5568;
}

.dark-mode .search-result-item:hover {
    background-color: #4a5568;
}

.dark-mode .search-result-item .game-icon {
    background: #4a5568;
    color: #a0aec0;
}

.dark-mode .search-no-results,
.dark-mode .search-loading {
    color: #a0aec0;
}

/* Dark Mode Order Form Styling */
body.dark-mode .card {
    background-color: #1e293b !important;
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

body.dark-mode .card-title {
    color: white !important;
}

body.dark-mode .card-header {
    background-color: #0f172a !important;
    border-color: rgba(255, 255, 255, 0.1);
    color: white;
}

body.dark-mode .card-body {
    background-color: #1e293b !important;
    color: white;
}

body.dark-mode .form-label,
body.dark-mode label {
    color: rgba(255, 255, 255, 0.9) !important;
}

body.dark-mode .form-text,
body.dark-mode .form-text.text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

body.dark-mode .text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

body.dark-mode .form-control,
body.dark-mode .form-select {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
}

body.dark-mode .form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

body.dark-mode .form-control:focus,
body.dark-mode .form-select:focus {
    background-color: rgba(255, 255, 255, 0.15);
    border-color: var(--theme-color);
    color: white;
    box-shadow: 0 0 0 3px rgba(202, 33, 36, 0.2);
}

/* Product selection styling */
body.dark-mode .product-option {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
}

body.dark-mode .product-option:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

body.dark-mode .product-option.selected {
    background-color: var(--theme-color);
    border-color: var(--theme-color);
    color: white;
}

/* Payment method styling */
body.dark-mode .payment-method {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    color: white;
}

body.dark-mode .payment-method:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

body.dark-mode .payment-method.selected {
    background-color: var(--theme-color);
    border-color: var(--theme-color);
    color: white;
}

/* Alert styling in dark mode */
body.dark-mode .alert {
    border-color: rgba(255, 255, 255, 0.2);
}

body.dark-mode .alert-info {
    background-color: rgba(13, 110, 253, 0.1);
    border-color: rgba(13, 110, 253, 0.2);
    color: #b3d7ff;
}

body.dark-mode .alert-danger {
    background-color: rgba(220, 38, 38, 0.1);
    border-color: rgba(220, 38, 38, 0.2);
    color: #fca5a5;
}

body.dark-mode .alert-success {
    background-color: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.2);
    color: #86efac;
}

body.dark-mode .alert-link {
    color: var(--theme-color) !important;
}

/* Price display styling */
body.dark-mode #diamond-amount,
body.dark-mode #price-amount {
    color: black !important;
}

body.dark-mode #diamond-amount p,
body.dark-mode #price-amount h5 {
    color: black !important;
}

body.dark-mode #pay-button {
    color: black;
    border: solid 1px black;
}

/* Fix for the price display container */
body.dark-mode .text-end p,
body.dark-mode .text-end h5 {
    color: white !important;
}

/* Ensure all price-related elements are visible */
body.dark-mode .me-3 p,
body.dark-mode .me-3 h5,
body.dark-mode .mb-0 {
    color: white !important;
}

/* Small text and additional elements */
body.dark-mode small {
    color: rgba(255, 255, 255, 0.7) !important;
}

body.dark-mode .text-success {
    color: #10b981 !important;
}

body.dark-mode .text-danger {
    color: #ef4444 !important;
}

body.dark-mode .fw-bold {
    color: white;
}

/* Comprehensive price display fix */
body.dark-mode .d-flex.justify-content-end .me-3 {
    color: white !important;
}

body.dark-mode .d-flex.justify-content-end .me-3 * {
    color: white !important;
}

/* Target the specific price display elements */
body.dark-mode p#diamond-amount,
body.dark-mode h5#price-amount {
    color: black !important;
    opacity: 1 !important;
}

/* Override any Bootstrap text colors in dark mode */
body.dark-mode .text-end {
    color: white !important;
}

body.dark-mode .text-end * {
    color: white !important;
}

/* Ultra-specific price display targeting */
body.dark-mode .d-flex.justify-content-end.align-items-center .me-3 p.mb-0.text-end,
body.dark-mode .d-flex.justify-content-end.align-items-center .me-3 h5.mb-0.text-end {
    color: white !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Force visibility for all elements in the price container */
body.dark-mode .d-flex.justify-content-end.align-items-center .me-3 {
    background-color: rgba(255, 255, 255, 0.05);
    padding: 10px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode .d-flex.justify-content-end.align-items-center .me-3 p,
body.dark-mode .d-flex.justify-content-end.align-items-center .me-3 h5 {
    color: white !important;
    text-shadow: none !important;
    font-weight: bold !important;
}

/* Most aggressive targeting for diamond-amount and price-amount */
body.dark-mode p[id="diamond-amount"],
body.dark-mode h5[id="price-amount"] {
    color: black !important;
    background-color: rgba(255, 255, 255, 0.1) !important;
    padding: 5px 10px !important;
    border-radius: 4px !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Even more specific selectors */
body.dark-mode #diamond-amount,
body.dark-mode #price-amount {
    color: black !important;
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    padding: 8px 12px !important;
    border-radius: 6px !important;
    margin: 2px 0 !important;
}



/* Force style attribute override */
body.dark-mode [id="diamond-amount"][style],
body.dark-mode [id="price-amount"][style] {
    color: black !important;
}

/* Responsive Typography */
@media (max-width: 768px) {
    h1, .h1 { font-size: var(--font-size-3xl); }
    h2, .h2 { font-size: var(--font-size-2xl); }
    h3, .h3 { font-size: var(--font-size-xl); }
    
    .balance-display {
        font-size: var(--font-size-xl);
    }
    
    .btn-lg {
        padding: 0.625rem 1.5rem;
        font-size: var(--font-size-sm);
    }
    
    .search-results-dropdown {
        max-height: 300px;
    }
    
    .search-result-item {
        padding: 0.5rem 0.75rem;
    }
}

/* .btn-custom-theme.dark-mode {
    background-color: #444 !important;
    color: #fff !important;
} */
