:root {
    --nav-gold: #c99a4e;
    --nav-dark: #050505;
    --nav-panel: #090909;
    --nav-hover: #171717;
    --nav-border: rgba(201, 154, 78, .22);
}

/*
 * GLOBAL NAVBAR GEOMETRY LOCK
 * ---------------------------
 * Some legacy pages (Home) already apply border-box globally, while newer
 * pages such as Gallery and News Detail scope box-sizing to page content.
 * When #main-header becomes .scrolled it adds horizontal padding. Without
 * border-box the fixed header becomes wider than the viewport, which makes
 * the whole navbar appear to slide to the right. Keep the header geometry
 * identical on every frontend route without changing the approved scroll
 * animation itself.
 */
#main-header,
#main-header *,
#main-header *::before,
#main-header *::after {
    box-sizing: border-box;
}

/* Desktop keeps the visual language from the original native site. */
#main-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 1400;
    width: 100%;
    padding: 0 !important;
    border-bottom: 0;
    background: transparent;
    transition: background-color .35s ease, padding .35s ease, box-shadow .35s ease, border-color .35s ease;
}

#main-header.scrolled {
    padding: 5px 40px !important;
    background: rgba(5, 5, 5, .88);
    border-bottom: 1px solid rgba(201, 154, 78, .18);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .48);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

#main-header .kc-native-nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1200px !important;
    margin: 0 auto;
    padding: 0 !important;
    box-sizing: border-box;
}

#main-header .logo {
    flex: 1 1 0;
    display: flex;
    align-items: center;
    min-width: 0;
    z-index: 1403;
}

#main-header .logo a {
    display: inline-flex;
    align-items: center;
}

#main-header .logo-img {
    display: block;
    width: auto;
    height: 100px;
    max-width: 260px;
    object-fit: contain;
    transition: height .35s ease, transform .25s ease;
}

#main-header.scrolled .logo-img { height: 65px; }
#main-header .logo-img:hover { transform: scale(1.04); }

#main-header .hamburger,
#main-header .mobile-nav-head,
#main-header .mobile-submenu-toggle,
.nav-backdrop {
    display: none;
}

#main-header .nav-wrapper {
    flex: 3 1 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#main-header nav {
    flex: 2 1 auto;
    display: flex;
    justify-content: center;
    min-width: 0;
}

#main-header nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

#main-header nav > ul {
    display: flex;
    align-items: center;
    gap: clamp(22px, 2.55vw, 35px);
}

#main-header nav > ul > li { position: relative; }
#main-header .nav-item-row { display: flex; align-items: center; }

#main-header .nav-item-row > a {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 0;
    color: #fff;
    text-decoration: none;
    text-transform: uppercase;
    white-space: nowrap;
    font-family: "Montserrat", sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    transition: color .25s ease;
}

#main-header:not(.scrolled) .nav-item-row > a {
    text-shadow: 0 2px 4px rgba(0, 0, 0, .5);
}

#main-header .nav-item-row > a:hover,
#main-header .nav-item-row > a.text-gold,
#main-header .nav-active > .nav-item-row > a {
    color: var(--nav-gold);
}

/* Desktop product dropdown */
#main-header .dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1410;
    width: 220px;
    margin-top: 25px;
    padding: 10px 0;
    border: 1px solid #333;
    border-radius: 6px;
    background: #121212;
    box-shadow: 0 8px 18px rgba(0, 0, 0, .62);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity .2s ease, visibility .2s ease, transform .2s ease;
}

#main-header.scrolled .dropdown-menu { margin-top: 15px; }
html[dir="rtl"] #main-header .dropdown-menu { left: auto; right: 0; }

#main-header .dropdown:hover > .dropdown-menu,
#main-header .dropdown:focus-within > .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#main-header .dropdown-menu::before {
    content: "";
    position: absolute;
    top: -16px;
    left: 0;
    width: 100%;
    height: 16px;
}

#main-header .dropdown-menu li,
#main-header .dropdown-menu li a { width: 100%; }

#main-header .dropdown-menu li a {
    display: block;
    box-sizing: border-box;
    padding: 12px 20px;
    color: #fff;
    text-decoration: none;
    text-transform: capitalize;
    white-space: normal;
    font-family: "Montserrat", sans-serif;
    font-size: 13px;
    line-height: 1.35;
    transition: background-color .2s ease, color .2s ease, padding .2s ease;
}

#main-header .dropdown-menu li a:hover,
#main-header .dropdown-menu li a:focus-visible {
    color: var(--nav-gold);
    background: var(--nav-hover);
    padding-inline-start: 25px;
    outline: 0;
}

