/* Petersen Bau — Design-System
   Farben aus dem Firmenlogo: Anthrazit + Ziegelrot auf Beton-Grau.
   Typo: Barlow Condensed (Display) + Barlow (Text), selbst gehostet. */

@font-face {
  font-family: "Barlow";
  src: url("../fonts/barlow-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("../fonts/barlow-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("../fonts/barlow-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("../fonts/barlow-condensed-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("../fonts/barlow-condensed-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #22201d;
  --text: #3c3934;
  --muted: #6b665e;
  --paper: #f2f1ed;
  --panel: #e7e4dd;
  --line: #d3cfc6;
  --red: #a61a1a;
  --red-dark: #841313;
  --white: #fdfdfc;
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Barlow", "Segoe UI", sans-serif;
  --gutter: 16px;
  --maxw: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--paper);
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--red); }
a:hover { color: var(--red-dark); }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.08;
  margin: 0 0 0.4em;
}
h1 { font-size: clamp(2.4rem, 6vw, 4rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.35rem, 2.5vw, 1.7rem); font-weight: 600; }
p { margin: 0 0 1em; max-width: 68ch; }
ul { padding-left: 1.2em; }
li { margin-bottom: 0.35em; }

/* Die rote Fuge: Markenzeichen unter Abschnittsüberschriften */
.fuge {
  width: 64px;
  height: 7px;
  background: var(--red);
  border: 0;
  margin: 0 0 1.4rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { height: 52px; width: auto; mix-blend-mode: multiply; }
.main-nav { display: flex; align-items: center; gap: 26px; }
.main-nav a {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--ink);
  text-decoration: none;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--red); }
.main-nav a[aria-current="page"] { box-shadow: 0 3px 0 var(--red); }

.btn {
  display: inline-block;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.15rem;
  text-decoration: none;
  padding: 10px 22px;
  border: 2px solid var(--red);
  color: var(--red);
  background: transparent;
  cursor: pointer;
}
.btn:hover { background: var(--red); color: var(--white); }
.btn-solid { background: var(--red); color: var(--white); }
.btn-solid:hover { background: var(--red-dark); border-color: var(--red-dark); color: var(--white); }
.btn-light { border-color: var(--white); color: var(--white); }
.btn-light:hover { background: var(--white); color: var(--ink); }

.nav-toggle {
  display: none;
  background: none;
  border: 2px solid var(--ink);
  padding: 6px 10px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1rem;
  color: var(--ink);
  cursor: pointer;
}

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .main-nav {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--paper);
    border-bottom: 2px solid var(--red);
  }
  .main-nav.open { display: flex; }
  .main-nav a {
    padding: 14px var(--gutter);
    border-top: 1px solid var(--line);
  }
  .main-nav a[aria-current="page"] { box-shadow: inset 4px 0 0 var(--red); }
  .main-nav .btn { border: 0; background: var(--red); color: var(--white); margin: 0; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: var(--white);
  background: var(--ink);
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}
.hero .wrap {
  position: relative;
  padding-top: clamp(64px, 12vw, 140px);
  padding-bottom: clamp(64px, 12vw, 140px);
}
.hero h1 { color: var(--white); max-width: 15em; }
.hero p {
  font-size: 1.2rem;
  max-width: 46ch;
  color: #eceae6;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 1.6rem; }

/* Faktenleiste unter dem Hero */
.facts {
  background: var(--ink);
  color: #dcd9d3;
  border-top: 1px solid #3a3733;
}
.facts .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 0;
  padding-top: 18px;
  padding-bottom: 18px;
}
.facts span {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.1rem;
  padding-right: 22px;
  margin-right: 22px;
  border-right: 5px solid var(--red);
}
.facts span:last-child { border-right: 0; margin-right: 0; padding-right: 0; }
@media (max-width: 640px) {
  .facts span { border-right: 0; border-left: 5px solid var(--red); padding: 0 0 0 12px; margin: 0; width: 100%; }
}

