/* ═══════════ MODERN CSS RESET ═══════════ */

*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  -moz-text-size-adjust: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
}

body {
  min-height: 100vh;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

p {
  overflow-wrap: break-word;
}

video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

textarea {
  white-space: revert;
}

/* `hidden` gewinnt gegen jede display-Regel des Autors; until-found bleibt durchsuchbar. */
[hidden]:not([hidden="until-found"]) {
  display: none !important;
}

/* ═══════════ DESIGN-TOKENS (PROJEKT) ═══════════
   Projekteigene Design-Tokens — diese Datei gehört dem Projekt und wird von
   Template-Updates nie überschrieben (Konfliktregel: immer --ours, docs/UPDATES.md).
   Engine-CSS (_base.css & Co.) referenziert nur die Variablen.

   Theme-Blöcke sind erlaubt. Das Kontrast-Gate (scripts/check-contrast.js)
   erkennt sie als eigenes Theme und rechnet jedes einzeln gegen WCAG AA durch:
   `@media (prefers-color-scheme: dark)`, `[data-theme="…"]` (auch als
   `:root[data-theme=…]`, `body[data-theme=…]` oder im CSS-Nesting als
   `&[data-theme=…]`) und der klassenbasierte Umschalter (`html.dark`, `.dark`).
   Was hier im `:root` steht, gilt in allen Themes — ein Theme-Block
   überschreibt nur, was er selbst deklariert. `@layer`/`@supports` klammern
   bloß und bilden kein eigenes Theme; `@media print` und
   `@media (forced-colors: …)` bleiben ganz außen vor.

   Für ein dunkles Theme gilt: JEDES gepaarte Token gehört überschrieben, auch
   `--color-on-primary` (Text auf der Primärfarbe: .btn/.skip-link, CTA-Leiste,
   Formular-Button) und `--color-rating` (Bewertungssterne). Beide waren früher
   feste Farben im Engine-CSS und damit theme-blind — deshalb sind sie hier
   Token (N8). Was ein Theme nicht überschreibt, erbt es aus `:root`: ein
   dunkler Hintergrund plus geerbtes `--color-rating: #92400e` fällt im Gate
   als Kontrast-Befund auf, nicht erst im Betrieb.

   Weiter fest im Engine-CSS steht nur der WhatsApp-CTA (_cta.css): fremde
   Markenfarbe samt eigenem weißem Text, in jedem Theme unverändert. */

:root {
  /* Palette aus dem Entwurf (design-entwurf/): warmes Creme, Beinahe-Schwarz, Kupferbraun.
     Der Entwurf kennt keine Radien und kein dunkles Theme; die dunklen Bänder sind
     Sektionen auf --color-ink, kein Theme. */
  --color-primary: #8a5a3b;
  --color-primary-hover: #1c1917; /* Entwurf: gefüllte Knöpfe wechseln von Kupfer auf Schwarz */
  --color-on-primary: #f6f2ea;
  --color-text: #1c1917;
  --color-text-muted: #6b6257; /* 5,36:1 auf --color-bg, 4,95:1 auf --color-bg-alt */
  --color-bg: #f6f2ea;
  --color-bg-alt: #efe9dd;
  --color-border: #d8d1c4; /* Zierlinie (Entwurf: rgba(28,25,23,.14) auf Creme) */
  --color-border-control: #8c8377; /* 3,34:1 auf --color-bg, 3,09:1 auf --color-bg-alt */
  --color-success: #2f6b4f;
  --color-error: #a3321f;
  --color-rating: #8a5a3b;

  /* Projekt-Token (neu, nicht von der Engine gelesen). Paare prüft _config/kontrast-paare.js. */
  --color-text-body: #4a443c;     /* Fließtext der Entwurfsseiten */
  --color-bg-deep: #e7e0d2;       /* Bildflächen, Hover auf --color-bg-alt */
  --color-ink: #1c1917;           /* dunkle Bänder, Kopfleiste, Fußzeile */
  --color-on-ink: #ede6d8;
  --color-on-ink-strong: #f6f2ea;
  --color-on-ink-muted: #c6beb1;
  --color-on-ink-subtle: #948b7f; /* kleinste Schrift auf Dunkel; der Entwurf nutzte #8a7e6e (4,4:1) */
  --color-accent-on-ink: #c99a6b; /* Kupfer-Hell auf Dunkel */
  --color-on-cta: #f9f5ee;        /* Text im kupferfarbenen Abschlussband */

  --font-sans: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;

  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 2rem;
  --space-xl: 4rem;

  --container-max: 80rem;
  --container-padding: clamp(1.25rem, 4.5vw, 2rem);

  --radius: 0;
  --radius-lg: 0;
}

/* Design-Token-Werte liegen in _tokens.css (projekteigen) — hier nur Engine-CSS. */

/* ═══════════ BODY ═══════════ */

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background-color: var(--color-bg);
}

/* ═══════════ DEUTSCHE TYPOGRAFIE ═══════════ */

/* Komposita („Grundstücksentwässerungsanlage") brauchen Silbentrennung in schmalen
   Spalten — hyphens: auto greift nur mit lang="de" am <html> (base.njk, site.language). */
body {
  hyphens: auto;
}

/* Überschriften: ausgewogene Umbrüche, Trennung nur per weichem Trennstrich (&shy;) */
h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
  hyphens: manual;
}

p {
  text-wrap: pretty;
}

/* ═══════════ CONTAINER ═══════════ */

.container {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-padding);
}

/* ═══════════ PROSE ═══════════ */

.prose h1 { font-size: 2.25rem; line-height: 1.2; margin-block: var(--space-lg) var(--space-md); }
.prose h2 { font-size: 1.75rem; line-height: 1.25; margin-block: var(--space-lg) var(--space-sm); }
.prose h3 { font-size: 1.375rem; line-height: 1.3; margin-block: var(--space-lg) var(--space-sm); }
.prose p { margin-block-end: var(--space-md); }
.prose ul, .prose ol { margin-block-end: var(--space-md); padding-inline-start: var(--space-lg); }
.prose li { margin-block-end: var(--space-xs); }
.prose blockquote {
  border-inline-start: 3px solid var(--color-primary);
  padding-inline-start: var(--space-md);
  color: var(--color-text-muted);
  margin-block-end: var(--space-md);
}
.prose code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background: var(--color-bg-alt);
  padding: 0.125em 0.25em;
  border-radius: var(--radius);
}
.prose pre {
  background: var(--color-bg-alt);
  padding: var(--space-md);
  border-radius: var(--radius);
  overflow-x: auto;
  margin-block-end: var(--space-md);
}
.prose pre code {
  background: none;
  padding: 0;
}

/* ═══════════ HEADINGS ═══════════ */

h1, h2, h3, h4, h5, h6 {
  line-height: 1.2;
}

/* ═══════════ LINKS ═══════════ */

a {
  color: var(--color-primary);
  text-decoration-skip-ink: auto;
}

a:hover {
  color: var(--color-primary-hover);
}

/* ═══════════ ACCESSIBILITY ═══════════ */

/* Sichtbarer Fokus für Tastaturnutzer — niemals ersatzlos entfernen (WCAG 2.4.7) */
:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ═══════════ UMGEBUNGS-LEISTE ═══════════ */

