/* ==========================================================
   BDHN Praxenverzeichnis - Frontend Layout
   Nutzt Typografie des Themes, definiert nur Struktur & Farben.
   ========================================================== */

/* Icon-Größen (nur size, keine font-family) */
.bdhn-praxen-wrap .material-icons-outlined,
.bdhn-form-wrap .material-icons-outlined,
.bdhn-popup .material-icons-outlined {
	font-size: 1.15em;
}

/* --- Container ------------------------------------------- */
.bdhn-praxen-wrap {
	margin: 1.5em 0;
}

/* --- Steuerelemente (Suche + Filter) --------------------- */
.bdhn-controls {
	margin-bottom: 1.25em;
}

.bdhn-search-wrap {
	position: relative;
	max-width: 500px;
	margin-bottom: 0.75em;
}

.bdhn-search-icon {
	position: absolute;
	left: 0.7em;
	top: 50%;
	transform: translateY(-50%);
	color: #888;
	pointer-events: none;
}

.bdhn-search {
	width: 100%;
	padding: 0.6em 2.4em 0.6em 2.4em;
	border: 1px solid #ccc;
	border-radius: 4px;
	background: #fff;
	box-sizing: border-box;
}

.bdhn-search:focus {
	outline: 2px solid #2563eb;
	outline-offset: 1px;
	border-color: #2563eb;
}

.bdhn-search-clear {
	position: absolute;
	right: 0.4em;
	top: 50%;
	transform: translateY(-50%);
	background: transparent;
	border: 0;
	padding: 0.3em;
	cursor: pointer;
	color: #666;
	border-radius: 3px;
}

