:root {
	--psh-header-height: 72px;
	--psh-header-green: #00463b;
	--psh-header-green-active: #00701c;
	--psh-header-text: #111111;
	--psh-header-max: 1900px;
}

/* Nasconde header Divi (classic + Theme Builder) */
body.psh-glass-header-active #main-header,
body.psh-glass-header-active #top-header,
body.psh-glass-header-active header.et-l.et-l--header {
	display: none !important;
	height: 0 !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	overflow: hidden !important;
	visibility: hidden !important;
}

body.psh-glass-header-active {
	padding-top: 0 !important;
}

body.psh-glass-header-active #page-container,
body.psh-glass-header-active.et_fixed_nav #page-container,
body.psh-glass-header-active.et_fixed_nav.et_show_nav #page-container {
	padding-top: var(--psh-header-height) !important;
}

body.admin-bar.psh-glass-header-active #page-container {
	padding-top: calc(var(--psh-header-height) + 32px) !important;
}

@media screen and (max-width: 782px) {
	body.admin-bar.psh-glass-header-active #page-container {
		padding-top: calc(var(--psh-header-height) + 46px) !important;
	}
}

body.psh-glass-header-active #et-main-area,
body.psh-glass-header-active #main-content,
body.psh-glass-header-active #main-content .container,
body.psh-glass-header-active #main-content > .container {
	padding-top: 0 !important;
	margin-top: 0 !important;
}

body.psh-glass-header-active.admin-bar .psh-glass-header {
	top: 32px;
}

@media screen and (max-width: 782px) {
	body.psh-glass-header-active.admin-bar .psh-glass-header {
		top: 46px;
	}
}

.psh-glass-header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 100000;
	pointer-events: none;
}

.psh-glass-header__bar {
	pointer-events: auto;
	background: rgba(255, 255, 255, 0.78);
	border-bottom: 1px solid rgba(255, 255, 255, 0.65);
	box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
	backdrop-filter: blur(18px) saturate(165%);
	-webkit-backdrop-filter: blur(18px) saturate(165%);
	transition:
		background 0.35s ease,
		box-shadow 0.35s ease,
		border-color 0.35s ease;
}

.psh-glass-header.is-scrolled .psh-glass-header__bar {
	background: rgba(255, 255, 255, 0.92);
	border-bottom-color: rgba(0, 70, 59, 0.08);
	box-shadow: 0 8px 32px rgba(15, 23, 42, 0.1);
}

.psh-glass-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	max-width: var(--psh-header-max);
	margin: 0 auto;
	padding: 0 clamp(16px, 3vw, 32px);
	min-height: var(--psh-header-height);
}

.psh-glass-header__logo {
	display: flex;
	align-items: center;
	flex: 0 0 auto;
	line-height: 0;
	margin: 0;
	padding: 0;
}

.psh-glass-header__logo img {
	display: block;
	width: auto;
	height: 60px;
	max-width: min(220px, 50vw);
	object-fit: contain;
}

.psh-glass-header__langs {
	display: none;
	flex: 0 0 auto;
	align-items: center;
}

.psh-glass-header__lang-list {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.psh-glass-header__lang-item a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	opacity: 0.72;
	transition: opacity 0.2s ease, background 0.2s ease;
}

.psh-glass-header__lang-item a:hover,
.psh-glass-header__lang-item a:focus-visible {
	opacity: 1;
	background: rgba(0, 70, 59, 0.08);
}

.psh-glass-header__lang-item.is-active a {
	opacity: 1;
}

.psh-glass-header__lang-item img {
	display: block;
	width: 18px;
	height: auto;
	border-radius: 1px;
}

.psh-glass-header__lang-item span {
	font-family: 'Red Hat Display', Helvetica, Arial, sans-serif;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.04em;
	color: var(--psh-header-text);
}

.psh-glass-header__nav {
	flex: 1 1 auto;
	display: flex;
	justify-content: flex-end;
	min-width: 0;
}

.psh-glass-header__menu {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	flex-wrap: wrap;
	gap: 4px 0;
	margin: 0;
	padding: 0;
	list-style: none;
}

.psh-glass-header__menu > li {
	position: relative;
	margin: 0;
	padding: 0;
}

.psh-glass-header__menu > li > a {
	display: block;
	padding: 10px 16px;
	color: var(--psh-header-text);
	font-family: 'Red Hat Display', Helvetica, Arial, sans-serif;
	font-size: 16px;
	font-weight: 500;
	line-height: 1.3;
	text-decoration: none;
	transition: color 0.2s ease, opacity 0.2s ease;
}

.psh-glass-header__menu > li > a:hover,
.psh-glass-header__menu > li > a:focus-visible {
	color: var(--psh-header-green);
	opacity: 0.85;
}

.psh-glass-header__menu > li.current-menu-item > a,
.psh-glass-header__menu > li.current-menu-ancestor > a,
.psh-glass-header__menu > li.current_page_item > a {
	color: var(--psh-header-green-active);
	font-weight: 600;
}

