/* Sternsinger Feucht – verspielte Ergänzungen zu theme.json
   Bildsprache: Sterne, Kreide, Klebezettel, Polaroid – wie selbst gebastelt. */

:root {
	--ss-stern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23ffc73a' stroke='%23e0a000' stroke-width='1' stroke-linejoin='round' d='M12 1.8l2.9 6.6 7.2.6-5.5 4.7 1.7 7-6.3-3.8-6.3 3.8 1.7-7L1.9 9l7.2-.6z'/%3E%3C/svg%3E");
	--ss-welle: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 40' preserveAspectRatio='none'%3E%3Cpath d='M0 0h1200v20c-50 0-75 18-150 18S975 4 900 4s-75 34-150 34S675 4 600 4s-75 34-150 34S375 4 300 4s-75 34-150 34S75 20 0 20z'/%3E%3C/svg%3E");
	--ss-schatten: 4px 5px 0 var(--wp--preset--color--dunkel);
}

html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { animation: none !important; transition: none !important; } }

body {
	-webkit-font-smoothing: antialiased;
	/* ein paar verstreute Punkte im Hintergrund */
	background-image:
		radial-gradient(circle at 12% 18%, rgba(255, 199, 58, .18) 0 3px, transparent 4px),
		radial-gradient(circle at 78% 42%, rgba(123, 63, 160, .12) 0 3px, transparent 4px),
		radial-gradient(circle at 35% 76%, rgba(30, 143, 166, .12) 0 3px, transparent 4px);
	background-size: 260px 260px, 340px 340px, 300px 300px;
}
.wp-site-blocks { overflow-x: clip; }
.ss-main .wp-block-post-content > * + * { margin-block-start: 0; }

/* ---------- Kopfzeile ---------- */
.ss-header { position: sticky; top: 0; z-index: 50; border-bottom: 3px solid var(--wp--preset--color--gold); }
.admin-bar .ss-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .ss-header { top: 46px; } }
.ss-brand { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--wp--preset--color--dunkel); line-height: 1; }
.ss-brand__text { font-family: var(--wp--preset--font-family--fredoka); font-weight: 700; font-size: 1.35rem; }
.ss-brand small { display: block; font-weight: 500; font-size: .85rem; color: var(--wp--preset--color--lila); margin-top: .15rem; }
.ss-brand__star { width: 2.6rem; height: 2.6rem; flex: none; background: var(--ss-stern) center / contain no-repeat; transition: transform .4s; }
.ss-brand:hover .ss-brand__star { transform: rotate(72deg) scale(1.1); }
.ss-header__cta .wp-block-button__link { padding: .45em 1.1em; font-size: 1.05rem; }

/* ---------- Buttons wie Sticker ---------- */
.wp-block-button__link {
	box-shadow: var(--ss-schatten); border: 2px solid var(--wp--preset--color--dunkel) !important;
	transition: transform .15s, box-shadow .15s;
}
.wp-block-button__link:hover { transform: translate(-1px, -2px) rotate(-1.5deg); box-shadow: 6px 7px 0 var(--wp--preset--color--dunkel); }
.wp-block-button__link:active { transform: translate(3px, 4px); box-shadow: 1px 1px 0 var(--wp--preset--color--dunkel); }
.wp-block-button.is-style-outline .wp-block-button__link { background: var(--wp--preset--color--weiss); color: var(--wp--preset--color--dunkel); }

