/*
Theme Name: Hadar Yeger
Author: Itamar Ben Ezri
Description: Custom WordPress theme built from a Figma design (with the figma-to-wp skill).
Version: 0.1.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: hadar
*/

/* Derived from static-to-fullwp (2026-07). Improvements worth sharing: port back manually. */

/* =============================================================================
 * Fonts — SELF-HOSTED (Stage F2)
 * -----------------------------------------------------------------------------
 * @font-face blocks for every family/weight the design uses. WOFF2 files live
 * in assets/fonts/. Always font-display: swap. Keep per-subset unicode-range
 * blocks when the design mixes scripts (e.g. Latin + Hebrew).
 *
 * There is NO external fonts enqueue in functions.php — this block is the only
 * fonts source. A missing family here shows up as a tokens.spec.js failure
 * (document.fonts.check) — that failure is the reminder, don't silence it.
 * ========================================================================== */

/* Assistant is a variable font on Google Fonts: one file per subset covers 600–700. */
/* hebrew */
@font-face {
	font-family: 'Assistant';
	src: url('assets/fonts/assistant-var-hebrew.woff2') format('woff2');
	font-weight: 600 700;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
/* latin */
@font-face {
	font-family: 'Assistant';
	src: url('assets/fonts/assistant-var-latin.woff2') format('woff2');
	font-weight: 600 700;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* hebrew */
@font-face {
	font-family: 'Gveret Levin';
	src: url('assets/fonts/gveret-levin-400-hebrew.woff2') format('woff2');
	font-weight: 400;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
/* latin */
@font-face {
	font-family: 'Gveret Levin';
	src: url('assets/fonts/gveret-levin-400-latin.woff2') format('woff2');
	font-weight: 400;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}



/* =============================================================================
 * Design system — FROM FIGMA (Stage F1)
 * -----------------------------------------------------------------------------
 * The :root tokens extracted from the Figma file (get_variable_defs, or
 * harvested from representative frames when the file defines no variables).
 * These MUST mirror design/tokens.json exactly — the Playwright harness audits
 * computed styles against that JSON. Change a token → change both.
 *
 * Naming: --color-*, --font-*, --fs-* (type scale), --space-*, --radius-*,
 * --shadow-*, --container-max. Breakpoints cannot be CSS variables — they are
 * recorded in design/tokens.json and written literally into media queries,
 * each tagged with a comment naming its token (bp: --bp-md).
 *
 * This is WordPress's mandatory main stylesheet and loads on EVERY page, so the
 * design system belongs here — do NOT split it into a separate design-system.css.
 *
 * LOGICAL PROPERTIES ONLY (margin-inline-*, padding-inline, inset-inline-*,
 * text-align: start) — even on LTR sites — so RTL/Hebrew projects work without
 * a rewrite. Escape hatch for genuinely directional decoration: a comment
 * containing the word `physical` on the same line. lint-css.mjs enforces this.
 *
 * RTL/Hebrew: set the WordPress Site Language (Settings → General) so is_rtl()
 * is true and language_attributes() emits dir="rtl".
 * ========================================================================== */

:root {
	/* colors */
	--color-surface: #FEF6FB;
	--color-surface-raised: #FDFAFE;
	--color-surface-glass: rgb(254 246 251 / 0.75);
	--color-ink: #542712;
	--color-primary: #E766A0;
	--color-primary-strong: #E65F9C; /* button fill: ≥3:1 with --color-on-primary (WCAG large text) */
	--color-on-primary: #FEF6FB;
	--color-tint: #F4E3E9;
	--color-tint-strong: #EECCD9;
	--color-blush: #FFDEEF;
	/* fontFamilies */
	--font-display: 'Gveret Levin', 'Assistant', system-ui, sans-serif;
	--font-body: 'Assistant', system-ui, sans-serif;
	/* typeScale */
	--fs-400: clamp(1.125rem, 0.902rem + 0.915vw, 2rem);
	--fs-500: clamp(1.25rem, 0.9951rem + 1.0458vw, 2.25rem);
	--fs-600: clamp(1.375rem, 1.0882rem + 1.1765vw, 2.5rem);
	--fs-700: clamp(1.75rem, 1.4314rem + 1.3072vw, 3rem);
	--fs-800: clamp(2.25rem, 1.8039rem + 1.8301vw, 4rem);
	--fs-900: clamp(3.5rem, 2.3529rem + 4.7059vw, 8rem);
	/* spacing */
	--space-1: 0.25rem;
	--space-2: 0.5rem;
	--space-3: 0.75rem;
	--space-4: 1rem;
	--space-6: 1.5rem;
	--space-8: 2rem;
	--space-9: 2.25rem;
	--space-11: 2.75rem;
	--space-12: 3rem;
	--space-16: clamp(2rem, 1.4902rem + 2.0915vw, 4rem);
	--space-21: clamp(2.5rem, 1.799rem + 2.8758vw, 5.25rem);
	--space-26: clamp(3rem, 2.1078rem + 3.6601vw, 6.5rem);
	--space-section: clamp(4rem, 2.4706rem + 6.2745vw, 10rem);
	--gutter: clamp(1.5rem, 0.8627rem + 2.6144vw, 4rem);
	/* radius */
	--radius-lg: 2rem;
	--radius-xl: 2.5rem;
	--radius-full: 9999px;
	/* shadows */
	--shadow-button: 0 4px 4px rgb(99 69 59 / 0.12);
	--shadow-card: 0 4px 8px rgb(84 39 18 / 0.2);
	--shadow-glow: 0 4px 8px #FEF6FB;
	/* container */
	--container-max: 88rem;
	/* tracking */
	--tracking-display: 0.03em;
	--tracking-hero: 0.05em;
	/* motion */
	--ease-out: cubic-bezier(0.22, 1, 0.36, 1);
	--duration-fast: 180ms;
	--duration-base: 320ms;
	--duration-reveal: 700ms;
}


/* =============================================================================
 * Base + resets + typography — FROM FIGMA
 * -----------------------------------------------------------------------------
 * Reset, base element typography (body, headings mapped to the --fs-* scale),
 * .container (max-width: var(--container-max)), and shared utilities.
 * ========================================================================== */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-behavior: smooth;
}

body {
	margin: 0;
	overflow-x: clip; /* clip, not hidden — hidden would break position: sticky */
	background: var(--color-surface);
	color: var(--color-ink);
	font-family: var(--font-body);
	font-size: var(--fs-400);
	font-weight: 600;
	line-height: 1.3; /* Figma "normal" for Assistant ≈ 1.3 */
	-webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
	margin: 0;
	font-family: var(--font-display);
	font-weight: 400;
	letter-spacing: var(--tracking-display);
	line-height: 1.1;
	text-wrap: balance;
}

/* Figma trims every text box to cap-height/baseline (text-box-trim). Matching it makes
   the design's gaps true in CSS; browsers without support just get slightly looser rhythm. */
h1,
h2,
h3,
h4,
p,
.site-header__menu a,
.contact-form__label {
	text-box: trim-both cap alphabetic;
}

h1 { font-size: var(--fs-900); line-height: 1; }
h2 { font-size: var(--fs-800); }
h3 { font-size: var(--fs-700); }

p {
	margin: 0;
	text-wrap: pretty;
}

strong,
b {
	font-weight: 700;
}

img,
svg,
video {
	display: block;
	max-width: 100%;
	height: auto;
}

a {
	color: inherit;
	text-decoration: none;
	transition: color var(--duration-fast) var(--ease-out), opacity var(--duration-fast) var(--ease-out);
}

:focus-visible {
	outline: 3px solid var(--color-primary);
	outline-offset: 3px;
}

button,
input,
textarea,
select {
	font: inherit;
	color: inherit;
}

.container {
	inline-size: 100%;
	max-inline-size: calc(var(--container-max) + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
}

/* The designer's line breaks (hadar_text_html): kept on desktop, free wrapping below. */
@media (max-width: 1023px) { /* bp: --bp-lg */
	.br-desktop {
		display: none;
	}
}

.screen-reader-text {
	position: absolute !important;
	inline-size: 1px;
	block-size: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: fixed;
	inset-block-start: var(--space-2);
	inset-inline-start: var(--space-2);
	z-index: 1000;
	inline-size: auto;
	block-size: auto;
	padding: var(--space-3) var(--space-6);
	margin: 0;
	clip-path: none;
	background: var(--color-ink);
	color: var(--color-on-primary);
	border-radius: var(--radius-full);
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}


/* =============================================================================
 * Global chrome — FROM FIGMA
 * -----------------------------------------------------------------------------
 * Header, nav, mobile drawer, buttons, footer — anything shown on every page.
 * Built from the Figma header/footer sections (Stage A1).
 *
 * When header.php switches to wp_nav_menu() output, retarget the nav selectors
 * to WordPress menu classes (e.g. `.menu-item-has-children > .sub-menu`).
 *
 * ONE CSS FILE = ONE SCOPE. Keep global rules here; homepage-only rules in
 * front-page.css (loaded via is_front_page()); per-page rules in
 * assets/css/{template}.css; per-section rules in the section's own
 * template-parts/{id}/{id}.css. Don't duplicate chrome across files.
 * ========================================================================== */

/* ---------------------------------------------------------------------------
 * Shared components: buttons, section heading, heart divider
 * ------------------------------------------------------------------------- */

.btn {
	--btn-pad: var(--space-3);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--space-3);
	/* text-box trim can't reach a flex label: take the half-leading out of the padding instead (Figma: cap + 2×12). */
	padding-block: calc(var(--btn-pad) - (1em - 1cap) / 2);
	padding-inline: var(--space-6);
	border: 1px solid var(--color-tint);
	border-radius: var(--radius-full);
	background: var(--color-primary-strong);
	color: var(--color-on-primary);
	box-shadow: var(--shadow-button);
	font-size: var(--fs-400);
	line-height: 1;
	text-align: center;
	cursor: pointer;
	transition:
		transform var(--duration-base) var(--ease-out),
		box-shadow var(--duration-base) var(--ease-out),
		background-color var(--duration-base) var(--ease-out),
		color var(--duration-base) var(--ease-out);
}

.btn:hover,
.btn:focus-visible {
	transform: translateY(-3px);
	box-shadow: var(--shadow-card);
}

.btn:active {
	transform: translateY(0);
}

/* Below 1024 the label drops under 24px: bold + fs-500 keeps it "large text" (WCAG 3:1 on the pink). */
@media (max-width: 1023px) { /* bp: --bp-lg */
	.btn {
		font-size: var(--fs-500);
		font-weight: 700;
	}
}

.btn--outline {
	border-color: var(--color-primary);
	background: var(--color-surface);
	color: var(--color-ink);
}

.btn--outline:hover,
.btn--outline:focus-visible {
	background: var(--color-primary-strong);
	color: var(--color-on-primary);
}

.btn--dark {
	background: var(--color-ink);
}

.btn--wide {
	padding-inline: var(--space-16);
}

.btn--block {
	--btn-pad: var(--space-6);
	inline-size: 100%;
	font-size: var(--fs-600);
}

.btn__icon {
	flex: none;
	inline-size: 0.875em; /* icons follow the label's size (28px @ 32px) */
	block-size: auto;
	transition: transform var(--duration-base) var(--ease-out);
}

.btn__icon--arrow {
	inline-size: 0.925em;
}

.btn:hover .btn__icon--arrow,
.btn:focus-visible .btn__icon--arrow {
	transform: translateX(-6px); /* physical: the arrow points to the visual left */
}

.section-head {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-8);
	text-align: center;
}

.section-head__title {
	font-size: var(--fs-800);
}

.heart-divider {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: var(--space-4);
	inline-size: 100%;
	max-inline-size: 42.625rem; /* 682px — the divider's Figma width */
}

.heart-divider__line {
	flex: 1 1 0;
	max-inline-size: 18.8125rem; /* 301px per rule */
	border-block-start: 2px solid var(--color-primary);
}

.heart-divider__icon {
	flex: none;
	inline-size: calc(var(--fs-800) * 0.78); /* 50px @ 64px heading */
	transition: transform var(--duration-base) var(--ease-out);
}

.section-head:hover .heart-divider__icon {
	transform: scale(1.12);
}

/* ---------------------------------------------------------------------------
 * Header (Figma 258:224)
 * ------------------------------------------------------------------------- */

.site-header {
	--logo-size: clamp(6rem, 3.8rem + 9.02vw, 14.625rem); /* 96px @390 → 234px @1920 */
	position: relative;
	z-index: 20;
	background: var(--color-surface);
}

.site-header__inner {
	display: flex;
	align-items: center;
	gap: var(--space-9);
	padding-block: var(--space-16) var(--space-8);
}

/* The round logo overhangs the hero below it (Figma: 232px circle in a 143px bar). */
.site-header__logo {
	flex: none;
	align-self: flex-start;
	inline-size: var(--logo-size);
	margin-block: calc(var(--space-9) * -1) calc(var(--logo-size) * -0.62);
	border-radius: 50%;
	transition: transform var(--duration-base) var(--ease-out);
}

.site-header__logo:hover,
.site-header__logo:focus-visible {
	transform: rotate(-4deg) scale(1.03);
}

.site-header__logo img {
	inline-size: 100%;
}

.site-header__menu {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-8);
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-header__menu a {
	position: relative;
	display: inline-block;
	line-height: normal;
	text-shadow: var(--shadow-glow);
}

.site-header__menu a::after,
.site-drawer__menu a::after {
	content: "";
	position: absolute;
	inset-inline: 0;
	inset-block-end: -0.15em;
	block-size: 2px;
	background: var(--color-primary);
	transform: scaleX(0);
	transition: transform var(--duration-base) var(--ease-out);
}

.site-header__menu a:hover::after,
.site-header__menu a:focus-visible::after,
.site-header__menu .current-menu-item:not(.menu-item-type-custom) > a::after,
.site-drawer__menu a:hover::after {
	transform: scaleX(1);
}

.site-header__burger {
	display: none;
	margin-inline-start: auto;
	padding: var(--space-3);
	border: 0;
	background: none;
	cursor: pointer;
}

.site-header__burger-bars,
.site-header__burger-bars::before,
.site-header__burger-bars::after {
	display: block;
	inline-size: 1.75rem;
	block-size: 3px;
	border-radius: var(--radius-full);
	background: var(--color-ink);
	transition: transform var(--duration-base) var(--ease-out);
}

.site-header__burger-bars {
	position: relative;
}

.site-header__burger-bars::before,
.site-header__burger-bars::after {
	content: "";
	position: absolute;
	inset-inline-start: 0;
}

.site-header__burger-bars::before { transform: translateY(-9px); }
.site-header__burger-bars::after { transform: translateY(9px); }

/* "גלגל המזל" pill (Figma 258:188): pushed to the inline-end (visual left). */
.site-header__wheel {
	margin-inline-start: auto;
	white-space: nowrap;
}

.site-drawer__wheel {
	margin-block-start: var(--space-8);
}

@media (max-width: 1439px) { /* bp: --bp-xl — 7 links + the logo need the full desktop width */
	.site-header__nav,
	.site-header__wheel {
		display: none;
	}

	.site-header__burger {
		display: block;
	}

	.site-header__inner {
		padding-block: var(--space-6);
	}

	.site-header__logo {
		margin-block: calc(var(--space-3) * -1) calc(var(--logo-size) * -0.55);
	}
}

/* ---------------------------------------------------------------------------
 * Drawer (no Figma frame — composed from the tokens)
 * ------------------------------------------------------------------------- */

.site-drawer {
	position: fixed;
	inset: 0;
	z-index: 100;
}

.site-drawer[hidden] {
	display: none;
}

.site-drawer__backdrop {
	position: absolute;
	inset: 0;
	background: var(--color-ink);
	opacity: 0;
	transition: opacity var(--duration-base) var(--ease-out);
}

.site-drawer__panel {
	position: absolute;
	inset-block: 0;
	inset-inline-start: 0;
	inline-size: min(22rem, 85vw);
	padding: var(--space-21) var(--space-8) var(--space-8);
	overflow-y: auto;
	background: var(--color-surface);
	box-shadow: var(--shadow-card);
	transform: translateX(100%); /* physical: RTL drawer enters from the visual right */
	transition: transform var(--duration-base) var(--ease-out);
}

.site-drawer.is-open .site-drawer__backdrop { opacity: 0.35; }
.site-drawer.is-open .site-drawer__panel { transform: none; }

.site-drawer__close {
	position: absolute;
	inset-block-start: var(--space-4);
	inset-inline-end: var(--space-4);
	padding: var(--space-2) var(--space-3);
	border: 0;
	background: none;
	color: var(--color-ink);
	font-size: var(--fs-700);
	line-height: 1;
	cursor: pointer;
}

.site-drawer__menu {
	display: flex;
	flex-direction: column;
	gap: var(--space-6);
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: var(--fs-700);
}

.site-drawer__menu a {
	position: relative;
	display: inline-block;
}

/* ---------------------------------------------------------------------------
 * Footer — contact block (Figma 258:349) + legal row + credit (258:385)
 * ------------------------------------------------------------------------- */

.site-footer {
	position: relative;
	overflow-x: clip; /* the macaron strip is 106% wide by design */
}

.site-footer__contact {
	position: relative;
	isolation: isolate;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-6);
	padding-block: var(--space-26) var(--space-26);
	padding-inline: var(--gutter);
	scroll-margin-block-start: var(--space-8);
}