/* Nur auf Vorschau-Ständen im Markup (layouts/base.njk, `umgebung.istStaging`) — im
   Auslieferungszustand rendert die Regel gegen nichts.

   KEIN `min-block-size: 44px`. Die 44 px aus N26 gehören echten Tap-Zielen (WCAG 2.5.5);
   die Leiste ist ein Satz zum Lesen und kein Bedienelement. Ihre Höhe kommt deshalb aus
   dem Innenabstand, nicht aus einer Zahl der Nachbaraufgabe.

   FARBEN AUS BESTEHENDEN TOKEN, kein neues: `src/_includes/css/_tokens.css` gehört dem
   Projekt und wird von /template-update nie ersetzt (`--ours`, docs/UPDATES.md). Ein
   neues Token hier verlangte von JEDEM Bestandsprojekt eine Handanlegung, sonst bräche
   dessen Kontrast-Gate mit „Token fehlt" — genau der Weg, den N8 einmal gehen musste.
   `--color-error` trägt die Warnfarbe, die es schon gibt; das Paar steht in PAIRS
   (scripts/lib/kontrast.js) und wird gegen 4,5:1 gerechnet.

   NICHT `--color-primary`: Die Sprungmarke darunter füllt sich daraus. Blau auf Blau
   ließe sie im Fokus in der Leiste verschwinden — sie liegt mit `z-index: 100` über ihr
   und muss dort als eigene Fläche erkennbar bleiben. */
.umgebung-leiste {
  padding: var(--space-sm) var(--container-padding);
  background: var(--color-error);
  color: var(--color-on-primary);
  font-weight: 600;
  text-align: center;
}

/* ═══════════ SKIP LINK ═══════════ */

/* Tap-Ziel ≥ 44 px (WCAG 2.5.5, N26): gemessen 41,59 px. `inline-flex` blockifiziert
   hier wegen `position: absolute` zu `flex` — die Breite bleibt also weiterhin am Inhalt,
   nur die Höhe bekommt einen Boden und der Text seine Mitte. */
.skip-link {
  position: absolute;
  display: inline-flex;
  align-items: center;
  min-block-size: 44px;
  top: -100%;
  left: var(--space-md);
  background: var(--color-primary);
  color: var(--color-on-primary);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius);
  z-index: 100;
  text-decoration: none;
  font-weight: 600;
}

.skip-link:focus {
  top: var(--space-sm);
}

/* ═══════════ BUTTON ═══════════ */

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s;
}

.btn:hover {
  background: var(--color-primary-hover);
  color: var(--color-on-primary);
}

/* ─────────────────────────────────────────────────────────
   Responsive Images — Base Styles
   Add these rules to your main stylesheet.
   Required for proper responsive behavior and CLS prevention.
   ───────────────────────────────────────────────────────── */

/* Core responsive image behavior + CLS prevention */
img {
  max-inline-size: 100%;
  block-size: auto;
  display: block;
}

/* Ensure <picture> wrapper doesn't break layout */
picture {
  display: block;
}

/* ─────────────────────────────────────────────────────────
   Hero Image — Optional utility class
   Apply to the hero <img> or wrapping <picture> element.
   Use with eleventy:pictureattr:class="hero-image" on the <img>.
   ───────────────────────────────────────────────────────── */
.hero-image {
  inline-size: 100%;
}

.hero-image img {
  inline-size: 100%;
  block-size: auto;
  object-fit: cover;
}

/* ─────────────────────────────────────────────────────────
   Content Images — Optional styling
   Images within the main content column.
   ───────────────────────────────────────────────────────── */
.content img,
.prose img {
  border-radius: 4px;
  margin-block: 1.5rem;
}

/* ─────────────────────────────────────────────────────────
   Thumbnail / Card Images — Optional
   For card grid layouts with fixed aspect ratio.
   ───────────────────────────────────────────────────────── */
.card-image img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
  aspect-ratio: 16 / 9;
}

/* ═══════════ SITE HEADER + NAV ═══════════ */

.site-header {
  padding-block: var(--space-md);
  border-block-end: 1px solid var(--color-border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.site-header__logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  text-decoration: none;
}

.site-header__logo:hover {
  color: var(--color-primary);
}

/* Mobile: details/summary als Umschalter.
   Die Navigation steht als Geschwister NEBEN dem <details> (nav.njk), nicht
   darin: sie wird allein über `[open]` und die Media-Query ein-/ausgeblendet.
   Bewusst kein `display: contents` auf dem <details> — wie eine Engine den
   Inhalt eines geschlossenen <details> dabei behandelt, ist nicht verlässlich.
   Übernommener Befund (Audit 2026-07-24, Fund 7, Gegenprüfung): Chrome blendet
   ihn über ::details-content aus, die Hauptnavigation war ab 768px auf jeder
   Seite unsichtbar.
   Selbst nachgemessen wurde nicht diese Ursache, sondern das Ergebnis: das
   Rendering-Gate in .github/workflows/deploy.yml prüft im headless Chrome bei
   1280px und 375px (zu- und aufgeklappt) die Bounding-Box von
   `.site-nav__list a`. Gegen den alten Aufbau schlägt es fehl, gegen diesen
   nicht. Firefox/Safari sind nicht nachgemessen — bei leerem <details> hängt
   dort nichts mehr am Engine-Verhalten für geschlossene Inhalte.
   Quelltextseitig zusätzlich abgesichert in scripts/tests/kontrast.test.js. */
.site-nav__toggle {
  display: block;
}

/* Tap-Ziel ≥ 44 px (WCAG 2.5.5, N26). Gemessen bei 375 px waren es 41,59 px — die
   Polsterung allein trägt die Fläche nicht über die Schwelle. `display: flex` ist hier
   kein Beiwerk: `min-block-size` allein ließe „Menü" oben in der gewachsenen Fläche
   kleben. Das <summary> bleibt trotz des geänderten `display` der Umschalter des
   <details> — im Browser bei 375 px auf- und wieder zugeklappt nachgeprüft. */
.site-nav__toggle > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  min-block-size: 44px;
  padding: var(--space-sm) var(--space-md);
  font-weight: 600;
}

.site-nav__toggle > summary::-webkit-details-marker {
  display: none;
}

/* Geschlossen versteckt, offen als volle Zeile unter dem Umschalter
   (.site-header .container ist ein Flex-Container mit flex-wrap: wrap). */
.site-nav {
  display: none;
  flex-basis: 100%;
}

.site-nav__toggle[open] ~ .site-nav {
  display: block;
}

.site-nav__list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

/* Tap-Ziel ≥ 44 px (WCAG 2.5.5, N26): gemessen 41,59 px. `flex` statt `block`, damit der
   Linktext in der gewachsenen Zeile mittig steht; die Fläche bleibt so breit wie zuvor,
   weil Flex-Container wie Blockboxen die volle Zeile einnehmen. */
.site-nav__list a {
  display: flex;
  align-items: center;
  min-block-size: 44px;
  padding: var(--space-sm) var(--space-md);
  color: var(--color-text);
  text-decoration: none;
  border-radius: var(--radius);
}

.site-nav__list a:hover,
.site-nav__list a[aria-current="page"] {
  color: var(--color-primary);
  background: var(--color-bg-alt);
}

/* Desktop: 768px+ — Umschalter weg, Navigation immer sichtbar. Der zweite
   Selektor deckt den Fall ab, dass das <details> aus der Mobilansicht noch
   [open] ist (Vergrößern des Fensters). */