/* Language selector keeps the familiar flag treatment on desktop. */
#main-header .nav-right-container {
    flex: 1 1 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 20px;
}

#main-header .language-selector { position: relative; }
#main-header .lang-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    min-height: 42px;
    padding: 4px 8px 4px 4px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: transparent;
    cursor: pointer;
    font-family: "Montserrat", sans-serif;
    transition: background .2s ease, transform .2s ease;
}

#main-header .lang-btn:hover,
#main-header .lang-btn:focus-visible {
    background: rgba(255,255,255,.045);
    outline: 1px solid rgba(201,154,78,.24);
}

#main-header .flag-icon {
    display: block;
    width: 28px;
    height: 28px;
    border: 1px solid #444;
    border-radius: 50%;
    object-fit: cover;
    flex: 0 0 auto;
}

#main-header .main-flag {
    width: 32px;
    height: 32px;
    border-color: var(--nav-gold);
}

#main-header:not(.scrolled) .main-flag { box-shadow: 0 2px 5px rgba(0,0,0,.5); }
#main-header .desktop-lang-label { display: none; font-size: 11px; font-weight: 600; }
#main-header .language-chevron,
#main-header .mobile-chevron {
    width: 7px;
    height: 7px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform .2s ease;
}

#main-header .lang-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 1410;
    min-width: 150px;
    margin: 0;
    padding: 6px 0;
    border: 1px solid #333;
    border-radius: 7px;
    background: #121212;
    box-shadow: 0 8px 18px rgba(0,0,0,.62);
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-7px);
    transition: .2s ease;
    max-height: min(420px, 70vh);
    overflow-y: auto;
}

html[dir="rtl"] #main-header .lang-dropdown { right: auto; left: 0; }
#main-header .language-selector.lang-open .lang-dropdown,
#main-header .language-selector:hover .lang-dropdown,
#main-header .language-selector:focus-within .lang-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#main-header .lang-dropdown a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    color: #fff;
    text-decoration: none;
    white-space: nowrap;
    font-family: "Montserrat", sans-serif;
    font-size: 12px;
}

#main-header .lang-dropdown a:hover,
#main-header .lang-dropdown a.is-current {
    color: var(--nav-gold);
    background: var(--nav-hover);
}

