/* Ported from Blazor LanguageSwitcher.razor.css */

.lang-switcher-root {
    position: relative;
    display: inline-flex;
    flex-shrink: 0;
}

.lang-switcher--desktop {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    background: rgba(15, 42, 68, 0.05);
    border-radius: 999px;
    padding: 2px 6px;
    flex-shrink: 0;
}

.lang-switcher--header {
    background: rgba(43, 184, 200, 0.12);
    border: 1px solid rgba(43, 184, 200, 0.28);
    padding: 3px 8px 3px 4px;
    box-shadow: 0 2px 8px rgba(43, 184, 200, 0.12);
}

.lang-switcher__globe {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    color: var(--teal, #2BB8C8);
    flex-shrink: 0;
}

.lang-switcher__globe svg {
    display: block;
}

.lang-switcher__btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    color: var(--navy, #0F2A44);
    padding: 6px 8px;
    border-radius: 999px;
    line-height: 1.2;
    min-height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
    font-family: 'Inter', sans-serif;
}

.lang-switcher__btn[lang="ur"] {
    font-family: 'Noto Sans Arabic', 'Inter', sans-serif;
    font-size: 12px;
    padding-block: 6px;
}

.lang-switcher__btn:hover {
    background: rgba(43, 184, 200, 0.12);
    color: var(--teal, #2BB8C8);
}

.lang-switcher__btn--active {
    background: var(--teal, #2BB8C8);
    color: white;
}

.lang-switcher__btn--active:hover {
    background: var(--teal-dark, #1A9BAF);
    color: white;
}

.lang-switcher__sep {
    color: rgba(15, 42, 68, 0.25);
    font-size: 11px;
    user-select: none;
}

.lang-switcher--mobile {
    display: none;
    position: relative;
    align-items: center;
}

.lang-switcher__trigger {
    background: rgba(15, 42, 68, 0.05);
    border: none;
    cursor: pointer;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--navy, #0F2A44);
    transition: background 0.2s, transform 0.15s, color 0.2s;
    flex-shrink: 0;
    padding: 0;
}

.lang-switcher__trigger:hover,
.lang-switcher__trigger[aria-expanded="true"] {
    background: rgba(43, 184, 200, 0.13);
    color: var(--teal, #2BB8C8);
}

.lang-switcher__trigger:focus-visible {
    outline: 2px solid var(--teal, #2BB8C8);
    outline-offset: 2px;
}

.lang-switcher__trigger svg {
    display: block;
}

.lang-switcher__backdrop {
    position: fixed;
    inset: 0;
    z-index: 250;
    background: transparent;
    border: none;
    cursor: default;
    padding: 0;
}

.lang-switcher__menu {
    position: absolute;
    top: calc(100% + 8px);
    inset-inline-end: 0;
    min-width: 148px;
    background: #ffffff;
    border: 1px solid rgba(43, 184, 200, 0.28);
    border-radius: 14px;
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    z-index: 300;
    box-shadow: 0 12px 32px rgba(15, 42, 68, 0.16);
}

.lang-switcher__option {
    display: flex;
    align-items: center;
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: var(--navy, #0F2A44);
    padding: 10px 12px;
    border-radius: 10px;
    line-height: 1.2;
    text-align: start;
    transition: background 0.15s, color 0.15s;
    font-family: 'Inter', sans-serif;
}

.lang-switcher__option[lang="ur"] {
    font-family: 'Noto Sans Arabic', 'Inter', sans-serif;
}

.lang-switcher__option:hover {
    background: rgba(43, 184, 200, 0.1);
    color: var(--teal, #2BB8C8);
}

.lang-switcher__option--active {
    background: rgba(43, 184, 200, 0.14);
    color: var(--teal, #2BB8C8);
}

.lang-switcher__option:focus-visible {
    outline: 2px solid var(--teal, #2BB8C8);
    outline-offset: -2px;
}

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

    .lang-switcher--mobile {
        display: inline-flex;
    }

    .lang-switcher__trigger {
        width: 36px;
        height: 36px;
    }

    .lang-switcher__trigger svg {
        width: 18px;
        height: 18px;
    }

    .lang-switcher__menu {
        min-width: 136px;
    }

    .lang-switcher__option {
        font-size: 13px;
        padding: 9px 10px;
    }
}
