:root{
  --max-width:1200px;
  --accent:#0d6efd;
  --muted:#6b7280;
  --bg:#f7f7f8;
  --surface:#ffffff;
  --radius:10px;
  --gap:1.125rem;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  color-scheme: light;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  background:var(--bg);
  color:#111827;
  line-height:1.45;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
}

html {
  scroll-behavior: smooth;
}

.container{
  max-width:var(--max-width);
  margin:0 auto;
  padding:0 1rem;
}

/* HEADER */
.site-header{
  background:linear-gradient(180deg,rgba(255,255,255,0.9),rgba(255,255,255,0.85));
  position:sticky;
  top:0;
  z-index:50;
  border-bottom:1px solid rgba(0,0,0,0.05);
}
.header-inner{
  display:flex;
  align-items:center;
  gap:1rem;
  padding:0.75rem 0;
}
.brand img{display:block}
.site-nav{margin-left:auto}
.site-nav ul{display:flex;gap:1rem;list-style:none;padding:0;margin:0}
.site-nav a{color:inherit;text-decoration:none;padding:0.5rem 0.75rem;border-radius:6px}
.site-nav a:hover{background:rgba(0,0,0,0.03)}
.phone-cta{
  margin-left:1rem;
  background:var(--accent);
  color:white;
  padding:0.5rem 0.9rem;
  border-radius:8px;
  text-decoration:none;
  font-weight:600;
}
.nav-toggle{display:none;border:0;background:transparent;font-size:1.2rem;padding:0.5rem}

/* HERO */
.hero{padding:3rem 0}
.hero-inner{display:grid;grid-template-columns:1fr 480px;gap:2rem;align-items:center}
.hero-text h1{font-size:clamp(1.6rem,2.6vw,2.4rem);margin:0 0 0.5rem}
.hero-text p{color:var(--muted);margin:0 0 1rem}
.hero-image img{width:100%;height:auto;border-radius:10px;display:block;box-shadow:0 8px 30px rgba(14,20,30,0.06)}

/* --- Hero Slideshow --- */
.hero-image { display:flex; align-items:center; justify-content:center; }

.hero-slideshow {
  position: relative;
  width: 100%;
  height: 600px;            /* anpassen (z.B. 300/450) */
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(14,20,30,0.06);
}

/* Slide */
.slide {
  position: absolute;
  inset: 0;                 /* top:0; right:0; bottom:0; left:0 */
  opacity: 0;
  transition: opacity 600ms ease-in-out;
  display: flex;
}
.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* sichtbar */
.slide.active {
  opacity: 1;
  z-index: 2;
}

/* Prev/Next Buttons */
.slide-prev,
.slide-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.4);
  color: #fff;
  border: none;
  width: 36px;
  height: 48px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
}
.slide-prev { left: 12px; }
.slide-next { right: 12px; }
.slide-prev:hover, .slide-next:hover { background: rgba(0,0,0,0.55); }

/* Dots */
.dots {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 12px;
  display: flex;
  gap: 8px;
  z-index: 4;
}
.dots .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,0.6);
  border: none;
  cursor: pointer;
}
.dots .dot.active {
  background: white;
  box-shadow: 0 0 6px rgba(0,0,0,0.25);
}

/* Responsive: auf kleinen Bildschirmen weniger Höhe */
@media (max-width: 760px) {
  .hero-slideshow { height: 240px; }
}

/* Buttons */
.btn{display:inline-block;padding:0.6rem 1rem;border-radius:8px;text-decoration:none;font-weight:600}
.btn-primary{background:var(--accent);color:white}
.btn-outline{border:1px solid rgba(13,110,253,0.15);background:transparent;color:var(--accent)}

/* Sections */
.section{padding:2.25rem 0}
.lead{color:var(--muted);margin-top:0.25rem}

/* Services grid */
.services-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:1rem;margin-top:1rem}
.service-card{background:var(--surface);padding:1rem;border-radius:10px;box-shadow:0 6px 18px rgba(12,18,30,0.03)}
.service-card h3{margin:0.5rem 0}
.service-card p{color:var(--muted);margin:0}
.service-card {text-align: center;
                padding: 20px;}

/* Process */
.process-steps{display:flex;flex-direction:column;gap:0.75rem;padding-left:0;list-style:none}
.process-steps li{background:var(--surface);padding:1rem;border-radius:8px;box-shadow:0 6px 18px rgba(12,18,30,0.03)}

/* Gallery */
.snap-carousel {
  display: flex;
  overflow-x: hidden;
  gap: 20px;
  scroll-behavior: smooth;
  justify-content: flex-start; /* JS zentriert das aktuelle */
  align-items: center;
}

.snap-item {
  flex: 0 0 350px;
  transition: transform 0.3s, opacity 0.3s;
  text-align: center;
}

.snap-item img,
.snap-item video {
  width: 100%;
  height: 450px;
  object-fit: cover;
  border-radius: 8px;
}

.carousel-wrapper {
  position: relative; /* WICHTIG für absolute Buttons */
  width: 100%;
  display: flex;
  align-items: center;
}

/* Pfeile als runde Kreise */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.5);
  color: white;
  font-size: 24px;
  border: none;
  border-radius: 50%;       /* macht sie rund */
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  transition: all 0.3s ease;
}

.carousel-btn:hover {
  background: rgba(0,0,0,0.7);
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 18px rgba(0,0,0,0.4);
}

/* Links/Rechts */
.carousel-btn.prev { left: 10px; }
.carousel-btn.next { right: 10px; }

