/* evergreetz – neue Erstellungsseite (v2). Wird nur auf der Vorschau geladen.
   Markenfarben aus dem Logo: Cyan "Ever" + Orange "greetz", Akzente Gelb/Pink.
   Weiße Schrift nur auf --v2-blue/--v2-blue-deep bzw. --v2-btn (WCAG geprüft). */

:root {
	--v2-cyan: #00a9dd;
	--v2-blue: #0083c4;
	--v2-blue-deep: #00609f;
	--v2-orange: #ff6a13;
	--v2-orange-dark: #c93c00;
	--v2-btn: #e04a00;
	--v2-yellow: #ffc928;
	--v2-pink: #ff4f8b;
	--v2-pink-dark: #b81d57;
	--v2-ink: #1f2a33;
	--v2-ink-2: #55606a;
	--v2-line: #d5e3eb;
	--v2-bg: #eef9fd;
	--v2-card: #ffffff;
	--v2-radius: 24px;
	--v2-shadow: 0 2px 4px rgba(0, 72, 110, .06), 0 14px 32px rgba(0, 72, 110, .10);
}

body { background: var(--v2-bg); }
header { background: #fff; position: relative; z-index: 1; }

/* Kopfbereich: einfarbiges Band, Deko-Kreise nur an den Rändern */
.v2-hero {
	position: relative;
	overflow: hidden;
	padding: 40px 16px 88px;
	background: linear-gradient(160deg, var(--v2-blue), var(--v2-blue-deep));
	text-align: center;
	isolation: isolate;
}
.v2-hero::before,
.v2-hero::after {
	content: '';
	position: absolute;
	z-index: -1;
	border-radius: 50%;
}
.v2-hero::before {
	width: 220px;
	height: 220px;
	left: -90px;
	top: -70px;
	background: var(--v2-yellow);
}
.v2-hero::after {
	width: 160px;
	height: 160px;
	right: -50px;
	top: 20px;
	background: var(--v2-pink);
	box-shadow: -60px 150px 0 -40px var(--v2-orange);
}
.v2-hero h1 {
	max-width: 760px;
	margin: 0 auto 22px;
	font-family: 'Poppins', sans-serif;
	font-size: clamp(24px, 4.4vw, 38px);
	font-weight: 900;
	line-height: 1.2;
	color: #fff;
	text-wrap: balance;
}
.v2-progress {
	list-style: none;
	display: inline-flex;
	gap: 8px;
	flex-wrap: wrap;
	justify-content: center;
	margin: 0;
	padding: 0;
}
.v2-progress li {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 6px 16px 6px 6px;
	border-radius: 999px;
	background: #fff;
	color: var(--v2-ink);
	font-size: 14px;
	font-weight: 700;
	box-shadow: 0 4px 0 rgba(0, 40, 80, .25);
}
.v2-progress span {
	display: inline-grid;
	place-items: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	color: #fff;
	font-size: 13px;
}
.v2-progress li:nth-child(1) span { background: var(--v2-blue); }
.v2-progress li:nth-child(2) span { background: var(--v2-btn); }
.v2-progress li:nth-child(3) span { background: var(--v2-pink-dark); }
.v2-progress li:nth-child(4) span { background: #7a4fd0; }

/* Inhalt: Karten ragen in den Kopfbereich hinein */
main.v2 {
	position: relative;
	margin-top: -60px;
	padding: 0 16px 56px;
	background: none;
	text-align: left;
	color: var(--v2-ink);
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
main.v2 * { font-family: inherit; }

.v2-card {
	--accent: var(--v2-blue);
	--accent-soft: #e0f3fc;
	position: relative;
	max-width: 760px;
	margin: 0 auto 20px;
	padding: 28px;
	background: var(--v2-card);
	border-radius: var(--v2-radius);
	box-shadow: var(--v2-shadow);
}
.v2-card[data-step="2"] { --accent: var(--v2-btn);       --accent-soft: #ffeadd; }
.v2-card[data-step="3"] { --accent: var(--v2-pink-dark); --accent-soft: #ffe4ee; }
.v2-card[data-step="4"] { --accent: #7a4fd0;             --accent-soft: #eee6ff; }

main.v2 h2.v2-step {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0 0 20px;
	font-family: 'Poppins', sans-serif;
	font-size: 21px;
	line-height: 1.25;
	color: var(--v2-ink);
}
.v2-num {
	flex: 0 0 auto;
	display: inline-grid;
	place-items: center;
	width: 36px;
	height: 36px;
	border-radius: 12px;
	background: var(--accent);
	color: #fff;
	font-size: 18px;
	font-weight: 900;
	transform: rotate(-6deg);
	box-shadow: 0 3px 0 rgba(0, 0, 0, .18);
}

/* Schritt 1: Figuren */
.v2-chars {
	display: grid;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: 8px;
}
.v2-char {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	padding: 12px 4px;
	border: 2px solid transparent;
	border-radius: 18px;
	background: none;
	cursor: pointer;
	color: var(--v2-ink-2);
	font-size: 14px;
	font-weight: 700;
	transition: background .15s, border-color .15s;
}
.v2-char img {
	width: 100%;
	max-width: 88px;
	height: auto;
	transition: transform .2s;
}
.v2-char span { padding: 2px 10px; border-radius: 999px; }
.v2-char:hover { background: var(--accent-soft); }
.v2-char:hover img { transform: translateY(-3px) rotate(-4deg); }
.v2-char[aria-checked="true"] {
	border-color: var(--accent);
	background: var(--accent-soft);
}
.v2-char[aria-checked="true"] span { background: var(--accent); color: #fff; }

/* Schritt 2: Motive (horizontal wischbar) */
.v2-motifs {
	display: flex;
	gap: 14px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-padding-inline: 8px;
	padding: 8px 8px 14px;
	margin: -8px -8px 0;
	scrollbar-width: thin;
}
.v2-motifs[hidden] { display: none; }
.v2-motif {
	position: relative;
	flex: 0 0 auto;
	width: 128px;
	scroll-snap-align: start;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
	color: var(--v2-ink-2);
	font-size: 14px;
	font-weight: 700;
	text-align: center;
}
.v2-motif img {
	width: 128px;
	height: 128px;
	border-radius: 18px;
	object-fit: cover;
	outline: 4px solid transparent;
	outline-offset: 2px;
	transition: outline-color .15s, transform .15s;
}
.v2-motif:hover img { transform: scale(1.03); }
.v2-motif[aria-checked="true"] { color: var(--v2-orange-dark); }
.v2-motif[aria-checked="true"] img { outline-color: var(--v2-orange); }
.v2-motif[aria-checked="true"]::after {
	content: '';
	position: absolute;
	top: 8px;
	right: 8px;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: var(--v2-btn) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 18px no-repeat;
	box-shadow: 0 2px 6px rgba(0, 0, 0, .25);
}

/* Formular-Gruppen */
main.v2 form#my-form {
	display: block;
	text-align: left;
}
.v2-group {
	border: 0;
	margin: 0 0 22px;
	padding: 0;
	min-width: 0;
}
.v2-card > .v2-group:last-child { margin-bottom: 0; }
.v2-group legend {
	margin-bottom: 10px;
	padding: 0;
	font-size: 15px;
	font-weight: 800;
	color: var(--v2-ink);
}

/* Chips = Radiobuttons */
.v2-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.v2-chip {
	position: relative;
	margin: 0 !important;
	cursor: pointer;
}
.v2-chip input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: pointer;
}
.v2-chip span {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 42px;
	padding: 0 16px 0 12px;
	border: 2px solid var(--v2-line);
	border-radius: 999px;
	background: #fff;
	color: var(--v2-ink);
	font-size: 15px;
	font-weight: 600;
	transition: background .12s, border-color .12s, color .12s, transform .12s;
}
.v2-chip i { font-style: normal; font-size: 18px; line-height: 1; }
.v2-chip:hover span { border-color: var(--accent); }
.v2-chip input:checked + span {
	border-color: var(--accent);
	background: var(--accent);
	color: #fff;
	transform: translateY(-1px);
	box-shadow: 0 3px 0 rgba(0, 0, 0, .18);
}
.v2-chip input:focus-visible + span { outline: 3px solid var(--v2-ink); outline-offset: 2px; }

/* Eingabefelder */
main.v2 input[type="text"],
main.v2 textarea {
	width: 100%;
	height: 50px;
	margin: 0;
	padding: 0 16px;
	border: 2px solid var(--v2-line);
	border-radius: 14px;
	background: #fff;
	box-shadow: none;
	font-size: 16px;
	color: var(--v2-ink);
	transition: border-color .15s, box-shadow .15s;
}
main.v2 textarea {
	height: 110px;
	padding: 12px 16px;
	resize: vertical;
}
main.v2 input[type="text"]:focus,
main.v2 textarea:focus {
	outline: none;
	border-color: var(--accent);
	box-shadow: 0 0 0 4px var(--accent-soft);
}
#morereasondiv { margin-top: 10px; }
#morereasondiv[hidden] { display: none; }

.v2-names {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}
main.v2 label { margin: 0; font-size: 15px; color: var(--v2-ink); }
.v2-field { display: flex; flex-direction: column; gap: 6px; }
.v2-field > span { font-size: 13px; font-weight: 700; color: var(--v2-ink-2); }

/* Schalter */
main.v2 .v2-switch {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0 0 14px;
	padding: 12px 14px;
	border-radius: 14px;
	background: var(--accent-soft);
	cursor: pointer;
	font-weight: 600;
}
.v2-switch input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
	margin: 0;
}
.v2-switch-track {
	flex: 0 0 auto;
	position: relative;
	width: 46px;
	height: 28px;
	border-radius: 999px;
	background: #b9c6ce;
	transition: background .15s;
}
.v2-switch-track::after {
	content: '';
	position: absolute;
	top: 3px;
	left: 3px;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
	transition: transform .15s;
}
.v2-switch input:checked + .v2-switch-track { background: var(--accent); }
.v2-switch input:checked + .v2-switch-track::after { transform: translateX(18px); }
.v2-switch input:focus-visible + .v2-switch-track { outline: 3px solid var(--v2-ink); outline-offset: 2px; }
.v2-reveal { margin: -4px 0 16px; }
.v2-reveal[hidden] { display: none; }

/* Foto-Upload (Slim) */
.v2-upload .slim {
	max-width: 220px;
	margin: 0 auto;
	border: 2px dashed var(--accent);
	border-radius: 18px;
	background: var(--accent-soft);
	color: var(--v2-ink-2);
	cursor: pointer;
}
.v2-upload .slim .slim-label { color: var(--v2-ink); font-size: 14px; }
.v2-upload .slim .slim-label u { color: var(--accent); font-weight: 800; }

/* Einwilligung */
main.v2 .v2-consent {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	margin: 8px 0 16px;
	padding: 14px;
	border-radius: 14px;
	border: 2px solid var(--v2-line);
	font-size: 14px;
	line-height: 1.5;
	color: var(--v2-ink-2);
}
main.v2 .v2-consent input[type="checkbox"] {
	flex: 0 0 auto;
	width: 22px;
	height: 22px;
	margin: 0;
	accent-color: var(--accent);
}
.v2-consent a { color: var(--accent); font-weight: 700; }

main.v2 .cf-turnstile { display: flex; justify-content: center; margin-bottom: 16px; }

/* Absenden */
main.v2 button.v2-cta {
	display: block;
	width: 100%;
	margin: 8px 0 0;
	padding: 18px 24px;
	border: 0;
	border-radius: 16px;
	background: linear-gradient(180deg, var(--v2-btn), var(--v2-orange-dark));
	box-shadow: 0 6px 0 #8a2e00, 0 16px 28px rgba(201, 60, 0, .35);
	color: #fff;
	font-family: 'Poppins', sans-serif;
	font-size: 22px;
	font-weight: 900;
	cursor: pointer;
	transition: transform .1s, box-shadow .1s, filter .15s;
}
main.v2 button.v2-cta:hover { filter: brightness(1.06); color: #fff; }
main.v2 button.v2-cta:active { transform: translateY(4px); box-shadow: 0 2px 0 #8a2e00, 0 6px 12px rgba(201, 60, 0, .3); }
main.v2 button.v2-cta:focus-visible { outline: 3px solid var(--v2-ink); outline-offset: 4px; }

.v2-hint { margin: 10px 0 0; font-size: 13px; color: var(--v2-ink-2); text-align: center; }
.v2-center { text-align: center; }

.v2-char:focus-visible,
.v2-motif:focus-visible { outline: 3px solid var(--v2-ink); outline-offset: 2px; border-radius: 18px; }

/* Modal für Warte- und Abspielseite */
.v2-modal {
	position: fixed;
	inset: 0;
	z-index: 100;
	display: grid;
	place-items: center;
	padding: 16px;
	background: rgba(0, 45, 80, .6);
	backdrop-filter: blur(4px);
}
.v2-modal.lightbox-hidden { display: none; }
.v2-modal-panel {
	position: relative;
	width: 100%;
	max-width: 560px;
	height: min(820px, 100%);
	border: 4px solid #fff;
	border-radius: 28px;
	overflow: hidden;
	background: var(--v2-blue-deep);
	box-shadow: 0 24px 64px rgba(0, 0, 0, .35);
}
.v2-modal-close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	width: 42px;
	height: 42px;
	border: 0;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 2px 6px rgba(0, 0, 0, .2);
	color: var(--v2-ink);
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
}
.v2-modal #response-frame {
	display: block;
	width: 100%;
	height: 100%;
	border: 0;
}

@media (max-width: 640px) {
	.v2-hero { padding: 28px 16px 80px; }
	.v2-hero::before { width: 120px; height: 120px; left: -70px; top: -60px; }
	.v2-hero::after { width: 90px; height: 90px; right: -50px; top: auto; bottom: 40px; box-shadow: none; }
	.v2-progress li { padding: 4px 12px 4px 4px; font-size: 13px; }
	.v2-progress span { width: 22px; height: 22px; font-size: 12px; }
	.v2-card { padding: 22px 16px; border-radius: 20px; }
	main.v2 h2.v2-step { font-size: 19px; }
	.v2-chars {
		display: flex;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		scroll-padding-inline: 16px;
		margin: 0 -16px;
		padding: 0 16px 4px;
	}
	.v2-char { flex: 0 0 88px; scroll-snap-align: start; }
	.v2-motifs { margin: -8px -16px 0; padding: 8px 16px 14px; scroll-padding-inline: 16px; }
	.v2-motif, .v2-motif img { width: 112px; }
	.v2-motif img { height: 112px; }
	.v2-chip span { min-height: 40px; padding: 0 14px 0 10px; font-size: 14px; }
	.v2-names { grid-template-columns: 1fr; }
	.v2-modal { padding: 0; }
	.v2-modal-panel { max-width: none; height: 100%; border: 0; border-radius: 0; }
}

@media (prefers-reduced-motion: reduce) {
	main.v2 *, .v2-modal *, .v2-hero * { transition: none !important; }
}

/* Desktop: alle Motive sichtbar, kein verstecktes Scrollen */
@media (min-width: 641px) {
	.v2-motifs { flex-wrap: wrap; overflow: visible; margin: -8px -8px 0; }
}

/* Scroll-Aufbau (html.v2-anim setzt create/template.v2.inc.php nur bei erlaubter Bewegung) */
@keyframes v2-rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes v2-pop { 0% { opacity: 0; transform: scale(.6); } 70% { transform: scale(1.06); } }
.v2-anim .v2-hero h1 { animation: v2-rise .7s cubic-bezier(.2, .8, .2, 1) both; }
.v2-anim .v2-progress li { animation: v2-pop .5s cubic-bezier(.2, .8, .2, 1) both; }
.v2-anim .v2-progress li:nth-child(1) { animation-delay: .25s; }
.v2-anim .v2-progress li:nth-child(2) { animation-delay: .35s; }
.v2-anim .v2-progress li:nth-child(3) { animation-delay: .45s; }
.v2-anim .v2-progress li:nth-child(4) { animation-delay: .55s; }
.v2-anim [data-reveal] {
	opacity: 0;
	transform: translateY(28px);
	transition: opacity .6s ease, transform .7s cubic-bezier(.2, .8, .2, 1);
	transition-delay: var(--d, 0ms);
}
.v2-anim .v2-char[data-reveal], .v2-anim .v2-motif[data-reveal] { transform: translateY(16px) scale(.9); }
.v2-anim [data-reveal].is-in { opacity: 1; transform: none; }
.v2-anim .v2-card.is-in .v2-num { animation: v2-pop .5s cubic-bezier(.2, .8, .2, 1) .15s both; }
