/* Theme Name:      KIEFER MOLD Multisite Theme
Theme URI:       https://kiefer-mold.de
Description:     Kiefer Mold Custom Theme
Author:          Marcel Michael Maas
Author URI:      https://mossimedia.de
Version:         1.1.0
Text Domain:     kiefer-multi-theme
*/

/* ==========================================================================
   1. VARIABLEN & FONTS
   ========================================================================== */
:root {
    /* Farben */
    --kiefer-red: #e30613;
    --kiefer-gray: #aab2b7;
    --kiefer-dark: #3a3a3a;
    --kiefer-light: #f2f2f3;
    --transition: all 0.2s ease-in-out;

    /* Typografie-Skala (Modern & Legitim) */
    --font-base: 1rem;          /* 16px - Standard Fließtext & Listen */
    --font-small: 0.875rem;     /* 14px - Breadcrumbs, Copyright, Meta-Infos */
    
    /* Überschriften */
    --font-h1: 2.5rem;          /* 40px - Die Hauptüberschrift (Content) */
    --font-h2: 1.75rem;         /* 28px - Sektionsüberschriften */
    --font-h3: 1.35rem;         /* 21.6px - Unterüberschriften & Footer-Headlines */
    
    /* Navigationen */
    --font-nav-main: 1.1rem;    /* ~17.6px - Hauptmenü oben */
    --font-nav-sub: 1rem;       /* 16px - Dropdowns, Top-Nav & Sidebar */
}

@font-face {
    font-family: 'Ubuntu';
    src: url('assets/fonts/Ubuntu-Regular.ttf') format('truetype');
    font-weight: 400; font-style: normal; font-display: swap;
}

@font-face {
    font-family: 'Ubuntu Condensed';
    src: url('assets/fonts/UbuntuCondensed-Regular.ttf') format('truetype');
    font-weight: 400; font-style: normal; font-display: swap;
}

/* Font Awesome */
@font-face {
    font-family: 'Font Awesome Free';
    src: url('assets/fonts/fa-regular-400.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: block;
}

/* ==========================================================================
   2. RESET & BASICS
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    background: #efefef;
    scroll-behavior: smooth;
}

body {
    font-family: "Ubuntu", sans-serif;
    color: var(--kiefer-dark);
    font-size: var(--font-base);
    line-height: 1.5;
}

h1 { font-size: var(--font-h1); }
h2 { font-size: var(--font-h2); }
h3 { font-size: var(--font-h3); }

h1, h2, h3, h4, h5, h6 {
    font-family: "Ubuntu Condensed", sans-serif;
    text-transform: uppercase;
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul { list-style: none; }

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    font: inherit;
    background: none;
    border: 0;
    cursor: pointer;
}

.container {
    width: min(100% - 2rem, 1320px);
    margin-inline: auto;
}

.sr-only {
    position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0);
}

.flex {
    display: flex;
}

[hidden] { display: none !important; }

/* ==========================================================================
   3. HEADER & COMPLETE NAVIGATION BLOCK
   ========================================================================== */
   
/* --- Header Top Bar --- */
.header-top {
  position: relative;
  z-index: 20;
  color: #fff;
  background: #e30613;
}

.header-top__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 42px;
}

.language-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  text-transform: uppercase;
  font-weight: 700;
  color: #fff;
  font-size: var(--font-sub);
}

/* --- Top Navigation --- */
.top-nav {
  display: none;
}

.top-nav > ul {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.top-nav a,
.top-nav button {
  color: #fff;
  font-size: var(--font-nav-sub);
}

.top-nav li {
  position: relative;
}

.top-nav__dropdown {
  position: absolute;
  top: calc(100% + 0.8rem);
  right: 0;
  min-width: 230px;
  padding: 0.5rem 0;
  background: #e30613;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-0.5rem);
  transition: 0.2s ease;
}

.top-nav li:hover .top-nav__dropdown,
.top-nav li:focus-within .top-nav__dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.top-nav__dropdown a {
  display: block;
  padding: 0.65rem 1rem;
}

.top-nav__dropdown a:hover,
.top-nav__dropdown a[aria-current="page"] {
  background: #96c11f;
}

/* --- Language Menu Overlay --- */
.language-menu {
  position: absolute;
  z-index: 15;
  width: 100%;
  color: #fff;
  background: #e30613;
}

.language-menu__list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  padding: 1rem 0;
}

.language-menu a {
  text-transform: uppercase;
  font-weight: 700;
  font-size: var(--font-nav-sub);
}

/* --- Header Main Section & Logo --- */
.header-main {
  position: relative;
  z-index: 10;
  background: #fff;
}

.header-main__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 88px;
}

.logo img {
  width: 180px;
  height: auto;
}

/* --- Mobile Burger Button (.nav-toggle) --- */
.nav-toggle {
  position: relative;
  width: 44px;
  height: 44px;
}

