/* Scoped to the theme's actual mobile navigation; without JS the theme works normally. */
body.ah-menu-motion-active { overflow-anchor: none; }
#masthead .menu-toggle .icon-menu-bars svg.ah-menu-morph { display: inline-block !important; overflow: visible; }
#masthead .menu-toggle.ah-menu-morph-ready .icon-menu-bars svg:not(.ah-menu-morph) { display: none !important; }
#masthead .menu-toggle .ah-menu-morph .ah-menu-line {
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 240ms cubic-bezier(.22,.61,.36,1), opacity 140ms ease;
}
#masthead .menu-toggle[aria-expanded="true"] .ah-menu-line-top { transform: translateY(375%) rotate(45deg); }
#masthead .menu-toggle[aria-expanded="true"] .ah-menu-line-middle { transform: scaleX(0); opacity: 0; }
#masthead .menu-toggle[aria-expanded="true"] .ah-menu-line-bottom { transform: translateY(-375%) rotate(-45deg); }

#masthead #site-navigation.ah-nav-animated {
  transition: margin-top 300ms cubic-bezier(.4,0,.2,1);
}
#masthead #site-navigation.ah-nav-animated .main-nav {
  display: block !important;
  max-height: none !important;
  overflow: hidden;
  visibility: hidden;
  opacity: 0;
  transition: height 300ms cubic-bezier(.4,0,.2,1), opacity 220ms ease, visibility 0s linear 300ms;
}
#masthead #site-navigation.ah-nav-animated .main-nav > ul { display: block !important; }
#masthead #site-navigation.ah-nav-animated.toggled .main-nav {
  overflow-y: auto;
  visibility: visible;
  opacity: 1;
  transition: height 260ms cubic-bezier(.22,.61,.36,1), opacity 180ms ease, visibility 0s;
}
@media (prefers-reduced-motion: reduce) {
  #masthead .menu-toggle .ah-menu-morph .ah-menu-line,
  #masthead #site-navigation.ah-nav-animated,
  #masthead #site-navigation.ah-nav-animated .main-nav { transition: none !important; }
}
