/*
 * fx12_video — kompakte Videozeile mit Logo.
 *
 * Schriftgroessen, Farben und Container kommen aus project.css. Hier stehen nur
 * Layout, Abstaende und Zustaende dieses Moduls. Kein Hex, keine font-family,
 * keine font-size in px — alles ueber Tokens.
 *
 * Reihenfolge: 1. Grundregeln, 2. Buehne, 3. Media-Queries zuletzt.
 */

/* ---------- 1 Flaeche und Raster ---------- */

section.fx12_video {
	background: var(--fx-navy);
}

/*
 * Rechte Spalte als minmax(0, 600px) statt fester 600px: zwischen 992px und
 * etwa 1250px reicht die Breite sonst nicht fuer Textspalte + Abstand + Buehne
 * und das Raster laeuft aus dem Viewport.
 */
section.fx12_video .fx12_raster {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 600px);
	gap: 72px;
}

section.fx12_video .fx12_text {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: 32px;
	min-width: 0;
}

section.fx12_video .fx12_topline {
	margin-bottom: 18px;
}

section.fx12_video .fx12_titel {
	margin: 0;
	font-size: var(--fx-fs-h2-video);
	line-height: 1.08;
	color: var(--fx-white);
}

/* ---------- 2 Logo-Zeile ---------- */

section.fx12_video .fx12_marke {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	padding-top: 26px;
	border-top: 1px solid var(--fx-rule-dark);
}

section.fx12_video .fx12_logo {
	display: flex;
	align-items: center;
	gap: 16px;
	min-width: 0;
}

/*
 * Die Logo-PNGs sind blau auf transparent. brightness(0) macht sie schwarz,
 * invert(1) daraus reines Weiss — die Transparenz bleibt dabei erhalten.
 */
section.fx12_video .fx12_logo_mark,
section.fx12_video .fx12_logo_word {
	display: block;
	width: auto;
	filter: brightness(0) invert(1);
}

section.fx12_video .fx12_logo_mark { height: 56px; }
section.fx12_video .fx12_logo_word { height: 30px; }

section.fx12_video .fx12_claim {
	text-align: right;
	line-height: 1.5;
	letter-spacing: var(--fx-ls-button);
	color: var(--fx-ice);
}

/* Die Kurzfassung gilt erst unter 992px. */
section.fx12_video .fx12_claim--kurz {
	display: none;
}

/* Nachgeben muss das Logo, nicht der Claim: sonst bricht die Ortszeile zwischen
   992 und 1299px um und "&" haengt allein am Zeilenende. Zwischen 992 und ~1180px
   ragt die Claim-Box dabei ueber die Wortmarke — kollisionsfrei nur, weil die
   Leerzeilen im Claim-Feld die Textzeilen ueber und unter das Logo setzen. */
section.fx12_video .fx12_claim--lang {
	flex-shrink: 0;
}

/* ---------- 3 Buehne ---------- */

/*
 * aspect-ratio liefert die breitenbasierte Hoehe (600 x 9/16 = 338px bei
 * Entwurfsbreite), max-height deckelt sie zusaetzlich an der Bildschirmhoehe —
 * zusammen also min(breitenbasiert, --fx-buehne-mittel).
 * align-self: center, damit eine laengere Textspalte die Buehne nicht streckt
 * und dabei das Seitenverhaeltnis ueberschreibt.
 */
section.fx12_video .fx12_buehne {
	position: relative;
	align-self: center;
	aspect-ratio: 16 / 9;
	max-height: var(--fx-buehne-mittel);
	background: var(--fx-navy-deep);
	overflow: hidden;
}

section.fx12_video .fx12_video_el {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	background: var(--fx-navy-deep);
}

section.fx12_video .fx12_sprosse {
	position: absolute;
	left: 46%;
	inset-block: 0;
	width: 3px;
	background: var(--fx-glare-28);
	pointer-events: none;
}

section.fx12_video .fx12_play {
	position: absolute;
	left: 0;
	bottom: 0;
	z-index: 2;
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 18px 24px;
	min-height: 48px;
	border: 0;
	border-radius: 0;
	background: var(--fx-white);
	color: var(--fx-navy);
	font: 700 var(--fx-fs-label-gross)/1 var(--font-body);
	letter-spacing: var(--fx-ls-button);
	text-transform: uppercase;
	cursor: pointer;
}

