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

.language-flag {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.language-flag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-color: #ff882d;
}

.language-flag.active {
    border-color: #ff882d;
    box-shadow: 0 0 0 2px rgba(255, 136, 45, 0.3);
    animation: pulse 2s infinite;
}

.language-flag.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    background: #ff882d;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(255, 136, 45, 0.8);
}

.language-flag img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.language-flag:hover img {
    transform: scale(1.1);
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    padding: 12px;
    min-width: 150px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.language-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(8px);
}

.language-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

.language-dropdown-item:hover {
    background: linear-gradient(135deg, #fff5eb 0%, #ffe9d6 100%);
    transform: translateX(2px);
    color: #ff882d;
}

.language-dropdown-item.active {
    background: linear-gradient(135deg, #ff882d 0%, #ff6b00 100%);
    color: white;
    font-weight: 600;
}

.language-dropdown-item .flag-small {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.language-dropdown-item.active .flag-small {
    border-color: rgba(255, 255, 255, 0.3);
}

.flag-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.language-switcher-mobile {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 25px 20px;
    /* border-top: 1px solid rgba(255, 136, 45, 0.2); */
    margin-top: 20px;
    /* background: linear-gradient(to bottom, rgba(255, 136, 45, 0.05) 0%, transparent 100%); */
    border-radius: 0 0 16px 16px;
}

.language-switcher-mobile h3 {
    color: #ff882d;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.mobile-language-flags {
    display: flex;
    gap: 20px;
    justify-content: center;
    width: 100%;
}

.language-flag-mobile {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.language-flag-mobile:hover {
    transform: scale(1.1);
    border-color: #ff882d;
    box-shadow: 0 6px 20px rgba(255, 136, 45, 0.3);
}

.language-flag-mobile.active {
    border-color: #ff882d;
    box-shadow: 0 0 0 3px rgba(255, 136, 45, 0.4);
    animation: pulse 2s infinite;
}

.language-flag-mobile.active::before {
    content: '✓';
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ff882d;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.language-flag-mobile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 136, 45, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(255, 136, 45, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(255, 136, 45, 0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1200px) {
    .language-switcher {
        margin-left: 15px;
    }
}

@media (max-width: 1024px) {
    .language-switcher {
        margin-left: 10px;
    }

    .language-flag {
        width: 32px;
        height: 32px;
    }
}

@media (max-width: 768px) {
    .language-switcher {
        display: none;
    }

    .language-switcher-mobile {
        display: flex;
        animation: slideIn 0.5s ease-out;
    }
}

@media (max-width: 480px) {
    .mobile-language-flags {
        gap: 15px;
    }

    .language-flag-mobile {
        width: 44px;
        height: 44px;
    }

    .language-switcher-mobile h3 {
        font-size: 14px;
    }
}

.language-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #ff882d 0%, #ff6b00 100%);
    color: white;
    padding: 16px 24px;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(255, 136, 45, 0.4);
    z-index: 9999;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideIn 0.3s ease-out;
    max-width: 300px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.language-notification.error {
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
}

.language-flag[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: slideIn 0.2s ease-out;
}

.language-flag[title]:hover::before {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 5px;
    border-style: solid;
    border-color: #333 transparent transparent transparent;
    z-index: 1000;
}