/* Bound the page itself, including loading, menu, footer and static fallback.
   The background and carousel remain clipped by their own scene containers. */
@media (max-width:800px), (pointer:coarse) {
 html,html.portrait-story,html.mobile-home {
  width:100%;max-width:100%;overflow-x:hidden;overscroll-behavior-x:none;
 }
 /* A root overflow lock alone lets iOS pan the body from empty scene edges.
    Fix the whole document until the shared story actually reaches its end. */
 .portrait-story.story-locked body {position:fixed;inset:0;width:100%;height:100%;overflow:hidden;}
 body {width:100%;max-width:100%;overscroll-behavior-x:none;}
 main,.story,.stage,.site-footer {max-width:100%;min-width:0;}
 #mobile-nav,.mobile-menu-links,[data-native-scroll] {overflow-x:hidden;overscroll-behavior-x:none;}
 .portrait-story .program-gallery {touch-action:pan-y pinch-zoom;overscroll-behavior-x:none;}
 .mobile-home .program-gallery {overscroll-behavior-x:contain;}
}