.site-footer__bg {
	position: absolute;
	inset: 0;
	z-index: -1;
}

.site-footer__bg img {
	inline-size: 100%;
	block-size: 100%;
	object-fit: cover;
}

.site-footer__panel {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-21);
	inline-size: 100%;
	max-inline-size: var(--container-max);
	padding-block: var(--space-16);
	padding-inline: var(--space-16);
	border-radius: var(--radius-lg);
	background: var(--color-surface-glass);
	box-shadow: var(--shadow-card);
	backdrop-filter: blur(2px);
}

.site-footer__panel .section-head {
	inline-size: 100%;
}

.site-footer__intro {
	margin-block-start: calc(var(--space-21) * -1 + var(--space-8)); /* intro sits in the heading stack (gap 32) */
	text-align: center;
}

.site-footer__form {
	inline-size: 100%;
	max-inline-size: 77.875rem; /* 1246px form row */
}

.site-footer__socials {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: var(--space-12);
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-footer__social {
	display: block;
	border-radius: 50%;
	transition: transform var(--duration-base) var(--ease-out);
}

.site-footer__social-icon {
	inline-size: clamp(3.5rem, 2.6rem + 3.7vw, 5.625rem); /* 56px → 90px */
	filter: drop-shadow(var(--shadow-button));
}

.site-footer__social:hover,
.site-footer__social:focus-visible {
	transform: translateY(-4px) scale(1.06);
}

.site-footer__legal {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: var(--space-6);
	text-align: center;
}

.site-footer__legal-menu {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: var(--space-6);
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-footer__legal-menu li,
.site-footer__copyright {
	display: flex;
	align-items: center;
	gap: var(--space-6);
}

/* Vertical rule between legal items (Figma 36px × 2px). */
.site-footer__legal-menu li::after {
	content: "";
	inline-size: 2px;
	block-size: 1.125em;
	background: var(--color-ink);
}

.site-footer__legal-menu a:hover {
	color: var(--color-primary);
}

.site-footer__copyright {
	gap: var(--space-3);
}

.site-footer__copyright-icon {
	inline-size: 1.25em;
}

/* The macaron strip overlaps the bottom of the contact photo (Figma: 216px strip, 77px over). */
.site-footer__macarons {
	position: relative;
	z-index: 1;
	margin-block-start: calc(-3.6 * var(--space-6));
	margin-inline: -3%;
	pointer-events: none;
}

.site-footer__macarons img {
	inline-size: 100%;
}

.site-footer__credit {
	display: flex;
	justify-content: center;
	padding-block: var(--space-12) var(--space-16);
}

.site-footer__credit img {
	inline-size: clamp(7rem, 5.6rem + 2.5vw, 11.125rem); /* 178px credit logo */
}

/* ---------------------------------------------------------------------------
 * Contact form (Figma 258:358 → 258:369) — B5 maps CF7 onto these classes
 * ------------------------------------------------------------------------- */

.contact-form {
	display: flex;
	flex-direction: column;
	gap: var(--space-21);
}

.contact-form__row {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: var(--space-6);
	padding: var(--space-2);
}

.contact-form__field {
	display: flex;
	flex: 1 1 14rem;
	min-inline-size: 0;
	align-items: flex-end;
	gap: var(--space-6);
}

.contact-form__field--wide {
	flex-basis: 100%;
}

.contact-form__label {
	flex: none;
	font-family: var(--font-display);
	font-size: var(--fs-700);
	letter-spacing: var(--tracking-display);
	line-height: 1.1;
}

.contact-form__input {
	flex: 1;
	inline-size: 100%; /* drop the input's ~20ch intrinsic width so 3 fields share a row */
	min-inline-size: 0;
	padding-block: var(--space-1);
	padding-inline: 0;
	border: 0;
	border-block-end: 2px solid var(--color-ink);
	border-radius: 0;
	background: transparent;
	font-size: var(--fs-400);
	resize: vertical;
	transition: border-color var(--duration-fast) var(--ease-out);
}

/* Submit arrow as a mask, so the CF7 form body needs no theme URL (CF7 stores it in the DB). */
.contact-form__submit::after {
	content: "";
	inline-size: 0.925em;
	aspect-ratio: 37 / 29;
	background: currentcolor;
	mask: url("assets/img/icon-arrow.svg") center / contain no-repeat;
	transition: transform var(--duration-base) var(--ease-out);
}

.contact-form__submit:hover::after,
.contact-form__submit:focus-visible::after {
	transform: translateX(-6px); /* physical: the arrow points to the visual left */
}

.contact-form__submit:disabled {
	opacity: 0.6;
	cursor: progress;
}

/* Privacy consent: box + label + link read as one sentence. The link sits OUTSIDE the
   CF7 label (clicking a link inside a label would tick the box). */
.contact-form__consent {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: var(--space-2);
	margin-block-start: calc(var(--space-21) * -1 + var(--space-6));
}

.contact-form .contact-form__consent .wpcf7-form-control-wrap,
.contact-form__consent .wpcf7-acceptance,
.contact-form__consent .wpcf7-list-item {
	display: contents; /* beats the general wrapper rule below (flex: 1 would split the sentence) */
}

.contact-form__consent label {
	display: flex;
	align-items: center;
	gap: var(--space-2);
	cursor: pointer;
}

.contact-form__consent input[type="checkbox"] {
	inline-size: 1.25rem;
	aspect-ratio: 1;
	margin: 0;
	accent-color: var(--color-primary-strong);
}

.contact-form__consent a {
	color: var(--color-ink);
	text-decoration: underline;
	text-underline-offset: 0.15em;
}

.contact-form__consent a:hover {
	color: var(--color-primary);
}

/* CF7 retarget: its wrapper span becomes the flex item that grows. */
.contact-form .wpcf7-form-control-wrap {
	display: flex;
	flex: 1;
	flex-direction: column;
	min-inline-size: 0;
}

.contact-form .wpcf7-not-valid-tip {
	margin-block-start: var(--space-1);
	color: var(--color-primary);
	font-size: var(--fs-400);
	text-align: start;
}

.contact-form .wpcf7-not-valid {
	border-block-end-color: var(--color-primary);
}

.contact-form .wpcf7-spinner {
	display: none;
}

.wpcf7 .contact-form .wpcf7-response-output,
.wpcf7-form.contact-form .wpcf7-response-output {
	margin: var(--space-6) 0 0;
	padding: var(--space-4) var(--space-6);
	border: 2px solid var(--color-primary);
	border-radius: var(--radius-lg);
	background: var(--color-surface-raised);
	text-align: center;
}

.contact-form__input:focus {
	outline: none;
	border-block-end-color: var(--color-primary);
}

.contact-form__input:focus-visible {
	outline: none;
	box-shadow: 0 2px 0 0 var(--color-primary);
}

@media (max-width: 767px) { /* bp: --bp-md */
	.site-footer__panel {
		padding-inline: var(--space-6);
		gap: var(--space-16);
	}

	.site-footer__intro {
		margin-block-start: calc(var(--space-16) * -1 + var(--space-6));
	}

	.contact-form {
		gap: var(--space-8);
	}

	.contact-form__row {
		flex-direction: column;
		align-items: stretch;
		gap: var(--space-8);
		padding: 0;
	}

	.contact-form__field {
		flex-basis: auto;
	}

	.site-footer__legal,
	.site-footer__legal-menu {
		flex-direction: column;
		gap: var(--space-3);
	}

	.site-footer__legal-menu li::after {
		display: none;
	}
}

/* ---------------------------------------------------------------------------
 * Card — Figma 258:295 (home) / 258:490 (patisserie): white, 5px pink frame, radius 32
 * ------------------------------------------------------------------------- */

.card {
	display: flex;
	flex-direction: column;
	gap: var(--space-12);
	overflow: hidden; /* radius mask for the photo — decorative clip */
	padding-block-end: var(--space-8);
	border: 5px solid var(--color-primary);
	border-radius: var(--radius-lg);
	background: var(--color-surface-raised);
	box-shadow: var(--shadow-button);
	transition:
		transform var(--duration-base) var(--ease-out),
		box-shadow var(--duration-base) var(--ease-out);
}

.card:hover,
.card:focus-within {
	transform: translateY(-6px);
	box-shadow: var(--shadow-card);
}

.card__media {
	margin: 0;
	aspect-ratio: 439 / 376; /* the Figma photo box (R7: ratio on the container) */
	overflow: hidden;
}

.card__media img {
	inline-size: 100%;
	block-size: 100%;
	object-fit: cover;
	transition: transform 700ms var(--ease-out);
}

.card:hover .card__media img {
	transform: scale(1.05);
}

.card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	align-items: center;
	gap: var(--space-9);
	padding-inline: var(--space-3);
	text-align: center;
}

.card__title {
	font-size: var(--fs-700);
}

.card__cta {
	margin-block-start: auto;
}

/* ---------------------------------------------------------------------------
 * Gift-wheel popup (SpinToWin iframe, loaded on first open)
 * ------------------------------------------------------------------------- */

.wheel-dialog {
	inline-size: min(92vw, 30rem);
	block-size: min(85vh, 48rem);
	padding: 0;
	border: 0;
	border-radius: var(--radius-lg);
	background: var(--color-surface);
	box-shadow: var(--shadow-card);
	overflow: visible;
}

.wheel-dialog[open] {
	animation: lightbox-in var(--duration-base) var(--ease-out);
}

.wheel-dialog::backdrop {
	background: var(--color-ink);
	opacity: 0.8;
}

.wheel-dialog__frame {
	display: block;
	inline-size: 100%;
	block-size: 100%;
	border: 0;
	border-radius: var(--radius-lg);
}

.wheel-dialog__close {
	position: absolute;
	inset-block-start: calc(var(--space-12) * -1);
	inset-inline-end: 0;
	display: grid;
	place-items: center;
	inline-size: 2.75rem;
	aspect-ratio: 1;
	padding: 0;
	border: 1px solid var(--color-tint);
	border-radius: 50%;
	background: var(--color-primary-strong);
	color: var(--color-on-primary);
	font-size: var(--fs-600);
	line-height: 1;
	cursor: pointer;
	transition: transform var(--duration-fast) var(--ease-out);
}

.wheel-dialog__close:hover {
	transform: scale(1.08);
}

/* Category page: order CTA under the gallery. */
.category-order {
	display: flex;
	justify-content: center;
	padding-block: var(--space-8) calc(var(--space-section) / 2);
}

/* ---------------------------------------------------------------------------
 * Marquee pause/play (testimonials, workshop strips) — WCAG 2.2.2
 * ------------------------------------------------------------------------- */

.marquee-toggle {
	display: grid;
	place-items: center;
	inline-size: 2.25rem;
	aspect-ratio: 1;
	padding: 0;
	border: 1px solid var(--color-primary);
	border-radius: 50%;
	background: var(--color-surface);
	color: var(--color-ink);
	cursor: pointer;
	transition: transform var(--duration-fast) var(--ease-out), background-color var(--duration-fast) var(--ease-out);
}

.marquee-toggle:hover {
	transform: scale(1.08);
	background: var(--color-tint);
}

/* Two bars while moving, a triangle (pointing left = forward in RTL) once paused. */
.marquee-toggle__icon {
	inline-size: 0.75rem;
	aspect-ratio: 1;
	background: currentcolor;
	clip-path: polygon(0 0, 35% 0, 35% 100%, 0 100%, 0 0, 65% 0, 100% 0, 100% 100%, 65% 100%, 65% 0);
}

.marquee-toggle[aria-pressed="true"] .marquee-toggle__icon {
	clip-path: polygon(100% 0, 100% 100%, 0 50%);
}

@media (prefers-reduced-motion: reduce) {
	.marquee-toggle {
		display: none; /* nothing moves, nothing to pause */
	}
}

/* ---------------------------------------------------------------------------
 * Video poster + lightbox (lecture videos, category gallery)
 * ------------------------------------------------------------------------- */

.video-poster {
	display: grid;
	grid-template: minmax(0, 1fr) / minmax(0, 1fr); /* the cell is the box (aspect-ratio), not the photo's own height */
	margin: 0;
	overflow: hidden; /* radius mask */
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-card);
}

