/* Pulpit i nawigacja: spójny próg tablet/telefon składany = 960 px. */
#command,#command .cd-home-grid,#command .cd-home-grid>*,#command .cd-home-head>*,#command .cd-home-event>*,#command .sectionhead>*{min-width:0;max-width:100%;box-sizing:border-box}
#command .cd-home-info-line>*,#command .cd-home-hint,#command .cd-home-number,#command .cd-home-event-title{overflow-wrap:anywhere}
@media(min-width:761px){
 #command .cd-home-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,340px),1fr))!important}
 #command .cd-home-head-side{flex:0 1 auto}
 #command .cd-home-head-side button{max-width:100%;white-space:normal}
 #command .sectionhead{flex-wrap:wrap}
 #command .cd-home-event{flex-wrap:wrap}
 #command .cd-home-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(min-width:761px) and (max-width:959px){
 body:has(#dashboard:not(.hidden)){padding-bottom:calc(78px + env(safe-area-inset-bottom))!important}
 .shell:has(#dashboard:not(.hidden)){width:100%!important;max-width:100%!important;margin:0!important;padding:12px 16px 24px!important;box-sizing:border-box}
 #dashboard{min-width:0;max-width:100%}
 #dashboard .pkx-nav-primary{display:none!important}
 #dashboard .pkx-toolbar{display:flex!important;flex-wrap:wrap;min-width:0}
 #dashboard .pkx-nav-right{flex:1 1 100%;display:flex;flex-wrap:wrap;justify-content:flex-end;gap:6px;min-width:0}
 #pkxMobileNav{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));position:fixed;z-index:860;bottom:0;left:0;right:0;padding:6px 12px calc(6px + env(safe-area-inset-bottom));background:#142337;border-top:1px solid #3b566d;gap:6px;box-sizing:border-box}
 #pkxMobileNav button{display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-width:0;min-height:49px;padding:4px!important;border:1px solid transparent!important;border-radius:9px!important;background:transparent!important;color:#adc0d3!important;font-size:11px!important;line-height:1.2}
 #pkxMobileNav button.active{background:#28435f!important;color:#f0f7ff!important;border-color:#365c7e!important}
 #pkxMobileMore:not(.hidden){display:grid!important;position:fixed;z-index:865;left:max(16px,calc((100vw - 560px)/2));right:max(16px,calc((100vw - 560px)/2));bottom:calc(74px + env(safe-area-inset-bottom));background:#142337;color:#e9f3ff;border:1px solid #49627b;border-radius:12px;box-shadow:0 10px 38px #0008}
 #command .cd-home-hero{padding:22px}
}
/* 1.11.4: mały pasek statusu; pełne menu w dolnej nawigacji układu kompaktowego. */
@media(max-width:1179px){
 body:has(#dashboard:not(.hidden)){padding-bottom:calc(78px + env(safe-area-inset-bottom))!important}
 .top{height:48px!important;min-height:48px!important;padding:5px 12px!important;box-sizing:border-box}
 .top h1{font-size:19px!important}.top .themebar{display:none!important}
 .shell:has(#dashboard:not(.hidden)){width:100%!important;max-width:100%!important;margin:0!important;padding:8px 12px 24px!important;box-sizing:border-box}
 #dashboard>.pkx-nav-primary,#dashboard .pkx-toolbar .pkx-nav-primary{display:none!important}
 #dashboard .pkx-toolbar{position:sticky!important;top:48px!important;display:flex!important;align-items:center!important;justify-content:flex-end!important;flex-wrap:nowrap!important;gap:6px!important;min-height:38px!important;height:auto!important;padding:4px 7px!important;margin:0 0 8px!important;box-sizing:border-box}
 #dashboard .pkx-nav-right{display:flex!important;flex:0 1 auto!important;align-items:center!important;justify-content:flex-end!important;flex-wrap:nowrap!important;gap:5px!important;border:0!important;padding:0!important;min-width:0!important;min-height:28px!important}
 #dashboard .pkx-nav-right #logout{display:none!important}
 #dashboard .pkx-presence-toggle,#dashboard .pkx-cloud{font-size:10px!important;min-height:27px!important;padding:5px 7px!important;margin:0!important;white-space:nowrap!important;max-width:180px!important;box-sizing:border-box}
 #dashboard .pkx-cloud{max-width:min(48vw,190px)!important}
 #dashboard #pkxCloudText{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 #pkxMobileNav{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));position:fixed;z-index:860;bottom:0;left:0;right:0;padding:6px 8px calc(6px + env(safe-area-inset-bottom));background:#142337;border-top:1px solid #3b566d;gap:4px;box-sizing:border-box}
 #pkxMobileNav button{display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-width:0;min-height:49px;padding:4px!important;border:1px solid transparent!important;border-radius:9px!important;background:transparent!important;color:#adc0d3!important;font-size:11px!important;line-height:1.2}
 #pkxMobileNav button.active{background:#28435f!important;color:#f0f7ff!important;border-color:#365c7e!important}
 body.pkx-more-open{overflow:hidden}
 #pkxMobileMoreBackdrop:not(.hidden){display:block!important;position:fixed;inset:0;background:rgba(3,10,18,.6);z-index:864}
 #pkxMobileMore:not(.hidden){display:grid!important;position:fixed;z-index:865;left:max(12px,calc((100vw - 560px)/2));right:max(12px,calc((100vw - 560px)/2));bottom:calc(74px + env(safe-area-inset-bottom));background:#142337;color:#e9f3ff;border:1px solid #49627b;border-radius:12px;box-shadow:0 10px 38px #0008;box-sizing:border-box;padding:14px!important;gap:12px!important;max-height:calc(100dvh - 110px)!important;overflow:auto;overscroll-behavior:contain}
 #pkxMobileMore .pkx-more-head{display:flex;align-items:center;justify-content:space-between;gap:12px}
 #pkxMobileMore #pkxMobileMoreClose{display:flex!important;align-items:center;justify-content:center;min-width:38px;min-height:38px!important;padding:5px!important;background:transparent!important;border-color:transparent!important}
 #pkxMobileMore .pkx-more-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 #pkxMobileMore .pkx-more-grid button{display:flex!important;align-items:center;gap:8px;min-width:0;min-height:49px!important;font-size:12px!important;line-height:1.25;white-space:normal!important;padding:9px 10px!important;border:1px solid #36516a!important;background:#21374f!important;color:#eaf4ff!important;border-radius:9px}
 #pkxMobileMore .pkx-more-grid button.active{border-color:#75c5df!important;background:#254961!important}
 #pkxMobileMore .pkx-more-footer{display:flex;align-items:center;justify-content:space-between;padding-top:10px;border-top:1px solid #36516a;gap:12px}
 #pkxMobileMore .pkx-more-footer>span{font-size:11px;color:#afc1d2}
 #pkxMobileMore #pkxMobileLogout{min-height:36px!important;padding:6px 10px!important;background:transparent!important;font-size:11px!important;color:#eaf4ff}
}
@media(min-width:1180px){
 #pkxMobileNav,#pkxMobileMore,#pkxMobileMoreBackdrop{display:none!important}
 #dashboard>.pkx-nav-primary{display:flex!important;position:fixed!important;left:0!important;top:56px!important;bottom:0!important;flex-direction:column!important;align-items:stretch!important;width:66px!important;overflow-y:auto!important;z-index:790;padding:8px 6px;box-sizing:border-box;background:var(--panel,#142337)}
 body.baza-sidebar-expanded #dashboard>.pkx-nav-primary{width:211px!important}
 #dashboard>.pkx-nav-primary .pkx-pulpit-group{width:100%;display:flex!important;flex-direction:column!important;align-items:stretch!important}
 #dashboard>.pkx-nav-primary .cd-submenu-items{position:static!important;display:flex!important;flex-direction:column!important;min-width:0!important;width:100%!important}
 #dashboard .pkx-toolbar{max-height:58px}
}
@media(max-width:1179px){
 body.baza-sidebar-expanded .shell:has(#dashboard:not(.hidden)),body .shell:has(#dashboard:not(.hidden)){padding-left:12px!important;padding-right:12px!important}
}