@media (min-width: 768px) {
  .site-nav__toggle {
    display: none;
  }

  .site-nav,
  .site-nav__toggle[open] ~ .site-nav {
    display: block;
    flex-basis: auto;
  }

  .site-nav__list {
    flex-direction: row;
    gap: var(--space-sm);
  }
}

/* ═══════════ SITE FOOTER ═══════════ */

.site-footer {
  margin-block-start: var(--space-xl);
  padding-block: var(--space-lg);
  border-block-start: 1px solid var(--color-border);
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: var(--space-lg);
  margin-block-end: var(--space-lg);
}

.site-footer__name {
  font-weight: 600;
  color: var(--color-text);
  margin: 0 0 var(--space-xs);
}

.site-footer__address {
  font-style: normal;
  line-height: 1.6;
}

.site-footer__heading {
  font-weight: 600;
  color: var(--color-text);
  margin: 0 0 var(--space-sm);
}

.site-footer__contact,
.site-footer__social,
.site-footer__hours {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--space-xs);
}

.site-footer__social {
  grid-auto-flow: column;
  justify-content: start;
  gap: var(--space-md);
  margin-block-start: var(--space-sm);
}

.site-footer__hours li {
  display: flex;
  justify-content: space-between;
  gap: var(--space-md);
}

.site-footer__hint {
  margin-block-start: var(--space-sm);
}

/* Unterstrichen, weil die Linkfarbe dieselbe ist wie die des Fließtexts: in den
   Kanal-Zeilen („Support: +49 …") stünde der Link sonst ununterscheidbar im
   Text (WCAG 1.4.1/F73, Audit 2026-07-24, Fund 78). */
.site-footer a {
  color: var(--color-text-muted);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.site-footer a:hover {
  color: var(--color-primary);
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-md);
  padding-block-start: var(--space-md);
  border-block-start: 1px solid var(--color-border);
}

.site-footer__links {
  display: flex;
  gap: var(--space-md);
  list-style: none;
  padding: 0;
  margin: 0;
}

/* WCAG 2.5.8: Klickziele ≥ 24 px — Links in Footer-Listen sind eigenständige Ziele */
.site-footer__contact a,
.site-footer__social a,
.site-footer__links a {
  display: inline-block;
  padding-block: var(--space-xs);
}

/* ═══════════ LEAD FORM ═══════════ */

.lead-form {
  max-width: 32rem;
  margin: var(--space-lg) auto;
  padding: var(--space-lg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-bg);
}

.lead-form__heading {
  margin: 0 0 var(--space-md);
  font-size: 1.5rem;
}

