/* Site menu: a panel that slides in from the right, next to the Menu button.
   Loaded on every page after the theme and page styles, so it wins over them. */

#menu.ahehc-flyout {
    position: fixed;
    inset: 0;
    left: 0 !important;
    width: 100%;
    height: 100%;
    z-index: 9999;
    padding: 0 !important;
    overflow: hidden;
    transform: none !important;
    background: rgba(0, 0, 0, 0.35) !important;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#menu.ahehc-flyout.active {
    opacity: 1;
    visibility: visible;
}

#menu .ahehc-flyout__panel {
    position: absolute;
    top: 0;
    right: 0;
    width: min(360px, 100%);
    max-width: none;
    height: 100%;
    margin: 0;
    padding: 96px 32px 32px;
    box-sizing: border-box;
    overflow-y: auto;
    background: #fbfaf9;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.15);
    transform: translateX(100%);
    transition: transform 0.35s ease;
}

#menu.ahehc-flyout.active .ahehc-flyout__panel {
    transform: translateX(0);
}

/* The theme's header is a full-width bar; here it only holds the Close button */
#menu .ahehc-flyout__header {
    position: static;
    width: auto;
    max-width: none;
    margin: 0;
    padding: 0 !important;
    background: none !important;
}

#menu .ahehc-flyout__body {
    display: block;
    height: auto;
    overflow: visible;
    padding: 0 !important;
}

/* Close sits where the Menu button was, so the pointer doesn't have to move */
#menu .js-close {
    position: absolute;
    top: 20px;
    right: 20px;
}

#menu .ahehc-flyout__body,
#menu .ahehc-flyout__primary,
#menu .ahehc-wizard-nav,
#menu .ahehc-wizard-nav ul.menu {
    width: auto !important;
    margin: 0;
    padding: 0;
}

#menu .ahehc-wizard-nav ul.menu {
    list-style: none;
}

#menu .menu-item {
    margin: 0;
    padding: 0;
    border-top: 1px solid rgba(0, 0, 0, 0.12);
}

#menu .menu-item:last-child {
    border-bottom: 1px solid rgba(0, 0, 0, 0.12);
}

#menu .menu-item-link {
    display: block;
    padding: 0.7rem 0 !important;
    font-size: 1.25rem !important;
    line-height: 1.3;
    font-weight: 400;
    text-decoration: none;
}

#menu .menu-item-link:hover,
#menu .menu-item-link:focus-visible {
    color: #800000;
}

#menu .menu-search {
    display: none;
}
