/* ===================================
   iOS MOBILE MENU FIX
   ===================================

   Fixes menu button not working on iPhone 16 Pro Max
   and other iOS devices
*/

/* Ensure menu button is clickable on iOS */
.w-nav-button,
.navbar1_menu-button,
.menu-icon1 {
  cursor: pointer !important;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1) !important;
  -webkit-touch-callout: none !important;
  -webkit-user-select: none !important;
  user-select: none !important;
  /* Ensure it's above other elements */
  position: relative !important;
  z-index: 1001 !important;
  /* Make sure touch events work */
  pointer-events: auto !important;
  touch-action: manipulation !important;
}

/* Ensure the menu button container has proper dimensions for touch */
.navbar1_menu-button {
  min-width: 44px !important; /* iOS recommended touch target size */
  min-height: 44px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 8px !important;
}

/* Fix for iOS Safari fixed navbar touch issues */
@supports (-webkit-touch-callout: none) {
  /* iOS-specific styles */
  .navbar1_component {
    -webkit-transform: translate3d(0, 0, 0) !important;
    transform: translate3d(0, 0, 0) !important;
  }

  .w-nav-button {
    -webkit-transform: translate3d(0, 0, 0) !important;
    transform: translate3d(0, 0, 0) !important;
  }
}

/* Ensure menu overlay doesn't block the button */
.w-nav-overlay {
  pointer-events: none !important;
}

.w-nav-overlay[data-nav-menu-open] {
  pointer-events: auto !important;
}

/* Make sure menu is properly positioned on mobile */
@media (max-width: 991px) {
  .navbar1_menu,
  .w-nav-menu {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    background: white !important;
    z-index: 1000 !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    transform: translateX(100%) !important;
    transition: transform 0.3s ease-in-out !important;
  }

  .navbar1_menu.w--open,
  .w-nav-menu.w--open {
    transform: translateX(0) !important;
    pointer-events: auto !important;
  }

  /* Ensure menu links are clickable */
  .navbar1_link,
  .w-nav-link {
    cursor: pointer !important;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.05) !important;
    touch-action: manipulation !important;
    min-height: 44px !important;
    display: flex !important;
    align-items: center !important;
  }

  /* Fix navbar container on mobile */
  .navbar1_container {
    position: relative !important;
    z-index: 1001 !important;
  }
}

/* Additional iOS-specific touch improvements */
@media (max-width: 991px) {
  /* Remove iOS tap delay */
  a,
  button,
  .w-nav-button,
  .navbar1_menu-button,
  .w-nav-link,
  .navbar1_link {
    -ms-touch-action: manipulation !important;
    touch-action: manipulation !important;
  }

  /* Ensure proper stacking context */
  .navbar1_component {
    isolation: isolate !important;
  }
}

/* Force hardware acceleration on iOS for smoother animations */
.navbar1_menu,
.w-nav-menu,
.navbar1_menu-button,
.w-nav-button {
  -webkit-transform: translateZ(0) !important;
  transform: translateZ(0) !important;
  -webkit-backface-visibility: hidden !important;
  backface-visibility: hidden !important;
}

/* Fix for iOS 15+ (including iPhone 16 Pro Max) */
@supports (height: 100dvh) {
  @media (max-width: 991px) {
    .navbar1_menu,
    .w-nav-menu {
      height: 100dvh !important;
    }
  }
}

/* Ensure menu icon lines are visible and clickable */
.menu-icon1_line-top,
.menu-icon1_line-middle,
.menu-icon1_line-bottom {
  pointer-events: none !important;
  -webkit-backface-visibility: hidden !important;
  backface-visibility: hidden !important;
}

/* Active state for better iOS feedback */
.navbar1_menu-button:active,
.w-nav-button:active {
  opacity: 0.7 !important;
  transform: scale(0.95) !important;
}
