/*
Theme Name: Greifvogel- und Eulenpark Wilder Wald
Description: A custom block theme scaffolded by Studio Code.
Requires at least: 6.7
Tested up to: 6.9
Requires PHP: 7.2
Version: 0.1.24
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wildwald
Tags: full-site-editing, block-patterns, block-styles, wide-blocks, accessibility-ready, style-variations
*/

/* WordPress inserts a margin-block-start equal to the block gap (24px unless
   theme.json sets styles.spacing.blockGap) between the template's top-level
   sections (header part, main, footer part) — a gap that exists even when no
   markup asks for it. Zero it so sections butt edge-to-edge and own their
   vertical rhythm via padding; this does not affect block gaps inside nested
   layouts. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

/* With that gap gone, main carries its own vertical padding so templates this
   theme does not author (WooCommerce shop, product, cart…) still clear the
   header and footer. A descendant selector, not a child one: WooCommerce wraps
   the single-product main in an extra group. Templates built from full-bleed
   sections opt out with is-flush and let the sections own the rhythm. */
.wp-site-blocks main {
	padding-block: var(--wp--preset--spacing--60) var(--wp--preset--spacing--70);
}
.wp-site-blocks main.is-flush {
	padding-block: 0;
}

/* Full-bleed bands inside page content butt edge-to-edge: zero the block gap
   between top-level blocks in post-content so the tilted reels and bands flow
   straight down without page-background slivers between them. */
.wp-block-post-content > * + * {
	margin-block-start: 0;
}

/* === design tokens === */
.site-header {
	background: var(--wp--preset--color--surface);
	border-bottom: 1px solid var(--wp--preset--color--stone);
}
.site-header-row {
	align-items: center;
	min-height: 4.5rem;
}
.site-header .wp-block-site-title {
	font-size: 1.15rem;
	font-weight: 600;
	letter-spacing: -0.01em;
	color: var(--wp--preset--color--text);
}
.site-header .wp-block-site-title a {
	color: inherit;
	text-decoration: none;
}
.site-nav {
	font-size: 0.95rem;
	gap: 0.5rem;
}
.site-nav .wp-block-navigation-item__content {
	color: var(--wp--preset--color--text);
}
.site-nav .wp-block-navigation-item__content:hover {
	color: var(--wp--preset--color--primary);
}

/* === tilted reel === */
.reel {
	overflow: hidden;
	position: relative;
}
.reel-text {
	position: relative;
	z-index: 2;
	padding-block: 4.5rem 0.75rem;
}
.reel-text h1,
.reel-text h2 {
	color: var(--wp--preset--color--text);
}
.reel-eyebrow {
	width: fit-content;
	background: rgb(200 114 79 / 0.12);
	color: #a05a3a;
	border-radius: 999px;
	padding: 0.35rem 1rem;
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}
.reel-strip {
	display: flex;
	flex-wrap: nowrap;
	gap: 1.5rem;
	width: 106vw;
	margin-inline-start: -3vw;
	padding: 0.5rem 0 2.75rem;
}
.reel--a .reel-strip {
	transform: rotate(-3deg);
}
.reel--b .reel-strip {
	transform: rotate(3.2deg);
}
.reel-strip .wp-block-image {
	flex: 0 0 auto;
	min-width: 300px;
}
.reel-strip .wp-block-image img {
	width: 100%;
	height: 232px;
	object-fit: cover;
	object-position: 50% 50%;
	border-radius: 16px;
	filter: saturate(0.8) brightness(1.02);
	display: block;
}
/* keep the upper part (head) of this photo visible in the strip */
/* nudge this strip photo: slight zoom, panned to the right */
.reel-strip .wp-block-image:has(img.wp-image-103) {
	overflow: hidden;
	border-radius: 16px;
}
.reel-strip img.wp-image-103 {
	object-position: 50% 0%;
	transform: scale(1.05);
	transform-origin: 20% 0%;
}
/* crop lower part of this strip photo */
.reel-strip img.wp-image-104 {
	object-position: 50% 45%;
}
/* Kontakt- und Geschenkeseite: Adler-Porträt etwas höher ansetzen */
:is(.page-id-16, .page-id-91) .reel-strip img.wp-image-63 {
	object-position: 50% 20%;
}

/* Bild in der "Aktuell"-Karte */
.aktuell-card .wp-block-image {
	margin-block: 0.5rem 0;
	margin-inline: 0;
	width: 100%;
}
.aktuell-card .wp-block-image img {
	width: 100%;
	height: 340px;
	object-fit: contain;
	object-position: 50% 50%;
	border-radius: 12px;
}

/* === sections === */
.lead-band {
	background: var(--wp--preset--color--surface);
}
.panel-note {
	color: #6a665d;
}

