/* 🎨 Theme variables now live in css/theme-global.css (single source of truth) */

/* 🍔 NAVBAR - CLEAN & SIMPLE */

.navbar {
    position: sticky;
    top: 0;
    background: linear-gradient(180deg, 
        rgba(5, 0, 10, 0.99), 
        rgba(5, 0, 10, 0.95));
    border-bottom: 2px solid rgba(162, 0, 255, 0.3);
    padding: 16px 20px;
    z-index: 100;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    gap: 30px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* LEFT: LOGO + THEME */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.navbar-left {
    display: flex;
    align-items: center;
    gap: 25px;
    flex: 0 0 auto;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo {
    font-size: 28px;
    font-weight: 900;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 3px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-badge {
    font-size: 20px;
    animation: badgePulse 2s infinite;
}

@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

/* THEME PICKER */
.theme-picker {
    position: relative;
}

.theme-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(162, 0, 255, 0.15);
    border: 2px solid rgba(162, 0, 255, 0.4);
    color: #fff;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.theme-btn:hover {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-color: var(--secondary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(162, 0, 255, 0.3);
}

.theme-icon {
    font-size: 16px;
}

.theme-dropdown-icon {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.theme-btn.active .theme-dropdown-icon {
    transform: rotate(180deg);
}

/* Theme Menu */
.theme-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: linear-gradient(135deg, 
        rgba(20, 0, 35, 0.95), 
        rgba(10, 5, 20, 0.95));
    border: 2px solid rgba(162, 0, 255, 0.4);
    border-radius: 15px;
    margin-top: 10px;
    padding: 10px;
    min-width: 210px;
    display: none;
    flex-direction: column;
    gap: 6px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    z-index: 1000;
    animation: menuAppear 0.3s ease;
}

.theme-menu.active {
    display: flex;
}

@keyframes menuAppear {
    0% {
        opacity: 0;
        transform: translateY(-10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.theme-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: transparent;
    border: 2px solid transparent;
    color: #fff;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.3s ease;
    text-align: left;
}

.theme-option:hover {
    background: rgba(162, 0, 255, 0.15);
    border-color: #a200ff;
    transform: translateX(5px);
}

.theme-color {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid currentColor;
}

.default-theme {
    background: linear-gradient(135deg, #a200ff, #d000ff);
}

.cyber-theme {
    background: linear-gradient(135deg, #00d9ff, #00ffff);
}

.midnight-theme {
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
}

.theme-name {
    flex: 1;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* CENTER: NAV LINKS */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.navbar-center {
    display: flex;
    align-items: center;
    gap: 30px;
    flex: 1;
    justify-content: center;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    padding: 10px 18px;
    border-radius: 12px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: #a200ff;
    z-index: -1;
    transition: left 0.3s ease;
    border-radius: 12px;
}

.nav-link:hover::before {
    left: 0;
}

.nav-link:hover {
    color: #000;
    transform: translateY(-2px);
}

.nav-icon {
    font-size: 16px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* RIGHT: PROFILE + COINS */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.navbar-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 0 0 auto;
}

.navbar-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(162, 0, 255, 0.15);
    padding: 12px 18px;
    border-radius: 25px;
    border: 2px solid rgba(162, 0, 255, 0.4);
    transition: all 0.3s ease;
    cursor: pointer;
    min-width: 170px;
}

.navbar-profile:hover {
    background: rgba(162, 0, 255, 0.25);
    border-color: #a200ff;
    transform: scale(1.05);
}

.profile-avatar {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, #a200ff, #d000ff);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 900;
    box-shadow: 0 4px 15px rgba(162, 0, 255, 0.3);
    flex-shrink: 0;
    overflow: hidden;
}

.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }

.profile-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.profile-name {
    font-weight: 700;
    font-size: 13px;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.profile-tier {
    font-size: 11px;
    color: #00ff88;
    font-weight: 600;
    text-transform: uppercase;
}

.navbar-coins {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(162, 0, 255, 0.15);
    padding: 12px 18px;
    border-radius: 25px;
    border: 2px solid rgba(162, 0, 255, 0.4);
    min-width: 110px;
    transition: all 0.3s ease;
}

.navbar-coins:hover {
    background: rgba(162, 0, 255, 0.25);
    transform: scale(1.05);
}

.coins-icon {
    font-size: 18px;
    animation: coinsFloat 2s ease-in-out infinite;
}

@keyframes coinsFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.coins-amount {
    font-weight: 700;
    font-size: 13px;
    color: #fff;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.hamburger {
    width: 24px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active .hamburger:nth-child(1) {
    transform: rotate(45deg) translateY(10px);
}

.mobile-menu-toggle.active .hamburger:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active .hamburger:nth-child(3) {
    transform: rotate(-45deg) translateY(-10px);
}

.navbar-mobile-menu {
    display: none;
    flex-direction: column;
    gap: 8px;
    padding: 15px;
    border-top: 2px solid rgba(162, 0, 255, 0.3);
    background: linear-gradient(180deg, 
        rgba(5, 0, 10, 0.98), 
        rgba(5, 0, 10, 0.95));
}

.navbar-mobile-menu.active {
    display: flex;
}

.mobile-nav-link {
    padding: 12px 16px;
    background: rgba(162, 0, 255, 0.1);
    border: 2px solid rgba(162, 0, 255, 0.3);
    color: #fff;
    border-radius: 12px;
    text-align: left;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
}

.mobile-nav-link:hover {
    background: #a200ff;
    border-color: #a200ff;
    transform: translateX(5px);
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* RESPONSIVE */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

@media (max-width: 1024px) {
    .navbar-container {
        gap: 15px;
    }

    .navbar-center {
        gap: 15px;
    }

    .nav-link {
        font-size: 12px;
        padding: 8px 14px;
    }

    .theme-btn {
        padding: 8px 12px;
        font-size: 12px;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 12px 14px;
    }

    .navbar-container {
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        overflow: visible;
    }

    .navbar-left {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .navbar-center {
        display: none;
    }

    .navbar-right {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }

    .logo {
        font-size: 20px;
        letter-spacing: 2px;
    }

    .logo-badge { font-size: 16px; }

    .navbar-profile {
        padding: 8px 12px;
        min-width: auto;
        border-radius: 20px;
        width: 100%;
        justify-content: center;
    }

    .profile-details { display: flex; }

    .profile-name { font-size: 12px; }
    .profile-tier { font-size: 10px; }

    .profile-avatar {
        width: 30px;
        height: 30px;
        font-size: 15px;
    }

    .navbar-coins {
        padding: 8px 12px;
        min-width: auto;
        border-radius: 20px;
        width: 100%;
        justify-content: center;
    }

    .coins-icon { font-size: 14px; }
    .coins-amount { font-size: 12px; }

    .mobile-menu-toggle { display: none; }

    .theme-btn {
        padding: 8px 12px;
        border-radius: 20px;
        font-size: 12px;
    }

    .theme-dropdown-icon { display: none; }
    .theme-menu { min-width: 160px; }
}

@media (max-width: 480px) {
    .navbar-container {
        gap: 8px;
    }

    .logo {
        font-size: 18px;
        letter-spacing: 2px;
    }

    .logo-badge {
        font-size: 16px;
    }

    .navbar-right {
        gap: 8px;
    }

    .navbar-coins {
        padding: 8px 12px;
    }

    .theme-menu {
        min-width: 160px;
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* SMOOTH TRANSITIONS */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

button {
    transition: all 0.3s ease;
}

button:active {
    transform: scale(0.95);
}
