/* ===================================================================
   APB: Agrarpodcastingbeitrag fuer Betriebe (betriebe.php, 03.11.2026).
   /apb/ mit Feldszene und Rechner, /betriebe/ Uebersicht, Hofseiten.
   Baut auf seite.css auf (Variablen, Baender, FAQ); Kanten und Schatten
   wie kachelstil.css. Alles auf .b2p-apb- gescopet.
   =================================================================== */

/* ─── Rechner-Kachel mit Feldszene ───────────────────────────────── */

.b2p-apb-kachel {
	border: 2px solid var(--b2p-dunkel);
	box-shadow: 6px 6px 0 var(--b2p-dunkel);
	background: var(--b2p-creme-warm);
	overflow: hidden;
}

.b2p-apb-feld {
	display: block;
	width: 100%;
	height: auto;
	border-bottom: 2px solid var(--b2p-dunkel);
}

/* Szene bewegt sich mit dem Betrag (apb.js). */
#apb-traktor { transition: transform 0.7s ease; }
#gruenrect { transition: width 0.7s ease; }
#apb-sonne { transition: r 0.7s ease; }
#apb-schaf1, #apb-schaf2, #apb-schaf3, #apb-schaf4 { transition: opacity 0.4s ease; }

.b2p-apb-feld .guelle { animation: b2p-apb-guelle 1.1s steps(2) infinite; }

@keyframes b2p-apb-guelle {
	50% { opacity: 0.35; }
}

@media (prefers-reduced-motion: reduce) {
	#apb-traktor, #gruenrect, #apb-sonne { transition: none; }
	.b2p-apb-feld .guelle { animation: none; }
}

.b2p-s p.b2p-apb-fehler {
	margin: 0;
	padding: 14px 28px;
	background: var(--b2p-gelb);
	border-bottom: 2px solid var(--b2p-dunkel);
	font-weight: 700;
}

.b2p-apb-rechner {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 24px 48px;
	padding: 24px 28px 28px;
}

.b2p-apb-rechner h3 { margin: 0 0 12px; }

.b2p-s p.b2p-apb-dach {
	font-family: var(--b2p-font-display-regular);
	font-size: 15px;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: var(--b2p-grau);
	margin: 0 0 4px;
}

.b2p-s p.b2p-apb-eingabe {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0 0 8px;
	font-weight: 700;
}

.b2p-apb-eingabe input {
	width: 140px;
	min-height: 52px;
	padding: 8px 14px;
	border: 2px solid var(--b2p-dunkel);
	border-radius: 3px;
	background: var(--b2p-weiss);
	color: var(--b2p-dunkel);
	font-family: var(--b2p-font-body);
	font-size: 22px;
	font-weight: 700;
}

.b2p-apb-eingabe input:focus-visible { outline: 3px solid var(--b2p-rot); outline-offset: 2px; }

.b2p-apb-ergebnis {
	grid-column: 1 / -1;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 20px 40px;
	border-top: 1px solid var(--b2p-linie);
	padding-top: 20px;
}

.b2p-s p.b2p-apb-formel { margin: 0; font-size: 15px; color: var(--b2p-grau); }

.b2p-s p.b2p-apb-summe {
	margin: 0;
	display: flex;
	align-items: baseline;
	gap: 10px;
	font-weight: 700;
}

.b2p-apb-summe strong {
	font-family: var(--b2p-font-display);
	font-weight: normal;
	font-size: 68px;
	line-height: 0.95;
}

.b2p-s a.b2p-apb-knopf,
.b2p-s button.b2p-apb-knopf {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 54px;
	padding: 10px 22px;
	border: 0;
	border-radius: 3px;
	background: var(--b2p-dunkel);
	color: var(--b2p-creme);
	text-decoration: none;
	font-family: var(--b2p-font-body);
	font-size: 17px;
	font-weight: 700;
	cursor: pointer;
	transition: transform 0.15s ease;
}

.b2p-s a.b2p-apb-knopf:hover { transform: scale(1.02); }
.b2p-s a.b2p-apb-knopf:focus-visible { outline: 3px solid var(--b2p-rot); outline-offset: 3px; }
.b2p-s button.b2p-apb-knopf:disabled { opacity: 0.55; cursor: default; }
.b2p-s .b2p-apb-knopf--hell { background: transparent; color: var(--b2p-dunkel); border: 2px solid var(--b2p-dunkel); }

.b2p-apb-bald { max-width: 340px; display: flex; flex-direction: column; gap: 8px; }

/* ─── Drei Karten (Vorteile, Hofseite) ───────────────────────────── */

.b2p-apb-karten {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 28px;
	margin-top: 28px;
}

.b2p-s-eng .b2p-apb-karten { margin-top: 0; }

.b2p-apb-karte {
	border: 2px solid var(--b2p-dunkel);
	box-shadow: 6px 6px 0 var(--b2p-dunkel);
	background: var(--b2p-creme);
	padding: 24px;
}

.b2p-apb-karte--gelb { background: var(--b2p-gelb); }
.b2p-apb-karte--dunkel { background: var(--b2p-dunkel); color: var(--b2p-creme); }
.b2p-s .b2p-apb-karte--dunkel h3 { color: var(--b2p-gelb); }
.b2p-s .b2p-apb-karte--dunkel a { color: var(--b2p-gelb); }
.b2p-apb-karte h3 { margin: 0 0 8px; }
.b2p-apb-karte p { margin: 0; }

