/* ==========================================================================
   MJ Bauelemente GmbH
   Farben aus der Schaufenster-Folie: Signalrot E4180C, Anthrazit RAL 7016.
   Schrift: Archivo (variabel, Breite 62–125 %), selbst gehostet.
   ========================================================================== */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  src: url("../fonts/archivo-var.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  src: url("../fonts/archivo-var-ext.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --red: #E4180C;
  --red-dark: #B8130A;
  --anthracite: #383E42;
  --anthracite-deep: #2A2F32;
  --ink: #1F2326;
  --steel: #5F676C;
  --glass: #E8EDEF;
  --glass-line: #CBD3D7;
  --white: #FFFFFF;

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --wide: 125%;
  --semi-wide: 112%;
  --narrow: 75%;

  --gutter: clamp(16px, 4vw, 40px);
  --max: 1240px;
  --section: clamp(4rem, 9vw, 7.5rem);
  --frame: clamp(10px, 1.4vw, 16px);
  --header-h: 76px;

  --ease-out: cubic-bezier(.22, 1, .36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-stretch: 100%;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
/* Unscharfer Platzhalter, bis das Bild geladen ist (siehe img() in inc/bootstrap.php).
   color: transparent blendet den Alt-Text während des Ladens aus; Screenreader lesen ihn weiter. */
.has-lqip {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: transparent;
}
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.1; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
ul, ol { margin: 0; padding: 0; }
button { font: inherit; color: inherit; }

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
}

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

.skip-link {
  position: absolute;
  left: 16px; top: -60px;
  z-index: 100;
  padding: .7rem 1rem;
  background: var(--red);
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* --- Typografie ----------------------------------------------------------- */

/* Lange deutsche Komposita ("Terrassenüberdachungen") in der breiten Schrift: Getrennt wird
   nur an festen weichen Trennstellen (&shy; in inc/services.php). Bewusst kein hyphens: auto,
   das trennt mit deutschem Wörterbuch auch Wörter, die in die nächste Zeile passen würden
   ("Leis-tungen"). overflow-wrap ist nur die Notbremse gegen Überlauf hinter das Bild. */
h1, h2, h3 {
  hyphens: manual;
  overflow-wrap: break-word;
}

.section-title {
  font-size: clamp(1.9rem, 3.6vw, 2.9rem);
  font-stretch: var(--wide);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1.05;
  margin-bottom: 1.25rem;
  color: var(--anthracite);
}
.section-title--light { color: var(--white); }

/* Rote Linie wie auf der Schaufenster-Folie */
.rule {
  display: block;
  width: 72px;
  height: 6px;
  background: var(--red);
  border: 0;
  margin: 0 0 1.5rem;
}

/* --- Buttons -------------------------------------------------------------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  min-height: 52px;
  padding: .8rem 1.5rem;
  border: 2px solid transparent;
  font-weight: 700;
  font-stretch: var(--semi-wide);
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--ease-out);
}
.button:active { transform: translateY(1px); }

.button--red { background: var(--red); color: var(--white); }
.button--red:hover { background: var(--red-dark); }

.button--outline { border-color: var(--anthracite); color: var(--anthracite); }
.button--outline:hover { background: var(--anthracite); color: var(--white); }

.button--white { background: var(--white); color: var(--red); }
.button--white:hover { background: var(--anthracite); color: var(--white); }

.button--ghost-light { border-color: rgba(255, 255, 255, .7); color: var(--white); }
.button--ghost-light:hover { background: var(--white); color: var(--red); border-color: var(--white); }

/* --- Header --------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--glass-line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.brand__mark { width: auto; height: 46px; }
.brand__word { width: auto; height: 34px; }
.l-red { fill: var(--red); }
.l-text { fill: var(--anthracite); }
.brand--light .l-text { fill: var(--white); }

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 2.25rem);
}

.site-nav__list {
  display: flex;
  align-items: center;
  gap: clamp(.25rem, 1.4vw, 1.25rem);
  list-style: none;
}

.site-nav__item { position: relative; }

.site-nav__link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .6rem .5rem;
  background: none;
  border: 0;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  color: var(--anthracite);
  cursor: pointer;
  position: relative;
}
.site-nav__link::after {
  content: "";
  position: absolute;
  left: .5rem; right: .5rem; bottom: .25rem;
  height: 3px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s var(--ease-out);
}
.site-nav__link:hover::after,
.site-nav__link.is-active::after { transform: scaleX(1); }

.site-nav__subtoggle::before {
  content: "";
  order: 2;
  width: 7px; height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform .2s;
}
.site-nav__subtoggle[aria-expanded="true"]::before { transform: translateY(1px) rotate(-135deg); }

.site-nav__sub {
  list-style: none;
  position: absolute;
  top: calc(100% + 10px);
  left: -1rem;
  min-width: 270px;
  padding: .75rem 0;
  background: var(--anthracite);
  border-top: 4px solid var(--red);
  box-shadow: 0 18px 40px rgba(31, 35, 38, .22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .18s, transform .18s var(--ease-out), visibility 0s .18s;
}
.has-sub.is-open .site-nav__sub {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity .18s, transform .18s var(--ease-out), visibility 0s;
}
.site-nav__sub a {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .55rem 1.25rem;
  color: var(--white);
  text-decoration: none;
  font-weight: 500;
}
.site-nav__sub a { white-space: nowrap; }
/* Quadrat wird per scaleX zum Balken – ohne Layoutverschiebung, damit kein Zeilenumbruch entsteht */
.site-nav__sub a::before {
  content: "";
  width: 8px; height: 8px;
  background: var(--red);
  flex-shrink: 0;
  transform-origin: left center;
  transition: transform .2s var(--ease-out);
}
.site-nav__sub a:hover::before,
.site-nav__sub a[aria-current="page"]::before { transform: scaleX(2.25); }
.site-nav__sub a:hover { background: rgba(255, 255, 255, .06); }

.call-button {
  display: inline-flex;
  flex-direction: column;
  padding: .4rem 0 .4rem 1rem;
  border-left: 4px solid var(--red);
  color: var(--anthracite);
  text-decoration: none;
  line-height: 1.15;
  transition: color .2s;
}
.call-button:hover { color: var(--red); }
.call-button__label { font-size: .78rem; font-weight: 600; color: var(--steel); }
.call-button__number { font-size: 1.05rem; font-weight: 800; font-stretch: var(--semi-wide); font-variant-numeric: tabular-nums; }

.nav-toggle {
  display: none;
  width: 48px; height: 48px;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
  position: relative;
}
.nav-toggle__bars,
.nav-toggle__bars::before,
.nav-toggle__bars::after {
  position: absolute;
  left: 11px;
  width: 26px; height: 3px;
  background: var(--anthracite);
  transition: transform .25s var(--ease-out), opacity .2s;
}
.nav-toggle__bars { top: 50%; margin-top: -1.5px; }
.nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; left: 0; }
.nav-toggle__bars::before { top: -8px; }
.nav-toggle__bars::after { top: 8px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 1080px) {
  :root { --header-h: 68px; }
  .brand__mark { height: 40px; }
  .brand__word { height: 29px; }

  .nav-toggle { display: block; }

  .site-nav {
    position: fixed;
    inset: var(--header-h) 0 0 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2rem;
    padding: 1.5rem var(--gutter) 2.5rem;
    background: var(--anthracite);
    overflow-y: auto;
    visibility: hidden;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity .2s, transform .25s var(--ease-out), visibility 0s .25s;
  }
  .site-nav.is-open {
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: opacity .2s, transform .25s var(--ease-out), visibility 0s;
  }
  .site-nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .site-nav__item { border-bottom: 1px solid rgba(255, 255, 255, .12); }
  .site-nav__link {
    width: 100%;
    justify-content: space-between;
    padding: 1rem 0;
    color: var(--white);
    font-size: 1.35rem;
    font-stretch: var(--semi-wide);
  }
  .site-nav__link::after { display: none; }
  .site-nav__link.is-active { color: #FF8A82; }
  .site-nav__sub {
    position: static;
    min-width: 0;
    padding: 0 0 1rem;
    border: 0;
    box-shadow: none;
    background: none;
    transform: none;
    display: none;
    opacity: 1;
    visibility: visible;
  }
  .has-sub.is-open .site-nav__sub { display: block; }
  .site-nav__sub a { padding: .55rem 0; font-size: 1.05rem; }
  .call-button { align-self: flex-start; color: var(--white); }
  .call-button__label { color: #CDD3D6; font-size: .9rem; }
  .call-button__number { font-size: 1.5rem; }
  body.nav-open { overflow: hidden; }
}

/* --- Bildrahmen: schmale rote Kontur --------------------------------------- */

.window {
  position: relative;
  margin: 0;
  border: 3px solid var(--red);
  box-shadow: 0 30px 60px -30px rgba(31, 35, 38, .45);
}
.window__pane {
  position: relative;
  overflow: hidden;
  background: var(--glass);
}
.window__pane img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.window--hero .window__pane { aspect-ratio: 5 / 4; }
.window--small .window__pane { aspect-ratio: 4 / 3; }

/* Leeres Glas mit Spiegelungsstrichen wie im Logo */
.window__glass {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(125deg, transparent 58%, rgba(255, 255, 255, .9) 58.3%, rgba(255, 255, 255, .9) 59.6%, transparent 60%),
    linear-gradient(125deg, transparent 63%, rgba(255, 255, 255, .9) 63.3%, rgba(255, 255, 255, .9) 64.4%, transparent 64.8%),
    linear-gradient(125deg, transparent 68%, rgba(255, 255, 255, .9) 68.3%, rgba(255, 255, 255, .9) 69%, transparent 69.4%),
    linear-gradient(160deg, #DCE4E7, #F1F4F5 60%, #E2E8EA);
}

/* --- Hero ------------------------------------------------------------------ */

/* Hintergrundbild steht fest (background-attachment: fixed), Text und Fenster scrollen darüber */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: min(calc(100vh - var(--header-h)), 700px);
  padding: clamp(2.5rem, 4.5vw, 4rem) 0 clamp(3rem, 5vw, 4.75rem);
  overflow: hidden;
  color: var(--white);
  background-color: var(--anthracite-deep);
  background-image:
    linear-gradient(90deg, rgba(31, 35, 38, .94) 0%, rgba(31, 35, 38, .82) 38%, rgba(31, 35, 38, .45) 70%, rgba(31, 35, 38, .25) 100%),
    url("../img/wintergaerten-terrassendaecher-uebersicht-1600.webp");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
/* Roter Streifen an der Unterkante als Übergang */
.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 8px;
  background: var(--red);
}
.hero > .wrap { width: 100%; }

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

.hero__title {
  font-size: clamp(2.5rem, 5.6vw, 4.9rem);
  font-stretch: var(--wide);
  font-weight: 800;
  line-height: .98;
  letter-spacing: -.02em;
  color: var(--white);
  text-shadow: 0 2px 24px rgba(0, 0, 0, .25);
  margin-bottom: 1.75rem;
  text-wrap: balance;
}
.hero__title::after {
  content: "";
  display: block;
  width: 96px;
  height: 7px;
  margin-top: 1.75rem;
  background: var(--red);
}
.hero__lead {
  max-width: 34rem;
  font-size: clamp(1.1rem, 1.4vw, 1.25rem);
  line-height: 1.55;
  color: #D5DBDE;
  margin-bottom: 2rem;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.hero .window { box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .7); }

.hero__visual {
  position: relative;
  padding-top: 2.5rem;
}

/* Der rote Aufkleber aus dem Schaufenster */
.sticker {
  position: absolute;
  top: 0;
  left: clamp(-2.5rem, -3vw, -1rem);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: .9rem 1.4rem 1rem;
  background: var(--red);
  color: var(--white);
  text-decoration: none;
  line-height: 1.1;
  transform: rotate(-6deg);
  box-shadow: 0 14px 30px -12px rgba(120, 10, 4, .55);
  overflow: hidden;
  /* "backwards" statt "both": nach dem Aufkleben gilt wieder das normale transform, sonst greift kein Hover */
  animation: sticker-on .7s .35s var(--ease-out) backwards;
  transition: transform .4s cubic-bezier(.34, 1.56, .64, 1), box-shadow .4s var(--ease-out), background-color .25s;
}
/* Lichtreflex, der beim Überfahren über den Aufkleber wischt */
.sticker::after {
  content: "";
  position: absolute;
  inset: -20% 0;
  background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, .5) 48%, rgba(255, 255, 255, .5) 52%, transparent 70%);
  transform: translateX(-130%);
  pointer-events: none;
}
.sticker:hover,
.sticker:focus-visible {
  transform: rotate(-1.5deg) translateY(-5px) scale(1.06);
  box-shadow: 0 24px 40px -14px rgba(120, 10, 4, .7);
}
.sticker:hover::after,
.sticker:focus-visible::after {
  transform: translateX(130%);
  transition: transform .7s var(--ease-out);
}
.sticker:active {
  transform: rotate(-1.5deg) translateY(-2px) scale(1.02);
  background: var(--red-dark);
  transition-duration: .1s;
}
.sticker__top {
  font-size: clamp(.85rem, 1.2vw, 1.05rem);
  font-weight: 800;
  font-stretch: var(--wide);
  letter-spacing: .06em;
}
.sticker__cta {
  font-size: clamp(1.25rem, 2.1vw, 1.8rem);
  font-weight: 800;
  font-stretch: var(--semi-wide);
  letter-spacing: .01em;
}
.sticker__number {
  font-size: clamp(1.35rem, 2.3vw, 2rem);
  font-weight: 800;
  font-stretch: var(--semi-wide);
  font-variant-numeric: tabular-nums;
  letter-spacing: .01em;
}

@keyframes sticker-on {
  0% { opacity: 0; transform: translate(-14px, -18px) rotate(-16deg) scale(1.18); }
  70% { opacity: 1; transform: rotate(-4.5deg) scale(.98); }
  100% { opacity: 1; transform: rotate(-6deg) scale(1); }
}

/* Touch-Geräte (v. a. iOS) können kein fixes Hintergrundbild – dort scrollt es normal mit */
@media (hover: none), (max-width: 860px), (prefers-reduced-motion: reduce) {
  .hero { background-attachment: scroll; }
}

@media (max-width: 860px) {
  .hero {
    min-height: 0;
    background-image:
      linear-gradient(180deg, rgba(31, 35, 38, .9) 0%, rgba(31, 35, 38, .78) 55%, rgba(31, 35, 38, .55) 100%),
      url("../img/wintergaerten-terrassendaecher-uebersicht-960.webp");
  }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { padding-top: 1.75rem; }
  .sticker { left: -6px; }
}

/* --- Leistungen ------------------------------------------------------------ */

.services {
  padding: var(--section) 0;
  background: var(--glass);
}
.services__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: start;
}
.services__intro {
  position: sticky;
  top: calc(var(--header-h) + 2rem);
}
.services__intro > p { max-width: 30rem; color: var(--steel); }
.services__preview { margin-top: 2rem; max-width: 420px; }
.services__preview .window__pane { background: var(--anthracite); }
.services__preview-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .35s ease;
}
.services__preview-img.is-visible { opacity: 1; }