.nav-toggle__line,
.nav-toggle__line::before,
.nav-toggle__line::after {
  position: absolute;
  left: 7px;
  width: 30px;
  height: 2px;
  background: var(--kiefer-red);
  content: "";
  transition: 0.25s ease;
}

.nav-toggle__line { top: 21px; }
.nav-toggle__line::before { top: -10px; left: 0; }
.nav-toggle__line::after { top: 10px; left: 0; }

.nav-toggle[aria-expanded="true"] .nav-toggle__line {
  background: transparent;
}
.nav-toggle[aria-expanded="true"] .nav-toggle__line::before {
  top: 0;
  transform: rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__line::after {
  top: 0;
  transform: rotate(-45deg);
}

/* --- Allgemeine Dropdown-Pfeile (CSS-Dreiecke) --- */
.dropdown-trigger {
  cursor: pointer;
  background: none;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dropdown-trigger::after {
  content: "";
  display: inline-block;
  width: 0; 
  height: 0; 
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #e30613;
  transition: transform 0.3s ease;
}

.has-dropdown.is-open > .dropdown-trigger::after {
  transform: rotate(180deg) !important;
}

/* ==========================================================================
   NAVIGATION UNTER 1300px (MOBILE LOGIK)
   ========================================================================== */
@media (max-width: 1299px) {
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    display: none;
    width: 100%;
    padding: 1rem;
    background: #3a3a3a;
  }

  .main-nav.is-open {
    display: block;
  }

  .main-nav > ul {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
  }

  .main-nav .has-dropdown {
    position: relative !important;
    display: block !important;
    width: 100% !important;
  }

  .main-nav a {
    display: block !important;
    padding: 15px 60px 15px 15px !important;
    color: #fff !important;
    text-align: left !important;
    width: 100% !important;
    font-size: var(--font-nav-sub);
  }

  .main-nav a:hover {
    color: #e30613 !important;
  }

  .dropdown-trigger {
    position: absolute !important;
    right: 0 !important;
    top: 0 !important;
    width: 60px !important;
    height: 50px !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border-left: 1px solid rgba(255, 255, 255, 0.1) !important;
    z-index: 10 !important;
  }

  .main-nav__dropdown {
    display: none !important;
    width: 100% !important;
    background: #2a2a2a !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .has-dropdown.is-open > .main-nav__dropdown {
    display: block !important;
  }

  .main-nav__dropdown a {
    padding-left: 30px !important;
  }
  
  .main-nav__dropdown .main-nav__dropdown a {
    padding-left: 45px !important;
  }
  
  .mobile-only {
    display: block;
  }
}

/* ==========================================================================
   NAVIGATION AB 1300px (DESKTOP LOGIK)
   ========================================================================== */
@media (min-width: 1300px) {
  .top-nav { display: block; }
  .header-main__inner { min-height: 168px; }
  .logo img { width: 224px; }
  .nav-toggle { display: none; }
  .mobile-only { display: none; }

  .main-nav {
    position: static;
    display: block;
    width: auto;
    padding: 0;
    background: transparent;
  }

  .main-nav > ul {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
  }

  .main-nav a,
  .main-nav button {
    width: auto;
    padding: 0.75rem;
    font-size: var(--font-nav-main);
    color: #000;
  }

  .main-nav a:hover {
    color: #e30613;
  }

  .main-nav .has-dropdown {
    position: relative;
    display: flex;
    align-items: center;
  }

  .main-nav .main-nav__dropdown {
    display: none !important;
    position: absolute;
    background: #fff;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    padding: 10px 0;
  }

  .main-nav > ul > .has-dropdown > .lvl-1 {
    top: 100%;
    left: 0;
    min-width: 250px;
    z-index: 1000;
  }

  .lvl-1 > .has-dropdown > .lvl-2 {
    top: -10px;
    left: 100% !important;
    min-width: 250px;
    z-index: 1001;
  }

  .main-nav > ul > .has-dropdown:hover > .lvl-1 {
    display: block !important;
  }

  .lvl-1 > .has-dropdown:hover > .lvl-2 {
    display: block !important;
  }
  
  .has-dropdown:hover > .dropdown-trigger::after {
    transform: rotate(180deg);
  }

  .main-nav__dropdown a {
    display: block;
    padding: 0.65rem 1rem;
    white-space: nowrap;
    width: 100%;
    font-size: var(--font-nav-sub) !important;
  }

  .main-nav__dropdown a:hover {
    color: #fff !important;
    background: #e30613;
  }

  .dropdown-trigger {
    padding: 0 5px;
    height: 100%;
  }
}

/* --- Search Overlay --- */
.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  background: rgba(0, 0, 0, 0.92);
}

.search-overlay__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  color: #fff;
  font-size: 3rem;
  line-height: 1;
}

.search-form { width: min(100%, 520px); }
.search-form input {
  width: 100%;
  padding: 1rem;
  color: #fff;
  font-size: 1.4rem;
  background: transparent;
  border: 4px solid #e30613;
  outline: none;
}
.search-form input::placeholder { color: rgba(255, 255, 255, 0.75); }

