/* KW Biohof – Aktionshinweis-Widget. Eine kompakte Handlungs-Gruppe für direkt
   unter Überschrift und Einstiegstext: kleine Einleitung, einladender Aufruf-Satz,
   zwei echte Knöpfe (Hauptaktion gefüllt + zweite Aktion umrandet) und eine
   optionale Vertrauenszeile. Richtet sich an der Überschrift aus (zentriert/links/
   rechts); wahlweise nahtlos oder als abgesetzte Karte. Farben aus Tokens; white/
   black nur für Knopf-Glanz/Tiefe. Kein !important, komplett ohne JS. */

.biohof-action {
	--biohof-action-max: 46rem;
	--biohof-action-gap: clamp(0.85rem, 0.7rem + 0.6vw, 1.25rem);
	--biohof-action-pad: clamp(1.5rem, 1.1rem + 1.8vw, 2.75rem);
	/* Aufruf-Satz: führend, aber ruhig – ordnet sich der Überschrift unter und
	   lässt die Knöpfe der Blickfang sein (fluide; ~17px mobil → ~19px Desktop). */
	--biohof-action-text-fs: clamp(1.0625rem, 0.99rem + 0.34vw, 1.2rem);
	--biohof-action-fg: var(--biohof-color-text);
	--biohof-action-eyebrow: var(--biohof-color-primary);
	--biohof-action-btn-bg: var(--biohof-color-primary);
	--biohof-action-btn-fg: var(--biohof-color-on-primary);
	--biohof-action-btn-shadow: var(--biohof-color-primary);
	--biohof-action-outline: var(--biohof-color-primary);
	--biohof-action-focus: var(--biohof-color-focus);
	/* Karte: dezente, edle Tönung (halb so kräftig wie surface-soft) statt
	   vollem Hellgrün – wirkt ruhiger und hochwertiger. */
	--biohof-action-panel: color-mix(in srgb, var(--biohof-color-surface-soft) 48%, var(--biohof-color-bg));
	--biohof-action-panel-border: color-mix(in srgb, var(--biohof-color-primary) 14%, transparent);

	font-family: var(--biohof-font-body);
	font-size: var(--biohof-fs-400);
	line-height: var(--biohof-line-base);
	color: var(--biohof-action-fg);
}

/* ── Inhaltsspalte: max-breit, an der Überschrift ausgerichtet ──────────────── */
.biohof-action__inner {
	display: flex;
	flex-direction: column;
	gap: var(--biohof-action-gap);
	max-inline-size: var(--biohof-action-max);
}

.biohof-action--align-center .biohof-action__inner {
	margin-inline: auto;
	align-items: center;
	text-align: center;
}
.biohof-action--align-left .biohof-action__inner {
	margin-inline-end: auto;
	align-items: flex-start;
	text-align: start;
}
.biohof-action--align-right .biohof-action__inner {
	margin-inline-start: auto;
	align-items: flex-end;
	text-align: end;
}

/* ── Einleitung (klein, warm – kein Schrei-Caps) ───────────────────────────── */
.biohof-action__eyebrow {
	margin: 0;
	display: inline-flex;
	align-items: center;
	gap: var(--biohof-space-2xs);
	font-size: var(--biohof-fs-300);
	font-weight: var(--biohof-weight-semibold);
	letter-spacing: 0.01em;
	color: var(--biohof-action-eyebrow);
}
.biohof-action__eyebrow-ico {
	display: inline-flex;
	flex: none;
	--biohof-icon-size: 1.15em;
}
.biohof-action__eyebrow-ico svg {
	inline-size: 1.15em;
	block-size: 1.15em;
}

