/*
Theme Name: Maple Grove West
Theme URI: https://maplegrovewest.com
Description: Beaver Builder child theme for the Maple Grove West landing page (Landric Homes).
Author: Landric Homes
Template: bb-theme
Version: 1.3.0
Text Domain: maple-grove-west
*/

/* ------------------------------------------------------------------
   Rules for what belongs here (everything else is a Beaver Builder,
   Themer, or theme Customizer setting):

   1. Site-wide browser primitives Beaver Builder has no field for
      (smooth scroll, focus rings, reduced motion, image rendering).
   2. Gravity Forms Orbital theme overrides — the form can be reused on
      other pages, so it is styled once here, not per page.
   3. Nothing node-specific. Page-only rules go in that page's Layout CSS,
      header/footer rules go in the Themer layout's CSS.
------------------------------------------------------------------- */

/* ---------- Primitives ---------- */
html {
	/* No CSS smooth scrolling: Beaver Builder animates anchor links itself (with the sticky-header offset),
	   and the two together produce a stuttering scroll. */
	scroll-padding-top: 110px; /* announcement bar + sticky header */
}

body {
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

.fl-builder-content img {
	height: auto;
}

/* Visible keyboard focus on our brand colour (BB global outline setting covers modules; this covers theme/GF elements). */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
	outline: 2px solid var(--fl-global-green, #2f5233);
	outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
	.fl-builder-content *,
	.fl-theme-builder-header * {
		animation: none !important;
		transition: none !important;
	}
}

/* ---------- Rich text spacing ----------
   Module margins control vertical rhythm; the last paragraph inside a
   Text Editor module must not add its own bottom margin. */
.fl-builder-content .fl-rich-text > :last-child {
	margin-bottom: 0;
}

/* ---------- Gravity Forms (basic "gravity-theme") ----------
   Styled once here to match the design system exactly; the form may be
   reused on other pages. Values mirror the original landing page form. */
.gform_wrapper.gravity-theme .gform_required_legend {
	display: none;
}
.gform_wrapper.gravity-theme .gform_fields {
	display: grid;
	grid-template-columns: repeat(12, 1fr);
	grid-column-gap: 19.2px;
	grid-row-gap: 19.2px;
}
.gform_wrapper.gravity-theme .gfield {
	margin: 0;
}
/* Required fields reserve the inline error line (.field__error: .35rem + 1em at .78rem). */
.gform_wrapper.gravity-theme .gfield.gfield_contains_required {
	padding-bottom: 18.08px;
}
.gform_wrapper.gravity-theme .gfield.gfield_contains_required.gfield_error {
	padding-bottom: 0;
}
.gform_wrapper.gravity-theme .gfield_label {
	display: block;
	font-family: "Jost", system-ui, sans-serif;
	font-size: 13px;
	line-height: 1.65;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	font-weight: 500;
	color: var(--fl-global-ink, #1c1d1a);
	margin: 0 0 8px;
	padding: 0;
}
.gform_wrapper.gravity-theme .gfield_required {
	color: var(--fl-global-gold, #b8922f);
	font-size: inherit;
	margin-left: 4px;
	margin-right: 0;
}
.gform_wrapper.gravity-theme .gfield_required_text {
	display: none;
}
.gform_wrapper.gravity-theme input[type="text"],
.gform_wrapper.gravity-theme input[type="email"],
.gform_wrapper.gravity-theme input[type="tel"],
.gform_wrapper.gravity-theme select,
.gform_wrapper.gravity-theme textarea {
	font-family: "Jost", system-ui, sans-serif;
	font-size: 15.68px;
	font-weight: 300;
	line-height: normal;
	color: var(--fl-global-ink, #1c1d1a);
	padding: 12.8px 14.4px;
	border: 1px solid var(--fl-global-line, #e4ddcf);
	border-radius: 4px;
	background: var(--fl-global-cream, #faf8f3);
	width: 100%;
	height: auto;
	min-height: 0;
	margin: 0;
	box-shadow: none;
	transition: border-color 0.2s, box-shadow 0.2s;
}
.gform_wrapper.gravity-theme input:focus,
.gform_wrapper.gravity-theme select:focus,
.gform_wrapper.gravity-theme textarea:focus {
	outline: none;
	border-color: var(--fl-global-green, #2f5233);
	box-shadow: 0 0 0 3px rgba(47, 82, 51, 0.12);
	background: #ffffff;
}
.gform_wrapper.gravity-theme .gfield .ginput_container textarea,
.gform_wrapper.gravity-theme .gfield .ginput_container textarea.small,
.gform_wrapper.gravity-theme .gfield .ginput_container textarea.medium,
.gform_wrapper.gravity-theme .gfield .ginput_container textarea.large {
	resize: vertical;
	height: 120px; /* rows="4" in the original */
}
.gform_wrapper.gravity-theme .ginput_container_select {
	position: relative;
}
.gform_wrapper.gravity-theme .ginput_container_select::after {
	content: "";
	position: absolute;
	right: 16px;
	top: 50%;
	width: 8px;
	height: 8px;
	border-right: 2px solid var(--fl-global-ink-soft, #4a4c46);
	border-bottom: 2px solid var(--fl-global-ink-soft, #4a4c46);
	transform: translateY(-70%) rotate(45deg);
	pointer-events: none;
}
.gform_wrapper.gravity-theme select {
	appearance: none;
	-webkit-appearance: none;
	cursor: pointer;
	padding-right: 40px;
}
.gform_wrapper.gravity-theme ::placeholder {
	color: var(--fl-global-ink-soft, #4a4c46);
	opacity: 0.55;
}
.gform_wrapper.gravity-theme .gfield_radio {
	display: flex;
	gap: 19.2px;
	padding-top: 6.4px;
}
.gform_wrapper.gravity-theme .gfield_radio .gchoice {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}
.gform_wrapper.gravity-theme .gfield_radio input[type="radio"] {
	accent-color: var(--fl-global-green, #2f5233);
	width: 18px;
	height: 18px;
	margin: 0;
}
.gform_wrapper.gravity-theme .gfield_radio label {
	display: inline;
	max-width: none;
	white-space: nowrap;
	font-size: 16px;
	font-weight: 300;
	line-height: 1.65;
	color: var(--fl-global-ink, #1c1d1a);
	margin: 0;
	padding: 0;
}
.gform_wrapper.gravity-theme .gform_footer {
	margin: 19.2px 0 0;
	padding: 0;
}
.gform_wrapper.gravity-theme .gform_footer .gform_button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	font-family: "Jost", system-ui, sans-serif;
	font-size: 13.6px;
	font-weight: 500;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	line-height: normal;
	color: #ffffff;
	background: var(--fl-global-green, #2f5233);
	padding: 16px 32px;
	border: 1px solid transparent;
	border-radius: 4px;
	margin: 0;
	cursor: pointer;
	transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), background 0.25s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}
.gform_wrapper.gravity-theme .gform_footer .gform_button:hover {
	background: var(--fl-global-green-deep, #223d26);
	transform: translateY(-2px);
	box-shadow: 0 10px 24px rgba(47, 82, 51, 0.28);
}
.gform_wrapper.gravity-theme .gfield_validation_message,
.gform_wrapper.gravity-theme .validation_message {
	background: none;
	border: 0;
	padding: 0;
	margin: 5.6px 0 0;
	color: #c0392b;
	font-size: 13px;
	font-weight: 400;
}
.gform_wrapper.gravity-theme .gfield_error input,
.gform_wrapper.gravity-theme .gfield_error select,
.gform_wrapper.gravity-theme .gfield_error textarea {
	border-color: #c0392b;
	box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.1);
}
.gform_wrapper.gravity-theme .gform_validation_errors {
	display: none;
}

/* Gravity Forms enlarges inputs below 640px; keep the original metrics at every width. */
@media (max-width: 641px) {
	/* Same specificity as Gravity Forms' own phone rule (:not() chains), declared later so ours wins. */
	.gform_wrapper.gravity-theme .gfield input:not([type="radio"]):not([type="checkbox"]):not([type="image"]):not([type="file"]),
	.gform_wrapper.gravity-theme .gfield select:not([multiple]):not([size]),
	.gform_wrapper.gravity-theme .gfield textarea:not([rows="0"]):not([cols="0"]):not([wrap="x"]):not([wrap="y"]) {
		font-size: 15.68px;
		line-height: normal;
		min-height: 0;
		height: auto;
	}
	.gform_wrapper.gravity-theme .gfield .ginput_container textarea:not([rows="0"]):not([cols="0"]):not([wrap="x"]):not([wrap="y"]) {
		height: 120px;
	}
}

/* Single-column form at the original 720px breakpoint. */
@media (max-width: 720px) {
	.gform_wrapper.gravity-theme .gfield.gfield--width-half {
		grid-column: span 12;
	}
}

/* Confirmation message (replaces the form after submit). */
.gform_confirmation_wrapper .gform_confirmation_message {
	text-align: center;
	padding: 40px 16px;
	color: var(--fl-global-ink-soft, #4a4c46);
	font-size: 16px;
	font-weight: 300;
	line-height: 1.65;
	animation: mgwFadeUp 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.gform_confirmation_message .mgw-confirm__mark {
	width: 66px;
	height: 66px;
	margin: 0 auto 22.4px;
	border-radius: 50%;
	background: var(--fl-global-green-soft, #eef2ec);
	color: var(--fl-global-green, #2f5233);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 30px;
}
.gform_confirmation_message h3 {
	font-family: "Cormorant Garamond", Georgia, serif;
	font-size: 30.4px;
	font-weight: 600;
	line-height: 1.65;
	color: var(--fl-global-ink, #1c1d1a);
	margin: 0 0 11.2px;
}
.gform_confirmation_message p {
	max-width: 42ch;
	margin: 0 auto;
}
.gform_confirmation_message a {
	color: var(--fl-global-green, #2f5233);
	font-weight: 500;
}
@keyframes mgwFadeUp {
	from { opacity: 0; transform: translateY(16px); }
	to { opacity: 1; transform: none; }
}
