/* ==========================================================================
   Forest Lawn — component styles
   --------------------------------------------------------------------------
   Colours and fonts come from Elementor > Site Settings, exposed as CSS
   variables (--e-global-color-*, --e-global-typography-*). Change them there
   and everything below follows.

   This file only covers what Elementor's free controls can't do:
     - small global refinements (text balance, focus ring, anchors)
     - the mobile hero fade
     - "fl-" helper classes you can add under Advanced > CSS Classes
     - Gravity Forms styling for the Contact form
   ========================================================================== */

:root {
	--fl-ink: var(--e-global-color-primary, #042213);
	--fl-green: var(--e-global-color-secondary, #3a684c);
	--fl-body: var(--e-global-color-text, #424843);
	--fl-green-dark: var(--e-global-color-green_dark, #2f563e);
	--fl-surface: var(--e-global-color-surface, #edf6ec);
	--fl-surface-alt: var(--e-global-color-surface_alt, #e8f0e7);
	--fl-on-dark: var(--e-global-color-on_dark, #f3fcf2);
	--fl-muted: var(--e-global-color-muted, #727973);
	--fl-white: #ffffff;
	--fl-font-body: var(--e-global-typography-text-font-family, 'Plus Jakarta Sans'), system-ui, sans-serif;
	--fl-header-height: 72px;
}

/* ---------- Global refinements ---------- */

html {
	scroll-behavior: smooth;
}

body {
	-webkit-font-smoothing: antialiased;
}

/* Anchor links (e.g. "Learn More" → #did-you-know) land clear of the edge. */
[id] {
	scroll-margin-top: 24px;
}

:focus-visible {
	outline: 2px solid var(--fl-green);
	outline-offset: 3px;
}

::selection {
	background: var(--fl-green);
	color: var(--fl-white);
}

/* Even line breaks on headings, like the design. */
.elementor-heading-title {
	text-wrap: balance;
}

/* Text Editor widgets: no stray space under the last paragraph. */
.elementor-widget-text-editor p:last-child {
	margin-bottom: 0;
}

/* Emphasis inside headings (Quote band) and licence line. */
.elementor-heading-title strong,
.fl-strong-700 strong {
	font-weight: 700;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		transition-duration: 0.01ms !important;
	}
}

/* ---------- Helper classes (Advanced > CSS Classes) ---------- */

/* fl-hero: on phones the diagonal white fade becomes a top-to-bottom fade so
   the text stays readable over the photo. */
@media (max-width: 767px) {
	.fl-hero.e-con::before {
		background-image: linear-gradient(
			180deg,
			rgba(255, 255, 255, 0.92) 0%,
			rgba(255, 255, 255, 0.7) 60%,
			rgba(255, 255, 255, 0.35) 100%
		) !important;
		opacity: 1 !important;
	}
}

/* fl-card-texture: adds the subtle paper texture over a card image. */
.fl-card-texture {
	position: relative;
}
.fl-card-texture::after {
	content: '';
	position: absolute;
	inset: 0;
	background: url('../img/card-texture.png') repeat;
	opacity: 0.2;
	mix-blend-mode: multiply;
	pointer-events: none;
}

/* fl-tabular: digits line up in price columns. */
.fl-tabular .elementor-heading-title {
	font-variant-numeric: tabular-nums;
}

/* fl-hide-empty-link: hides a button/link widget whose URL is still empty or "#". */
.fl-hide-empty-link a[href=''],
.fl-hide-empty-link a[href='#'] {
	display: none;
}

/* ---------- Contact form (Gravity Forms, "gravity-theme" framework) ---------- */

.fl-form {
	width: 100%;
	font-family: var(--fl-font-body);
}

.fl-form .gform_wrapper.gravity-theme {
	margin: 0;
}

.fl-form .gform_wrapper.gravity-theme .gform_fields {
	grid-column-gap: 16px;
	grid-row-gap: 16px;
}

.fl-form .gform_wrapper.gravity-theme .gfield_label,
.fl-form .gform_wrapper.gravity-theme .gfield_label.gform-field-label {
	margin-bottom: 4px;
	padding: 0;
	font-size: 11px;
	font-weight: 700;
	line-height: 16px;
	letter-spacing: 0.88px;
	text-transform: uppercase;
	color: var(--fl-body);
}

.fl-form .gform_wrapper.gravity-theme .gfield_required {
	color: var(--fl-green);
	font-size: 11px;
}

.fl-form .gform_wrapper.gravity-theme input[type='text'],
.fl-form .gform_wrapper.gravity-theme input[type='email'],
.fl-form .gform_wrapper.gravity-theme input[type='tel'],
.fl-form .gform_wrapper.gravity-theme select,
.fl-form .gform_wrapper.gravity-theme textarea {
	width: 100%;
	min-height: 48px;
	padding: 12px 16px;
	border: 1px solid transparent;
	border-radius: 0;
	background-color: var(--fl-white);
	font-family: inherit;
	font-size: 15px;
	line-height: 24px;
	color: var(--fl-ink);
	box-shadow: none;
	transition: border-color 160ms ease, box-shadow 160ms ease;
}

.fl-form .gform_wrapper.gravity-theme textarea {
	min-height: 104px;
	height: 104px;
	resize: vertical;
}

.fl-form .gform_wrapper.gravity-theme select {
	appearance: none;
	padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23424843' stroke-width='1.5'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 16px center;
}

.fl-form .gform_wrapper.gravity-theme ::placeholder {
	color: var(--fl-muted);
	opacity: 1;
}

.fl-form .gform_wrapper.gravity-theme input:focus,
.fl-form .gform_wrapper.gravity-theme select:focus,
.fl-form .gform_wrapper.gravity-theme textarea:focus {
	outline: none;
	border-color: var(--fl-green);
	box-shadow: 0 0 0 2px rgba(58, 104, 76, 0.25);
}

/* Consent checkbox: green bar from the design. */
.fl-form .gform_wrapper.gravity-theme .gfield--type-consent .ginput_container_consent {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 10px 20px;
	background: var(--fl-green);
	color: var(--fl-white);
}
.fl-form .gform_wrapper.gravity-theme .gfield--type-consent label {
	margin: 0;
	font-size: 13px;
	line-height: 20px;
	color: var(--fl-white);
	cursor: pointer;
}
.fl-form .gform_wrapper.gravity-theme .gfield--type-consent input[type='checkbox'] {
	flex: none;
	width: 14px;
	height: 14px;
	margin: 0;
	accent-color: var(--fl-ink);
}
.fl-form .gform_wrapper.gravity-theme .gfield--type-consent .gfield_required {
	color: var(--fl-white);
}

/* Submit button: matches the "ink" button style. */
.fl-form .gform_wrapper.gravity-theme .gform_footer {
	margin: 0;
	padding: 16px 0 0;
}
.fl-form .gform_wrapper.gravity-theme .gform_footer input[type='submit'],
.fl-form .gform_wrapper.gravity-theme .gform_footer button,
.fl-form .gform_wrapper.gravity-theme .gform_button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	margin: 0;
	padding: 14px 32px 14px 52px;
	border: 0;
	border-radius: 0;
	background-color: var(--fl-ink);
	/* Paper-plane icon from the design. */
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='15' height='12' viewBox='0 0 14.25 12'%3E%3Cpath d='M0 12V0l14.25 6zm1.5-2.25L10.39 6 1.5 2.25v2.63L6 6l-4.5 1.13z' fill='white'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: 30px center;
	font-family: inherit;
	font-size: 13px;
	font-weight: 600;
	line-height: 18px;
	letter-spacing: 0.26px;
	color: var(--fl-white);
	cursor: pointer;
	transition: background-color 160ms ease;
}
.fl-form .gform_wrapper.gravity-theme .gform_footer input[type='submit']:hover,
.fl-form .gform_wrapper.gravity-theme .gform_button:hover {
	background-color: var(--fl-green);
}

/* Validation and confirmation */
.fl-form .gform_wrapper.gravity-theme .gfield_error input,
.fl-form .gform_wrapper.gravity-theme .gfield_error select,
.fl-form .gform_wrapper.gravity-theme .gfield_error textarea {
	border-color: #c02b0a;
}
.fl-form .gform_confirmation_message {
	padding: 20px;
	background: var(--fl-white);
	font-size: 15px;
	line-height: 24px;
	color: var(--fl-ink);
}

/* Fallback shown until Gravity Forms is active. */
.fl-form--fallback {
	padding: 20px;
	background: var(--fl-white);
	font-size: 15px;
	line-height: 24px;
	color: var(--fl-ink);
}
.fl-form--fallback a {
	color: var(--fl-green);
	font-weight: 600;
}
.fl-form__admin-note {
	margin-top: 8px;
	font-size: 13px;
	color: var(--fl-muted);
}