/* Poster and play icon share one grid cell: the icon centres without absolute positioning. */
.video-poster > img {
	grid-area: 1 / 1;
	inline-size: 100%;
	block-size: 100%;
	object-fit: cover;
	transition: transform 700ms var(--ease-out);
}

.video-poster > .screen-reader-text {
	grid-area: 1 / 1; /* otherwise it opens an implicit row below the poster */
}

.video-poster > .video-poster__play {
	grid-area: 1 / 1;
	place-self: center;
	inline-size: clamp(4rem, 2.8rem + 4.9vw, 8.125rem); /* 130px play icon */
	filter: drop-shadow(var(--shadow-card));
	transition: transform var(--duration-base) var(--ease-out);
}

.video-poster--playable:hover img { transform: scale(1.04); }
.video-poster--playable:hover .video-poster__play { transform: scale(1.1); }

.lightbox {
	inline-size: min(92vw, 80rem);
	max-block-size: 94vh;
	padding: 0;
	border: 0;
	background: transparent;
	overflow: visible;
}

.lightbox::backdrop {
	background: var(--color-ink);
	opacity: 0.88;
}

.lightbox__stage {
	display: grid;
	place-items: center;
	min-block-size: 20vh;
	touch-action: pan-y;
}

.lightbox__img,
.lightbox__stage video,
.lightbox__stage iframe {
	max-inline-size: 100%;
	max-block-size: 80vh;
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-card);
}

