/* ==========================================================================
   batec – Gestaltung
   Aufbau dieser Datei:
   1. Farben und Grundlagen
   2. Kopf: Leiste, Würfel-Menü, Menüs, Button
   3. Abschnitte und Farbflächen
   4. Bausteine im Inhalt (Raster, Karten, Schritte, Fragen ...)
   5. Fuß
   6. Kleine Bildschirme
   Die Klassen mit "b-" werden im WordPress-Editor an Blöcken vergeben
   (Block auswählen → Erweitert → Zusätzliche CSS-Klasse).
   ========================================================================== */

/* ---------- 1. Farben und Grundlagen ---------- */

:root {
	--tinte: #0B2226;      /* Schrift */
	--grau: #4A5C60;       /* Fließtext zweite Ebene */
	--linie: #DDE3E4;      /* feine Trennlinien */
	--hell: #F5F7F7;       /* heller Abschnitt */
	--nacht: #06272C;      /* dunkler Abschnitt und Fuß */
	--farbe: #00545E;      /* Blockfarbe der Gesellschaft (wird je Seite gesetzt) */
	--auf-farbe: #ffffff;  /* Schrift auf der Blockfarbe */
	--akzent: #00545E;     /* kleine Schrift und Linien in Firmenfarbe */
	--ton: #ffffff;        /* Hintergrund des Seiteneinstiegs */
}
.gesellschaft-service { --ton: #FBF3EC; }
.gesellschaft-connect { --hell: #F7F3F5; --nacht: #2A1420; --tinte: #2A1420; --linie: #E2D6DB; }

body { margin: 0; font-family: Geograph, 'Helvetica Neue', Arial, sans-serif; font-size: 17px; line-height: 1.6; color: var(--tinte); background: #fff; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; font-weight: 700; text-wrap: balance; }
h1 { font-size: clamp(38px, 4.4vw, 64px); line-height: 1.04; letter-spacing: -0.025em; }
h2 { font-size: clamp(30px, 3.2vw, 44px); line-height: 1.04; letter-spacing: -0.025em; }
h3 { font-size: 21px; line-height: 1.2; letter-spacing: -0.01em; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--akzent); outline-offset: 3px; }

.breite { max-width: 1160px; margin: 0 auto; padding-left: 40px; padding-right: 40px; }
.sprunglink { position: absolute; left: -9999px; }
.sprunglink:focus { left: 16px; top: 16px; background: #fff; padding: 12px 16px; z-index: 100; }

/* ---------- 2. Kopf ---------- */

.leiste { background: var(--nacht); color: #C9DADC; font-size: 14px; }
.leiste-innen { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; }

.kopf { background: #fff; border-bottom: 1px solid var(--linie); }
.kopf-innen { min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo img { display: block; height: 46px; width: auto; }

.hauptmenue, .untermenue { display: flex; align-items: center; gap: clamp(20px, 2.6vw, 40px); font-size: 16px; white-space: nowrap; }
.untermenue a.aktiv { color: var(--akzent); font-weight: 700; }

/* Aufklappliste "Alle Unternehmen" im Hauptmenü */
.alle-unternehmen { position: relative; }
.alle-unternehmen summary { cursor: pointer; list-style: none; }
.alle-unternehmen summary::-webkit-details-marker { display: none; }
.alle-unternehmen .einzeiler-liste { position: absolute; left: -24px; top: 44px; z-index: 20; background: #fff; border: 1px solid var(--linie); padding: 24px; box-shadow: 0 12px 30px rgba(11, 34, 38, 0.12); }

.knopf, .wp-block-button__link { display: inline-block; background: var(--farbe); color: var(--auf-farbe); font-weight: 700; font-size: 16px; line-height: 1.2; padding: 15px 26px; border-radius: 999px; white-space: nowrap; }
.is-style-outline .wp-block-button__link { background: transparent; color: var(--tinte); border: 1px solid var(--tinte); padding: 14px 25px; }

/* Würfel-Menü: im Ruhezustand ist nur der eigene Würfel zu sehen.
   Beim Überfahren (oder per Tab-Taste) fahren alle acht Fläche an Fläche heraus. */
.wuerfelmenue { position: relative; width: 64px; height: 64px; flex: none; z-index: 5; }
.wuerfelmenue .wm { position: absolute; left: 0; top: 0; opacity: 0; pointer-events: none; transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.25s ease; }
.wuerfelmenue .wm img { display: block; width: 64px; height: 64px; }
.wuerfelmenue .wm.aktiv { opacity: 1; pointer-events: auto; }
.wuerfelmenue:hover .wm, .wuerfelmenue:focus-within .wm { opacity: 1; pointer-events: auto; }
.wuerfelmenue:hover .wm:nth-child(2), .wuerfelmenue:focus-within .wm:nth-child(2) { transform: translateX(52px); }
.wuerfelmenue:hover .wm:nth-child(3), .wuerfelmenue:focus-within .wm:nth-child(3) { transform: translateX(104px); }
.wuerfelmenue:hover .wm:nth-child(4), .wuerfelmenue:focus-within .wm:nth-child(4) { transform: translateX(156px); }
.wuerfelmenue:hover .wm:nth-child(5), .wuerfelmenue:focus-within .wm:nth-child(5) { transform: translateX(208px); }
.wuerfelmenue:hover .wm:nth-child(6), .wuerfelmenue:focus-within .wm:nth-child(6) { transform: translateX(260px); }
.wuerfelmenue:hover .wm:nth-child(7), .wuerfelmenue:focus-within .wm:nth-child(7) { transform: translateX(312px); }
.wuerfelmenue:hover .wm:nth-child(8), .wuerfelmenue:focus-within .wm:nth-child(8) { transform: translateX(364px); }
.wuerfelmenue .wm:nth-child(1) { z-index: 1; } .wuerfelmenue .wm:nth-child(2) { z-index: 2; } .wuerfelmenue .wm:nth-child(3) { z-index: 3; } .wuerfelmenue .wm:nth-child(4) { z-index: 4; }
.wuerfelmenue .wm:nth-child(5) { z-index: 5; } .wuerfelmenue .wm:nth-child(6) { z-index: 6; } .wuerfelmenue .wm:nth-child(7) { z-index: 7; } .wuerfelmenue .wm:nth-child(8) { z-index: 8; }
.wuerfelmenue:hover::before { content: ""; position: absolute; left: -8px; top: -14px; width: 700px; height: 92px; }
.wuerfelmenue:hover ~ .untermenue, .wuerfelmenue:focus-within ~ .untermenue { opacity: 0; pointer-events: none; }
.untermenue { transition: opacity 0.2s ease; }
.wm-name { position: fixed; opacity: 0; pointer-events: none; font-size: 20px; letter-spacing: -0.01em; color: #17454E; white-space: nowrap; }
.wuerfelmenue .wm-name { position: absolute; top: 18px; left: 0; }
.wuerfelmenue:hover .wm:hover .wm-name, .wuerfelmenue .wm:focus-visible .wm-name { opacity: 1; }
.wuerfelmenue .wm:nth-child(1) .wm-name { left: 448px; } .wuerfelmenue .wm:nth-child(2) .wm-name { left: 396px; } .wuerfelmenue .wm:nth-child(3) .wm-name { left: 344px; } .wuerfelmenue .wm:nth-child(4) .wm-name { left: 292px; }
.wuerfelmenue .wm:nth-child(5) .wm-name { left: 240px; } .wuerfelmenue .wm:nth-child(6) .wm-name { left: 188px; } .wuerfelmenue .wm:nth-child(7) .wm-name { left: 136px; } .wuerfelmenue .wm:nth-child(8) .wm-name { left: 84px; }
@media (prefers-reduced-motion: reduce) { .wuerfelmenue .wm { transition: none; } }

/* ---------- 3. Abschnitte und Farbflächen ---------- */

.b-sec { padding: 104px 0; }
.b-sec > .breite > * + * { margin-top: 28px; }
.b-hell { background: var(--hell); }
.b-ton { background: var(--ton); }
.b-nacht { background: var(--nacht); color: #fff; }
.b-nacht p { color: #C9DADC; }
.b-farbe { background: var(--farbe); color: var(--auf-farbe); }
.b-knapp { padding: 72px 0; }
.b-einstieg { padding: 72px 0 88px; }

.b-eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: var(--akzent); }
.b-nacht .b-eyebrow, .b-farbe .b-eyebrow { color: inherit; }
.b-lead { font-size: 20px; line-height: 1.6; color: var(--grau); max-width: 620px; }
.b-pfad { font-size: 14px; color: var(--grau); }
.b-pfad a { border-bottom: 1px solid #9AA6A9; }
.b-mittig { text-align: center; }
.b-mittig .b-lead, .b-mittig h1 { margin-left: auto; margin-right: auto; }
.b-mittig .wp-block-buttons { justify-content: center; }

.wp-block-buttons { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }
.b-link a, a.b-link { font-weight: 700; border-bottom: 1px solid var(--akzent); padding-bottom: 4px; }

ul.b-haken { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
ul.b-haken li::before { content: "✓ "; }

/* ---------- 4. Bausteine im Inhalt ---------- */

/* Zwei Spalten nebeneinander */
.b-zwei { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 56px; align-items: start; }
.b-zwei.b-unten { align-items: end; }
.b-zwei.b-mitte { align-items: center; }
.b-zwei > * > * + * { margin-top: 22px; }

/* Raster mit 2, 3 oder 4 Spalten */
.b-raster { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 36px 32px; align-items: stretch; }
.b-raster.b-eng { gap: 20px; }
.b-raster-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Punkt mit farbiger Linie oben */
.b-punkt { border-top: 2px solid var(--akzent); padding-top: 22px; }
.b-punkt > * + * { margin-top: 10px; }
.b-punkt p, .b-karte p { font-size: 16px; color: var(--grau); }

/* Weiße Karte */
.b-karte { background: #fff; border: 1px solid var(--linie); border-radius: 6px; padding: 30px; color: var(--tinte); display: flex; flex-direction: column; gap: 12px; }
.b-karte .b-wuerfel img { width: 88px; height: 88px; }
.b-karte .b-link { margin-top: auto; padding-top: 10px; }

/* Schritte 01 02 03 */
.b-schritte { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 40px; }
.b-schritt > * + * { margin-top: 8px; }
.b-zahl { font-size: 44px; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; color: inherit !important; }
.b-zahl::before { content: ""; display: block; width: 44px; height: 4px; background: var(--farbe); margin-bottom: 10px; }
.b-farbe .b-zahl::before { background: currentColor; }

/* Kennzahlen in einer Reihe */
.b-fakten { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; border-top: 1px solid var(--linie); padding-top: 28px; }
.b-fakten .b-wert { font-size: 36px; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; color: inherit; }
.b-fakten p { font-size: 14px; color: var(--grau); }
.b-farbe .b-fakten { border-top: 0; padding-top: 0; }
.b-farbe .b-fakten p { color: inherit; font-size: 19px; font-weight: 700; }

/* Würfel-Kacheln der Startseite */
.b-wuerfel-raster { display: grid; grid-template-columns: repeat(4, 1fr); column-gap: 40px; }
.b-wuerfel-kachel { border-top: 1px solid #C9D3D5; padding: 36px 0 30px; display: flex; flex-direction: column; gap: 10px; }
.b-wuerfel-kachel .b-wuerfel img { width: 148px; height: 148px; }
.b-wuerfel-kachel h3 { font-size: 22px; margin-top: 14px; }
.b-wuerfel-kachel p { font-size: 15px; color: var(--grau); }
.b-wuerfel-kachel .b-link { margin-top: auto; padding-top: 14px; font-size: 14px; color: var(--akzent); }
.b-wuerfel-kachel .b-link a, .b-karte .b-link a { border-bottom: 0; }
.b-wuerfel { margin: 0; }
.b-wuerfel img { display: block; }

/* Fotos und Zeichnungen */
.b-foto { margin: 0; }
.b-foto img { display: block; width: 100%; height: 520px; object-fit: cover; filter: grayscale(1) contrast(1.08); }
.b-foto.b-farbig img { filter: none; border-radius: 6px; }
.b-foto.b-niedrig img { height: 380px; }
.b-zeichnung { margin: 0; }
.b-zeichnung img { display: block; width: 100%; height: auto; }
.b-einstieg .b-zeichnung { margin-bottom: -40px; }

/* Referenz */
.b-ref > * + * { margin-top: 14px; }
.b-ref .b-eyebrow { color: var(--grau); }
.b-ref h3 { font-size: 22px; }

/* Häufige Fragen (Block "Details") */
.wp-block-details { border-top: 1px solid #C9D3D5; padding: 22px 0; margin: 0 !important; }
.wp-block-details:last-of-type { border-bottom: 1px solid #C9D3D5; }
.wp-block-details summary { font-size: 20px; font-weight: 700; cursor: pointer; }
.wp-block-details p { margin-top: 10px; font-size: 16px; color: var(--grau); max-width: 760px; }

/* Listenzeilen mit Pfeil */
ul.b-zeilen { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid #C9D3D5; }
ul.b-zeilen li { border-top: 1px solid #C9D3D5; font-size: 19px; font-weight: 700; }
ul.b-zeilen li a { display: flex; justify-content: space-between; align-items: center; min-height: 60px; }
ul.b-zeilen li a::after { content: "→"; color: var(--akzent); }

/* Pakete (connect) */
.b-paket { background: #fff; border: 1px solid var(--linie); border-radius: 6px; padding: 36px 32px; display: flex; flex-direction: column; gap: 16px; }
.b-paket.b-hervor { border: 2px solid var(--farbe); }
.b-paket .b-preis { font-size: 36px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.b-paket .wp-block-buttons { margin-top: auto; }

/* Kontaktzeile */
.b-kontakt { border-top: 1px solid currentColor; padding-top: 24px; }
.b-kontakt .b-name { font-size: 24px; font-weight: 700; color: inherit; }

/* Eingebettetes Herstellerformular */
.b-einbettung { border: 1px solid #9AA6A9; border-radius: 6px; overflow: hidden; background: #fff; }
.b-einbettung iframe { display: block; width: 100%; min-height: 620px; border: 0; }

/* ---------- 5. Fuß ---------- */

.unternehmen { background: #fff; border-top: 1px solid var(--linie); }
.unternehmen-innen { padding-top: 72px; padding-bottom: 72px; display: flex; justify-content: space-between; align-items: flex-start; gap: 48px; flex-wrap: wrap; }
.unternehmen-titel { font-size: 32px; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; max-width: 340px; margin-top: 14px; }
.unternehmen-spalten { display: flex; gap: 40px 96px; flex-wrap: wrap; }
.einzeiler-liste { display: flex; flex-direction: column; gap: 18px; }
.einzeiler { display: flex; align-items: center; gap: 16px; font-size: 26px; line-height: 1; letter-spacing: -0.01em; color: #17454E; white-space: nowrap; }
.einzeiler .quadrat { width: 30px; height: 30px; flex: none; display: block; }
.hauptmenue .einzeiler { font-size: 20px; }
.hauptmenue .einzeiler .quadrat { width: 22px; height: 22px; }

.fuss { background: var(--nacht); color: #C9DADC; padding: 64px 0 44px; font-size: 15px; line-height: 1.8; }
.fuss-oben { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.fuss-oben img { display: block; height: 40px; width: auto; }
.fuss-unten { border-top: 1px solid rgba(255, 255, 255, 0.14); margin-top: 48px; padding-top: 22px; display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; font-size: 13px; letter-spacing: 0.04em; }

/* ---------- 6. Kleine Bildschirme ---------- */

@media (max-width: 1100px) {
	.b-wuerfel-raster { grid-template-columns: repeat(2, 1fr); }
	.hauptmenue > a { display: none; }
}
@media (max-width: 760px) {
	.breite { padding-left: 20px; padding-right: 20px; }
	.b-sec { padding: 64px 0; }
	.untermenue { display: none; }
	.wuerfelmenue .wm:not(.aktiv) { display: none; }
	.b-fakten, .b-raster-2 { grid-template-columns: 1fr; }
	.alle-unternehmen summary { white-space: normal; max-width: 180px; font-size: 14px; }
	.b-foto img { height: 300px; }
}
@media (max-width: 520px) {
	.b-wuerfel-raster { grid-template-columns: 1fr; }
}

/* ---------- Ergänzungen ---------- */
/* Rahmen-Knopf auf farbigem oder dunklem Band: Farbe vom Band übernehmen */
.b-farbe .is-style-outline .wp-block-button__link,
.b-nacht .is-style-outline .wp-block-button__link { color: inherit; border-color: currentColor; }
.b-nacht .wp-block-button:not(.is-style-outline) .wp-block-button__link { background: #fff; color: var(--nacht); }
/* Größerer Fließtext auf farbigem Band */
.b-gross { font-size: 20px; line-height: 1.5; }
/* Projektdaten (Fläche, Bauzeit, Rolle) als Zeilen */
ul.b-daten { list-style: none; margin: 18px 0 0; padding: 0; border-bottom: 1px solid var(--linie); }
ul.b-daten li { border-top: 1px solid var(--linie); padding: 12px 0; font-size: 16px; color: var(--grau); }
ul.b-daten li strong { color: var(--tinte); }
.b-sec .breite > .b-zwei + .b-zwei { margin-top: 72px; }
.b-zwei > .b-raster > * + * { margin-top: 0; }
.b-fakten p.b-wert { font-size: 36px; }
/* Sprungziele: Abstand nach oben, damit der feste Kopf nichts verdeckt */
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 110px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
/* projects: auf den Farbbändern weiße Schrift, dafür groß und fett */
.gesellschaft-projects .b-farbe { color: #fff; }
.b-farbe .b-fakten p.b-wert { font-size: clamp(34px, 3.6vw, 52px); }
.b-farbe .b-fakten p { font-size: 20px; }

/* ---------- Anklickbare Kacheln ----------
   Der Link am Ende der Kachel ("Mehr erfahren") wird über die ganze Kachel gelegt.
   So sind Würfel, Titel und Text anklickbar, ohne dass jeder einzeln verlinkt werden muss. */
.b-karte, .b-wuerfel-kachel { position: relative; }
.b-karte .b-link a::after, .b-wuerfel-kachel .b-link a::after { content: ""; position: absolute; inset: 0; }
.b-wuerfel img { transition: transform 0.25s ease; }
.b-karte h3, .b-wuerfel-kachel h3 { transition: color 0.2s ease; }
@media (hover: hover) {
	.b-karte:hover .b-wuerfel img, .b-wuerfel-kachel:hover .b-wuerfel img { transform: translateY(-6px) scale(1.04); }
	.b-karte:has(.b-link):hover h3, .b-wuerfel-kachel:hover h3 { color: var(--akzent); }
	.b-karte:has(.b-link):hover { border-color: var(--akzent); }
}
@media (prefers-reduced-motion: reduce) { .b-wuerfel img { transition: none; } }
/* Firmennamen: nur "batec" fett */
.b-wuerfel-kachel h3 { font-weight: 400; }
.b-wuerfel-kachel h3 strong { font-weight: 700; }
/* Raster mit drei Spalten (z. B. sechs Kacheln in zwei Reihen) */
.b-raster.b-raster-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .b-raster.b-raster-3 { grid-template-columns: 1fr; } }

/* ---------- Formulare (Fluent Forms) im Stil der Seite ---------- */
.b-klein { font-size: 13px; color: var(--grau); }
.b-klein a { text-decoration: underline; }
.b-formular .fluentform .ff-el-input--label label { font-size: 14px; font-weight: 700; color: var(--tinte); }
.b-formular .fluentform .ff-el-form-control { border: 1px solid #B9C5C8; border-radius: 6px; padding: 12px 14px; font: inherit; font-size: 16px; color: var(--tinte); background: #fff; }
.b-formular .fluentform .ff-el-form-control:focus { border-color: var(--akzent); outline: 2px solid var(--akzent); outline-offset: 1px; box-shadow: none; }
.b-formular .fluentform .ff-btn-submit { background: var(--farbe) !important; color: var(--auf-farbe) !important; border: 0; border-radius: 999px; padding: 15px 26px; font: inherit; font-size: 15px; font-weight: 700; }
.b-formular .fluentform .ff-btn-submit:hover { opacity: 0.9; }
.gruppe .b-formular .fluentform .ff-btn-submit { background: #00545E !important; color: #fff !important; }

/* Eingebettetes Formular (Stiebel Eltron): volle Breite unter dem Einleitungstext */
.breite > .b-einbettung { margin-top: 48px; }
.b-einbettung iframe { min-height: 900px; }
/* Stiebel-Formular ohne Rahmen. Das Formular bringt innen selbst 30px Rand mit,
   den gleichen wir auf breiten Bildschirmen aus, damit es bündig mit dem Text steht. */
.b-einbettung { border: 0; border-radius: 0; overflow: visible; background: transparent; }
.b-einbettung iframe { min-height: 600px; }
@media (min-width: 900px) { .b-einbettung iframe { width: calc(100% + 60px); margin-left: -30px; } }

/* Zwischenüberschrift mit Abstand nach oben, Liste aus Punkten untereinander */
.b-abstand { margin-top: 56px; margin-bottom: 20px; color: var(--grau); }
.b-liste > * + * { margin-top: 28px; }

/* ---------- Nacht-Einstieg (emotionaler Kopf der Service- und Elektroseiten) ----------
   Aufbau im Editor: kleine H1 (Suchbegriff), große Schlagzeile, Text, Knöpfe, Zeichnung. */
.b-nachtbild { background: linear-gradient(180deg, #06181B 0%, #0B2226 55%, #12333A 100%); color: #fff; text-align: center; padding-bottom: 0; overflow: hidden; }
.b-nachtbild .breite > * { margin-left: auto; margin-right: auto; }
.b-nachtbild h1.b-eyebrow { font-size: 13px; line-height: 1.4; letter-spacing: 0.22em; text-transform: uppercase; color: var(--licht); max-width: none; }
.b-schlagzeile { font-weight: 700; font-size: clamp(44px, 6.6vw, 100px); line-height: 0.95; letter-spacing: -0.035em; max-width: 1000px; margin-top: 20px; text-wrap: balance; }
.b-schlagzeile em { font-style: normal; color: var(--licht); }
.b-nachtbild .b-lead { color: #D5DEE0; max-width: 620px; margin-top: 24px; }
.b-nachtbild .wp-block-buttons { justify-content: center; margin-top: 28px; }
.b-nachtbild .is-style-outline .wp-block-button__link { color: #fff; border-color: #fff; }
.b-nachtbild .b-zeichnung { margin-top: 24px; }
.b-nachtbild .b-zeichnung img { display: block; width: 100%; height: auto; }
:root { --licht: var(--farbe); }
.gesellschaft-electric { --licht: #F26B6F; }
@media (max-width: 700px) { .b-nachtbild .b-zeichnung { margin-left: -40%; margin-right: -40%; } }
.b-nachtbild .b-zeichnung { margin-bottom: 0; }
