/* ==========================================================
   [custom_nav_menu]
   Colors: #000000 text · #D2AE5B hover/active · #f7f7f7 submenu bg
   ========================================================== */

.custom-nav {
	display: flex;
	align-items: center;
}

.custom-menu {
	display: flex;
	align-items: center;
	gap: 2rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.custom-menu li {
	position: relative;
}

.custom-menu > li > a {
	display: flex;
	align-items: center;
	gap: 6px;
	color: #000000;
	text-decoration: none;
	font-weight: 400;
	font-size: 16px;
	padding: 8px 0;
	transition: color 0.15s ease;
}

.custom-menu > li > a:hover,
.custom-menu > li.current-menu-item > a,
.custom-menu > li.current-menu-parent > a,
.custom-menu > li.custom-open > a {
	color: #D2AE5B;
}

/* Chevron for items with children */
.custom-menu li.menu-item-has-children > a::after {
	content: '';
	width: 7px;
	height: 7px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	margin-top: -4px;
	transition: transform 0.15s ease;
}

.custom-menu li.menu-item-has-children:hover > a::after,
.custom-menu li.menu-item-has-children.custom-open > a::after {
	transform: rotate(225deg);
	margin-top: 3px;
}

/* Dropdown panel */
.custom-menu .sub-menu {
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 180px;
	margin: 0;
	padding: 0;
	list-style: none;
	background: #f7f7f7;
	box-shadow: 0 4px 12px rgba(0,0,0,0.08);
	opacity: 0;
	visibility: hidden;
	transform: translateY(4px);
	transition: opacity 0.12s ease, transform 0.12s ease, visibility 0.12s ease;
	z-index: 100;
}

.custom-menu li.menu-item-has-children:hover > .sub-menu,
.custom-menu li.menu-item-has-children.custom-open > .sub-menu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
	transition: opacity 0.12s ease, transform 0.12s ease, visibility 0.12s ease;
}

.custom-menu .sub-menu li a {
	display: block;
	padding: 14px 20px;
	color: #000000;
	text-decoration: none;
	font-size: 15px;
	border-bottom: 1px solid #ececec;
	white-space: nowrap;
	transition: color 0.15s ease, background 0.15s ease;
}

.custom-menu .sub-menu li:last-child a {
	border-bottom: none;
}

.custom-menu .sub-menu li a:hover,
.custom-menu .sub-menu li.current-menu-item a {
	color: #FFFFFF;
	background: #D2AE5B;
}

/* Mobile toggle button — hidden on desktop */
.custom-nav-toggle {
	display: none;
	flex-direction: column;
	gap: 5px;
	background: none;
	border: none;
	cursor: pointer;
	padding: 6px;
}

.custom-nav-toggle-bar {
	width: 24px;
	height: 2px;
	background: #000000;
}

@media (max-width: 880px) {
	.custom-nav-toggle {
		display: flex;
	}

	.custom-menu {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		flex-direction: column;
		align-items: stretch;
		gap: 0;
		background: #ffffff;
		box-shadow: 0 8px 16px rgba(0,0,0,0.08);
	}

	.custom-nav.custom-nav-open .custom-menu {
		display: flex;
	}

	.custom-menu > li > a {
		padding: 14px 20px;
		border-bottom: 1px solid #f0f0f0;
	}

	.custom-menu .sub-menu {
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		box-shadow: none;
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.15s ease;
	}

	.custom-menu li.menu-item-has-children.custom-open > .sub-menu {
		max-height: 600px;
	}
}

/* Visually hidden label for the toggle (in case the parent theme's rule is off) */
.custom-nav .screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}