.search-toggle .icon { margin-right: 0.5rem; color: #96c11f; }

@media (min-width: 1300px) {
  .search-toggle { min-width: 46px; justify-content: center; }
  .search-toggle span:last-child { display: none; }
  .search-toggle .icon { margin-right: 0; }
}

/* ==========================================================================
   4. SEITEN-INHALTE & LAYOUTS
   ========================================================================== */
.content-wrapper {
    background: #fff;
}

section.breadcrumbs-section {
    background: #f2f2f3;
    padding: 32px 0;
    color: #aab2b7;
    text-transform: uppercase;
    font-family: "Ubuntu Condensed", sans-serif;
    font-weight: 600;
    font-size: var(--font-small);
}

section.breadcrumbs-section a, section.breadcrumbs-section span {
    color: #aab2b7;
    font-family: "Ubuntu Condensed", sans-serif;
}

section.breadcrumbs-section a:hover {
    color: var(--kiefer-red);
}

section.aktuelles {
    background: #f2f2f3;
    padding: 4em 0;
}

section.aktuelles h2 {
    text-align: center;
    font-size: var(--font-h2);
}

section.aktuelles .flex {
    gap: 4em;
}

section.aktuelles .news-item {
    width: 50%;
}

section.aktuelles .news-item .news-title {
    font-size: var(--font-h3);
}

section.aktuelles .news-item .news-image {
    width: 400px;
}

section.aktuelles .news-item .news-title a, section.aktuelles .news-item .news-title a:hover {
    color: var(--kiefer-dark);
}

section.aktuelles .allnews_link {
    text-align: center;
    color: var(--kiefer-red);
    font-weight: 600;
    padding: 1em 0 0 0;
    font-size: var(--font-base);
}

.row {
    display: flex;
}

.sidebar {
    flex: 0 0 370px;
    border-right: 1px solid #f2f2f3;
    margin-right: 40px;
    padding-top: 20px;
}

.sidebar-subnav li {
    list-style-type: none;
    padding: 5px 0;
}

.sidebar-subnav li a {
    padding: 6px 0 6px 12px;
    color: #000;
    font-weight: bold;
    font-size: var(--font-nav-sub);
}

.sidebar-subnav li a:hover, .sidebar-subnav li.active a {
    color: var(--kiefer-red) !important;
}

.sidebar-subnav li a::before {
    margin-right: 5px;
    color: #aab2b7;
    content: '>';
}

.sidebar-subnav li.lv-2 a {
    padding-left: 20px;
    color: #aab2b7;
    font-weight: bold;
}

.sidebar-subnav li.lv-2 a::before {
    margin-right: 5px;
    color: #aab2b7;
    content: '∟';
}

/* ==========================================================================
   5. MAIN CONTENT STRUKTUR & TABELLEN
   ========================================================================== */
.main-layout {
    flex-grow: 1;
}

.main-layout section {
    margin-bottom: 2em;
}

.main-layout h1 {
    font-size: var(--font-h1);
    margin: 20px 0;
    line-height: 1.2em;
}

.main-layout p {
    margin: 0 0 20px;
    font-size: var(--font-base);
}

.main-layout p a {
    color: #e30613;
}

.main-layout .galerie {
    display: flex;
    gap: 20px;
}

.main-layout li {
    padding: 4px 0 4px 22px;
    position: relative;
    list-style: none outside none;
    font-size: var(--font-base);
}

.main-layout .main-content-area li:before {
    content: "+";
    color: #fff;
    background: #e30613;
    margin-right: 5px;
    position: absolute;
    left: 0;
    top: 8px;
    -webkit-font-smoothing: antialiased;
    font-weight: 600;
    -moz-osx-font-smoothing: grayscale;
    width: 18px;
    text-align: center;
    line-height: 17px;
    border-radius: 5px;
}

.main-layout li p {
    margin: 0;
}

.main-layout table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--font-base);
}

.main-layout table th {
    border-top: 1px solid #dadada;
    padding: 0.5em 0.75em;
    vertical-align: top;
    background: #e30613;
    color: #fff;
    border-right: 1px solid #fff;
    text-align: left;
}

.main-layout table td {
    border-top: 1px solid #dadada;
    padding: 0.5em 0.75em;
    vertical-align: top;
    background: #e6e6e6;
    border-right: 1px solid #fff;
}

.main-layout tr:nth-child(2n) td {
    background: #f2f2f3;
}

.main-layout img.alignleft {
    float: left;
    padding-right: 10px;
}

.main-layout img.alignright {
    float: right;
    padding-left: 10px;
}

a.button, .news-button a {
    background: var(--kiefer-red);
    padding: 10px;
    color: #fff;
    border: 2px solid var(--kiefer-red);
    display: inline-block;
    font-size: var(--font-base);
}