.lead-form__form {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.lead-form__field {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.lead-form__field label {
  font-size: 0.875rem;
  font-weight: 600;
}

/* Der Rahmen ist hier keine Zierde: Das Feld trägt keine eigene Füllung und steht
   auf `.lead-form` (--color-bg). Ohne den Rahmen wäre nicht zu sehen, dass da ein
   Eingabefeld ist — genau das meint WCAG 1.4.11 mit „visual information required to
   identify user interface components" (3:1). Deshalb --color-border-control (N31). */
/* Tap-Ziel ≥ 44 px (WCAG 2.5.5, N26). Gemessen bei 375 px: 43,59 px — knapp, aber
   darunter. Keine Zentrierung nötig, die Felder zentrieren ihren Inhalt selbst; für
   das mehrzeilige textarea ist 44px ohnehin nur ein Boden, keine Höhe. Wirkt, weil
   _reset.css `box-sizing: border-box` setzt: die 44px enthalten Polsterung und Rahmen. */
.lead-form__field input,
.lead-form__field textarea,
.lead-form__field select {
  min-block-size: 44px;
  padding: var(--space-sm) 0.75rem;
  border: 1px solid var(--color-border-control);
  border-radius: var(--radius);
  font-size: 1rem;
  font-family: inherit;
}

.lead-form__field input:focus,
.lead-form__field textarea:focus,
.lead-form__field select:focus {
  outline: 2px solid var(--color-primary);
  outline-offset: 1px;
  border-color: var(--color-primary);
}

/* Inline-Validierung ohne JS: markiert erst nach Nutzer-Interaktion (WCAG 3.3.1) */
.lead-form__field input:user-invalid,
.lead-form__field textarea:user-invalid {
  border-color: var(--color-error);
  outline-color: var(--color-error);
}

.lead-form__required-hint {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
  margin: 0;
}

.lead-form__privacy-note {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
  margin: 0;
}

.lead-form__privacy-note a {
  color: var(--color-primary);
}

.lead-form__submit {
  padding: 0.75rem 1.5rem;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.15s;
}

.lead-form__submit:hover {
  background: var(--color-primary-hover);
}

/* ═══════════ BLOG INDEX ═══════════ */

.post-list {
  padding-block: var(--space-xl);
}

.post-list__items {
  list-style: none;
  padding: 0;
  display: grid;
  gap: var(--space-md);
  margin-block-start: var(--space-md);
}

.post-list__item {
  padding: var(--space-md);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.post-list__item a {
  text-decoration: none;
  color: inherit;
}

.post-list__title {
  margin-block-end: var(--space-xs);
  font-size: 1.25rem;
}

.post-list__meta {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  margin: 0;
}

.post-list__excerpt {
  margin-block-start: var(--space-sm);
  margin-block-end: 0;
}

/* ═══════════ BLOG POST ═══════════ */

.post__header {
  margin-block-end: var(--space-lg);
  padding-block-end: var(--space-md);
  border-block-end: 1px solid var(--color-border);
}

.post__meta {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  margin-block-start: var(--space-sm);
}

/* ═══════════ SEKTIONEN (Leistungen, Team, Kundenstimmen) ═══════════ */

.section {
  padding-block: var(--space-xl);
}

.section--alt {
  background-color: var(--color-bg-alt);
}

.section__lead {
  color: var(--color-text-muted);
  max-width: 40rem;
  margin-block-start: var(--space-sm);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: var(--space-md);
  margin-block-start: var(--space-lg);
  list-style: none;
  padding: 0;
}

.card {
  padding: var(--space-lg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background-color: var(--color-bg);
}

/* Karten-Headings tag-unabhängig auf Design-Größe festlegen: das adaptive kartenTag
   (h2 statt h3 ohne Sektions-h2, siehe a1a9401) darf die Optik nicht ändern.
   1.25rem = bestehende Präzedenz der Standort-Übersichtskarten. */
.card :is(h2, h3) {
  font-size: 1.25rem;
}

/* ── Leistungen ── */

.leistung {
  display: flex;
  flex-direction: column;
}

.leistung--featured {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px var(--color-primary);
}

.leistung__name {
  margin: 0 0 var(--space-xs);
}

.leistung__desc {
  color: var(--color-text-muted);
  margin: 0 0 var(--space-md);
}

.leistung__price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
}

.leistung__price small {
  display: block;
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--color-text-muted);
}

.leistung__features {
  list-style: none;
  padding: 0;
  margin: var(--space-md) 0 0;
  display: grid;
  gap: var(--space-xs);
  font-size: 0.9375rem;
}

.leistung__features li::before {
  content: "✓";
  color: var(--color-success);
  margin-inline-end: var(--space-xs);
}

/* ── Kundenstimmen ── */

.testimonial {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.testimonial__quote {
  font-size: 1.0625rem;
  line-height: 1.6;
  margin: 0;
}

.testimonial__stars {
  /* Eigenes Token, damit ein dunkles Theme die Sterne mit umstellen kann — als
     Literal maß das Gate hier in jedem Theme den Light-Wert (N8). Im
     Auslieferungszustand ≥ 6,78:1 auf --color-bg und --color-bg-alt (WCAG 1.4.3),
     deutlich über dem AA-Mindestwert 4,5:1. */
  color: var(--color-rating);
  letter-spacing: 0.1em;
}

.testimonial__author {
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}

/* ── FAQ ── */

.faq__list {
  display: grid;
  gap: var(--space-sm);
  margin-block-start: var(--space-lg);
  max-width: 48rem;
}

.faq__item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  background-color: var(--color-bg);
}

/* Tap-Ziel ≥ 44 px (WCAG 2.5.5, N26). Gemessen bei 375 px: 25,59 px bei einzeiliger
   Frage — die Höhe hing allein an der Zeilenhöhe und damit an der Fragelänge. Genau
   deshalb ist der Boden nötig: eine lange, umbrechende Frage kam zufällig über 44 px,
   eine kurze nie.

   `display: list-item` ist der Vorgabewert von <summary> und steht hier trotzdem
   ausgeschrieben — als Sperre. Dieses <summary> hat, anders als der Nav-Umschalter
   (`_nav.css:52` mit `list-style: none`), KEIN `list-style: none`: sein Aufklapp-Dreieck
   ▶ ist der einzige optische Hinweis, dass der Eintrag sich öffnet. Chrome rendert diesen
   Marker nur bei `display: list-item` — jeder andere Wert löscht ihn. Eine erste Fassung
   dieser Regel stand auf `display: flex` und tat genau das (Fix-Runde 1: gemessen
   textLeft 17,00 statt 33,94, Dreieck weg). Die Mitte holt deshalb `align-content`, das
   auf Blockcontainern dasselbe leistet, ohne den Marker anzufassen.
   Wer hier ein anderes `display` einträgt, nimmt der ganzen Fleet das Dreieck;
   scripts/tests/touch-ziele.test.js hält den Wert fest. */
.faq__question {
  display: list-item;
  align-content: center;
  min-block-size: 44px;
  font-weight: 600;
  cursor: pointer;
}

.faq__answer {
  margin: var(--space-sm) 0 0;
  color: var(--color-text-muted);
}

/* ── Team ── */

.team-member__photo {
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  object-fit: cover;
  margin-block-end: var(--space-sm);
}

.team-member__name {
  margin: 0;
}

.team-member__role {
  color: var(--color-primary);
  font-size: 0.9375rem;
  margin: 0 0 var(--space-sm);
}

.team-member__bio {
  color: var(--color-text-muted);
  font-size: 0.9375rem;
  margin: 0;
}

/* Hinweiszeile unter Sektionen */
.section__hinweis {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  margin-block-start: var(--space-md);
}

/* ── Karte (components/karte.njk) ── */

/* Steht bewusst hier und nicht in einer eigenen, bedingt eingebundenen Datei wie
   _einbettung.css: Die Karte hängt an keinem Dienst (E9) und ist auf jeder Site
   verfügbar. Eine Bedingung in assets/style.njk wäre der Anfang genau der Kopplung, die
   die Komponente vermeidet. */
.karte {
  margin: 0 0 var(--space-lg);
}

/* Ein Kartenausschnitt kommt in der Breite, in der ihn jemand exportiert hat. `max-width`
   hält ihn im Container, `height: auto` verhindert dabei das Verzerren. Ein festes
   `aspect-ratio` wie in _einbettung.css wäre hier falsch: Dort ersetzt der Klick das Bild
   durch ein iframe, und nur gleiche Höhen lassen die Seite nicht springen — hier bleibt
   das Bild, was es ist. */
.karte__bild {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
}

/* Die figcaption trägt hier die Handlung statt einer Bildunterschrift; ohne eigenen
   Abstand klebte der Knopf am Bildrand. */
.karte__aktion {
  margin-block-start: var(--space-md);
}

/* ── Hinweisseiten (src/pages/: 404, Danke) ── */

/* Klassen statt Inline-Styles: _projekt.css trifft sie so ohne !important. */
.hinweis-seite {
  text-align: center;
  padding-block: var(--space-xl);
}

.hinweis-seite__erfolg {
  color: var(--color-success);
}

/* ═══════════ STICKY MOBILE CTA ═══════════ */

.cta-bar {
  display: none;
}

@media (max-width: 767px) {
  .cta-bar {
    position: fixed;
    inset-block-end: 0;
    inset-inline: 0;
    display: flex;
    gap: 1px;
    z-index: 90;
    background: var(--color-border);
    box-shadow: 0 -2px 8px rgb(0 0 0 / 0.08);
    padding-block-end: env(safe-area-inset-bottom);
  }

  /* Inhalt nicht von der Leiste verdecken */
  body {
    padding-block-end: 3.5rem;
  }

  /* WCAG 2.4.11: fokussierte Elemente dürfen beim Tabben nicht hinter der Leiste landen */
  html {
    scroll-padding-block-end: calc(3.5rem + env(safe-area-inset-bottom));
  }
}

.cta-bar__btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0.875rem;
  background: var(--color-primary);
  color: var(--color-on-primary);
  text-decoration: none;
  font-weight: 600;
}

.cta-bar__btn:hover {
  background: var(--color-primary-hover);
  color: var(--color-on-primary);
}

.cta-bar__btn svg {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
}

/* Dunkles WhatsApp-Teal statt Brand-Grün. Der Text ist normaler Text (1rem/600,
   kein „large text"), also gilt WCAG 1.4.3 mit 4,5:1 — das frühere #128c7e
   erreichte nur 4,14:1. Beide Werte stehen als Paar in scripts/lib/kontrast.js
   und werden vom Build-Gate nachgerechnet (Audit 2026-07-24, Fund 10).

   Fremde Markenfarbe: sie folgt KEINEM Token und bleibt in jedem Theme dieselbe
   — deshalb setzt die Variante auch ihren Textton selbst statt das theme-
   abhängige --color-on-primary aus `.cta-bar__btn` zu erben (im dunklen Theme
   wäre das dunkel auf dunkel). Die Hover-Regel braucht das eigene `color`
   ebenfalls: `.cta-bar__btn:hover` ist spezifischer als diese Grundregel (N8). */
.cta-bar__btn--whatsapp {
  background: #0e7266; /* 5,81:1 zu #fff */
  color: #fff;
}

.cta-bar__btn--whatsapp:hover {
  background: #0b5b52; /* 7,98:1 zu #fff */
  color: #fff;
}









/* ═══════════ PROJEKT-DESIGN — Energieausweis Köln ═══════════
   Design-Import 2026-09-22, SOLL: design-entwurf/ (Claude-Design-Export, .dc.html).
   Der Entwurf setzt jeden Wert als Inline-Style; hier stehen dieselben Werte als
   Klassen mit Präfix `ek-`. Farben über Token (_tokens.css); Haarlinien auf Dunkel
   bleiben rgba-Literale, weil das Kontrast-Gate rgba-Token nicht messen kann.
   Mindestspalten immer als min(…, 100%) — sonst läuft 320 px über. */

/* ── Schriften (static/fonts/, Lizenz: static/fonts/LICENSE.txt) ── */

@font-face {
  font-family: "Manrope";
  src: url("/fonts/manrope-variable.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Instrument Serif";
  src: url("/fonts/instrument-serif-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-mono-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/fonts/ibm-plex-mono-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* ── Grundlagen ── */

/* Layout-Variablen vererben NICHT: sonst schlüge das --gap eines Stapels auf ein Raster
   darin durch (vier Karten à 280 px passten dann nicht mehr in eine Zeile). */
@property --gap { syntax: "<length>"; inherits: false; initial-value: 20px; }
@property --fuge { syntax: "<length>"; inherits: false; initial-value: 24px; }
@property --min { syntax: "<length>"; inherits: false; initial-value: 300px; }

main a {
  color: inherit;
  text-decoration: none;
}
main a:hover {
  color: inherit;
  text-decoration: underline;
}
/* Fließtext-Links (Rechtsseiten) bleiben unterstrichen und kupferfarben. */
main .prose a {
  color: var(--color-primary);
  text-decoration: underline;
}

.ek-wrap {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-padding);
}
.ek-wrap--820 { max-width: 51.25rem; }
.ek-wrap--920 { max-width: 57.5rem; }
.ek-wrap--1000 { max-width: 62.5rem; }

.ek-stapel {
  display: flex;
  flex-direction: column;
  gap: var(--gap);
}
.ek-raster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(var(--min), 100%), 1fr));
  gap: var(--fuge);
}
.ek-kopf {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: clamp(26px, 4vw, 40px);
  flex-wrap: wrap;
}
.ek-kopf > p { max-width: 440px; }

