/* Language switcher — minimal text toggle, headings font, no box/border */
.lang-switch {
    display: inline-flex;
    align-items: center;
    background: transparent;
}

.lang-switch__btn {
    appearance: none;
    border: none;
    background-color: transparent;
    color: #777;
    /* inherit font-family/text-transform/font-size/letter-spacing/font-weight
       from .main-nav so it matches "ABOUT US", "CONTACT", etc. exactly */
    font: inherit;
    text-transform: inherit;
    letter-spacing: inherit;
    line-height: 1;
    padding: 4px;
    cursor: pointer;
    transition: color 0.4s ease-in-out;
}

.lang-switch__sep {
    color: #ccc;
    font: inherit;
    padding: 0 2px;
}

.lang-switch__btn:hover {
    color: #156d83;
}

.lang-switch__btn.is-active {
    color: #156d83;
}

.lang-switch__btn:focus-visible {
    outline: 2px solid #156d83;
    outline-offset: 2px;
}

/* --- Desktop: sits inline as the last nav item, right after "Contact" ---
   Height is matched to .main-nav's own line-height-based row height (90px,
   75px once .menu-sticky kicks in on scroll) so the pill is vertically
   centered exactly like the surrounding <a> links. */
.nav.navbar-nav > li.lang-switch-item {
    float: left;
    display: flex !important;
    align-items: center;
    height: 90px;
    margin-left: 15px;
    transition: height 0.4s ease-in-out;
}

.menu-sticky .nav.navbar-nav > li.lang-switch-item {
    height: 75px;
}

.lang-switch--mobile,
.lang-switch--floating {
    display: none;
}

/* --- Pages without a main-nav (Innerpage_* detail pages): fixed top-right --- */
.lang-switch--floating {
    display: inline-flex;
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 1040;
    padding: 6px 10px;
}

.lang-switch--floating .lang-switch__btn,
.lang-switch--floating .lang-switch__sep {
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}

/* --- Mobile / collapsed nav: logo left, switch right-aligned next to the
   burger (with a small gap so it doesn't touch it), nav copy hides --- */
@media (max-width: 991px) {
    .navbar {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
    }

    .brand-logo {
        float: none;
        order: 1;
        display: flex;
        align-items: center;
    }

    /* Bootstrap hard-codes .navbar-brand to height:50px; our logo is taller,
       so it overflowed that box and threw off the flex vertical centering. */
    .brand-logo .navbar-brand {
        height: auto;
        display: flex;
        align-items: center;
    }

    .lang-switch--mobile {
        display: inline-flex;
        order: 2;
        margin-left: auto;
        margin-right: 16px;
    }

    .navbar-header {
        float: none;
        order: 3;
    }

    .custom-collapse.navbar-collapse {
        order: 4;
        flex-basis: 100%;
    }

    .nav.navbar-nav > li.lang-switch-item {
        display: none !important;
    }

    /* A touch bigger than the original 90px-tall desktop logo would look on a
       small header, and vertically centered via .navbar's flex align-items */
    .brand-logo img {
        height: 70px;
    }

    /* Grows a little further once the nav goes sticky on scroll, same idea
       as the desktop menu-sticky treatment, just scoped to mobile sizes */
    .menu-sticky .brand-logo img {
        height: 80px !important;
    }
}

@media (max-width: 420px) {
    .lang-switch__btn {
        padding: 7px 8px;
    }

    .brand-logo img {
        height: 60px;
    }

    .menu-sticky .brand-logo img {
        height: 68px !important;
    }

    .lang-switch--floating {
        top: 12px;
        right: 12px;
    }
}
