:root {
  --accent: #b11f1f;
  --text: #111;
  --muted: #666;
  --border: #e5e5e5;
  --max: 1100px;
  --font: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: #fff;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-decoration-color: var(--accent);
}

.wrapper {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
}

/* Header */
header {
  border-bottom: 1px solid var(--border);
  padding: 18px 0 12px;
}

/* Logo+Nav als Gruppe */
.header-center{
  grid-column: 2;
  display: flex;
  align-items: center;
  gap: 22px;
  justify-content: center;
}

.header-inner {
  display: flex;

  align-items: center;
}


.brand {

 /* display: flex; */
  /* justify-content: center; */ /* zentriert das Logo wirklich */
	width: auto;
}

.brand img {
  display: block;
  height: 62px;
  width: auto;
  max-width: 100%;
}

.brand a:hover { text-decoration: none; }


@media (max-width: 600px) {
  .brand img {
    height: 48px;      /* Mobile-Höhe */
  }
}

/* Wir lassen die alte rote Linie weg, weil sie im Logo schon drin ist */
.logo-line { display: none; }

nav {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 10px;
  font-size: 14px;
  flex-wrap: wrap;
}


/* Footer */
footer {
  border-top: 1px solid var(--border);
  margin-top: 60px;
  padding: 20px 0;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}
.site-footer {
  margin-top: 60px;
  padding: 16px 0;
  border-top: 1px solid #e5e5e5;
  background: #fafafa;
  font-size: 14px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.footer-right a {
  margin-left: 14px;
  text-decoration: none;
}

.footer-right a:hover {
  text-decoration: underline;
}

/* Mobile */
@media (max-width: 600px) {
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .footer-right a {
    margin-left: 0;
    margin-right: 10px;
  }
}

/* Headings */
h1 {
  font-size: 28px;
  margin: 30px 0 14px;
}

h2 {
  font-size: 20px;
  margin: 24px 0 10px;
}

p {
  line-height: 1.5;
}
/* Angebote */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 18px 0 40px;
}

@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .grid { grid-template-columns: 1fr; }
}

.card {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
}

.card img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  display: block;
  background: #f2f2f2;
}

.card-body {
  padding: 12px 12px 14px;
}

.badge {
  display: inline-block;
  padding: 4px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 8px;
}

.card-title {
  font-weight: 700;
  margin: 0 0 6px;
}

.card-addr {
  color: var(--muted);
  font-size: 13px;
  margin: 0 0 10px;
}

.facts {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
}

.fact {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 6px 8px;
}

.card-price {
  margin-top: 10px;
  font-weight: 700;
}

.card-body {
  padding: 12px 12px 14px;
  display: flex;
  flex-direction: column;
  flex: 1;              /* nimmt den restlichen Platz der Karte ein */
}

/* Button in der Card immer nach unten */
.card .btn {
  margin-top: auto;     /* drückt den Button nach unten */
}

.btn {
  margin-top: 12px;
  display: inline-block;
  padding: 10px 12px;
  border: 1px solid var(--accent);
  border-radius: 10px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
  text-align: center;
}

.btn:hover {
  background: var(--accent);
  color: #fff;
  text-decoration: none;
}

/* Angebot-Detail */
.hero {
  margin-top: 22px;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.hero-img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  display: block;
  background: #f2f2f2;
}

.hero-body {
  padding: 14px;
}

.hero-title {
  font-size: 28px;
  margin: 10px 0 8px;
}

.hero-sub {
  margin: 0 0 10px;
  color: var(--muted);
}

.hero-price {
  margin-top: 10px;
  font-size: 18px;
  font-weight: 800;
}

.layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
  margin-top: 16px;
}

@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
}

.card2 {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  padding: 14px;
  margin-bottom: 16px;
}

.card2-title {
  font-size: 18px;
  margin: 0 0 10px;
}

.pre {
  margin: 0;
  white-space: pre-line;
  line-height: 1.6;
}

.kv {
  width: 100%;
  border-collapse: collapse;
}

.kv td {
  padding: 8px 0;
  border-top: 1px solid var(--border);
  vertical-align: top;
}

.kv tr:first-child td {
  border-top: none;
}

.kv-k {
  width: 42%;
  padding-right: 12px;
}

.kv-v {
  color: var(--text);
}

