/**
 * Impact Legacy — header navigation enhancements.
 *
 * Deliberately minimal, and deliberately NOT relying on the Navigation
 * block's JSON ":hover" style support — that block-supports API is
 * inconsistently honoured across WordPress core versions, so every
 * interactive state below is implemented as plain CSS instead.
 *
 * IMPORTANT: this file does not add any hover-based reveal for the
 * "More" submenu. WordPress core's Navigation block already opens
 * submenus on click/tap and via keyboard (Enter/Space to open, arrow
 * keys to move between items, Escape to close) — that behaviour is
 * built into wp-includes/js/dist/block-library, not something a theme
 * should override. Do not add a ":hover { display: block }" style to
 * .wp-block-navigation__submenu-container — it would break keyboard
 * and touch users by making the submenu appear/disappear on mouse
 * movement alone, contrary to WCAG 2.1.4.13.
 */

/* Sticky header must sit above article content, images, and any
   in-page dropdowns beneath it. */
.impact-legacy-header {
	z-index: 9000;
}

/* Top-level nav links: white by default, gold on hover/focus, gold
   while the submenu they own is open, gold for the current page. */
.impact-legacy-primary-nav .wp-block-navigation-item__content {
	color: #FFFFFF;
	padding-top: 0.4rem;
	padding-bottom: 0.4rem;
	transition: color 0.15s ease;
}

.impact-legacy-primary-nav .wp-block-navigation-item__content:hover,
.impact-legacy-primary-nav .wp-block-navigation-item__content:focus,
.impact-legacy-primary-nav .wp-block-navigation-item__content:focus-visible {
	color: #C9A24B;
}

.impact-legacy-primary-nav .current-menu-item > .wp-block-navigation-item__content,
.impact-legacy-primary-nav .wp-block-navigation-item__content[aria-current="page"] {
	color: #C9A24B;
}

/* The "More" toggle itself gets the same gold state while its panel
   is open (aria-expanded="true"), so it's visually obvious which
   item the open dropdown belongs to. */
.impact-legacy-primary-nav .wp-block-navigation-submenu > .wp-block-navigation-item__content[aria-expanded="true"] {
	color: #C9A24B;
}

/* Dropdown ("More") submenu panel — appearance only; open/close
   behaviour is left entirely to WordPress core. */
.impact-legacy-primary-nav .wp-block-navigation__submenu-container {
	background-color: #0B0B0A;
	border: 1px solid #2A2822;
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
	padding: 0.5rem 0;
	min-width: 220px;
	z-index: 9100;
}

.impact-legacy-primary-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: 0.6rem 1.25rem;
}

.impact-legacy-primary-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:hover,
.impact-legacy-primary-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:focus {
	color: #C9A24B;
	background-color: rgba(201, 162, 75, 0.08);
}

/* Mobile/tablet overlay (hamburger menu) — sits above everything,
   and submenu items get more vertical padding for comfortable
   touch targets (WCAG 2.5.5, min. 44x44px tap area). */
.impact-legacy-primary-nav .wp-block-navigation__responsive-container.is-menu-open {
	z-index: 9999;
}
.impact-legacy-primary-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	padding-top: 0.9rem;
	padding-bottom: 0.9rem;
}
