/* ===========================
KHW Navigation – Komplett CSS
Desktop + Overlay/Mobil, barrierefreundlich
=========================== */
:root {
	--primary: #326eb6; 
	--secondary: #9f1f1f;
	--third: #1b266e;
}
/* Logo links, Navigation rechts */
#header_wrap {
	position: fixed;
	z-index: 999;
	width: 100%;
	background: rgba(255,255,255,0.95);
	box-shadow:5px 5px 15px rgba(0,0,0,0.05);
}
#header_wrap.onscroll_link{
	background: rgba(255,255,255,1);
}
#social_top{
	background: #efefef;
	padding: 2px 25px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}
#social_top p{
	font-size: 0.9rem;
}
#social_top p i{
	color: var(--primary);
	margin-right: 5px;
	font-size: 1.1rem;
}
ul#social_navi_top{
	list-style: none;
	display: flex;
}
ul#social_navi_top li{
	margin-right: 5px;
}
ul#social_navi_top li a{
	font-size: 1.2rem;
	color: var(--primary);
}
#top .wrapper_nav {
	display: flex;
	align-items: center;
	justify-content: space-between; /* hält Logo links & Nav rechts */
	gap: 1rem;
}
#logo_wrap {
	flex: 0 0 auto;               /* Logo behält seine Breite */
}
#header_info{
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	margin-right: 25px;
}
#header_info div:first-child{
	padding: 2px 15px;
	border-left: 1px solid rgba(0,0,0,0.15);
}
#header_info i{
	color: var(--primary);
	font-size: 2.5rem;
}
#header_info p.head{
	color: var(--primary);
	font-weight: 700;
}
#header_info p{
	line-height: 120%;
}
#nav {
	flex: 1 1 auto;               /* nimmt restliche Breite */
	display: flex;
	align-items: center;
	justify-content: flex-end;    /* schiebt Inhalt nach rechts */
}
/* Desktop-Liste an den rechten Rand */
#nav .navigation_dt {
	margin-left: auto;            /* falls andere Styles dazwischen funken */
}
/* Mobil: Burger-Button rechts ausrichten */
#nav .menu-button {
	margin-left: auto;            /* sitzt rechts, wenn Desktop-Navi ausgeblendet ist */
}
#logo_wrap .logo {
	max-width: 75px;
	height: auto;
}
/* Screenreader-only Texte (z. B. beim Home-Icon) */
.sr-only {
	position: absolute !important;
	width: 1px; height: 1px;
	padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0,0,0,0);
	white-space: nowrap; border: 0;
}

/* Utility */
.clear { clear: both; }
.no-scroll { overflow: hidden; }

/* -------- Layout Header-Zeile -------- */
#top .wrapper_nav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding:5px 20px;
}
#logo_wrap {
	padding: 10px 0px;
}
#logo_wrap .logo,
.logo_mobil {
	max-width: 300px;
	height: auto;
}
#header_wrap.onscroll_link #logo_wrap .logo{
	max-width: 200px;
}

/* -------- Desktop Navigation -------- */
#nav {
	display: flex;
	align-items: center;
	gap: 1rem;
	position: relative;
}

/* Der Mobil-Button wird erst unter 980px sichtbar */
#nav .menu-button {
	display: none;
	background: none;
	border: none;
	font-size: 1.8rem;
	padding: .25rem .5rem;
	cursor: pointer;
	color: #333;
}

/* Hauptliste Desktop */
#nav .navigation_dt {
	list-style: none;
	margin: 0; padding: 0;
	display: flex;
	align-items: stretch;
	gap: .25rem;
}

#nav .navigation_dt > li {
	position: relative;
	display: flex;
	align-items: center;
}

/* Hauptlinks */
#nav .navigation_dt > li > a {
	display: inline-flex;
	align-items: center;
	gap: .4rem;
	padding: .7rem .9rem;
	text-decoration: none;
	color: #222;
	font-weight: 600;
	font-size: 1.1rem;
	line-height: 1.2;
}

/* Aktiver Punkt */
#nav .navigation_dt > li.aktiv > a {
	color: var(--primary);
	border-bottom: 2px solid var(--primary);
}

/* Toggle-Button für Untermenüs (Desktop) – steht direkt neben dem Link */
#nav .submenu-toggle {
	background: none;
	border: none;
	cursor: pointer;
	padding: .7rem .4rem;
	line-height: 1;
	color: #222;
}
#nav .submenu-toggle i { margin-left: .3rem; }

