/* =========================================================
   M34 - Referenzen (dunkler Abschnitt, BG der aktiven Referenz)
   Links: Header + Liste (Auto-Advance). Rechts: Testimonial-Card.
   Tokens: hell #f4f5f2 | braun #685a51 | orange #f48520 | dunkel #271b11
   Font-Sizes in rem, Spacing in px.
   ========================================================= */

section.m34_referenzen {
	position: relative;
	overflow: hidden;
	color: #f4f5f2;
}
/* Hintergrundbild (wird per JS zur aktiven Referenz gewechselt) */
section.m34_referenzen .m34_bg {
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	z-index: 0;
	max-width: 50%;
	right: 0;
	top: 0;
	left: 50%;
}
/* Solides braunes Panel links (Bild liegt nur rechts, Figma 9:2) */
section.m34_referenzen .m34_overlay {
	position: absolute;
	left: 0;
	top: 0;
	bottom: 0;
	width: 50%;
	z-index: 1;
	background-color: #4a2e15;
}
section.m34_referenzen .mM_container {
	position: relative;
	z-index: 2;
}

section.m34_referenzen .m34_inner {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 64px;
}
section.m34_referenzen .m34_left {
	flex: 0 0 46%;
	max-width: 46%;
}
/* Testimonial-Card: absolut zur Section -> horizontal mittig in der rechten Bildregion (rechts vom Panel),
   vertikal 60px Abstand zum unteren Section-Rand (Figma). */
section.m34_referenzen .m34_right {
	position: absolute;
	left: 50%;            /* Bildregion = rechts vom braunen Panel (50%) */
	right: 0;
	bottom: 60px;
	z-index: 2;
	display: flex;
	justify-content: center;   /* horizontal mittig zum Bild */
}

/* ---------- Header ---------- */
section.m34_referenzen .m34_header {
	margin-bottom: 38px;
}
section.m34_referenzen .m34_topline {
	display: block;
	margin-bottom: 2px;
	font-size: 1.0625rem;   /* 17px */
	font-weight: 800;
	text-transform: uppercase;
	color: #f48520;
}
section.m34_referenzen .m34_titel,
section.m34_referenzen .m34_titel * {
	margin: 0;
	text-transform: uppercase;
	font-weight: 800;
	color: #f4f5f2;
}
section.m34_referenzen .m34_links {
	margin-top: 49px;
}

/* ---------- Liste ---------- */
section.m34_referenzen .m34_list {
	display: flex;
	flex-direction: column;
}
/* Trennlinie Button <-> Liste (Figma): 2px hoch, links buendig mit dem Bildrand
   (Item-Padding 20px) und rechts der gleiche Versatz. */
section.m34_referenzen .m34_list::before {
	content: '';
	display: block;
	height: 2px;
	margin: 0 20px 23px;
	background-color: rgba(244, 245, 242, 0.3);
}
section.m34_referenzen .m34_item {
	position: relative;
	display: flex;
	align-items: center;
	gap: 27px;
	width: 100%;
	padding: 16px 20px;
	background: transparent;
	border: 0;
	border-radius: 0;   /* evtl. geerbten Button-Radius entfernen */
	cursor: pointer;
	text-align: left;
	transition: background-color 0.3s ease;
}
section.m34_referenzen .m34_item.is-active {
	background-color: #685a51;
}
section.m34_referenzen .m34_item_thumb {
	flex: 0 0 56px;
	width: 56px;
	height: 56px;
	overflow: hidden;
	background: rgba(244,245,242,0.1);
}
section.m34_referenzen .m34_item_thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
section.m34_referenzen .m34_item_text {
	display: flex;
	flex-direction: column;
	line-height: 25px;
	min-width: 0;   /* Flex-Child darf schrumpfen -> Text bricht um statt abgeschnitten zu werden */
	white-space: normal;   /* globales Button-nowrap aufheben, sonst kein Umbruch */
}
section.m34_referenzen .m34_item_name {
	font-size: 1.0625rem;   /* 17px */
	font-weight: 600;
	color: #f4f5f2;
	overflow-wrap: break-word;
	word-break: break-word;
}
section.m34_referenzen .m34_item_branche {
	font-size: 1.0625rem;   /* 17px */
	font-weight: 400;
	color: rgba(244,245,242,0.5);
	overflow-wrap: break-word;
	word-break: break-word;
}
/* Fortschrittsleiste am unteren Rand des aktiven Items */
section.m34_referenzen .m34_item_progress {
	position: absolute;
	left: 0;
	bottom: 0;
	width: 100%;
	height: 3px;
	background-color: rgba(244,245,242,0.3);
	opacity: 0;
}
section.m34_referenzen .m34_item.is-active .m34_item_progress {
	opacity: 1;
}
section.m34_referenzen .m34_item_progress_fill {
	display: block;
	width: 0;
	height: 100%;
	background-color: #f48520;
}