/* === cards === */
.is-style-card {
	background: var(--wp--preset--color--background);
	border: 1px solid var(--wp--preset--color--stone);
	border-radius: 16px;
	padding: 1.75rem;
	box-shadow: 0 1px 2px rgb(0 0 0 / 0.04);
}
/* equal-height cards inside a row of columns */
.wp-block-column > .is-style-card {
	height: 100%;
}
/* cards are flex columns so buttons line up at the bottom */
.is-style-card {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}
.is-style-card > .wp-block-buttons {
	margin-top: auto;
}
.is-style-card > :where(h3, p) {
	margin-block: 0;
}
/* Geschenkideen: prices line up across the three cards */
/* Geschenkideen: gleiche Höhe für Überschrift + Text, damit die Preisblöcke
   in Karte 1 und 2 auf einer Linie mit dem "Antrag"-Button von Karte 3 liegen */
body.page-id-91 .wp-block-column:nth-child(-n+2) .is-style-card > h3 {
	min-height: 40.5px;
}
body.page-id-91 .wp-block-column:nth-child(-n+2) .is-style-card > p:first-of-type {
	flex: 0 0 auto;
	min-height: 256px;
}
body.page-id-91 .wp-block-column:nth-child(-n+2) .is-style-card > p:nth-of-type(2) {
	margin-block-start: -6px;
}
.lead-band .aktuell-card {
	max-width: 40rem;
	margin-inline: auto;
	margin-top: 2.5rem;
}
.is-style-card h3 {
	font-size: 1.15rem;
	margin-bottom: 0.5rem;
}
.is-style-card .card-price {
	color: var(--wp--preset--color--accent);
	font-size: 1.6rem;
	font-weight: 600;
	line-height: 1.1;
}

/* === file / download block === */
.wp-block-file {
	font-size: 1rem;
}
.wp-block-file a:not(.wp-block-file__button) {
	color: var(--wp--preset--color--text);
	text-decoration: underline;
}
.wp-block-file__button {
	margin-left: 0.75rem;
}

/* === footer === */
.site-footer {
	background: var(--wp--preset--color--surface);
	border-top: 1px solid var(--wp--preset--color--stone);
	padding-block: var(--wp--preset--spacing--50);
}
.site-footer h3 {
	font-size: 1rem;
}
.site-footer .wp-block-column {
	padding-block: 0.5rem;
}
.footer-note {
	color: #6a665d;
}
.footer-nav a {
	color: var(--wp--preset--color--text);
}
.footer-copy {
	color: #837e73;
	font-size: 0.85rem;
}

/* === reduced motion: rotation of the reel strips is static geometry, not motion,
   so it stays; only animated transitions are disabled. === */

/* === responsive: strips unrotate and scroll on mobile === */
@media (max-width: 782px) {
	.reel--a .reel-strip,
	.reel--b .reel-strip {
		transform: none;
		width: auto;
		margin-inline-start: 0;
		overflow-x: auto;
		padding-inline: var(--wp--preset--spacing--40);
	}
	.reel-strip {
		gap: 1rem;
	}
	.reel-strip .wp-block-image {
		min-width: 240px;
	}
}

/* === bands & text === */
.lead-band {
	padding-block: 5rem;
}
.lead-inner > * + * {
	margin-block-start: 2.25rem;
}
.lead-inner .panel-note {
	max-width: 44em;
	margin-inline: auto;
}
.reel-text .wp-block-paragraph {
	max-width: 38em;
}
.reel-text .wp-block-buttons {
	margin-block-start: 1.75rem;
}

/* === outline button === */
.wp-block-button.is-style-outline .wp-element-button {
	background: transparent;
	color: var(--wp--preset--color--primary);
	border: 2px solid currentColor;
	padding: calc(1rem - 2px) calc(1.75rem - 2px);
}
.wp-block-button.is-style-outline .wp-element-button:hover {
	background: var(--wp--preset--color--primary);
	color: #fff;
}

/* === contact form === */
.wp-block-jetpack-contact-form {
	max-width: 100%;
}
.wp-block-jetpack-contact-form .wp-block-jetpack-input-wrap {
	gap: 0.35rem;
}
.wp-block-jetpack-contact-form label {
	font-weight: 600;
	font-size: 0.9rem;
	display: block;
	margin-bottom: 0.35rem;
}
.wp-block-jetpack-contact-form input[type="text"],
.wp-block-jetpack-contact-form input[type="email"],
.wp-block-jetpack-contact-form textarea {
	width: 100%;
	border: 1px solid var(--wp--preset--color--stone);
	border-radius: 12px;
	padding: 0.85rem 1rem;
	background: var(--wp--preset--color--background);
	font: inherit;
	color: var(--wp--preset--color--text);
}
.wp-block-jetpack-contact-form textarea {
	min-height: 140px;
}
.wp-block-jetpack-contact-form .wp-block-button__link {
	margin-block-start: 0.5rem;
}

/* === footer columns === */
.site-footer .wp-block-columns {
	gap: 2.5rem;
}