/*
 * Kein eigener Farbwechsel: den Wisch nach --fx-tint vergibt project.css
 * global ueber .fx12_play::before und die Variable --fx-wisch.
 */

/* ZWINGEND — display:flex auf .fx12_play schlaegt [hidden] sonst. */
section.fx12_video .fx12_play[hidden] {
	display: none;
}

section.fx12_video .fx12_play_icon {
	display: inline-flex;
	color: var(--fx-azure);
}

section.fx12_video .fx12_play_icon--pause { display: none; }
section.fx12_video .fx12_play.is-laeuft .fx12_play_icon--play { display: none; }
section.fx12_video .fx12_play.is-laeuft .fx12_play_icon--pause { display: inline-flex; }

section.fx12_video .fx12_badge {
	position: absolute;
	right: 12px;
	top: 12px;
	z-index: 2;
	padding: 8px 12px;
	background: var(--fx-overlay-deep);
	color: var(--fx-white);
}

/* ---------- 4 Media-Queries ---------- */

/* Unterhalb von etwa 1280px frisst der 72er-Abstand die Textspalte auf. */
@media (min-width: 992px) and (max-width: 1279px) {
	section.fx12_video .fx12_raster { gap: 40px; }
	section.fx12_video .fx12_logo_mark { height: 44px; }
	section.fx12_video .fx12_logo_word { height: 24px; }
}

@media (max-width: 991px) {
	/*
	 * Einspaltig, und die Reihenfolge dreht sich: Ueberschrift, Video, Logo-Zeile.
	 * display: contents loest die Textspalte auf, damit Kopf und Logo-Zeile als
	 * eigene Rasterzeilen um die Buehne herum sortiert werden koennen.
	 */
	section.fx12_video .fx12_raster {
		grid-template-columns: minmax(0, 1fr);
		gap: 0;
	}

	section.fx12_video .fx12_text { display: contents; }

	section.fx12_video .fx12_kopf   { order: 1; }
	section.fx12_video .fx12_buehne { order: 2; }
	section.fx12_video .fx12_marke  { order: 3; }

	section.fx12_video .fx12_topline { margin-bottom: 12px; }
	section.fx12_video .fx12_titel   { margin-bottom: 18px; }

	/*
	 * FEHLENDES TOKEN: der Entwurf verlangt hier 26px. --fx-fs-h2-band steht
	 * unter 992px auf 32px. --fx-fs-h3-referenz trifft die 26px exakt und dient
	 * hier als Platzhalter, bis ein eigenes Token existiert.
	 */
	section.fx12_video .fx12_titel { line-height: 1.1; }

	/* Mobil uebernehmen die nativen Controls — eigener Knopf und Sprosse entfallen. */
	section.fx12_video .fx12_buehne {
		align-self: stretch;
		max-height: none;
	}

	section.fx12_video .fx12_sprosse,
	section.fx12_video .fx12_play { display: none; }

	section.fx12_video .fx12_marke {
		margin-top: 18px;
		padding-top: 16px;
		gap: 12px;
	}

	section.fx12_video .fx12_logo { gap: 10px; }
	section.fx12_video .fx12_logo_mark { height: 32px; }
	section.fx12_video .fx12_logo_word { height: 17px; }

	section.fx12_video .fx12_claim {
		line-height: 1.4;
		letter-spacing: var(--fx-ls-versal);
	}

	section.fx12_video .fx12_claim--lang { display: none; }
	section.fx12_video .fx12_claim--kurz { display: block; }

	section.fx12_video .fx12_badge {
		right: 8px;
		top: 8px;
		padding: 7px 10px;
	}
}

/* Ab hier wird die Logo-Zeile eng: Bildmarke, Wortmarke und Claim in einer
   Zeile passen unter 360px nicht mehr nebeneinander. */
@media (max-width: 359px) {
	section.fx12_video .fx12_marke {
		flex-wrap: wrap;
		gap: 10px;
	}

	section.fx12_video .fx12_claim {
		flex: 1 0 100%;
		text-align: left;
	}

	section.fx12_video .fx12_logo_mark { height: 28px; }
	section.fx12_video .fx12_logo_word { height: 15px; }
}

@media (prefers-reduced-motion: reduce) {
	section.fx12_video .fx12_play { transition: none; }
}