/* ---------- Wellenkante unten an Bildern ---------- */
.ss-welle { -webkit-mask: linear-gradient(#000 0 0) top / 100% calc(100% - 38px) no-repeat, var(--ss-welle) bottom / 100% 40px no-repeat;
	mask: linear-gradient(#000 0 0) top / 100% calc(100% - 38px) no-repeat, var(--ss-welle) bottom / 100% 40px no-repeat; }

/* ---------- Hero ---------- */
.ss-hero { min-height: min(82vh, 48rem) !important; }
.ss-hero .wp-block-cover__inner-container { width: 100%; max-width: 1120px; margin-inline: auto; }
.ss-hero .wp-block-cover__inner-container > * { margin-inline: 0 !important; }
.ss-sticker {
	position: relative; background: var(--wp--preset--color--weiss); color: var(--wp--preset--color--dunkel);
	max-width: 34rem; padding: 1.6rem 1.8rem 1.8rem; border-radius: 22px; border: 3px solid var(--wp--preset--color--dunkel);
	box-shadow: 8px 9px 0 var(--wp--preset--color--rot); transform: rotate(-1.5deg);
}
.ss-sticker h1 { margin: .2rem 0 .8rem; color: var(--wp--preset--color--dunkel); }
.ss-sticker > p:not(.ss-badge) { margin: 0 0 1.3rem; font-size: 1.15rem; }
.ss-sticker::after { /* großer Stern oben rechts am Sticker */
	content: ""; position: absolute; width: 5.5rem; height: 5.5rem; right: -2rem; top: -2.4rem;
	background: var(--ss-stern) center / contain no-repeat; transform: rotate(14deg);
	animation: ss-funkeln 4s ease-in-out infinite;
}
@keyframes ss-funkeln { 0%, 100% { transform: rotate(14deg) scale(1); } 50% { transform: rotate(26deg) scale(1.08); } }
.ss-badge {
	display: inline-block; margin: 0; padding: .2rem .8rem; border-radius: 999px; transform: rotate(-3deg);
	background: var(--wp--preset--color--tuerkis); color: #fff; font-family: var(--wp--preset--font-family--fredoka); font-weight: 600; font-size: 1rem;
}
.ss-kringel { position: relative; white-space: nowrap; color: var(--wp--preset--color--rot); isolation: isolate; }
.ss-kringel::after { /* gemalte Unterstreichung */
	content: ""; position: absolute; left: -2%; right: -2%; bottom: -.2em; height: .35em;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 20' preserveAspectRatio='none'%3E%3Cpath d='M3 14c40-9 80-11 120-8 25 2 50 4 74-2' fill='none' stroke='%23ffc73a' stroke-width='6' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
	z-index: -1;
}
.ss-credit-img { position: absolute; right: .9rem; bottom: 3rem; margin: 0 !important; font-size: .7rem !important; color: rgba(255, 255, 255, .85); z-index: 2; }

/* ---------- Termin als Klebezettel ---------- */
.ss-zettel {
	position: relative; max-width: 34rem; margin: 0 auto; padding: 1.8rem 1.6rem 1.4rem;
	background: #fff3a8; transform: rotate(1.2deg); border-radius: 4px 4px 18px 4px;
	box-shadow: 0 14px 18px -10px rgba(42, 31, 61, .35);
}
.ss-zettel::before { /* Klebestreifen */
	content: ""; position: absolute; top: -14px; left: 50%; width: 120px; height: 30px; transform: translateX(-50%) rotate(-3deg);
	background: rgba(255, 255, 255, .65); border: 1px dashed rgba(42, 31, 61, .15);
}
.ss-zettel p { margin: 0 0 .3rem; }
.ss-zettel .ss-zettel__titel { font-family: var(--wp--preset--font-family--fredoka); font-weight: 600; color: var(--wp--preset--color--lila); font-size: 1.1rem; }
.ss-zettel .ss-zettel__datum { font-family: var(--wp--preset--font-family--fredoka); font-weight: 700; font-size: clamp(1.5rem, 4.5vw, 2rem); line-height: 1.15; color: var(--wp--preset--color--rot); }

/* ---------- Überschriften mit Stern ---------- */
h2.ss-stern { position: relative; padding-left: 2.6rem; }
h2.ss-stern::before {
	content: ""; position: absolute; left: 0; top: .05em; width: 2.1rem; height: 2.1rem;
	background: var(--ss-stern) center / contain no-repeat; transform: rotate(-12deg);
}

/* ---------- „Wusstest du …“ als Sprechblasen ---------- */
.ss-wusstest { color: var(--wp--preset--color--lila); margin-top: 2rem !important; }
.ss-blasen { list-style: none; padding: 0; margin: 1rem 0 2rem; display: grid; gap: 1.4rem; }
.ss-blasen li {
	position: relative; padding: 1rem 1.2rem; border-radius: 20px; border: 2.5px solid var(--wp--preset--color--dunkel);
	background: #fff; font-size: 1.1rem; line-height: 1.5;
}
.ss-blasen li::after { /* Zipfel der Sprechblase */
	content: ""; position: absolute; bottom: -12px; left: 2.2rem; width: 20px; height: 20px; background: inherit;
	border-right: 2.5px solid var(--wp--preset--color--dunkel); border-bottom: 2.5px solid var(--wp--preset--color--dunkel); transform: rotate(45deg);
}
.ss-blasen li:nth-child(1) { background: #ffe1e0; transform: rotate(-.8deg); }
.ss-blasen li:nth-child(2) { background: #dff3f6; transform: rotate(.7deg); margin-left: 2rem; }
.ss-blasen li:nth-child(2)::after { left: auto; right: 2.2rem; }
.ss-blasen li:nth-child(3) { background: #efe3f6; transform: rotate(-.5deg); }
@media (max-width: 600px) { .ss-blasen li:nth-child(2) { margin-left: .8rem; } }

/* ---------- Kreide-Zeile ---------- */
.ss-kreide { letter-spacing: .04em; transform: rotate(-2deg); }
.ss-band h2 { text-shadow: 2px 3px 0 rgba(42, 31, 61, .55); }

/* ---------- Video wie ein Fernseher ---------- */
.ss-fernseher video {
	width: 100%; height: auto; aspect-ratio: 16 / 9; background: #000; display: block;
	border-radius: 22px; border: 10px solid var(--wp--preset--color--dunkel); box-shadow: 8px 9px 0 var(--wp--preset--color--tuerkis);
}
.ss-fernseher figcaption { font-size: .85rem; color: #6b5f74; margin-top: .9rem; }

/* ---------- Anmeldeformular ---------- */
.ss-form {
	background: #fff; padding: clamp(1.25rem, 3vw, 2rem); border-radius: 22px;
	border: 3px solid var(--wp--preset--color--dunkel); box-shadow: 8px 9px 0 var(--wp--preset--color--gold);
}
.ss-form .wpcf7-form { display: grid; gap: 1.1rem; }
.ss-form label { display: grid; gap: .35rem; font-weight: 600; }
.ss-form input[type="text"], .ss-form input[type="email"], .ss-form input[type="tel"] {
	width: 100%; box-sizing: border-box; font: inherit; font-weight: 400; padding: .75rem .9rem;
	border: 2px solid #cfc3d9; border-radius: 14px; background: var(--wp--preset--color--creme); color: inherit;
}
.ss-form input:focus-visible { outline: 3px solid var(--wp--preset--color--gold); outline-offset: 1px; border-color: var(--wp--preset--color--lila); }
.ss-form .wpcf7-quiz-label { font-weight: 600; display: block; margin-bottom: .35rem; }
.ss-form .wpcf7-quiz { width: 8rem !important; }
.ss-form .wpcf7-acceptance .wpcf7-list-item { margin: 0; }
.ss-form .wpcf7-acceptance label { display: flex; gap: .6rem; align-items: flex-start; font-weight: 400; font-size: .95rem; line-height: 1.5; }
.ss-form .wpcf7-acceptance input { width: 1.3rem; height: 1.3rem; margin-top: .1rem; flex: none; accent-color: var(--wp--preset--color--rot); }
.ss-form input[type="submit"] {
	font-family: var(--wp--preset--font-family--fredoka); font-weight: 600; font-size: 1.2rem; cursor: pointer;
	border: 2px solid var(--wp--preset--color--dunkel); border-radius: 16px; padding: .65em 1.6em;
	background: var(--wp--preset--color--rot); color: #fff; justify-self: start; box-shadow: var(--ss-schatten); transition: transform .15s, box-shadow .15s;
}
.ss-form input[type="submit"]:hover { transform: translate(-1px, -2px) rotate(-1.5deg); box-shadow: 6px 7px 0 var(--wp--preset--color--dunkel); }
.ss-form input[type="submit"]:focus-visible { outline: 3px solid var(--wp--preset--color--lila); outline-offset: 3px; }
.ss-form .wpcf7-not-valid-tip { font-size: .85rem; color: var(--wp--preset--color--rot-dunkel); }
.ss-form .wpcf7-response-output { margin: 0 !important; border-radius: 12px; padding: .75rem 1rem !important; }

/* ---------- Polaroid neben dem Formular ---------- */
.ss-polaroid { background: #fff; padding: 12px 12px 8px; transform: rotate(2.5deg); box-shadow: 0 16px 24px -12px rgba(42, 31, 61, .45); position: relative; margin-top: 1rem; }
.ss-polaroid::before { content: ""; position: absolute; top: -12px; left: 50%; width: 90px; height: 26px; transform: translateX(-50%) rotate(4deg); background: rgba(255, 199, 58, .7); z-index: 1; }
.ss-polaroid img { aspect-ratio: 2 / 3; object-fit: cover; width: 100%; display: block; border-radius: 0; }
.ss-polaroid figcaption { font-size: .72rem; color: #6b5f74; text-align: center; margin: .5rem 0 0; }
@media (max-width: 781px) { .ss-polaroid { max-width: 22rem; margin-inline: auto; } .ss-polaroid img { aspect-ratio: 4 / 5; } }

/* ---------- Karte ---------- */
.ss-map-wrap { border-radius: 22px; overflow: hidden; border: 3px solid var(--wp--preset--color--dunkel); box-shadow: 8px 9px 0 var(--wp--preset--color--lila); }
.ss-map { height: clamp(26rem, 78vh, 48rem); width: 100%; background: #efe9e1; }
.ss-map-popup { margin: 0; font-weight: 600; font-family: var(--wp--preset--font-family--fredoka); font-size: 1.1rem; }
.maplibregl-ctrl-attrib { font-size: 11px; }

/* ---------- Fragen + Fußzeile ---------- */
.ss-fragen h2 { margin-top: 0; }
.ss-fragen a { color: var(--wp--preset--color--dunkel); font-weight: 600; }
.ss-footer a { color: inherit; }
.ss-credit { font-size: .8rem; opacity: .8; color: inherit; }

/* ---------- Normale Seiten (Impressum, Datenschutz) ---------- */
.ss-page .wp-block-post-title { margin-bottom: 1.5rem; }
.ss-page h2 { font-size: 1.6rem; margin-top: 2rem; }
.ss-page h3 { font-size: 1.25rem; }

/* ---------- Mobil ---------- */
@media (max-width: 600px) {
	.ss-sticker { padding: 1.2rem 1.2rem 1.4rem; transform: rotate(-1deg); }
	.ss-sticker::after { width: 4rem; height: 4rem; right: -.6rem; top: -2rem; }
	.ss-credit-img { bottom: 2.6rem; }
	h2.ss-stern { padding-left: 2.2rem; }
	h2.ss-stern::before { width: 1.7rem; height: 1.7rem; }
}

/* keine Lücken zwischen Hauptbereich und Fußzeile */
.wp-site-blocks > * + * { margin-block-start: 0; }
.ss-zettel__datum { text-wrap: balance; }
.ss-fernseher video { box-sizing: border-box; }
@media (max-width: 781px) {
	.ss-hero .ss-credit-img { top: .6rem; bottom: auto; }
	.ss-fernseher video { border-width: 6px; }
}
.ss-hero .wp-block-cover__inner-container, .ss-band .wp-block-cover__inner-container { position: static; }
.ss-kreide { white-space: nowrap; font-size: clamp(1.7rem, 9vw, 4.2rem) !important; }

/* Karte breiter als der Textblock */
.ss-map-wrap { max-width: var(--wp--style--global--wide-size) !important; margin-inline: auto !important; }
.ss-map-hinweis { font-size: .85rem; color: #6b5f74; margin-top: .8rem !important; text-align: center; }
.ss-page .wp-block-post-content > h2 { margin-block-start: 2.4rem !important; margin-block-end: .6rem; }
.ss-page .wp-block-post-content > h3 { margin-block-start: 1.8rem !important; }

/* ---------- Hero mobil: Foto frei sichtbar, Sticker darunter ---------- */
@media (max-width: 781px) {
	.ss-hero {
		--ss-bildhoehe: 78vw;
		min-height: 0 !important;
		padding-top: calc(var(--ss-bildhoehe) - 2.2rem) !important;
		padding-bottom: 2.5rem !important;
		-webkit-mask: none; mask: none;
		overflow: visible;
	}
	.ss-hero > .wp-block-cover__image-background,
	.ss-hero > .wp-block-cover__background { height: var(--ss-bildhoehe); bottom: auto; }
	.ss-hero > .wp-block-cover__image-background { object-position: 55% 22% !important; }
	.ss-hero::before { /* Welle zwischen Foto und Sticker */
		content: ""; position: absolute; left: 0; right: 0; top: calc(var(--ss-bildhoehe) - 38px); height: 40px; z-index: 1;
		background: var(--wp--preset--color--creme);
		-webkit-mask: var(--ss-welle) center / 100% 100% no-repeat; mask: var(--ss-welle) center / 100% 100% no-repeat;
		transform: scaleY(-1);
	}
	.ss-sticker { z-index: 3; }
	.ss-hero .ss-credit-img { z-index: 3; }
}