/* Tablet and mobile: functional off-canvas menu, desktop styling stays untouched. */
@media (max-width: 1024px) {
    #main-header,
    #main-header.scrolled {
        padding: 8px 18px !important;
        background: rgba(5, 5, 5, .92);
        border-bottom: 1px solid rgba(201,154,78,.16);
        box-shadow: 0 8px 28px rgba(0,0,0,.34);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
    }

    #main-header .kc-native-nav-container {
        min-height: 66px;
        max-width: 100% !important;
        padding: 0 !important;
    }

    #main-header .logo { flex: 0 1 auto; }
    #main-header .logo-img,
    #main-header.scrolled .logo-img {
        height: 62px;
        max-width: min(215px, 58vw);
    }

    #main-header .hamburger {
        position: relative;
        z-index: 1420;
        margin-inline-start: auto;
        width: 46px;
        height: 46px;
        display: grid;
        place-content: center;
        gap: 5px;
        padding: 0;
        border: 1px solid rgba(201,154,78,.38);
        border-radius: 11px;
        background: rgba(201,154,78,.06);
        cursor: pointer;
        pointer-events: auto;
        touch-action: manipulation;
    }

    #main-header .hamburger span {
        display: block;
        width: 22px;
        height: 1.5px;
        border-radius: 2px;
        background: #fff;
        transition: transform .22s ease, opacity .22s ease;
    }

    #main-header .hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
    #main-header .hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
    #main-header .hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

    #main-header .nav-wrapper {
        position: fixed;
        top: 0;
        left: 0;
        z-index: 1430;
        width: min(370px, 88vw);
        max-width: 88vw;
        height: 100dvh;
        padding: 0;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0;
        overflow-y: auto;
        overscroll-behavior: contain;
        background: linear-gradient(180deg, #0b0b0c, #060606);
        border-right: 1px solid rgba(201,154,78,.2);
        box-shadow: 16px 0 48px rgba(0,0,0,.62);
        transform: translateX(-105%);
        visibility: hidden;
        pointer-events: none;
        transition: transform .3s cubic-bezier(.22,.61,.36,1), visibility .3s ease;
    }

    html[dir="rtl"] #main-header .nav-wrapper {
        left: auto;
        right: 0;
        border-right: 0;
        border-left: 1px solid rgba(201,154,78,.2);
        box-shadow: -16px 0 48px rgba(0,0,0,.62);
        transform: translateX(105%);
    }

    #main-header .nav-wrapper.active {
        transform: translateX(0);
        visibility: visible;
        pointer-events: auto;
    }

    #main-header .mobile-nav-head {
        position: sticky;
        top: 0;
        z-index: 2;
        min-height: 82px;
        padding: 12px 16px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        background: rgba(8,8,9,.98);
        border-bottom: 1px solid rgba(255,255,255,.07);
    }

    #main-header .mobile-nav-brand {
        min-width: 0;
        display: flex;
        align-items: center;
        gap: 10px;
        color: #fff;
        text-decoration: none;
        font: 700 12px/1.2 "Montserrat", sans-serif;
        text-transform: uppercase;
    }

    #main-header .mobile-nav-brand img {
        width: 55px;
        height: 55px;
        object-fit: contain;
        flex: 0 0 auto;
    }

    #main-header .mobile-nav-brand span {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    #main-header .mobile-nav-close {
        position: relative;
        width: 42px;
        height: 42px;
        flex: 0 0 42px;
        border: 1px solid rgba(255,255,255,.12);
        border-radius: 10px;
        background: rgba(255,255,255,.035);
        cursor: pointer;
        touch-action: manipulation;
    }

    #main-header .mobile-nav-close span {
        position: absolute;
        top: 20px;
        left: 11px;
        width: 19px;
        height: 1.5px;
        background: #fff;
    }
    #main-header .mobile-nav-close span:first-child { transform: rotate(45deg); }
    #main-header .mobile-nav-close span:last-child { transform: rotate(-45deg); }

    #main-header nav {
        flex: 0 0 auto;
        width: 100%;
        display: block;
        padding: 12px 18px 6px;
    }

    #main-header nav > ul {
        width: 100%;
        display: block;
    }

    #main-header nav > ul > li {
        width: 100%;
        border-bottom: 1px solid rgba(255,255,255,.065);
    }

    #main-header .nav-item-row { width: 100%; }
    #main-header .nav-item-row > a {
        min-width: 0;
        min-height: 55px;
        flex: 1 1 auto;
        padding: 10px 4px;
        font-size: 13px;
        letter-spacing: .035em;
        text-shadow: none !important;
    }

    #main-header .mobile-submenu-toggle {
        width: 46px;
        height: 46px;
        flex: 0 0 46px;
        display: grid;
        place-items: center;
        border: 1px solid rgba(255,255,255,.07);
        border-radius: 9px;
        color: #ddd;
        background: rgba(255,255,255,.025);
        cursor: pointer;
        touch-action: manipulation;
    }

    #main-header .mobile-submenu-toggle[aria-expanded="true"] .mobile-chevron {
        transform: rotate(225deg) translate(-1px,-1px);
    }

    #main-header .dropdown-menu,
    #main-header.scrolled .dropdown-menu {
        position: static;
        width: 100%;
        max-height: 0;
        margin: 0;
        padding: 0 6px;
        overflow: hidden;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        transition: max-height .28s ease, padding .28s ease;
    }

    #main-header .dropdown:hover > .dropdown-menu,
    #main-header .dropdown:focus-within > .dropdown-menu { max-height: 0; padding-bottom: 0; }

    #main-header .dropdown.submenu-open > .dropdown-menu {
        max-height: 430px;
        padding-bottom: 10px;
    }

    #main-header .dropdown-menu::before { display: none; }
    #main-header .dropdown-menu li a {
        padding: 10px 12px 10px 22px;
        border-left: 1px solid rgba(201,154,78,.22);
        border-radius: 0 8px 8px 0;
        color: #c9c9cb;
        font-size: 12px;
    }

    html[dir="rtl"] #main-header .dropdown-menu li a {
        padding: 10px 22px 10px 12px;
        border-left: 0;
        border-right: 1px solid rgba(201,154,78,.22);
        border-radius: 8px 0 0 8px;
    }

    #main-header .nav-right-container {
        flex: 0 0 auto;
        width: 100%;
        margin-top: auto;
        padding: 18px 18px calc(22px + env(safe-area-inset-bottom));
        border-top: 1px solid rgba(255,255,255,.07);
    }

    #main-header .language-selector { width: 100%; }
    #main-header .lang-btn { display: none; }
    #main-header .lang-dropdown {
        position: static;
        width: 100%;
        min-width: 0;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        padding: 0;
        border: 0;
        background: transparent;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
    }

    #main-header .lang-dropdown a {
        justify-content: center;
        min-height: 48px;
        padding: 9px 10px;
        border: 1px solid rgba(255,255,255,.08);
        border-radius: 10px;
        background: rgba(255,255,255,.025);
    }

    .nav-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1425;
        display: block;
        margin: 0;
        padding: 0;
        border: 0;
        background: rgba(0,0,0,.68);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity .25s ease, visibility .25s ease;
    }

    .nav-backdrop.active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    body.nav-open {
        overflow: hidden !important;
        touch-action: none;
    }
}

