/* BILYF Global Header — styles are intentionally namespaced with bgh-. */
body.bgh-enabled {
	--bgh-deep: #071f19;
	--bgh-green: #123d2e;
	--bgh-lime: #b8e51d;
	--bgh-yellow: #ffd029;
	--bgh-cream: #f4f2e9;
	--bgh-height: 96px;
}

body.bgh-fixed {
	padding-top: var(--bgh-height) !important;
}

body.bgh-menu-open {
	overflow: hidden !important;
}

body.bgh-hide-theme-header .site-header,
body.bgh-hide-theme-header #masthead,
body.bgh-hide-theme-header .elementor-location-header,
body.bgh-hide-theme-header .elementor-location-theme-header {
	display: none !important;
}

/* The homepage already contains an embedded first-version navigation. */
body.bgh-enabled .bilyf-portal > .bilyf-nav {
	display: none !important;
}

.bgh-header,
.bgh-header *,
.bgh-header *::before,
.bgh-header *::after {
	box-sizing: border-box;
}

.bgh-header {
	--bgh-admin-offset: 0px;
	position: relative;
	z-index: 99990;
	width: 100%;
	height: var(--bgh-height);
	margin: 0;
	background:
		linear-gradient(90deg, rgba(255, 255, 255, .025) 1px, transparent 1px) 0 0 / 64px 64px,
		linear-gradient(105deg, #071f19, #103829 68%, #123d2e);
	box-shadow: 0 12px 38px rgba(2, 15, 11, .16);
	font-family: "Space Grotesk", "Plus Jakarta Sans", Arial, Helvetica, sans-serif;
	color: #fff;
	isolation: isolate;
}

body.bgh-fixed .bgh-header {
	position: fixed;
	top: var(--bgh-admin-offset);
	left: 0;
	right: 0;
}

body.admin-bar .bgh-header {
	--bgh-admin-offset: 32px;
}

.bgh-header.is-scrolled {
	box-shadow: 0 18px 48px rgba(2, 15, 11, .28);
}

.bgh-accent {
	position: absolute;
	inset: 0 0 auto;
	display: grid;
	grid-template-columns: 1fr 1.6fr .7fr;
	height: 4px;
	overflow: hidden;
}

.bgh-accent i:nth-child(1) { background: var(--bgh-lime); }
.bgh-accent i:nth-child(2) { background: var(--bgh-yellow); }
.bgh-accent i:nth-child(3) { background: #1aaee8; }

.bgh-inner {
	position: relative;
	z-index: 3;
	display: flex;
	align-items: center;
	width: min(1240px, calc(100% - 48px));
	height: 100%;
	margin: 0 auto;
	gap: 25px;
}

.bgh-brand {
	display: inline-flex !important;
	flex: 0 0 auto;
	align-items: center;
	width: 146px;
	min-width: 146px;
	height: 82px;
	margin: 0 !important;
	padding: 7px 0 3px !important;
	text-decoration: none !important;
}

.bgh-brand img {
	display: block !important;
	width: auto !important;
	max-width: 146px !important;
	max-height: 82px !important;
	height: auto !important;
	object-fit: contain;
	object-position: left center;
}

.bgh-brand-fallback {
	display: none;
	font-size: 27px;
	font-weight: 900;
	line-height: .9;
	letter-spacing: -.045em;
	color: #fff;
}

.bgh-brand-fallback small {
	display: block;
	margin-top: 6px;
	font-size: 8px;
	letter-spacing: .12em;
	color: var(--bgh-yellow);
}

.bgh-brand.is-fallback img {
	display: none !important;
}

.bgh-brand.is-fallback .bgh-brand-fallback {
	display: block;
}

.bgh-desktop-nav {
	min-width: 0;
	margin-left: auto;
}

.bgh-menu {
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

.bgh-desktop-menu {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 2px;
}

.bgh-menu > li {
	position: relative;
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

.bgh-desktop-menu > li > a {
	position: relative;
	display: flex !important;
	align-items: center;
	height: 92px;
	padding: 0 11px !important;
	border: 0 !important;
	background: transparent !important;
	color: rgba(255, 255, 255, .76) !important;
	font-size: 12px !important;
	font-weight: 750 !important;
	line-height: 1 !important;
	letter-spacing: -.01em;
	text-decoration: none !important;
	white-space: nowrap;
	transition: color .2s ease;
}

.bgh-desktop-menu > li > a::after {
	content: "";
	position: absolute;
	left: 11px;
	right: 11px;
	bottom: 16px;
	height: 2px;
	background: var(--bgh-yellow);
	transform: scaleX(0);
	transform-origin: left;
	transition: transform .2s ease;
}

.bgh-desktop-menu > li:hover > a,
.bgh-desktop-menu > li:focus-within > a,
.bgh-desktop-menu > .current-menu-item > a,
.bgh-desktop-menu > .current-menu-ancestor > a,
.bgh-desktop-menu > li > a[aria-current="page"],
.bgh-desktop-menu > li > a.is-active {
	color: #fff !important;
}

.bgh-desktop-menu > li:hover > a::after,
.bgh-desktop-menu > li:focus-within > a::after,
.bgh-desktop-menu > .current-menu-item > a::after,
.bgh-desktop-menu > .current-menu-ancestor > a::after,
.bgh-desktop-menu > li > a[aria-current="page"]::after,
.bgh-desktop-menu > li > a.is-active::after {
	transform: scaleX(1);
}

.bgh-desktop-menu .sub-menu {
	position: absolute;
	top: calc(100% - 8px);
	right: 0;
	display: none;
	width: 235px;
	margin: 0 !important;
	padding: 10px !important;
	list-style: none !important;
	background: #fff;
	border-top: 4px solid var(--bgh-yellow);
	box-shadow: 0 22px 55px rgba(0, 0, 0, .26);
}

.bgh-desktop-menu li:hover > .sub-menu,
.bgh-desktop-menu li:focus-within > .sub-menu {
	display: block;
}

.bgh-desktop-menu .sub-menu a {
	display: block !important;
	padding: 12px !important;
	border-bottom: 1px solid #e7ebe7;
	color: #081a17 !important;
	font-size: 12px !important;
	font-weight: 750 !important;
	text-decoration: none !important;
}

.bgh-desktop-menu .sub-menu a:hover,
.bgh-desktop-menu .sub-menu a:focus {
	background: #f2f6ed !important;
	color: var(--bgh-green) !important;
}

.bgh-cta,
.bgh-mobile-cta {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 0 18px !important;
	border: 1px solid var(--bgh-yellow) !important;
	border-radius: 4px;
	background: var(--bgh-yellow) !important;
	color: #173016 !important;
	font-size: 10px !important;
	font-weight: 900 !important;
	line-height: 1 !important;
	letter-spacing: .07em;
	text-align: center;
	text-decoration: none !important;
	text-transform: uppercase;
	white-space: nowrap;
	transition: transform .2s ease, background .2s ease;
}

.bgh-cta:hover,
.bgh-cta:focus,
.bgh-mobile-cta:hover,
.bgh-mobile-cta:focus {
	background: var(--bgh-lime) !important;
	border-color: var(--bgh-lime) !important;
	transform: translateY(-2px);
}

.bgh-toggle {
	display: none;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 5px;
	width: 45px;
	height: 45px;
	margin-left: auto;
	padding: 0 !important;
	border: 1px solid rgba(255, 255, 255, .22) !important;
	border-radius: 4px;
	background: rgba(255, 255, 255, .06) !important;
	box-shadow: none !important;
	cursor: pointer;
}

.bgh-toggle span {
	display: block;
	width: 19px;
	height: 2px;
	background: #fff;
	transition: transform .2s ease, opacity .2s ease;
}

.bgh-toggle[aria-expanded="true"] span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}

.bgh-toggle[aria-expanded="true"] span:nth-child(2) {
	opacity: 0;
}

.bgh-toggle[aria-expanded="true"] span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

.bgh-backdrop {
	position: fixed;
	z-index: 1;
	inset: calc(var(--bgh-height) + var(--bgh-admin-offset)) 0 0;
	width: 100%;
	height: auto;
	margin: 0;
	padding: 0;
	border: 0;
	background: rgba(2, 14, 10, .68);
	backdrop-filter: blur(5px);
	cursor: default;
}

.bgh-mobile-panel {
	position: fixed;
	z-index: 2;
	top: calc(var(--bgh-height) + var(--bgh-admin-offset));
	right: 0;
	bottom: 0;
	width: min(430px, 92vw);
	padding: 24px 24px 30px;
	overflow-y: auto;
	background:
		radial-gradient(circle at 85% 0, rgba(184, 229, 29, .13), transparent 28%),
		#071f19;
	box-shadow: -24px 0 65px rgba(0, 0, 0, .28);
	animation: bgh-panel-in .22s ease both;
}

@keyframes bgh-panel-in {
	from { opacity: 0; transform: translateX(24px); }
	to { opacity: 1; transform: translateX(0); }
}

.bgh-mobile-menu > li {
	border-bottom: 1px solid rgba(255, 255, 255, .12);
}

.bgh-mobile-menu a {
	display: flex !important;
	align-items: center;
	min-height: 57px;
	padding: 8px 3px !important;
	border: 0 !important;
	background: transparent !important;
	color: #fff !important;
	font-size: 17px !important;
	font-weight: 800 !important;
	line-height: 1.15 !important;
	letter-spacing: -.02em;
	text-decoration: none !important;
}

.bgh-mobile-menu a.is-active,
.bgh-mobile-menu .current-menu-item > a,
.bgh-mobile-menu a[aria-current="page"] {
	color: var(--bgh-yellow) !important;
}

.bgh-mobile-menu .sub-menu {
	margin: -4px 0 12px 13px !important;
	padding: 0 0 0 14px !important;
	border-left: 2px solid var(--bgh-lime);
	list-style: none !important;
}

.bgh-mobile-menu .sub-menu a {
	min-height: 43px;
	font-size: 13px !important;
	color: rgba(255, 255, 255, .72) !important;
}

.bgh-mobile-cta {
	width: 100%;
	min-height: 52px;
	margin-top: 28px;
}

.bgh-mobile-signature {
	margin-top: 30px;
	padding-top: 20px;
	border-top: 1px solid rgba(255, 255, 255, .1);
	color: rgba(255, 255, 255, .4);
	font-size: 8px;
	font-weight: 900;
	letter-spacing: .15em;
	text-align: center;
}

.bgh-header [hidden] {
	display: none !important;
}

.bgh-header a:focus-visible,
.bgh-header button:focus-visible {
	outline: 3px solid var(--bgh-lime) !important;
	outline-offset: 3px;
}

@media (max-width: 1160px) {
	.bgh-inner {
		width: min(100% - 36px, 1240px);
	}

	.bgh-desktop-nav,
	.bgh-cta {
		display: none !important;
	}

	.bgh-toggle {
		display: flex;
	}
}

@media (max-width: 782px) {
	body.bgh-enabled {
		--bgh-height: 76px;
	}

	body.admin-bar .bgh-header {
		--bgh-admin-offset: 46px;
	}

	.bgh-inner {
		width: calc(100% - 28px);
	}

	.bgh-brand {
		width: 122px;
		min-width: 122px;
		height: 62px;
	}

	.bgh-brand img {
		max-width: 122px !important;
		max-height: 60px !important;
	}

	.bgh-toggle {
		width: 42px;
		height: 42px;
	}
}

@media (max-width: 600px) {
	body.admin-bar .bgh-header {
		--bgh-admin-offset: 0px;
	}

	body.admin-bar.bgh-fixed .bgh-header {
		position: absolute;
	}

	.bgh-mobile-panel,
	.bgh-backdrop {
		top: var(--bgh-height);
	}
}

@media (prefers-reduced-motion: reduce) {
	.bgh-header *,
	.bgh-header *::before,
	.bgh-header *::after {
		scroll-behavior: auto !important;
		animation-duration: .01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: .01ms !important;
	}
}