/* ── Aufruf-Satz (präsent, gut lesbar) ─────────────────────────────────────── */
.biohof-action__text {
	font-size: var(--biohof-action-text-fs);
	line-height: var(--biohof-line-base);
	color: var(--biohof-action-fg);
	text-wrap: pretty;
}
.biohof-action__text > :first-child {
	margin-block-start: 0;
}
.biohof-action__text > :last-child {
	margin-block-end: 0;
}
.biohof-action__text p {
	margin-block: 0;
}
.biohof-action__text p + p {
	margin-block-start: 0.5em;
}
.biohof-action__text strong,
.biohof-action__text b {
	font-weight: var(--biohof-weight-semibold);
	color: var(--biohof-color-text-strong);
}
.biohof-action__text a {
	color: var(--biohof-color-primary);
	text-decoration: underline;
	text-underline-offset: 0.15em;
}
/* Elementor-V4-Reset für Inline-Links im Aufruf-Text (Pink verhindern). */
.biohof-action .biohof-action__text a,
.biohof-action .biohof-action__text a:hover,
.biohof-action .biohof-action__text a:focus,
.biohof-action .biohof-action__text a:focus-visible,
.biohof-action .biohof-action__text a:active {
	color: var(--biohof-color-primary);
}

/* ══ Knöpfe ════════════════════════════════════════════════════════════════ */
.biohof-action__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--biohof-space-sm);
}
.biohof-action--align-center .biohof-action__actions {
	justify-content: center;
}
.biohof-action--align-right .biohof-action__actions {
	justify-content: flex-end;
}

.biohof-action__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--biohof-space-2xs);
	min-block-size: 52px;
	padding: 0.85rem 1.6rem;
	font-family: var(--biohof-font-body);
	font-size: var(--biohof-fs-400);
	font-weight: var(--biohof-weight-semibold);
	text-decoration: none;
	border: 1.5px solid transparent;
	border-radius: var(--biohof-radius-md);
	transition:
		background-color var(--biohof-duration) var(--biohof-ease),
		border-color var(--biohof-duration) var(--biohof-ease),
		box-shadow var(--biohof-duration) var(--biohof-ease),
		transform var(--biohof-duration) var(--biohof-ease);
}
.biohof-action__btn-ico,
.biohof-action__btn-ext {
	display: inline-flex;
	flex: none;
	transition: transform var(--biohof-duration) var(--biohof-ease);
}
.biohof-action__btn-ico svg {
	inline-size: 1.2rem;
	block-size: 1.2rem;
}
.biohof-action__btn-ext svg {
	inline-size: 0.85rem;
	block-size: 0.85rem;
}

/* Hauptaktion (gefüllt, plastisch): zarter Glanz + Innen-Highlight + warm
   getönter Schlagschatten. */
.biohof-action__btn--primary {
	color: var(--biohof-action-btn-fg);
	background-color: var(--biohof-action-btn-bg);
	background-image: linear-gradient(
		to bottom,
		color-mix(in srgb, white 14%, transparent),
		transparent 60%
	);
	box-shadow:
		inset 0 1px 0 color-mix(in srgb, white 40%, transparent),
		inset 0 -1.5px 0 color-mix(in srgb, var(--biohof-action-btn-bg) 70%, black),
		0 1px 2px color-mix(in srgb, black 14%, transparent),
		0 10px 24px color-mix(in srgb, var(--biohof-action-btn-shadow) 30%, transparent);
}

/* Zweite Aktion (umrandet): ruhiger, gleichwertig groß. Rand deckend genug für
   WCAG 1.4.11 (UI-Grenze ≥ 3:1) – eine winzige Fülltönung gibt zusätzlich Halt. */
.biohof-action__btn--outline {
	color: var(--biohof-action-outline);
	background-color: color-mix(in srgb, var(--biohof-action-outline) 6%, transparent);
	border-color: color-mix(in srgb, var(--biohof-action-outline) 80%, transparent);
}

/* Elementor-V4-Reset: Knopf-Farbe in ALLEN Zuständen halten (Defense setzt
   `color: inherit`). a-Doppelung; :focus PFLICHT (nicht nur :focus-visible). */