.ek-knoepfe {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* ── Typografie ── */

.ek-eyebrow {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-primary);
}
.ek-h1 {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(34px, 7vw, 56px);
  line-height: 1.07;
  letter-spacing: -0.01em;
}
.ek-h1 em,
.ek-h2 em { color: var(--color-primary); }
.ek-h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(28px, 5vw, 42px);
  line-height: 1.12;
}
.ek-h2--klein { font-size: clamp(25px, 4.1vw, 34px); }
.ek-h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}
.ek-h3-serif {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(24px, 3.6vw, 30px);
  line-height: 1.15;
}
.ek-lead {
  margin: 0;
  max-width: 560px;
  font-size: 18px;
  line-height: 1.65;
  color: var(--color-text-body);
}
.ek-text {
  margin: 0;
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--color-text-body);
}
.ek-klein {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--color-text-muted);
}
.ek-liste {
  margin: 0;
  padding-left: 18px;
  font-size: 16px;
  line-height: 2.05;
  color: var(--color-text-body);
}

/* ── Knöpfe und Pfeil-Links ── */

.ek-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 15px 28px;
  border: 1px solid transparent;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
a.ek-btn:hover,
.ek-btn:hover {
  background: var(--color-primary-hover);
  color: var(--color-on-primary);
  text-decoration: none;
}
.ek-btn--dunkel {
  background: var(--color-ink);
  color: var(--color-on-ink-strong);
}
a.ek-btn--dunkel:hover {
  background: var(--color-primary);
  color: var(--color-on-primary);
}
.ek-btn--rahmen {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border-control);
}
a.ek-btn--rahmen:hover {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-text);
}
.ek-btn--hell {
  background: transparent;
  color: var(--color-on-ink);
  border-color: var(--color-on-ink-subtle);
}
a.ek-btn--hell:hover {
  background: transparent;
  color: var(--color-on-ink-strong);
  border-color: var(--color-on-ink);
}

.ek-pfeil {
  font-weight: 600;
  color: var(--color-primary);
}
main a.ek-pfeil { color: var(--color-primary); }
/* Pfeil nur fürs Auge: der Alternativtext nach „/" ist leer. */
.ek-pfeil::after { content: " →"; content: " →" / ""; }

/* ── Bänder (Sektionen) ── */

.ek-band { padding-block: clamp(48px, 7vw, 88px); }
.ek-band--kompakt { padding-block: clamp(44px, 7vw, 80px); }
.ek-band--alt { background: var(--color-bg-alt); }
.ek-band--ink {
  background: var(--color-ink);
  color: var(--color-on-ink);
}
.ek-band--ink .ek-eyebrow { color: var(--color-accent-on-ink); }
.ek-band--ink .ek-text,
.ek-band--ink .ek-liste,
.ek-band--ink p { color: var(--color-on-ink-muted); }
.ek-band--ink .ek-h3 { color: var(--color-on-ink-strong); }
.ek-band--ink main a.ek-pfeil,
.ek-band--ink a.ek-pfeil { color: var(--color-accent-on-ink); }
.ek-band--ink :focus-visible,
.ek-footer :focus-visible,
.ek-topbar :focus-visible { outline-color: var(--color-accent-on-ink); }

.ek-band--cta {
  background: var(--color-primary);
  color: var(--color-on-cta);
  padding-block: clamp(42px, 7vw, 70px);
}
.ek-band--cta :focus-visible { outline-color: var(--color-on-cta); }
.ek-cta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: clamp(26px, 4vw, 40px);
  flex-wrap: wrap;
}
.ek-cta__text { max-width: 640px; --gap: 14px; }
.ek-cta__text p {
  margin: 0;
  font-size: 17px;
  line-height: 1.65;
}
.ek-band--cta a.ek-btn--dunkel:hover {
  background: var(--color-bg);
  color: var(--color-text);
}
.ek-cta__neben {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
  text-align: center;
  font-size: 14.5px;
}
.ek-cta__neben a:not(.ek-btn) { text-decoration: underline; }

/* ── Kopfleiste und Kopf ── */

.ek-topbar {
  background: var(--color-ink);
  color: var(--color-on-ink);
  font-size: 13px;
}
.ek-topbar__inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding-block: 10px;
}
.ek-topbar__claims {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ek-topbar a {
  color: inherit;
  text-decoration: none;
}
.ek-topbar a:hover { text-decoration: underline; }
@media (max-width: 720px) {
  .ek-topbar__claims { display: none; }
}

.ek-header {
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
}
.ek-header__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px 32px;
  padding-block: 16px;
}
.ek-logo {
  display: flex;
  align-items: center;
  min-width: 0;
}
/* Kopf-Logo (static/img/logo.svg): Höhe führt, Breite folgt dem Seitenverhältnis */
.ek-logo__bild {
  display: block;
  width: auto;
  height: clamp(50px, 12vw, 72px);
  max-width: 100%;
}

.ek-nav ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 26px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
  font-weight: 500;
}
.ek-nav a {
  color: var(--color-text);
  text-decoration: none;
}
.ek-nav a:hover { text-decoration: underline; }
.ek-nav a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-color: var(--color-primary);
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}
.ek-nav__zusatz,
.ek-nav__aktionen { display: none; }
.ek-nav-toggle { display: none; }
.ek-header__cta { flex: none; }
.ek-header__cta .ek-btn { min-height: 46px; padding: 12px 22px; font-size: 15px; }

