/*
 * Beyondweightcompass — Frontend-Stylesheet für das Einrichtungs-Archiv und die Einrichtungs-Profilseite.
 * Zusammengeführt aus den abgenommenen Mockups 07_mockups/klinikuebersicht.html und
 * 07_mockups/einrichtung-ein-*.html. Platzhalter-Farbpalette — kein Beyondweightcompass-Styleguide
 * existiert bisher.
 */

:root{
  --primary:#1f6f78;
  --primary-dark:#154f56;
  --primary-light:#e4f1f2;
  --bg:#f7f8f6;
  --surface:#ffffff;
  --text:#273238;
  --text-muted:#5c6b70;
  --border:#dfe6e5;
  --ok-bg:#e4f5ea; --ok-text:#1d7a46; --ok-border:#bfe6cf;
  --warn-bg:#fdf3dd; --warn-text:#92660a; --warn-border:#f2dba3;
  --unknown-bg:#eef0ef; --unknown-text:#5c6b70; --unknown-border:#d8dcdb;
  --radius:10px;
}
*{box-sizing:border-box;}
body.bwc-frontend{
  margin:0;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
  background:var(--bg);
  color:var(--text);
  line-height:1.5;
}
.bwc-frontend a{color:var(--primary-dark);}

/* ------------------------------------------------------------------------
 * Header / Footer / Breadcrumb (identisch Archiv + Single)
 * ---------------------------------------------------------------------- */
header.site-header{
  background:var(--surface);
  border-bottom:1px solid var(--border);
  padding:14px 24px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:12px;
}
.wordmark{font-weight:700;font-size:1.15rem;color:var(--primary-dark);text-decoration:none;}
.wordmark span{color:var(--primary);}
nav.site-nav a{
  margin-left:20px;
  text-decoration:none;
  color:var(--text-muted);
  font-size:0.92rem;
}
nav.site-nav a:first-child{margin-left:0;}

.breadcrumb{
  max-width:1200px;
  margin:0 auto;
  padding:14px 24px 0;
  font-size:0.8rem;
  color:var(--text-muted);
}
.breadcrumb a{color:var(--text-muted);text-decoration:none;}
.breadcrumb a:hover{text-decoration:underline;}