a.button:hover, .news-button a:hover {
    background: transparent;
    padding: 10px;
    color: var(--kiefer-red);
    border: 2px solid var(--kiefer-red);
}

.download-liste li a {
    color: var(--kiefer-red);
}

.download-liste li a:hover {
    color: var(--kiefer-gray);
}

.news-item {
    margin: 2em 0;
}

.news-item .main-grid {
    display: flex;
    flex: 155px 1;
    gap: 1em;
}

.news-item .news-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.news-item .main-grid .news-title {
    font-weight: 600;
    text-transform: uppercase;
    font-size: var(--font-h2);
}

.news-item .main-grid .news-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: var(--font-base);
}

.news-item .news-image {
    max-width: 155px;
    min-width: 155px;
}

/* ==========================================================================
   SIMPLE HERO SLIDER (PERFEKT ZUSAMMENGEFASST)
   ========================================================================== */

/* 1. Slider Basis & Container */
.simple-slider {
	position: relative;
	width: 100%;
	min-height: 550px;
	height: 70vh; /* Nutzt 70% der Bildschirmhöhe */
	overflow: hidden;
	background: #000;
}

.slider-wrapper {
	position: relative;
	width: 100%;
	height: 100%;
}

/* 2. Einzelner Slide & Animation */
.simple-slide {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
	z-index: 1;
}

/* Der aktive Slide wird eingeblendet */
.simple-slide.active {
	opacity: 1;
	visibility: visible;
	z-index: 2;
}

/* 3. Hintergrundbild */
.slide-bg {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

.slide-bg img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* 4. Inhalt & Flexbox-Zentrierung */
.slide-overlay {
	position: relative;
	z-index: 3;
	width: 100%;
	height: 100%; /* Streckt das Overlay auf die volle Höhe des Slides */
	background: linear-gradient(90deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.2) 100%);
	display: flex;
	align-items: center;    /* Vertikale Zentrierung */
	justify-content: center; /* Horizontale Zentrierung */
	color: #fff;
}

.slide-overlay .container {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;    /* Vertikale Zentrierung des Content-Blocks */
	justify-content: center; /* Horizontale Zentrierung des Content-Blocks */
	padding-left: 20px;
	padding-right: 20px;
	box-sizing: border-box;
}

.slide-content {
	max-width: 650px;
	text-align: center; /* Zentriert den Text innerhalb des Blocks */
}

.slide-kicker {
	font-size: 1.25rem;
	text-transform: uppercase;
	margin-bottom: 12px;
	letter-spacing: 1px;
}

.slide-title {
	font-size: 3.5rem;
	color: #fff;
	line-height: 1.2;
	margin-bottom: 20px;
}

/* 5. Pfeil-Navigation (Links / Rechts) */
.slider-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: rgba(0, 0, 0, 0.4);
	color: #fff;
	border: none;
	font-size: 2rem;
	padding: 15px 20px;
	cursor: pointer;
	z-index: 10;
	transition: background 0.3s;
}

.slider-arrow:hover {
	background: rgba(0, 0, 0, 0.8);
}

.prev-arrow { left: 20px; }
.next-arrow { right: 20px; }

/* 6. Punkte-Navigation (Dots) */
.slider-dots {
	position: absolute;
	bottom: 20px;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	gap: 10px;
	z-index: 10;
}

.dot {
	width: 12px;
	height: 12px;
	background-color: rgba(255, 255, 255, 0.4);
	border: 2px solid transparent;
	border-radius: 50%;
	cursor: pointer;
	transition: background-color 0.3s, transform 0.3s;
	padding: 0;
}

.dot:hover {
	background-color: rgba(255, 255, 255, 0.8);
	transform: scale(1.2);
}

.dot.active {
	background-color: #ffffff;
	transform: scale(1.1);
}

/* ==========================================================================
   7. RESPONSIVE MEDIA QUERIES (RESPONSIVE ENGINE)
   ========================================================================== */

/* Tablets & Smartphones (max-width: 768px) */
@media (max-width: 768px) {
	.simple-slider {
		min-height: 450px;
		height: 60vh; /* Etwas flacher auf Mobilgeräten für besseren Scrollflow */
	}

	.slide-title {
		font-size: 2rem; /* Verhindert das seitliche Ausbrechen der H1 */
		line-height: 1.3;
		margin-bottom: 15px;
		word-wrap: break-word; /* Erzwingt Umbruch bei extrem langen Wörtern */
	}

	.slide-kicker {
		font-size: 1rem;
		margin-bottom: 8px;
	}

	/* Pfeile mobil kompakter und näher an den Rand setzen */
	.slider-arrow {
		padding: 10px 12px;
		font-size: 1.2rem;
		background: rgba(0, 0, 0, 0.6);
	}

	.prev-arrow { left: 5px; }
	.next-arrow { right: 5px; }
	
	.slider-dots {
		bottom: 15px;
	}
}