.lightbox__img {
	animation: lightbox-in var(--duration-base) var(--ease-out);
	user-select: none;
}

@keyframes lightbox-in {
	from { opacity: 0; transform: scale(0.98); }
	to { opacity: 1; transform: none; }
}

.lightbox__stage iframe {
	inline-size: 100%;
	block-size: auto;
	aspect-ratio: 16 / 9;
	border: 0;
}

/* YouTube Shorts: a phone-shaped player, as tall as the screen allows. */
.lightbox.is-vertical .lightbox__stage iframe {
	inline-size: auto;
	block-size: min(80vh, 50rem);
	aspect-ratio: 9 / 16;
}

.lightbox__bar {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: var(--space-6);
	margin-block-start: var(--space-4);
	color: var(--color-on-primary);
}

.lightbox.is-single .lightbox__bar {
	display: none;
}

.lightbox__btn,
.lightbox__close {
	display: grid;
	place-items: center;
	inline-size: 3rem;
	aspect-ratio: 1;
	padding: 0;
	border: 1px solid var(--color-tint);
	border-radius: 50%;
	background: var(--color-primary);
	color: var(--color-on-primary);
	font-size: var(--fs-600);
	line-height: 1;
	cursor: pointer;
	transition: transform var(--duration-fast) var(--ease-out), background-color var(--duration-fast) var(--ease-out);
}