/* Reviews */
.reviews .review{background:var(--surface);padding:1rem;border-radius:8px;box-shadow:0 6px 18px rgba(12,18,30,0.03)}

/* Contact layout */
.contact-inner {
  display: flex;
  flex-direction: row;       /* nebeneinander */
  justify-content: center;   /* beide Blöcke in der Mitte */
  align-items: flex-start;   /* oben ausrichten */
  gap: 40px;                 /* Abstand zwischen Formular und Kontaktdaten */
  flex-wrap: wrap;           /* bei kleinen Bildschirmen untereinander */
  margin: 0 auto;
}

.contact-form,
.contact-info {
  max-width: 500px;          /* gleiche Breite für Konsistenz */
  width: 100%;
  text-align: left;           /* Inhalte linksbündig */
}

.contact-form h2 {
  text-align: center;
  color: #333;
  font-size: 24px;
  margin-bottom: 15px;
}

.contact-form label {
  font-weight: bold;
  color: #555;
  display: block;
  margin-bottom: 5px;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="betreff"],
.contact-form textarea,
.contact-form input[type="file"] {
  width: 100%;
  padding: 10px;
  margin-bottom: 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 14px;
  box-sizing: border-box;
}

.contact-form textarea {
  resize: vertical;
}

.contact-form button {
  width: 100%;
  padding: 10px;
  font-size: 16px;
  font-weight: bold;
  color: #fff;
  background-color: #007BFF;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.contact-form button:hover {
  background-color: #0056b3;
}

.contact-info{background:var(--surface);padding:1rem;border-radius:8px;box-shadow:0 6px 18px rgba(12,18,30,0.03)}
.map-placeholder{background:#e9e9ef;height:200px;border-radius:8px;display:flex;align-items:center;justify-content:center;color:var(--muted)}

/* Footer */
.site-footer{padding:1rem 0;background:#fafafb;border-top:1px solid rgba(0,0,0,0.04)}
.footer-inner{display:flex;justify-content:space-between;gap:1rem;align-items:center;font-size:0.95rem}
.footer-nav a{margin-left:1rem;color:var(--muted);text-decoration:none}

/* Utilities */
.small{font-size:0.9rem;color:var(--muted)}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}

/* Responsive */
@media (max-width:980px){
  .hero-inner{grid-template-columns:1fr}
  .contact-inner{grid-template-columns:1fr}
}
@media (max-width:760px){
  .site-nav{display:none}
  .nav-toggle{display:inline-block;margin-left:auto}
  .phone-cta{display:none}
  .hero{padding:2rem 0}
  .gallery-grid img{height:140px}
}

/* Mobile nav active */
.site-nav.open{display:block;position:absolute;left:0;right:0;top:64px;background:var(--surface);padding:1rem;border-bottom:1px solid rgba(0,0,0,0.06)}
.site-nav.open ul{flex-direction:column;gap:0}


/* === HERO: mobile-only fix to avoid overlap ===
   Paste this at the END of styles.css so it overrides prior rules. */

.hero { position: relative; padding: 2.5rem 1rem; }

/* Base layout: desktop (keine Änderung) */
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

/* Ensure text isn't absolutely positioned */
.hero-text {
  position: relative;
  z-index: 5;
}

/* Slideshow container should be positioned relative so absolutely-positioned slides stay inside it */
.hero-slideshow,
.hero-image { 
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  border-radius: 12px;
}

/* Slides inside must be positioned relative to the slideshow */
.hero-slideshow .slide { position: absolute; inset: 0; }

/* Make images behave nicely */
.hero-slideshow img,
.hero-image img { 
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* === MOBILE: stack text then slideshow, prevent overlap === */
@media (max-width: 768px) {
  .hero-inner {
    grid-template-columns: 1fr !important;
    align-items: stretch;
  }

  /* order: text first, slideshow second */
  .hero-text { order: 1; text-align: center; padding-bottom: 1rem; }

  .hero-image,
  .hero-slideshow { order: 2; margin: 0 auto; }

  /* give slideshow a fixed mobile height so absolutely positioned slides have space */
  .hero-slideshow { height: 450px !important; min-height: 180px; }

  /* ensure slides remain absolutely positioned inside the slideshow */
  .hero-slideshow .slide { position: absolute; inset: 0; }

  /* Optional: make hero buttons centered and stacked */
  .hero-actions { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; }
  .hero-actions .btn { min-width: 140px; }
}

#formPopup {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0,0,0,0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 1000;
}

#formPopup.show {
  opacity: 1;
  pointer-events: auto;
}

.popup-content {
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  text-align: center;
  max-width: 400px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.popup-content button {
  margin-top: 1rem;
  padding: 0.5rem 1.5rem;
  border: none;
  background-color: #007BFF;
  color: #fff;
  border-radius: 6px;
  cursor: pointer;
}

.popup-content button:hover {
  background-color: #0056b3;
}

/* === Werbeaktion Popup === */
.promo-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.promo-overlay.active {
  display: flex;
}

.promo-box {
  position: relative;
  display: inline-block;
  background: #fff;
  padding: 20px;
  max-width: 600px;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.promo-box img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.promo-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  border-radius: 50%;              /* Kreis */
  border: none;
  background: rgba(0, 0, 0, 0.5);  /* leicht durchsichtig */
  color: #fff;
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
  z-index: 10; /* damit es immer über dem Bild liegt */
}

.promo-close:hover {
  background: rgba(0, 0, 0, 0.7);
}