/* Ganz kleine Smartphones (max-width: 480px) */
@media (max-width: 480px) {
	.simple-slider {
		min-height: 400px;
		height: 55vh;
	}

	.slide-title {
		font-size: 1.65rem; /* Perfekte Skalierung für schmale Displays */
	}
}


.small-slider {
    background-color: var(--kiefer-red);
    position: relative;
}

.small-slider .slide {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1em;
}

.small-slider .slide img {
    width: 100%;
}



/* ==========================================================================
   7. SITE FOOTER BLOCK
   ========================================================================== */
.site-footer {
    background-color: #3a3a3a;
    padding: 60px 0;
    color: #fff;
    width: 100%;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
}

.footer-col {
    flex: 1;
    min-width: 250px;
    margin-bottom: 30px;
}

.footer-col--brand {
    flex: 0 0 150px;
}

.footer-headline {
    font-size: var(--font-h3);
    margin-bottom: 25px;
    letter-spacing: 1px;
}

.footer-content p, .footer-nav {
    line-height: 1.8;
    font-size: var(--font-base);
}

.copyright {
    line-height: 1.8;
    font-size: var(--font-small);
}

.footer-nav {
    list-style: none;
    padding: 0;
}

.footer-nav a, .contact-link {
    color: #fff;
    text-decoration: none;
    display: block;
    margin-bottom: 5px;
}

.social-wrapper {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}

.social-box {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: 0.3s;
}

.social-box:hover {
    background: #e30613;
}

.contact-link i {
    color: #e30613;
    margin-right: 10px;
    width: 16px;
}

.legal-links ul {
    display: flex;
    gap: 12px;
}

@media (max-width: 991px) {
    .footer-container {
        flex-direction: column;
    }
    .footer-col {
        width: 100%;
        min-width: 100%;
    }
}

/* ==========================================================================
   8. FORMULARE
   ========================================================================== */
.km_form, .km_form form, .km_form .wpcf7 {
    max-width: 870px;
	width: 100%;
}

.km_form {
    margin: 1em 0;
}

.km_form input, .km_form textarea {
    display: block;
    width: 100%;
    padding: .375rem .75rem;
    font-size: var(--font-base);
    font-weight: 400;
    line-height: 1.5;
    color: #212529;
    background-color: #fff;
    border: .0625rem solid #ced4da;
    border-radius: 0;
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
    background-clip: unset;
    border-width: .125rem;
    outline: 0;
    box-shadow: none;
    resize: none;
}

.km_form input:focus, .km_form textarea:focus {
    border-color: var(--kiefer-red);
    outline: 0;
    box-shadow: none;
}

.km_form .wpcf7-submit {
    background: var(--kiefer-red);
    padding: 10px;
    color: #fff;
    border: 2px solid var(--kiefer-red);
    display: inline-block;
    font-size: var(--font-base);
    transition: var(--transition);
    width: auto;
    margin: 0 auto;
    display: block;
    font-family: 'Ubuntu';
}

.km_form .wpcf7-submit:hover {
    background: transparent;
    padding: 10px;
    color: var(--kiefer-red);
    border: 2px solid var(--kiefer-red);
}

/* Sternchen automatisch an Pflichtfelder anhängen (Fix für Label-Verschachtelung) */
.wpcf7-form-control-wrap.wpcf7-validates-as-required {
    display: inline-block;
    position: relative;
}

.wpcf7-form-control-wrap.wpcf7-validates-as-required::before {
    content: "*";
    color: var(--kiefer-red); /* Dein Kiefer-Rot */
    font-weight: bold;
    position: absolute;
    top: -1.5rem; /* Schiebt das Sternchen hoch auf die Höhe des Label-Textes */
    right: 0;
}




/* Zusätzlicher Content */
.content-image, .content-video{
	    max-width: 870px;
width: 100%;
}


/* Layout-Raster */
.main-layout {
	display: flex;
	flex-wrap: wrap;
	gap: 40px;
	padding: 4em 0;
	
}

/* Wenn Sidebar aktiv: Aufteilung 25% zu ~70% */
.main-layout--has-sidebar .sidebar {
	flex: 1 1 250px;
	max-width: 300px;
}

.main-layout--has-sidebar .main-layout-area {
	flex: 3 1 600px;
}

/* Wenn keine Sidebar aktiv: Volle Breite */
.main-layout--full-width .main-layout-area {
	flex: 1 1 100%;
}

/* Einfache Sidebar-Menü Optik */
.sidebar-menu {
	list-style: none;
	padding: 0;
	margin: 0;
	padding-right:40px;
}

.sidebar-menu__item {
	margin-bottom: 8px;
}

.sidebar-menu__link {
	display: block;
	padding: 6px 15px;
	color: #333;
	text-decoration: none;
}

.sidebar-menu__item.is-active > .sidebar-menu__link {
	color: #ff0000; /* Deine Theme-Farbe */
	font-weight: bold;
}