.clean-ul {
  margin: 0;
  padding-left: 18px;
  line-height: 1.7;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

@media (max-width: 600px) {
  .gallery { grid-template-columns: 1fr; }
}

.gallery-item img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: 10px;
  display: block;
  background: #f2f2f2;
}

.bigimg img {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  display: block;
  background: #f2f2f2;
}
/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.86);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 9999;
}

.lightbox.open {
  display: flex;
}

.lightbox-inner {
  position: relative;
  max-width: min(1100px, 96vw);
  max-height: 90vh;
  width: 100%;
  display: grid;
  place-items: center;
}

.lightbox-img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  border-radius: 10px;
  background: #111;
}

.lightbox-close {
  position: absolute;
  top: -12px;
  right: -12px;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(0,0,0,0.45);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
}

.lightbox-close:hover {
  background: rgba(0,0,0,0.7);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(0,0,0,0.45);
  color: #fff;
  font-size: 26px;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.lightbox-nav:hover {
  background: rgba(0,0,0,0.7);
}

.lightbox-prev { left: -8px; }
.lightbox-next { right: -8px; }

@media (max-width: 700px) {
  .lightbox-prev { left: 6px; }
  .lightbox-next { right: 6px; }
  .lightbox-close { top: 6px; right: 6px; }
}

.lightbox-caption {
  margin-top: 10px;
  color: rgba(255,255,255,0.85);
  font-size: 13px;
  text-align: center;
  user-select: none;
}

/* --- Fix: Button immer unten in Angebotskarten --- */
.grid .card {
  height: 100%;
}

.grid .card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.grid .card-body .btn {
  margin-top: auto !important;   /* überschreibt .btn { margin-top: 12px; } */
}
/* Rechtliche Seiten */
.legal h1 {
  margin-bottom: 20px;
}

.legal h2 {
  margin-top: 28px;
  margin-bottom: 8px;
}

.legal p {
  max-width: 800px;
  line-height: 1.6;
}
/* ===== Footer (Fix) ===== */
.site-footer{
  margin-top: 60px;
  padding: 18px 0;
  border-top: 1px solid #e5e7eb;
  background: #fafafa;
  width: 100%;
}

.site-footer .footer-inner{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.site-footer .footer-left{
  white-space: nowrap;
  color: #555;
}

.site-footer .footer-right{
  display: flex;
  gap: 18px;
}

.site-footer .footer-right a{
  text-decoration: none;
  color: #111;
}

.site-footer .footer-right a:hover{
  text-decoration: underline;
}

/* Mobile */
@media (max-width: 640px){
  .site-footer .footer-inner{
    flex-direction: column;
    text-align: center;
  }
  .site-footer .footer-left{
    white-space: normal;
  }
}
html, body {
  overflow-x: hidden;
}

.container{
  padding-left: 16px;
  padding-right: 16px;
}
/* Startseite: Teaserboxen */
.teaser{
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 16px;
  margin: 28px 0 10px;
}

.teaser-card{
  border: 1px solid #e5e7eb;
  background: #fff;
  border-radius: 10px;
  padding: 16px;
}

.teaser-card h2{
  margin: 0 0 8px;
  font-size: 18px;
}

.teaser-card p{
  margin: 0 0 12px;
  line-height: 1.6;
  max-width: 70ch;
}

@media (max-width: 700px){
  .teaser{ grid-template-columns: 1fr; }
}/* Kontakt */
.contact-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 16px;
}

.contact-card{
  border: 1px solid #e5e7eb;
  background: #fff;
  border-radius: 10px;
  padding: 16px;
}

.contact-card h2{
  margin: 0 0 10px;
  font-size: 18px;
}

.contact-form label{
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
}

.contact-form input,
.contact-form textarea{
  width: 100%;
  margin-top: 6px;
  padding: 10px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font: inherit;
}

.contact-form textarea{ resize: vertical; }

.checkbox{
  display: flex !important;
  gap: 10px;
  align-items: flex-start;
  margin-top: 10px;
}

.checkbox input{ margin-top: 3px; }

.form-actions{
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.muted{
  color: #6b7280;
  font-size: 13px;
  line-height: 1.5;
}

@media (max-width: 800px){
  .contact-grid{ grid-template-columns: 1fr; }
}
/* Startseite: Teaserboxen */
.teaser{
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 16px;
  margin: 28px 0 10px;
}

.teaser-card{
  border: 1px solid #e5e7eb;
  background: #fff;
  border-radius: 10px;
  padding: 16px;

  /* NEU */
  display: flex;
  flex-direction: column;
}

.teaser-card h2{
  margin: 0 0 8px;
  font-size: 18px;
}

.teaser-card p{
  margin: 0 0 12px;
  line-height: 1.6;
  max-width: 70ch;
}

/* Button immer nach unten */
.teaser-card .btn{
  margin-top: auto;

	min-width: 180px;
  text-align: center;
}

@media (max-width: 700px){
  .teaser{ grid-template-columns: 1fr; }
}
/* Über uns / Content-Seiten */
.content{
  padding: 28px 0 60px;
}

.content h1{
  font-size: 34px;
  line-height: 1.15;
  margin: 18px 0 14px;
}

.content h2{
  font-size: 22px;
  margin: 28px 0 10px;
}

.content p{
  max-width: 78ch;
  line-height: 1.7;
  margin: 0 0 14px;
}

.content ul{
  max-width: 78ch;
  margin: 0 0 18px 18px;
}

.content li{
  margin: 6px 0;
  line-height: 1.6;
}
/* Content-Seiten: ruhiger Lesebereich */
.content{
  padding: 28px 0 60px;
}

.page-card{
  max-width: 900px;
  margin: 0 auto;              /* zentriert */
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 22px 22px 26px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}

.page-card h1{
  font-size: 34px;
  line-height: 1.15;
  margin: 0 0 14px;
}

.page-card h2{
  font-size: 22px;
  margin: 26px 0 10px;
}

.page-card p{
  max-width: 78ch;
  line-height: 1.75;
  margin: 0 0 14px;
}

.page-card ul{
  max-width: 78ch;
  margin: 0 0 18px 18px;
}

.page-card li{
  margin: 6px 0;
  line-height: 1.6;
}
/* Kontakt: Checkbox sauber ausrichten */
.contact-form .checkbox{
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 12px;
  font-size: 14px;
  line-height: 1.4;
}

.contact-form .checkbox input{
  margin: 3px 0 0;
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

.contact-form .checkbox span{
  display: block;
  flex: 1 1 auto;
  min-width: 0;
}
/* Kontakt: Seite etwas kompakter */
.content{
  padding: 28px 0 60px;
}

.contact-grid{
  max-width: 1100px;
  margin: 0 auto;
}
/* ===== Modal (Datenschutz-Overlay) ===== */
.modal{
  position: fixed;
  inset: 0;
  display: none;
  z-index: 9999;
}

.modal.is-open{ display: block; }

.modal__backdrop{
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
}

.modal__panel{
  position: relative;
  width: min(920px, calc(100% - 24px));
  max-height: calc(100vh - 24px);
  margin: 12px auto;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
  display: flex;
  flex-direction: column;
}

.modal__header{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid #e5e7eb;
}

.modal__header h2{
  margin: 0;
  font-size: 18px;
}

.modal__close{
  border: 0;
  background: transparent;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
}

.modal__body{
  padding: 16px;
  overflow: auto;
}

.modal__body h1{ display:none; } /* falls aus HTML übernommen */
.modal__body h2{ margin-top: 18px; }
.modal__body p{ line-height: 1.7; max-width: 78ch; }

/* ===== Mobile Basics ===== */
*{ box-sizing: border-box; }
img{ max-width: 100%; height: auto; }

/* Wrapper/Container: auf Handy mit Padding */
.wrapper, .container{
  width: min(1100px, 100%);
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

/* Header: Logo + Navigation umbrechen */
header .header-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

header nav{
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* Teaser: 3 Karten -> responsive Grid */
.teaser{
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 16px;
  margin: 20px 0 10px;
}

/* Buttons in Teaser immer unten */
.teaser-card{
  display: flex;
  flex-direction: column;
}
.teaser-card .btn{
  margin-top: auto;
  align-self: flex-start;
}

/* Breakpoints */
@media (max-width: 900px){
  .teaser{ grid-template-columns: repeat(2, minmax(220px, 1fr)); }
}

@media (max-width: 640px){
  .teaser{ grid-template-columns: 1fr; }
  header nav{ width: 100%; }
}
.teaser{
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 1fr));
  gap: 16px;
  margin: 20px 0 10px;
}

@media (max-width: 700px){
  .teaser{ grid-template-columns: 1fr; }
}

/* "Immobilien in Berlin" Block */
.home-intro{
  margin: 18px 0 34px;
}

.home-intro h1{
  margin: 0 0 10px;
}

.home-intro p{
  max-width: 78ch;
  line-height: 1.7;
}
/* ===== Startseite: Immobilien in Berlin ===== */
.home-intro{
  max-width: 900px;
  margin: 28px auto 40px;
  padding: 20px 22px 24px;
  background: #fafafa;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
}

.home-intro h1{
  margin: 0 0 12px;
  font-size: 28px;
  line-height: 1.2;
}

.home-intro p{
  margin: 0 0 12px;
  max-width: 78ch;
  line-height: 1.7;
}

.home-intro a{
  font-weight: 600;
  text-decoration: none;
}

.home-intro a:hover{
  text-decoration: underline;
}

/* Mobile Feinschliff */
@media (max-width: 640px){
  .home-intro{
    margin: 20px auto 28px;
    padding: 16px;
  }

  .home-intro h1{
    font-size: 24px;
  }
}
/* ===== Responsive Navigation ===== */
.site-header{
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  border-bottom: 1px solid #e5e7eb;
}

.header-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 10px;
  padding-bottom: 10px;
}

.brand img{
  height: 44px;
  width: auto;
  display: block;
}

/* Desktop Nav */
.site-nav{
  display: flex;
  align-items: center;
  gap: 18px;
}

.site-nav a{
  text-decoration: none;
  color: #111;
  font-weight: 500;
  padding: 8px 10px;
  border-radius: 8px;
}

.site-nav a:hover{
  background: #f3f4f6;
}

.site-nav a[aria-current="page"]{
  background: #111;
  color: #fff;
}

/* Burger Button (hidden on desktop) */
.nav-toggle{
  display: none;
  border: 1px solid #e5e7eb;
  background: #fff;
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
}

.nav-toggle span{
  display: block;
  width: 22px;
  height: 2px;
  background: #111;
  margin: 4px 0;
}

/* Mobile Layout */
@media (max-width: 720px){
  .nav-toggle{ display: inline-flex; flex-direction: column; justify-content: center; }

  .site-nav{
    position: absolute;
    left: 16px;
    right: 16px;
    top: 72px;                 /* ggf. an Logo-Höhe anpassen */
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 10px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.12);
  }

  .site-nav a{
    padding: 12px 12px;
  }

  /* geöffnet */
  body.nav-open .site-nav{
    display: flex;
  }
}

/* ===== Sticky Footer (Footer immer unten bei wenig Inhalt) ===== */
html, body {
  height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}
/* ===== Header Layout Fix (Logo neben Navi) ===== */
.site-header .header-inner{
  display: flex;
  align-items: center;
  justify-content: flex-start;   /* Logo + Navi als Einheit */
  gap: 22px;
}

.site-header .brand{
  width: auto;                   /* überschreibt width:100% */
  justify-content: flex-start;   /* überschreibt center */
}

.site-header .site-nav{
  margin-top: 0;                 /* falls alte nav styles greifen */
}

@media (max-width: 720px){
  .site-nav .nav-start{ display: none; }
}

.nav-toggle{
  grid-column: 3;
  justify-self: end; }

/* ===== Header: Logo + Navigation mittig (nebeneinander) ===== */
.site-header .header-inner{
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;   /* <-- zentriert die Gruppe */
  gap: 0;
  padding-top: 10px;
  padding-bottom: 10px;
}

/* Gruppe aus Logo + (Desktop-)Navigation */
.site-header .header-group{
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
}

/* Desktop-Navigation inline */
.site-header .site-nav{
  position: static;
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

/* Burger rechts anheften (damit Center wirklich Center bleibt) */
.site-header .nav-toggle{
  display: none; /* wird im Mobile-Breakpoint eingeschaltet */
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
}

/* ===== Mobile: Dropdown nur für Links (Logo bleibt oben) ===== */
@media (max-width: 720px){
  .site-header .nav-toggle{
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
  }

  .site-header .site-nav{
    position: absolute;
    top: calc(100% + 8px);
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 10px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.12);
  }

  body.nav-open .site-nav{
    display: flex;
  }
}
