/* =========================================================
   PAKTOGRAF PWA SCROLL V2
   A normal page scrolls on the document; true open overlays keep their lock.
   ========================================================= */

html.pg-pwa-scroll-unlocked,
html.pg-pwa-scroll-unlocked body {
  overflow-x: hidden !important;
  overflow-y: auto !important;
  height: auto !important;
  max-height: none !important;
  min-height: 100dvh !important;
  position: relative !important;
  touch-action: pan-x pan-y !important;
  overscroll-behavior-y: auto !important;
  -webkit-overflow-scrolling: touch !important;
}

html.pg-pwa-scroll-unlocked body #page,
html.pg-pwa-scroll-unlocked body .site,
html.pg-pwa-scroll-unlocked body .main-page,
html.pg-pwa-scroll-unlocked body #main-container,
html.pg-pwa-scroll-unlocked body #apus-main-content,
html.pg-pwa-scroll-unlocked body .wrapper-main-page,
html.pg-pwa-scroll-unlocked body .site-content,
html.pg-pwa-scroll-unlocked body .main-content,
html.pg-pwa-scroll-unlocked body .page-content {
  height: auto !important;
  max-height: none !important;
  min-height: 0;
  overflow: visible !important;
  touch-action: pan-y !important;
}

/* Verification/account pages must remain scrollable in standalone mode. */
html.pg-pwa-scroll-unlocked body:has(.pgacc-verify),
html.pg-pwa-scroll-unlocked body:has(.pg-verify-wrap),
html.pg-pwa-scroll-unlocked body.page-verifikacija-racuna {
  padding-bottom: max(86px, calc(70px + env(safe-area-inset-bottom))) !important;
}

