/* Jero header: matches the Divi 4 built-in header it replaces (measured 2026-11-19). */

.jero-header {
	--jero-bar-h: 90px;
	--jero-top: var(--wp-admin--admin-bar--height, 0px);
	--jero-muted: #999;
	position: relative;
	height: var(--jero-bar-h);
	font-family: 'Open Sans', Arial, sans-serif;
}
.jero-header.is-scrolled { --jero-bar-h: 60px; }

.jero-header .screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* !important: Divi's Code module styles every ul inside it (disc bullets, 0 0 23px 1em padding)
   with ID-level selectors. */
.jero-header ul { list-style: none !important; margin: 0 !important; padding: 0 !important; }
.jero-header a { text-decoration: none; }
.jero-header :where(button) {
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	text-transform: inherit;
	cursor: pointer;
}

.jero-header__bar {
	position: fixed;
	top: var(--jero-top);
	right: 0;
	left: 0;
	z-index: 99999;
	height: var(--jero-bar-h);
	background: #000;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.1);
	transition: height 0.4s;
}
.jero-header.is-scrolled .jero-header__bar { box-shadow: 0 0 7px rgba(0, 0, 0, 0.1); }

.jero-header__inner {
	position: relative;
	width: 90%;
	max-width: 1440px;
	height: 100%;
	margin: 0 auto;
}

.jero-header__logo {
	position: absolute;
	top: 50%;
	left: 4px;
	transform: translateY(-50%);
	line-height: 0;
}
.jero-header__logo img { width: auto; height: 36px; transition: height 0.4s; }
.jero-header.is-scrolled .jero-header__logo img { height: 24px; }

/* Desktop menu: centred over the area right of the logo, like Divi's #et-top-navigation */
.jero-header__nav {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	left: 130px;
	display: flex;
	justify-content: center;
	pointer-events: none;
}
.jero-header__menu { display: flex; pointer-events: auto; }
/* Divi: 22px padding + the inline-block space = 26px between items; its trailing padding
   shifts the centring, matched here to land the first item on the same x. */
.jero-header__menu > li { padding-right: 26px; }
.jero-header__menu > li:nth-last-child(1 of :not(.hide_desktop)) { padding-right: 20px; }
.jero-header__menu > li > a,
.jero-header__toggle {
	display: block;
	padding: 35px 0;
	color: #fff;
	font-size: 14px;
	font-weight: 400;
	line-height: 14px;
	text-transform: uppercase;
	transition: padding 0.4s, color 0.2s;
}
.jero-header.is-scrolled .jero-header__menu > li > a,
.jero-header.is-scrolled .jero-header__toggle { padding: 20px 0; }
.jero-header__menu > li > a:hover,
.jero-header__toggle:hover,
.jero-header__menu > li.is-open > .jero-header__toggle,
.jero-header__menu > li.current-menu-item > a,
.jero-header__menu > li.current-menu-ancestor > a { color: var(--jero-muted); }
.jero-header__chevron { display: none; }
.jero-header__menu .sub-menu,
.jero-header__menu .hide_desktop { display: none; }

/* Mega panel: full-width band under the bar */
.jero-mega {
	position: fixed;
	top: calc(var(--jero-top) + var(--jero-bar-h));
	right: 0;
	left: 0;
	height: 244px;
	background: #000;
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.2s, visibility 0.2s, top 0.4s;
}
.jero-header__menu > li.is-open > .jero-mega { visibility: visible; opacity: 1; }
.jero-mega__inner {
	position: relative;
	width: 90%;
	max-width: 1440px;
	height: 100%;
	margin: 0 auto;
}
.jero-mega__links {
	position: absolute;
	top: 32px;
	left: var(--jero-menu-left, 0px);
	display: flex;
	flex-direction: column;
	flex-wrap: wrap;
	align-content: flex-start;
	column-gap: 48px;
	height: 165px;
}
.jero-mega__links li { margin-bottom: 8px; }
.jero-mega__links a {
	display: block;
	padding-bottom: 8px;
	color: #fff;
	font-size: 14px;
	font-weight: 500;
	line-height: 16.8px;
	text-transform: uppercase;
	white-space: nowrap;
	transition: color 0.2s;
}
.jero-mega__links a:hover,
.jero-mega__links a:focus-visible { color: var(--jero-muted); }
.jero-mega__links .current-menu-item > a { font-weight: 700; }
/* "See all" (class menu_see_all on the panel menus' item, Appearance → Menus; the mobile menu
   doesn't list it): a smaller, tracked label so it stands apart from the categories; same line
   height, so the columns don't move. */
