/* Company and modules share the top row; study content keeps the viewport. */
.app-header .header-inner{display:grid;grid-template-columns:auto minmax(0,1fr) auto;max-width:none;min-height:56px;padding:4px 16px;gap:16px}
.study-active.study-nav-hidden .app-header{display:block}
.app-header .brand{display:none}
.app-header .company-switch{grid-column:1;margin:0;padding:3px;gap:2px;border-radius:8px}
.app-header .company-switch button{min-width:80px;min-height:40px;padding:6px 10px;font-size:.86rem}
.app-header .main-nav{grid-column:2;grid-row:1;display:flex;min-width:0;min-height:48px;margin:0;padding:0;gap:4px;overflow-x:auto;overflow-y:hidden;background:transparent;border:0;scrollbar-width:thin;scrollbar-color:#8094ab #172c46}
.app-header .main-nav a{min-height:44px;padding:0 12px;gap:6px;white-space:nowrap;color:#dce6f1;font-size:.87rem;border-radius:6px;flex-shrink:0}
.app-header .main-nav a:hover{background:#29435e;color:#fff}
.app-header .main-nav a[aria-current=page]{background:#fff;color:var(--ink)}
.app-header .main-nav a[aria-current=page]:after{display:none}
.app-header .nav-icon{width:17px;height:17px}
.header-actions{grid-column:3;grid-row:1;display:flex;align-items:center;gap:8px}
.app-header #sync-entry,.app-header #study-nav-toggle{min-height:44px;width:auto;padding:7px 10px;font-size:.8rem;white-space:nowrap}
.app-header #sync-entry .button-label{display:none}
.app-header #study-nav-toggle{background:transparent;color:#eaf1f8;border-color:#66798f}
.app-header #study-nav-toggle:hover{background:#29435e}
.app-header[data-study-active=true][data-modules-hidden=true] .main-nav{display:none}
.app-header[data-study-active=true][data-modules-hidden=true] .header-actions{margin-left:auto}
.study-active #account-bar{display:none}
.study-active main{margin-top:12px}
.account-bar{margin-top:8px;padding-block:6px}
@media(max-width:759px){
 .app-header .header-inner{gap:4px 8px;padding:4px 12px;min-height:52px;grid-template-columns:minmax(0,1fr) auto}
 .app-header .company-switch{justify-self:start}
 .app-header .company-switch button{min-width:76px;padding-inline:8px}
 .app-header .header-actions{grid-column:2;gap:6px}
 .app-header .main-nav{grid-column:1/-1;grid-row:2;min-height:44px;gap:2px}
 .app-header .main-nav a{padding-inline:10px;font-size:.82rem}
}
