/* =======================================================================
   BASIS
   ======================================================================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

body {
  display: flex;
  min-height: 100vh;
  background: #f9f9f9;
  color: #333;
  flex-direction: column;
}

/* ---------------------------
   NAVIGATION (Desktop-Basis)
   --------------------------- */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 200px;             /* Platz für Desktop-Sidebar */
  height: 50px;
  background-color: #4A0114;
  display: flex;
  align-items: center;
  z-index: 2000;
  padding: 0 20px;
}

/* Hamburger ist auf Desktop unsichtbar – wird mobil gezeigt */
.hamburger{
  display: none;
  background: none;
  border: 0;
  font-size: 26px;
  line-height: 1;
  color: #fff;
  cursor: pointer;
}

nav.top-nav ul {
  list-style: none;
  width: 100%;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

nav.top-nav ul li { position: relative; }

nav.top-nav ul li a {
  text-decoration: none;
  color: #ffdcdc;
  padding: 15px 10px;
  display: block;
  font-weight: 600;
  transition: color 0.3s;
}
nav.top-nav ul li a:hover { color: #fff; }

nav.top-nav ul.submenu { justify-content: space-evenly; }

nav.top-nav .back-btn {
  font-weight: bold;
  color: #4A0114 !important;
  padding-right: 20px;
}

/* -----------------------------------------------
   DROPDOWN (Desktop-Grundstil)
   ----------------------------------------------- */
.top-nav .main-menu { position: relative; }
.top-nav .main-menu > li { position: relative; }

.top-nav .dropdown {
  position: absolute;
  top: 100%; left: 0;
  min-width: 220px;
  background: #4A0114;
  border: 0;
  border-radius: 8px;
  box-shadow: 0 8px 18px rgba(0,0,0,.12);
  padding: 8px 0;
  display: none;
  z-index: 2001;
}
.top-nav .dropdown li a {
  display: block;
  padding: 10px 14px;
  color: #ffdcdc;
  text-decoration: none;
  white-space: nowrap;
}
.top-nav .dropdown li a:hover {
  background: #5e0202;
  color: #fff;
}
.top-nav .has-submenu:hover > .dropdown,
.top-nav .has-submenu:focus-within > .dropdown,
.top-nav .has-submenu.open > .dropdown { display: block; }
.top-nav .has-submenu > a::after {
  content: "▾";
  margin-left: 6px;
  font-size: .8em;
}

/* ---------------------------
   MAIN + SIDEBAR (Desktop)
   --------------------------- */
main {
  margin-top: 60px;
  padding: 20px 30px;
  flex-grow: 1;
  max-width: 1200px;
  margin-left: 20px;
  margin-right: 200px;
}

.right-sidebar {
  width: 200px;
  background-color: #4A0114;
  color: #fff;
  position: fixed;
  top: 0; right: 0;
  height: 100vh;
  padding: 20px 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: -3px 0 5px rgba(0,0,0,0.1);
  font-size: 14px;
  overflow-y: auto;
}

.sidebar-section { margin-bottom: 25px; }
.sidebar-section h3 {
  font-size: 18px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.3);
  padding-bottom: 4px;
}
.sidebar-section ul { list-style: none; padding-left: 0; }
.sidebar-section ul li { margin-bottom: 8px; }
.sidebar-section ul li a {
  color: #ffdcdc;
  text-decoration: none;
  transition: color 0.3s;
}
.sidebar-section ul li a:hover {
  color: #fff;
  text-decoration: underline;
}
.important {
  font-weight: 700;
  font-size: 17px;
  color: #ffdcdc;
}
.bpa-logo {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.bpa-logo-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain; /* sorgt dafür, dass es wie der Placeholder hineinpasst */
  display: block;
}


/* ---------------------------
   TYPO/KOMPONENTEN (Basis)
   --------------------------- */
p { margin-bottom: 20px; }

ul {
  margin-left: 30px;
  padding-left: 20px;
}

.grid {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.box {
  flex: 1;
  min-width: 250px;
  padding: 20px;
  background: #fff;
  border: 5px solid #4A0114;
}

.maps-square {
  width: 100%;
  height: 300px;
  margin: 20px 0;
}

.btn-primary {
  display: inline-block;
  background-color: #4A0114;
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
}
.btn-primary:hover { background-color: #5e0202; }

/* Formular-Container */
.kontakt-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  margin-top: 30px;
  flex-wrap: wrap;
}
.kontakt-form { flex: 1 1 auto; max-width: 600px; }
.kontakt-form .form-row { display: flex; flex-direction: column; margin-bottom: 15px; }
.kontakt-form label { font-weight: 600; margin-bottom: 5px; color: #333; }

.kontakt-form input[type="text"],
.kontakt-form input[type="email"],
.kontakt-form input[type="tel"],
.kontakt-form input[type="file"],
.kontakt-form textarea {
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  width: 100%;
  transition: border-color 0.3s;
}
.kontakt-form input:focus,
.kontakt-form textarea:focus {
  border-color: #4A0114;
  outline: none;
}

.kontakt-form fieldset { border: none; padding: 0; }
.kontakt-form fieldset legend { font-weight: 600; margin-bottom: 8px; }
.kontakt-form fieldset label {
  font-weight: normal;
  margin-right: 15px;
  display: inline-flex;
  align-items: center;
}
.kontakt-form fieldset input[type="checkbox"] { margin-right: 6px; }

.kontakt-form button.btn-primary {
  background-color: #4A0114;
  color: #fff;
  padding: 12px 20px;
  font-weight: bold;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  align-self: flex-start;
  transition: background-color 0.3s;
}
.kontakt-form button.btn-primary:hover { background-color: #5e0202; }

.floating-maps { flex: 0 0 400px; max-width: 400px; }
.floating-maps .maps-square {
  width: 100%;
  height: 400px;
  border-radius: 12px;
  border: 2px solid #4A0114;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* Filterformular */
.filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  background: #fff;
  padding: 15px;
  border-radius: 8px;
  margin: 20px 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.filter-form .form-row { display: flex; flex-direction: column; flex: 1; min-width: 180px; }
.filter-form label { font-weight: 600; margin-bottom: 5px; }

/* Jobs Liste */
.jobs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}
.job-item {
  background: #fff;
  padding: 15px;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
.job-item h3 { margin-bottom: 6px; font-size: 18px; color: #4A0114; }

/* Bewerbungsformular */
.bewerbungs-form {
  max-width: 600px;
  background: #fff;
  padding: 25px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.bewerbungs-form .form-row { display: flex; flex-direction: column; margin-bottom: 15px; }
.bewerbungs-form label { font-weight: 600; margin-bottom: 5px; }
.bewerbungs-form input[type="text"],
.bewerbungs-form input[type="email"],
.bewerbungs-form input[type="file"],
.bewerbungs-form select {
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  width: 100%;
}
.bewerbungs-form input:focus,
.bewerbungs-form select:focus {
  border-color: #4A0114;
  outline: none;
}
.bewerbungs-form button.btn-primary {
  background-color: #4A0114;
  color: #fff;
  padding: 12px 20px;
  font-weight: bold;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  transition: background-color 0.3s;
}
.bewerbungs-form button.btn-primary:hover { background-color: #5e0202; }

/* =========================
   Team / Mitarbeiter
   ========================= */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  margin-top: 30px;
}
.team-card {
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.team-card:hover { transform: translateY(-4px); box-shadow: 0 6px 16px rgba(0,0,0,0.15); }

/* FOTO als Hintergrunddiv + Bordeaux-Rahmen */
.team-photo {
  width: 100%;
  max-width: 250px;
  aspect-ratio: 1 / 1;
  margin: 0 auto 15px;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
  border: 4px solid #4A0114;   /* Bordeaux Rahmen */
  box-shadow: 0 0 8px rgba(0,0,0,0.08);
}

.team-card h2 { margin-bottom: 8px; font-size: 20px; color: #4A0114; }
.team-card p { margin-bottom: 8px; line-height: 1.5; font-size: 14px; }

/* individuelle Fotos */
.team-photo.maximilian { background-image: url("images/maximilian.jpg"); }
.team-photo.svenja     { background-image: url("images/svenja.jpeg"); }
.team-photo.mitarbeiter1 { background-image: url("images/mitarbeiter1.png"); }
.team-photo.mitarbeiter2 { background-image: url("images/mitarbeiter2.png"); }
.team-photo.mitarbeiter3 { background-image: url("images/mitarbeiter3.png"); }

/* Mitarbeiter-Karten (falls separat genutzt) */
.employee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  align-items: stretch;
}
.employee-card {
  background: #fff;
  border-radius: 12px;
  padding: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
  font-size: 0.95rem;
  transition: transform .2s ease, box-shadow .2s ease;
}
.employee-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}
.employee-card h2 { font-size: 1.1rem; margin: 8px 0 4px; }
.employee-card p { margin: 6px 0; }
.employee-card .employee-meta { list-style: none; padding: 0; margin: 6px 0 0; font-size: 0.9rem; }
.employee-card .employee-meta li { margin: 2px 0; }

/* Optional: für größere Bildschirme */
@media (min-width: 1200px) {
  .employee-card .team-photo { max-width: 280px; } /* optional */
}

/* =========================
   HERO
   ========================= */
.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding: 60px 30px;
  background: transparent;
  border-radius: 8px;
  margin-top: 60px; /* wegen fixer Nav */
}
.hero-content { flex: 1; }
.hero-content h1 { font-size: 2.2rem; margin-bottom: 15px; color: #4A0114; }
.hero-content p { font-size: 1.1rem; margin-bottom: 20px; line-height: 1.5; }
.hero-content .btn-primary { font-size: 1rem; padding: 14px 26px; }
.hero-image { flex: 1; text-align: center; }
.hero-image img {
  width: auto; height: auto;
  max-width: 300px; max-height: 300px;
  object-fit: contain;
  border: 2px solid #4A0114;
  border-radius: 8px;
  margin-left: auto;
}

/* Leistungen Vorschau */
.leistungen-preview { margin-top: 60px; }
.leistungen-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 20px;
}
.leistung-card {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.leistung-card:hover { transform: translateY(-4px); box-shadow: 0 6px 14px rgba(0,0,0,0.1); }
.leistung-card h1,
.leistung-card h2,
.leistung-card h3 { margin-bottom: 10px; color: #4A0114; }
.leistung-card p { font-size: 0.95rem; margin-bottom: 10px; }
.leistung-card a { color: #4A0114; font-weight: 600; text-decoration: none; }
.leistung-card a:hover { text-decoration: underline; }

/* Sidebar-Listen bündig – globale ul-Einrückung überschreiben */
.right-sidebar .sidebar-section ul { margin-left: 0 !important; padding-left: 0 !important; list-style: none; }
.right-sidebar .sidebar-section li { margin-left: 0; padding-left: 0; }
.right-sidebar .sidebar-section li a { display: block; padding: 2px 0; }

/* =======================================================================
   MOBILE / RESPONSIVE
   ======================================================================= */

/* Tablet: Inhalte mittig, Sidebar rutscht darunter */
@media (max-width: 1024px) {
  main {
    margin-left: auto;
    margin-right: auto;
    padding: 15px;
  }
}

/* Form/Map untereinander */
@media (max-width: 900px) {
  .kontakt-wrapper { flex-direction: column; }
  .floating-maps { max-width: 100%; margin-top: 20px; }
}

/* Handyansicht (≤ 768px) */
@media (max-width: 768px) {
  .top-nav {
    right: 0;
    height: auto;
    padding: 8px 12px;
    background: #4A0114;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    gap: 12px;
  }

  .hamburger { display: block; }

  nav.top-nav ul.main-menu {
    display: none;             /* geschlossen */
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
    background: #4A0114;
    border-radius: 8px;
    box-shadow: 0 8px 18px rgba(0,0,0,.08);
    overflow: hidden;
    margin-top: 8px;
  }
  body.nav-open nav.top-nav ul.main-menu { display: flex; }
  nav.top-nav .main-menu > li { width: 100%; }
  nav.top-nav .main-menu > li > a {color: #fff; padding: 14px 14px; border-bottom: 1px solid rgba(255, 255, 255, 0.15); }
  nav.top-nav .main-menu > li:last-child > a { border-bottom: 0; }

  .top-nav .dropdown {
    position: static;
    display: none;
    background: #4A0114;
    margin: 0 0 8px 0;
    border-radius: 8px;
  }
  .top-nav .has-submenu.open > .dropdown,
  .top-nav .has-submenu:focus-within > .dropdown { display: block; }

  main {
    margin-right: 0;
    padding: 15px;
    padding-bottom: 140px;     /* Platz für die mobile Leiste */
  }

  .maps-square { width: 100%; height: 200px; }

  /* Sidebar als horizontale, wischbare Leiste unten */
  .right-sidebar {
    position: fixed;
    left: 0; right: 0; bottom: 0; top: auto;
    height: 120px;
    background: #4A0114;
    color: #fff;
    padding: 10px 12px;
    display: grid;
    grid-auto-flow: column;
    align-items: stretch;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    box-shadow: 0 -6px 16px rgba(0,0,0,.1);
    z-index: 1000;
    width: 100%;
    scrollbar-width: thin;
  }
  .right-sidebar::-webkit-scrollbar { height: 6px; }
  .right-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.35); border-radius: 3px; }
  .right-sidebar::-webkit-scrollbar-track { background: transparent; }

  .right-sidebar .sidebar-section {
    min-width: 240px;
    background: rgba(255,255,255,.1);
    border-radius: 10px;
    padding: 10px;
    scroll-snap-align: start;
    display: flex; flex-direction: column; justify-content: center;
  }
  .right-sidebar .sidebar-section h3 {
    font-size: 14px; margin: 0 0 6px; border: 0; padding: 0;
  }
  .right-sidebar .sidebar-section p,
  .right-sidebar .sidebar-section li,
  .right-sidebar .sidebar-section a {
    font-size: 14px;
    color: #ffdcdc;
    text-decoration: none;
  }

  /* Hero kompakter */
  .hero { flex-direction: column; text-align: center; padding: 36px 16px; margin-top: 56px; }
  .hero-content h1 { font-size: clamp(1.6rem, 4.5vw, 2.0rem); }
  .hero-content p { font-size: 1rem; }
  .hero-image img { max-width: 90%; margin: 20px auto 0; }
}

/* Desktop-Re-Definition (Klarheit) */
@media (min-width: 769px) {
  .right-sidebar {
    position: fixed;
    top: 0; right: 0;
    width: 200px; height: 100vh;
    background: #4A0114; color: #fff;
    padding: 20px 15px;
    box-shadow: -3px 0 5px rgba(0,0,0,0.1);
    overflow-y: auto;
  }
  body main { margin-right: 220px; }
}
/* Alle Überschriften bordeaux */
h1, h2, h3, h4, h5, h6 {
  color: #4A0114;
}

/* Ausnahme: Überschriften in der Sidebar sollen weiß bleiben */
.right-sidebar h1,
.right-sidebar h2,
.right-sidebar h3,
.right-sidebar h4,
.right-sidebar h5,
.right-sidebar h6 {
  color: #fff; /* oder deine Sidebar-Farbe */
}

main h1 {
  margin-bottom: 1em;   /* Abstand nach unten */
}

main h2 {
  margin-top: 1em;        /* Abstand nach oben */
  margin-bottom: 0.8em;   /* Abstand nach unten */
}

main p {
  margin-bottom: 1.2em;   /* Textblöcke nicht so gedrungen */
}

main ul {
  margin-top: 0.5em;      /* Etwas Luft oberhalb Listen */
  margin-bottom: 0.5em;
}

body.ansprechpartner {
  background: url("images/bg-ansprechpartner.jpg") no-repeat center center;
  background-size: cover;
}

body.ansprechpartner::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.3); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.behandlungspflege {
  background: url("images/bg-behandlungspflege.jpg") no-repeat center center;
  background-size: cover;
}

body.behandlungspflege::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.6); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.betreuungsleistungen {
  background: url("images/bg-betreuungsleistungen.jpg") no-repeat center center;
  background-size: cover;
}

body.betreuungsleistungen::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.5); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.grundpflege {
  background: url("images/bg-grundpflege.jpg") no-repeat center center;
  background-size: cover;
}

body.grundpflege::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.6); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.hauswirtschaft {
  background: url("images/bg-hauswirtschaft.jpg") no-repeat center center;
  background-size: cover;
}

body.hauswirtschaft::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.5); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.index {
  background: url("images/bg-index.jpg") no-repeat center center;
  background-size: cover;
}

body.index::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.6); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.leitbild {
  background: url("images/bg-leitbild.jpg") no-repeat center center;
  background-size: cover;
}

body.leitbild::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.7); /* Weißes Overlay mit 70% */
  z-index: -1;
}