.jero-mega__links .menu_see_all > a {
	font-size: 12px;
	font-weight: 300;
	letter-spacing: 2px;
}
.jero-mega__media {
	position: absolute;
	top: 24px;
	right: 0;
	width: 300px;
	height: 167px;
	line-height: 0;
}
.jero-mega__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0;
}
.jero-mega__media.has-image img { opacity: 1; transition: opacity 0.4s; }

/* Right column: language, search, client login */
.jero-header__tools {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	display: flex;
	align-items: center;
	gap: 22px;
	color: #fff;
}
.jero-header__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
	width: 24px;
	height: 24px;
	color: #fff;
	transition: color 0.2s;
}
.jero-header__icon:hover,
.jero-header__lang.is-open > .jero-header__icon { color: var(--jero-muted); }
.jero-header__account.is-logged-in::after {
	content: '';
	position: absolute;
	top: 1px;
	right: 0;
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: #b12c23;
}

/* Language dropdown: a small panel hanging from the bar's bottom edge, styled like the mega
   panels. The globe's wrapper spans the bar's height, so hovering from icon to panel is continuous. */
.jero-header__lang {
	display: flex;
	align-items: center;
	align-self: stretch;
}
.jero-header .jero-header__dropdown {
	position: absolute;
	top: 100%;
	left: -28px;
	min-width: 180px;
	padding: 24px 28px 14px !important;
	background: #000;
	box-shadow: 0 12px 24px rgba(0, 0, 0, 0.25);
	visibility: hidden;
	opacity: 0;
	transform: translateY(-4px);
	transition: opacity 0.2s, visibility 0.2s, transform 0.2s;
}
.jero-header__lang.is-open .jero-header__dropdown { visibility: visible; opacity: 1; transform: none; }
.jero-header__dropdown li { margin-bottom: 8px; }
.jero-header__dropdown a {
	display: block;
	padding-bottom: 8px;
	font-size: 14px;
	font-weight: 500;
	line-height: 16.8px;
	text-transform: uppercase;
	transition: color 0.2s;
}
.jero-header__dropdown a[aria-current] .jero-header__lang-name::after {
	content: '';
	display: inline-block;
	width: 6px;
	height: 6px;
	margin-left: 10px;
	border-radius: 50%;
	background: #b12c23;
	vertical-align: middle;
}
.jero-header__langs { display: none; }

/* Search (mu-plugins/jero-search: its icon is a .jero-header__icon, its panel has its own CSS) */
.jero-header__search { line-height: 0; }

.jero-header__burger { display: none; }

/* !important: on WooCommerce archives and products Divi's custom-post-type stylesheet colours
   every link (.et-db #et-boc .et-l a { color: #000 }) with an ID-level selector. */