/* ─── Uebersicht /betriebe/ ──────────────────────────────────────── */

.b2p-apb-hoefe {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 32px;
}

.b2p-s .b2p-apb-hof {
	display: flex;
	flex-direction: column;
	border: 2px solid var(--b2p-dunkel);
	box-shadow: 6px 6px 0 var(--b2p-dunkel);
	background: var(--b2p-creme-warm);
	color: var(--b2p-dunkel);
	text-decoration: none;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.b2p-s .b2p-apb-hof:hover {
	transform: translate(-3px, -3px);
	box-shadow: 9px 9px 0 var(--b2p-dunkel);
}

.b2p-s .b2p-apb-hof .b2p-apb-hof__bild,
.b2p-s img.b2p-apb-hof__bild {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 3 / 2;
	object-fit: cover;
	border-bottom: 2px solid var(--b2p-dunkel);
}

.b2p-apb-hof__text {
	display: flex;
	flex-direction: column;
	gap: 4px;
	padding: 16px 18px 20px;
}

.b2p-apb-hof__name {
	font-family: var(--b2p-font-display);
	font-size: 27px;
	line-height: 1.05;
}

/* ─── Hofseite ───────────────────────────────────────────────────── */

.b2p-apb-hofseite {
	display: grid;
	grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
	gap: 48px;
	align-items: start;
}

.b2p-apb-hofseite__bild {
	border: 2px solid var(--b2p-dunkel);
	box-shadow: 6px 6px 0 var(--b2p-dunkel);
	overflow: hidden;
	background: var(--b2p-creme-warm);
}

.b2p-apb-hofseite__bild img,
.b2p-apb-hofseite__bild svg { display: block; width: 100%; height: auto; }

.b2p-s .b2p-apb-hofseite h1 { font-size: clamp(44px, 6vw, 72px); }

.b2p-apb-hofseite__inhalt { margin-top: 14px; max-width: 640px; }
.b2p-apb-hofseite__inhalt p { margin: 0 0 12px; }

.b2p-s p.b2p-apb-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 6px 0 0;
}

.b2p-apb-chips span {
	display: inline-flex;
	align-items: center;
	min-height: 38px;
	padding: 4px 14px;
	border: 2px solid var(--b2p-dunkel);
	border-radius: 3px;
	background: var(--b2p-weiss);
	font-size: 15px;
	font-weight: 700;
}

.b2p-s p.b2p-apb-hofseite__links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 18px 0 0;
}

/* ─── Maske /betriebe/eintragen/ ─────────────────────────────────── */

.b2p-apb-form {
	display: flex;
	flex-direction: column;
	gap: 6px;
	border: 2px solid var(--b2p-dunkel);
	box-shadow: 6px 6px 0 var(--b2p-dunkel);
	background: var(--b2p-creme-warm);
	padding: 28px;
	max-width: 760px;
}

.b2p-s .b2p-apb-form h2 { font-size: 30px; margin: 22px 0 4px; }
.b2p-s .b2p-apb-form h2:first-of-type { margin-top: 0; }

.b2p-s p.b2p-apb-f { margin: 0 0 10px; display: flex; flex-direction: column; gap: 6px; }
.b2p-apb-f label span { font-weight: 400; color: var(--b2p-grau); font-size: 14px; }

.b2p-apb-f input[type="text"],
.b2p-apb-f textarea {
	width: 100%;
	padding: 12px 14px;
	border: 2px solid var(--b2p-dunkel);
	border-radius: 3px;
	background: var(--b2p-weiss);
	color: var(--b2p-dunkel);
	font-family: var(--b2p-font-body);
	font-size: 16px;
}

.b2p-apb-f input:focus-visible,
.b2p-apb-f textarea:focus-visible { outline: 3px solid var(--b2p-rot); outline-offset: 2px; }

.b2p-apb-bilder { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 32px; }
.b2p-s img.b2p-apb-form__bild { display: block; max-width: 260px; height: auto; border: 2px solid var(--b2p-dunkel); }
.b2p-s img.b2p-apb-form__bild--logo { max-width: 160px; background: var(--b2p-weiss); padding: 8px; }

.b2p-apb-honig { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.b2p-apb-gespeichert { margin-bottom: 24px; }

/* Logo auf der Hofseite */
.b2p-s img.b2p-apb-hofseite__logo { max-height: 72px; width: auto; margin-bottom: 4px; }

/* ─── Schmal ─────────────────────────────────────────────────────── */

@media (max-width: 900px) {
	.b2p-apb-hofseite { grid-template-columns: minmax(0, 1fr); gap: 28px; }
	.b2p-apb-hofseite__bild { max-width: 440px; }
}

@media (max-width: 760px) {
	.b2p-apb-kachel,
	.b2p-apb-karte,
	.b2p-s .b2p-apb-hof,
	.b2p-apb-hofseite__bild { box-shadow: 4px 4px 0 var(--b2p-dunkel); }
	.b2p-apb-rechner { padding: 18px 16px 22px; }
	.b2p-apb-summe strong { font-size: 54px; }
}