.service-list { list-style: none; border-top: 2px solid var(--anthracite); }
.service-list li { border-bottom: 1px solid var(--glass-line); }
.service-list__link {
  display: grid;
  grid-template-columns: 18px 1fr;
  column-gap: 1rem;
  padding: .85rem 0;
  text-decoration: none;
  position: relative;
}
/* Rotes Quadrat wie auf der Folie; wird beim Überfahren zum Balken */
.service-list__link::before {
  content: "";
  grid-row: 1;
  align-self: center;
  width: 13px; height: 13px;
  background: var(--red);
  transition: width .3s var(--ease-out);
}
.service-list__name {
  font-size: clamp(1.15rem, 1.7vw, 1.4rem);
  font-weight: 750;
  font-stretch: var(--semi-wide);
  color: var(--anthracite);
  line-height: 1.15;
  transition: color .2s, transform .3s var(--ease-out);
}
.service-list__teaser {
  grid-column: 2;
  margin-top: .15rem;
  color: var(--steel);
  font-size: .95rem;
  line-height: 1.45;
  max-width: 36rem;
}
.service-list__link:hover::before,
.service-list__link:focus-visible::before { width: 28px; }
.service-list__link:hover .service-list__name,
.service-list__link:focus-visible .service-list__name { color: var(--red); transform: translateX(15px); }
.service-list__link:hover .service-list__teaser,
.service-list__link:focus-visible .service-list__teaser { transform: translateX(15px); }
.service-list__teaser { transition: transform .3s var(--ease-out); }