.jero-header a { color: #fff !important; }
.jero-header__menu > li > a:hover,
.jero-header__menu > li.current-menu-item > a,
.jero-header__menu > li.current-menu-ancestor > a,
.jero-mega__links a:hover,
.jero-mega__links a:focus-visible,
.jero-header__dropdown a:hover,
.jero-header__dropdown a[aria-current],
.jero-header__icon:hover { color: var(--jero-muted) !important; }

/* Mobile: matches Divi's mobile header and full-screen menu */
@media (max-width: 980px) {
	.jero-header { --jero-bar-h: 80px; height: 79px; } /* Divi's mobile header overlaps content by 1px */
	.jero-header.is-scrolled { --jero-bar-h: 80px; }
	.jero-header__bar { position: absolute; top: 0; }
	.jero-header__logo { left: 4px; }
	.jero-header__logo img,
	.jero-header.is-scrolled .jero-header__logo img { height: 43px; }
	.jero-header__lang,
	.jero-mega { display: none; }
	.jero-header__tools { gap: 20px; z-index: 2; }

	.jero-header__burger {
		display: flex;
		align-items: center;
		justify-content: center;
		width: 32px;
		height: 32px;
	}
	.jero-header__burger > span:first-child,
	.jero-header__burger > span:first-child::before,
	.jero-header__burger > span:first-child::after {
		display: block;
		position: relative;
		width: 24px;
		height: 2px;
		background: #fff;
		transition: transform 0.3s, background 0.3s;
	}
	.jero-header__burger > span:first-child::before,
	.jero-header__burger > span:first-child::after {
		content: '';
		position: absolute;
		left: 0;
	}
	.jero-header__burger > span:first-child::before { top: -7px; }
	.jero-header__burger > span:first-child::after { top: 7px; }
	.jero-header.is-menu-open .jero-header__burger > span:first-child { background: transparent; }
	.jero-header.is-menu-open .jero-header__burger > span:first-child::before { transform: translateY(7px) rotate(45deg); }
	.jero-header.is-menu-open .jero-header__burger > span:first-child::after { transform: translateY(-7px) rotate(-45deg); }

	.jero-header__nav {
		position: fixed;
		inset: 0;
		z-index: 1;
		display: none;
		padding: 100px 0 40px;
		overflow-y: auto;
		background: rgba(10, 10, 10, 0.9);
		pointer-events: auto;
	}
	/* Flex column so the language row sits at the bottom of the screen when the menu is short */
	.jero-header.is-menu-open .jero-header__nav { display: flex; flex-direction: column; }
	.jero-header__menu { display: block; text-align: center; }
	.jero-header__menu > li,
	.jero-header__menu > li:nth-last-child(1 of :not(.hide_desktop)) { position: relative; padding-right: 0; }
	.jero-header__menu .hide_desktop { display: block; }
	.jero-header__menu > li > a,
	.jero-header__toggle,
	.jero-header.is-scrolled .jero-header__menu > li > a,
	.jero-header.is-scrolled .jero-header__toggle {
		width: 100%;
		padding: 22.5px 20px;
		font-size: 16px;
		font-weight: 600;
		letter-spacing: 1px;
		line-height: 1.2;
	}
	.jero-header__chevron {
		display: block;
		position: absolute;
		top: 26px;
		right: 24px;
		width: 9px;
		height: 9px;
		border-right: 2px solid #fff;
		border-bottom: 2px solid #fff;
		transform: rotate(45deg);
		transition: transform 0.3s, top 0.3s;
	}
	.jero-header__menu > li.is-open .jero-header__chevron { top: 31px; transform: rotate(-135deg); }
	.jero-header__menu > li.is-open > .sub-menu { display: block; padding-bottom: 12px !important; }
	.jero-header__menu .sub-menu a {
		display: block;
		padding: 14px 20px;
		color: #fff;
		font-size: 12px;
		letter-spacing: 1px;
		line-height: 1.2;
		text-transform: uppercase;
	}
	/* Languages: one row under a divider instead of TranslatePress's stacked menu items */
	.jero-header__menu .trp-language-switcher-container { display: none; }
	.jero-header__langs {
		display: flex;
		flex: none;
		justify-content: center;
		width: 60%;
		margin: auto auto 0;
		padding-top: 24px;
		border-top: 1px solid rgba(255, 255, 255, 0.35);
	}
	.jero-header__langs a {
		padding: 6px 18px;
		font-size: 14px;
		font-weight: 600;
		letter-spacing: 1px;
		line-height: 1.2;
	}
	.jero-header__langs a + a { border-left: 1px solid rgba(255, 255, 255, 0.2); }
	.jero-header .jero-header__langs a:not([aria-current]) { color: var(--jero-muted) !important; }

	html.jero-menu-open { overflow: hidden; }
}