@media (max-width: 560px) {
    #main-header,
    #main-header.scrolled { padding-inline: 12px !important; }
    #main-header .kc-native-nav-container { min-height: 60px; }
    #main-header .logo-img,
    #main-header.scrolled .logo-img { height: 54px; max-width: 180px; }
    #main-header .hamburger { width: 44px; height: 44px; }
    #main-header .nav-wrapper { width: min(350px, 92vw); max-width: 92vw; }
}

/* ============================================================================
   PHASE 4C.7D - MOBILE MENU CLICK LAYER + PROFESSIONAL TAP TARGETS
   Important: the backdrop must sit BELOW #main-header. The header creates its
   own stacking context, so a backdrop above z-index 1400 would visually cover
   the drawer and intercept taps even when the drawer itself uses a higher child
   z-index.
   ============================================================================ */
@media (max-width: 1024px) {
    #main-header {
        z-index: 1500 !important;
    }

    .nav-backdrop {
        z-index: 1490 !important;
    }

    #main-header .nav-wrapper {
        z-index: 1510 !important;
        isolation: isolate;
        overflow: hidden !important;
        width: min(400px, 92vw);
        max-width: 92vw;
    }

    #main-header .mobile-nav-head {
        z-index: 3;
        flex: 0 0 auto;
    }

    #main-header nav {
        position: relative;
        z-index: 2;
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        padding: 10px 14px 14px;
    }

    #main-header nav > ul,
    #main-header nav > ul > li,
    #main-header .nav-item-row {
        position: relative;
        z-index: 2;
        pointer-events: auto !important;
    }

    #main-header .nav-item-row {
        min-height: 58px;
        gap: 8px;
        border-radius: 10px;
        transition: background-color .2s ease;
    }

    #main-header .nav-item-row:has(> a:active),
    #main-header .nav-active > .nav-item-row {
        background: rgba(201, 154, 78, .075);
    }

    #main-header .nav-item-row > a {
        position: relative;
        z-index: 3;
        width: 100%;
        min-height: 58px;
        padding: 0 14px !important;
        display: flex;
        align-items: center;
        border-radius: 9px;
        pointer-events: auto !important;
        touch-action: manipulation;
        -webkit-tap-highlight-color: rgba(201,154,78,.18);
        user-select: none;
    }

    #main-header .nav-item-row > a:hover,
    #main-header .nav-item-row > a:focus-visible {
        background: rgba(255,255,255,.035);
        outline: 1px solid rgba(201,154,78,.22);
        outline-offset: -1px;
    }

    #main-header .mobile-submenu-toggle {
        position: relative;
        z-index: 4;
        width: 50px;
        height: 50px;
        flex: 0 0 50px;
        margin-inline-end: 4px;
        pointer-events: auto !important;
    }

    #main-header .dropdown-menu {
        position: relative;
        z-index: 3;
    }

    #main-header .dropdown-menu li,
    #main-header .dropdown-menu li a {
        position: relative;
        z-index: 4;
        pointer-events: auto !important;
    }

    #main-header .dropdown-menu li a {
        min-height: 48px;
        display: flex;
        align-items: center;
        padding-block: 10px !important;
        touch-action: manipulation;
        -webkit-tap-highlight-color: rgba(201,154,78,.18);
    }

    #main-header .nav-right-container {
        position: relative;
        z-index: 4;
        flex: 0 0 auto;
        margin-top: 0;
        background: rgba(7,7,8,.98);
    }

    #main-header .lang-dropdown,
    #main-header .lang-dropdown li,
    #main-header .lang-dropdown a {
        position: relative;
        z-index: 5;
        pointer-events: auto !important;
    }

    #main-header .lang-dropdown a {
        min-height: 50px;
        touch-action: manipulation;
        -webkit-tap-highlight-color: rgba(201,154,78,.18);
    }

    #main-header .mobile-nav-close,
    #main-header .hamburger {
        pointer-events: auto !important;
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    /* Prevent the old body rule from disabling touch gestures inside the menu. */
    body.nav-open {
        overflow: hidden !important;
        touch-action: auto !important;
    }
}

