/* Mobile scrolling fixes for UCIC Orientation */
/* ============================================ */

/* iOS momentum scrolling for all scrollable containers */
html, body, .container, .slides-container, [class*="scroll"] {
  -webkit-overflow-scrolling: touch;
}

/* Prevent double-tap zoom on interactive elements */
.slides-container, .slide-content, .container, .nav a, .card, .flow-step, .toc-link {
  touch-action: manipulation;
}

/* Safe area insets for notched iOS devices */
body {
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}

/* Ensure fixed overlays don't trap touch events */
.scanlines::after, .noise::before {
  pointer-events: none !important;
  touch-action: none;
}

/* Fix 100dvh fallback for older browsers */
.slides-container, .h-dvh, .min-h-dvh, [class*="dvh"] {
  height: 100vh;
  height: 100dvh;
}
.min-h-dvh {
  min-height: 100vh;
  min-height: 100dvh;
}

/* Prevent text size adjust on orientation change (iOS) */
html {
  -webkit-text-size-adjust: 100%;
}

/* Ensure overflow containers work on mobile */
.slides-container {
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

/* Smooth page scroll for non-slide pages */
html {
  scroll-behavior: smooth;
}
