.kscm-frontend,
.kscm-map,
.kscm-location-list {
	width: 100%;
}

.kscm-map {
	margin-bottom: 34px;
}

.kscm-map-attribution {
	margin-top: 5px;
	font-size: 11px;
	color: #777;
	text-align: right;
}

.kscm-location-list {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 18px;
}

.kscm-location-card {
	display: flex;
	gap: 18px;
	padding: 20px;
	background: #f6f6f4;
	border-left: 4px solid var(--accent, #eebd00);
}

.kscm-location-logo {
	flex: 0 0 90px;
}

.kscm-location-logo img {
	display: block;
	width: 90px;
	height: 70px;
	object-fit: contain;
	background: #fff;
}

.kscm-location-main {
	min-width: 0;
}

.kscm-location-main h3 {
	margin: 0 0 4px;
	font-size: 22px;
	line-height: 1.15;
}

.kscm-location-zusatz {
	font-weight: 600;
	margin-bottom: 6px;
}

.kscm-location-address {
	margin-bottom: 8px;
}

.kscm-location-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 7px;
	margin: 8px 0;
	font-size: 12px;
}

.kscm-location-meta span {
	display: inline-block;
	padding: 4px 8px;
	background: #fff;
	border: 1px solid #ddd;
}


.kscm-location-info {
	margin-top: 10px;
	font-size: 14px;
	line-height: 1.45;
}

.kscm-location-links {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 12px;
}

.kscm-location-links a {
	font-weight: 700;
	text-decoration: none;
}