@media (max-width: 860px) {
  .services__grid { grid-template-columns: 1fr; }
  .services__intro { position: static; }
  .services__preview { display: none; }
}

/* --- Projekte / Galerie ---------------------------------------------------- */

.projects { padding: var(--section) 0; }
.projects__head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 2rem;
  align-items: end;
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
}
.projects__head .section-title { margin-bottom: 0; }
.projects__head p { color: var(--steel); max-width: 32rem; justify-self: end; }

.gallery {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: clamp(1rem, 2vw, 1.75rem);
  row-gap: clamp(2rem, 4vw, 3rem);
}
.gallery__item figure { margin: 0; }
.gallery__open {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: var(--glass);
  cursor: zoom-in;
  overflow: hidden;
  position: relative;
}
.gallery__open img {
  width: 100%;
  height: var(--h, 380px);
  object-fit: cover;
  transition: transform .6s var(--ease-out);
}
/* Rahmenecke in Rot, erscheint beim Überfahren */
.gallery__open::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 0 solid var(--red);
  transition: border-width .25s var(--ease-out);
  pointer-events: none;
}
.gallery__open:hover img { transform: scale(1.035); }
.gallery__open:hover::after,
.gallery__open:focus-visible::after { border-width: 6px; }

.gallery figcaption {
  display: grid;
  grid-template-columns: 1fr auto;
  column-gap: 1rem;
  padding-top: 1rem;
}
.gallery__title {
  font-size: 1.2rem;
  font-weight: 750;
  font-stretch: var(--semi-wide);
  color: var(--anthracite);
}
.gallery__text {
  grid-column: 1 / -1;
  grid-row: 2;
  margin-top: .4rem;
  color: var(--steel);
  font-size: .98rem;
  max-width: 40rem;
}
.gallery__tag {
  grid-column: 2;
  grid-row: 1;
  align-self: start;
  font-size: .85rem;
  font-weight: 700;
  color: var(--red);
  text-decoration: none;
  border-bottom: 2px solid currentColor;
  white-space: nowrap;
}
.gallery__tag:hover { color: var(--anthracite); }

