/* Language switcher (DaletForge theme/language-switcher: toggle + list of real <a> links, current language marked,
   flags) and the language list inside the burger panel. Flags are decorative (aria-hidden): the language name is the label. */
.flag{display:inline-block;flex:none;width:24px;height:16px;border-radius:2px;box-shadow:0 0 0 1px rgba(0,0,0,.18);background-size:cover;background-position:center}
.flag-us{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 20'%3E%3Crect width='30' height='20' fill='%23B22234'/%3E%3Cpath d='M0 2.3h30M0 5.4h30M0 8.5h30M0 11.6h30M0 14.7h30M0 17.8h30' stroke='%23fff' stroke-width='1.54'/%3E%3Crect width='12' height='10.8' fill='%233C3B6E'/%3E%3Cg fill='%23fff'%3E%3Ccircle cx='2' cy='2' r='.6'/%3E%3Ccircle cx='5' cy='2' r='.6'/%3E%3Ccircle cx='8' cy='2' r='.6'/%3E%3Ccircle cx='11' cy='2' r='.6'/%3E%3Ccircle cx='3.5' cy='4.2' r='.6'/%3E%3Ccircle cx='6.5' cy='4.2' r='.6'/%3E%3Ccircle cx='9.5' cy='4.2' r='.6'/%3E%3Ccircle cx='2' cy='6.4' r='.6'/%3E%3Ccircle cx='5' cy='6.4' r='.6'/%3E%3Ccircle cx='8' cy='6.4' r='.6'/%3E%3Ccircle cx='11' cy='6.4' r='.6'/%3E%3Ccircle cx='3.5' cy='8.6' r='.6'/%3E%3Ccircle cx='6.5' cy='8.6' r='.6'/%3E%3Ccircle cx='9.5' cy='8.6' r='.6'/%3E%3C/g%3E%3C/svg%3E")}
.flag-fr{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 3 2'%3E%3Crect width='1' height='2' fill='%23002654'/%3E%3Crect x='1' width='1' height='2' fill='%23fff'/%3E%3Crect x='2' width='1' height='2' fill='%23CE1126'/%3E%3C/svg%3E")}
.flag-de{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 5 3'%3E%3Crect width='5' height='1' fill='%23000'/%3E%3Crect y='1' width='5' height='1' fill='%23DD0000'/%3E%3Crect y='2' width='5' height='1' fill='%23FFCE00'/%3E%3C/svg%3E")}
.flag-es{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 750 500'%3E%3Crect width='750' height='500' fill='%23AA151B'/%3E%3Crect y='125' width='750' height='250' fill='%23F1BF00'/%3E%3C/svg%3E")}
.flag-pt{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 400'%3E%3Crect width='600' height='400' fill='%23FF0000'/%3E%3Crect width='240' height='400' fill='%23006600'/%3E%3Ccircle cx='240' cy='200' r='80' fill='none' stroke='%23FFFF00' stroke-width='22'/%3E%3Cpath d='M205 160h70v60a35 35 0 0 1-70 0z' fill='%23fff' stroke='%23FF0000' stroke-width='14'/%3E%3C/svg%3E")}

/* Desktop switcher in the header utilities */
.lang-switcher{position:relative}
.lang-switcher__toggle{display:inline-flex;align-items:center;gap:.5rem;min-height:44px;padding:.5rem .75rem;border:1px solid var(--line);border-radius:var(--nav-radius);background:#fff;color:var(--nav-ink);font:500 .9375rem/1.2 var(--font-body);cursor:pointer;transition:background-color 200ms ease,border-color 200ms ease}
.lang-switcher__toggle:hover,.lang-switcher__toggle[aria-expanded="true"]{background:var(--nav-hover-bg);border-color:var(--line-strong)}
.lang-switcher__toggle .mega-nav__arrow{transition:transform 200ms ease}
.lang-switcher__toggle[aria-expanded="true"] .mega-nav__arrow{transform:rotate(180deg)}
.lang-switcher__dropdown{position:absolute;top:calc(100% + .5rem);right:0;z-index:100;min-width:210px;margin:0;padding:.4rem;list-style:none;background:#fff;border:1px solid var(--line);border-radius:var(--panel-radius);box-shadow:0 12px 40px rgba(16,24,40,.16)}
.lang-switcher__dropdown[hidden]{display:none!important}
.lang-switcher__dropdown li{max-width:none;margin:0}
.lang-switcher__option,.mobile-lang__option{display:flex;align-items:center;gap:.75rem;min-height:44px;padding:.6rem .9rem;border-radius:calc(var(--panel-radius) - 2px);color:var(--ink);text-decoration:none;font-weight:500}
.lang-switcher__option:hover{background:var(--surface-2);color:var(--primary-dark)}
.lang-switcher__option:focus-visible,.mobile-lang__option:focus-visible{background:var(--surface-2);outline:3px solid var(--focus);outline-offset:2px}
.lang-switcher__option[aria-current="true"],.mobile-lang__option[aria-current="true"]{background:var(--surface-2);color:var(--primary-dark);font-weight:700}
.lang-switcher__option[aria-current="true"]::after,.mobile-lang__option[aria-current="true"]::after{content:"\2713" / "";margin-left:auto;color:var(--primary)}

/* Burger panel language list (<=1023px) */
.mobile-lang{padding:1rem 1.25rem .5rem;border-bottom:1px solid var(--line)}
.mobile-lang__title{margin:0 0 .5rem;font:700 .875rem/1.3 var(--font-body);letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.mobile-lang__list{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:.25rem;list-style:none;margin:0;padding:0}
.mobile-lang__list li{max-width:none;margin:0}
.mobile-lang__option{padding-inline:.6rem}
@media (max-width:1023px){.header-utilities .lang-switcher{display:none}}
