/* Blue/orange language control, shared across the public site. */
.locale-switcher summary {
 gap: 10px;
 min-height: 48px;
 padding: 10px 15px;
 border: 1px solid #cbdfee;
 border-radius: 12px;
 background: linear-gradient(135deg, #ffffff 20%, #edf6fe 100%);
 box-shadow: 0 4px 14px #082d500a, inset 0 1px 0 #ffffff;
 color: #082d50;
 font-size: 15px;
 font-weight: 700;
 transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.locale-switcher summary::before {
 content: '';
 display: block;
 flex: 0 0 25px;
 width: 25px;
 height: 25px;
 border-radius: 50%;
 background: #e1effc url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23006dc7' stroke-width='1.6' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='8'/%3E%3Cellipse cx='12' cy='12' rx='3.5' ry='8'/%3E%3Cpath d='M4 12h16M5.5 7.5h13M5.5 16.5h13'/%3E%3C/svg%3E") center / 22px 22px no-repeat;
}
.locale-switcher summary::after {
 content: '';
 width: 7px;
 height: 7px;
 flex: 0 0 7px;
 margin-inline-start: 3px;
 margin-block-start: -4px;
 border-right: 2px solid #006dc7;
 border-bottom: 2px solid #006dc7;
 transform: rotate(45deg);
 transition: transform .18s ease;
}
.locale-switcher summary:hover, .locale-switcher[open] summary {
 border-color: #8ebde3;
 background: linear-gradient(135deg, #fff 0%, #e8f3fd 100%);
 box-shadow: 0 5px 18px #082d5012, inset 0 -2px 0 #ff8a00;
}
.locale-switcher[open] summary::after { transform: translateY(4px) rotate(225deg); }
.locale-switcher .locale-options {
 inset-block-start: calc(100% + 10px);
 padding: 8px;
 min-width: 205px;
 border: 1px solid #d6e4f0;
 border-radius: 14px;
 box-shadow: 0 14px 40px #082d501c, 0 3px 8px #082d5008;
 background: #fff;
}
.locale-switcher .locale-options a {
 position: relative;
 border-radius: 8px;
 padding: 11px 16px;
 font-size: 15px;
 font-weight: 600;
 line-height: 1.4;
 transition: background .15s ease, color .15s ease;
}
.locale-switcher .locale-options a:hover, .locale-switcher .locale-options a:focus-visible { background: #f0f6fc; color: #006dc7; }
.locale-switcher .locale-options a[aria-current=page] { background: #eaf3fc; color: #006dc7; }
.locale-switcher .locale-options a[aria-current=page]::before {
 content: '';
 position: absolute;
 inset-inline-start: 0;
 inset-block: 13px;
 width: 3px;
 border-radius: 3px;
 background: #ff8a00;
}
@media(max-width:680px) {
 .locale-switcher summary { gap: 7px; min-height: 42px; padding: 8px 10px; border-radius: 10px; font-size: 13px; }
 .locale-switcher summary::before { flex-basis: 20px; width: 20px; height: 20px; background-size: 19px; }
 .locale-switcher .locale-options { min-width: 185px; }
}
@media(prefers-reduced-motion:reduce) {
 .locale-switcher summary, .locale-switcher summary::after, .locale-switcher .locale-options a { transition:none; }
}

/* Keep the enhanced language control within narrow headers. */
@media(max-width: 680px) {
 body.brand-blue .topbar[data-resources-header] { display:flex; gap:10px; padding-inline:12px; }
 body.brand-blue .topbar[data-resources-header] > .brand { flex:1 1 auto; min-width:0; max-width:180px; }
 body.brand-blue .topbar[data-resources-header] .brand-logo { width:100%; max-width:180px; }
 body.brand-blue .topbar[data-resources-header] .brand-logo img { width:100%; height:auto; }
 body.brand-blue .topbar[data-resources-header] .mobile-menu { flex:0 0 32px; margin-inline-start:auto; margin-inline-end:0; }
 body.brand-blue .topbar[data-resources-header] .locale-switcher { flex:0 0 auto; margin:0; }
 html[lang=ar] .topbar[data-resources-header] .locale-options { right:auto; left:0; }
}
