/* ===================
   Modern Header
=================== */
#site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

#site-header.scrolled {
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    padding: 15px 0;
}

/* Logo */
.header-logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: transform 0.3s ease;
}

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

.header-logo img {
    height: 40px;
    width: auto;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

/* Search Bar */
.header-search {
    flex: 1;
    max-width: 600px;
}

.search-form {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    padding: 4px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.search-form:focus-within {
    border-color: #FFD700;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.search-icon {
    position: absolute;
    left: 20px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 1rem;
    pointer-events: none;
}

.search-form input {
    flex: 1;
    padding: 12px 20px 12px 50px;
    background: transparent;
    border: none;
    outline: none;
    color: white;
    font-size: 0.95rem;
    font-weight: 500;
}

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

.search-btn {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #1a1a2e;
    border: none;
    padding: 12px 20px;
    border-radius: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-weight: 600;
}

.search-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(255, 165, 0, 0.4);
}

.search-btn i {
    font-size: 1rem;
}

/* Desktop Navigation */
.header-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #FFD700;
    transform: translateY(-2px);
}

.nav-link i {
    font-size: 1rem;
}

.nav-link-login {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.nav-link-login:hover {
    background: linear-gradient(135deg, #764ba2, #667eea);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.nav-link-logout {
    background: rgba(255, 107, 107, 0.2);
    color: #FF6B6B;
}

.nav-link-logout:hover {
    background: rgba(255, 107, 107, 0.3);
}

/* Hamburger Menu (Mobile) */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.hamburger-line {
    width: 28px;
    height: 3px;
    background: white;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.hamburger.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.hamburger.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.hamburger.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    height: 100vh;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.3);
    z-index: 1002;
    transition: right 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    overflow-y: auto;
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 25px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-menu-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: white;
}

.close-menu {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-menu:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

.close-menu i {
    color: white;
    font-size: 1.2rem;
}

.mobile-nav {
    padding: 10px 0;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 25px;
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
}

.mobile-nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #FFD700;
    padding-left: 30px;
}

.mobile-nav-link i {
    font-size: 1.2rem;
    width: 25px;
    color: #FFD700;
}

/* Overlay */
.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Responsive */
@media (max-width: 1024px) {
    .header-nav {
        display: none;
    }

    .hamburger {
        display: flex;
    }
}

@media (max-width: 768px) {
    .header-inner {
        gap: 15px;
        padding: 12px 0;
    }

    .logo-text {
        display: none;
    }

    .header-logo img {
        height: 35px;
    }

    .header-search {
        max-width: none;
    }

    .search-form {
        padding: 3px;
    }

    .search-form input {
        padding: 10px 15px 10px 45px;
        font-size: 0.9rem;
    }

    .search-icon {
        left: 15px;
        font-size: 0.9rem;
    }

    .search-btn {
        padding: 10px 16px;
    }

    .mobile-menu {
        width: 280px;
    }
}

@media (max-width: 480px) {
    .header-container {
        padding: 0 15px;
    }

    .search-form input {
        padding: 8px 12px 8px 40px;
        font-size: 0.85rem;
    }

    .search-btn {
        padding: 8px 14px;
    }

    .mobile-menu {
        width: 260px;
    }
}

/* ===================
   Language & Currency Settings Panel
=================== */

/* Settings Dropdown Container */
.nav-settings-dropdown {
    position: relative;
}

.nav-settings-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.nav-settings-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 215, 0, 0.5);
    transform: scale(1.02);
}

.nav-settings-toggle .current-flag {
    font-size: 1.2rem;
}

.nav-settings-toggle .current-currency {
    font-weight: 600;
    font-size: 0.8rem;
    background: rgba(255, 215, 0, 0.3);
    padding: 2px 6px;
    border-radius: 4px;
}

/* Settings Panel (dropdown) */
.nav-settings-panel {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    min-width: 320px;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-15px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1001;
}

.nav-settings-panel.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.nav-settings-panel::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 20px;
    width: 16px;
    height: 16px;
    background: white;
    transform: rotate(45deg);
    box-shadow: -3px -3px 5px rgba(0, 0, 0, 0.05);
}

.settings-section {
    margin-bottom: 20px;
}

.settings-section:last-child {
    margin-bottom: 0;
}

.settings-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #666;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}

.settings-label i {
    color: #FFB800;
}

.settings-grid {
    display: grid;
    gap: 8px;
}

.settings-grid.lang-grid {
    grid-template-columns: repeat(2, 1fr);
}

.settings-grid.currency-grid {
    grid-template-columns: repeat(3, 1fr);
}

.settings-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 12px;
    background: #f5f5f5;
    border: 2px solid transparent;
    border-radius: 10px;
    color: #333;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.settings-btn:hover {
    background: #FFD700;
    color: #333;
    transform: translateY(-2px);
}

.settings-btn.active {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #333;
    font-weight: 600;
    border-color: #FF8C00;
    box-shadow: 0 4px 15px rgba(255, 165, 0, 0.4);
}

.settings-btn .flag {
    font-size: 1.3rem;
}

.settings-btn .name {
    font-size: 0.8rem;
}

.settings-btn.currency-btn {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 8px;
}

/* OLD dropdown styles - keeping for backwards compatibility */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.nav-dropdown-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 215, 0, 0.5);
}

.nav-dropdown-toggle .flag-icon {
    font-size: 1.1rem;
}

.nav-dropdown-toggle .dropdown-label {
    max-width: 80px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nav-dropdown-toggle .currency-icon {
    font-weight: 600;
    font-size: 0.85rem;
}

.nav-dropdown-toggle i.fa-chevron-down {
    font-size: 0.7rem;
    opacity: 0.7;
    transition: transform 0.3s ease;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    min-width: 180px;
    max-height: 300px;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

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

.nav-dropdown-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    background: none;
    border: none;
    color: #333;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.nav-dropdown-menu .dropdown-item:hover {
    background: #f0f0f0;
}

.nav-dropdown-menu .dropdown-item.active {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: white;
}

.nav-dropdown-menu .dropdown-item .flag-icon {
    font-size: 1.2rem;
}

/* Currency dropdown styling */
.currency-menu .dropdown-item {
    justify-content: flex-start;
}

/* Mobile Settings Section */
.mobile-settings-section {
    padding: 15px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-setting-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.mobile-lang-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.mobile-lang-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid transparent;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
}

.mobile-lang-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mobile-lang-btn.active {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #1a1a2e;
    font-weight: 600;
}

.mobile-lang-btn .flag-icon {
    font-size: 1.1rem;
}

.mobile-lang-btn .lang-name {
    font-size: 0.8rem;
}

.mobile-currency-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.mobile-currency-btn {
    padding: 10px 8px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid transparent;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.8rem;
    text-align: center;
}

.mobile-currency-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mobile-currency-btn.active {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #1a1a2e;
    font-weight: 600;
}

/* Hide dropdown labels on smaller screens */
@media (max-width: 1200px) {
    .nav-dropdown-toggle .dropdown-label {
        display: none;
    }
}

/* Hide language/currency in nav on tablet/mobile */
@media (max-width: 1024px) {
    .nav-dropdown {
        display: none;
    }
}
