/* Premium Design System for New Laex - V2 */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=Inter:wght@300;400;500;700&display=swap');

:root {
    /* Color Palette - Sophisticated HSL */
    --primary-h: 220;
    --primary-s: 90%;
    --primary-l: 56%;
    --primary: hsl(var(--primary-h), var(--primary-s), var(--primary-l));
    --header-height: 76px;
    --rank-height: 0px;
    --total-header-offset: var(--header-height);

    --secondary-h: 38;
    --secondary-s: 95%;
    --secondary-l: 55%;
    --secondary: hsl(var(--secondary-h), var(--secondary-s), var(--secondary-l));

    --accent-h: 350;
    --accent-s: 85%;
    --accent-l: 60%;
    --accent: hsl(var(--accent-h), var(--accent-s), var(--accent-l));

    /* Light Theme - Refined Gray Palette */
    --bg-color: #f1f5f9;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --card-bg: rgba(255, 255, 255, 0.9);
    --card-border: rgba(255, 255, 255, 0.6);
    --glass-blur: 16px;
    --shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
    --border-color: #e2e8f0;

    /* Gradients */
    --grad-primary: linear-gradient(135deg, var(--primary), #6366f1);
    --grad-gold: linear-gradient(135deg, #f59e0b, #fbbf24);
    --grad-surface: linear-gradient(180deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);

    --transition: cubic-bezier(0.4, 0, 0.2, 1) 0.3s;

    /* Gold Card Variables - Light */
    --gold-card-bg: linear-gradient(135deg, #fffbeb, #fef3c7);
    --gold-card-border: rgba(245, 158, 11, 0.3);
    --gold-card-text: #92400e;
    --gold-card-muted: #b45309;
    --gold-card-glow: radial-gradient(circle, rgba(245, 158, 11, 0.15), transparent);
    --gold-card-shadow: 0 20px 40px -10px rgba(245, 158, 11, 0.15);

    --benefit-bg: rgba(245, 158, 11, 0.06);
    --benefit-border: rgba(245, 158, 11, 0.15);
    --benefit-hover-bg: rgba(245, 158, 11, 0.12);
    --benefit-hover-border: rgba(245, 158, 11, 0.35);

    /* Plinko Variables - Light */
    --plinko-card-bg: #ffffff;
    --plinko-card-border: #e2e8f0;
    --plinko-tab-bg: #f8fafc;
    --plinko-tab-active-bg: #ffffff;
    --plinko-tab-text: #64748b;
    --plinko-tab-active-text: #0f172a;
    --plinko-input-bg: #f8fafc;
    --plinko-input-border: #e2e8f0;
    --plinko-input-text: #0f172a;
    --plinko-side-ctrl-bg: #f8fafc;
    --plinko-muted: #94a3b8;
    --plinko-game-bg: #0f172a;
    /* Keep dark by default or theme-aware */
    --plinko-game-shadow: rgba(0, 0, 0, 0.3);

    /* Hi-Lo Variables - Light */
    --hilo-board-bg: linear-gradient(180deg, #f1f5f9 0%, #e8edf5 100%);
    --hilo-board-border: rgba(0, 0, 0, 0.06);
    --hilo-board-shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    --hilo-glow-top: rgba(99, 102, 241, 0.08);
    --hilo-glow-bottom: rgba(99, 102, 241, 0.04);
    --hilo-mult-bg: rgba(255, 255, 255, 0.85);
    --hilo-mult-border: rgba(0, 0, 0, 0.08);
    --hilo-mult-label: #94a3b8;
    --hilo-idle-text: #64748b;
    --hilo-idle-title: #475569;
    --hilo-card-glow: rgba(99, 102, 241, 0.2);
    --hilo-prob-track: rgba(0, 0, 0, 0.07);
    --hilo-prob-label: #94a3b8;
    --hilo-ribbon-bg: rgba(0, 0, 0, 0.03);
    --hilo-prob-label: #94a3b8;
    --plinko-mult-box-bg: rgba(0, 0, 0, 0.03);
    --plinko-mult-box-border: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] {
    --plinko-game-bg: #ffffff;
    --plinko-game-shadow: rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] {
    --bg-color: #020617;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --card-bg: rgba(15, 23, 42, 0.6);
    --card-border: rgba(255, 255, 255, 0.1);
    --shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.8);
    --border-color: #1e293b;

    /* Gold Card Variables - Dark */
    --gold-card-bg: linear-gradient(135deg, #1a0a00, #2d1600);
    --gold-card-border: rgba(245, 158, 11, 0.4);
    --gold-card-text: #fde68a;
    --gold-card-muted: rgba(255, 255, 255, 0.5);
    --gold-card-glow: radial-gradient(circle, rgba(245, 158, 11, 0.2), transparent);
    --gold-card-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);

    --benefit-bg: rgba(245, 158, 11, 0.08);
    --benefit-border: rgba(245, 158, 11, 0.2);
    --benefit-hover-bg: rgba(245, 158, 11, 0.15);
    --benefit-hover-border: rgba(245, 158, 11, 0.4);

    /* Plinko Variables - Dark */
    --plinko-card-bg: rgba(15, 23, 42, 0.6);
    --plinko-card-border: rgba(255, 255, 255, 0.08);
    --plinko-tab-bg: rgba(0, 0, 0, 0.2);
    --plinko-tab-active-bg: rgba(255, 255, 255, 0.05);
    --plinko-tab-text: rgba(255, 255, 255, 0.4);
    --plinko-tab-active-text: #ffffff;
    --plinko-input-bg: #0f1114;
    --plinko-input-border: rgba(255, 255, 255, 0.05);
    --plinko-input-text: #ffffff;
    --plinko-side-ctrl-bg: rgba(255, 255, 255, 0.02);
    --plinko-muted: rgba(255, 255, 255, 0.3);
    --plinko-game-bg: #0f172a;
    --plinko-game-shadow: rgba(0, 0, 0, 0.6);

    /* Hi-Lo Variables - Dark */
    --hilo-board-bg: linear-gradient(180deg, #0d1117 0%, #0d1520 100%);
    --hilo-board-border: rgba(255, 255, 255, 0.07);
    --hilo-board-shadow: 0 32px 80px -20px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    --hilo-glow-top: rgba(99, 102, 241, 0.25);
    --hilo-glow-bottom: rgba(99, 102, 241, 0.1);
    --hilo-mult-bg: rgba(255, 255, 255, 0.03);
    --hilo-mult-border: rgba(255, 255, 255, 0.06);
    --hilo-mult-label: rgba(255, 255, 255, 0.3);
    --hilo-idle-text: rgba(255, 255, 255, 0.3);
    --hilo-idle-title: rgba(255, 255, 255, 0.55);
    --hilo-card-glow: rgba(99, 102, 241, 0.35);
    --hilo-prob-track: rgba(255, 255, 255, 0.06);
    --hilo-prob-label: rgba(255, 255, 255, 0.4);
    --hilo-ribbon-bg: rgba(255, 255, 255, 0.02);
    --plinko-mult-box-bg: rgba(255, 255, 255, 0.05);
    --plinko-mult-box-border: rgba(255, 255, 255, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    height: 100%;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    transition: var(--transition);
    line-height: 1.6;
    /* background-image:
        radial-gradient(at 0% 0%, hsla(220, 100%, 15%, 0.05) 0, transparent 50%),
        radial-gradient(at 100% 100%, hsla(38, 100%, 15%, 0.05) 0, transparent 50%); */
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

h1,
h2,
h3,
h4,
.logo {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Glassmorphism Classes */
.glass {
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow);
}

/* Auth Cards & Layouts */
.auth-card {
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--card-border);
    padding: 3rem;
    border-radius: 24px;
    box-shadow: var(--shadow);
    max-width: 480px;
    margin: 6rem auto;
    text-align: center;
}

.auth-card h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: var(--grad-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Form Styles */
.form-group {
    margin-bottom: 2rem;
    text-align: left;
}

.auth-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-control {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid transparent;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.03);
    color: var(--text-main);
    font-size: 1rem;
    transition: var(--transition);
    border-color: var(--border-color);
}

[data-theme="dark"] .form-control {
    background: rgba(255, 255, 255, 0.03);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    background: transparent;
    box-shadow: 0 0 0 4px hsla(var(--primary-h), var(--primary-s), var(--primary-l), 0.1);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    border: none;
    border-radius: 12px;
    background: var(--grad-primary);
    color: white;
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    box-shadow: 0 4px 12px hsla(var(--primary-h), var(--primary-s), var(--primary-l), 0.2);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px hsla(var(--primary-h), var(--primary-s), var(--primary-l), 0.3);
    filter: brightness(1.1);
}

.btn:active {
    transform: translateY(0);
}

.btn-secondary {
    background: var(--grad-gold);
    box-shadow: 0 4px 12px hsla(var(--secondary-h), var(--secondary-s), var(--secondary-l), 0.2);
}

.btn-accent {
    background: var(--accent);
    box-shadow: 0 4px 12px hsla(var(--accent-h), var(--accent-s), var(--accent-l), 0.2);
}

.btn-sm {
    padding: 0.6rem 1.2rem;
    font-size: 0.875rem;
    border-radius: 8px;
}

/* Navbar & Navigation */
.navbar {
    padding: 1.25rem 0;
    position: sticky !important;
    top: 0;
    width: 100%;
    z-index: 10000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--bg-color);
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    padding: 0.75rem 0;
}

.navbar.scrolled ~ * {
    --header-height: 60px;
}

:has(.navbar.scrolled) {
    --header-height: 60px;
}

.navbar::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(to right,
            transparent 0%,
            var(--border-color) 5%,
            var(--border-color) 42%,
            transparent 45%,
            transparent 55%,
            var(--border-color) 58%,
            var(--border-color) 95%,
            transparent 100%);
}

/* Subtle glow below navbar */
.navbar::before {
    content: '';
    position: absolute;
    bottom: -80px;
    left: 0;
    width: 100%;
    height: 80px;
    background: linear-gradient(to bottom,
            rgba(99, 102, 241, 0.08) 0%,
            rgba(99, 102, 241, 0.03) 40%,
            transparent 100%);
    pointer-events: none;
    opacity: 0.7;
}

.navbar.scrolled {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    padding: 0.75rem 0;
}

.navbar.scrolled::after {
    background: var(--border-color);
    opacity: 0.5;
}

.navbar.scrolled::before {
    display: none;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.hdr-balance-label {
    display: none;
    color: var(--text-muted);
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: 700;
}

.header-balance {
    display: none;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 1rem;
    border-radius: 100px;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 0.8rem;
    color: var(--text-main);
    cursor: default;
    transition: var(--transition);
    border: 1px solid var(--card-border);
    background: rgba(255, 255, 255, 0.03);
}

[data-theme="dark"] .header-balance {
    background: rgba(255, 255, 255, 0.05);
}

.header-balance i {
    color: var(--secondary);
    font-size: 0.85rem;
}

.header-balance:hover {
    transform: translateY(-1px);
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.nav-links {
    display: flex;
    gap: 4rem;
    align-items: center;
}

.nav-main-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-main-links a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 700;
    font-size: 0.75rem;
    transition: var(--transition);
    padding: 0.5rem 0;
    position: relative;
    letter-spacing: 0.02em;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.nav-main-links a i {
    font-size: 1.1rem;
    opacity: 0.8;
}

.nav-main-links a:hover,
.nav-main-links a.active {
    color: var(--text-main);
}

.nav-main-links a.active::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 15%;
    width: 70%;
    height: 2px;
    background: var(--primary);
    border-radius: 4px;
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.6);
}

.nav-actions-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Action Buttons */
.btn-nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 0.85rem;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    color: white;
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
    gap: 0.6rem;
    line-height: 1;
}

.btn-nav:hover {
    transform: translateY(-2px);
    filter: brightness(1.1);
}

.btn-nav span {
    font-family: 'Outfit', sans-serif;
}

.btn-admin {
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.2);
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

.btn-telegram {
    background: #229ED9;
}

.btn-settings {
    background: #f59e0b;
}

.btn-notify {
    background: #374151;
    position: relative;
}

.btn-notify i {
    color: #fbbf24;
}

.btn-logout {
    background: #f43f5e;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.btn-login {
    background: var(--primary);
}

.btn-register {
    background: var(--secondary);
    color: #1a1a1a !important;
}

/* Notification Badge */
#noti-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    padding: 2px 5px;
    border-radius: 6px;
    font-weight: 800;
    border: 2px solid var(--bg-color);
    line-height: 1;
}

/* Notification Dropdown */
.notification-wrapper {
    position: relative;
}

#noti-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 15px);
    right: 0;
    width: 320px;
    max-height: 400px;
    z-index: 1100;
    overflow-y: auto;
    border-radius: 20px;
    padding: 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.noti-dropdown-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
}