/* Einrückung für Unterseiten */
.sidebar-menu__item.lv-1 { padding-left: 15px; }
.sidebar-menu__item.lv-2 { padding-left: 30px; }

@media (max-width: 768px) {
	.main-layout {
		flex-direction: column-reverse; /* Mobil wandert die Sidebar über oder unter den Content */
	}
	.main-layout--has-sidebar .main-layout-area {
    flex: auto;
}
	.main-layout--has-sidebar .sidebar {
		max-width: 100%;
	}
}


/* ==========================================================================
   FLEXIBLE BOXEN / TEASER GRID
   ========================================================================== */

/* Das umschließende Grid */
.teaser-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 30px;
	margin: 30px 0;
	width: 100%;
}

/* Die einzelne Box */
.teaser-box {
	flex: 1 1 calc(33.333% - 20px); /* 3 Spalten auf Desktop */
	min-width: 280px;
	background-color: #f4f4f4; /* Das helle Grau aus dem Screenshot */
	display: flex;
	flex-direction: column; /* Richtet Inhalt von oben nach unten aus */
	overflow: hidden;
}

/* Bildbereich oben */
.teaser-box__image {
	width: 100%;
	height: 200px; /* Feste Höhe für die Bilder-Zeile */
	background-color: #ddd; /* Fallback, falls kein Bild da ist */
}

.teaser-box__image img {
	width: 100%;
	height: 100%;
	object-fit: cover; /* Schneidet das Bild sauber passend zu */
}

/* Platzhalter, falls im Backend mal kein Bild gepflegt ist */
.teaser-box__image--placeholder {
	background: #e0e0e0;
	height: 150px; 
}

/* Text-Inhalt der Box */
.teaser-box__content {
	padding: 25px 20px;
	text-align: center; /* Alles zentrieren wie im Screenshot */
	display: flex;
	flex-direction: column;
	flex-grow: 1; /* Sorgt dafür, dass dieser Bereich den Rest der Box füllt */
}

/* Große Hauptüberschrift */
.teaser-box__title {
	font-size: 1.6rem;
	font-weight: bold;
	text-transform: uppercase; /* Komplett in Großbuchstaben */
	color: #000;
	margin: 0 0 5px 0;
}

/* Kleine Unterüberschrift */
.teaser-box__subtitle {
	font-size: 0.95rem;
	text-transform: uppercase;
	color: #777; /* Grauer Text */
	font-weight: 600;
	margin: 0 0 20px 0;
	letter-spacing: 0.5px;
}

/* Beschreibungstext */
.teaser-box__text {
	font-size: 1rem;
	color: #333;
	line-height: 1.5;
	margin: 0 0 25px 0;
}

/* Button-Wrapper, der den Button nach ganz unten drückt */
.teaser-box__button-wrapper {
	margin-top: auto; /* Magischer Flexbox-Trick: Drückt den Button an den Boden */
}

/* --- Responsive Anpassungen --- */
@media (max-width: 992px) {
	.teaser-box {
		flex: 1 1 calc(50% - 15px); /* 2 Spalten auf Tablets */
	}
}

@media (max-width: 600px) {
	.teaser-grid {
		gap: 20px;
	}
	.teaser-box {
		flex: 1 1 100%; /* 1 Spalte auf Handys */
	}
}

/* ==========================================================================
   SMALL SLIDER (ROTEN BOX LOOK)
   ========================================================================== */

.small-slider-container {
	position: relative;
	width: 100%;
	
	    max-width: 870px;
	margin: 40px 0;
	overflow: hidden;
}

.small-slider-wrapper {
	position: relative;
	width: 100%;
	/* Wir geben dem Container eine Mindesthöhe (Bild-Höhe + geschätzte rote Box-Höhe) */
	min-height: 500px; 
}

/* Einzelner Slide (Übereinandergelegt) */
.small-slide {
	position: absolute;
	top: 0;
	left: 0;
width: 100%;
	height: 100%;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.6s ease-in-out, visibility 0.6s ease-in-out;
	display: flex;
	flex-direction: column;
	z-index: 1;
}

.small-slide.active {
	opacity: 1;
	visibility: visible;
	position: relative; /* Der aktive Slide bestimmt die reale Höhe */
	z-index: 2;
}

/* Bildbereich oben */
.small-slide__image {
	width: 100%;
	height: 300px; /* Höhe des Werkzeug-Bildes */
}

.small-slide__image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* Die markante rote Box darunter */
.small-slide__red-box {
	background-color: #d90414; /* Dein Kiefer-Rot */
	color: #ffffff;
	padding: 40px 20px 60px 20px; /* Unten mehr Platz für die Pfeile */
	text-align: center;
	display: flex;
	justify-content: center;
	align-items: center;
	flex-grow: 1;
}

.small-slide__content {
	max-width: 800px;
	width: 100%;
}