.lightbox__btn:hover,
.lightbox__close:hover {
	transform: scale(1.08);
}

/* Arrows: the site chevron as a mask. Not the ‹ › characters — those are
   bidi-mirrored and flip in RTL text. The SVG points left (= "next" in RTL). */
.lightbox__prev span,
.lightbox__next span {
	inline-size: 0.7rem;
	aspect-ratio: 23.5 / 42;
	background: currentcolor;
	mask: url("assets/img/icon-chevron.svg") center / contain no-repeat;
}

.lightbox__prev span {
	transform: scaleX(-1); /* physical: "previous" sits on the visual right and points right */
}

/* Play / pause glyph drawn in CSS: two bars while playing, a triangle while paused. */
.lightbox__play span {
	inline-size: 0.875rem;
	aspect-ratio: 1;
	background: currentcolor;
	clip-path: polygon(100% 0, 100% 100%, 0 50%); /* points left = forward in RTL */
}

.lightbox.is-playing .lightbox__play span {
	clip-path: polygon(0 0, 35% 0, 35% 100%, 0 100%, 0 0, 65% 0, 100% 0, 100% 100%, 65% 100%, 65% 0);
}

.lightbox__count {
	min-inline-size: 4ch;
	font-variant-numeric: tabular-nums;
	text-align: center;
}

