/*
 * Heritage Motorworks – Custom Header
 * Eigenständiger Header oberhalb des Hero; CI-Farben aus dem Heritage Design System.
 */
:root {
	--hm-header-accent: #18a891;
	--hm-header-dark: #171a21;
	--hm-header-black: #111111;
	--hm-header-height: 104px;
	--hm-header-height-compact: 88px;
}

.hm-header {
	position: sticky;
	top: 0;
	z-index: 1000;
	width: 100%;
	color: #fff;
	background: var(--hm-header-dark);
	border-bottom: 1px solid rgba(255,255,255,.08);
	transition: box-shadow .25s ease;
}

.admin-bar .hm-header { top: 32px; }

.hm-header__bar {
	display: grid;
	grid-template-columns: minmax(190px, 230px) minmax(0, 1fr) auto;
	align-items: center;
	gap: clamp(16px, 2vw, 32px);
	width: min(calc(100% - 64px), 1600px);
	min-height: var(--hm-header-height);
	margin-inline: auto;
	transition: min-height .25s ease;
}

.hm-header__brand,
.hm-header__home-link,
.hm-header__brand .custom-logo-link {
	display: flex;
	align-items: center;
	min-width: 0;
	color: inherit;
	text-decoration: none;
}

.hm-header__brand .custom-logo {
	display: block;
	width: auto;
	max-width: clamp(145px, 15vw, 220px);
	height: 58px;
	max-height: 58px;
	object-fit: contain;
}

.hm-header__site-name { font-size: 1.1rem; font-weight: 700; letter-spacing: .05em; }
.hm-header__nav { justify-self: center; min-width: 0; }
.hm-header__menu,
.hm-header__menu ul,
.hm-header__mobile-menu,
.hm-header__mobile-menu ul {
	margin: 0;
	padding: 0;
	list-style: none;
}
.hm-header__menu { display: flex; align-items: center; justify-content: center; gap: clamp(14px, 1.7vw, 28px); }
.hm-header__menu > li { position: relative; }
.hm-header__menu a,
.hm-header__mobile-menu a {
	display: inline-flex;
	align-items: center;
	color: inherit;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: .015em;
	text-decoration: none;
	transition: color .2s ease;
}
.hm-header__menu > li > a { min-height: 44px; white-space: nowrap; }
.hm-header__menu a:hover,
.hm-header__menu a:focus-visible,
.hm-header__mobile-menu a:hover,
.hm-header__mobile-menu a:focus-visible { color: var(--hm-header-accent); }

.hm-header__menu > li > .sub-menu {
	position: absolute;
	top: calc(100% - 1px);
	left: 0;
	display: none;
	grid-auto-flow: column;
	grid-template-rows: repeat(8, minmax(0, auto));
	grid-auto-columns: minmax(190px, 220px);
	gap: 2px 14px;
	width: max-content;
	max-width: min( min(900px, 90vw), calc(100vw - 40px) );
	padding: 16px;
	border: 1px solid rgba(255,255,255,.1);
	border-radius: 14px;
	background: var(--hm-header-dark);
	box-shadow: 0 18px 44px rgba(0,0,0,.28);
	/* Dropdown beginnt bündig unter dem auslösenden Menüpunkt und wächst nach rechts. */
	transform: none;
}
.hm-header__menu > li > .sub-menu > li { min-width: 0; }
.hm-header__menu .sub-menu .sub-menu { display: none !important; }
.hm-header__menu li:hover > .sub-menu,
.hm-header__menu li:focus-within > .sub-menu { display: grid; }
.hm-header__menu .sub-menu a { display: flex; width: 100%; padding: 11px 12px; border-radius: 7px; white-space: normal; }