body.mitarbeiter {
  background: url("images/bg-mitarbeiter.jpg") no-repeat center center;
  background-size: cover;
}

body.mitarbeiter::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.3); /* Weißes Overlay mit 70% */
  z-index: -1;
}

@media (max-width: 768px) {
  body,
  body.ansprechpartner,
  body.behandlungspflege,
  body.betreuungsleistungen,
  body.grundpflege,
  body.hauswirtschaft,
  body.index,
  body.leitbild,
  body.mitarbeiter {
    background: none !important;   /* entfernt Bilder */
    background-color: #fff;        /* Ersatz: weißer Hintergrund */
  }
}

/* --- Jobs NEU --- */
.jobs-header h1{ margin-bottom: .3em; }
.jobs-header p{ margin-bottom: 1.2em; }

.jobs-controls{
  display:flex; gap:16px; flex-wrap:wrap; align-items:center; margin:16px 0 12px;
}
.jobs-search{ flex:1 1 240px; }
.jobs-search input{
  width:100%; padding:10px 12px; border:1px solid #ddd; border-radius:8px;
  font-size:15px;
}

.jobs-chips{ display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.jobs-chips .divider{ width:1px; height:20px; background:#e5e5e5; margin:0 6px; }
.chip{
  border:1px solid #e3c9cf; border-radius:999px; padding:6px 12px; background:#fff; cursor:pointer;
  font-size:14px; color:#4A0114;
}
.chip.active{ background:#4A0114; color:#fff; border-color:#4A0114; }

.jobs-grid{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap:16px;
}

.job-card{
  background:#fff; border-radius:12px; box-shadow:0 2px 10px rgba(0,0,0,.06);
  padding:16px; display:flex; flex-direction:column; gap:10px;
}
.job-head h3{ color:#4A0114; font-size:18px; margin-bottom:6px; }
.tags{ display:flex; gap:6px; flex-wrap:wrap; }
.tag{
  font-size:12px; padding:4px 8px; border-radius:999px; background:#fdecef; color:#4A0114; font-weight:600;
}
.tag.muted{ background:#f2f2f2; color:#555; font-weight:500; }

.job-brief p{ margin:0; line-height:1.45; }

.job-details summary{
  cursor:pointer; color:#4A0114; font-weight:600; margin-top:4px;
}
.job-details[open]{ border-top:1px solid #f0e2e5; padding-top:8px; }
.job-details h4{ margin:8px 0 6px; color:#4A0114; }
.job-details .req{ margin-left:18px; }

.job-actions{ margin-top:auto; display:flex; justify-content:flex-end; }
.job-actions .btn-primary{ padding:10px 14px; font-size:14px; }