.small-slide__title {
	font-size: 1.8rem;
	font-weight: bold;
	text-transform: uppercase;
	color: #000000; /* Schwarze Schrift auf rotem Grund laut Screenshot */
	margin: 0 0 15px 0;
	letter-spacing: 0.5px;
}

.small-slide__text {
	font-size: 1.05rem;
	color: #000000; /* Schwarze Schrift auf rotem Grund */
	line-height: 1.6;
	margin: 0;
}

/* Pfeil-Navigation absolut am unteren Ende der roten Box zentrieren */
.small-slider-nav {
	position: absolute;
	bottom: 15px;
	left: 50%;
	transform: translateX(-50%);
	display: flex;
	gap: 20px;
	z-index: 10;
}

.small-slider-arrow {
	background: none;
	border: none;
	color: #ffffff; /* Weiße Pfeile */
	font-size: 1.8rem;
	font-weight: bold;
	cursor: pointer;
	padding: 5px 10px;
	transition: transform 0.2s ease, opacity 0.2s;
}

.small-slider-arrow:hover {
	transform: scale(1.2);
	opacity: 0.8;
}

/* Responsive Anpassung */
@media (max-width: 768px) {
	.small-slide__image {
		height: 200px; /* Mobil etwas flacheres Bild */
	}
	.small-slide__title {
		font-size: 1.4rem;
	}
	.small-slide__text {
		font-size: 0.95rem;
	}
}
/* ==========================================================================
   CUSTOM LOOP (ZEILEN / ROW LAYOUT)
   ========================================================================== */

.custom-loop-container {
	width: 100%;
	margin: 30px 0;
	display: flex;
	flex-direction: column;
	gap: 35px; /* Abstand zwischen den einzelnen Zeilen */
}

/* Die einzelne Zeile */
.custom-loop-item {
	display: flex;
	gap: 25px; /* Abstand zwischen Bild und Text */
	align-items: flex-start; /* Verhindert, dass das Bild gestreckt wird */
	width: 100%;
}

/* Bild-Container links */
.custom-loop-item__image {
	flex: 0 0 180px; /* Fixe Breite für das Bild, wie im Screenshot */
	height: 120px;   /* Feste Höhe */
	overflow: hidden;
	border: 1px solid #ddd; /* Optionaler feiner Rahmen ums Werkzeug-Bild */
}

.custom-loop-item__image img {
	width: 100%;
	height: 100%;
	object-fit: cover; /* Schneidet das Bild perfekt in die Box ein */
}

/* Inhalts-Container rechts */
.custom-loop-item__content {
	flex: 1; /* Nutzt den gesamten restlichen Platz */
}

/* Die Überschrift (Serifenlos, Fett, komplett in Großbuchstaben) */
.custom-loop-item__title {
	font-size: 1.25rem;
	font-weight: bold;
	text-transform: uppercase;
	color: #000000;
	margin: 0 0 12px 0;
	letter-spacing: 0.5px;
}

/* Der Fließtext */
.custom-loop-item__text {
	font-size: 1rem;
	color: #333333;
	line-height: 1.5;
}

/* Der rote "...mehr" Link */
.custom-loop-item__more-link {
	color: #d90414; /* Das Kiefer-Rot */
	text-decoration: none;
	font-weight: bold;
	white-space: nowrap; /* Verhindert, dass "...mehr" mitten im Wort umbricht */
	transition: color 0.2s ease;
}

.custom-loop-item__more-link:hover {
	color: #000000;
	text-decoration: underline;
}

/* --- Responsive Anpassung für mobile Endgeräte --- */
@media (max-width: 600px) {
	.custom-loop-item {
		flex-direction: column; /* Bild wandert mobil über den Text */
		gap: 15px;
	}

	.custom-loop-item__image {
		flex: 0 0 auto;
		width: 100%;    /* Bild nutzt mobile volle Breite */
		height: 180px;  /* Etwas mehr Höhe im mobilen Viewport */
	}
}

/* ==========================================================================
   PORTFOLIO ITEM / BRAND CARD
   ========================================================================== */

.brand-cards-container {
	width: 100%;
	margin: 40px 0;
	/* Der obere Trennstrich laut Screenshot */
	border-top: 1px solid #cccccc;
}

/* Der untere Trennstrich (wird nach dem letzten Element platziert) */
.brand-card-divider-bottom {
	border-bottom: 1px solid #cccccc;
	width: 100%;
	margin-top: 20px;
}

/* Das Flex-Layout für die Reihe */
.brand-card {
	display: flex;
	align-items: center; /* Vertikale Zentrierung von Logo und Text */
	gap: 50px;
	padding: 30px 10px;
	width: 100%;
}

/* Linke Spalte: Logo */
.brand-card__logo-col {
	flex: 0 0 250px; /* Feste Basis-Breite fürs Logo */
	display: flex;
	justify-content: center;
	align-items: center;
}

.brand-card__logo-col img {
	max-width: 100%;
	height: auto;
	object-fit: contain;
}