/* Asymmetrisches Raster: 7/5, 4/4/4, 5/7 */
.gallery__item--1 { grid-column: span 7; --h: 460px; }
.gallery__item--2 { grid-column: span 5; --h: 460px; }
.gallery__item--3 { grid-column: span 4; --h: 300px; }
.gallery__item--4 { grid-column: span 4; --h: 300px; }
.gallery__item--5 { grid-column: span 4; --h: 300px; }
.gallery__item--6 { grid-column: span 5; --h: 400px; }
.gallery__item--7 { grid-column: span 7; --h: 400px; }
.gallery__item--2 img, .gallery__item--4 img { object-position: center 35%; }

@media (max-width: 960px) {
  .gallery__item--1, .gallery__item--7 { grid-column: span 12; --h: 380px; }
  .gallery__item--2, .gallery__item--3, .gallery__item--4,
  .gallery__item--5, .gallery__item--6 { grid-column: span 6; --h: 300px; }
}
@media (max-width: 640px) {
  .projects__head { grid-template-columns: 1fr; gap: 0; }
  .projects__head p { justify-self: start; margin-top: 1rem; }
  .gallery { row-gap: 2.25rem; }
  .gallery__item { grid-column: span 12 !important; }
  .gallery__open img { height: auto; aspect-ratio: 4 / 3; }
}