.biohof-action a.biohof-action__btn--primary,
.biohof-action a.biohof-action__btn--primary:hover,
.biohof-action a.biohof-action__btn--primary:focus,
.biohof-action a.biohof-action__btn--primary:focus-visible,
.biohof-action a.biohof-action__btn--primary:active {
	color: var(--biohof-action-btn-fg);
}
.biohof-action a.biohof-action__btn--outline,
.biohof-action a.biohof-action__btn--outline:hover,
.biohof-action a.biohof-action__btn--outline:focus,
.biohof-action a.biohof-action__btn--outline:focus-visible,
.biohof-action a.biohof-action__btn--outline:active {
	color: var(--biohof-action-outline);
}

@media (hover: hover) {
	.biohof-action__btn--primary:hover {
		transform: translateY(-2px);
		box-shadow:
			inset 0 1px 0 color-mix(in srgb, white 55%, transparent),
			inset 0 -1.5px 0 color-mix(in srgb, var(--biohof-action-btn-bg) 66%, black),
			0 2px 4px color-mix(in srgb, black 16%, transparent),
			0 16px 32px color-mix(in srgb, var(--biohof-action-btn-shadow) 40%, transparent);
	}
	.biohof-action__btn--outline:hover {
		transform: translateY(-2px);
		border-color: var(--biohof-action-outline);
		background-color: color-mix(in srgb, var(--biohof-action-outline) 10%, transparent);
	}
	.biohof-action__btn:hover .biohof-action__btn-ico {
		transform: translateX(-1px);
	}
	.biohof-action__btn:hover .biohof-action__btn-ext {
		transform: translate(1px, -1px);
	}
}

.biohof-action__btn:focus-visible {
	outline: 3px solid var(--biohof-action-focus);
	outline-offset: 2px;
}

/* ── Vertrauenszeile (klein, ruhig, AA auf bg UND Karten-Tint) ─────────────── */
.biohof-action__trust {
	margin: 0;
	font-size: var(--biohof-fs-300);
	color: var(--biohof-action-fg);
}

/* ══ Erscheinung: abgesetzte Karte ═══════════════════════════════════════════ */
.biohof-action--panel .biohof-action__inner {
	padding: var(--biohof-action-pad);
	background-color: var(--biohof-action-panel);
	border: 1px solid var(--biohof-action-panel-border);
	border-radius: var(--biohof-radius-lg);
	box-shadow: var(--biohof-shadow-md);
}

/* ── Sanftes Einblenden beim Laden (greift auch above-the-fold; reines CSS) ─── */
@media (prefers-reduced-motion: no-preference) {
	.biohof-action--reveal .biohof-action__inner {
		animation: biohof-action-rise 600ms var(--biohof-ease) both;
	}
}

@keyframes biohof-action-rise {
	from {
		opacity: 0;
		transform: translateY(14px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ── Editor-Hinweise ─────────────────────────────────────────────────────────
   --empty zeigt den Leer-Hinweis; --notice ergänzende Editor-Hinweise. */
.biohof-action--empty {
	display: block;
	color: var(--biohof-color-text);
	padding: var(--biohof-space-md);
	border: 1px dashed var(--biohof-color-border);
	border-radius: var(--biohof-radius-md);
	background: var(--biohof-color-surface-soft);
}
.biohof-action__notice {
	margin: 0;
	font-size: var(--biohof-fs-300);
	color: var(--biohof-color-text-muted);
}

/* ── Bewegung reduzieren (BFSG) ──────────────────────────────────────────────
   Die Einblend-Animation entfällt schon durch die no-preference-Query oben. */
@media (prefers-reduced-motion: reduce) {
	.biohof-action__btn,
	.biohof-action__btn-ico,
	.biohof-action__btn-ext {
		transition: none;
	}
	.biohof-action__btn--primary:hover,
	.biohof-action__btn--outline:hover {
		transform: none;
	}
}