footer.site-footer{
  background:var(--primary-dark);
  color:#dce9ea;
  padding:28px 24px;
  font-size:0.82rem;
}
footer.site-footer .disclaimer{
  max-width:900px;
  margin:0 auto 14px;
  color:#c7dadb;
}
footer.site-footer .footer-links{
  max-width:900px;
  margin:0 auto;
  display:flex;
  gap:18px;
  flex-wrap:wrap;
}
footer.site-footer a{color:#ffffff;text-decoration:none;}

/* ------------------------------------------------------------------------
 * Badges / Tags (gemeinsam, Archiv + Single)
 * ---------------------------------------------------------------------- */
.badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:4px 10px;
  border-radius:999px;
  font-size:0.78rem;
  font-weight:600;
  width:fit-content;
}
.badge.ok{background:var(--ok-bg);color:var(--ok-text);border:1px solid var(--ok-border);}
.badge.warn{background:var(--warn-bg);color:var(--warn-text);border:1px solid var(--warn-border);}
.badge.unknown{background:var(--unknown-bg);color:var(--unknown-text);border:1px solid var(--unknown-border);}
.badge.info{background:var(--primary-light);color:var(--primary-dark);border:1px solid #c9dfe0;}

.tag{
  display:inline-block;
  padding:3px 9px;
  border-radius:999px;
  font-size:0.76rem;
  border:1px solid var(--border);
  background:var(--bg);
  color:var(--text-muted);
}
.tag.setting-ambulant{background:#eaf4f1;color:#1d6e5c;border-color:#c9e6dc;}
.tag.setting-stationaer{background:#eceef7;color:#394a9c;border-color:#d3d8ef;}
.tag.setting-online{background:#f3ecf7;color:#6a3b96;border-color:#e2d2ee;}
.tag-row{display:flex;flex-wrap:wrap;gap:6px;}

.unbekannt-value{color:var(--text-muted);font-style:italic;}
.missing-data-flag{
  font-size:0.76rem;
  color:var(--warn-text);
  background:var(--warn-bg);
  border:1px solid var(--warn-border);
  border-radius:6px;
  padding:4px 8px;
  width:fit-content;
}

/* ------------------------------------------------------------------------
 * Archiv: Hero, Toolbar, Filter-Sidebar, Result-List
 * ---------------------------------------------------------------------- */
.hero{
  background:linear-gradient(180deg,var(--primary-light) 0%,var(--bg) 100%);
  padding:40px 24px 28px;
  text-align:center;
}
.hero h1{
  margin:0 0 10px;
  font-size:1.8rem;
  color:var(--primary-dark);
  max-width:760px;
  margin-inline:auto;
}
.hero p{
  margin:0 auto 20px;
  max-width:620px;
  color:var(--text-muted);
  font-size:0.98rem;
}

.toolbar{
  max-width:1200px;
  margin:0 auto;
  padding:18px 24px 0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:12px;
}
.result-count{font-size:0.92rem;color:var(--text-muted);}
.match-note{
  max-width:1200px;
  margin:6px auto 0;
  padding:0 24px;
  font-size:0.8rem;
  color:var(--text-muted);
}

.layout{
  max-width:1200px;
  margin:0 auto;
  padding:20px 24px 60px;
  display:grid;
  grid-template-columns:260px 1fr;
  gap:26px;
  align-items:start;
}

aside.filters{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:4px 0;
}
.filters-header{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:12px 16px;
  border-bottom:1px solid var(--border);
}
.filters-header strong{font-size:0.98rem;}
.filters-header a{font-size:0.82rem;text-decoration:none;}
.filter-group{border-bottom:1px solid var(--border);}
.filter-group:last-child{border-bottom:none;}
.filter-group summary{
  padding:13px 16px;
  cursor:pointer;
  font-size:0.92rem;
  font-weight:600;
  list-style:none;
  display:flex;
  justify-content:space-between;
  align-items:center;
}
.filter-group summary::after{
  content:"+";
  color:var(--text-muted);
  font-weight:400;
}
.filter-group[open] summary::after{content:"–";}
.filter-group summary::-webkit-details-marker{display:none;}
.filter-options{
  padding:0 16px 14px;
  display:flex;
  flex-direction:column;
  gap:8px;
}
.filter-options label{
  font-size:0.86rem;
  color:var(--text-muted);
  display:flex;
  align-items:center;
  gap:8px;
}
.filter-note{
  padding:10px 16px 14px;
  font-size:0.78rem;
  color:var(--text-muted);
  font-style:italic;
}
.filters-footer{padding:12px 16px;border-top:1px solid var(--border);}
.btn-filter-submit{
  width:100%;
  padding:10px 14px;
  background:var(--primary);
  color:#fff;
  border:none;
  border-radius:8px;
  font-size:0.88rem;
  font-weight:600;
  cursor:pointer;
}
.btn-filter-submit:hover{background:var(--primary-dark);}

.result-list{
  display:flex;
  flex-direction:column;
  gap:16px;
}
.empty-state{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:28px;
  text-align:center;
  color:var(--text-muted);
}

.result-card{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:18px;
  display:flex;
  gap:18px;
  align-items:flex-start;
}
.result-thumb{
  flex:0 0 120px;
  width:120px;
  height:120px;
  border-radius:8px;
  background:var(--primary-light);
  color:var(--primary);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:2.3rem;
  overflow:hidden;
}
.result-thumb img{width:100%;height:100%;object-fit:cover;}

.result-body{
  flex:1;
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:8px;
}
.result-body h3{margin:0;font-size:1.08rem;color:var(--text);}
.result-body h3 a{text-decoration:none;color:inherit;}
.result-location{
  font-size:0.82rem;
  color:var(--text-muted);
  display:flex;
  align-items:center;
  gap:4px;
}
.desc{font-size:0.88rem;color:var(--text-muted);margin:0;}

.data-note{
  font-size:0.76rem;
  color:var(--text-muted);
  display:flex;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:6px;
}
.result-footer{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
  border-top:1px dashed var(--border);
  padding-top:10px;
  margin-top:2px;
}
.result-actions{display:flex;align-items:center;gap:16px;}
.details-link{
  font-size:0.85rem;
  font-weight:600;
  color:#fff;
  background:var(--primary);
  padding:8px 14px;
  border-radius:8px;
  text-decoration:none;
  white-space:nowrap;
}
.details-link:hover{background:var(--primary-dark);}
.claim-link{
  font-size:0.76rem;
  color:var(--text-muted);
  text-decoration:none;
}

@media (max-width:860px){
  .layout{grid-template-columns:1fr;}
}
@media (max-width:560px){
  .result-card{flex-direction:column;}
  .result-thumb{width:100%;height:90px;flex-basis:auto;}
}

/* ------------------------------------------------------------------------
 * Profilseite: Detail-Header, Content-Sections, Angebots-Karten
 * ---------------------------------------------------------------------- */
.detail-header{
  max-width:1200px;
  margin:0 auto;
  padding:10px 24px 26px;
}
.parent-org-line{font-size:0.88rem;color:var(--text-muted);margin:6px 0 0;}
.detail-header h1{
  margin:4px 0 6px;
  font-size:1.65rem;
  color:var(--primary-dark);
}
.short-desc{
  font-size:0.98rem;
  color:var(--text);
  margin:6px 0 16px;
  max-width:760px;
}
.action-bar{display:flex;gap:10px;flex-wrap:wrap;}
.btn-primary, .btn-secondary{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:10px 16px;
  border-radius:8px;
  text-decoration:none;
  font-size:0.88rem;
  font-weight:600;
  border:1px solid transparent;
  cursor:pointer;
}
.btn-primary{background:var(--primary);color:#fff;}
.btn-primary:hover{background:var(--primary-dark);}
.btn-secondary{background:var(--surface);color:var(--text);border-color:var(--border);}
.btn-secondary[disabled], .btn-primary[disabled]{
  opacity:0.5;
  cursor:not-allowed;
  pointer-events:none;
}

.content-section{
  max-width:1200px;
  margin:0 auto;
  padding:26px 24px;
  border-top:1px solid var(--border);
}
.content-section h2{
  font-size:1.2rem;
  color:var(--primary-dark);
  margin:0 0 16px;
}

.glance-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(200px,1fr));
  gap:18px;
}
.glance-item dt{
  font-size:0.74rem;
  color:var(--text-muted);
  text-transform:uppercase;
  letter-spacing:.03em;
  margin-bottom:4px;
}
.glance-item dd{margin:0;font-size:0.92rem;}

.map-placeholder{
  background:var(--unknown-bg);
  border:1px dashed var(--unknown-border);
  border-radius:var(--radius);
  padding:36px 20px;
  text-align:center;
  color:var(--text-muted);
  font-size:0.88rem;
}
.map-placeholder p{margin:0 0 10px;}

.offer-card{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:20px;
  margin-bottom:18px;
}
.offer-card h3{margin:0 0 14px;font-size:1.05rem;}
.tag-group{margin-bottom:14px;}
.tag-group:last-child{margin-bottom:0;}
.tag-group-label{
  font-size:0.72rem;
  font-weight:600;
  color:var(--text-muted);
  text-transform:uppercase;
  letter-spacing:.04em;
  margin:0 0 6px;
}
.offer-access-note{
  font-size:0.82rem;
  color:var(--text-muted);
  font-style:italic;
  margin:14px 0 0;
  padding-top:10px;
  border-top:1px dashed var(--border);
}

.gallery-placeholder{display:flex;gap:10px;flex-wrap:wrap;}
.gallery-slot{
  width:150px;
  height:100px;
  border-radius:8px;
  overflow:hidden;
}
.gallery-slot img{width:100%;height:100%;object-fit:cover;}

.about-text h3{font-size:1.0rem;color:var(--text);margin:20px 0 8px;}
.about-text h3:first-child{margin-top:0;}
.about-text p{font-size:0.92rem;color:var(--text);line-height:1.65;margin:0 0 10px;}

.similar-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
  gap:16px;
}
.similar-card{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:16px;
  display:flex;
  flex-direction:column;
  gap:8px;
}
.similar-card h3{font-size:0.96rem;margin:0;}
.similar-card .result-location{font-size:0.8rem;color:var(--text-muted);}
.similar-card .details-link{
  font-size:0.8rem;
  font-weight:600;
  color:#fff;
  background:var(--primary);
  padding:7px 12px;
  border-radius:8px;
  text-decoration:none;
  width:fit-content;
}
.similar-card .details-link:hover{background:var(--primary-dark);}
.similar-note{font-size:0.8rem;color:var(--text-muted);margin:0 0 14px;}

.claim-box{
  background:var(--primary-light);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:20px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:16px;
  flex-wrap:wrap;
}
.claim-box h3{margin:0 0 6px;font-size:1rem;color:var(--primary-dark);}
.claim-box p{margin:0;font-size:0.85rem;color:var(--text-muted);max-width:540px;}
.claim-box-actions{display:flex;gap:10px;flex-wrap:wrap;}
.verified-plus-hint{
  margin-top:14px;
  font-size:0.78rem;
  color:var(--text-muted);
  max-width:760px;
}

@media (max-width:680px){
  .claim-box{flex-direction:column;align-items:flex-start;}
}

/* ------------------------------------------------------------------------
 * Korrektur-/Claim-Formular
 * ---------------------------------------------------------------------- */
.bwc-correction-form{
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:22px;
  margin-top:18px;
  max-width:560px;
}
.bwc-correction-form .form-row{margin-bottom:16px;}
.bwc-correction-form label{
  display:block;
  font-size:0.86rem;
  font-weight:600;
  margin-bottom:6px;
  color:var(--text);
}
.bwc-correction-form .radio-row{display:flex;gap:18px;margin-bottom:16px;}
.bwc-correction-form .radio-row label{
  display:flex;
  align-items:center;
  gap:6px;
  font-weight:400;
  margin-bottom:0;
}
.bwc-correction-form input[type="text"],
.bwc-correction-form input[type="email"],
.bwc-correction-form textarea{
  width:100%;
  padding:9px 12px;
  border:1px solid var(--border);
  border-radius:8px;
  font-size:0.9rem;
  font-family:inherit;
  color:var(--text);
  background:var(--surface);
}
.bwc-correction-form textarea{min-height:110px;resize:vertical;}
.bwc-correction-form .bwc-honeypot{
  position:absolute;
  left:-9999px;
  top:auto;
  width:1px;
  height:1px;
  overflow:hidden;
}
.bwc-form-feedback{
  border-radius:8px;
  padding:12px 14px;
  margin-bottom:16px;
  font-size:0.88rem;
}
.bwc-form-feedback.success{background:var(--ok-bg);color:var(--ok-text);border:1px solid var(--ok-border);}
.bwc-form-feedback.error{background:var(--warn-bg);color:var(--warn-text);border:1px solid var(--warn-border);}
.bwc-form-feedback ul{margin:6px 0 0;padding-left:18px;}

/* ------------------------------------------------------------------------
 * Monetarisierung (Platzhalter, nicht im MVP aktiv)
 * ---------------------------------------------------------------------- */
.ad-slot{
  border:1px dashed var(--border);
  border-radius:var(--radius);
  padding:16px;
  text-align:center;
  color:var(--text-muted);
  font-size:0.78rem;
  background:var(--bg);
}
.ad-slot .ad-label{
  font-size:0.68rem;
  text-transform:uppercase;
  letter-spacing:.05em;
  color:var(--text-muted);
  display:block;
  margin-bottom:6px;
}