/* Lightbox */
.lightbox {
  width: min(1100px, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  padding: 0;
  border: 0;
  background: transparent;
  overflow: visible;
}
.lightbox::backdrop { background: rgba(31, 35, 38, .86); }
.lightbox[open] { animation: lightbox-in .3s var(--ease-out); }
.lightbox__frame {
  position: relative;
  padding: var(--frame);
  background: var(--anthracite);
}
.lightbox__img {
  width: 100%;
  max-height: calc(100vh - 14rem);
  object-fit: contain;
  background: var(--anthracite-deep);
}
.lightbox__caption {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: .4rem 1.5rem;
  padding: 1.1rem .4rem .4rem;
  color: var(--white);
}
.lightbox__title { font-size: 1.25rem; font-stretch: var(--semi-wide); font-weight: 750; }
.lightbox__text { grid-column: 1; margin: 0; color: #CDD3D6; max-width: 60ch; }
.lightbox__link {
  grid-column: 2; grid-row: 1 / span 2;
  align-self: center;
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid var(--red);
}
.lightbox__close {
  position: absolute;
  top: -14px; right: -10px;
  padding: .55rem 1rem;
  background: var(--red);
  border: 0;
  color: var(--white);
  font-weight: 700;
  cursor: pointer;
  transform: rotate(3deg);
}
.lightbox__close:hover { background: var(--red-dark); }
@keyframes lightbox-in { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }

@media (max-width: 640px) {
  .lightbox__caption { grid-template-columns: 1fr; }
  .lightbox__link { grid-column: 1; grid-row: auto; justify-self: start; margin-top: .5rem; }
}

/* --- Ablauf ---------------------------------------------------------------- */

.process {
  padding: var(--section) 0;
  background: var(--anthracite);
  color: var(--white);
}
.process__intro { color: #CDD3D6; max-width: 36rem; margin-bottom: clamp(2.5rem, 5vw, 4rem); font-size: 1.1rem; }
.process__steps {
  list-style: none;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.5rem, 3vw, 2.5rem);
}
.process__steps li {
  counter-increment: step;
  position: relative;
  padding-top: 4.75rem;
  border-top: 2px solid rgba(255, 255, 255, .18);
}
/* Fortschrittsbalken in Rot über jedem Schritt */
.process__steps li::after {
  content: "";
  position: absolute;
  top: -2px; left: 0;
  height: 2px;
  width: calc(25% * var(--step, 1));
  background: var(--red);
}
.process__steps li:nth-child(1) { --step: 1; }
.process__steps li:nth-child(2) { --step: 2; }
.process__steps li:nth-child(3) { --step: 3; }
.process__steps li:nth-child(4) { --step: 4; }
.process__steps li::before {
  content: counter(step);
  position: absolute;
  top: 1.25rem; left: 0;
  display: grid;
  place-items: center;
  width: 2.5rem; height: 2.5rem;
  background: var(--red);
  font-weight: 800;
  font-stretch: var(--wide);
  font-size: 1.15rem;
}
.process__steps h3 {
  font-size: 1.4rem;
  font-stretch: var(--wide);
  font-weight: 800;
  margin-bottom: .75rem;
}
.process__steps p { color: #CDD3D6; font-size: 1rem; }

@media (max-width: 960px) {
  .process__steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 3rem; }
}
@media (max-width: 560px) {
  .process__steps { grid-template-columns: 1fr; }
}

/* --- Über uns & Öffnungszeiten --------------------------------------------- */

.about { padding: var(--section) 0; }
.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}
.about__text p { max-width: 38rem; font-size: 1.1rem; }
.about__area { color: var(--steel); font-size: 1rem !important; margin-top: 1.75rem; }
.about__area strong { color: var(--anthracite); }

/* Öffnungszeiten wie auf der Eingangstür-Folie */
.hours-panel {
  background: var(--anthracite);
  color: var(--white);
  padding: 2.25rem 2rem 2rem;
  border-top: 8px solid var(--red);
  border-bottom: 8px solid var(--red);
  text-align: center;
}
.hours-panel__title {
  font-size: 1.15rem;
  font-weight: 800;
  font-stretch: var(--wide);
  letter-spacing: .08em;
}
.hours-panel__title::after {
  content: "";
  display: block;
  width: 64px; height: 4px;
  margin: .9rem auto 1.25rem;
  background: var(--red);
}
.hours { margin: 0; }
.hours div + div { margin-top: 1rem; }
.hours dt { font-size: .95rem; font-stretch: var(--wide); letter-spacing: .06em; color: #CDD3D6; }
.hours dd {
  margin: 0;
  font-size: clamp(1.6rem, 2.6vw, 2.1rem);
  font-weight: 800;
  font-stretch: var(--semi-wide);
  font-variant-numeric: tabular-nums;
}
.hours-panel__note { margin-top: 1.5rem; font-size: .95rem; color: #CDD3D6; }
.hours-panel__note a { color: var(--white); font-weight: 700; white-space: nowrap; }

.hours--compact div { display: flex; gap: .75rem; justify-content: space-between; }
.hours--compact div + div { margin-top: .4rem; }
.hours--compact dt { font-stretch: 100%; letter-spacing: 0; font-size: 1rem; }
.hours--compact dd { font-size: 1rem; font-weight: 600; font-stretch: 100%; }

@media (max-width: 860px) {
  .about__grid { grid-template-columns: 1fr; }
}

/* --- CTA -------------------------------------------------------------------- */

.cta {
  background: var(--red);
  color: var(--white);
  padding: clamp(3.5rem, 7vw, 5.5rem) 0;
  position: relative;
  overflow: hidden;
}
/* Fensterkreuz als Wasserzeichen */
.cta::before {
  content: "";
  position: absolute;
  right: -40px; top: 50%;
  width: 360px; height: 420px;
  transform: translateY(-50%) rotate(-6deg);
  border: 22px solid rgba(255, 255, 255, .12);
  background:
    linear-gradient(rgba(255, 255, 255, .12), rgba(255, 255, 255, .12)) center / 20px 100% no-repeat,
    linear-gradient(rgba(255, 255, 255, .12), rgba(255, 255, 255, .12)) 0 34% / 100% 20px no-repeat;
}
.cta__inner { position: relative; }
.cta__title {
  font-size: clamp(1.9rem, 4vw, 3.2rem);
  font-weight: 800;
  font-stretch: var(--wide);
  line-height: 1.05;
  letter-spacing: -.01em;
  max-width: 18ch;
  margin-bottom: 1.25rem;
}
.cta__text { max-width: 36rem; font-size: 1.1rem; margin-bottom: 2rem; }
.cta__actions { display: flex; flex-wrap: wrap; gap: .75rem; }

/* --- Footer ----------------------------------------------------------------- */

.site-footer {
  background: var(--anthracite-deep);
  color: #CDD3D6;
  padding: clamp(3.5rem, 6vw, 5rem) 0 0;
  font-size: .98rem;
}
.site-footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr));
  gap: 2.5rem;
  padding-bottom: 3rem;
}
.site-footer__brand p { margin-top: 1.25rem; max-width: 22rem; }
.site-footer__title {
  font-size: 1rem;
  font-weight: 800;
  font-stretch: var(--wide);
  color: var(--white);
  margin-bottom: 1rem;
}
.site-footer ul { list-style: none; }
.site-footer li + li { margin-top: .35rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; text-decoration-color: var(--red); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.site-footer address { font-style: normal; margin-bottom: 1rem; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, .12);
  font-size: .9rem;
}
.site-footer__bottom ul { display: flex; gap: 1.5rem; }
.site-footer__bottom li + li { margin-top: 0; }