/* Submenu desktop */
.psh-glass-header__menu .sub-menu {
	position: absolute;
	top: calc(100% + 4px);
	left: 0;
	z-index: 20;
	min-width: 220px;
	margin: 0;
	padding: 10px 0;
	list-style: none;
	background: rgba(255, 255, 255, 0.94);
	border: 1px solid rgba(255, 255, 255, 0.8);
	border-radius: 0;
	box-shadow: 0 16px 40px rgba(15, 23, 42, 0.12);
	backdrop-filter: blur(16px) saturate(160%);
	-webkit-backdrop-filter: blur(16px) saturate(160%);
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition:
		opacity 0.22s ease,
		transform 0.22s ease,
		visibility 0.22s ease;
}

.psh-glass-header__menu li:hover > .sub-menu,
.psh-glass-header__menu li:focus-within > .sub-menu {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.psh-glass-header__menu .sub-menu a {
	display: block;
	padding: 10px 18px;
	color: var(--psh-header-text);
	font-size: 15px;
	font-weight: 500;
	text-decoration: none;
	white-space: nowrap;
}

.psh-glass-header__menu .sub-menu a:hover,
.psh-glass-header__menu .sub-menu .current-menu-item > a {
	color: var(--psh-header-green-active);
}

.psh-glass-header__menu .sub-menu .sub-menu {
	top: 0;
	left: 100%;
}

/* Hamburger */
.psh-glass-header__toggle {
	display: none;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
}

.psh-glass-header__toggle-box {
	display: grid;
	gap: 6px;
	width: 22px;
}

.psh-glass-header__toggle-box span {
	display: block;
	height: 2px;
	background: var(--psh-header-text);
	border-radius: 1px;
	transition: transform 0.25s ease, opacity 0.25s ease;
}

.psh-glass-header.is-open .psh-glass-header__toggle-box span:nth-child(1) {
	transform: translateY(8px) rotate(45deg);
}

.psh-glass-header.is-open .psh-glass-header__toggle-box span:nth-child(2) {
	opacity: 0;
}

.psh-glass-header.is-open .psh-glass-header__toggle-box span:nth-child(3) {
	transform: translateY(-8px) rotate(-45deg);
}

/* Mobile overlay */
.psh-glass-header__mobile {
	position: fixed;
	inset: 0;
	z-index: 100001;
	display: flex;
	align-items: stretch;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.32s ease, visibility 0.32s ease;
}

.psh-glass-header__mobile.is-open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.psh-glass-header__mobile-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(255, 255, 255, 0.35);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
}

.psh-glass-header__mobile-panel {
	position: relative;
	z-index: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	padding: 72px 24px 48px;
	background: rgba(255, 255, 255, 0.97);
	backdrop-filter: blur(24px) saturate(180%);
	-webkit-backdrop-filter: blur(24px) saturate(180%);
	overflow-y: auto;
}

.psh-glass-header__mobile-close {
	position: absolute;
	top: max(16px, env(safe-area-inset-top));
	right: max(16px, env(safe-area-inset-right));
	display: flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--psh-header-text);
	font-size: 36px;
	line-height: 1;
	cursor: pointer;
}

.psh-glass-header__mobile-nav {
	width: 100%;
	max-width: 420px;
}

.psh-glass-header__menu--mobile {
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0;
	width: 100%;
}

.psh-glass-header__menu--mobile > li {
	width: 100%;
	text-align: center;
}

.psh-glass-header__menu--mobile > li > a {
	padding: 16px 12px;
	font-size: clamp(22px, 5vw, 28px);
	font-weight: 600;
	line-height: 1.25;
	color: var(--psh-header-text);
}

.psh-glass-header__menu--mobile > li.current-menu-item > a,
.psh-glass-header__menu--mobile > li.current-menu-ancestor > a,
.psh-glass-header__menu--mobile > li.current_page_item > a {
	color: var(--psh-header-green-active);
}

.psh-glass-header__menu--mobile .sub-menu {
	position: static;
	opacity: 1;
	visibility: visible;
	transform: none;
	display: block;
	min-width: 0;
	margin: 0;
	padding: 0 0 8px;
	background: transparent;
	border: 0;
	box-shadow: none;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
}

.psh-glass-header__menu--mobile .sub-menu a {
	padding: 10px 12px;
	font-size: clamp(17px, 4vw, 20px);
	font-weight: 500;
	color: rgba(17, 17, 17, 0.78);
	white-space: normal;
}

.psh-glass-header__menu--mobile .sub-menu .current-menu-item > a {
	color: var(--psh-header-green-active);
}

.psh-glass-header__menu--mobile > .lang-item {
	display: none !important;
}

body.psh-glass-header-menu-open {
	overflow: hidden;
}

@media (max-width: 980px) {
	.psh-glass-header__inner {
		display: grid;
		grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
		align-items: center;
		gap: 8px;
	}

	.psh-glass-header__langs {
		display: flex;
		grid-column: 1;
		justify-self: start;
	}

	.psh-glass-header__logo {
		grid-column: 2;
		justify-self: center;
	}

	.psh-glass-header__nav {
		display: none;
	}

	.psh-glass-header__toggle {
		display: inline-flex;
		grid-column: 3;
		justify-self: end;
	}

	.psh-glass-header__logo img {
		height: 54px;
		max-width: min(200px, 46vw);
	}
}

@media (prefers-reduced-motion: reduce) {
	.psh-glass-header__bar,
	.psh-glass-header__mobile,
	.psh-glass-header__menu .sub-menu,
	.psh-glass-header__toggle-box span {
		transition: none;
	}
}