.noti-dropdown-header h4 {
    margin: 0;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
}

.noti-dropdown-header button {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
}

.noti-loading {
    padding: 2.5rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* --- Global Rank Wrapper (Desktop) --- */
.header-rank-wrapper {
    position: sticky;
    top: var(--header-height) !important;
    --rank-height: 52px;
    --total-header-offset: calc(var(--header-height) + var(--rank-height));
    z-index: 1000;
    backdrop-filter: blur(10px);
    background: rgba(2, 6, 23, 0.7);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease, top 0.3s ease;
}

.header-rank-wrapper.scrolled {
    --total-header-offset: calc(60px + var(--rank-height));
}

[data-theme="light"] .header-rank-wrapper {
    background: rgba(241, 245, 249, 0.85);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.header-rank-bar {
    background: transparent;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: baseline;
    gap: 1.5rem;
    transition: var(--transition);
}

.header-progress-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.header-rank-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    flex-wrap: wrap;
}

.rank-label {
    font-weight: 800;
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.rank-label-current { color: var(--primary); }
.rank-label-next { color: var(--text-muted); opacity: 0.8; }

.header-progress-bar-container {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--border-color);
}

[data-theme="light"] .header-progress-bar-container {
    background: rgba(0, 0, 0, 0.05);
}

.header-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary) 0%, #a78bfa 100%);
    border-radius: 10px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.header-progress-stats {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-muted);
    font-family: 'Outfit', sans-serif;
    text-align: center;
    margin-top: 0.1rem;
}