/* ---------- Testimonial-Card ---------- */
section.m34_referenzen .m34_card {
	position: relative;
	width: 70%;            /* ~35vw der Bildregion, wie Figma (684/1920) */
	max-width: 684px;
	margin: 0;
	padding: 56px 56px 55px 72px;   /* top right bottom left */
	background-color: #271b11;   /* solid, nicht transparent */
}
section.m34_referenzen .m34_quote_mark {
	display: block;
	margin-bottom: -24px;   /* Zitat naeher heranziehen (Figma) */
	font-family: 'Inter', sans-serif;
	font-weight: 800;
	font-size: 4.6875rem;   /* 75px */
	line-height: 1;   /* grosse line-height erzeugte zu viel Abstand zum Zitat */
	color: #f48520;
}
section.m34_referenzen .m34_card_zitat {
	margin: 0 0 34px;
	font-size: 1.375rem;   /* 22px */
	line-height: 32px;
	font-weight: 400;
	color: #f4f5f2;
}
section.m34_referenzen .m34_card_person {
	font-style: normal;
	font-size: 1.0625rem;   /* 17px */
	font-weight: 400;
	color: rgba(244,245,242,0.6);
}
section.m34_referenzen .m34_card_name {
	font-weight: 600;
}

section.m34_referenzen .m34_quote_mark.m34_quote_mark--eckdaten {
	font-size: 1.2rem;
	margin-bottom: 0;
}

section.m34_referenzen .m34_card_zitat.m34_card_eckdaten {
	font-size: 1rem;
	margin-bottom: 0;
}

/* =========================================================
   Responsive
   ========================================================= */
@media screen and (max-width: 991px) {
	/* Gestapeltes Layout: Header+Liste -> Bild -> Zitat-Card.
	   Section bleibt Block (damit .mM_container seine native, zentrierte Breite/Gutter behaelt);
	   das Braun kommt als Section-Hintergrund, das absolute Overlay (das sonst Bild + Card
	   ueberdecken wuerde) entfaellt. Reihenfolge ergibt sich aus dem Markup (Bild steht vor der Card). */
	section.m34_referenzen {
		background-color: #4a2e15;
	}
	section.m34_referenzen .m34_overlay {
		display: none;
	}
	/* Bild aus der absoluten Lage in den Fluss holen (sonst vom Panel verdeckt) */
	section.m34_referenzen .m34_bg {
		position: relative;
		inset: auto;
		width: 100%;
		height: 500px;
		margin-top: 48px;
		max-width: 100%;
	}
	section.m34_referenzen .m34_inner {
		flex-direction: column;
		align-items: stretch;   /* Liste auf volle Breite (sonst nur Inhaltsbreite -> wirkt abgeschnitten) */
		gap: 40px;
	}
	section.m34_referenzen .m34_left {
		flex: 1 1 auto;
		max-width: 100%;
	}
	/* Card unter das Bild, leicht ueberlappend. position:relative -> z-index greift wieder. */
	section.m34_referenzen .m34_right {
		position: relative;
		left: auto;
		right: auto;
		bottom: auto;
		z-index: 2;
		margin-top: -56px;
		padding: 0 24px;
	}
	section.m34_referenzen .m34_card {
		width: 100%;
		max-width: 100%;
	}
	section.m34_referenzen .m34_header {
		margin-bottom: 32px;
	}
	section.m34_referenzen .m34_titel,
	section.m34_referenzen .m34_titel * {
		font-size: 2.25rem;   /* 36px */
		line-height: 1.15;
	}
}

@media screen and (max-width: 600px) {
	section.m34_referenzen .m34_bg {
		height: 420px;
		margin-top: 32px;
	}
	section.m34_referenzen .m34_card {
		padding: 40px 24px 32px;
	}
	section.m34_referenzen .m34_item {
		padding: 14px 16px;
		gap: 16px;
	}
}