/* Wie im Entwurf: unter 980 px klappt die Leiste in ein Menü. */
@media (min-width: 981px) {
  .ek-header__inner { flex-wrap: nowrap; }
  .ek-nav { margin-left: auto; }
}
@media (max-width: 980px) {
  .ek-header__cta { display: none; }
  /* Logo schrumpft (Unterzeile bricht um), damit der Menü-Knopf in derselben Zeile bleibt. */
  .ek-logo { flex: 1 1 0; min-width: 0; }
  .ek-nav-toggle { display: block; }
  .ek-nav-toggle summary {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 46px;
    padding: 11px 16px;
    background: var(--color-ink);
    color: var(--color-on-ink-strong);
    font-size: 15px;
    font-weight: 600;
    list-style: none;
    cursor: pointer;
  }
  .ek-nav-toggle summary::-webkit-details-marker { display: none; }
  .ek-burger {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 18px;
  }
  .ek-burger span {
    height: 2px;
    background: currentColor;
  }
  /* Aufgeklappt stehen Menü und Knöpfe als eine Fläche über die volle Breite. */
  .ek-header__inner { row-gap: 0; }
  .ek-nav {
    display: none;
    flex-basis: calc(100% + 2 * var(--container-padding));
    margin-inline: calc(-1 * var(--container-padding));
    margin-bottom: -22px;
    padding: 8px var(--container-padding) 22px;
    background: var(--color-bg-alt);
    border-top: 1px solid var(--color-border);
  }
  .ek-nav-toggle[open] ~ .ek-nav { display: block; }
  .ek-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    font-size: 17px;
  }
  .ek-nav li a {
    display: block;
    padding: 16px 0;
    border-bottom: 1px solid var(--color-border);
  }
  .ek-nav__zusatz { display: inline; }
  .ek-nav-toggle[open] ~ .ek-nav { margin-top: 22px; margin-bottom: 0; padding-bottom: 0; }
  .ek-nav-toggle[open] ~ .ek-nav__aktionen {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-basis: calc(100% + 2 * var(--container-padding));
    margin: 0 calc(-1 * var(--container-padding)) -22px;
    padding: 20px var(--container-padding) 22px;
    background: var(--color-bg-alt);
  }
}

/* Sehr schmal: Menü-Knopf nur mit Symbol, die Beschriftung bleibt für Screenreader. */
@media (max-width: 359px) {
  .ek-nav-toggle summary { padding-inline: 12px; }
  .ek-nav-toggle__text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}

/* ── Karten ── */

.ek-karte {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: clamp(24px, 5vw, 32px);
  border-top: 3px solid var(--color-primary);
}
.ek-karte--gross { padding: clamp(24px, 5vw, 40px); gap: 18px; }
.ek-karte--alt { background: var(--color-bg-alt); }
.ek-karte--hell { background: var(--color-bg); }
.ek-karte--neutral { border-top-color: var(--color-border-control); }
.ek-karte--ink {
  background: var(--color-ink);
  color: var(--color-on-ink);
  border-top-color: var(--color-primary);
}
.ek-karte p {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.68;
  color: var(--color-text-body);
}
.ek-karte .ek-liste { font-size: 15px; line-height: 2; }
.ek-karte--ink p,
.ek-karte--ink .ek-liste { color: var(--color-on-ink-muted); }
.ek-karte--ink a.ek-pfeil { color: var(--color-accent-on-ink); }
.ek-karte .ek-pfeil { margin-top: auto; padding-top: 14px; }
.ek-karte__kopf {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
}
.ek-preis {
  font-family: var(--font-mono);
  font-size: 19px;
  color: var(--color-primary);
  white-space: nowrap;
}
.ek-karte--ink .ek-preis { color: var(--color-accent-on-ink); }
.ek-preis--gross {
  font-family: var(--font-serif);
  font-size: clamp(30px, 6vw, 48px);
  line-height: 1;
}
.ek-karte__unterzeile { font-size: 14px; color: var(--color-text-muted); }
.ek-karte--ink .ek-karte__unterzeile { color: var(--color-on-ink-muted); }

/* Haarlinien-Raster: Zellen mit 1 px Fuge */
.ek-zellen {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(var(--min), 100%), 1fr));
  gap: 1px;
  background: var(--color-border);
  border: 1px solid var(--color-border);
}
.ek-zellen > * {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 0;
  padding: 30px;
  background: var(--color-bg);
}
.ek-zellen p {
  margin: 0;
  font-size: 15px;
  line-height: 1.65;
  color: var(--color-text-body);
}
.ek-zellen--links > a {
  padding: 20px 22px;
  font-size: 15.5px;
  font-weight: 500;
}
.ek-zellen--links > span,
.ek-zellen--links > li {
  padding: 20px 22px;
  font-size: 15.5px;
  font-weight: 500;
}
main .ek-zellen--links > a:hover {
  background: var(--color-bg-alt);
  text-decoration: none;
}
.ek-zelle__marke {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-primary);
}

/* ── Startseite ── */

.ek-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr));
}
.ek-hero__text {
  display: flex;
  justify-content: flex-end;
  padding: clamp(48px, 7vw, 76px) var(--container-padding) clamp(44px, 6.5vw, 70px);
  container-type: inline-size;
}
.ek-hero__text > .ek-stapel { max-width: 640px; --gap: 24px; }
.ek-hero .ek-h1 {
  font-size: clamp(34px, 12cqw, 64px);
  line-height: 1.05;
}
.ek-hero .ek-lead { max-width: 540px; }
.ek-hero .ek-bild { --h: 540px; }
.ek-vertrauen {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 10px 0 0;
  padding: 22px 0 0;
  border-top: 1px solid var(--color-border);
  list-style: none;
  font-size: 13.5px;
  color: var(--color-text-muted);
}

.ek-kennzahlen {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
  gap: 32px;
  margin-block: 0;
  padding-block: 34px;
}
.ek-kennzahlen div {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
  gap: 5px;
}
.ek-kennzahlen dt { font-size: 14px; color: var(--color-on-ink); }
.ek-kennzahlen dd {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(25px, 4.1vw, 34px);
  color: var(--color-on-ink-strong);
}

.ek-hinweisband {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  padding: 26px var(--container-padding);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
}
.ek-hinweisband p { margin: 0; font-size: 16px; color: var(--color-text-body); }

.ek-nummern { display: flex; flex-direction: column; }
.ek-nummern > div {
  display: flex;
  gap: 18px;
  padding: 22px 0;
  border-top: 1px solid var(--color-border);
}
.ek-nummern > div:last-child { border-bottom: 1px solid var(--color-border); }
.ek-nummern__nr {
  padding-top: 3px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--color-primary);
}
.ek-nummern p {
  margin: 5px 0 0;
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--color-text-body);
}
.ek-merkkasten {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 28px;
  background: var(--color-bg-alt);
  border-left: 3px solid var(--color-primary);
}
.ek-merkkasten strong {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 400;
}
.ek-merkkasten span { font-size: 15.5px; line-height: 1.65; color: var(--color-text-body); }

