/*
 * AISA Site Kit - desktop dropdown menus (Take Action, Learn More).
 * Loaded on every page, after the theme's stylesheets.
 *
 * The theme opens each dropdown 0.5rem below its menu link, with
 * nothing in between, so moving the mouse down to the dropdown
 * crossed empty space and closed it. This:
 *   1. fills that gap with an invisible strip that counts as part of
 *      the dropdown, so the hover is never lost on the way down, and
 *   2. waits a quarter of a second before closing, so a slightly
 *      wobbly mouse doesn't snap it shut.
 * Keyboard users still open it with Tab (focus-within).
 * Scoped to #primary-nav, so the phone menu (#mobile-menu) is untouched.
 */
#primary-nav .nav-item-wrap .sub-menu {
	display: block;
	visibility: hidden;
	opacity: 0;
	transform: translateY(-4px);
	transition: opacity 0.15s ease, transform 0.15s ease, visibility 0s linear 0.25s;
	transition-delay: 0.25s;
}
#primary-nav .nav-item-wrap:hover .sub-menu,
#primary-nav .nav-item-wrap:focus-within .sub-menu {
	visibility: visible;
	opacity: 1;
	transform: none;
	transition-delay: 0s;
}

/* Invisible bridge across the gap between the link and the dropdown. */
#primary-nav .nav-item-wrap .sub-menu::before {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 100%;
	height: calc(0.5rem + 2px);
}
