header{position:relative}.language-switch{display:flex;justify-content:flex-end;gap:4px;padding:10px 20px;margin:0 auto;max-width:1040px}.language-switch button{font:600 12px/1.4 system-ui,sans-serif;background:#f7eee8;color:#654858;border:1px solid #c7adb8;border-radius:7px;padding:7px 11px;box-shadow:none;min-height:32px;cursor:pointer}.language-switch button[aria-pressed=true]{background:#795360;color:#fff}.language-switch button:focus-visible{outline:3px solid #b1839c;outline-offset:3px}.adventure-header{flex-wrap:wrap}.adventure-header .language-switch{margin:0;padding:0}.brand:empty{display:none}html[lang=fr-CA] .blox-section-tabs button{font-size:14px}html[lang=fr-CA] #sharedCoinNote{font-size:12px}html[lang=fr-CA] .brand>span:last-child:empty{display:none}@media(max-width:600px){.language-switch{padding:8px 14px}.language-switch button{font-size:12px}}

/* Keep complete navigation labels visible in both languages. */
header nav{flex-wrap:wrap;overflow:visible;min-width:0;row-gap:6px}header nav a{flex:0 0 auto;max-width:100%;white-space:normal}header:not(.site-header):not(.adventure-header){flex-wrap:wrap}header:not(.site-header):not(.adventure-header) nav{flex:1 1 650px}header:not(.site-header):not(.adventure-header) .language-switch{flex:0 0 auto;margin-left:auto;margin-right:0}@media(max-width:760px){header nav{column-gap:5px}header nav a{padding:10px 12px}header:not(.site-header):not(.adventure-header) nav{width:100%}}

/* One shared, consistently placed language control across all page shells. */
header{position:relative}
header .language-switch{position:absolute;top:22px;right:max(16px,calc((100% - 1040px)/2));z-index:4;display:flex;flex-wrap:nowrap;align-items:center;justify-content:flex-end;gap:6px;max-width:none;margin:0;padding:0}
header .language-switch button{min-height:44px;padding:9px 12px;font:600 13px/1.3 Arial,sans-serif;white-space:nowrap;border-radius:8px;border:1px solid #a97788;background:#fffaf6;color:#62283b;box-shadow:none}
header .language-switch button[aria-pressed=true]{background:#8d5265;border-color:#8d5265;color:#fffdf9}
header .language-switch button:focus-visible{outline:3px solid #62283b;outline-offset:3px}
.site-header .brand{padding-right:175px;min-height:90px}
.site-header .brand a{min-width:0;max-width:100%}
.site-header .brand-icon{flex-shrink:0}
header:not(.site-header):not(.adventure-header):not(.grade-header){flex-wrap:wrap;align-items:center}
header:not(.site-header):not(.adventure-header):not(.grade-header)>.logo{max-width:calc(100% - 175px);margin-right:175px}
header:not(.site-header):not(.adventure-header):not(.grade-header)>nav{flex:1 1 100%;width:100%}
.adventure-header{padding-top:78px!important}
.adventure-header .language-switch{top:18px;right:4vw}
.language-source-note{margin:0;padding:12px max(20px,calc((100% - 1040px)/2));background:#f1e8df;color:#624d54;border-bottom:1px solid #ddcbd0;font:14px/1.6 Arial,sans-serif}
@media(max-width:650px){header .language-switch{right:16px;top:22px}header .language-switch button{font-size:12px;padding:9px 10px}.site-header .brand{padding-right:158px;min-height:92px}.site-header .brand a{font-size:21px;line-height:1.3}.site-header .brand-icon{width:30px;height:32px;font-size:23px}.adventure-header .language-switch{right:16px;top:14px}.grade-header .language-switch{right:12px;top:22px}}
@media(max-width:340px){.site-header .brand{padding-right:0;padding-top:70px}.grade-header .language-switch{top:67px}header:not(.site-header):not(.adventure-header):not(.grade-header)>.logo{max-width:100%;margin-right:0}header:not(.site-header):not(.adventure-header):not(.grade-header){padding-top:76px}}
/* Anchor language buttons to the page edge rather than the content column. */
header .language-switch{right:24px!important;left:auto!important}
@media(max-width:650px){header .language-switch{right:16px!important}}
