
/* ===== FA IOS SCROLL GUARD V1 ===== */

/* Root halaman tidak boleh ikut rubber-band */
html,
body{
  width:100%;
  height:100%;
  margin:0;
  padding:0;
  overflow:hidden !important;
  overscroll-behavior:none !important;
}

/* Safari iPad/iPhone: kunci viewport utama */
body{
  position:fixed !important;
  inset:0 !important;
  width:100vw !important;
  height:100vh !important;
  height:100dvh !important;
  max-height:100dvh !important;
}

/* Yang boleh scroll hanyalah screen aktif */
.screen.active{
  box-sizing:border-box !important;

  width:100% !important;

  height:100vh !important;
  height:100dvh !important;

  min-height:100vh !important;
  min-height:100dvh !important;

  max-height:100vh !important;
  max-height:100dvh !important;

  overflow-x:hidden !important;
  overflow-y:auto !important;

  overscroll-behavior-x:none !important;
  overscroll-behavior-y:contain !important;

  -webkit-overflow-scrolling:touch;
}

/* Screen yang tidak aktif jangan ikut membentuk tinggi halaman */
.screen:not(.active){
  overflow:hidden !important;
}

/* Hindari gambar/dekorasi memperlebar viewport */
.screen.active img,
.screen.active video,
.screen.active canvas,
.screen.active svg{
  max-width:100%;
}

/* Safe area bawah iPhone/iPad */
.screen.active{
  padding-bottom:max(
    8px,
    env(safe-area-inset-bottom)
  );
}

/* ===== END FA IOS SCROLL GUARD V1 ===== */