.ek-schritte {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: clamp(26px, 4vw, 40px);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ek-schritte li {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 26px;
  border-top: 1px solid rgba(237, 230, 216, 0.24);
}
.ek-schritte__nr {
  font-family: var(--font-serif);
  font-size: clamp(30px, 5.6vw, 44px);
  line-height: 1;
  color: var(--color-accent-on-ink);
}
.ek-schritte h3 { margin: 0; font-size: 19px; font-weight: 700; color: var(--color-on-ink-strong); }
.ek-schritte p { margin: 0; font-size: 15.5px; line-height: 1.7; }

.ek-zitate figure {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin: 0;
  padding: 34px;
  background: var(--color-bg);
}
.ek-zitate blockquote {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 22px;
  line-height: 1.45;
}
.ek-zitate figcaption { font-size: 14px; color: var(--color-text-muted); }
.ek-bewertung {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.ek-bewertung strong {
  font-family: var(--font-mono);
  font-size: 19px;
  font-weight: 400;
  color: var(--color-primary);
}
.ek-bewertung span { font-size: 14px; color: var(--color-text-muted); }

/* ── Aufklappbare Fragen ── */

.ek-klapp { border-top: 1px solid var(--color-border); }
.ek-klapp__eintrag { border-bottom: 1px solid var(--color-border); }
.ek-klapp__eintrag summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  min-height: 44px;
  padding: 20px 0;
  list-style: none;
  cursor: pointer;
}
.ek-klapp__eintrag summary::-webkit-details-marker { display: none; }
.ek-klapp__eintrag summary::after {
  content: "+";
  flex: none;
  font-family: var(--font-mono);
  font-size: 20px;
  color: var(--color-primary);
}
.ek-klapp__eintrag[open] summary::after { content: "−"; }
.ek-klapp__eintrag h3 { margin: 0; font-size: 18px; font-weight: 600; line-height: 1.4; }
.ek-klapp__eintrag p {
  max-width: 720px;
  margin: 0;
  padding: 0 0 22px;
  font-size: 16px;
  line-height: 1.72;
  color: var(--color-text-body);
}

/* ── Frage-Antwort-Zeilen, Begriffszeilen ── */

.ek-fragezeilen { border-top: 1px solid var(--color-border); }
.ek-fragezeilen__zeile {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: 12px 24px;
  padding: 24px 0;
  border-bottom: 1px solid var(--color-border);
}
.ek-fragezeilen h3 { margin: 0; font-size: 18.5px; font-weight: 600; line-height: 1.4; }
.ek-fragezeilen p { margin: 0; font-size: 16px; line-height: 1.72; color: var(--color-text-body); }

.ek-zeilen {
  margin: 0;
  border-top: 1px solid rgba(237, 230, 216, 0.24);
}
.ek-zeilen__zeile {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr));
  gap: 8px 24px;
  padding: 22px 0;
  border-bottom: 1px solid rgba(237, 230, 216, 0.24);
}
.ek-zeilen dt { font-size: 17px; font-weight: 600; color: var(--color-on-ink-strong); }
.ek-zeilen dd { margin: 0; font-size: 16px; line-height: 1.7; color: var(--color-on-ink-muted); }

/* ── Seitenkopf der Unterseiten ── */

.ek-krume {
  padding-top: 18px;
  font-size: 13px;
  color: var(--color-text-muted);
}
.ek-krume a { color: inherit; text-decoration: none; }
.ek-krume a:hover { text-decoration: underline; }
/* Trenner in Textfarbe: pa11y (htmlcs) misst auch aria-hidden-Text, 3,3:1 fiel durch. */
.ek-krume span[aria-hidden] { color: var(--color-text-muted); }

.ek-seitenkopf {
  padding-block: clamp(32px, 6.5vw, 44px) clamp(45px, 6.5vw, 64px);
}
.ek-seitenkopf .ek-stapel { --gap: 20px; }
.ek-produktkopf {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr));
  gap: clamp(32px, 5vw, 56px);
  align-items: start;
  padding-block: clamp(32px, 6.5vw, 44px) clamp(53px, 6.5vw, 76px);
}
.ek-produktkopf > .ek-stapel {
  min-width: 0;
  --gap: 22px;
  container-type: inline-size;
}
.ek-produktkopf .ek-h1 { font-size: clamp(32px, 12cqw, 58px); }
.ek-produktkopf .ek-liste { font-size: 16px; line-height: 2.1; }

/* Bestellkarte (ersetzt die Formular-Attrappe des Entwurfs) */
.ek-bestellkarte {
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: clamp(24px, 5vw, 40px);
  background: var(--color-ink);
  color: var(--color-on-ink);
}
.ek-bestellkarte h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 400;
}
.ek-bestellkarte .ek-preis { font-size: 22px; color: var(--color-accent-on-ink); }
.ek-bestellkarte ol {
  margin: 0;
  padding-left: 20px;
  font-size: 15.5px;
  line-height: 1.9;
  color: var(--color-on-ink-muted);
}
.ek-bestellkarte__fuss {
  font-size: 13px;
  text-align: center;
  color: var(--color-on-ink-subtle);
}
.ek-bestellkarte .ek-btn { width: 100%; }
.ek-bestellkarte a.ek-btn:hover {
  background: var(--color-accent-on-ink);
  color: var(--color-ink);
}