.kscm-front-notice {
	padding: 14px 16px;
	background: #f6f6f4;
	border-left: 4px solid var(--accent, #eebd00);
}

@media (max-width: 760px) {
	.kscm-location-list {
		grid-template-columns: 1fr;
	}

	.kscm-location-card {
		padding: 16px;
	}

	.kscm-location-logo {
		flex-basis: 70px;
	}

	.kscm-location-logo img {
		width: 70px;
		height: 58px;
	}
}

/* =========================================================
   V0.9 – RESPONSIVE KARTENAUSGABE
   ========================================================= */

.kscm-map-responsive {
	--kscm-map-height: var(--kscm-map-height-desktop, 480px);
	width: var(--kscm-map-width, 100%);
	max-width: 100%;
	margin-left: auto;
	margin-right: auto;
}

/*
 * Der Leaflet-Shortcode erhält height="var(--kscm-map-height)".
 * Die Variable wird hier responsiv umgeschaltet, ohne die Karte
 * auf kleinen Displays mit einer festen Pixelbreite zu überladen.
 */
@media (max-width: 768px) {
	.kscm-map-responsive {
		--kscm-map-height: var(--kscm-map-height-mobile, 360px);
		width: 100%;
	}
}


/* =========================================================
   V0.10 – GRUPPIERTE STANDORTLISTE
   ========================================================= */

.kscm-location-groups {
	display: grid;
	gap: 34px;
}

.kscm-location-group-title {
	margin: 0 0 16px;
	padding-bottom: 8px;
	border-bottom: 3px solid var(--accent, #eebd00);
	font-size: clamp(24px, 3vw, 34px);
	line-height: 1.15;
}

.kscm-location-group .kscm-location-list {
	margin-top: 0;
}


/* =========================================================
   V0.11 – KONFIGURIERBARE VISITENKARTE
   ========================================================= */

.kscm-location-card {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 18px;
	align-items: start;
}

.kscm-location-card.has-image {
	grid-template-columns: 110px minmax(0, 1fr);
}

.kscm-location-logo {
	display: flex;
	align-items: flex-start;
	justify-content: center;
}

.kscm-location-logo img {
	display: block;
	width: auto;
	height: auto;
	max-width: 100px;
	max-height: 90px;
	object-fit: contain;
}

.kscm-location-main {
	min-width: 0;
}

.kscm-card-name {
	margin: 0 0 5px;
}

.kscm-card-line,
.kscm-card-info {
	margin-top: 4px;
	line-height: 1.45;
}

.kscm-card-label {
	font-weight: 700;
}

.kscm-card-phone a,
.kscm-card-email a,
.kscm-card-web a {
	text-decoration: none;
}

.kscm-card-phone a:hover,
.kscm-card-email a:hover,
.kscm-card-web a:hover {
	text-decoration: underline;
}

.kscm-card-info {
	margin-top: 10px;
}

@media (max-width: 560px) {
	.kscm-location-card.has-image {
		grid-template-columns: 78px minmax(0, 1fr);
		gap: 13px;
	}

	.kscm-location-logo img {
		max-width: 72px;
		max-height: 72px;
	}
}


/* =========================================================
   V0.12 – LISTE → KARTE
   ========================================================= */

.kscm-card-map-action {
	margin-top: 12px;
}

.kscm-show-on-map {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	font-weight: 700;
	text-decoration: none;
	cursor: pointer;
}

.kscm-show-on-map:hover,
.kscm-show-on-map:focus {
	text-decoration: underline;
}

.kscm-map {
	scroll-margin-top: 90px;
}


/* =========================================================
   V1.2 – LISTENLAYOUTS JE KARTE
   ========================================================= */

/* VCard – klassisch: entspricht bewusst dem bisherigen Erscheinungsbild. */
.kscm-layout-classic .kscm-location-list {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kscm-layout-classic .kscm-location-card {
	background: #f6f6f4;
	border-left: 4px solid var(--accent, #eebd00);
	border-radius: 0;
	box-shadow: none;
}

/* Nur Text: kompakt, ohne Bild, ohne Card-Hintergrund oder dekorativen Rahmen. */
.kscm-layout-text .kscm-location-list {
	display: block;
}

.kscm-layout-text .kscm-location-card,
.kscm-layout-text .kscm-location-card.has-image {
	display: block;
	padding: 12px 0 14px;
	margin: 0;
	background: transparent;
	border: 0;
	border-bottom: 1px solid rgba(0,0,0,.12);
	border-radius: 0;
	box-shadow: none;
}

.kscm-layout-text .kscm-location-card:last-child {
	border-bottom: 0;
}

.kscm-layout-text .kscm-location-logo {
	display: none !important;
}

.kscm-layout-text .kscm-card-name {
	font-size: 1.12em;
}

.kscm-layout-text .kscm-card-info {
	margin-top: 7px;
}

.kscm-layout-text .kscm-card-map-action {
	margin-top: 7px;
}

/* Modern: eigenständige, ruhige Cards mit Kriecherl-Akzent. */
.kscm-layout-modern .kscm-location-list {
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 22px;
}

.kscm-layout-modern .kscm-location-card,
.kscm-layout-modern .kscm-location-card.has-image {
	position: relative;
	overflow: hidden;
	padding: 22px;
	gap: 18px;
	background: #fff;
	border: 1px solid rgba(0,0,0,.10);
	border-top: 5px solid var(--accent, #eebd00);
	border-radius: 14px;
	box-shadow: 0 8px 24px rgba(0,0,0,.07);
}

.kscm-layout-modern .kscm-location-card.has-image {
	grid-template-columns: 128px minmax(0, 1fr);
}

.kscm-layout-modern .kscm-location-logo {
	min-height: 94px;
	padding: 8px;
	align-items: center;
	background: #f7f7f5;
	border-radius: 10px;
}

.kscm-layout-modern .kscm-location-logo img {
	max-width: 112px;
	max-height: 88px;
}

.kscm-layout-modern .kscm-card-name {
	margin-bottom: 7px;
	font-size: clamp(21px, 2vw, 27px);
	line-height: 1.15;
}

.kscm-layout-modern .kscm-card-line {
	margin-top: 5px;
}

.kscm-layout-modern .kscm-card-info {
	margin-top: 12px;
	padding-top: 10px;
	border-top: 1px solid rgba(0,0,0,.08);
}

.kscm-layout-modern .kscm-show-on-map {
	margin-top: 2px;
	padding: 7px 11px;
	border: 1px solid var(--accent, #eebd00);
	border-radius: 999px;
}

/*
 * Kriecherl CI: eigenständige Partnerdarstellung passend zur Website.
 * Warme Bildfläche, kräftige gelbe Akzente und bewusst kantige Aktionen.
 */
.kscm-layout-ci {
	--kscm-ci-accent: var(--accent, #eebd00);
	--kscm-ci-ink: #20201d;
	--kscm-ci-cream: #f8f4e6;
}

.kscm-layout-ci .kscm-location-group-title {
	display: flex;
	align-items: center;
	gap: 12px;
	padding-bottom: 11px;
	border-bottom: 1px solid rgba(32, 32, 29, .22);
	color: var(--kscm-ci-ink);
}

.kscm-layout-ci .kscm-location-group-title::before {
	content: "";
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	background: var(--kscm-ci-accent);
	border-radius: 50%;
	box-shadow: 8px -4px 0 rgba(238, 189, 0, .42);
}

.kscm-layout-ci .kscm-location-list {
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
}

.kscm-layout-ci .kscm-location-card,
.kscm-layout-ci .kscm-location-card.has-image {
	position: relative;
	overflow: hidden;
	padding: 0;
	gap: 0;
	background: #fff;
	border: 1px solid rgba(32, 32, 29, .14);
	border-bottom: 5px solid var(--kscm-ci-accent);
	border-radius: 2px;
	box-shadow: 0 10px 28px rgba(32, 32, 29, .08);
	transition: transform .2s ease, box-shadow .2s ease;
}

.kscm-layout-ci .kscm-location-card:hover {
	transform: translateY(-2px);
	box-shadow: 0 14px 34px rgba(32, 32, 29, .12);
}

.kscm-layout-ci .kscm-location-card.has-image {
	grid-template-columns: 145px minmax(0, 1fr);
}

.kscm-layout-ci .kscm-location-logo {
	min-height: 100%;
	padding: 24px 18px;
	align-items: center;
	background: var(--kscm-ci-cream);
	border-right: 1px solid rgba(32, 32, 29, .08);
}

.kscm-layout-ci .kscm-location-logo img {
	max-width: 108px;
	max-height: 96px;
	background: transparent;
}

.kscm-layout-ci .kscm-location-main {
	padding: 24px;
	color: var(--kscm-ci-ink);
}

.kscm-layout-ci .kscm-card-name {
	margin-bottom: 9px;
	font-size: clamp(21px, 2vw, 27px);
	line-height: 1.14;
	color: var(--kscm-ci-ink);
}

.kscm-layout-ci .kscm-card-line {
	margin-top: 5px;
}

.kscm-layout-ci .kscm-card-label {
	font-size: .78em;
	letter-spacing: .055em;
	text-transform: uppercase;
}

.kscm-layout-ci .kscm-card-info {
	margin-top: 13px;
	padding: 11px 0 0 13px;
	border-top: 1px solid rgba(32, 32, 29, .10);
	border-left: 3px solid var(--kscm-ci-accent);
}

.kscm-layout-ci .kscm-card-phone a,
.kscm-layout-ci .kscm-card-email a {
	color: var(--kscm-ci-ink);
	text-decoration-color: var(--kscm-ci-accent);
	text-decoration-thickness: 2px;
	text-underline-offset: 3px;
}

.kscm-layout-ci .kscm-card-web a,
.kscm-layout-ci .kscm-show-on-map {
	display: inline-flex;
	align-items: center;
	max-width: 100%;
	padding: 8px 12px;
	border-radius: 1px;
	font-weight: 700;
	line-height: 1.25;
	overflow-wrap: anywhere;
	text-decoration: none;
}

.kscm-layout-ci .kscm-card-web a {
	margin-top: 4px;
	background: var(--kscm-ci-accent);
	color: #171714;
}

.kscm-layout-ci .kscm-card-web a::after {
	content: "↗";
	margin-left: 7px;
	font-size: 1.05em;
}

.kscm-layout-ci .kscm-card-web a:hover,
.kscm-layout-ci .kscm-card-web a:focus {
	background: var(--kscm-ci-ink);
	color: #fff;
	text-decoration: none;
}

.kscm-layout-ci .kscm-card-map-action {
	margin-top: 14px;
}

.kscm-layout-ci .kscm-show-on-map {
	gap: 6px;
	border: 2px solid var(--kscm-ci-accent);
	color: var(--kscm-ci-ink);
}

.kscm-layout-ci .kscm-show-on-map:hover,
.kscm-layout-ci .kscm-show-on-map:focus {
	background: var(--kscm-ci-accent);
	color: #171714;
	text-decoration: none;
}

@media (max-width: 760px) {
	.kscm-layout-classic .kscm-location-list,
	.kscm-layout-modern .kscm-location-list,
	.kscm-layout-ci .kscm-location-list {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 560px) {
	.kscm-layout-modern .kscm-location-card.has-image {
		grid-template-columns: 82px minmax(0, 1fr);
		padding: 17px;
		gap: 13px;
	}

	.kscm-layout-modern .kscm-location-logo {
		min-height: 72px;
		padding: 5px;
	}

	.kscm-layout-modern .kscm-location-logo img {
		max-width: 70px;
		max-height: 66px;
	}

	.kscm-layout-ci .kscm-location-card.has-image {
		grid-template-columns: 92px minmax(0, 1fr);
	}

	.kscm-layout-ci .kscm-location-logo {
		padding: 17px 10px;
	}

	.kscm-layout-ci .kscm-location-logo img {
		max-width: 72px;
		max-height: 70px;
	}

	.kscm-layout-ci .kscm-location-main {
		padding: 18px 16px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.kscm-layout-ci .kscm-location-card {
		transition: none;
	}
}