@media (max-width: 560px) {
    #main-header .nav-wrapper {
        width: 100vw;
        max-width: 100vw;
        border-right: 0;
        border-left: 0;
        box-shadow: none;
    }

    #main-header nav {
        padding-inline: 12px;
    }

    #main-header .mobile-nav-head {
        min-height: 72px;
        padding: 9px 12px;
    }

    #main-header .mobile-nav-brand img {
        width: 48px;
        height: 48px;
    }

    #main-header .mobile-nav-brand span {
        font-size: 11px;
    }

    #main-header .nav-right-container {
        padding: 12px 12px calc(14px + env(safe-area-inset-bottom));
    }
}


/* ============================================================================
   PHASE 4C.7E - MOBILE LANGUAGE VISIBILITY + RTL DRAWER POSITION
   ============================================================================ */
#main-header .mobile-language-switcher {
    display: none;
}

@media (max-width: 1024px) {
    /* Do not depend only on html[dir]. The header carries its own locale state,
       so Arabic always opens from the right even if a legacy page injects LTR. */
    #main-header[data-locale="ar"] .nav-wrapper,
    #main-header[dir="rtl"] .nav-wrapper {
        left: auto !important;
        right: 0 !important;
        border-right: 0 !important;
        border-left: 1px solid rgba(201,154,78,.2) !important;
        box-shadow: -16px 0 48px rgba(0,0,0,.62) !important;
        transform: translateX(105%);
    }

    #main-header[data-locale="ar"] .nav-wrapper.active,
    #main-header[dir="rtl"] .nav-wrapper.active {
        transform: translateX(0);
    }

    #main-header[data-locale="ar"] .mobile-nav-head,
    #main-header[data-locale="ar"] nav,
    #main-header[dir="rtl"] .mobile-nav-head,
    #main-header[dir="rtl"] nav {
        direction: rtl;
        text-align: right;
    }

    #main-header[data-locale="ar"] .nav-item-row > a,
    #main-header[dir="rtl"] .nav-item-row > a {
        text-align: right;
        justify-content: flex-start;
    }

    #main-header[data-locale="ar"] .dropdown-menu li a,
    #main-header[dir="rtl"] .dropdown-menu li a {
        text-align: right;
        justify-content: flex-start;
    }

    /* Desktop dropdown language selector is replaced by two always-visible
       mobile buttons. This removes the 'Arabic is hidden below the drawer' issue. */
    #main-header .desktop-language-container {
        display: none !important;
    }

    #main-header .mobile-language-switcher {
        position: relative;
        z-index: 8;
        flex: 0 0 auto;
        width: 100%;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
        gap: 10px;
        padding: 12px 14px calc(14px + env(safe-area-inset-bottom));
        margin-top: auto;
        background: rgba(7,7,8,.995);
        border-top: 1px solid rgba(255,255,255,.08);
        box-shadow: 0 -12px 28px rgba(0,0,0,.22);
    }

    #main-header .mobile-language-option {
        min-width: 0;
        min-height: 52px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 9px;
        padding: 9px 12px;
        color: #d8d8da;
        background: rgba(255,255,255,.035);
        border: 1px solid rgba(255,255,255,.10);
        border-radius: 11px;
        text-decoration: none;
        font: 600 12px/1.2 "Montserrat", sans-serif;
        letter-spacing: .01em;
        pointer-events: auto !important;
        touch-action: manipulation;
        -webkit-tap-highlight-color: rgba(201,154,78,.18);
    }

    #main-header .mobile-language-option:hover,
    #main-header .mobile-language-option:focus-visible {
        color: #fff;
        border-color: rgba(201,154,78,.42);
        background: rgba(201,154,78,.08);
        outline: none;
    }

    #main-header .mobile-language-option.is-current {
        color: var(--nav-gold);
        border-color: rgba(201,154,78,.65);
        background: rgba(201,154,78,.11);
        box-shadow: inset 0 0 0 1px rgba(201,154,78,.06);
    }

    #main-header .mobile-language-option .flag-icon {
        width: 26px;
        height: 26px;
        flex: 0 0 26px;
    }

    #main-header[dir="rtl"] .mobile-language-switcher {
        direction: ltr; /* Language choices stay in configured order. */
    }

    #main-header .mobile-language-option[dir="rtl"] {
        direction: rtl;
    }
}

@media (max-width: 420px) {
    #main-header .mobile-language-switcher {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    #main-header .mobile-language-option {
        min-height: 48px;
    }
}
