/* markenkultour Hero | Author: markenkultour */

.mk-hero {
	--mk-screen: 100vh;
	position: relative;
	display: block;
	width: 100%;
	box-sizing: border-box;
	padding: var(--mk-frame, 5px);
	background: var(--mk-frame-color, #fff);
	margin-top: 0;
	margin-bottom: 0;
}
@supports (height: 100svh) {
	.mk-hero { --mk-screen: 100svh; }
}

/* ---------- Höhe ---------- */
.mk-hero--height-fixed  { height: var(--mk-h, 600px); }
.mk-hero--height-fit    { height: calc(var(--mk-screen) - var(--mk-top, 0px)); min-height: 360px; }
.mk-hero--height-screen { height: calc(var(--mk-screen) - var(--mk-offset, 0px)); min-height: 360px; }

/* ---------- Volle Fensterbreite ---------- */
.mk-hero--full {
	width: var(--mk-vw, 100vw);
	max-width: none;
	margin-left: calc(50% - var(--mk-vw, 100vw) / 2);
	margin-right: 0;
}

.mk-hero__stage {
	position: relative;
	width: 100%;
	height: 100%;
	overflow: hidden;
	background: #d7d7d7;
	isolation: isolate;
}

/* ---------- Hintergrund-Slideshow (Überblendung) ---------- */
.mk-hero__slides {
	position: absolute;
	inset: 0;
	z-index: 0;
}
.mk-hero__slide {
	position: absolute;
	inset: 0;
	opacity: 0;
	transition: opacity var(--mk-fade, 1500ms) ease-in-out;
}
/* Neues Bild blendet über dem alten ein, das alte bleibt darunter stehen */
.mk-hero__slide.is-active { opacity: 1; z-index: 2; }
.mk-hero__slide.is-prev   { opacity: 1; z-index: 1; transition: none; }
.mk-hero .mk-hero__slide img {
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	object-position: center;
	display: block;
	border: 0;
	margin: 0;
}

/* ---------- Kacheln ---------- */
.mk-hero__panels {
	position: absolute;
	inset: 0;
	z-index: 2;
	display: grid;
	grid-template-columns: repeat(var(--mk-cols, 4), minmax(0, 1fr));
	grid-auto-rows: 1fr;
	gap: var(--mk-gap, 10px);
	margin: 0;
	padding: 0;
}
/* Die weißen Trennstreifen: jede Kachel malt die Hälfte des Abstands */
.mk-hero__panel {
	position: relative;
	display: block;
	min-width: 0;
	box-shadow: 0 0 0 calc(var(--mk-gap, 10px) / 2) var(--mk-frame-color, #fff);
	text-decoration: none;
	color: inherit;
	container-type: inline-size;
	-webkit-tap-highlight-color: transparent;
}
.mk-hero__panel:focus { outline: none; }
.mk-hero__panel:focus-visible .mk-hero__circle { outline: 2px solid #fff; outline-offset: 4px; }

.mk-hero__circle {
	position: absolute;
	left: 50%;
	top: var(--mk-c-y, 72%);
	width: min(var(--mk-c-size, 190px), 82cqw, 82%);
	aspect-ratio: 1 / 1;
	transform: translate(-50%, -50%);
	border-radius: 50%;
	background: rgba(var(--mk-c-rgb, 175, 211, 53), var(--mk-c-alpha, 0.6));
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0.35em;
	box-sizing: border-box;
	padding: 8%;
	text-align: center;
	transition: transform 0.35s ease, background-color 0.35s ease;
}
.mk-hero__icon {
	display: block;
	width: min(var(--mk-i-size, 64px), 34cqw);
	height: auto;
	aspect-ratio: 1 / 1;
	color: var(--mk-l-color, #fff);
	flex: 0 0 auto;
	object-fit: contain;
}
.mk-hero .mk-hero__label {
	display: block;
	color: var(--mk-l-color, #fff);
	font-family: Arial, "Helvetica Neue", Helvetica, sans-serif;
	font-size: min(var(--mk-l-size, 30px), 14cqw);
	font-weight: 400;
	line-height: 1.1;
	letter-spacing: 0.02em;
	white-space: nowrap;
}

/* ---------- Hover ---------- */
@media (hover: hover) {
	.mk-hero--hover a.mk-hero__panel:hover .mk-hero__circle {
		transform: translate(-50%, -50%) scale(1.06);
		background: rgba(var(--mk-c-rgb, 175, 211, 53), min(1, calc(var(--mk-c-alpha, 0.6) + 0.25)));
	}
}

/* ---------- Einblenden der Kreise ---------- */
.mk-hero--anim-fade .mk-hero__circle,
.mk-hero--anim-zoom .mk-hero__circle { opacity: 0; }

.mk-hero.is-in.mk-hero--anim-fade .mk-hero__circle,
.mk-hero.is-in.mk-hero--anim-zoom .mk-hero__circle {
	animation-duration: 1.2s;
	animation-timing-function: ease-out;
	animation-fill-mode: forwards;
	animation-delay: calc(var(--mk-delay, 500ms) + var(--mk-i, 0) * var(--mk-stagger, 200ms));
}
.mk-hero.is-in.mk-hero--anim-fade .mk-hero__circle { animation-name: mk-fade; }
.mk-hero.is-in.mk-hero--anim-zoom .mk-hero__circle { animation-name: mk-zoom; }

@keyframes mk-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes mk-zoom {
	from { opacity: 0; transform: translate(-50%, -50%) scale(0.85); }
	to   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

/* ---------- Handy ---------- */
@media (max-width: 767px) {
	.mk-hero--height-fixed { height: var(--mk-h-m, 600px); }
	.mk-hero--m-grid .mk-hero__panels  { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.mk-hero--m-stack .mk-hero__panels { grid-template-columns: minmax(0, 1fr); }
	.mk-hero__circle {
		top: 50%;
		width: min(var(--mk-c-size, 190px), 74cqw, 74cqh, 150px);
	}
	.mk-hero__panel { container-type: size; }
	.mk-hero .mk-hero__label { font-size: min(var(--mk-l-size, 30px), 12cqw, 22px); }
	.mk-hero__icon { width: min(var(--mk-i-size, 64px), 26cqw, 48px); }
}

/* ---------- Barrierefreiheit ---------- */
@media (prefers-reduced-motion: reduce) {
	.mk-hero .mk-hero__circle { opacity: 1 !important; animation: none !important; }
	.mk-hero__slide { transition-duration: 0.01ms; }
}