.hm-header__actions { display: flex; align-items: center; justify-content: flex-end; gap: clamp(12px, 1.2vw, 20px); min-width: 0; white-space: nowrap; }
.hm-header__icon-link {
	position: relative;
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 38px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #fff;
	text-decoration: none;
	transition: color .2s ease, transform .2s ease;
}
.hm-header__icon-link:hover,
.hm-header__icon-link:focus-visible { color: var(--hm-header-accent); }
.hm-header__icon-link svg {
	display: block;
	width: 22px;
	height: 22px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.6;
	stroke-linecap: round;
	stroke-linejoin: round;
}
.hm-header__icon-link .hm-header__icon-solid { fill: currentColor; stroke: none; }
.hm-header__icon-link .hm-header__icon-fill { fill: currentColor; stroke: none; }
.hm-header__socials { display: flex; align-items: center; gap: 5px; padding-left: 4px; }
.hm-header__facebook svg { width: 19px; height: 22px; }
.hm-header__cart-count {
	position: absolute;
	top: 0;
	right: -4px;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 17px;
	height: 17px;
	padding: 0 4px;
	border-radius: 20px;
	background: var(--hm-header-accent);
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	line-height: 1;
}
.hm-header__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	min-height: 46px;
	padding: 0 22px;
	border: 1px solid var(--hm-header-accent);
	border-radius: 30px;
	background: var(--hm-header-accent);
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: .015em;
	text-decoration: none;
	white-space: nowrap;
	transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
}
.hm-header__cta:hover,
.hm-header__cta:focus-visible { border-color: #149780; background: #149780; color: #fff; transform: translateY(-1px); }
.hm-header__toggle { display: none; }
.hm-header__mobile-panel { display: none; }

.hm-header.is-scrolled { box-shadow: 0 8px 24px rgba(0,0,0,.12); }
.hm-header.is-scrolled .hm-header__bar { min-height: var(--hm-header-height-compact); }


@media (max-width: 1250px) {
	.hm-header__bar { grid-template-columns: minmax(140px, .7fr) minmax(0, 1.6fr) minmax(285px, 1.2fr); width: calc(100% - 40px); gap: 14px; }
	.hm-header__menu { gap: 12px; }
	.hm-header__menu a { font-size: 12px; }
	.hm-header__actions { gap: 9px; }
	.hm-header__cta { padding-inline: 15px; }
}
@media (max-width: 1050px) {
	.hm-header__bar { grid-template-columns: minmax(130px, .7fr) minmax(0, 1fr) minmax(270px, 1fr); }
	.hm-header__brand .custom-logo { max-width: 150px; }
	.hm-header__menu { gap: 9px; }
	.hm-header__menu a { font-size: 11px; }
	.hm-header__actions { gap: 6px; }
	.hm-header__cta { gap: 7px; padding-inline: 12px; }
}
@media (max-width: 900px) {
	.hm-header__bar { display: flex; justify-content: space-between; min-height: 82px; width: calc(100% - 36px); }
	.hm-header__nav { display: none; }
	.hm-header__brand .custom-logo { max-width: min(42vw, 205px); max-height: 52px; }
	.hm-header__actions { margin-left: auto; gap: 12px; }
	.hm-header__actions > .hm-header__socials { display: none; }
	.hm-header__cta { display: none; }
	.hm-header__toggle {
		display: inline-flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 5px;
		width: 44px;
		height: 44px;
		padding: 0;
		border: 1px solid rgba(255,255,255,.35);
		border-radius: 50%;
		background: transparent;
		cursor: pointer;
	}
	.hm-header__toggle span { display: block; width: 18px; height: 2px; border-radius: 2px; background: #fff; transition: transform .2s ease, opacity .2s ease; }
	.hm-header.is-menu-open .hm-header__toggle span:first-child { transform: translateY(7px) rotate(45deg); }
	.hm-header.is-menu-open .hm-header__toggle span:nth-child(2) { opacity: 0; }
	.hm-header.is-menu-open .hm-header__toggle span:last-child { transform: translateY(-7px) rotate(-45deg); }
	.hm-header.is-scrolled .hm-header__bar { min-height: 68px; }
	.hm-header__mobile-panel:not([hidden]) {
		position: fixed;
		z-index: 1001;
		inset: 0;
		display: block;
		overflow-y: auto;
		padding: 104px 28px 36px;
		background: var(--hm-header-dark);
		color: #fff;
	}
	.admin-bar .hm-header__mobile-panel:not([hidden]) { padding-top: 122px; }
	.hm-header__mobile-panel-inner { display: flex; flex-direction: column; gap: 24px; width: min(100%, 560px); margin-inline: auto; }
	.hm-header__mobile-menu > li { border-bottom: 1px solid rgba(255,255,255,.12); }
	.hm-header__mobile-menu a { display: flex; width: 100%; padding: 14px 0; font-size: clamp(18px, 4vw, 22px); }
	.hm-header__mobile-menu .sub-menu { padding-left: 16px; border-left: 1px solid rgba(24,168,145,.6); }
	.hm-header__mobile-menu .sub-menu a { font-size: 16px; }
	.hm-header__mobile-utility { display: flex; flex-wrap: wrap; gap: 14px 24px; }
	.hm-header__mobile-utility-link { display: inline-flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
	.hm-header__mobile-utility-link svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.6; }
	.hm-header__mobile-count { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 20px; background: var(--hm-header-accent); font-size: 11px; }
	.hm-header__mobile-socials { display: flex; gap: 10px; }
	.hm-header__mobile-logos { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; }
	.hm-header__mobile-logos img { display: block; max-width: 100px; max-height: 44px; object-fit: contain; }
	.hm-header__cta--mobile { display: inline-flex; align-self: flex-start; }
	body.hm-header-menu-open { overflow: hidden; }
}
@media (max-width: 600px) {
	.hm-header__bar { width: calc(100% - 28px); min-height: 74px; }
	.hm-header__brand .custom-logo { max-width: min(42vw, 175px); max-height: 46px; }
	.hm-header__actions { gap: 8px; }
	.hm-header__icon-link { width: 30px; }
	.hm-header__mobile-panel:not([hidden]) { padding-inline: 20px; }
	.hm-header.is-scrolled .hm-header__bar { min-height: 64px; }
}
@media (max-width: 782px) {
	.admin-bar .hm-header { top: 46px; }
	.admin-bar .hm-header__mobile-panel:not([hidden]) { padding-top: 138px; }
}
@media (prefers-reduced-motion: reduce) {
	.hm-header, .hm-header *, .hm-header *::before, .hm-header *::after { transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* Festes Zusatzlogo ganz rechts: Bestandteil des Themes, kein Customizer-Bildfeld. */
.hm-header__right-logo {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: flex-end;
	padding-left: clamp(14px, 1.5vw, 24px);
	margin-left: 2px;
	border-left: 1px solid rgba(255,255,255,.16);
}
.hm-header__right-logo img {
	display: block;
	width: 58px;
	height: 58px;
	object-fit: contain;
}
.hm-header.is-scrolled .hm-header__right-logo img { width: 58px; height: 58px; }
.hm-header.is-scrolled .hm-header__brand .custom-logo { height: 58px; max-height: 58px; }
.hm-header__bar { transition: min-height .25s ease; }
.hm-header__brand .custom-logo-link { flex: 0 0 auto; }
@media (max-width: 1250px) {
	.hm-header__bar { grid-template-columns: minmax(150px, 190px) minmax(0, 1fr) auto; gap: 12px; width: calc(100% - 40px); }
	.hm-header__right-logo { padding-left: 12px; }
	.hm-header__right-logo img { width: 48px; height: 48px; }
}
@media (max-width: 1050px) {
	.hm-header__bar { grid-template-columns: minmax(130px, 160px) minmax(0, 1fr) auto; gap: 10px; }
	.hm-header__actions { gap: 8px; }
	.hm-header__right-logo { display: none; }
}
@media (max-width: 900px) {
	.hm-header__brand .custom-logo { height: 52px; max-height: 52px; }
	.hm-header.is-scrolled .hm-header__brand .custom-logo { height: 52px; max-height: 52px; }
}
@media (max-width: 600px) {
	.hm-header__brand .custom-logo { height: 46px; max-height: 46px; }
	.hm-header.is-scrolled .hm-header__brand .custom-logo { height: 46px; max-height: 46px; }
}


/* Heritage Header – Premium refinement */
.hm-header {
	background: #171a21;
	border-bottom: 1px solid rgba(255,255,255,.10);
	box-shadow: 0 8px 28px rgba(0,0,0,.10);
}
.hm-header__bar {
	width: min(calc(100% - 80px), 1740px);
	min-height: 108px;
	grid-template-columns: 190px minmax(0,1fr) auto;
	gap: clamp(24px,2.1vw,38px);
}
.hm-header__brand .custom-logo,
.hm-header.is-scrolled .hm-header__brand .custom-logo {
	width: auto;
	height: 60px;
	max-height: 60px;
	max-width: 190px;
	object-fit: contain;
}
.hm-header__nav { min-width: 0; }
.hm-header__menu { gap: clamp(20px,2vw,34px); }
.hm-header__menu > li > a {
	min-height: 48px;
	font-size: 16px;
	font-weight: 500;
	letter-spacing: .005em;
	color: rgba(255,255,255,.92);
}
.hm-header__menu > li > a:hover,
.hm-header__menu > li > a:focus-visible { color: #18a891; }
.hm-header__menu > li.menu-item-has-children > a::after {
	content: "";
	width: 6px;
	height: 6px;
	margin: -3px 0 0 10px;
	border-right: 1px solid currentColor;
	border-bottom: 1px solid currentColor;
	transform: rotate(45deg);
	opacity: .7;
}
.hm-header__menu > li > .sub-menu {
	top: calc(100% + 10px);
	grid-template-rows: repeat(8, max-content);
	grid-auto-flow: column;
	grid-auto-columns: minmax(205px, 230px);
	gap: 2px 18px;
	padding: 18px;
	border: 1px solid rgba(255,255,255,.09);
	border-radius: 12px;
	background: #20242c;
	box-shadow: 0 24px 60px rgba(0,0,0,.34);
}
.hm-header__menu > li > .sub-menu::before {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	top: -11px;
	height: 12px;
}
.hm-header__menu .sub-menu a {
	padding: 11px 12px;
	border-radius: 6px;
	color: rgba(255,255,255,.82);
	font-size: 13px;
	font-weight: 450;
	line-height: 1.4;
}
.hm-header__menu .sub-menu a:hover,
.hm-header__menu .sub-menu a:focus-visible {
	background: rgba(24,168,145,.10);
	color: #35d2b7;
}
.hm-header__actions {
	gap: clamp(13px,1.2vw,20px);
}
.hm-header__icon-link {
	width: 34px;
	height: 42px;
	color: rgba(255,255,255,.92);
}
.hm-header__icon-link svg { width: 21px; height: 21px; stroke-width: 1.65; }
.hm-header__socials {
	gap: 10px;
	padding-left: 17px;
	margin-left: 1px;
	border-left: 1px solid rgba(255,255,255,.18);
}
.hm-header__cta {
	min-width: 132px;
	min-height: 48px;
	padding: 0 23px;
	gap: 14px;
	font-size: 13px;
	font-weight: 600;
	box-shadow: 0 5px 14px rgba(24,168,145,.12);
}
.hm-header__right-logo {
	padding-left: 22px;
	margin-left: 2px;
	border-left: 1px solid rgba(255,255,255,.18);
}
.hm-header__right-logo img,
.hm-header.is-scrolled .hm-header__right-logo img {
	width: 50px;
	height: 50px;
}
.hm-header.is-scrolled .hm-header__bar { min-height: 94px; }
.hm-header__brand .custom-logo-link { flex: 0 0 auto; }
.hm-header__toggle { color: #fff; }

/* Give the menu and actions room; switch to the mobile overlay before they become cramped. */
@media (max-width: 1390px) and (min-width: 1101px) {
	.hm-header__bar {
		width: calc(100% - 48px);
		grid-template-columns: 168px minmax(0,1fr) auto;
		gap: 20px;
	}
	.hm-header__brand .custom-logo,
	.hm-header.is-scrolled .hm-header__brand .custom-logo { max-width: 168px; }
	.hm-header__menu { gap: clamp(13px,1.35vw,20px); }
	.hm-header__menu > li > a { font-size: 16px; }
	.hm-header__actions { gap: 10px; }
	.hm-header__right-logo { display: none; }
	.hm-header__socials { padding-left: 10px; }
	.hm-header__cta { min-width: 112px; padding-inline: 16px; }
}
@media (max-width: 1100px) {
	.hm-header__bar {
		display: flex;
		justify-content: space-between;
		width: calc(100% - 48px);
		min-height: 88px;
		gap: 20px;
	}
	.hm-header__nav { display: none; }
	.hm-header__brand .custom-logo,
	.hm-header.is-scrolled .hm-header__brand .custom-logo {
		height: 58px;
		max-height: 58px;
		max-width: min(42vw,190px);
	}
	.hm-header__actions { margin-left: auto; gap: 14px; }
	.hm-header__right-logo { display: none; }
	.hm-header__actions > .hm-header__socials,
	.hm-header__actions > .hm-header__cta { display: none; }
	.hm-header.is-scrolled .hm-header__bar { min-height: 88px; }
}
@media (max-width: 600px) {
	.hm-header__bar { width: calc(100% - 32px); min-height: 76px; }
	.hm-header.is-scrolled .hm-header__bar { min-height: 76px; }
	.hm-header__brand .custom-logo,
	.hm-header.is-scrolled .hm-header__brand .custom-logo {
		height: 48px;
		max-height: 48px;
		max-width: min(45vw,165px);
	}
	.hm-header__actions { gap: 8px; }
	.hm-header__icon-link { width: 32px; }
	.hm-header__toggle { width: 42px; height: 42px; }
	.hm-header__mobile-panel:not([hidden]) { padding: 94px 22px 32px; }
	.admin-bar .hm-header__mobile-panel:not([hidden]) { padding-top: 116px; }
}


/* CTA bewusst zurücknehmen: als ruhiger Teil der Navigation statt als Fremdkörper. */
.hm-header .hm-header__cta {
	background: transparent;
	color: rgba(255,255,255,.88);
	border: 1px solid rgba(255,255,255,.24);
	border-radius: 999px;
	box-shadow: none;
	min-width: 116px;
	min-height: 44px;
	padding: 0 19px;
	gap: 10px;
	font-size: 13px;
	font-weight: 500;
	letter-spacing: .01em;
	transition: color .2s ease, border-color .2s ease, background-color .2s ease;
}
.hm-header .hm-header__cta:hover,
.hm-header .hm-header__cta:focus-visible {
	background: rgba(24,168,145,.09);
	border-color: rgba(24,168,145,.62);
	color: #fff;
	box-shadow: none;
}
.hm-header .hm-header__cta svg,
.hm-header .hm-header__cta .hm-header__cta-arrow {
	color: #18a891;
}
@media (max-width: 1390px) and (min-width: 1101px) {
	.hm-header .hm-header__cta {
		min-width: 106px;
		padding-inline: 14px;
	}
}


/* Mobile navigation refinement: close control, spacious actions and clear menu footer. */
@media (max-width: 1100px) {
	.hm-header__actions {
		gap: clamp(12px, 2.2vw, 18px);
	}
	.hm-header__icon-link {
		width: 36px;
		min-width: 36px;
	}
	.hm-header__toggle {
		flex: 0 0 48px;
		width: 48px;
		height: 48px;
		margin-left: 2px;
	}
	.hm-header__mobile-panel:not([hidden]) {
		box-sizing: border-box;
		padding: max(18px, env(safe-area-inset-top)) 28px max(28px, env(safe-area-inset-bottom));
	}
	.admin-bar .hm-header__mobile-panel:not([hidden]) {
		padding-top: max(52px, calc(env(safe-area-inset-top) + 34px));
	}
	.hm-header__mobile-panel-inner {
		gap: 26px;
		min-height: 100%;
	}
	.hm-header__mobile-panel-top {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 20px;
		padding-bottom: 18px;
		border-bottom: 1px solid rgba(255,255,255,.12);
	}
	.hm-header__mobile-home {
		display: inline-flex;
		align-items: center;
		min-width: 0;
		color: #fff;
		text-decoration: none;
	}
	.hm-header__mobile-home .custom-logo {
		display: block;
		width: auto;
		height: auto;
		max-width: min(48vw, 190px);
		max-height: 48px;
		object-fit: contain;
	}
	.hm-header__close {
		display: inline-flex;
		flex: 0 0 48px;
		align-items: center;
		justify-content: center;
		position: relative;
		width: 48px;
		height: 48px;
		padding: 0;
		border: 1px solid rgba(255,255,255,.35);
		border-radius: 50%;
		background: transparent;
		color: #fff;
		cursor: pointer;
	}
	.hm-header__close span {
		position: absolute;
		width: 19px;
		height: 2px;
		border-radius: 2px;
		background: currentColor;
	}
	.hm-header__close span:first-child { transform: rotate(45deg); }
	.hm-header__close span:last-child { transform: rotate(-45deg); }
	.hm-header__close:hover,
	.hm-header__close:focus-visible {
		border-color: var(--hm-header-accent);
		color: var(--hm-header-accent);
	}
	.hm-header__mobile-menu > li { border-bottom: 1px solid rgba(255,255,255,.14); }
	.hm-header__mobile-menu > li > a {
		position: relative;
		justify-content: space-between;
		min-height: 58px;
		padding: 16px 0;
		font-size: clamp(19px, 4.5vw, 23px);
		line-height: 1.25;
	}
	.hm-header__mobile-menu > li.menu-item-has-children > a::after {
		content: "";
		flex: 0 0 9px;
		width: 9px;
		height: 9px;
		margin-left: 18px;
		border-top: 1.5px solid var(--hm-header-accent);
		border-right: 1.5px solid var(--hm-header-accent);
		transform: rotate(45deg);
	}
	/* Baugruppen in der Shop-Ebene öffnen eine weitere mobile Menüebene. */
	.hm-header__mobile-menu > li.hm-header__mobile-has-sublevel > a::after {
		content: "";
		flex: 0 0 9px;
		width: 9px;
		height: 9px;
		margin-left: 18px;
		border-top: 1.5px solid var(--hm-header-accent);
		border-right: 1.5px solid var(--hm-header-accent);
		transform: rotate(45deg);
	}
	.hm-header__mobile-menu .sub-menu { display: none !important; }
	.hm-header__mobile-nav.has-sublevel .hm-header__mobile-menu > li { border: 0; }
	.hm-header__mobile-level { animation: hm-header-level-in .18s ease-out both; }
	.hm-header__mobile-back {
		display: inline-flex;
		align-items: center;
		gap: 10px;
		min-height: 44px;
		margin: 0 0 14px;
		padding: 0;
		border: 0;
		background: transparent;
		color: rgba(255,255,255,.78);
		font: inherit;
		font-size: 15px;
		cursor: pointer;
	}
	.hm-header__mobile-back span:first-child {
		color: var(--hm-header-accent);
		font-size: 22px;
		line-height: 1;
	}
	.hm-header__mobile-level-title {
		margin-bottom: 10px;
		color: var(--hm-header-accent);
		font-size: 12px;
		font-weight: 700;
		letter-spacing: .16em;
		text-transform: uppercase;
	}
	.hm-header__mobile-sublevel > li > a {
		min-height: 54px;
		padding: 15px 0;
		font-size: 19px;
	}
	.hm-header__mobile-sublevel > .hm-header__mobile-baugruppen-heading {
		margin-top: 14px;
		padding: 22px 0 4px;
		border-top: 1px solid rgba(255,255,255,.2);
		color: rgba(255,255,255,.58);
		font-size: 12px;
		font-weight: 600;
		letter-spacing: .08em;
		line-height: 1.4;
	}
	.hm-header__mobile-utility {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px;
		padding-top: 20px;
		border-top: 1px solid rgba(255,255,255,.14);
	}
	.hm-header__mobile-utility-link {
		min-height: 48px;
		gap: 10px;
		font-size: 15px;
	}
	.hm-header__mobile-utility-link svg { flex: 0 0 22px; }
	.hm-header__mobile-socials {
		gap: 12px;
		padding-top: 2px;
	}
	.hm-header__mobile-socials .hm-header__icon-link {
		width: 42px;
		height: 42px;
		border: 1px solid rgba(255,255,255,.18);
		border-radius: 50%;
	}
	.hm-header__cta--mobile {
		align-self: flex-start;
		min-width: 136px;
		min-height: 48px;
	}
	.hm-header__mobile-logos {
		display: flex;
		align-items: center;
		gap: 22px;
		min-height: 42px;
		padding-top: 4px;
	}
	.hm-header__mobile-logos .hm-header__partner-logo { display: inline-flex; align-items: center; }
	.hm-header__mobile-logos img { max-width: 88px; max-height: 40px; }
}
@media (max-width: 600px) {
	.hm-header__bar { width: calc(100% - 36px); }
	.hm-header__brand .custom-logo,
	.hm-header.is-scrolled .hm-header__brand .custom-logo {
		max-width: min(43vw, 170px);
	}
	/* Balance the visible gaps: tighter account/cart spacing, more room before menu. */
	.hm-header__actions { gap: 8px; }
	.hm-header__icon-link { width: 34px; min-width: 34px; }
	.hm-header__toggle { flex-basis: 46px; width: 46px; height: 46px; margin-left: 16px; }
	.hm-header__mobile-panel:not([hidden]) {
		padding-right: 22px;
		padding-left: 22px;
	}
	.hm-header__mobile-panel-inner { gap: 22px; }
	.hm-header__mobile-panel-top { padding-bottom: 14px; }
	.hm-header__mobile-home .custom-logo { max-width: min(48vw, 174px); max-height: 44px; }
	.hm-header__mobile-utility { grid-template-columns: minmax(0, 1fr); gap: 4px; }
	.hm-header__mobile-utility-link { min-height: 44px; }
}
@keyframes hm-header-level-in {
	from { opacity: 0; transform: translateX(8px); }
	to { opacity: 1; transform: translateX(0); }
}
@media (prefers-reduced-motion: reduce) {
	.hm-header__mobile-level { animation: none; }
}


/* Mobile header follow-up: stacking, navigation overview and aligned footer groups. */
@media (max-width: 1100px) {
	/* Keep the menu above page-specific heroes, filters and product overlays. */
	.hm-header.is-menu-open {
		position: relative;
		z-index: 2147483000;
	}
	.hm-header.is-menu-open .hm-header__mobile-panel:not([hidden]) {
		z-index: 2147483000;
	}

	/* The menu list owns its separators; the utility section adds the next divider. */
	.hm-header__mobile-menu > li:last-child {
		border-bottom: 0;
	}

	/* Account left, cart right. */
	.hm-header__mobile-utility {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: 12px;
	}
	.hm-header__mobile-utility-link {
		flex: 1 1 0;
		min-width: 0;
	}
	.hm-header__mobile-utility-link:last-child {
		justify-content: flex-end;
		text-align: right;
	}

	/* Social links left, contact action right, on one row. */
	.hm-header__mobile-panel-inner {
		gap: 22px;
	}
	.hm-header__mobile-socials {
		display: flex;
		align-items: center;
		gap: 10px;
		margin-top: 0;
	}
	.hm-header__mobile-socials .hm-header__icon-link {
		flex: 0 0 42px;
	}
	.hm-header__mobile-panel-inner > .hm-header__cta--mobile {
		align-self: auto;
		margin-left: auto;
	}
	.hm-header__mobile-socials,
	.hm-header__cta--mobile {
		grid-row: auto;
	}
	.hm-header__mobile-panel-inner {
		display: grid;
		grid-template-columns: minmax(0, 1fr) auto;
		align-content: start;
	}
	.hm-header__mobile-panel-top,
	.hm-header__mobile-nav,
	.hm-header__mobile-utility,
	.hm-header__mobile-logos {
		grid-column: 1 / -1;
	}
	.hm-header__mobile-socials {
		grid-column: 1;
		align-self: center;
	}
	.hm-header__mobile-panel-inner > .hm-header__cta--mobile {
		grid-column: 2;
		grid-row: auto;
		justify-self: end;
		white-space: nowrap;
	}
	.hm-header__mobile-logos {
		justify-content: center;
		padding-top: 0;
	}
	.hm-header__mobile-logos img {
		max-width: 132px;
		max-height: 60px;
	}
	.hm-header__mobile-logos .hm-header__partner-logo img {
		max-width: 132px;
		max-height: 60px;
	}
	.hm-header__mobile-parent-link > a {
		color: var(--hm-header-accent);
		font-size: 15px;
		font-weight: 600;
	}
}
@media (max-width: 600px) {
	.hm-header__mobile-panel:not([hidden]) {
		padding-right: 22px;
		padding-left: 22px;
	}
	.hm-header__mobile-utility {
		display: flex;
		flex-direction: row;
	}
	.hm-header__mobile-utility-link {
		font-size: 14px;
	}
	.hm-header__mobile-socials .hm-header__icon-link {
		width: 38px;
		height: 38px;
		flex-basis: 38px;
	}
	.hm-header__mobile-logos img,
	.hm-header__mobile-logos .hm-header__partner-logo img {
		max-width: 132px;
		max-height: 60px;
	}
}


/* Desktop: dritte Shop-Ebene für tatsächlich verfügbare Bauteile */
@media (min-width: 1101px) {
	.hm-header__menu > li > .sub-menu > li.hm-header__desktop-has-sublevel {
		position: relative;
	}
	.hm-header__menu > li > .sub-menu > li.hm-header__desktop-has-sublevel > a::after {
		content: "";
		width: 6px;
		height: 6px;
		margin-left: auto;
		margin-right: 2px;
		border-top: 1px solid currentColor;
		border-right: 1px solid currentColor;
		transform: rotate(45deg);
		opacity: .75;
		flex: 0 0 auto;
	}
	.hm-header__menu > li > .sub-menu > li > .hm-header__desktop-bauteile {
		position: absolute;
		top: -12px;
		left: 100%;
		display: none;
		grid-auto-flow: row;
		grid-template-rows: none;
		grid-auto-columns: minmax(190px, 240px);
		gap: 2px;
		width: max-content;
		max-width: min(320px, calc(100vw - 40px));
		max-height: min(70vh, 560px);
		overflow-y: auto;
		padding: 12px;
		border: 1px solid rgba(255,255,255,.1);
		border-radius: 14px;
		background: var(--hm-header-dark);
		box-shadow: 0 18px 44px rgba(0,0,0,.28);
		z-index: 1002;
	}
	.hm-header__menu > li > .sub-menu > li:hover > .hm-header__desktop-bauteile,
	.hm-header__menu > li > .sub-menu > li:focus-within > .hm-header__desktop-bauteile {
		display: grid !important;
	}
	.hm-header__menu > li > .sub-menu > li > .hm-header__desktop-bauteile a {
		display: flex;
		width: 100%;
		padding: 10px 12px;
		border-radius: 7px;
		white-space: normal;
	}
}


/* Desktop: keep the third-level menu inside narrower viewports.
   Preserve the existing submenu and hover rules; only change its opening side. */
@media (min-width: 1101px) and (max-width: 1350px) {
	.hm-header__menu > li > .sub-menu > li > .hm-header__desktop-bauteile {
		left: auto;
		right: 100%;
	}
}


/* Mobile menu polish: only the actual current page uses the teal accent.
   Touch-generated hover/focus must not leave unrelated entries highlighted. */
@media (max-width: 921px) {
  .hm-header__mobile-menu a:hover,
  .hm-header__mobile-menu a:focus,
  .hm-header__mobile-menu a:focus-visible,
  .hm-header__mobile-menu a:active {
    color: rgba(255,255,255,.92);
  }
  .hm-header__mobile-menu a.is-current-page,
  .hm-header__mobile-menu a[aria-current="page"] {
    color: #18A891;
  }
  .hm-header__mobile-back {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    margin: 0 0 14px;
    padding: 0;
    border: 0;
    background: transparent;
    color: rgba(255,255,255,.78);
    font: inherit;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
    text-align: left;
    appearance: none;
    -webkit-appearance: none;
    box-shadow: none;
  }
  .hm-header__mobile-back span:first-child {
    color: var(--hm-header-accent);
    font-size: 22px;
    line-height: 1;
  }
  .hm-header__mobile-back:hover,
  .hm-header__mobile-back:focus,
  .hm-header__mobile-back:active {
    color: rgba(255,255,255,.78);
    background: transparent;
    box-shadow: none;
  }
}


/* Desktop dropdown layering: keep every open menu level above page content
   (hero, shop filter and product overlays) without changing its geometry. */
@media (min-width: 1101px) {
  .hm-header:has(.hm-header__menu > li:hover),
  .hm-header:has(.hm-header__menu > li:focus-within) {
    position: sticky;
    top: 0;
    z-index: 2147483000;
  }
  .admin-bar .hm-header:has(.hm-header__menu > li:hover),
  .admin-bar .hm-header:has(.hm-header__menu > li:focus-within) {
    top: 32px;
  }
  .hm-header__menu > li > .sub-menu,
  .hm-header__menu .sub-menu .sub-menu {
    z-index: 2147483001;
  }
}


/* Desktop level 3: show at most seven entries per column, then continue
   horizontally instead of creating a clipped/scrolling single column. */
@media (min-width: 1101px) {
  .hm-header__menu > li > .sub-menu > li > .hm-header__desktop-bauteile {
    grid-auto-flow: column;
    grid-template-rows: repeat(7, minmax(0, auto));
    grid-auto-columns: minmax(190px, 240px);
    grid-template-columns: none;
    width: max-content;
    max-width: none;
    max-height: none;
    overflow: visible;
  }
}

/* Mobile: keep the header logo at the same size while scrolling. */
@media (max-width: 600px) {
	.hm-header__brand .custom-logo,
	.hm-header.is-scrolled .hm-header__brand .custom-logo {
		width: auto;
		height: 48px;
		max-height: 48px;
		max-width: min(43vw, 170px);
		transform: none;
	}
}


/* Final mobile fix: the logo must not grow when the sticky header changes state.
   Use the same explicit dimensions in normal and scrolled states. */
@media (max-width: 600px) {
  .hm-header .hm-header__brand .custom-logo-link,
  .hm-header.is-scrolled .hm-header__brand .custom-logo-link {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    height: 48px;
    max-height: 48px;
  }
  .hm-header .hm-header__brand img.custom-logo,
  .hm-header.is-scrolled .hm-header__brand img.custom-logo {
    display: block;
    width: auto !important;
    height: 48px !important;
    min-height: 0 !important;
    max-height: 48px !important;
    max-width: min(43vw, 170px) !important;
    transform: none !important;
    transition: none !important;
    object-fit: contain;
  }
}


/* Header Mini-Warenkorb – visuell an das Heritage Header-System angepasst. */

/* -------------------------------------------------------------------------
   Heritage Mini-Warenkorb
   Root-level Drawer: bewusst nicht unter #hm-site-header verschachteln.
   ------------------------------------------------------------------------- */
.hm-header__cart-overlay[hidden] {
	display: none !important;
}
.hm-header__cart-overlay:not([hidden]) {
	position: fixed !important;
	inset: 0 !important;
	z-index: 99990 !important;
	display: block !important;
	background: rgba(12, 14, 18, .68) !important;
	-webkit-backdrop-filter: blur(5px);
	backdrop-filter: blur(5px);
}
.hm-header__mini-cart {
	position: fixed !important;
	top: 0 !important;
	right: 0 !important;
	bottom: 0 !important;
	left: auto !important;
	z-index: 99991 !important;
	display: flex !important;
	flex-direction: column !important;
	width: min(470px, 100vw) !important;
	height: auto !important;
	max-height: none !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	overflow: hidden !important;
	box-sizing: border-box !important;
	background: #f7f7f5 !important;
	color: #171a21 !important;
	border: 0 !important;
	border-left: 1px solid rgba(23, 26, 33, .12) !important;
	border-radius: 0 !important;
	box-shadow: -18px 0 55px rgba(0, 0, 0, .24) !important;
	transform: translate3d(105%, 0, 0);
	visibility: hidden;
	transition: transform .28s ease, visibility .28s ease !important;
}
.hm-header__mini-cart.is-open {
	transform: translate3d(0, 0, 0) !important;
	visibility: visible !important;
}
body.admin-bar .hm-header__mini-cart {
	top: 32px !important;
	bottom: 0 !important;
	height: auto !important;
	max-height: none !important;
	min-height: 0 !important;
}
.hm-header__mini-cart-head {
	position: relative !important;
	z-index: 1 !important;
	flex: 0 0 auto !important;
	display: flex !important;
	align-items: center !important;
	justify-content: space-between !important;
	gap: 18px !important;
	min-height: 82px !important;
	margin: 0 !important;
	padding: 20px 26px !important;
	box-sizing: border-box !important;
	background: #171a21 !important;
	border: 0 !important;
	border-bottom: 3px solid #18a891 !important;
}
.hm-header__mini-cart-head h2 {
	margin: 0 !important;
	padding: 0 !important;
	color: #fff !important;
	font-size: 22px !important;
	font-weight: 700 !important;
	line-height: 1.25 !important;
	letter-spacing: -.025em !important;
}
.hm-header__mini-cart-close {
	flex: 0 0 38px !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 38px !important;
	height: 38px !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 1px solid rgba(255, 255, 255, .35) !important;
	border-radius: 50% !important;
	background: transparent !important;
	color: #fff !important;
	font-size: 25px !important;
	line-height: 1 !important;
	box-shadow: none !important;
	cursor: pointer !important;
}
.hm-header__mini-cart-scroll {
	flex: 1 1 0% !important;
	display: block !important;
	width: 100% !important;
	height: auto !important;
	min-width: 0 !important;
	min-height: 0 !important;
	max-height: none !important;
	margin: 0 !important;
	padding: 24px 26px 30px !important;
	box-sizing: border-box !important;
	overflow-x: hidden !important;
	overflow-y: auto !important;
	-webkit-overflow-scrolling: touch !important;
	overscroll-behavior-y: contain !important;
	background: #f7f7f5 !important;
}
.hm-header__mini-cart-scroll > .widget_shopping_cart_content {
	width: 100% !important;
	min-width: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	box-sizing: border-box !important;
	overflow: visible !important;
}
.hm-header__mini-cart-scroll *,
.hm-header__mini-cart-scroll *::before,
.hm-header__mini-cart-scroll *::after {
	box-sizing: border-box;
}
.hm-header__mini-cart-scroll ul.woocommerce-mini-cart {
	display: block !important;
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none !important;
}
.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item {
	position: relative !important;
	float: none !important;
	display: block !important;
	width: 100% !important;
	min-height: 96px !important;
	margin: 0 !important;
	padding: 2px 34px 22px 94px !important;
	border: 0 !important;
	border-bottom: 1px solid #deded9 !important;
	color: #171a21 !important;
	font-size: 13px !important;
	line-height: 1.5 !important;
	overflow-wrap: anywhere !important;
}
.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item + li.woocommerce-mini-cart-item {
	margin-top: 22px !important;
}
.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item a:not(.remove) {
	display: block !important;
	margin: 0 !important;
	padding: 0 !important;
	color: #171a21 !important;
	font-size: 13px !important;
	font-weight: 600 !important;
	line-height: 1.55 !important;
	text-decoration: none !important;
}
.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item img {
	position: absolute !important;
	top: 50% !important;
	left: 0 !important;
	float: none !important;
	display: block !important;
	transform: translateY(-50%) !important;
	width: 76px !important;
	height: 76px !important;
	max-width: 76px !important;
	margin: 0 !important;
	padding: 5px !important;
	border: 1px solid #e4e4df !important;
	border-radius: 10px !important;
	background: #fff !important;
	object-fit: contain !important;
}
.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item a.remove {
	position: absolute !important;
	top: 0 !important;
	right: 0 !important;
	left: auto !important;
	z-index: 1 !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 25px !important;
	height: 25px !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 1px solid #cfd1d0 !important;
	border-radius: 50% !important;
	background: #fff !important;
	color: #62656a !important;
	font-size: 18px !important;
	line-height: 1 !important;
}
.hm-header__mini-cart-scroll .quantity {
	display: block !important;
	margin-top: 9px !important;
	color: #686b70 !important;
	font-size: 12px !important;
	line-height: 1.4 !important;
}
.hm-header__mini-cart-scroll p.woocommerce-mini-cart__total {
	margin: 22px 0 0 !important;
	padding: 20px 0 16px !important;
	border-top: 1px solid #deded9 !important;
	color: #171a21 !important;
	font-size: 15px !important;
	line-height: 1.5 !important;
}
.hm-header__mini-cart-scroll .woocommerce-mini-cart__buttons {
	display: grid !important;
	grid-template-columns: 1fr !important;
	gap: 10px !important;
	margin: 0 !important;
	padding: 6px 0 0 !important;
}
.hm-header__mini-cart-scroll .woocommerce-mini-cart__buttons a.button {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 100% !important;
	min-height: 50px !important;
	margin: 0 !important;
	padding: 14px 20px !important;
	border: 1px solid #18a891 !important;
	border-radius: 28px !important;
	background: #18a891 !important;
	color: #fff !important;
	font-size: 12px !important;
	font-weight: 700 !important;
	line-height: 1.35 !important;
	letter-spacing: .04em !important;
	text-align: center !important;
	text-transform: uppercase !important;
	text-decoration: none !important;
	box-shadow: none !important;
}
.hm-header__mini-cart-scroll .woocommerce-mini-cart__buttons a.checkout {
	border-color: #171a21 !important;
	background: #171a21 !important;
}
.hm-header__mini-cart-scroll .woocommerce-mini-cart__empty-message {
	margin: 0 !important;
	padding: 28px 0 !important;
	color: #62656a !important;
	font-size: 14px !important;
	line-height: 1.6 !important;
}
body.hm-mini-cart-open {
	overflow: hidden !important;
}
@media (max-width: 600px) {
	.hm-header__mini-cart {
		width: 100vw !important;
	}
	.hm-header__mini-cart-head {
		min-height: 72px !important;
		padding: 16px 20px !important;
	}
	.hm-header__mini-cart-scroll {
		padding: 20px 20px 28px !important;
	}
	.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item {
		padding-left: 84px !important;
	}
\t.hm-header__mini-cart-scroll ul.woocommerce-mini-cart li.woocommerce-mini-cart-item img {
		top: 50% !important;
		transform: translateY(-50%) !important;
		width: 68px !important;
		height: 68px !important;
		max-width: 68px !important;
	}
	body.admin-bar .hm-header__mini-cart {
		top: 46px !important;
		height: calc(100vh - 46px) !important;
		height: calc(100dvh - 46px) !important;
		max-height: calc(100vh - 46px) !important;
		max-height: calc(100dvh - 46px) !important;
	}
}
@media (prefers-reduced-motion: reduce) {
	.hm-header__mini-cart {
		transition: none !important;
	}
}


/* Kompakter Hinweis zur Differenzbesteuerung im Mini-Warenkorb. */
#hm-header-mini-cart .hm-header__mini-cart-scroll .tax-info,
#hm-header-mini-cart .hm-header__mini-cart-scroll .wc-gzd-additional-info,
#hm-header-mini-cart .hm-header__mini-cart-scroll .woocommerce-tax-info,
#hm-header-mini-cart .hm-header__mini-cart-scroll .hm-global-tax-notice {
	font-size: 12px !important;
	line-height: 1.4 !important;
	letter-spacing: 0 !important;
}


/* Header-Suche: kompaktes Heritage-Pop-up neben dem Account-Symbol. */
.hm-header__search {
	position: relative;
	display: inline-flex;
	align-items: center;
	flex: 0 0 auto;
}
.hm-header__search-toggle {
	cursor: pointer;
	font: inherit;
}
.hm-header__search-panel[hidden] {
	display: none !important;
}
.hm-header__search-panel {
	position: absolute;
	top: calc(100% + 17px);
	right: -54px;
	z-index: 10020;
	width: min(410px, calc(100vw - 32px));
	padding: 22px;
	border: 1px solid rgba(23, 26, 33, .12);
	border-top: 3px solid #18a891;
	border-radius: 14px;
	background: #f7f7f5;
	color: #171a21;
	box-shadow: 0 18px 48px rgba(0, 0, 0, .22);
	white-space: normal;
}
.hm-header__search-panel::before {
	position: absolute;
	top: -9px;
	right: 62px;
	width: 14px;
	height: 14px;
	border-top: 1px solid rgba(23, 26, 33, .12);
	border-left: 1px solid rgba(23, 26, 33, .12);
	background: #18a891;
	content: "";
	transform: rotate(45deg);
}
.hm-header__search-panel-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin: 0 0 16px;
}
.hm-header__search-panel-head strong {
	color: #171a21;
	font-size: 17px;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: -.02em;
}
.hm-header__search-close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 30px;
	width: 30px;
	height: 30px;
	padding: 0;
	border: 1px solid #d8d9d4;
	border-radius: 50%;
	background: transparent;
	color: #171a21;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}
.hm-header__search-form {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 10px;
	margin: 0;
}
.hm-header__search-form input[type="search"] {
	display: block;
	width: 100%;
	min-width: 0;
	min-height: 48px;
	margin: 0;
	padding: 12px 15px;
	border: 1px solid #d8d9d4;
	border-radius: 9px;
	outline: none;
	background: #fff;
	color: #171a21;
	font: inherit;
	font-size: 14px;
	box-shadow: none;
}
.hm-header__search-form input[type="search"]:focus {
	border-color: #18a891;
	box-shadow: 0 0 0 3px rgba(24, 168, 145, .14);
}
.hm-header__search-form button[type="submit"] {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	width: 100%;
	min-height: 46px;
	margin: 0;
	padding: 12px 17px;
	border: 1px solid #18a891;
	border-radius: 28px;
	background: #18a891;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: .06em;
	text-transform: uppercase;
	cursor: pointer;
	box-shadow: none;
}
.hm-header__search-form button[type="submit"]:hover {
	border-color: #128b79;
	background: #128b79;
	color: #fff;
}
.hm-header__search-form button[type="submit"] span {
	font-size: 19px;
	line-height: 1;
}
@media (max-width: 600px) {
	.hm-header__search-panel {
		position: fixed;
		top: calc(var(--hm-header-height, 78px) + 12px);
		right: 12px;
		width: calc(100vw - 24px);
		padding: 20px;
	}
	.hm-header__search-panel::before {
		right: auto;
		left: 24px;
	}
}


/* Header-Suche v2: dunkles Panel und Akzent ausschließlich auf der Lupe. */
.hm-header__search .hm-header__search-toggle,
.hm-header__search .hm-header__search-toggle:hover,
.hm-header__search .hm-header__search-toggle:focus,
.hm-header__search .hm-header__search-toggle:focus-visible,
.hm-header__search .hm-header__search-toggle:active {
	background: transparent !important;
	background-color: transparent !important;
	border: 0 !important;
	border-color: transparent !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	outline-offset: 3px;
}
.hm-header__search .hm-header__search-toggle {
	color: rgba(255, 255, 255, .92);
}
.hm-header__search .hm-header__search-toggle:hover,
.hm-header__search .hm-header__search-toggle:focus-visible,
.hm-header__search .hm-header__search-toggle[aria-expanded="true"] {
	color: #18a891 !important;
}
.hm-header__search .hm-header__search-toggle svg {
	stroke: currentColor !important;
	fill: none !important;
}
.hm-header__search-panel {
	border-color: rgba(255, 255, 255, .12);
	border-top-color: #18a891;
	background: #171a21;
	color: #fff;
	box-shadow: 0 18px 48px rgba(0, 0, 0, .38);
}
.hm-header__search-panel::before {
	border-top-color: rgba(255, 255, 255, .12);
	border-left-color: rgba(255, 255, 255, .12);
	background: #171a21;
}
.hm-header__search-panel-head strong {
	color: #fff;
}
.hm-header__search-close {
	border-color: rgba(255, 255, 255, .22);
	background: transparent;
	color: rgba(255, 255, 255, .88);
}
.hm-header__search-close:hover,
.hm-header__search-close:focus-visible {
	border-color: #18a891;
	background: transparent;
	color: #18a891;
}
.hm-header__search-form input[type="search"] {
	border-color: rgba(255, 255, 255, .18);
	background: #22262d;
	color: #fff;
}
.hm-header__search-form input[type="search"]::placeholder {
	color: #a9adb4;
	opacity: 1;
}
.hm-header__search-form input[type="search"]:focus {
	border-color: #18a891;
	background: #22262d;
	box-shadow: 0 0 0 3px rgba(24, 168, 145, .16);
}


/* Such-Pop-up: dekorative Raute unter der Lupe entfernen. */
.hm-header__search-panel::before {
	display: none !important;
	content: none !important;
}


/* Mobile Header – Icon-Gruppe ausgewogen ausrichten */
@media (max-width: 600px) {
	.hm-header .hm-header__actions {
		gap: 10px;
	}

	.hm-header .hm-header__search,
	.hm-header .hm-header__account,
	.hm-header .hm-header__cart {
		width: 32px;
		min-width: 32px;
		flex: 0 0 32px;
		margin: 0;
	}

	.hm-header .hm-header__search-toggle,
	.hm-header .hm-header__account,
	.hm-header .hm-header__cart {
		width: 32px;
		min-width: 32px;
		padding: 0;
		justify-content: center;
	}

	.hm-header .hm-header__toggle {
		margin-left: 0;
	}
}


/* Mobile Header: Hauptlogo um ca. 10 % verkleinern */
@media (max-width: 600px) {
	.hm-header__brand .custom-logo,
	.hm-header.is-scrolled .hm-header__brand .custom-logo {
		height: 43px;
		max-height: 43px;
		max-width: min(38.7vw, 153px);
	}
}


/* Mobile-only Logo-Fix: tatsächliche Bildbreite verbindlich begrenzen.
   Gilt für normales und gescrolltes Header-Layout, nicht für Desktop. */
@media screen and (max-width: 600px) {
	body .hm-header .hm-header__brand img.custom-logo,
	body .hm-header .hm-header__brand .custom-logo-link img,
	body .hm-header.is-scrolled .hm-header__brand img.custom-logo,
	body .hm-header.is-scrolled .hm-header__brand .custom-logo-link img {
		display: block !important;
		width: auto !important;
		height: 43px !important;
		max-height: 43px !important;
		max-width: min(38.7vw, 153px) !important;
		object-fit: contain !important;
	}
}

/* Shop mega menu: centered quick links above the complete Baugruppen navigation. */
@media (min-width: 922px) {
	.hm-header__menu > li.hm-header__shop-with-specials { position: relative; }
	.hm-header__menu > li.hm-header__shop-with-specials > .hm-header__shop-specials {
		position: absolute; top: calc(100% + 10px); left: 0; z-index: 1002;
		display: none; box-sizing: border-box; width: min(814px, calc(100vw - 40px));
		padding: 14px 18px 15px; border: 1px solid rgba(255,255,255,.08);
		border-bottom: 1px solid rgba(24,168,145,.55); border-radius: 14px 14px 0 0;
		background: #20242c; box-shadow: 0 18px 34px rgba(0,0,0,.22);
	}
	.hm-header__menu > li.hm-header__shop-with-specials > .hm-header__shop-specials::before {
		content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 13px;
	}
	.hm-header__menu > li.hm-header__shop-with-specials:hover > .hm-header__shop-specials,
	.hm-header__menu > li.hm-header__shop-with-specials:focus-within > .hm-header__shop-specials { display: block; }
	.hm-header__menu > li.hm-header__shop-with-specials .hm-header__shop-specials-grid {
		display: grid !important; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; width: 100%;
	}
	.hm-header__menu > li.hm-header__shop-with-specials .hm-header__shop-special-link {
		box-sizing: border-box; display: flex !important; min-width: 0; min-height: 36px;
		align-items: center; justify-content: center; padding: 6px 10px;
		border: 1px solid rgba(255,255,255,.09); border-radius: 8px;
		background: rgba(255,255,255,.035); color: rgba(255,255,255,.94);
		font-size: 12px; font-weight: 600; line-height: 1.25; text-align: center;
		text-decoration: none; white-space: normal;
		transition: background-color .18s ease, border-color .18s ease, color .18s ease;
	}
	.hm-header__menu > li.hm-header__shop-with-specials .hm-header__shop-special-label {
		display: block; flex: 1 1 auto; min-width: 0; text-align: center;
	}
	.hm-header__menu > li.hm-header__shop-with-specials .hm-header__shop-special-link:hover,
	.hm-header__menu > li.hm-header__shop-with-specials .hm-header__shop-special-link:focus-visible {
		border-color: rgba(24,168,145,.55); background: rgba(24,168,145,.12); color: #fff;
	}
	.hm-header__menu > li.hm-header__shop-with-specials > .sub-menu.hm-header__shop-baugruppen {
		top: calc(100% + 75px); z-index: 1001;
		box-sizing: border-box; width: min(814px, calc(100vw - 40px));
		border-top: 0; border-radius: 0 0 14px 14px;
		box-shadow: 0 24px 50px rgba(0,0,0,.3);
	}
	/* Großzügiger Hover-Korridor zwischen „Shop“ und dem tiefer liegenden Dropdown.
	   Verhindert, dass das Menü beim diagonalen Mausweg kurz den Hover-Fokus verliert. */
	.hm-header__menu > li.hm-header__shop-with-specials::after {
		content: "";
		position: absolute;
		top: 100%;
		left: -8px;
		display: none;
		/* Über die rechte Kante des Shop-Menüpunkts hinausführen, damit
		   auch eine schräge Mausbewegung nach rechts im Hover-Bereich bleibt. */
		width: max(180px, calc(100% + 120px));
		height: 86px;
		z-index: 1000;
		background: transparent;
		pointer-events: auto;
	}
	.hm-header__menu > li.hm-header__shop-with-specials:hover::after,
	.hm-header__menu > li.hm-header__shop-with-specials:focus-within::after {
		display: block;
	}
	/* Keep the section title anchored inside the dark Baugruppen panel. */
	.hm-header__menu > li.hm-header__shop-with-specials > .sub-menu.hm-header__shop-baugruppen {
		position: absolute;
		padding-top: 44px;
	}
	.hm-header__menu > li.hm-header__shop-with-specials > .sub-menu.hm-header__shop-baugruppen::before {
		content: "TEILE NACH BAUGRUPPE";
		position: absolute;
		top: 17px;
		left: 28px;
		right: 28px;
		display: block;
		padding-bottom: 9px;
		border-bottom: 0;
		color: #35d2b7;
		font-size: 10px;
		font-weight: 700;
		letter-spacing: .15em;
		line-height: 1.2;
		text-transform: uppercase;
		pointer-events: none;
	}
	.hm-header__menu > li.hm-header__shop-with-specials:hover > .sub-menu.hm-header__shop-baugruppen,
	.hm-header__menu > li.hm-header__shop-with-specials:focus-within > .sub-menu.hm-header__shop-baugruppen {
		display: grid !important; visibility: visible !important; opacity: 1 !important; pointer-events: auto;
	}
}
@media (max-width: 921px) {
	.hm-header__mobile-menu .hm-header__mobile-shop-special a { font-weight: 600; color: rgba(255,255,255,.95); }
	.hm-header__mobile-menu .hm-header__mobile-shop-special--first {
		margin-top: 0;
		padding-top: 0;
		border-top: 0;
	}
	.hm-header__mobile-menu .hm-header__mobile-shop-special--last {
		margin-bottom: 0; padding-bottom: 0; border-bottom: 0;
	}
	.hm-header__mobile-menu .hm-header__mobile-baugruppen-heading {
		display: block;
		margin-top: 8px;
		padding: 16px 0 10px;
		border-top: 1px solid rgba(255,255,255,.16);
		color: #18A891;
		font-size: 11px;
		font-weight: 700;
		letter-spacing: .08em;
		line-height: 1.3;
		text-transform: uppercase;
	}
}


/* Mobile shop submenu: preserve the divider before the Baugruppen group label. */
@media (max-width: 921px) {
	.hm-header__mobile-nav.has-sublevel .hm-header__mobile-sublevel > li.hm-header__mobile-baugruppen-heading {
		display: block;
		margin-top: 4px;
		padding: 14px 0 8px;
		border: 0;
		border-top: 1px solid rgba(255,255,255,.2);
		color: #18a891;
		font-size: 11px;
		font-weight: 700;
		letter-spacing: .08em;
		line-height: 1.3;
		text-transform: uppercase;
	}
}