.header-roadmap-btn {
    padding: 8px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 10px;
    color: var(--primary);
    font-weight: 700;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.05);
}

.header-roadmap-btn:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-1px);
}

/* Dashboard & Cards */
.main-content {
    padding: 2rem 0 4rem 0;
    flex: 1 0 auto;
}

.footer {
    flex-shrink: 0;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.stat-card {
    background: var(--card-bg);
    backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--card-border);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--grad-surface);
    opacity: 0.5;
    pointer-events: none;
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
}

.stat-card h3 {
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.stat-card .value {
    font-size: clamp(1.1rem, 3.5vw, 2.25rem);
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    color: var(--text-main);
    word-break: break-all;
    overflow-wrap: break-word;
    line-height: 1.2;
}

/* Tables */
.table-container {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    box-shadow: var(--shadow);
    overflow-x: auto;
    margin-top: 3rem;
}

/* Custom scrollbar for table containers */
.table-container::-webkit-scrollbar,
.table-responsive::-webkit-scrollbar {
    height: 6px;
}

.table-container::-webkit-scrollbar-track,
.table-responsive::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 0 0 24px 24px;
}

.table-container::-webkit-scrollbar-thumb,
.table-responsive::-webkit-scrollbar-thumb {
    background: var(--grad-primary);
    border-radius: 99px;
}