/* Fokuszustände (sichtbar & konsistent) */
#nav a:focus-visible,
#nav button:focus-visible {
	outline: 2px solid #137c6f;
	outline-offset: 2px;
}

/* Untermenüs Desktop */
#nav .sub {
	position: absolute;
	left: 0; top: 100%;
	min-width: 220px;
	background: #fff;
	border: 1px solid #e5e5e5;
	box-shadow: 0 8px 20px rgba(0,0,0,.08);
	list-style: none;
	padding: .4rem 0;
	margin: 0;
	display: none;
	z-index: 1000;
}

/* Anzeigen bei Hover, Fokus im <li> oder wenn aria-expanded=true am Toggle */
#nav li:hover > .sub,
#nav li:focus-within > .sub,
#nav li > .submenu-toggle[aria-expanded="true"] + .sub {
	display: block;
}

#nav .sub li { margin: 0; }
#nav .sub li a {
	display: block;
	padding: .55rem .9rem;
	color: #333;
	text-decoration: none;
	white-space: nowrap;
	font-size: .98rem;
}
#nav .sub li a:hover,
#nav .sub li a:focus {
	background: var(--primary);
	color: #fff;
}

/* Kleine Hover-Verbesserung Hauptmenü */
#nav .navigation_dt > li > a:hover,
#nav .navigation_dt > li > a:focus {
	color: var(--primary);
}

/* -------- Overlay / Mobile Navigation -------- */
.overlay {
	height: 100%;
	width: 0;                 /* geschlossen */
	position: fixed;
	z-index: 2000;
	top: 0; left: 0;
	background: rgba(255,255,255,.98);
	overflow-x: hidden;
	transition: width .3s ease;
}
.overlay.open { width: 100%; }

/* Schließen-Button im Overlay */
.overlay .closebtn {
	position: absolute;
	top: 1rem; right: 1rem;
	font-size: 2rem;
	background: none; border: none;
	color: #333;
	cursor: pointer;
}
.overlay .closebtn:focus-visible {
	outline: 2px solid #137c6f;
	outline-offset: 2px;
}

/* Inhalt im Overlay */
.overlay .overlay-content {
	position: relative;
	top: 64px;
	padding-bottom: 3rem;
}
.logo_overlay_wrap {
	text-align: center;
	margin-bottom: 1rem;
}

/* Mobile Liste */
#navigation_mobile {
	list-style: none;
	margin: 0; padding: 0 0 1rem 0;
}
#navigation_mobile > li {
	border-top: 1px solid #e9e9e9;
}

/* Mobile Hauptlinks & Toggle-Buttons */
#navigation_mobile > li a,
#navigation_mobile > li button.collapse {
	display: block;
	width: 100%;
	text-align: left;
	padding: 1rem 1.25rem;
	font-size: 1.1rem;
	color: #222;
	background: none;
	border: none;
	text-decoration: none;
	cursor: pointer;
}
#navigation_mobile > li a:hover,
#navigation_mobile > li a:focus,
#navigation_mobile > li button.collapse:hover,
#navigation_mobile > li button.collapse:focus {
	color: var(--primary);
}
#navigation_mobile > li button.collapse i {
	margin-left: .5rem;
}

/* Mobile Untermenüs */
#navigation_mobile .sub {
	background: #f7f9f9;
	padding: .25rem 0 .75rem;
}
#navigation_mobile .sub li a {
	padding: .5rem 2.25rem;
	font-size: 1rem;
}
#kontakt_mobil{
	margin-left: 20px;
	margin-right: 20px;
	margin-top: 30px;
	display: flex;
	align-items: center;
	background: rgba(60,130,175,0.05);
	padding: 15px;
	border-radius: 25px;
}
#kontakt_mobil i{
	color: var(--primary);
	font-size: 2.5rem;
}
#kontakt_mobil .head{
	color: var(--primary);
	font-weight:700;
}
#kontakt_mobil div:last-child{
	padding-left: 15px;
	margin-left: 15px;
	border-left: 1px solid rgba(0,0,0,0.1);
}

ul#social_mobil{
	display: flex;
	list-style: none;
	margin-left: 20px;
	margin-top: 15px;
}
ul#social_mobil li:first-child{
	margin-right: 10px;
}
ul#social_mobil li a{
	color: var(--primary);
	font-size: 1.5rem;
}

/* -------- Responsive Breakpoint -------- */
@media (max-width: 1350px) {
	#header_info{ display: none; }
}
@media (max-width: 980px) {
	#nav .menu-button { display: inline-flex; }
	#nav .navigation_dt, #header_kontakt { display: none; }
}