/* ============================================================
   Allgemeines Layout & Grunddesign
============================================================ */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f0f0f0;
  color: #000;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 20px;
}

h1, h2 {
  line-height: 1.2;
}
h2 {
  margin-top: 8px;
}

.muted {
  color: #666;
}

.section {
  margin-top: 36px;
}

/* ============================================================
   Hero-Bereich / Header
============================================================ */
header.hero {
  background: url('haeuser_deutschland.webp') center center/cover no-repeat;
  color: #fff;
  text-align: center;
  padding: 60px 20px 20px;
  position: relative;
}

header.hero h1,
header.hero p {
  text-shadow: 1px 1px 3px #000;
  margin: 0.3em 0;
}

.logo {
  width: 180px;
  max-width: 40%;
  margin: 0 auto 20px;
  display: block;
}

/* ============================================================
   Navigation (Desktop + Mobile)
============================================================ */
nav {
  background: #ffd800;
  text-align: center;
  padding: 10px;
  margin-top: 15px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

nav a {
  padding: 8px 12px;
  background: #333;
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
  display: inline-block;
  font-weight: bold;
}

nav a:hover {
  background: #555;
}

/* Burger-Menü (mobil) */
.burger {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1100;
  width: 50px;
  height: 50px;
  border-radius: 10px;
  border: none;
  background: #ffd800;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,.25);
  display: none; /* nur mobil sichtbar */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
}

.burger-bar {
  width: 28px;
  height: 4px;
  background: #000;
  border-radius: 2px;
  transition: transform .25s ease, opacity .25s ease;
}

/* Off-Canvas Mobile Navigation */
.mobile-nav {
  position: fixed;
  top: 0;
  right: 0;
  width: min(50vw, 340px);
  height: 100vh;
  background: #111;
  color: #fff;
  transform: translateX(100%);
  transition: transform .25s ease;
  z-index: 1099;
  box-shadow: -10px 0 20px rgba(0,0,0,.3);
}

.mobile-nav.open {
  transform: translateX(0);
}

.mobile-nav-inner {
  display: flex;
  flex-direction: column;
  padding: 80px 24px 24px;
  gap: 12px;
}

.mobile-nav-inner a {
  color: #fff;
  text-decoration: none;
  font-size: 1.1rem;
  padding: 10px 6px;
  border-radius: 8px;
}

.mobile-nav-inner a:hover {
  background: rgba(255,216,0,0.18);
  color: #ffd800;
}

/* Overlay für mobile Navigation */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.35);
  z-index: 1098;
  display: none;
}

.nav-overlay.show {
  display: block;
}

/* ============================================================
   Buttons, CTAs & Badges
============================================================ */
.cta,
.call-button {
  display: inline-block;
  background: #ffd400;
  color: #000;
  padding: 12px 18px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
  text-align: center;
  transition: background-color 0.3s ease, color 0.3s ease;
  box-shadow: 0 4px 6px rgba(0,0,0,0.2);
}

.call-button {
  margin: 20px auto;
  font-size: 1.1em;
  border: none;
  cursor: pointer;
}

.call-button:active {
  background-color: #333;
  color: #ffd800;
}

.badges .badge {
  display: inline-block;
  margin: .25rem .25rem 0 0;
  padding: .2rem .6rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: .9rem;
}

/* ============================================================
   Listen, Karten, Layout-Elemente
============================================================ */
ul.check {
  list-style: none;
  padding-left: 0;
}

ul.check li {
  margin: 6px 0;
}

ul.check li::before {
  content: "✓ ";
  color: #0a7f2e;
  font-weight: 700;
}

.card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 16px;
}

/* ============================================================
   Grids & Galerie
============================================================ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.2rem;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 20px;
}


.gallery img {
  width: 100%;
  max-width: 400px;      /* auf großen Screens nicht größer als 400px */
  height: auto;          /* Höhe automatisch, damit nichts verzerrt */
  aspect-ratio: 1 / 1;   /* bleibt quadratisch */
  border-radius: 4px;
  object-fit: cover;
  object-position: center;
}