/* Rechte Spalte: Inhalt */
.brand-card__content-col {
	flex: 1;
	display: flex;
	flex-direction: column;
}

/* Überschrift */
.brand-card__title {
	font-size: 1.75rem;
	font-weight: bold;
	color: #0b2d48; /* Dunkelblau aus deinem Screenshot */
	margin: 0 0 8px 0;
}

/* Subline */
.brand-card__subline {
	font-size: 1.05rem;
	color: #4a5568;
	margin: 0 0 20px 0;
}

/* Zeile für den Button */
.brand-card__button-row {
	margin-bottom: 20px;
}

/* Der ovale dunkelrote Button */
.button--brand-oval {
	display: inline-block;
	background-color: #b0030f; /* Dunkleres Rot aus der Vorlage */
	color: #ffffff !important;
	text-decoration: none;
	padding: 8px 25px;
	font-size: 1rem;
	border-radius: 20px; /* Macht den Button komplett oval */
	transition: background-color 0.2s ease;
}

.button--brand-oval:hover {
	background-color: #d90414;
}

/* Social Media Icons */
.brand-card__socials {
	display: flex;
	gap: 12px;
}

.brand-card__socials a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	background-color: #1a202c; /* Dunkle Kreise */
	color: #ffffff !important;
	border-radius: 50%; /* Macht es kreisrund */
	font-size: 0.9rem;
	text-decoration: none;
	transition: background-color 0.2s, transform 0.2s;
}

.brand-card__socials a:hover {
	background-color: #b0030f; /* Hovert im Kiefer-Rot */
	transform: scale(1.1);
}

/* --- Responsive Anpassung --- */
@media (max-width: 768px) {
	.brand-card {
		flex-direction: column; /* Stapelt Logo und Content mobil untereinander */
		gap: 25px;
		text-align: center;
	}
	
	.brand-card__logo-col {
		flex: 0 0 auto;
		max-width: 200px;
		margin: 0 auto;
	}
	
	.brand-card__button-row {
		display: flex;
		justify-content: center;
	}
	
	.brand-card__socials {
		justify-content: center;
	}
}

/* ==========================================================================
   MILESTONES COUNTER GRID
   ========================================================================== */

.milestones-grid {
	display: flex;
	flex-wrap: wrap;
	justify-content: center; /* Zentriert die Boxen, falls eine Zeile nicht voll wird */
	gap: 40px 30px; /* 40px Abstand nach unten, 30px zwischen den Boxen */
	margin: 50px 0;
	width: 100%;
}

.milestone-card {
	/* Standardmäßig berechnet auf bis zu 3 oder 4 Spalten */
	flex: 1 1 calc(25% - 25px); 
	min-width: 220px;
	max-width: 320px;
	text-align: center; /* Alles zentrieren wie im Screenshot */
	display: flex;
	flex-direction: column;
	align-items: center;
}

/* Die grauen Icons oben */
.milestone-card__icon {
	font-size: 2.8rem;
	color: #888888; /* Elegantes Grau aus dem Screenshot */
	margin-bottom: 15px;
	display: flex;
	justify-content: center;
	align-items: center;
	height: 60px;
}

/* Die dicke rote Zahl */
.milestone-card__number {
	font-size: 2.5rem;
	font-weight: 800;
	color: #d90414; /* Dein markantes Kiefer-Rot */
	line-height: 1;
	margin-bottom: 12px;
	font-variant-numeric: tabular-nums; /* Verhindert, dass die Box beim Zählen wackelt */
}

/* Der Beschreibungstext unten */
.milestone-card__text {
	font-size: 1.1rem;
	font-weight: bold;
	color: #000000;
	line-height: 1.4;
	margin: 0;
}

/* --- Responsive Anpassungen --- */
@media (max-width: 992px) {
	.milestone-card {
		flex: 1 1 calc(50% - 20px); /* 2 Spalten auf Tablets */
	}
}

@media (max-width: 480px) {
	.milestones-grid {
		gap: 30px 10px;
	}
	.milestone-card {
		flex: 1 1 100%; /* Volle Breite auf kleinen Handys */
	}
	.milestone-card__number {
		font-size: 2.2rem;
	}
}

/* ==========================================================================
   BUTTON GRUPPE
   ========================================================================== */

.button-group-container {
	display: flex;
	flex-wrap: wrap; /* Lässt Buttons umbrechen, wenn der Platz nicht reicht */
	gap: 15px;       /* Abstand zwischen den einzelnen Buttons */
	margin: 25px 0;
	width: 100%;
}

/* Falls die Button-Gruppe mobil untereinander gestapelt werden soll */
@media (max-width: 480px) {
	.button-group-container {
		flex-direction: column;
		align-items: stretch; /* Macht alle Buttons gleich breit (volle Breite) */
	}
	
	.button-group-container .button {
		text-align: center;
	}
}



.main-content-area {
    flex-grow: 1;
}