/* =========================================================
   TOP NAV DROPDOWNS
   Add to your main stylesheet, or load separately for now.
   Only adds new rules — your existing .top_btn / .home_btn /
   .contact_btn styling is left alone.
   ========================================================= */

.nav_has_children {
	position: relative;
	display: inline-block;
}

/* The parent link keeps whatever .top_btn already looks like;
   this just makes room for the caret. */
.nav_has_children > .top_btn {
	display: inline-flex;
	align-items: center;
	gap: 7px;
}

.nav_caret {
	display: inline-block;
	width: 0;
	height: 0;
	border-left: 4px solid transparent;
	border-right: 4px solid transparent;
	border-top: 5px solid currentColor;
	opacity: .7;
	transition: transform .2s ease;
}

.nav_has_children:hover .nav_caret,
.nav_has_children:focus-within .nav_caret {
	transform: rotate(180deg);
}

/* ---------- The dropdown panel ---------- */

.nav_dropdown {
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 200;
	min-width: 230px;
	padding: 8px 0;
	background: #ffffff;
	border: 1px solid #e4e8e8;
	border-radius: 6px;
	box-shadow: 0 14px 34px rgba(24, 25, 41, .16);

	/* hidden but still focusable-in via keyboard */
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity .18s ease, transform .18s ease, visibility .18s;
}

/* Invisible bridge so the pointer can travel from link to panel */
.nav_dropdown:before {
	content: "";
	position: absolute;
	top: -10px;
	left: 0;
	right: 0;
	height: 10px;
}

.nav_has_children:hover .nav_dropdown,
.nav_has_children:focus-within .nav_dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.nav_dropdown_item {
	display: block;
	padding: 10px 18px;
	font-size: 14px;
	line-height: 1.4;
	color: darkslategray !important;
	text-decoration: none;
	white-space: nowrap;
	transition: background .15s ease, color .15s ease;
}

.nav_dropdown_item:hover,
.nav_dropdown_item:focus-visible {
	background: #fbfcfc;
	color: #ff9a17;
}

.nav_dropdown_item.is-active {
	color: #ff9a17;
	font-weight: 600;
}

/* Keep the last dropdown from running off the right edge */
.header .nav_has_children:nth-last-of-type(1) .nav_dropdown,
.header .nav_has_children:nth-last-of-type(2) .nav_dropdown {
	left: 0;
	right: auto;
}

/* ---------- Mobile: no hover, so show inline ---------- */

@media (max-width: 900px) {
	.nav_has_children {
		display: block;
		width: 100%;
	}

	.nav_caret { display: none; }

	.nav_dropdown {
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		min-width: 0;
		padding: 0 0 6px 14px;
		background: transparent;
		border: 0;
		box-shadow: none;
	}

	.nav_dropdown:before { display: none; }

	.nav_dropdown_item {
		padding: 7px 0;
		font-size: 14px;
		color: inherit;
		opacity: .85;
		white-space: normal;
	}
}