/* ============================================================
   Counter-Sektion
============================================================ */
.counter-section {
  text-align: center;
  padding: 10px;
  background: #fff8cc;
  margin: 10px 0;
  border-radius: 20px;
  box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

.counter-section h2 {
  font-size: 2em;
  margin-bottom: 10px;
  color: #333;
}

.counter {
  font-size: 3em;
  font-weight: bold;
  color: #d40000;
}

/* ============================================================
   Footer
============================================================ */
footer {
  font-size: 0.9em;
  text-align: center;
  margin-top: 40px;
  background: #f0f0f0;
  padding: 20px;
}

/* ============================================================
   Hinweisboxen
============================================================ */
.notice {
  background: #fff7cd;
  border: 1px solid #ffe28a;
  border-radius: 10px;
  padding: 12px;
}

/* ============================================================
   WhatsApp Floating Button (mobil)
============================================================ */
.whatsapp-fab {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 1100;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: #25D366;
  display: none; /* nur mobil sichtbar */
  justify-content: center;
  align-items: center;
  box-shadow: 0 6px 14px rgba(0,0,0,.25);
  transition: transform 0.2s ease;
}

.whatsapp-fab:hover {
  transform: scale(1.05);
}

.whatsapp-fab svg {
  width: 30px;
  height: 30px;
  fill: #fff;
}

/* ============================================================
   Responsive Design
============================================================ */
@media (min-width: 860px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 900px) {
  nav {
    display: none; /* Desktop-Navigation ausblenden */
  }
  .burger {
    display: flex;
  }
  .whatsapp-fab {
    display: flex;
  }
}

@media (max-width: 600px) {
  header.hero {
    padding: 40px 15px 15px;
  }
  .logo {
    width: 140px;
    margin-bottom: 15px;
  }
  .call-button {
    width: 100%;
    box-sizing: border-box;
  }
  .gallery {
    grid-template-columns: 1fr;
  }
  .counter-section h2 {
    font-size: 1.5em;
  }
  .counter {
    font-size: 2.2em;
  }
}

/* ============================================================
   Komfort: Scrolloffset bei Ankern
============================================================ */
:target {
  scroll-margin-top: 80px;
}
header.hero,
.section,
footer {
  padding-left: 20px;
  padding-right: 20px;
  box-sizing: border-box;
  max-width: 1120px;
  margin: 0 auto;
}
.counter-section { text-align: center; }
.counter {
  display: inline-block;
  margin: 8px auto;
}

/* ==========================
   NEWS-Artikel
========================== */
.news-article {
  background: #fff;
  padding: 22px;
  border-radius: 12px;
  border: 1px solid #eee;
  margin-bottom: 40px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.07);
}

.news-title {
  margin-top: 0;
  color: #333;
}

.news-meta {
  font-size: 0.9rem;
  color: #666;
  margin: 8px 0 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.news-image {
  text-align: center;
}

.news-image img {
  display: block;
  width: 100%;
  max-width: 400px;   /* auf großen Bildschirmen nicht breiter als 400px */
  height: auto;
  margin: 20px auto 0 auto;
  border-radius: 8px;
  object-fit: cover;  /* kannst du notfalls auch rausnehmen, wenn nichts beschnitten werden soll */
}

.news-image figcaption {
  font-size: 0.85rem;
  color: #666;
  margin-top: 6px;
}

.partner-box {
  background: #fff8d8;
  border: 1px solid #f0d88a;
  padding: 12px;
  border-radius: 8px;
  margin: 20px 0;
}

.news-cta {
  margin-top: 20px;
  text-align: center;
}
/* ==========================
   News Vorschau
========================== */

#news-preview .news-preview-box {
  display: flex;
  gap: 16px;
  background: #fff;
  padding: 16px;
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.15);
  align-items: flex-start;
}

#news-preview img {
  width: 140px;
  height: 100px;
  object-fit: cover;
  border-radius: 8px;
}

#news-preview .news-date {
  display: block;
  color: #666;
  font-size: 0.9rem;
  margin-bottom: 6px;
}

#news-preview h3 {
  margin: 4px 0;
}

#news-preview p {
  margin: 10px 0;
  color: #333;
}

@media (max-width: 600px) {
  #news-preview .news-preview-box {
    flex-direction: column;
  }
  #news-preview img {
    width: 100%;
    height: auto;
  }
}
