/* Zainstalowana aplikacja (standalone): bez górnego paska strony. Zwykła przeglądarka bez zmian. */
@media (display-mode: standalone){
#site-header,#top-bar-wrap,#top-bar,#site-header-sticky-wrapper,#mobile-dropdown,#mobile-fullscreen,#mobile-sidr,.sidr,.oceanwp-mobile-menu-icon,#wpadminbar{display:none!important}
html{margin-top:0!important}
body{padding-top:env(safe-area-inset-top,0px)}
}
html.nw-standalone #site-header,html.nw-standalone #top-bar-wrap,html.nw-standalone #top-bar,html.nw-standalone #site-header-sticky-wrapper,html.nw-standalone #mobile-dropdown,html.nw-standalone #mobile-fullscreen,html.nw-standalone #mobile-sidr,html.nw-standalone .sidr,html.nw-standalone .oceanwp-mobile-menu-icon,html.nw-standalone #wpadminbar{display:none!important}
html.nw-standalone{margin-top:0!important}
html.nw-standalone body{padding-top:env(safe-area-inset-top,0px)}
.nw-standalone-back{position:fixed;z-index:99990;top:calc(env(safe-area-inset-top,0px) + 10px);left:12px;display:inline-flex;align-items:center;min-height:44px;padding:0 16px;border-radius:999px;background:#242b21;border:1px solid #3e4937;color:#f4f6ee;font:700 14px/1 Karla,system-ui,sans-serif;text-decoration:none;box-shadow:0 2px 8px rgba(0,0,0,.25)}
.nw-standalone-back:focus-visible{outline:2px solid #a3cb3b;outline-offset:2px}
html.nw-standalone body.nw-has-back,body.nw-has-back{padding-top:calc(env(safe-area-inset-top,0px) + 64px)}

/* Ekran ładowania (jak makieta loader.html) – tylko w zainstalowanej aplikacji, do DOMContentLoaded; awaryjnie znika sam po 5 s. */
@media (display-mode: standalone){
html::before{content:"";position:fixed;z-index:2147483000;left:50%;top:calc(50% - 118px);width:120px;height:120px;margin-left:-60px;border-radius:28px;background:#fff url(icons/icon-192.png) center/96px no-repeat;box-shadow:0 0 40px rgba(163,203,59,.25),0 0 0 120vmax #111510;animation:nw-splash-out .25s 5s forwards}
html::after{content:"";position:fixed;z-index:2147483001;left:50%;top:calc(50% + 38px);width:36px;height:36px;margin-left:-22px;border-radius:50%;border:4px solid #3e4937;border-top-color:#a3cb3b;animation:nw-splash-spin .9s linear infinite,nw-splash-out .25s 5s forwards}
body::before{content:"Ładowanie…";position:fixed;z-index:2147483001;left:0;right:0;top:calc(50% + 100px);text-align:center;color:#f4f6ee;opacity:.75;font:400 15px/1.2 Karla,Arial,sans-serif;letter-spacing:.3px;animation:nw-splash-out .25s 5s forwards}
body.nw-load-training::before{content:"Ładowanie treningu…"}
html.nw-ready::before,html.nw-ready::after,html.nw-ready body::before{display:none!important}
}
@keyframes nw-splash-spin{to{transform:rotate(360deg)}}
@keyframes nw-splash-out{to{opacity:0;visibility:hidden}}
@media (prefers-reduced-motion:reduce){html::after{animation:nw-splash-out .25s 5s forwards!important}}