@media (max-width: 960px) {
  .site-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .site-footer__grid { grid-template-columns: 1fr; }
}

/* --- Unterseiten: Seitenkopf ------------------------------------------------ */

.breadcrumb {
  padding-top: 1.5rem;
  font-size: .9rem;
  color: var(--steel);
}
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; }
.breadcrumb li + li::before { content: "/"; margin-right: .5rem; color: var(--glass-line); }
.breadcrumb a { text-decoration: none; }
.breadcrumb a:hover { color: var(--red); }

.page-hero {
  position: relative;
  padding: clamp(1.5rem, 4vw, 3rem) 0 clamp(3rem, 7vw, 5.5rem);
  overflow: hidden;
}
.page-hero::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  left: 62%; right: 0;
  background: var(--glass);
  z-index: -1;
}
.page-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.page-hero__title {
  font-size: clamp(2rem, 3.8vw, 3.4rem);
  font-weight: 800;
  font-stretch: var(--wide);
  line-height: 1.04;
  letter-spacing: -.015em;
  color: var(--anthracite);
  margin-bottom: 1.5rem;
  text-wrap: balance;
}
.page-hero__title::after {
  content: "";
  display: block;
  width: 80px; height: 6px;
  margin-top: 1.5rem;
  background: var(--red);
}
.page-hero__lead {
  max-width: 36rem;
  font-size: clamp(1.08rem, 1.3vw, 1.2rem);
  color: var(--steel);
  margin-bottom: 2rem;
}
.page-hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; }
.page-hero .window__pane { aspect-ratio: 4 / 3.4; }
.page-hero .window--portrait .window__pane { aspect-ratio: 4 / 4.6; }