.table-container::-webkit-scrollbar-thumb:hover,
.table-responsive::-webkit-scrollbar-thumb:hover {
    filter: brightness(1.2);
}

/* Firefox */
.table-container,
.table-responsive {
    scrollbar-width: thin;
    scrollbar-color: var(--primary) transparent;
}

.table-header {
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th {
    padding: 1.25rem 2rem;
    text-align: left;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    background: rgba(0, 0, 0, 0.02);
}

.table td {
    padding: 1.25rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.table tr:last-child td {
    border-bottom: none;
}

.table tr:hover {
    background: rgba(0, 0, 0, 0.01);
}

/* Theme Switch */
.theme-switch {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3.5rem;
    height: 3.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow);
    cursor: pointer;
    z-index: 1000;
    transition: var(--transition);
}

.theme-switch:hover {
    transform: rotate(30deg) scale(1.1);
    border-color: var(--primary);
}

/* Faucet & Special UI */
.pin-display {
    font-family: 'Outfit', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    letter-spacing: 0.5rem;
    margin: 2rem 0;
    color: var(--primary);
}

.timer-ring {
    font-size: 4rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    background: var(--grad-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 2rem 0;
}

/* Plinko V2 Styles */
.game-main {
    background: var(--plinko-game-bg);
    padding: 3rem;
    border-radius: 32px;
    box-shadow: 0 0 50px var(--plinko-game-shadow);
    border: 1px solid var(--plinko-card-border);
    transition: background 0.4s ease, border 0.4s ease, box-shadow 0.4s ease;
}

#plinko-canvas {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.3));
    border-radius: 20px;
}

.plinko-columns {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.game-sidebar {
    flex: 0 0 350px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.game-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: visible;
}

.multiplier-row {
    display: flex;
    justify-content: center;
    margin: 1rem auto 2rem auto;
}

.multiplier-box {
    flex: 0 0 auto;
    background: var(--plinko-mult-box-bg);
    border: 1px solid var(--plinko-mult-box-border);
    color: var(--text-main);
    font-weight: 800;
    border-radius: 4px;
    padding: 4px 0;
    font-size: 0.6rem;
    transition: var(--transition);
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    white-space: nowrap;
}

.multiplier-box.active {
    background: var(--grad-primary);
    color: white;
    transform: scale(1.1) translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.qr-container {
    text-align: center;
    margin: 0 auto 2rem auto;
    background: #fff;
    padding: 1rem;
    border-radius: 16px;
    display: inline-block;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
}

.qr-image {
    display: block;
    width: 180px;
    height: 180px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(34, 197, 94, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

/* .animate-in {
    animation: fadeIn 0.8s var(--transition) forwards;
} */

/* Footer */
.footer {
    padding: 2rem 0;
    color: var(--text-muted);
    background: var(--card-bg);
    border-top: 1px solid var(--card-border);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.footer-section {
    flex: 1;
    display: flex;
    align-items: center;
}

.footer-left {
    justify-content: flex-start;
}

.footer-center {
    justify-content: center;
}

.footer-right {
    justify-content: flex-end;
    gap: 2rem;
}

.footer-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-link:hover {
    color: var(--text-main);
}

.footer-center p {
    margin: 0;
    font-size: 0.9rem;
}

/* Gold Card Component */
.dash-gold-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    padding: 1.5rem;
    background: var(--gold-card-bg);
    border: 1px solid var(--gold-card-border);
    box-shadow: var(--gold-card-shadow);
    transition: var(--transition);
}

.dash-gold-card .glow {
    position: absolute;
    top: -30px;
    right: -30px;
    width: 120px;
    height: 120px;
    background: var(--gold-card-glow);
    pointer-events: none;
    z-index: 0;
}

.dash-gold-card-content {
    position: relative;
    z-index: 1;
}

.dash-gold-title {
    font-weight: 800;
    font-size: 1rem;
    background: var(--grad-gold);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.dash-gold-text {
    font-size: 0.75rem;
    color: var(--gold-card-muted);
    line-height: 1.5;
    margin-bottom: 1.25rem;
}

.btn-gold-action {
    display: block;
    text-align: center;
    background: var(--grad-gold);
    color: #1a0a00;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 0.75rem;
    border-radius: 10px;
    text-decoration: none;
    letter-spacing: 0.05em;
    transition: var(--transition);
    border: none;
}

.btn-gold-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(245, 158, 11, 0.4);
}

/* Plinko Theme-Responsive Components */
.plinko-sidebar-card {
    background: var(--plinko-card-bg);
    border: 1px solid var(--plinko-card-border);
    border-radius: 24px;
    padding: 2rem;
    box-shadow: var(--shadow);
    width: 100%;
}

.plinko-mode-tabs {
    display: flex;
    background: var(--plinko-tab-bg);
    border-radius: 12px;
    padding: 0.3rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--plinko-input-border);
}

.plinko-mode-tab {
    flex: 1;
    text-align: center;
    padding: 0.6rem;
    cursor: pointer;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--plinko-tab-text);
    transition: all 0.2s;
}

.plinko-mode-tab.active {
    background: var(--grad-gold);
    color: #000;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
    transform: scale(1.05);
}

.plinko-bet-input-group {
    background: var(--plinko-input-bg);
    border: 2px solid var(--plinko-input-border);
    border-radius: 16px;
    display: flex;
    overflow: hidden;
    height: 5rem;
    transition: var(--transition);
}

.plinko-bet-input-group:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px hsla(var(--primary-h), var(--primary-s), var(--primary-l), 0.1);
}

.plinko-bet-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0 1rem;
    border-left: 2px solid var(--plinko-input-border);
    border-right: 2px solid var(--plinko-input-border);
}

#bet-amount {
    background: transparent;
    border: none;
    color: var(--plinko-input-text);
    width: 100%;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 800;
    padding: 0;
    outline: none;
    font-family: 'Outfit', sans-serif;
}

