/* Metaflor blocks — component styles. Brand values come from the theme's CSS variables, with fallbacks. */
:root {
	--_green: var(--mf-green, #173c2b);
	--_green-2: var(--mf-green-2, #42785b);
	--_cream: var(--mf-cream, #f8f5ed);
	--_sand: var(--mf-sand, #efe8d8);
	--_ink: var(--mf-ink, #2c4a3b);
	--_gold: var(--mf-gold, #f3d9a4);
	--_error: var(--mf-error, #a3312b);
	--_serif: var(--mf-font-serif, "Cormorant Garamond", Georgia, serif);
}

/* ---------- Hero ---------- */
.mf-hero {
	position: relative;
	display: flex;
	align-items: flex-end;
	min-height: clamp(560px, 82vh, 860px);
	overflow: hidden;
	color: var(--_cream);
	background: var(--_green);
	isolation: isolate;
}
.mf-hero__media, .mf-hero__media picture, .mf-hero__img, .mf-hero__video, .mf-hero__fallback, .mf-hero__overlay {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}
.mf-hero__media { z-index: -2; }
.mf-hero__img, .mf-hero__video {
	object-fit: cover;
	object-position: var(--mf-focal, 50% 50%);
}
.mf-hero__fallback { background: radial-gradient(circle at 70% 40%, #b9737a, var(--_green)); }
.mf-hero__video { opacity: 0; transition: opacity .8s ease; }
.mf-hero.is-playing .mf-hero__video { opacity: 1; }
.mf-hero__overlay {
	z-index: -1;
	background: linear-gradient(90deg, rgba(16, 41, 30, calc(var(--mf-overlay, .55) + .25)) 0%, rgba(16, 41, 30, var(--mf-overlay, .55)) 45%, rgba(16, 41, 30, calc(var(--mf-overlay, .55) * .25)) 85%);
}
.mf-hero__inner {
	width: 100%;
	max-width: var(--mf-wide, 1320px);
	margin: 0 auto;
	padding: 120px var(--mf-gutter, 24px) clamp(56px, 9vh, 104px);
	box-sizing: border-box;
}
.mf-hero__eyebrow {
	margin: 0 0 18px;
	font-size: .8125rem;
	font-weight: 700;
	letter-spacing: .22em;
	text-transform: uppercase;
	color: var(--_gold);
}
.mf-hero__title {
	max-width: 15em;
	margin: 0;
	font-family: var(--_serif);
	font-weight: 500;
	font-size: clamp(2.6rem, 6vw, 5.25rem);
	line-height: 1.02;
	color: var(--_cream);
	text-wrap: balance;
}
.mf-hero__text {
	max-width: 34em;
	margin: 26px 0 0;
	color: var(--_cream);
	font-size: clamp(1.0625rem, 1.4vw, 1.1875rem);
	line-height: 1.6;
}
.mf-hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 38px; }
.mf-hero__toggle {
	position: absolute;
	right: var(--mf-gutter, 24px);
	bottom: 24px;
	width: 48px;
	height: 48px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 999px;
	border: 1px solid rgba(248, 245, 237, .75);
	background: rgba(16, 41, 30, .55);
	color: var(--_cream);
	cursor: pointer;
}
.mf-hero__toggle[hidden] { display: none; }
.mf-hero__toggle .mf-icon-play, .mf-hero__toggle.is-paused .mf-icon-pause { display: none; }
.mf-hero__toggle.is-paused .mf-icon-play { display: block; }
.mf-hero__toggle:focus-visible { outline: 3px solid var(--_gold); outline-offset: 3px; }
@media (max-width: 767px) {
	.mf-hero { min-height: 640px; }
	.mf-hero__img { object-position: var(--mf-focal-mobile, 50% 50%); }
	.mf-hero__overlay { background: linear-gradient(0deg, rgba(16, 41, 30, calc(var(--mf-overlay, .55) + .3)) 0%, rgba(16, 41, 30, var(--mf-overlay, .55)) 55%, rgba(16, 41, 30, calc(var(--mf-overlay, .55) * .3)) 100%); }
	.mf-hero__inner { padding-bottom: 48px; }
	.mf-hero__actions { flex-direction: column; }
	.mf-hero__actions .mf-btn { text-align: center; }
}

/* ---------- Buttons used inside blocks ---------- */
.mf-btn {
	display: inline-block;
	min-height: 48px;
	padding: 15px 28px;
	box-sizing: border-box;
	border: 1px solid transparent;
	border-radius: 2px;
	font-weight: 700;
	font-size: 1rem;
	line-height: 1.1;
	text-decoration: none;
	transition: background-color .2s, color .2s;
}
.mf-btn--light { background: var(--_cream); color: var(--_green); }
.mf-btn--light:hover { background: #fff; color: var(--_green); }
.mf-btn--outline-light { border-color: var(--_cream); color: var(--_cream); }
.mf-btn--outline-light:hover { background: rgba(248, 245, 237, .14); color: var(--_cream); }
.mf-btn--primary { background: var(--_green); color: var(--_cream); border: 0; cursor: pointer; font-family: inherit; }
.mf-btn--primary:hover { background: #0f2a1e; }
.mf-btn--primary:disabled { opacity: .7; cursor: progress; }
.mf-btn--outline { border-color: var(--_green); color: var(--_green); }
.mf-btn:focus-visible { outline: 3px solid var(--mf-focus, #c99a3b); outline-offset: 3px; }

/* ---------- Filters ---------- */
.mf-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	justify-content: space-between;
	align-items: center;
	padding: 18px 0;
	margin-bottom: 40px;
	border-top: 1px solid rgba(23, 60, 43, .18);
	border-bottom: 1px solid rgba(23, 60, 43, .18);
}
.mf-filters__links, .mf-filters__buttons { display: flex; flex-wrap: wrap; gap: 10px; }
.mf-filters__links[hidden], .mf-filters__buttons[hidden] { display: none; }
.mf-filters__status { margin: 0; font-size: .875rem; color: var(--_green-2); min-height: 1.4em; }
.mf-chip {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 8px 20px;
	border: 1px solid var(--_green);
	border-radius: 999px;
	background: transparent;
	color: var(--_green);
	font: 700 .875rem/1.2 inherit;
	font-family: inherit;
	text-decoration: none;
	cursor: pointer;
}
.mf-chip:hover { background: rgba(23, 60, 43, .06); }
.mf-chip[aria-pressed="true"] { background: var(--_green); color: var(--_cream); }
.mf-chip:focus-visible { outline: 3px solid var(--mf-focus, #c99a3b); outline-offset: 2px; }

/* ---------- Cards / grid ---------- */
.mf-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
	gap: 48px 28px;
}
.mf-card { display: flex; flex-direction: column; }
.mf-card[hidden] { display: none; }
.mf-card__media { display: block; margin-bottom: 18px; background: var(--_sand); aspect-ratio: 4 / 5; overflow: hidden; }
.mf-card__img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.mf-card:hover .mf-card__img { transform: scale(1.03); }
.mf-card__noimg { display: block; width: 100%; height: 100%; }
.mf-card__cat { margin: 0 0 6px; font-size: .75rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--_green-2); }
.mf-card__title { margin: 0; font-family: var(--_serif); font-weight: 600; font-size: 1.75rem; line-height: 1.1; }
.mf-card__title a { color: var(--_green); text-decoration: none; }
.mf-card__title a:hover { text-decoration: underline; text-underline-offset: 4px; }
.mf-card__alt { margin: 2px 0 10px; font-family: var(--_serif); font-style: italic; font-size: 1.1875rem; color: var(--_green-2); }
.mf-card__desc { margin: 0 0 12px; font-size: .9375rem; line-height: 1.6; color: var(--_ink); }
.mf-card__facts { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0 0 16px; font-size: .875rem; line-height: 1.5; }
.mf-card__facts dt { font-weight: 700; }
.mf-card__facts dd { margin: 0; color: var(--_ink); }
.mf-card__more { margin-top: auto; font-weight: 700; font-size: .9375rem; color: var(--_green); }
.mf-note {
	margin: 56px 0 0;
	padding: 20px 24px;
	background: var(--_sand);
	font-size: .9375rem;
	line-height: 1.6;
	color: var(--_green);
}

/* ---------- Featured ---------- */
.mf-featured { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 24px; }
.mf-featured__item { display: flex; flex-direction: column; color: var(--_green); text-decoration: none; }
.mf-featured__img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; margin-bottom: 14px; background: var(--_sand); }
.mf-featured__name { font-family: var(--_serif); font-weight: 600; font-size: 1.5rem; line-height: 1.15; }
.mf-featured__item:hover .mf-featured__name { text-decoration: underline; text-underline-offset: 4px; }
.mf-featured__cat { margin-top: 4px; font-size: .875rem; color: var(--_green-2); }
.mf-featured__note { margin: 28px 0 0; font-size: .9375rem; color: var(--_green-2); }
@media (max-width: 600px) { .mf-featured { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; } .mf-featured__name { font-size: 1.25rem; } }

/* ---------- Contact details ---------- */
.mf-contact-details { margin: 24px 0; }
.mf-contact-details > div { padding: 18px 0; border-top: 1px solid rgba(23, 60, 43, .2); }
.mf-contact-details > div:last-child { border-bottom: 1px solid rgba(23, 60, 43, .2); }
.mf-contact-details dt { margin: 0 0 4px; font-size: .75rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--_green-2); }
.mf-contact-details dd { margin: 0; font-family: var(--_serif); font-size: 1.625rem; font-weight: 600; overflow-wrap: anywhere; }
.mf-contact-details a { color: inherit; }
.mf-contact-details--inline { display: flex; flex-wrap: wrap; gap: 8px 28px; }
.mf-contact-details--inline > div, .mf-contact-details--inline > div:last-child { padding: 0; border: 0; }
.mf-contact-details--inline dt { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mf-contact-details--inline dd { font-family: inherit; font-size: 1rem; font-weight: 400; }
.mf-editor-note { display: inline-block; padding: 4px 8px; background: #fff4d6; color: #5c4400; font: 600 .8125rem/1.4 system-ui, sans-serif; border: 1px dashed #b88a00; }

/* ---------- Inquiry form ---------- */
.mf-inquiry { background: #fff; padding: clamp(24px, 4vw, 48px); border: 1px solid rgba(23, 60, 43, .12); color: var(--_green); }
.mf-inquiry__success h2, .mf-form__title { margin: 0 0 10px; font-family: var(--_serif); font-weight: 500; font-size: clamp(1.9rem, 3vw, 2.4rem); line-height: 1.1; }
.mf-inquiry__success:focus { outline: none; }
.mf-form { display: flex; flex-direction: column; gap: 22px; }
.mf-form[hidden], .mf-inquiry__success[hidden] { display: none; }
.mf-form__req { margin: -8px 0 0; font-size: .875rem; color: var(--_ink); }
.mf-form__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 22px; }
.mf-form__grid--city { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
@media (max-width: 480px) { .mf-form__grid--city { grid-template-columns: 1fr; } }
.mf-field label { display: block; margin-bottom: 8px; font-weight: 700; }
.mf-optional { font-weight: 400; color: var(--_ink); }
.mf-hint { margin: -4px 0 8px; font-size: .875rem; color: var(--_ink); }
.mf-field input, .mf-field select, .mf-field textarea {
	display: block;
	width: 100%;
	min-height: 48px;
	padding: 12px 14px;
	box-sizing: border-box;
	border: 1px solid #6b7f74;
	border-radius: 2px;
	background: #fff;
	color: var(--_green);
	font: inherit;
	font-size: 1rem;
}
.mf-field textarea { resize: vertical; min-height: 150px; }
.mf-field input:focus, .mf-field select:focus, .mf-field textarea:focus { outline: 3px solid var(--mf-focus, #c99a3b); outline-offset: 1px; border-color: var(--_green); }
.mf-field.has-error input, .mf-field.has-error textarea, .mf-field.has-error select { border: 2px solid var(--_error); }
.mf-error { margin: 6px 0 0; font-size: .875rem; font-weight: 700; color: var(--_error); }
.mf-error[hidden] { display: none; }
.mf-form__alert { padding: 16px 20px; border: 2px solid var(--_error); background: #fbedeb; color: #7a1f1a; }
.mf-form__alert[hidden] { display: none; }
.mf-form__alert p { margin: 0 0 6px; }
.mf-form__alert ul { margin: 0; padding-left: 20px; }
.mf-form__alert a { color: #7a1f1a; }
.mf-form__alert:focus { outline: 3px solid var(--mf-focus, #c99a3b); outline-offset: 2px; }
.mf-form__privacy { margin: 0; font-size: .8125rem; line-height: 1.6; color: var(--_ink); }
.mf-form .mf-btn--primary { align-self: flex-start; min-height: 52px; padding: 15px 32px; }
.mf-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
	.mf-hero__video { display: none; }
	.mf-card__img, .mf-btn { transition: none; }
	.mf-card:hover .mf-card__img { transform: none; }
}

/* ---------- Form sections, choices, wide fields (contact + application) ---------- */
.mf-form__grid > .mf-field--wide, .mf-form__grid > .mf-field--checkbox, .mf-form__grid > .mf-field--checkboxes { grid-column: 1 / -1; }
.mf-form__section {
	margin: 12px 0 0;
	padding: 12px 18px;
	background: var(--_green);
	color: var(--_cream);
	font: 700 .8125rem/1.3 var(--mf-font-sans, Mulish, sans-serif);
	letter-spacing: .16em;
	text-transform: uppercase;
}
.mf-form__intro { font-size: .9375rem; line-height: 1.65; color: var(--_ink); }
.mf-form__intro p { margin: 0 0 12px; }
.mf-policy { background: var(--_cream); padding: 14px 18px; }
.mf-policy summary { cursor: pointer; font-weight: 700; color: var(--_green); min-height: 24px; }
.mf-policy ul { margin: 12px 0 0; padding-left: 20px; }
fieldset.mf-field { border: 0; margin: 0; padding: 0; min-width: 0; }
fieldset.mf-field legend { padding: 0; margin-bottom: 8px; font-weight: 700; }
.mf-choices { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.mf-check, .mf-field label.mf-check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; margin: 0 !important; min-height: 32px; cursor: pointer; }
.mf-field .mf-check input { width: 22px; min-height: 22px; height: 22px; margin: 1px 0 0; padding: 0; flex: none; accent-color: var(--_green); }
.mf-field.has-error .mf-check input { outline: 2px solid var(--_error); outline-offset: 1px; border: 0; }
.mf-field select { appearance: auto; }
