.language-switcher {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 15px;
}

.language-switcher .lang-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    color: white;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.language-switcher .lang-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
}

.language-switcher .lang-btn.active {
    background: white;
    color: #1e40af;
    border-color: white;
}

.language-switcher .flag-icon {
    display: inline-block;
    width: 16px;
    height: 11px;
    border-radius: 2px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.language-switcher .flag-cn {
    background-image: url('/images/flags/cn.svg');
}

.language-switcher .flag-gb {
    background-image: url('/images/flags/gb.svg');
}

@media screen and (max-width: 768px) {
    .language-switcher {
        margin-left: 10px;
        gap: 5px;
    }
    
    .language-switcher .lang-btn {
        padding: 5px 10px;
        font-size: 11px;
    }
    
    .language-switcher .flag-icon {
        width: 14px;
        height: 10px;
    }
}

@media screen and (max-width: 480px) {
    .language-switcher .lang-btn {
        padding: 4px 8px;
        font-size: 10px;
    }
    
    .language-switcher .flag-icon {
        width: 12px;
        height: 8px;
    }
}

.user-menu {
    margin-left: 15px;
}

.login-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 20px;
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.login-btn:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.user-dropdown {
    position: relative;
}

.user-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px 6px 6px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.user-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
}

.user-avatar {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
}

.chevron-down {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
}

.user-dropdown.open .chevron-down {
    transform: rotate(180deg);
}

.user-dropdown-content {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 180px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    z-index: 1000;
    animation: slideDown 0.2s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.user-dropdown.open .user-dropdown-content {
    display: block;
}

.user-dropdown-content a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
    border-bottom: 1px solid #f3f4f6;
}

.user-dropdown-content a:last-child {
    border-bottom: none;
}

.user-dropdown-content a:hover {
    background: #f3f4f6;
    color: #1d4ed8;
}

.user-dropdown-content a svg {
    width: 18px;
    height: 18px;
    color: #6b7280;
}

.user-dropdown-content a:hover svg {
    color: #1d4ed8;
}

@media screen and (max-width: 768px) {
    .user-menu {
        margin-left: 10px;
    }
    
    .user-name {
        display: none;
    }
    
    .user-btn {
        padding: 4px;
    }
    
    .user-dropdown-content {
        right: -50%;
    }
}

@media screen and (max-width: 480px) {
    .login-btn {
        padding: 6px 14px;
        font-size: 12px;
    }
    
    .user-avatar {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
}