.plinko-bet-ctrls {
    display: flex;
    flex-direction: column;
    width: 50px;
    background: var(--plinko-side-ctrl-bg);
}

.plinko-bet-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--plinko-muted);
    font-size: 0.7rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    border-bottom: 1px solid var(--plinko-input-border);
}

.plinko-bet-btn:hover {
    background: rgba(var(--primary-h), var(--primary-s), var(--primary-l), 0.05);
    color: var(--primary);
}

.plinko-diff-btn {
    background: var(--plinko-tab-bg);
    border: 1px solid var(--plinko-input-border);
    color: var(--plinko-tab-text);
    padding: 0.6rem 0.8rem;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 700;
    transition: all 0.2s;
    flex: 1;
    opacity: 0.5;
}

.plinko-diff-btn.active {
    background: var(--grad-gold);
    color: #000;
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
    opacity: 1;
    transform: scale(1.05);
}


/* Alert Utilities */
.alert {
    padding: 1.25rem 1.5rem;
    border-radius: 14px;
    margin-bottom: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition);
}

.alert-danger {
    background: #ef4444;
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.25);
}

.alert-success {
    background: #22c55e;
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(34, 197, 94, 0.25);
}

.alert-info {
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.25);
}

/* Toast Notification System */
#toast-container {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    width: 320px;
    padding: 1.25rem 1.5rem;
    border-radius: 16px;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: toast-in 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    transition: all 0.3s ease;
    cursor: pointer;
}