@media (max-width: 860px) {
  .page-hero::before { left: 0; top: auto; height: 40%; }
  .page-hero__grid { grid-template-columns: 1fr; }
}

/* Schlichter Seitenkopf (Kontakt, Rechtliches) */
.page-head { padding: clamp(1.5rem, 4vw, 3rem) 0 clamp(2rem, 4vw, 3rem); }
.page-head .page-hero__title { margin-bottom: 1.25rem; }

/* --- Unterseiten: Inhalt ---------------------------------------------------- */

.detail { padding: var(--section) 0; }
.detail__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(2rem, 6vw, 6rem);
}
.detail__intro p { font-size: 1.1rem; max-width: 36rem; }
.detail__quote {
  margin: 2rem 0 0;
  padding-left: 1.25rem;
  border-left: 6px solid var(--red);
  font-size: clamp(1.3rem, 2vw, 1.6rem);
  font-weight: 700;
  font-stretch: var(--semi-wide);
  line-height: 1.25;
  color: var(--anthracite);
}

.offer-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem 2.5rem;
  border-top: 2px solid var(--anthracite);
  padding-top: 2rem;
}
/* Quadrat absolut statt Flexbox: Flex-Text darf nicht schmaler als das längste Wort werden
   und liefe dann über die Spalte hinaus; so greift die Silbentrennung. */
.offer-list h3 {
  position: relative;
  padding-left: calc(12px + .75rem);
  font-size: 1.15rem;
  font-weight: 750;
  font-stretch: var(--semi-wide);
  color: var(--anthracite);
  margin-bottom: .45rem;
}
.offer-list h3::before {
  content: "";
  position: absolute;
  left: 0; top: .4em;
  width: 12px; height: 12px;
  background: var(--red);
}
.offer-list p { color: var(--steel); font-size: 1rem; padding-left: calc(12px + .75rem); }

@media (max-width: 860px) {
  .detail__grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .offer-list { grid-template-columns: 1fr; }
}

.detail-gallery { padding: 0 0 var(--section); }
.detail-gallery__list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: clamp(1rem, 2vw, 1.75rem);
}
.detail-gallery figure { margin: 0; }
.detail-gallery .gallery__open img { height: 320px; }
.detail-gallery figcaption { padding-top: .8rem; color: var(--steel); font-size: .95rem; }

/* FAQ */
.faq { padding: var(--section) 0; background: var(--glass); }
.faq__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(2rem, 6vw, 6rem);
}
.faq__list { border-top: 2px solid var(--anthracite); }
.faq details { border-bottom: 1px solid var(--glass-line); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  padding: 1.35rem 0;
  font-size: 1.15rem;
  font-weight: 700;
  font-stretch: var(--semi-wide);
  color: var(--anthracite);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex-shrink: 0;
  width: 16px; height: 16px;
  background:
    linear-gradient(var(--red), var(--red)) center / 100% 3px no-repeat,
    linear-gradient(var(--red), var(--red)) center / 3px 100% no-repeat;
  transition: transform .25s var(--ease-out);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--red); }
