/*
 * com_einzelhandel - Frontend (WFG-Stil)
 */

:root {
	--hwk-primary: #E11D24;
	--hwk-primary-dark: #B0151B;
	--hwk-primary-darker: #8B1015;
	--hwk-primary-soft: #FDEAEB;
	--hwk-text: #2c3e50;
	--hwk-muted: #6b7785;
	--hwk-bg: #F5F6F7;
	--hwk-card-bg: #ffffff;
	--hwk-border: #e6e9ec;
	--hwk-shadow: 0 2px 12px rgba(176, 21, 27, 0.10);
	--hwk-shadow-hover: 0 6px 20px rgba(176, 21, 27, 0.20);
	--hwk-radius: 4px;
	--hwk-radius-lg: 8px;
}

/* ===== Buttons ===== */

.hwk-btn-primary,
.hwk-btn {
	background: var(--hwk-primary);
	color: #fff !important;
	border: 0;
	padding: 8px 18px;
	border-radius: var(--hwk-radius);
	font-size: 0.9rem;
	cursor: pointer;
	text-decoration: none !important;
	display: inline-block;
	transition: background 0.15s ease;
	letter-spacing: 0.3px;
	line-height: 1.45;
}

.hwk-btn-primary:hover,
.hwk-btn:hover {
	background: var(--hwk-primary-dark);
	color: #fff !important;
}

.hwk-btn-outline {
	background: transparent;
	color: var(--hwk-primary-dark) !important;
	border: 1px solid var(--hwk-primary);
}

.hwk-btn-outline:hover {
	background: var(--hwk-primary);
	color: #fff !important;
}

