/*
 * LEAD BOX ID (authbox) -> admin-core. authbox is built on the core components directly,
 * so the LEAD BOX tokens from core.css apply as is; only the shell hand-over lives here:
 * hiding the server sidebar once the shell is mounted, the user footer and first-paint geometry.
 */

/* Ready: the shell owns sidebar + header; the server sidebar is the no-JS fallback only. */
html.authbox-admin-ready .ab-side{display:none}
html.authbox-admin-ready .ab-app.suite-shell-page{display:block;min-height:100vh}
html.authbox-admin-ready .ab-main{padding:0}

/* User footer moved into the shell: avatar + name/email, logout icon button. */
.suite-shell .ab-foot{display:flex;align-items:center;gap:6px;padding:12px 0 4px}
.suite-shell .ab-foot .suite-shell-user{flex:1;min-width:0;padding:4px}
.suite-shell .ab-foot .suite-shell-user small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.suite-shell .ab-foot form{margin:0;flex:none}
.suite-shell .ab-foot-logout.suite-button{display:grid;place-items:center;width:var(--admin-control-sm);min-height:var(--admin-control-sm);padding:0;border-color:transparent;background:transparent;color:var(--admin-side-muted)}
.suite-shell .ab-foot-logout.suite-button:hover{background:var(--admin-danger-bg);border-color:transparent;color:var(--admin-danger)}
.suite-shell .ab-foot-logout svg{width:18px;height:18px}
@media(min-width:801px){html[data-nav=compact] .suite-shell .ab-foot{flex-direction:column;gap:4px}}
/* Core hides the footer on phones; authbox keeps sign-out reachable under the section strip. */
@media(max-width:800px){
 .suite-shell-side>.suite-shell-footer.ab-foot{display:flex;margin-top:10px;padding:10px 0 0}
 html.authbox-admin-ready .ab-app.suite-shell-page{min-height:0;padding:20px 16px 40px}
}

/* Same geometry before and after hydration: no flash of the fallback sidebar. */
html.authbox-admin-pending .ab-side{display:none}
html.authbox-admin-pending .ab-app{display:block;margin:0 0 0 var(--admin-shell-width);padding:88px 32px 40px}
html.authbox-admin-pending .ab-main{padding:0}
@media(min-width:801px){
 html.authbox-admin-pending .ab-app::before{content:"";box-sizing:border-box;position:fixed;inset:0 auto 0 0;width:var(--admin-shell-width);background:var(--admin-side-bg);border-right:1px solid var(--admin-side-line)}
 html.authbox-admin-pending .ab-app::after{content:"";box-sizing:border-box;position:fixed;inset:0 0 auto var(--admin-shell-width);height:64px;background:var(--admin-bg);border-bottom:1px solid var(--admin-line-soft)}
}
@media(max-width:800px){html.authbox-admin-pending .ab-app{margin:0;padding:20px 16px 40px}}
@media print{html.authbox-admin-ready .ab-app.suite-shell-page,html.authbox-admin-pending .ab-app{margin:0;padding:0}}
