/* Aktivferien Infovideos. Farben über Variablen anpassbar, z. B. im Impreza-CSS:
   :root { --afv-farbe: #e30613; } */
:root {
	--afv-farbe: var(--color-content-primary, #c8102e);
	--afv-text: #1f2a30;
	--afv-grau: #5b666d;
	--afv-linie: #dfe3e6;
	--afv-grund: #f5f6f7;
	--afv-radius: 14px;
}

html.afv-offen { overflow: hidden; }

.afv-fenster { position: fixed; inset: 0; z-index: 100000; display: flex; align-items: center; justify-content: center; padding: 16px; }
.afv-fenster[hidden] { display: none; }
.afv-fenster-grund { position: absolute; inset: 0; background: rgba(15, 22, 26, .62); backdrop-filter: blur(2px); animation: afv-ein .18s ease-out; }
.afv-fenster-box {
	position: relative; width: 100%; max-width: 520px; max-height: calc(100vh - 32px); overflow-y: auto;
	background: #fff; color: var(--afv-text); border-radius: var(--afv-radius); padding: 28px 28px 22px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, .28); animation: afv-hoch .22s ease-out; font-size: 16px; line-height: 1.5;
}
@keyframes afv-ein { from { opacity: 0; } }
@keyframes afv-hoch { from { opacity: 0; transform: translateY(14px); } }
@media (prefers-reduced-motion: reduce) { .afv-fenster-grund, .afv-fenster-box { animation: none; } }

.afv-fenster .afv-zu {
	position: absolute; top: 10px; right: 10px; width: 38px; height: 38px; border: 0; border-radius: 50%;
	background: var(--afv-grund) !important; color: var(--afv-text) !important; font-size: 24px; line-height: 38px; padding: 0; cursor: pointer;
}
.afv-fenster .afv-zu:hover, .afv-fenster .afv-zu:focus-visible { background: var(--afv-linie); }

.afv-kopf { display: flex; gap: 14px; align-items: center; margin: 0 40px 12px 0; }
.afv-bild { flex: 0 0 96px; height: 64px; border-radius: 8px; background: var(--afv-grund) center / cover no-repeat; }
.afv-bild[hidden] { display: none; }
.afv-dach { margin: 0 0 2px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--afv-farbe); }
.afv-fenster h2.afv-video-titel { margin: 0; padding: 0; font-size: 21px; line-height: 1.25; color: var(--afv-text); }
.afv-text { margin: 0 0 16px; color: var(--afv-grau); font-size: 15px; }