.faq details p { padding: 0 2.5rem 1.5rem 0; color: var(--steel); max-width: 60ch; }

@media (max-width: 860px) {
  .faq__grid { grid-template-columns: 1fr; }
}

/* Weitere Leistungen */
.more { padding: clamp(3rem, 6vw, 4.5rem) 0; }
.more__title { font-size: 1.2rem; font-weight: 800; font-stretch: var(--wide); color: var(--anthracite); margin-bottom: 1.25rem; }
.more__list { list-style: none; display: flex; flex-wrap: wrap; gap: .6rem; }
.more__list a {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .6rem 1rem;
  border: 2px solid var(--glass-line);
  text-decoration: none;
  font-weight: 600;
  color: var(--anthracite);
  transition: border-color .2s, color .2s;
}
.more__list a::before { content: ""; width: 8px; height: 8px; background: var(--red); }
.more__list a:hover { border-color: var(--red); color: var(--red); }

/* --- Kontakt ---------------------------------------------------------------- */

.contact { padding: 0 0 var(--section); }
.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: start;
}

.form { border-top: 2px solid var(--anthracite); padding-top: 2rem; }
.form__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.field { margin-bottom: 1.35rem; }
.field label, .field .field__label {
  display: block;
  margin-bottom: .45rem;
  font-weight: 700;
  font-size: .98rem;
  color: var(--anthracite);
}
.field__optional { font-weight: 400; color: var(--steel); }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 52px;
  padding: .8rem 1rem;
  border: 2px solid var(--glass-line);
  border-radius: 0;
  background: var(--white);
  font: inherit;
  color: var(--ink);
  transition: border-color .2s;
}
.field textarea { min-height: 170px; resize: vertical; }
.field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--anthracite) 50%), linear-gradient(135deg, var(--anthracite) 50%, transparent 50%);
  background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%;
  background-size: 6px 6px;
  background-repeat: no-repeat;
  padding-right: 2.75rem;
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: #A7B0B5; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--anthracite); box-shadow: 0 0 0 3px rgba(228, 24, 12, .25); }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: var(--red); }
.field__error { display: block; margin-top: .4rem; color: var(--red-dark); font-size: .92rem; font-weight: 600; }

.check { display: grid; grid-template-columns: 24px 1fr; gap: .8rem; align-items: start; margin-bottom: 1.75rem; font-size: .98rem; }
.check input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--red); }
.check.has-error label { color: var(--red-dark); }
.check .field__error { grid-column: 2; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.notice {
  padding: 1.25rem 1.5rem;
  margin-bottom: 2rem;
  border-left: 6px solid var(--anthracite);
  background: var(--glass);
}
.notice h2 { font-size: 1.2rem; font-stretch: var(--semi-wide); font-weight: 800; margin-bottom: .4rem; color: var(--anthracite); }
.notice--success { border-color: #2E7D4F; }
.notice--error { border-color: var(--red); }

.contact-card { display: grid; gap: 1.5rem; }
.contact-card__block { border-top: 2px solid var(--anthracite); padding-top: 1.25rem; }
.contact-card__block h2 { font-size: 1.05rem; font-weight: 800; font-stretch: var(--wide); color: var(--anthracite); margin-bottom: .6rem; }
.contact-card address { font-style: normal; }
.contact-card .hours dt { color: var(--steel); }
.contact-card a { font-weight: 600; text-decoration-color: var(--red); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.contact-card a:not(.sticker):hover { color: var(--red); }
.contact-card .sticker {
  position: static;
  align-self: start;
  justify-self: start;
  margin: .5rem 0 .75rem 4px;
  animation: none;
}

@media (max-width: 860px) {
  .contact__grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .form__row { grid-template-columns: 1fr; gap: 0; }
}

/* --- Rechtstexte ------------------------------------------------------------ */

.legal { padding: 0 0 var(--section); }
.legal__body { max-width: 46rem; }
.legal__body h2 { font-size: 1.35rem; font-stretch: var(--semi-wide); font-weight: 800; color: var(--anthracite); margin: 2.5rem 0 .75rem; }
.legal__body h3 { font-size: 1.1rem; font-weight: 700; color: var(--anthracite); margin: 1.75rem 0 .5rem; }
.legal__body ul { padding-left: 1.25rem; margin-bottom: 1em; }
.legal__body address { font-style: normal; margin-bottom: 1em; }
.placeholder { background: #FFF1A8; padding: 0 .2em; }

/* --- 404 -------------------------------------------------------------------- */

.not-found { padding: clamp(3rem, 8vw, 6rem) 0 var(--section); }
.not-found .more__list { margin-top: 2rem; }

/* --- Bewegung reduzieren ---------------------------------------------------- */

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