/* V50.1: toolbar and theme corrections; no changes to login or printable documents. */
html.app-active{--v501-fg:#263e50;--v501-muted:#607687;--v501-panel:#fff;--v501-border:#d6e3eb;--v501-hover:#eaf3fa;--v501-header:#f8fbfd}
html.app-active.v46-dark{--v501-fg:#e4edf5;--v501-muted:#b1c3d2;--v501-panel:#152738;--v501-border:#354d60;--v501-hover:#203c52;--v501-header:#101f2d}
html.app-active #appShell .topbar{background:var(--v501-header)!important;border-color:var(--v501-border)!important;color:var(--v501-fg)!important;overflow:visible!important;gap:10px!important}
html.app-active #appShell .topbar .top-actions{gap:7px!important;flex:0 0 auto;min-width:0!important;margin-left:auto!important;align-items:center!important}
html.app-active #appShell .topbar #globalSearchBtn{flex:1 1 380px!important;min-width:0!important;max-width:480px!important;width:auto!important;overflow:hidden!important}
html.app-active #appShell .topbar #globalSearchBtn>span:nth-child(2){min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html.app-active #appShell .topbar #v50Quick,html.app-active #appShell .topbar #v50Fav{display:inline-flex!important;align-items:center;justify-content:center;gap:6px;width:auto!important;min-width:0!important;flex:0 0 auto!important;padding:0 11px!important;white-space:nowrap;font-size:12px!important;height:40px!important;border-radius:9px!important}
html.app-active #appShell .topbar #v50Quick{color:#fff!important;background:#176ca6!important;border-color:#176ca6!important}
html.app-active #appShell .topbar #v50Quick:hover{background:#105c91!important}
html.app-active #appShell .topbar #v50Fav{color:var(--v501-fg)!important;background:var(--v501-panel)!important;border-color:var(--v501-border)!important}
html.app-active #appShell .topbar #v50Fav.v501-pinned svg{fill:#176ca620;stroke:var(--v50-blue)}
html.app-active #appShell .topbar #v50Quick svg,html.app-active #appShell .topbar #v50Fav svg{width:16px!important;height:16px!important;flex:none}
html.app-active #appShell .topbar #v50Quick svg:last-child{width:12px!important}
html.app-active #appShell .topbar #v46Theme svg{width:18px!important;height:18px!important}
html.app-active #appShell .topbar #profileBtn{gap:8px!important;white-space:nowrap!important}
html.app-active #appShell .topbar #profileBtn strong{font-size:12px!important;font-weight:500!important}
html.app-active #appShell .topbar #profileBtn small{font-size:10px!important}
html.app-active #sidebar .sidebar-brand{position:relative!important;display:flex!important;align-items:center!important;justify-content:space-between!important;gap:5px!important;padding:12px!important}
html.app-active #sidebar .sidebar-brand .sidebar-logo{min-width:0;max-width:calc(100% - 36px)!important;object-fit:contain}
@media(min-width:901px){html.app-active #sidebar #v46Collapse{display:grid!important;place-items:center;width:28px!important;height:28px!important;min-width:28px!important;flex:0 0 28px!important;padding:0!important;border:1px solid var(--v501-border)!important;background:var(--v501-panel)!important;color:var(--v501-fg)!important;border-radius:8px!important;cursor:pointer}html.app-active #sidebar #v46Collapse:hover{background:var(--v501-hover)!important}html.app-active #sidebar #v46Collapse svg{width:17px!important;height:17px!important}html.app-active.v46-collapsed #sidebar .sidebar-brand{flex-direction:column;justify-content:center!important;height:88px!important;padding:6px!important;gap:5px!important}html.app-active.v46-collapsed #sidebar .sidebar-brand .sidebar-logo{max-width:48px!important;width:48px!important}html.app-active #appShell .topbar #menuBtn{display:none!important}}
.v501-popover{position:fixed;z-index:1600;width:min(284px,calc(100vw - 16px));overflow:auto;padding:6px;background:var(--v501-panel,#fff);color:var(--v501-fg,#263e50);border:1px solid var(--v501-border,#d6e3eb);border-radius:12px;box-shadow:0 12px 35px #081b3530;animation:v50drop .18s ease-out;font-size:13px}
.v501-pop-title{padding:11px 10px 9px;font-size:13px;font-weight:500;border-bottom:1px solid var(--v501-border);margin-bottom:4px}
.v501-pop-section{padding:10px 10px 4px;color:var(--v501-muted);font-size:10px;letter-spacing:.5px;text-transform:uppercase}
.v501-pop-item{display:flex;align-items:center;gap:10px;text-align:left;width:100%;padding:10px;border:0;background:transparent;color:inherit;border-radius:7px;cursor:pointer;font-size:12px;font-weight:400;min-height:38px}
.v501-pop-item>span{flex:1;min-width:0;overflow-wrap:anywhere}.v501-pop-item svg{width:17px;height:17px;flex:none;color:var(--v50-blue,#176ca6)}.v501-pop-item:hover,.v501-pop-item:focus-visible{background:var(--v501-hover);outline:none}.v501-pop-item:disabled{color:var(--v501-muted);cursor:default;opacity:.75}
/* The old white page-head rule had !important; scope overrides to active dark workspace. */
html.app-active.v46-dark #appShell .page-head:not(.dashboard-head){background:var(--v501-panel)!important;border-color:var(--v501-border)!important;color:var(--v501-fg)!important}
html.app-active.v46-dark #appShell .page-head .page-title,html.app-active.v46-dark #appShell .page-head h1,html.app-active.v46-dark #appShell .mail-view-head h3,html.app-active.v46-dark #appShell .mail-list-head h3,html.app-active.v46-dark #appShell .ai-head h3{color:var(--v501-fg)!important}
html.app-active.v46-dark #appShell .page-head .eyebrow,html.app-active.v46-dark #appShell .page-head .page-sub,html.app-active.v46-dark #appShell .mail-meta,html.app-active.v46-dark #appShell .mail-meta span{color:var(--v501-muted)!important}
html.app-active.v46-dark #appShell .mail-view-head,html.app-active.v46-dark #appShell .mail-list-head,html.app-active.v46-dark #appShell .ai-head{background:var(--v501-panel)!important;color:var(--v501-fg)!important;border-color:var(--v501-border)!important}
@media(max-width:1150px){html.app-active #appShell .topbar #v50Fav>span{display:none!important}html.app-active #appShell .topbar #v50Fav{padding:0 9px!important}}
@media(max-width:900px){html.app-active #sidebar #v46Collapse{display:none!important}html.app-active #sidebar .sidebar-brand{padding-right:46px!important}html.app-active #appShell .topbar #globalSearchBtn{flex:0 0 32px!important;width:32px!important;min-width:32px!important;max-width:32px!important}html.app-active #appShell .topbar .top-actions{gap:4px!important}html.app-active #appShell .topbar #v50Fav{display:none!important}html.app-active #appShell .topbar #v50Quick{display:inline-flex!important;padding:0 6px!important;height:34px!important;font-size:11px!important}html.app-active #appShell .topbar #v50Quick svg:last-child{display:none!important}html.app-active #appShell .topbar #v46Theme{width:32px!important;min-width:32px!important;flex:0 0 32px!important}html.app-active #appShell .topbar #notificationBtn,html.app-active #appShell .topbar #mailQuickBtn{display:grid!important;min-width:30px!important;width:30px!important;flex:0 0 30px!important}html.app-active #appShell .topbar .v36-profile-switch{display:none!important}html.app-active #appShell .topbar #profileBtn{width:33px!important;min-width:33px!important;flex:0 0 33px!important}}
@media(prefers-reduced-motion:reduce){.v501-popover{animation:none!important}}
@media(min-width:901px) and (max-width:1150px){html.app-active #appShell .topbar #profileBtn{width:42px!important;min-width:42px!important;max-width:42px!important;padding:4px!important;justify-content:center!important}html.app-active #appShell .topbar #profileBtn>span:nth-child(2),html.app-active #appShell .topbar #profileBtn>span:last-child{display:none!important}html.app-active #appShell .topbar .v36-profile-switch{width:42px!important;min-width:42px!important;padding:0!important;justify-content:center!important}html.app-active #appShell .topbar .v36-profile-switch>span:last-child{display:none!important}html.app-active #appShell .topbar .period-select{width:95px!important;min-width:95px!important;padding:0 8px!important}html.app-active #appShell .topbar #globalSearchBtn{flex:1 1 120px!important}}
@media(max-width:900px){html.app-active #appShell.app-shell{grid-template-columns:minmax(0,1fr)!important}html.app-active #appShell .main-shell{grid-column:1!important;min-width:0!important;width:100%!important}html.app-active #appShell .topbar #menuBtn{display:grid!important;place-items:center!important}}