/* Fluent Forms im Fenster: ruhig, gross, gut tippbar */
.afv-formular .fluentform .ff-el-group { margin-bottom: 14px; }
.afv-formular .fluentform .ff-t-container { gap: 12px; }
.afv-formular .fluentform .ff-el-input--label label { font-size: 14px; font-weight: 600; color: var(--afv-text); }
.afv-formular .fluentform .ff-el-form-control {
	width: 100%; min-height: 48px; padding: 10px 14px; font-size: 16px; color: var(--afv-text);
	border: 1px solid var(--afv-linie); border-radius: 10px; background: #fff; box-shadow: none; transition: border-color .15s, box-shadow .15s;
}
.afv-formular .fluentform .ff-el-form-control:focus { border-color: var(--afv-farbe); box-shadow: 0 0 0 3px color-mix(in srgb, var(--afv-farbe) 18%, transparent); outline: 0; }
.afv-formular .fluentform .ff-el-form-check { font-size: 14px; color: var(--afv-grau); }
.afv-formular .fluentform .ff-el-form-check-input { width: 18px; height: 18px; margin-right: 6px; vertical-align: -3px; accent-color: var(--afv-farbe); }
.afv-formular .fluentform .ff-btn-submit,
.afv-formular .fluentform button[type="submit"] {
	width: 100%; min-height: 52px; border: 0; border-radius: 10px; background: var(--afv-farbe) !important; color: #fff !important;
	font-size: 17px; font-weight: 700; cursor: pointer; transition: filter .15s;
}
.afv-formular .fluentform .ff-btn-submit:hover { filter: brightness(1.08); }
.afv-formular .fluentform .error, .afv-formular .ff-el-is-error .text-danger { font-size: 13px; color: #b42318; }
.afv-formular .ff-message-success { border: 0; padding: 12px 14px; border-radius: 10px; background: #ecfdf3; color: #05603a; box-shadow: none; }

.afv-meldung { margin: 10px 0 0; padding: 12px 14px; border-radius: 10px; background: #ecfdf3; color: #05603a; font-weight: 600; }
.afv-meldung[hidden] { display: none; }

.afv-schon { margin-top: 14px; border-top: 1px solid var(--afv-linie); padding-top: 12px; font-size: 14px; }
.afv-schon summary { cursor: pointer; color: var(--afv-grau); }
.afv-schon summary:hover { color: var(--afv-text); }
.afv-schon-form { margin-top: 10px; }
.afv-schon-form label { display: block; margin-bottom: 4px; font-weight: 600; }
.afv-schon-zeile { display: flex; gap: 8px; }
.afv-schon-zeile input { flex: 1; min-width: 0; min-height: 44px; padding: 8px 12px; border: 1px solid var(--afv-linie); border-radius: 10px; font-size: 16px; }
.afv-schon-zeile button { min-height: 44px; padding: 0 14px; border: 1px solid var(--afv-text); border-radius: 10px; background: #fff; color: var(--afv-text); font-weight: 600; cursor: pointer; white-space: nowrap; }
.afv-schon-meldung { margin: 6px 0 0; min-height: 1em; color: var(--afv-grau); }

.afv-klein { margin: 12px 0 0; font-size: 12px; color: var(--afv-grau); }
.afv-klein a { color: inherit; text-decoration: underline; }
.afv-hinweis { padding: 10px; background: #fff7e6; border-radius: 8px; }

@media (max-width: 560px) {
	.afv-fenster { align-items: flex-end; padding: 0; }
	.afv-fenster-box { max-width: none; max-height: 92vh; border-radius: var(--afv-radius) var(--afv-radius) 0 0; padding: 22px 18px 18px; }
	.afv-bild { flex-basis: 72px; height: 52px; }
	.afv-fenster h2.afv-video-titel { font-size: 18px; }
	.afv-schon-zeile { flex-direction: column; }
}

/* Player */
.afv-player { position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--afv-radius); background: #10171b; }
.afv-player > iframe, .afv-player > video, .afv-player-bild { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.afv-player > video { object-fit: contain; background: #000; }
.afv-player-start {
	position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
	width: 100%; border: 0; padding: 0; background: linear-gradient(180deg, rgba(0,0,0,.05), rgba(0,0,0,.45)); color: #fff; cursor: pointer;
}
.afv-knopf { position: relative; width: 78px; height: 78px; border-radius: 50%; background: var(--afv-farbe); box-shadow: 0 8px 24px rgba(0,0,0,.35); transition: transform .15s; }
.afv-knopf::after { content: ""; position: absolute; left: 31px; top: 24px; border-style: solid; border-width: 15px 0 15px 24px; border-color: transparent transparent transparent #fff; }
.afv-player-start:hover .afv-knopf, .afv-player-start:focus-visible .afv-knopf { transform: scale(1.07); }
.afv-player-text { font-size: 18px; font-weight: 700; text-shadow: 0 1px 6px rgba(0,0,0,.5); }
.afv-player.is-laedt .afv-knopf { animation: afv-puls 1s infinite; }
@keyframes afv-puls { 50% { opacity: .55; } }
.afv-fehler { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; margin: 0; padding: 20px; color: #fff; text-align: center; }
.afv-player-hinweis { margin-top: 6px; }

.afv-button { display: inline-block; padding: 12px 20px; border-radius: 10px; background: var(--afv-farbe); color: #fff !important; font-weight: 700; text-decoration: none !important; }
.afv-button:hover { filter: brightness(1.08); }

/* Alter Video-Bereich und sein Lade-Hinweis: dauerhaft aus, das Plugin zeigt einen eigenen Player */
html.afv-alt-aus #single-player-video-container,
html.afv-alt-aus #video-loader,
html.afv-alt-aus .video-loader { display: none !important; }

.afv-player > .afv-huelle { position: absolute; inset: 0; display: block; }

/* [infovideo_liste] */
.afv-liste { display: grid; grid-template-columns: repeat(var(--afv-spalten, 3), minmax(0, 1fr)); gap: 24px; margin: 0 0 24px; }
@media (max-width: 900px) { .afv-liste { grid-template-columns: repeat(min(var(--afv-spalten, 3), 2), minmax(0, 1fr)); } }
@media (max-width: 560px) { .afv-liste { grid-template-columns: 1fr; } }
.afv-karte { display: flex; flex-direction: column; gap: 10px; }
.afv-karte-bild { position: relative; display: flex; align-items: center; justify-content: center; aspect-ratio: 16 / 9; border-radius: var(--afv-radius); background: #10171b center / cover no-repeat; overflow: hidden; }
.afv-karte-bild .afv-knopf { width: 60px; height: 60px; }
.afv-karte-bild .afv-knopf::after { left: 24px; top: 18px; border-width: 12px 0 12px 19px; }
.afv-karte-bild:hover .afv-knopf { transform: scale(1.07); }
.afv-karte-titel { margin: 0; font-size: 18px; line-height: 1.3; }
.afv-karte .afv-button { align-self: flex-start; }

/* Teaser über dem Vorschaubild: [infovideo_player titel="…" text="…"] */
.afv-player.hat-teaser .afv-player-start { background: linear-gradient(180deg, rgba(0,0,0,.05) 30%, rgba(0,0,0,.65)); }
.afv-player-teaser { position: absolute; left: 0; right: 0; bottom: 0; padding: 20px 24px; color: #fff; pointer-events: none; display: flex; flex-direction: column; gap: 4px; text-shadow: 0 1px 6px rgba(0,0,0,.5); }
.afv-player-titel { font-size: clamp(18px, 2.4vw, 26px); font-weight: 700; line-height: 1.2; }
.afv-player-unter { font-size: clamp(14px, 1.6vw, 17px); opacity: .92; }
@media (max-width: 560px) {
	.afv-player-teaser { padding: 10px 14px; gap: 2px; }
	.afv-player-unter { font-size: 13px; }
	.afv-player.hat-teaser .afv-player-text { display: none; }
	.afv-player.hat-teaser .afv-player-start { padding-bottom: 60px; }
	.afv-player.hat-teaser .afv-knopf { width: 56px; height: 56px; }
	.afv-player.hat-teaser .afv-knopf::after { left: 22px; top: 16px; border-width: 12px 0 12px 19px; }
}

/* Gegen Button-Stile des Themes (Impreza u. a.): der Startknopf bleibt durchsichtig über dem Vorschaubild */
.afv-player .afv-player-start,
.afv-player .afv-player-start:hover,
.afv-player .afv-player-start:focus {
	background-color: transparent !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	margin: 0 !important;
	min-height: 0 !important;
	height: auto !important;
	color: #fff !important;
	text-transform: none !important;
	letter-spacing: normal !important;
	line-height: 1.3 !important;
	transform: none !important;
}
.afv-player .afv-player-start:focus-visible { outline: 3px solid #fff; outline-offset: -6px; }
