/* ==========================================================================
   Selecteur de langue (header navbar)
   ========================================================================== */

.mdm-lang-switcher {
    position: relative;
    display: inline-block;
    font-family: var(--m-font-body);
    font-size: 13px;
}

.mdm-lang-switcher__current {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 999px;
    color: var(--m-ink, #4A3832);
    cursor: pointer;
    font: inherit;
    transition: background .15s ease, border-color .15s ease;
}
.mdm-lang-switcher__current:hover,
.mdm-lang-switcher__current[aria-expanded="true"] {
    background: rgba(74, 56, 50, .06);
    border-color: rgba(74, 56, 50, .12);
}

.mdm-lang-switcher__code {
    font-weight: 700;
    letter-spacing: .04em;
    font-size: 11px;
}

.mdm-lang-switcher__caret {
    font-size: 10px;
    opacity: .6;
    margin-left: 2px;
}

/* Menu deroulant */
.mdm-lang-switcher__menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin: 4px 0 0;
    padding: 4px;
    list-style: none;
    background: #fff;
    border: 1px solid rgba(74, 56, 50, .12);
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(74, 56, 50, .08);
    min-width: 160px;
    z-index: 100;

    /* Etat ferme par defaut */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity .15s ease, transform .15s ease, visibility .15s;
}
.mdm-lang-switcher.is-open .mdm-lang-switcher__menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.mdm-lang-switcher__link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 5px;
    color: var(--m-ink, #4A3832);
    text-decoration: none;
    transition: background .12s ease;
}
.mdm-lang-switcher__link:hover,
.mdm-lang-switcher__link:focus-visible {
    background: rgba(74, 56, 50, .06);
    text-decoration: none;
    outline: none;
}
.mdm-lang-switcher__link.is-active {
    background: rgba(213, 154, 90, .14);
    color: var(--m-gold, #D8A85F);
    font-weight: 500;
}
.mdm-lang-switcher__link.is-active::after {
    content: "✓";
    margin-left: auto;
    color: var(--m-gold, #D8A85F);
    font-weight: 700;
}

.mdm-lang-switcher__menu .mdm-lang-switcher__code {
    min-width: 22px;
    padding: 1px 6px;
    background: rgba(74, 56, 50, .06);
    border-radius: 3px;
    text-align: center;
    font-size: 10px;
}

.mdm-lang-switcher__menu .mdm-lang-switcher__label {
    flex: 1;
    font-size: 13px;
}

/* Sur mobile : selecteur compact, label cache dans le bouton */
@media (max-width: 600px) {
    .mdm-lang-switcher__current { padding: 6px 8px; }
}