.hwk-btn-back {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.hwk-back-bar {
	margin-bottom: 16px;
}

.hwk-back-bar-bottom {
	margin-top: 24px;
	padding-top: 16px;
	border-top: 1px solid var(--hwk-border);
	margin-bottom: 0;
}

/* ===== List Page ===== */

.com-einzelhandel-list {
	padding: 16px 0;
}

.com-einzelhandel-list .hwk-page-header {
	text-align: center;
	margin-bottom: 28px;
}

.com-einzelhandel-list .hwk-page-title {
	font-size: 1.6rem;
	letter-spacing: 2px;
	text-transform: uppercase;
	color: var(--hwk-primary);
	font-weight: 600;
	margin: 0 0 6px;
}

.com-einzelhandel-list .hwk-page-subtitle {
	color: var(--hwk-muted);
	font-size: 0.95rem;
	margin: 0;
}

.com-einzelhandel-list .einzelhandel-filter {
	background: var(--hwk-card-bg);
	border: 1px solid var(--hwk-border);
	border-radius: var(--hwk-radius-lg);
	padding: 16px 20px;
	margin-bottom: 20px;
	box-shadow: var(--hwk-shadow);
}

.com-einzelhandel-list .einzelhandel-filter .form-control,
.com-einzelhandel-list .einzelhandel-filter .form-select {
	border-radius: var(--hwk-radius);
	border-color: var(--hwk-border);
	font-size: 0.95rem;
}

.com-einzelhandel-list .einzelhandel-filter .form-control:focus,
.com-einzelhandel-list .einzelhandel-filter .form-select:focus {
	border-color: var(--hwk-primary);
	box-shadow: 0 0 0 0.2rem rgba(225, 29, 36, 0.18);
}

.com-einzelhandel-list .hwk-results-count {
	color: var(--hwk-muted);
	font-size: 0.9rem;
	margin-bottom: 14px;
	padding: 0 4px;
}

/* DIV-Tabelle */
.hwk-table {
	background: var(--hwk-card-bg);
	border: 1px solid var(--hwk-border);
	border-radius: var(--hwk-radius-lg);
	overflow: hidden;
	box-shadow: var(--hwk-shadow);
}

.hwk-table-head,
.hwk-table-row {
	display: grid;
	grid-template-columns: 80px minmax(0, 2.4fr) minmax(0, 1.4fr) minmax(0, 1.2fr) minmax(0, 1.2fr) 50px;
	gap: 12px;
	align-items: center;
	padding: 12px 16px;
}

.hwk-table-head {
	background: var(--hwk-primary-soft);
	border-bottom: 2px solid var(--hwk-primary);
}

.hwk-th {
	font-size: 0.78rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1px;
	color: var(--hwk-primary-dark);
}

.hwk-sort {
	color: var(--hwk-primary-dark);
	text-decoration: none;
	display: inline-block;
	padding: 4px 0;
}

.hwk-sort:hover {
	color: var(--hwk-primary-darker);
	text-decoration: underline;
}

.hwk-sort.active {
	color: var(--hwk-primary-darker);
	font-weight: 800;
}

.hwk-table-row {
	border-bottom: 1px solid var(--hwk-border);
	color: var(--hwk-text);
	text-decoration: none;
	transition: background 0.15s ease, box-shadow 0.15s ease;
	cursor: pointer;
}

.hwk-table-row:last-child {
	border-bottom: 0;
}

.hwk-table-row:hover {
	background: var(--hwk-primary-soft);
	color: var(--hwk-text);
	text-decoration: none;
}

.hwk-td {
	font-size: 0.92rem;
	min-width: 0;
}

.hwk-col-logo {
	display: flex;
	justify-content: center;
	align-items: center;
}

.hwk-col-logo img {
	max-width: 64px;
	max-height: 48px;
	object-fit: contain;
}

.hwk-logo-placeholder {
	display: inline-flex;
	width: 48px;
	height: 48px;
	align-items: center;
	justify-content: center;
	color: var(--hwk-primary);
	font-size: 1.5rem;
	background: var(--hwk-primary-soft);
	border-radius: var(--hwk-radius);
	opacity: 0.6;
}

.hwk-firma-name {
	font-weight: 700;
	color: var(--hwk-text);
	letter-spacing: 0.3px;
	text-transform: uppercase;
	font-size: 0.95rem;
	line-height: 1.3;
}

.hwk-firma-teaser {
	font-size: 0.82rem;
	color: var(--hwk-muted);
	margin-top: 3px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.hwk-branche-badge {
	display: inline-block;
	background: var(--hwk-primary);
	color: #fff;
	padding: 3px 10px;
	border-radius: 12px;
	font-size: 0.75rem;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	font-weight: 600;
	white-space: nowrap;
}

.hwk-row-arrow {
	color: var(--hwk-primary);
	font-size: 1.6rem;
	font-weight: 700;
	line-height: 1;
}

.hwk-table-row:hover .hwk-row-arrow {
	color: var(--hwk-primary-darker);
	transform: translateX(2px);
}

.com-einzelhandel-list .pagination-wrap {
	margin-top: 24px;
	display: flex;
	justify-content: center;
}

.com-einzelhandel-list .pagination .page-link {
	color: var(--hwk-primary-dark);
	border-color: var(--hwk-border);
}

.com-einzelhandel-list .pagination .page-item.active .page-link {
	background-color: var(--hwk-primary);
	border-color: var(--hwk-primary);
	color: #fff;
}

/* ===== Detail Page ===== */

.com-einzelhandel-detail {
	padding: 16px 0;
}

.com-einzelhandel-detail .einzelhandel-card {
	background: transparent;
	border: 0;
	padding: 0;
	border-radius: 0;
}

.com-einzelhandel-detail .einzelhandel-hero {
	background: linear-gradient(135deg, #ffffff 0%, var(--hwk-primary-soft) 100%);
	border-radius: var(--hwk-radius-lg);
	padding: 32px;
	box-shadow: var(--hwk-shadow);
	display: flex;
	gap: 28px;
	align-items: center;
	margin-bottom: 24px;
}

.com-einzelhandel-detail .einzelhandel-logo-large {
	flex-shrink: 0;
	background: #fff;
	border-radius: var(--hwk-radius-lg);
	padding: 16px;
	box-shadow: 0 1px 6px rgba(0,0,0,0.08);
}

.com-einzelhandel-detail .einzelhandel-logo-large img {
	display: block;
	max-width: 180px;
	max-height: 160px;
	object-fit: contain;
}

.com-einzelhandel-detail .einzelhandel-title-wrap {
	flex: 1;
}

.com-einzelhandel-detail .einzelhandel-branche {
	display: inline-block;
	background: var(--hwk-primary);
	color: #fff;
	padding: 4px 14px;
	border-radius: 14px;
	font-size: 0.78rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 1px;
	margin-bottom: 12px;
}

.com-einzelhandel-detail .einzelhandel-title {
	font-size: 2rem;
	font-weight: 700;
	color: var(--hwk-text);
	letter-spacing: 0.5px;
	margin: 0 0 8px;
}

.com-einzelhandel-detail .einzelhandel-teaser-large {
	color: var(--hwk-muted);
	font-size: 1.05rem;
	margin: 0;
	line-height: 1.5;
}

/* Section card */
.com-einzelhandel-detail .hwk-section {
	background: #fff;
	border-radius: var(--hwk-radius-lg);
	padding: 28px;
	box-shadow: var(--hwk-shadow);
	margin-bottom: 22px;
	border: 1px solid var(--hwk-border);
}

.com-einzelhandel-detail .hwk-section-title {
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--hwk-primary);
	letter-spacing: 2px;
	text-transform: uppercase;
	margin: 0 0 18px;
	padding-bottom: 12px;
	border-bottom: 2px solid var(--hwk-primary-soft);
}

.com-einzelhandel-detail .einzelhandel-description {
	color: var(--hwk-text);
	line-height: 1.7;
	font-size: 1rem;
}

/* Map */
.com-einzelhandel-detail .hwk-map {
	height: 380px;
	border: 1px solid var(--hwk-border);
	border-radius: var(--hwk-radius-lg);
	overflow: hidden;
	margin-bottom: 16px;
}

.com-einzelhandel-detail .hwk-route-box {
	background: var(--hwk-primary-soft);
	border-radius: var(--hwk-radius-lg);
	padding: 18px 20px;
	margin-top: 16px;
}

.com-einzelhandel-detail .hwk-route-box h3 {
	color: var(--hwk-primary-dark);
	font-size: 1rem;
	font-weight: 600;
	margin-bottom: 12px;
}

/* Contact card */
.com-einzelhandel-detail .einzelhandel-contact {
	background: #fff;
	border-radius: var(--hwk-radius-lg);
	box-shadow: var(--hwk-shadow);
	border: 0;
}

.com-einzelhandel-detail .einzelhandel-contact .card-body {
	padding: 28px;
}

.com-einzelhandel-detail .einzelhandel-contact .card-title {
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--hwk-primary);
	letter-spacing: 2px;
	text-transform: uppercase;
	margin: 0 0 18px;
	padding-bottom: 12px;
	border-bottom: 2px solid var(--hwk-primary-soft);
}

.com-einzelhandel-detail .einzelhandel-contact .hwk-row {
	margin-bottom: 14px;
}

.com-einzelhandel-detail .einzelhandel-contact .hwk-label {
	font-weight: 600;
	display: block;
	color: var(--hwk-muted);
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 1px;
	margin-bottom: 2px;
}

.com-einzelhandel-detail .einzelhandel-contact a {
	color: var(--hwk-primary-dark);
	text-decoration: none;
	word-break: break-word;
}

.com-einzelhandel-detail .einzelhandel-contact a:hover {
	text-decoration: underline;
}

.com-einzelhandel-detail .einzelhandel-contact address {
	margin-bottom: 0;
	font-style: normal;
	color: var(--hwk-text);
	line-height: 1.5;
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
	.hwk-table-head,
	.hwk-table-row {
		grid-template-columns: 60px minmax(0, 2fr) minmax(0, 1fr) 30px;
	}
	.hwk-th.hwk-col-name,
	.hwk-th.hwk-col-ort,
	.hwk-td.hwk-col-name,
	.hwk-td.hwk-col-ort {
		display: none;
	}
}

@media (max-width: 600px) {
	.hwk-table-head {
		display: none;
	}
	.hwk-table-row {
		display: block;
		padding: 14px 16px;
	}
	.hwk-td {
		display: block;
	}
	.hwk-col-logo {
		justify-content: flex-start;
		margin-bottom: 8px;
	}
	.hwk-col-name,
	.hwk-col-ort {
		display: block !important;
		font-size: 0.85rem;
		color: var(--hwk-muted);
		margin-top: 4px;
	}
	.hwk-col-name::before,
	.hwk-col-ort::before {
		content: attr(data-label) ': ';
		font-weight: 600;
		text-transform: uppercase;
		font-size: 0.7rem;
		letter-spacing: 1px;
		display: inline;
	}
	.hwk-col-action {
		display: none;
	}
	.com-einzelhandel-detail .einzelhandel-hero {
		flex-direction: column;
		text-align: center;
		padding: 24px 18px;
	}
	.com-einzelhandel-detail .einzelhandel-title {
		font-size: 1.5rem;
	}
}

/* ================================================================== */
/* Selbst-Registrierung: Button                                       */
/* ================================================================== */
.hwk-register-wrap {
	margin-top: 32px;
	padding-top: 24px;
	border-top: 1px solid var(--hwk-border, #e0e0e0);
	text-align: center;
}

.hwk-btn-register {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 12px 28px;
	background: transparent;
	border: 2px solid var(--hwk-primary, #0055a4);
	border-radius: 8px;
	color: var(--hwk-primary, #0055a4);
	font-size: 0.95rem;
	font-weight: 600;
	cursor: pointer;
	transition: background 0.2s, color 0.2s;
	text-decoration: none;
}
.hwk-btn-register:hover,
.hwk-btn-register:focus {
	background: var(--hwk-primary, #0055a4);
	color: #fff;
	outline: none;
}

/* ================================================================== */
/* Registrierungs-Modal                                               */
/* ================================================================== */

/* Header: Primärfarbe mit weißem Text */
.hwk-register-modal .modal-header {
	background: var(--hwk-primary, #0055a4);
	color: #fff !important;
	border-bottom: none;
	padding: 1.1rem 1.5rem;
	border-radius: 12px 12px 0 0;
}
.hwk-register-modal .modal-title,
.hwk-register-modal .modal-header .modal-title,
.hwk-register-modal .modal-header span[class*="icon-"] {
	color: #fff !important;
	font-weight: 700;
	font-size: 1.1rem;
}
.hwk-register-modal .btn-close {
	filter: invert(1) grayscale(1);
	opacity: 0.85;
}

/* Modal-Content: weicher Schatten, leicht abgerundet */
.hwk-register-modal.modal-content {
	border: none;
	border-radius: 12px;
	box-shadow: 0 8px 40px rgba(0,0,0,0.18);
	overflow: hidden;
}

/* Modal-Body: etwas mehr Padding */
.hwk-register-modal .modal-body {
	padding: 1.5rem;
	background: #f8f9fb;
}

/* Footer */
.hwk-register-modal .modal-footer {
	background: #fff;
	border-top: 1px solid #e9ecef;
	padding: 1rem 1.5rem;
	gap: 0.5rem;
}

/* ------------------------------------------------------------------ */
/* Formular-Sektionen                                                  */
/* ------------------------------------------------------------------ */
.hwk-reg-section {
	background: #fff;
	border: 1px solid #e4e8ee;
	border-radius: 10px;
	padding: 1.1rem 1.2rem 0.8rem;
	margin-bottom: 1rem;
}
.hwk-reg-section:last-of-type {
	margin-bottom: 0;
}

.hwk-reg-legend {
	font-size: 0.72rem;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	color: var(--hwk-primary, #0055a4);
	padding: 0 6px;
	margin-bottom: 0.9rem;
	width: auto;
	float: none;
	background: #fff;
	border-radius: 4px;
}

/* ------------------------------------------------------------------ */
/* Formularfelder: abgerundet                                          */
/* ------------------------------------------------------------------ */
.hwk-register-modal .form-control,
.hwk-register-modal .form-select {
	border-radius: 8px;
	border: 1px solid #ced4da;
	padding: 0.5rem 0.75rem;
	font-size: 0.9rem;
	transition: border-color 0.15s, box-shadow 0.15s;
	background: #fff;
}
.hwk-register-modal .form-control:focus,
.hwk-register-modal .form-select:focus {
	border-color: var(--hwk-primary, #0055a4);
	box-shadow: 0 0 0 3px rgba(0,85,164,0.12);
	outline: none;
}
.hwk-register-modal .form-label {
	font-size: 0.82rem;
	font-weight: 600;
	color: #444;
	margin-bottom: 0.3rem;
}
.hwk-register-modal .form-text {
	font-size: 0.76rem;
	color: #888;
}
.hwk-register-modal .form-check-input {
	border-radius: 4px;
	border: 1.5px solid #ced4da;
	width: 1.1em;
	height: 1.1em;
	margin-top: 0.2em;
}
.hwk-register-modal .form-check-input:checked {
	background-color: var(--hwk-primary, #0055a4);
	border-color:     var(--hwk-primary, #0055a4);
}
.hwk-register-modal .form-check-input:focus {
	box-shadow: 0 0 0 3px rgba(0,85,164,0.15);
}

/* ------------------------------------------------------------------ */
/* Pflichtfeld-Markierung & Hinweise                                   */
/* ------------------------------------------------------------------ */
.hwk-required {
	color: #dc3545;
	margin-left: 2px;
}
.hwk-required-note {
	margin-top: 0.75rem;
	margin-bottom: 0;
	font-size: 0.78rem;
	color: #888;
}

/* ------------------------------------------------------------------ */
/* Datenschutz-Box                                                     */
/* ------------------------------------------------------------------ */
.hwk-dsgvo-section {
	background: #eef4ff;
	border-color: #c0d4f0;
	border-radius: 10px;
}
.hwk-dsgvo-section .form-check-label {
	font-size: 0.85rem;
	line-height: 1.55;
	color: #333;
}

/* ------------------------------------------------------------------ */
/* CAPTCHA                                                             */
/* ------------------------------------------------------------------ */
.hwk-captcha-section {
	padding: 0.8rem 1.2rem;
	border-radius: 10px;
}

/* ------------------------------------------------------------------ */
/* Absende-Button                                                      */
/* ------------------------------------------------------------------ */
.hwk-btn-primary {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: var(--hwk-primary, #0055a4);
	color: #fff;
	border: none;
	border-radius: 8px;
	padding: 0.55rem 1.4rem;
	font-size: 0.95rem;
	font-weight: 600;
	cursor: pointer;
	transition: background 0.2s, box-shadow 0.2s;
}
.hwk-btn-primary:hover,
.hwk-btn-primary:focus {
	background: #003d7a;
	box-shadow: 0 2px 8px rgba(0,85,164,0.25);
	color: #fff;
	outline: none;
}

/* Spinner während des Sendens */
@keyframes hwk-spin {
	to { transform: rotate(360deg); }
}
.icon-spinner::before {
	content: '\27F3';
	display: inline-block;
	animation: hwk-spin 1s linear infinite;
}



/* Editor für die Langbeschreibung im Registrierungsformular */
.hwk-register-modal .hwk-editor-wrap {
	border: 1px solid #ced4da;
	border-radius: 0.375rem;
	background: #fff;
}
.hwk-register-modal .hwk-editor-toolbar {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem;
	padding: 0.5rem;
	border-bottom: 1px solid #dee2e6;
	background: #f8f9fa;
	border-radius: 0.375rem 0.375rem 0 0;
}
.hwk-register-modal .hwk-ed-btn {
	border: 1px solid #ced4da;
	background: #fff;
	border-radius: 0.25rem;
	padding: 0.25rem 0.5rem;
	font-size: 0.9rem;
	cursor: pointer;
}
.hwk-register-modal .hwk-ed-btn:hover,
.hwk-register-modal .hwk-ed-btn:focus,
.hwk-register-modal .hwk-ed-active {
	background: #e9ecef;
	border-color: #adb5bd;
}
.hwk-register-modal .hwk-ed-sep {
	width: 1px;
	background: #dee2e6;
	margin: 0 0.25rem;
}
.hwk-register-modal .hwk-editor-content {
	min-height: 320px;
	max-height: 55vh;
	overflow-y: auto;
	line-height: 1.5;
	border: 0;
	box-shadow: none;
	border-radius: 0 0 0.375rem 0.375rem;
}
.hwk-register-modal .hwk-editor-content:empty::before {
	content: attr(data-placeholder);
	color: #6c757d;
	pointer-events: none;
}

/* Unsichtbares Honeypot-Feld fuer Spam-Bots: bleibt fuer Menschen verborgen. */
.hwk-honeypot {
	position: absolute !important;
	left: -10000px !important;
	top: auto !important;
	width: 1px !important;
	height: 1px !important;
	overflow: hidden !important;
	opacity: 0 !important;
	pointer-events: none !important;
}
.hwk-register-modal .hwk-captcha-answer {
	max-width: 180px;
}

.einzelhandel-opening-hours {
	font-size: 0.95rem;
	line-height: 1.45;
}
.einzelhandel-opening-hours p:last-child,
.einzelhandel-opening-hours ul:last-child,
.einzelhandel-opening-hours ol:last-child {
	margin-bottom: 0;
}
.hwk-opening-hours {
	padding-bottom: 1rem;
	margin-bottom: 1rem;
	border-bottom: 1px solid rgba(0,0,0,.08);
}
