/* Root canvas also paints Safari's overscroll and safe areas. */
html{background-color:#090a14!important;min-height:100%;color-scheme:dark}
html body{background-color:#090a14!important;min-height:100vh;min-height:100dvh}
@media(max-width:760px){
 body .auth-login .auth-panel{padding-top:calc(28px + env(safe-area-inset-top,0px));padding-bottom:calc(30px + env(safe-area-inset-bottom,0px))}
 body .mobile-menu{padding-top:calc(18px + env(safe-area-inset-top,0px))}
}

/* Keep the visible label within its touch target on narrow screens. */
@media(max-width:760px){
 html body .mobile-nav>.language-picker{gap:3px!important;overflow:hidden!important;box-sizing:border-box!important}
 html body .mobile-nav>.language-picker .language-current{font-size:10px!important;min-width:0!important;white-space:nowrap!important}
 html body .auth-language-picker,html body .floating-language-picker{box-sizing:border-box!important;max-width:calc(100vw - 32px)!important;width:auto!important;gap:6px!important;overflow:hidden!important}
 html body .auth-language-picker .language-current,html body .floating-language-picker .language-current{min-width:0!important;white-space:nowrap!important;line-height:1.4!important;flex:0 1 auto!important}
 html body .auth-language-picker>span[aria-hidden]:first-child,html body .floating-language-picker>span[aria-hidden]:first-child{flex:0 0 auto!important}
}

/* Align the globe and language on one baseline-independent row. */
html body label.auth-language-picker,html body label.floating-language-picker,html body label.calendar-language-picker,html body label.dashboard-language-picker,html body .mobile-nav>label.language-picker{display:flex!important;align-items:center!important;flex-direction:row!important;flex-wrap:nowrap!important;justify-content:center!important}
html body label.auth-language-picker>span,html body label.floating-language-picker>span,html body label.calendar-language-picker>span,html body label.dashboard-language-picker>span,html body .mobile-nav>label.language-picker>span{margin:0!important;padding:0!important;align-self:center!important;line-height:1!important;transform:none!important}
html body label.auth-language-picker>span:first-child,html body label.floating-language-picker>span:first-child,html body label.calendar-language-picker>span:first-child,html body label.dashboard-language-picker>span:first-child,html body .mobile-nav>label.language-picker>span:first-child{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:18px!important;height:18px!important;flex:0 0 18px!important;font-size:15px!important}

html body .language-globe svg{display:block!important;width:18px!important;height:18px!important;flex:none!important;color:#bceaf3}
@media(max-width:760px){
 html body label.calendar-language-picker,html body label.dashboard-language-picker{position:relative!important;display:block!important;box-sizing:border-box!important;width:44px!important;height:40px!important;min-height:40px!important;padding:0!important;overflow:hidden!important;margin-top:0!important;margin-bottom:0!important;line-height:0!important}
 html body label.calendar-language-picker>span.language-globe:first-child,html body label.dashboard-language-picker>span.language-globe:first-child{position:absolute!important;left:50%!important;top:50%!important;transform:translate(-50%,-50%)!important;width:18px!important;height:18px!important;margin:0!important;padding:0!important;line-height:0!important}
 html body label.calendar-language-picker>span.language-current,html body label.dashboard-language-picker>span.language-current{display:none!important}
}

@media(max-width:760px){
 html body.calendar-dashboard header{position:relative!important}
 html body.calendar-dashboard header>label.calendar-language-picker{position:absolute!important;right:58px!important;left:auto!important;top:50%!important;bottom:auto!important;transform:translateY(-50%)!important;margin:0!important;align-self:center!important}
}

/* Billing and other standalone pages: readable language control on dark canvas. */
html body label.floating-language-picker{background:#211b35!important;color:#f3edff!important;border:1px solid #514367!important;border-radius:12px!important;min-height:38px!important;padding:8px 14px!important;gap:8px!important;box-shadow:0 5px 18px rgba(0,0,0,.18)!important}
html body label.floating-language-picker .language-current{color:#f3edff!important;font-size:12px!important;font-weight:750!important;min-width:0!important}
html body label.floating-language-picker .language-globe svg{color:#bceaf3!important}
html body label.floating-language-picker:focus-within{outline:2px solid #bba8ff!important;outline-offset:3px}
html body label.floating-language-picker select option{background:#211b35!important;color:#f3edff!important}