.lightbox__close {
	position: absolute;
	inset-block-start: calc(var(--space-16) * -1);
	inset-inline-end: 0;
}

/* Auto-enabled images (script.js) */
[data-lightbox-auto] {
	cursor: zoom-in;
}

[data-lightbox-auto]:focus-visible {
	outline-offset: -4px;
}

@media (max-width: 767px) { /* bp: --bp-md */
	.lightbox__close {
		inset-block-start: calc(var(--space-12) * -1);
	}
}

/* Page CTA pill (lecture / workshops): 545px, padding 24, arrow icon. */
.btn--cta {
	--btn-pad: var(--space-6);
	inline-size: min(100%, 34.0625rem);
}

/* ---------------------------------------------------------------------------
 * AccessibleWP toolbar (plugin) — reset to the base type, park the button
 * bottom-left so it never covers the hero copy or the header pill.
 * ------------------------------------------------------------------------- */

#acwp-toolbar,
#acwp-toolbar-btn-wrap {
	font-family: var(--font-body);
	font-size: 1rem;
	line-height: 1.4;
}

#acwp-toolbar-btn-wrap {
	top: auto !important; /* the plugin prints top: 120px inline */
	bottom: var(--space-6);
	left: var(--space-6) !important; /* physical: the visual bottom-left corner, clear of the content */
	right: auto !important; /* physical: pairs with left */
}

#acwp-toolbar .acwp-toggler label {
	font-size: 1rem;
}