/* Energieeffizienzklassen (Entwurfsfarben; Schrift je Klasse auf ≥ 4,5:1 gewählt) */
.ek-skala {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(64px, 100%), 1fr));
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ek-skala li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-height: 64px;
  padding: 14px 6px;
  color: #ffffff;
}
.ek-skala b { font-size: 16px; }
.ek-skala span { font-family: var(--font-mono); font-size: 11px; }
.ek-skala .k-ap { background: #2f6b4f; }
.ek-skala .k-a { background: #48824a; }
.ek-skala .k-b { background: #6e9741; color: #1c1917; }
.ek-skala .k-c { background: #9da636; color: #1c1917; }
.ek-skala .k-d { background: #c2a02e; color: #1c1917; }
.ek-skala .k-e { background: #c4802c; color: #1c1917; }
.ek-skala .k-f { background: #b65f29; }
.ek-skala .k-g { background: #9c4026; }
.ek-skala .k-h { background: #7a2620; }

/* Bildflächen (teile.bild): das Bild füllt die Fläche, Höhe über --h */
.ek-bild {
  position: relative;
  min-height: var(--h, 340px);
  overflow: hidden;
  background-color: var(--color-bg-deep);
}
.ek-bild img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ── Preise ── */

.ek-preiszeilen { border-top: 1px solid var(--color-border); }
.ek-preiszeilen > div {
  display: flex;
  justify-content: space-between;
  gap: 8px 24px;
  flex-wrap: wrap;
  padding: 20px 0;
  border-bottom: 1px solid var(--color-border);
}
.ek-preiszeilen b { display: block; font-size: 17px; font-weight: 600; }
.ek-preiszeilen span { font-size: 15px; color: var(--color-text-body); }
.ek-preiszeilen .ek-preis { font-size: 17px; }

/* ── Ablauf ── */

.ek-ablauf {
  margin: 0;
  padding: 0;
  list-style: none;
}
.ek-ablauf li {
  display: grid;
  grid-template-columns: minmax(56px, 120px) minmax(0, 1fr);
  gap: clamp(16px, 4vw, 32px);
  padding: 34px 0;
  border-top: 1px solid var(--color-border);
}
.ek-ablauf li:last-child { border-bottom: 1px solid var(--color-border); }
/* Entwurfsfarbe #8a7454: 4,0:1 auf Creme — zulässig nur, weil die Ziffer große
   Schrift ist (≥ 30 px, WCAG 1.4.3: 3:1). */
.ek-ablauf__nr {
  font-family: var(--font-serif);
  font-size: clamp(30px, 6.5vw, 52px);
  line-height: 1;
  color: #8a7454;
}
.ek-ablauf h2 { margin: 0; font-size: 24px; font-weight: 700; line-height: 1.3; }
.ek-ablauf p { margin: 0; font-size: 16.5px; line-height: 1.7; color: var(--color-text-body); }

/* ── Stadtteile ── */

.ek-fakten {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: clamp(24px, 5vw, 36px);
  background: var(--color-bg-alt);
}
.ek-fakten h2 {
  margin: 0 0 18px;
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 400;
}
.ek-fakten dl { margin: 0; }
.ek-fakten dl div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-top: 1px solid var(--color-border);
  font-size: 15px;
}
.ek-fakten dt { color: var(--color-text-body); }
.ek-fakten dd { margin: 0; font-weight: 600; text-align: right; }
.ek-fakten .ek-fakten__betont dt,
.ek-fakten .ek-fakten__betont dd { color: var(--color-primary); font-weight: 600; }

.ek-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}
.ek-chips li > * {
  display: inline-block;
  padding: 6px 12px;
  background: var(--color-bg-alt);
  font-size: 13.5px;
}
main .ek-chips a:hover {
  background: var(--color-ink);
  color: var(--color-on-ink-strong);
  text-decoration: none;
}
.ek-chips--ink { gap: 10px; }
.ek-chips--ink li > a {
  padding: 11px 18px;
  background: transparent;
  border: 1px solid var(--color-on-ink-subtle);
  font-size: 15px;
}
main .ek-chips--ink a:hover {
  background: var(--color-on-ink);
  color: var(--color-ink);
}
.ek-bezirk__kopf {
  display: flex;
  align-items: baseline;
  gap: 12px;
}
.ek-bezirk__nr {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--color-primary);
}

/* ── Quiz „Welchen Ausweis brauchen Sie?" (Logik: assets-quelle/projekt.js) ── */

.ek-quiz__raster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: clamp(32px, 5vw, 56px);
  align-items: start;
}
.ek-quiz__preise {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 440px;
  margin: 0;
  padding-top: 14px;
  border-top: 1px solid rgba(237, 230, 216, 0.22);
}
.ek-quiz__preise div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 15.5px;
}
.ek-quiz__preise dt { color: var(--color-on-ink-muted); }
.ek-quiz__preise dd { margin: 0; font-family: var(--font-mono); color: var(--color-on-ink); }
.ek-quiz__fortschritt {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-on-ink-subtle);
}
.ek-quiz__balken {
  position: relative;
  flex: 1;
  display: block;
  height: 2px;
  overflow: hidden;
  background: rgba(237, 230, 216, 0.18);
}
.ek-quiz__balken span {
  position: absolute;
  inset: 0 auto 0 0;
  display: block;
  width: 20%;
  background: var(--color-accent-on-ink);
}
.ek-quiz__karte {
  min-height: 360px;
  padding: clamp(24px, 5vw, 40px);
  background: var(--color-bg);
  color: var(--color-text);
}
.ek-quiz__karte :focus-visible { outline-color: var(--color-primary); }
.ek-quiz__schritt > .ek-stapel { --gap: 24px; }
.ek-quiz__frage {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.3;
}
.ek-quiz__frage:focus { outline: none; }
.ek-quiz__wahl {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-height: 56px;
  padding: 20px 24px;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border-control);
  color: var(--color-text);
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}
.ek-quiz__wahl::after { content: "→"; color: var(--color-primary); }
.ek-quiz__wahl:hover {
  background: var(--color-bg-deep);
  border-color: var(--color-primary);
}
.ek-quiz__zurueck {
  align-self: flex-start;
  padding: 0;
  background: none;
  border: 0;
  color: var(--color-primary);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.ek-quiz__marke {
  align-self: flex-start;
  padding: 7px 12px;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.ek-quiz__ergebnis-titel {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(26px, 4.4vw, 36px);
  font-weight: 400;
  line-height: 1.1;
}
.ek-quiz__ergebnis-titel:focus { outline: none; }
.ek-quiz__karte p {
  margin: 0;
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--color-text-body);
}
.ek-quiz__karte .ek-quiz__hinweis {
  padding-top: 18px;
  border-top: 1px solid var(--color-border);
  font-size: 14.5px;
  color: var(--color-text-muted);
}
.ek-quiz__regeln {
  margin: 0;
  padding-left: 18px;
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text-body);
}
.ek-quiz__regeln li + li { margin-top: 10px; }
.ek-quiz button.ek-btn { font: inherit; font-size: 16px; font-weight: 600; }

/* ── Kontakt ── */

.ek-kontaktblock {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
}
.ek-kontaktblock .ek-eyebrow { font-size: 11px; letter-spacing: 0.18em; margin-bottom: 8px; }
.ek-kontaktblock__gross {
  font-family: var(--font-serif);
  font-size: clamp(24px, 3.6vw, 30px);
  overflow-wrap: anywhere;
}
.ek-kontaktblock p { margin: 0; font-size: 17px; line-height: 1.7; }
.ek-kontaktblock .ek-klein { margin-top: 6px; font-size: 15px; color: var(--color-text-body); }

/* ── Rechtsseiten (layouts/page.njk, .container.prose) ── */

.container.prose {
  max-width: 51.25rem;
  padding-block: clamp(32px, 6.5vw, 44px) clamp(56px, 7vw, 88px);
}
.prose h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(34px, 7vw, 56px);
  line-height: 1.08;
}
.prose h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(24px, 3.6vw, 30px);
}
.prose p,
.prose li { color: var(--color-text-body); line-height: 1.72; }

/* ── Fußzeile ── */

.ek-footer {
  background: var(--color-ink);
  color: var(--color-on-ink-muted);
}
.ek-footer__inner {
  display: flex;
  flex-direction: column;
  gap: clamp(32px, 4.5vw, 48px);
  padding-block: clamp(40px, 7vw, 64px) 32px;
}
.ek-footer__spalten {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
  gap: clamp(26px, 4vw, 40px);
}
.ek-footer__marke {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.ek-footer p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.85;
}
.ek-footer .ek-footer__name {
  font-family: var(--font-serif);
  font-size: 23px;
  line-height: 1.2;
  color: var(--color-on-ink-strong);
}
.ek-footer .ek-footer__leise { font-size: 13.5px; line-height: 1.8; color: var(--color-on-ink-subtle); }
.ek-footer h2 {
  margin: 0 0 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent-on-ink);
}
.ek-footer ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14.5px;
}
.ek-footer a {
  display: inline-block;
  padding-block: 3px;
  color: inherit;
  text-decoration: none;
}
.ek-footer a:hover { color: var(--color-on-ink-strong); text-decoration: underline; }
.ek-footer__unten {
  display: flex;
  justify-content: space-between;
  gap: 8px 24px;
  flex-wrap: wrap;
  padding-top: 22px;
  border-top: 1px solid rgba(246, 242, 234, 0.14);
}
.ek-footer .ek-footer__unten p { font-size: 13px; line-height: 1.6; color: var(--color-on-ink-subtle); }

/* ═══════════ PRINT ═══════════
   Impressum und Leistungen/Angebote werden ausgedruckt: Interaktives raus,
   externe Link-Ziele lesbar machen, Druckfarbe sparen. */

@media print {
  /* body > header / footer: trifft auch einen Projekt-Header ohne Engine-Klassen
     (src/_includes/projekt/); Artikel-Header liegen in <main> und bleiben. */
  .site-header,
  .cta-bar,
  .lead-form,
  .skip-link,
  .site-footer,
  body > header,
  body > footer {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
    hyphens: manual;
  }

  /* Externe Link-Ziele ausschreiben — interne Pfade wären nur Rauschen */
  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 0.875em;
    word-break: break-all;
  }

  h1, h2, h3 {
    break-after: avoid;
  }

  figure, blockquote, .card {
    break-inside: avoid;
  }
}

