/* Locale bar (inc/locale-bar.php, assets/locale-bar.js). A white panel with Ink text and an Ink button: it stands
   out on the dark campaign photos as well as on light pages (a dark panel disappeared on the photos, 3.12.2026).
   Brand Book 2.0: panel corners 4 px, buttons and fields with square corners, at least 44 px high, focus always
   visible. Fixed over the page, so nothing below it moves; above the support chat button (switch-slack-chat,
   z-index 999999), which it covers on phones only while it is shown. */
.sw-locale-bar{position:fixed;z-index:1000000;left:50%;bottom:calc(16px + env(safe-area-inset-bottom,0px));width:min(480px,calc(100% - 32px));box-sizing:border-box;transform:translate(-50%,16px);opacity:0;transition:opacity .25s ease,transform .25s ease;background:var(--sw-white);color:var(--sw-ink);border:1px solid rgba(17,17,17,.12);border-radius:4px;box-shadow:0 12px 40px rgba(0,0,0,.35);font:400 14px/1.5 var(--sw-font-body)}
.sw-locale-bar.is-visible{transform:translate(-50%,0);opacity:1}
.sw-locale-bar.is-leaving{transition-duration:.2s;opacity:0}
/* The heading with the close button beside it, the list and the button under it, all from the left. */
.sw-locale-bar__inner{display:grid;grid-template-columns:minmax(0,1fr) 44px;align-items:start;gap:16px 8px;padding:20px 8px 20px 20px;text-align:left}
.sw-locale-bar__text{grid-column:1;grid-row:1;padding-top:10px}
.sw-locale-bar p{margin:0;color:inherit}
.sw-locale-bar .sw-locale-bar__title{font-size:16px;font-weight:700;line-height:1.25}
.sw-locale-bar__form{grid-column:1/-1;grid-row:2;display:flex;align-items:center;justify-content:flex-start;gap:8px;max-width:100%;margin:0}
/* The list of versions with flags: a button, the list opens upwards (the bar is at the bottom of the screen). */
.sw-locale-pick{position:relative;flex:0 1 auto;min-width:0}
.sw-locale-bar .sw-locale-pick__button{display:inline-flex;align-items:center;gap:8px;max-width:100%;height:44px;margin:0;padding:0 12px;box-sizing:border-box;border:1px solid var(--sw-ink);border-radius:0;background:var(--sw-white);color:var(--sw-ink);font:400 14px/1.25 var(--sw-font-body);cursor:pointer;white-space:nowrap}
/* The theme writes every button in capitals (base.css, !important); the names in the list keep their case. */
.sw-locale-bar .sw-locale-pick .sw-locale-pick__button{text-transform:none!important}
.sw-locale-bar .sw-locale-pick__button:hover{background:var(--sw-paper)}
.sw-locale-pick__text{overflow:hidden;text-overflow:ellipsis}
.sw-locale-pick__chevron{flex:0 0 auto;margin-left:4px;transition:transform .15s ease}
.sw-locale-pick.is-open .sw-locale-pick__chevron{transform:rotate(180deg)}
.sw-locale-pick__list{position:absolute;z-index:1;left:0;bottom:calc(100% + 4px);width:max-content;min-width:100%;max-width:calc(100vw - 32px);margin:0;padding:4px 0;box-sizing:border-box;list-style:none;background:var(--sw-white);color:var(--sw-ink);border:1px solid rgba(17,17,17,.12);border-radius:4px;box-shadow:0 8px 24px rgba(0,0,0,.28)}
.sw-locale-pick__list[hidden]{display:none}
.sw-locale-pick__option{display:flex;align-items:center;gap:8px;min-height:44px;margin:0;padding:0 16px 0 12px;cursor:pointer;white-space:nowrap}
.sw-locale-pick__option:hover,.sw-locale-pick__option:focus{background:var(--sw-paper);outline:none}
.sw-locale-pick__option:focus-visible{box-shadow:inset 0 0 0 2px var(--sw-orange)}
.sw-locale-pick__option[aria-selected="true"]{font-weight:700}
.sw-locale-flag{flex:0 0 auto;width:24px;height:16px;border-radius:2px;box-shadow:0 0 0 1px rgba(0,0,0,.15)}
.sw-locale-flag.is-globe{box-shadow:none}
.sw-locale-bar .sw-locale-bar__go{min-height:44px;margin:0;padding:0 20px;border:0;border-radius:0;background:var(--sw-ink);color:var(--sw-white);font:700 14px/1.25 var(--sw-font-body);cursor:pointer;white-space:nowrap}
.sw-locale-bar .sw-locale-bar__go:hover{background:#333}
.sw-locale-bar .sw-locale-bar__close{grid-column:2;grid-row:1;display:flex;align-items:center;justify-content:center;width:44px;height:44px;margin:-8px 0 0;padding:0;border:0;border-radius:0;background:none;color:var(--sw-ink);cursor:pointer}
.sw-locale-bar .sw-locale-bar__close:hover{background:var(--sw-paper)}
.sw-locale-bar button:focus-visible{outline:2px solid var(--sw-orange);outline-offset:2px}

/* After the bar flies away: the switcher it went to is pointed out for a moment. */
.sw-locale-found{outline:2px solid var(--sw-orange);outline-offset:4px;animation:sw-locale-found .8s ease-in-out 3}
@keyframes sw-locale-found{50%{outline-offset:1px}}
.sw-locale-hint{position:absolute;z-index:1000001;max-width:240px;padding:8px 12px;background:var(--sw-white);color:var(--sw-ink);border-radius:4px;box-shadow:0 4px 16px rgba(0,0,0,.24);font:700 12px/1.25 var(--sw-font-body);transition:opacity .3s ease}
.sw-locale-hint::before{content:"";position:absolute;top:-6px;left:var(--sw-locale-arrow,50%);width:12px;height:12px;margin-left:-6px;background:inherit;transform:rotate(45deg)}
.sw-locale-hint.is-leaving{opacity:0}

/* Phones: closer to the edges. */
@media(max-width:599px){
.sw-locale-bar{bottom:calc(8px + env(safe-area-inset-bottom,0px));width:calc(100% - 16px)}
.sw-locale-bar__inner{padding:16px 4px 16px 16px}
.sw-locale-bar__form{padding-right:12px}
}
@media(prefers-reduced-motion:reduce){
.sw-locale-bar{transition:opacity .2s ease;transform:translate(-50%,0)}
.sw-locale-found{animation:none}
}
