/* ============================================
   CasinoBet — Dark Neon Casino Theme
   BC.Game / Stake inspired design
   ============================================ */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@400;500;600;700;800&display=swap');

/* ===== CSS Variables ===== */
:root {
    /* Colors */
    --bg-primary: #0a0a1a;
    --bg-secondary: #0f0f24;
    --bg-card: #151530;
    --bg-card-hover: #1a1a3e;
    --bg-sidebar: #0d0d20;
    --bg-input: #1a1a35;
    --bg-modal: rgba(0, 0, 0, 0.85);
    
    --text-primary: #ffffff;
    --text-secondary: #a0a0c0;
    --text-muted: #6060a0;
    --text-dim: #404070;
    
    --neon-green: #00ff88;
    --neon-blue: #00d4ff;
    --neon-purple: #a855f7;
    --neon-pink: #ff00aa;
    --neon-yellow: #ffd000;
    --neon-orange: #ff6b35;
    --neon-red: #ff3355;
    
    --gradient-primary: linear-gradient(135deg, #00ff88, #00d4ff);
    --gradient-secondary: linear-gradient(135deg, #a855f7, #ff00aa);
    --gradient-accent: linear-gradient(135deg, #ffd000, #ff6b35);
    --gradient-danger: linear-gradient(135deg, #ff3355, #ff0066);
    --gradient-dark: linear-gradient(180deg, #0f0f24 0%, #0a0a1a 100%);
    
    --border-color: rgba(255, 255, 255, 0.06);
    --border-glow: rgba(0, 255, 136, 0.3);
    
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.5);
    --shadow-glow-green: 0 0 20px rgba(0, 255, 136, 0.15);
    --shadow-glow-blue: 0 0 20px rgba(0, 212, 255, 0.15);
    --shadow-glow-purple: 0 0 20px rgba(168, 85, 247, 0.15);
    
    /* Sizing */
    --sidebar-width: 240px;
    --sidebar-collapsed: 64px;
    --topbar-height: 60px;
    --bottom-nav-height: 64px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 50px;
    
    /* Fonts */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-display: 'Outfit', 'Inter', sans-serif;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ===== Reset ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a { color: var(--neon-green); text-decoration: none; transition: color var(--transition-fast); }
a:hover { color: var(--neon-blue); }

img { max-width: 100%; height: auto; display: block; }

input, select, textarea, button {
    font-family: var(--font-primary);
    font-size: 14px;
    border: none;
    outline: none;
    background: none;
}

button { cursor: pointer; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--bg-card); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

/* ===== Layout ===== */
.app {
    display: flex;
    min-height: 100vh;
}

/* ===== Sidebar ===== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-normal);
    overflow-y: auto;
}

.sidebar-logo {
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-logo .logo-icon {
    width: 36px;
    height: 36px;
    background: var(--gradient-primary);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.sidebar-logo .logo-text {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-nav {
    flex: 1;
    padding: 12px 8px;
}

.nav-section {
    margin-bottom: 8px;
}

.nav-section-title {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-dim);
    padding: 12px 14px 6px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-fast);
    cursor: pointer;
    position: relative;
    margin: 2px 0;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.nav-item.active {
    background: rgba(0, 255, 136, 0.1);
    color: var(--neon-green);
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 24px;
    background: var(--neon-green);
    border-radius: 0 3px 3px 0;
}

.nav-item .nav-icon {
    width: 20px;
    text-align: center;
    font-size: 16px;
}

.nav-item .nav-badge {
    margin-left: auto;
    background: var(--neon-red);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: var(--radius-full);
    min-width: 18px;
    text-align: center;
}

/* ===== Main Content ===== */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ===== Top Bar ===== */
.topbar {
    height: var(--topbar-height);
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    padding: 0 20px;
    gap: 12px;
    position: sticky;
    top: 0;
    z-index: 900;
    backdrop-filter: blur(20px);
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.menu-toggle {
    display: none;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 20px;
    background: var(--bg-card);
}

.topbar-wallet {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-card);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
}

.topbar-wallet .wallet-icon {
    color: var(--neon-green);
    font-size: 16px;
}

.topbar-wallet .wallet-amount {
    font-weight: 700;
    font-size: 14px;
    color: var(--text-primary);
    font-family: var(--font-display);
}

.topbar-wallet .wallet-currency {
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 600;
}

.topbar-right {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
}

.topbar-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 600;
    transition: all var(--transition-fast);
}

.btn-deposit {
    background: var(--gradient-primary);
    color: #000;
}

.btn-deposit:hover {
    box-shadow: var(--shadow-glow-green);
    transform: translateY(-1px);
}

.btn-withdraw {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-withdraw:hover {
    border-color: var(--neon-blue);
    box-shadow: var(--shadow-glow-blue);
}

.topbar-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gradient-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: box-shadow var(--transition-fast);
}

.topbar-avatar:hover {
    box-shadow: var(--shadow-glow-purple);
}

/* ===== Page Content ===== */
.page-content {
    flex: 1;
    padding: 20px;
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
}

/* ===== Cards ===== */
.card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    padding: 20px;
    transition: all var(--transition-normal);
}

.card:hover {
    border-color: rgba(255, 255, 255, 0.1);
}

.card-glass {
    background: rgba(21, 21, 48, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* ===== Game Cards Grid ===== */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 14px;
}

.game-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    overflow: hidden;
    cursor: pointer;
    transition: all var(--transition-normal);
    position: relative;
}

.game-card:hover {
    transform: translateY(-4px);
    border-color: var(--neon-green);
    box-shadow: var(--shadow-glow-green);
}

.game-card-image {
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    position: relative;
    overflow: hidden;
}

.game-card-image.crash-bg { background: linear-gradient(135deg, #1a0a2e, #2d1b4e); }
.game-card-image.mines-bg { background: linear-gradient(135deg, #0a1a2e, #1b2d4e); }
.game-card-image.dice-bg { background: linear-gradient(135deg, #1a2e0a, #2d4e1b); }
.game-card-image.limbo-bg { background: linear-gradient(135deg, #2e0a1a, #4e1b2d); }
.game-card-image.plinko-bg { background: linear-gradient(135deg, #2e1a0a, #4e2d1b); }

.game-card-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,0.5));
}

.game-card-info {
    padding: 10px 12px;
}

.game-card-name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 2px;
}

.game-card-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--neon-green);
    color: #000;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    z-index: 2;
}

.game-card-players {
    font-size: 11px;
    color: var(--text-muted);
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 600;
    transition: all var(--transition-fast);
    cursor: pointer;
    border: none;
    white-space: nowrap;
}

.btn-primary {
    background: var(--gradient-primary);
    color: #000;
}

.btn-primary:hover {
    box-shadow: var(--shadow-glow-green);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    border-color: var(--neon-blue);
}

.btn-danger {
    background: var(--gradient-danger);
    color: white;
}

.btn-accent {
    background: var(--gradient-accent);
    color: #000;
}

.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-lg { padding: 14px 28px; font-size: 16px; }
.btn-full { width: 100%; }
.btn-icon { width: 36px; height: 36px; padding: 0; border-radius: var(--radius-sm); }

.btn:disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* ===== Inputs ===== */
.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 14px;
    transition: border-color var(--transition-fast);
}

.form-input:focus {
    border-color: var(--neon-green);
    box-shadow: 0 0 0 3px rgba(0, 255, 136, 0.1);
}

.form-input::placeholder {
    color: var(--text-dim);
}

.form-select {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 14px;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='%23a0a0c0'%3E%3Cpath d='M6 8L0 0h12z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

/* ===== Tables ===== */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th {
    background: var(--bg-card);
    padding: 12px 16px;
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-color);
}

.table td {
    padding: 12px 16px;
    font-size: 13px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
}

.table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

/* ===== Badges ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
}

.badge-success { background: rgba(0, 255, 136, 0.15); color: var(--neon-green); }
.badge-danger { background: rgba(255, 51, 85, 0.15); color: var(--neon-red); }
.badge-warning { background: rgba(255, 208, 0, 0.15); color: var(--neon-yellow); }
.badge-info { background: rgba(0, 212, 255, 0.15); color: var(--neon-blue); }
.badge-purple { background: rgba(168, 85, 247, 0.15); color: var(--neon-purple); }

/* ===== Stats Cards ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
}

.stat-card.green::before { background: var(--gradient-primary); }
.stat-card.purple::before { background: var(--gradient-secondary); }
.stat-card.yellow::before { background: var(--gradient-accent); }
.stat-card.red::before { background: var(--gradient-danger); }

.stat-card .stat-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 6px;
}

.stat-card .stat-value {
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 800;
}

/* ===== Modal ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: var(--bg-modal);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-normal);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(20px) scale(0.95);
    transition: transform var(--transition-normal);
    box-shadow: var(--shadow-lg);
}

.modal-overlay.active .modal {
    transform: translateY(0) scale(1);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 700;
}

.modal-close {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-card);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    transition: all var(--transition-fast);
}

.modal-close:hover {
    background: var(--neon-red);
    color: white;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* ===== Section Headers ===== */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.section-title {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 700;
}

.section-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ===== Live Bets Feed ===== */
.live-bets {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.live-bets-header {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 14px;
}

.live-bets-header .live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--neon-green);
    animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.live-bet-item {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border-color);
    gap: 10px;
    font-size: 13px;
    animation: fadeInBet 0.3s ease;
}

@keyframes fadeInBet {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

.live-bet-item .bet-user {
    color: var(--text-secondary);
    font-weight: 500;
    min-width: 80px;
}

.live-bet-item .bet-game {
    color: var(--text-muted);
    font-size: 12px;
    min-width: 60px;
}

.live-bet-item .bet-amount {
    margin-left: auto;
    font-weight: 600;
}

.live-bet-item .bet-multiplier {
    font-weight: 700;
    min-width: 50px;
    text-align: right;
}

.live-bet-item .bet-multiplier.win { color: var(--neon-green); }
.live-bet-item .bet-multiplier.loss { color: var(--neon-red); }

/* ===== Sports Section ===== */
.sports-categories {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin-bottom: 16px;
}

.sport-cat-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.sport-cat-btn:hover, .sport-cat-btn.active {
    border-color: var(--neon-green);
    color: var(--neon-green);
    background: rgba(0, 255, 136, 0.05);
}

.match-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 10px;
    transition: all var(--transition-fast);
}

.match-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

.match-card .match-league {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.match-card .match-teams {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.match-card .team-name {
    font-weight: 600;
    font-size: 14px;
}

.match-card .match-vs {
    color: var(--text-dim);
    font-size: 12px;
    font-weight: 700;
}

.match-card .match-time {
    font-size: 12px;
    color: var(--neon-blue);
    font-weight: 500;
}

.match-card .match-live-badge {
    background: var(--neon-red);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    animation: pulse-dot 1.5s infinite;
}

.odds-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

.odds-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.odds-btn:hover, .odds-btn.selected {
    border-color: var(--neon-green);
    background: rgba(0, 255, 136, 0.1);
}

.odds-btn .odds-label {
    font-size: 10px;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.odds-btn .odds-value {
    font-weight: 700;
    font-size: 14px;
    color: var(--neon-green);
}

/* ===== Bet Slip ===== */
.bet-slip {
    position: fixed;
    bottom: 0;
    right: 0;
    width: 320px;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-color);
    border-top: 1px solid var(--border-color);
    border-radius: var(--radius-lg) 0 0 0;
    z-index: 800;
    transform: translateY(100%);
    transition: transform var(--transition-normal);
}

.bet-slip.active {
    transform: translateY(0);
}

/* ===== Wallet Display ===== */
.wallets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
}

.wallet-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.wallet-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
}

.wallet-card.main::before { background: var(--neon-green); }
.wallet-card.bonus::before { background: var(--neon-yellow); }
.wallet-card.commission::before { background: var(--neon-purple); }
.wallet-card.locked::before { background: var(--neon-red); }
.wallet-card.sports::before { background: var(--neon-blue); }
.wallet-card.casino::before { background: var(--neon-orange); }

.wallet-card .wallet-type {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 6px;
}

.wallet-card .wallet-balance {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 800;
}

/* ===== Game Specific Styles ===== */
/* Crash */
.crash-container {
    text-align: center;
    padding: 40px 20px;
}

.crash-multiplier {
    font-family: var(--font-display);
    font-size: 64px;
    font-weight: 900;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
    transition: all 0.1s;
}

.crash-multiplier.crashed {
    background: var(--gradient-danger);
    -webkit-background-clip: text;
    background-clip: text;
}

.crash-graph {
    width: 100%;
    height: 200px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    margin-bottom: 20px;
}

/* Mines */
.mines-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    max-width: 350px;
    margin: 0 auto 20px;
}

.mine-tile {
    aspect-ratio: 1;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.mine-tile:hover:not(.revealed) {
    border-color: var(--neon-green);
    background: rgba(0, 255, 136, 0.05);
    transform: scale(1.05);
}

.mine-tile.revealed.safe {
    background: rgba(0, 255, 136, 0.15);
    border-color: var(--neon-green);
}

.mine-tile.revealed.mine {
    background: rgba(255, 51, 85, 0.15);
    border-color: var(--neon-red);
}

/* Dice */
.dice-container {
    text-align: center;
    padding: 20px;
}

.dice-result {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: 900;
    margin: 20px 0;
}

.dice-slider {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--neon-red) 0%, var(--neon-yellow) 50%, var(--neon-green) 100%);
    -webkit-appearance: none;
    appearance: none;
    margin: 20px 0;
}

.dice-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: white;
    border: 3px solid var(--neon-green);
    cursor: pointer;
    box-shadow: var(--shadow-glow-green);
}

/* Plinko */
.plinko-container {
    text-align: center;
    padding: 20px;
}

.plinko-board {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

.plinko-multipliers {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin: 10px 0;
}

.plinko-multiplier {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
    min-width: 32px;
    text-align: center;
}

/* ===== Auth Pages ===== */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    background: var(--bg-primary);
}

.auth-container {
    width: 100%;
    max-width: 400px;
}

.auth-logo {
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo .logo-big {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 900;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-logo .logo-sub {
    color: var(--text-muted);
    font-size: 13px;
    margin-top: 4px;
}

.auth-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px;
}

.auth-tabs {
    display: flex;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    padding: 3px;
    margin-bottom: 24px;
}

.auth-tab {
    flex: 1;
    padding: 10px;
    text-align: center;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.auth-tab.active {
    background: var(--neon-green);
    color: #000;
}

/* ===== Profile ===== */
.profile-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.profile-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--gradient-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 800;
}

.profile-info .profile-name {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 700;
}

.profile-info .profile-id {
    font-size: 12px;
    color: var(--text-muted);
}

/* ===== Tabs ===== */
.tabs {
    display: flex;
    gap: 4px;
    background: var(--bg-card);
    padding: 4px;
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
    overflow-x: auto;
}

.tab {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    white-space: nowrap;
    transition: all var(--transition-fast);
}

.tab:hover { color: var(--text-secondary); }
.tab.active { background: var(--neon-green); color: #000; }

/* ===== Toast ===== */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 5000;
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    max-width: 400px;
    transform: translateX(120%);
    transition: transform var(--transition-normal);
    box-shadow: var(--shadow-lg);
}

.toast.show { transform: translateX(0); }
.toast.success { background: var(--neon-green); color: #000; }
.toast.error { background: var(--neon-red); color: white; }
.toast.info { background: var(--neon-blue); color: #000; }

/* ===== Loading ===== */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--neon-green);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 40px auto;
}

@keyframes spin { to { transform: rotate(360deg); } }

.skeleton {
    background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-hover) 50%, var(--bg-card) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes shimmer {
    to { background-position: -200% 0; }
}

/* ===== Referral ===== */
.referral-link-box {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
}

.referral-link-box input {
    flex: 1;
    background: none;
    color: var(--text-primary);
    font-size: 13px;
}

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state .empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

.empty-state .empty-text {
    font-size: 14px;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.animate-fade { animation: fadeIn 0.3s ease; }
.animate-slide { animation: slideUp 0.4s ease; }
.animate-scale { animation: scaleIn 0.3s ease; }

/* ===== Bottom Navigation (Mobile) ===== */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--bottom-nav-height);
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    z-index: 1000;
    backdrop-filter: blur(20px);
}

.bottom-nav-items {
    display: flex;
    height: 100%;
}

.bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: var(--text-dim);
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.bottom-nav-item .bnav-icon { font-size: 20px; }
.bottom-nav-item:hover, .bottom-nav-item.active { color: var(--neon-green); }

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .bottom-nav {
        display: block;
    }
    
    .page-content {
        padding: 14px;
        padding-bottom: calc(var(--bottom-nav-height) + 20px);
    }
    
    .topbar {
        padding: 0 14px;
    }
    
    .games-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 10px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .wallets-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .topbar-btn span {
        display: none;
    }
    
    .bet-slip {
        width: 100%;
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    }
    
    .crash-multiplier {
        font-size: 42px;
    }
    
    .auth-card {
        padding: 20px;
    }
    
    .section-title {
        font-size: 16px;
    }
    
    .stat-card .stat-value {
        font-size: 18px;
    }
    
    .sidebar-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.5);
        z-index: 999;
        opacity: 0;
        pointer-events: none;
        transition: opacity var(--transition-normal);
    }
    
    .sidebar-overlay.active {
        opacity: 1;
        pointer-events: all;
    }
}

@media (max-width: 480px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }
    
    .wallets-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }
    
    .mines-grid {
        max-width: 280px;
        gap: 6px;
    }
    
    .odds-grid {
        gap: 4px;
    }
}

/* ===== PWA Install Banner ===== */
.pwa-install-banner {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gradient-primary);
    color: #000;
    padding: 12px 24px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    z-index: 1100;
    box-shadow: var(--shadow-glow-green);
    animation: bounce 2s infinite;
    display: none;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(-8px); }
}

/* Admin specific */
.admin-layout .main-content {
    background: var(--bg-primary);
}

.admin-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 16px;
}

.admin-card-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 16px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