/* ---------- Sektionen ---------- */
.section { padding: clamp(48px, 8vw, 88px) 0; }
.section-panel { background: var(--panel); }
.section-dark { background: var(--ink); color: #dcd9d3; }
.section-dark h2, .section-dark h3 { color: var(--white); }
.section-dark p { color: #cfccc5; }

.kicker {
  font-weight: 700;
  color: var(--red);
  margin-bottom: 0.3rem;
  font-size: 1rem;
}

/* Leistungs-Kacheln */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 22px;
  margin-top: 1.6rem;
}
.tile {
  background: var(--white);
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
}
.tile img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.tile-body { padding: 18px 20px 22px; border-top: 5px solid var(--red); }
.tile h3 { margin-bottom: 0.3em; }
.tile p { margin: 0; font-size: 0.98rem; }
.tile:hover h3 { color: var(--red); }

/* Ablauf-Schritte (echte Sequenz) */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 26px; margin-top: 1.6rem; counter-reset: step; }
.step { border-top: 5px solid var(--red); padding-top: 14px; }
.step::before {
  counter-increment: step;
  content: counter(step) ".";
  font-family: var(--display);
  font-weight: 700;
  font-size: 2rem;
  color: var(--red);
  display: block;
  line-height: 1;
  margin-bottom: 6px;
}
.step h3 { margin-bottom: 0.25em; }
.step p { margin: 0; font-size: 0.98rem; }

/* Zweispaltiges Text/Bild-Layout */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.split img { border-top: 6px solid var(--red); }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } }

/* Leistungslisten */
.checklist { list-style: none; padding: 0; column-gap: 40px; }
.checklist li { padding-left: 26px; position: relative; margin-bottom: 0.5em; }
.checklist li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.48em;
  width: 12px; height: 7px;
  background: var(--red);
}
@media (min-width: 640px) { .checklist.cols { columns: 2; } }

/* Galerie */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 1.2rem;
}
.gallery a { display: block; background: var(--panel); }
.gallery img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.gallery a:hover img { opacity: 0.85; }

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(24, 22, 20, 0.94);
  display: none;
  align-items: center;
  justify-content: center;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: min(92vw, 1100px); max-height: 86vh; width: auto; }
.lightbox button {
  position: absolute;
  background: none;
  border: 0;
  color: var(--white);
  font-size: 2.4rem;
  line-height: 1;
  padding: 16px;
  cursor: pointer;
  font-family: var(--body);
}
.lightbox .lb-close { top: 8px; right: 12px; }
.lightbox .lb-prev { left: 4px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: 4px; top: 50%; transform: translateY(-50%); }

/* CTA-Band */
.cta-band { background: var(--red); color: var(--white); }
.cta-band .wrap {
  padding-top: clamp(40px, 6vw, 64px);
  padding-bottom: clamp(40px, 6vw, 64px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}
.cta-band h2 { color: var(--white); margin: 0; }
.cta-band p { color: #f4dede; margin: 0.4em 0 0; }
.cta-band .btn-light:hover { color: var(--red); }

/* Kontakt */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 44px; }
@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-card { font-style: normal; }
.contact-card strong { font-family: var(--display); font-size: 1.2rem; font-weight: 600; color: var(--ink); }
.contact-card a { color: var(--ink); }
.contact-card .big {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.7rem;
  color: var(--red);
  text-decoration: none;
}

form .field { margin-bottom: 16px; }
form label { display: block; font-weight: 500; color: var(--ink); margin-bottom: 4px; }
form input, form textarea {
  width: 100%;
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--text);
}
form input:focus, form textarea:focus { border-color: var(--red); outline: none; }
.form-note { font-size: 0.92rem; color: var(--muted); }

/* Tabellenartige Aufzählungen (Einzugsgebiet) */
.area-list { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.area-list li {
  background: var(--white);
  border: 1px solid var(--line);
  border-left: 5px solid var(--red);
  padding: 6px 14px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--ink);
  margin: 0;
}

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #b5b1a9; font-size: 0.95rem; }
.site-footer .wrap { padding-top: 56px; padding-bottom: 32px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.site-footer h3 { color: var(--white); font-size: 1.2rem; }
.site-footer a { color: #dcd9d3; text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.footer-legal {
  border-top: 1px solid #3a3733;
  margin-top: 40px;
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
}
.footer-legal nav { display: flex; gap: 20px; }

/* Unterseiten-Kopf */
.page-head { background: var(--panel); border-bottom: 1px solid var(--line); }
.page-head .wrap { padding-top: clamp(40px, 7vw, 72px); padding-bottom: clamp(40px, 7vw, 72px); }
.page-head p { font-size: 1.15rem; max-width: 60ch; margin-bottom: 0; }

/* Rechtstexte */
.legal h2 { font-size: 1.5rem; margin-top: 2em; }
.legal .wrap { max-width: 800px; }

.skip-link {
  position: absolute;
  left: -9999px;
  background: var(--red);
  color: var(--white);
  padding: 10px 16px;
  z-index: 200;
}
.skip-link:focus { left: 8px; top: 8px; }
