/* ACE shell: the behaviour Elementor's scripts gave the header menu and the drawer (ruling A5, playbook 3.2 and 3.6).
   Linked by SiteLayout on every page with a header, after the page's own CSS. The drawer script is in
   src/components/MobileDrawer.astro. */

/* Header dropdowns: hover, keyboard focus, and the script's click state (.ace-sub-open). */
.elementor-location-header .elementor-nav-menu--main .menu-item-has-children:hover > ul,
.elementor-location-header .elementor-nav-menu--main .menu-item-has-children:focus-within > ul,
.elementor-nav-menu .menu-item-has-children.ace-sub-open > ul {
  display: block;
}
.elementor-location-header .elementor-nav-menu--main .elementor-nav-menu > li > ul {
  top: 100%;
  width: auto;
  min-width: 12em;
  z-index: 100;
}
.elementor-nav-menu .sub-arrow {
  cursor: pointer;
}

/* Drawer submenus: the script opens them on click; until it has bound (data-ace-ready), keyboard focus opens them.
   :focus-visible, not :focus-within: a pointer press focuses the link too, and the submenu opening under it re-centres
   the drawer, so the release would land on another item and the tap would go nowhere. */
.elementor-popup-modal:not([data-ace-ready]) .menu-item-has-children:has(:focus-visible) > ul {
  display: block;
}

/* The drawer dialog: hidden until opened by the script (.ace-open) or, without script, by its link (:target). */
#elementor-popup-modal-2052 {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  overflow: auto;
}
#elementor-popup-modal-2052:target,
#elementor-popup-modal-2052.ace-open {
  display: flex;
}
#elementor-popup-modal-2052 .dialog-widget-content {
  position: relative;
  width: 100%;
}
#elementor-popup-modal-2052 [data-elementor-type='popup'] {
  display: block;
}
#elementor-popup-modal-2052 .dialog-close-button {
  position: absolute;
  align-items: center;
  justify-content: center;
  line-height: 1;
  color: #1f2124;
  text-decoration: none;
  cursor: pointer;
}
html.ace-drawer-open {
  overflow: hidden;
}
