/* Sprachumschalter im Header (Partials/Page/Navigation/LanguageSwitch.html): runder Button rechts neben der Lupe */
.c-language-switch {
    display: flex;
    flex: 0 0 auto;
    gap: .75rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.c-language-switch__link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid #1d1d1b;
    border-radius: 10px;
    background: #fff;
    color: #1d1d1b;
    font-size: .875rem;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    transition: background-color .2s ease, color .2s ease;
}

.c-language-switch__link:hover,
.c-language-switch__link:focus-visible {
    background: #1d1d1b;
    color: #fff;
    text-decoration: none;
}

.c-language-switch__link:focus-visible {
    outline: 2px solid #1d1d1b;
    outline-offset: 2px;
}

/* Ausgabe neben dem Burger-Button nur bei eingeklappter Navigation, die im Menü dann ausblenden */
.c-language-switch--mobile {
    display: none;
}

@media (max-width: 991.98px) {
    #mainnavigation .c-language-switch {
        display: none;
    }

    .c-language-switch--mobile {
        display: flex;
        margin: 0 0 0 auto;
    }

    /* Logo, Sprache und Burger in einer Zeile: kleinerer Abstand, Logo darf auf schmalen Geräten schrumpfen */
    .container-mainnavigation:has(> .c-language-switch--mobile) {
        flex-wrap: nowrap;
        column-gap: .5rem;
    }

    .container-mainnavigation:has(> .c-language-switch--mobile) > .navbar-brand {
        flex: 0 1 auto;
        min-width: 0;
    }

    .container-mainnavigation:has(> .c-language-switch--mobile) > .navbar-brand img {
        max-width: 100%;
        height: auto;
    }

    .container-mainnavigation > .navbar-toggler {
        flex: 0 0 auto;
    }

    /* gleiche Höhe wie der Burger-Button (Mobile.css) */
    .c-language-switch--mobile .c-language-switch__link {
        width: 45px;
        height: 45px;
    }
}

/* Seite ohne Hauptnavigation (Navigation/Main.html): Button rechtsbündig im Header */
.container-mainnavigation > .c-language-switch {
    margin: 0 0 0 auto;
}
