/* Language Switcher Styles */
.language-switcher {
    position: relative;
    display: inline-block;
    margin-right: 15px;
}

.language-current {
    background: transparent;
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    padding: 8px 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    min-width: 80px;
    justify-content: space-between;
}

.language-current:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #59a4e2;;
}

.language-current.active {
    background: rgba(255, 255, 255, 0.15);
    border-color: #59a4e2;;
}

.lang-flag {
    font-size: 16px;
    line-height: 1;
}

.lang-code {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.language-current i {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.language-current.active i {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    min-width: 150px;
    list-style: none;
    margin: 0;
    padding: 8px 0;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.language-switcher:hover .language-dropdown,
.language-switcher.active .language-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(5px);
}

.language-dropdown li {
    margin: 0;
    padding: 0;
}

.language-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
}

.language-option:hover {
    background: #f8f9fa;
    color: #59a4e2;
    text-decoration: none;
}

.language-option .lang-name {
    font-size: 13px;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .language-switcher {
        margin-right: 10px;
    }
    
    .language-current {
        padding: 6px 12px;
        font-size: 13px;
        min-width: 70px;
    }
    
    .language-dropdown {
        min-width: 130px;
    }
}

/* Dark theme for floating header when scrolled */
.floating-header.scrolled .language-current {
    border-color: #ddd;
    color: #333;
}

.floating-header.scrolled .language-current:hover {
    border-color: #59a4e2;;
    background: rgba(255, 165, 0, 0.1);
}

.floating-header.scrolled .language-current.active {
    border-color: #59a4e2;
    background: rgba(255, 165, 0, 0.1);
}

/* SEO and accessibility improvements */
.language-switcher button[aria-label] {
    position: relative;
}

.language-switcher .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Keyboard navigation */
.language-current:focus {
    outline: 2px solid #59a4e2;
    outline-offset: 2px;
}

.language-option:focus {
    background: #f8f9fa;
    color: #59a4e2;
    outline: 2px solid #59a4e2;
    outline-offset: -2px;
}