.bdhn-search-clear:hover { color: #000; background: #f0f0f0; }

/* --- Kategorien-Chips ------------------------------------ */
.bdhn-kat-filter {
	display: flex;
	flex-wrap: wrap;
	gap: 0.4em;
	margin-bottom: 0.75em;
}

.bdhn-kat-chip {
	padding: 0.35em 0.85em;
	background: #f0f0f0;
	border: 1px solid #ddd;
	border-radius: 999px;
	cursor: pointer;
	line-height: 1.2;
	color: inherit;
}

.bdhn-kat-chip:hover { background: #e5e5e5; }

.bdhn-kat-chip.is-active {
	background: #2563eb;
	border-color: #2563eb;
	color: #fff;
}

.bdhn-search-count {
	color: #666;
	min-height: 1.2em;
}

/* --- Liste (Grid) --------------------------------------- */
.bdhn-praxen-liste {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 1em;
}

.bdhn-praxis {
	background: #fff;
	border: 1px solid #e5e5e5;
	border-radius: 6px;
	padding: 1em 1.2em;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
	transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

.bdhn-praxis:hover,
.bdhn-praxis.is-highlighted {
	box-shadow: 0 3px 12px rgba(0, 0, 0, 0.1);
	border-color: #2563eb;
}

.bdhn-praxis-name {
	margin: 0 0 0.4em;
	color: inherit;
}

.bdhn-praxis-kats {
	display: flex;
	flex-wrap: wrap;
	gap: 0.3em;
	margin-bottom: 0.6em;
}

.bdhn-praxis-kat {
	display: inline-block;
	padding: 0.15em 0.55em;
	background: #eef2ff;
	color: #3730a3;
	border-radius: 3px;
	line-height: 1.3;
}

.bdhn-praxis-row {
	display: flex;
	align-items: baseline;
	gap: 0.5em;
	margin: 0.35em 0;
	line-height: 1.45;
}

.bdhn-icon {
	color: #666;
	flex-shrink: 0;
}

.bdhn-praxis a {
	text-decoration: none;
	color: inherit;
	border-bottom: 1px dotted currentColor;
}

.bdhn-praxis a:hover,
.bdhn-praxis a:focus {
	border-bottom-style: solid;
}

.bdhn-praxis-adresse a { border-bottom: none; }
.bdhn-praxis-adresse a:hover { text-decoration: underline; }

.bdhn-praxis-leistungen {
	margin-top: 0.75em;
	padding-top: 0.75em;
	border-top: 1px solid #eee;
	color: #555;
}

.bdhn-empty {
	text-align: center;
	padding: 2em;
	color: #888;
	font-style: italic;
}

/* --- Karte ---------------------------------------------- */
.bdhn-map {
	width: 100%;
	min-height: 300px;
	border-radius: 6px;
	z-index: 0;
	background: #f0f0f0;
}

/* --- Kombinierte Ansicht (Karte + Liste) ---------------- */
.bdhn-kombi-layout {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1.5em;
}

@media (min-width: 900px) {
	.bdhn-kombi-layout {
		grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
	}
	.bdhn-view-kombi .bdhn-kombi-map-col { position: sticky; top: 20px; height: fit-content; }
	.bdhn-view-kombi .bdhn-kombi-list-col { max-height: 700px; overflow-y: auto; padding-right: 0.5em; }
	.bdhn-view-kombi .bdhn-praxen-liste { grid-template-columns: 1fr; }
}

/* --- Karten-Popup --------------------------------------- */
.bdhn-popup {
	line-height: 1.5;
	min-width: 220px;
}

.bdhn-popup h4 {
	margin: 0 0 0.5em;
}

.bdhn-popup > div {
	margin: 0.25em 0;
	display: flex;
	align-items: baseline;
	gap: 0.5em;
}

.bdhn-popup a { color: #2563eb; text-decoration: none; }
.bdhn-popup a:hover { text-decoration: underline; }

.bdhn-popup-leistungen {
	margin-top: 0.5em;
	padding-top: 0.5em;
	border-top: 1px solid #eee;
	color: #555;
	max-height: 100px;
	overflow-y: auto;
	display: block !important;
}

/* --- Frontend-Formular ---------------------------------- */
.bdhn-form-wrap {
	max-width: 800px;
	margin: 1.5em 0;
}

.bdhn-form-notice {
	display: flex;
	align-items: center;
	gap: 0.5em;
	padding: 0.75em 1em;
	border-radius: 4px;
	margin-bottom: 1em;
	background: #eef;
	border-left: 4px solid #2563eb;
}

.bdhn-form-notice--success {
	background: #ecfdf5;
	border-left-color: #10b981;
	color: #065f46;
}

.bdhn-form-notice--error {
	background: #fef2f2;
	border-left-color: #ef4444;
	color: #991b1b;
}

.bdhn-form-status {
	margin-bottom: 1em;
}

.bdhn-status-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.35em;
	padding: 0.3em 0.75em;
	border-radius: 999px;
	background: #f0f0f0;
	color: #555;
}

.bdhn-status-badge.bdhn-status-publish {
	background: #d1fae5;
	color: #065f46;
}

.bdhn-form-grid {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: 1em;
}

.bdhn-form-field { grid-column: span 3; }
.bdhn-form-field--full { grid-column: span 6; }
.bdhn-form-field--wide { grid-column: span 4; }
.bdhn-form-field--narrow { grid-column: span 2; }

@media (max-width: 600px) {
	.bdhn-form-field,
	.bdhn-form-field--full,
	.bdhn-form-field--wide,
	.bdhn-form-field--narrow {
		grid-column: span 6;
	}
}

.bdhn-form-field label {
	display: block;
	margin-bottom: 0.3em;
	font-weight: 600;
}

.bdhn-form-field input,
.bdhn-form-field textarea {
	width: 100%;
	padding: 0.55em 0.75em;
	border: 1px solid #ccc;
	border-radius: 4px;
	background: #fff;
	box-sizing: border-box;
	font: inherit;
}

.bdhn-form-field input:focus,
.bdhn-form-field textarea:focus {
	outline: 2px solid #2563eb;
	outline-offset: 1px;
	border-color: #2563eb;
}

.bdhn-form-checkboxes {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 0.4em 1em;
	padding: 0.75em;
	background: #f9fafb;
	border: 1px solid #eee;
	border-radius: 4px;
}

.bdhn-form-cb {
	display: flex;
	align-items: center;
	gap: 0.5em;
	cursor: pointer;
	font-weight: normal !important;
}

.bdhn-form-cb input { width: auto !important; margin: 0; }

.bdhn-form-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5em;
	margin-top: 1.5em;
	padding-top: 1em;
	border-top: 1px solid #eee;
}

.bdhn-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	padding: 0.6em 1.2em;
	border: 1px solid transparent;
	border-radius: 4px;
	cursor: pointer;
	background: #f0f0f0;
	color: inherit;
	line-height: 1.3;
	font: inherit;
}

.bdhn-btn:hover { background: #e5e5e5; }

.bdhn-btn-primary {
	background: #2563eb;
	color: #fff;
}

.bdhn-btn-primary:hover { background: #1d4ed8; }

.bdhn-btn-secondary {
	background: #fff;
	border-color: #ccc;
}

.bdhn-btn-danger {
	background: #fff;
	color: #b91c1c;
	border-color: #fca5a5;
}

.bdhn-btn-danger:hover { background: #fef2f2; }

/* --- Accessibility ------------------------------------- */
.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	padding: 0; margin: -1px; overflow: hidden;
	clip: rect(0, 0, 0, 0); border: 0;
}