.toast.toast-out {
    animation: toast-out 0.4s ease forwards;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateX(50px) scale(0.9);
    }

    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@keyframes toast-out {
    from {
        opacity: 1;
        transform: translateX(0) scale(1);
    }

    to {
        opacity: 0;
        transform: translateX(50px) scale(0.9);
    }
}

.toast-success,
.toast-success .toast-message,
.toast-success .toast-title {
    color: var(--text-main) !important;
}

.toast-success i {
    color: #22c55e;
}

.toast-error,
.toast-error .toast-message,
.toast-error .toast-title {
    color: var(--text-main) !important;
}

.toast-error i {
    color: #ef4444;
}

.toast-warning,
.toast-warning .toast-message,
.toast-warning .toast-title {
    color: var(--text-main) !important;
}

.toast-warning i {
    color: #f59e0b;
}

.toast-content {
    flex: 1;
}

.toast-message {
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.5;
}

.toast-title {
    font-family: 'Outfit', sans-serif;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
    opacity: 1;
}

.toast i {
    font-size: 1.25rem;
    margin-top: 0.2rem;
}

#noti-list {
    background-color: var(--bg-color);
}

.abc a {
    color: white;
    text-decoration: none;
}
.num-fmt {
    cursor: help !important;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
    display: inline-block;
}

.num-fmt:hover {
    color: var(--primary) !important;
    border-bottom-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}
