/* Fernlea themes: shared foundations. Each design's look lives in theme.css. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body { margin: 0; background: var(--ft-bg); color: var(--ft-text); font-family: var(--ft-body); font-size: 16px; line-height: 1.7; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }
ul[class], ol[class] { list-style: none; padding: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
em { font-style: italic; }

/* Corners: one setting for every button, photo, box and form field. Each design sets its own default. */
:root { --ft-radius: 4px; --ft-btn-radius: 4px; }
.ft-corners-square { --ft-radius: 0; --ft-btn-radius: 0; }
.ft-corners-soft { --ft-radius: 4px; --ft-btn-radius: 4px; }
.ft-corners-rounded { --ft-radius: 14px; --ft-btn-radius: 10px; }
.ft-corners-round { --ft-radius: 24px; --ft-btn-radius: 999px; }

.ft-container { width: min(100% - 2 * var(--ft-gutter, 24px), var(--ft-max, 1280px)); margin-inline: auto; }
.ft-narrow { max-width: 820px; margin-inline: auto; }
.ft-center { text-align: center; }

.screen-reader-text { border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important; width: 1px; word-wrap: normal !important; }
.ft-skip { position: absolute; left: 16px; top: -100px; z-index: 1000; background: var(--ft-text); color: var(--ft-bg); padding: 10px 16px; border-radius: var(--ft-btn-radius); text-decoration: none; }
.ft-skip:focus { top: 16px; }
:focus-visible { outline: 2px solid var(--ft-accent); outline-offset: 3px; }

.ft-icon { width: 1.1em; height: 1.1em; flex: none; }
.ft-stars { display: inline-flex; gap: 3px; color: var(--ft-accent); }
.ft-stars .ft-icon { width: 16px; height: 16px; }

/* Buttons (designs restyle) */
.ft-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 14px 28px; border-radius: var(--ft-btn-radius); border: 1px solid transparent; text-decoration: none; cursor: pointer; line-height: 1.2; transition: background-color .2s, color .2s, border-color .2s, opacity .2s; text-align: center; }
.ft-btn--primary { background: var(--ft-primary); color: var(--ft-on-primary); }
.ft-btn--primary:hover { opacity: .88; }
.ft-btn--outline { border-color: currentColor; background: transparent; }
.ft-btn--outline:hover { background: var(--ft-text); color: var(--ft-bg); border-color: var(--ft-text); }
.ft-btn--light { background: var(--ft-bg); color: var(--ft-text); }
.ft-btn--light:hover { opacity: .9; }
.ft-btn--outline-light { border-color: currentColor; color: #fff; background: transparent; }
.ft-btn--outline-light:hover { background: #fff; color: var(--ft-text); border-color: #fff; }
.ft-buttons { display: flex; flex-wrap: wrap; gap: 14px; }
.ft-buttons--center { justify-content: center; }
.ft-link { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 4px; }

/* Header mechanics */
.ft-header { position: relative; z-index: 50; }
.ft-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.ft-logo { text-decoration: none; display: inline-flex; align-items: center; }
.ft-logo__img { max-height: 56px; width: auto; }
.ft-nav__list { display: flex; gap: 36px; align-items: center; }
.ft-nav__list a { text-decoration: none; }
.ft-menu-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: inherit; }
.ft-menu-toggle .ft-icon { width: 26px; height: 26px; }
.ft-menu-toggle__close { display: none; }
.ft-menu-toggle[aria-expanded="true"] .ft-menu-toggle__open { display: none; }
.ft-menu-toggle[aria-expanded="true"] .ft-menu-toggle__close { display: inline; }

@media (max-width: 960px) {
	.ft-menu-toggle { display: inline-flex; position: relative; z-index: 60; }
	.ft-nav { position: fixed; inset: 0; z-index: 55; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 32px; padding: 96px 24px 48px; background: var(--ft-bg); color: var(--ft-text); opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s; }
	.ft-nav.is-open { opacity: 1; visibility: visible; }
	.ft-nav .ft-nav__list { flex-direction: column; gap: 22px; text-align: center; }
	.ft-nav .ft-nav__list a { font-size: 22px; }
	.ft-menu-open { overflow: hidden; }
	.ft-menu-open .ft-header .ft-menu-toggle, .ft-menu-open .ft-header .ft-logo { color: var(--ft-text); position: relative; z-index: 60; }
}

/* Placeholders keep image spaces in shape */
.ft-ph { position: relative; width: 100%; height: 100%; min-height: 160px; background: var(--ft-surface-2); display: flex; align-items: center; justify-content: center; }
.ft-ph__label { display: none; align-items: center; gap: 8px; font-family: var(--ft-body); font-size: 13px; letter-spacing: .02em; color: var(--ft-text); background: color-mix(in srgb, var(--ft-bg) 88%, transparent); padding: 8px 14px; border-radius: var(--ft-btn-radius); text-transform: none; font-style: normal; font-weight: 500; }
.ft-editor-view .ft-ph { outline: 1.5px dashed color-mix(in srgb, var(--ft-text) 35%, transparent); outline-offset: -10px; }
.ft-editor-view .ft-ph__label { display: inline-flex; }
.ft-bg-label { position: absolute; top: 120px; left: 50%; transform: translateX(-50%); z-index: 3; }
.ft-editor-view .ft-bg-label { display: inline-flex; }

/* Image wrappers fill their box */
.ft-fill { position: relative; overflow: hidden; border-radius: var(--ft-radius); }
.ft-fill > img, .ft-fill > .ft-ph { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* Background image sections */
.ft-bgsec { position: relative; isolation: isolate; background: var(--ft-dark); color: var(--ft-on-dark); }
.ft-bgsec--image { background-image: var(--ft-bg-image); background-size: cover; background-position: center; color: #fff; }
.ft-bgsec--image::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(20, 16, 14, var(--ft-ov-top, .3)), rgba(20, 16, 14, var(--ft-ov-bottom, .55))); }

/* Forms */
.ft-form { display: grid; gap: 18px; }
.ft-form__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.ft-field { display: grid; gap: 8px; margin: 0; }
.ft-field label { font-size: 13px; font-weight: 500; }
.ft-field input, .ft-field textarea, .ft-field select { width: 100%; min-height: 52px; padding: 14px 16px; border: 1px solid var(--ft-line); border-radius: var(--ft-radius); background: var(--ft-bg); color: var(--ft-text); font-size: 15px; }
.ft-field textarea { min-height: 140px; resize: vertical; }
.ft-field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 44px; }
.ft-field input::placeholder, .ft-field textarea::placeholder { color: var(--ft-muted); opacity: .8; }
.ft-field input:focus, .ft-field textarea:focus, .ft-field select:focus { outline: 2px solid var(--ft-accent); outline-offset: 1px; border-color: transparent; }
.ft-consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.55; }
.ft-consent input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--ft-primary); flex: none; }
.ft-form .ft-btn { justify-self: start; }
.ft-notice { padding: 14px 18px; border-radius: var(--ft-radius); margin-bottom: 20px; font-size: 15px; }
.ft-notice--success { background: color-mix(in srgb, #3e7a52 14%, var(--ft-bg)); }
.ft-notice--error { background: color-mix(in srgb, #b3452f 14%, var(--ft-bg)); }

/* FAQ accordion mechanics */
.ft-faq__item summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 24px; align-items: center; }
.ft-faq__item summary::-webkit-details-marker { display: none; }
.ft-faq__icon { flex: none; display: inline-flex; transition: transform .25s; }
.ft-faq__item[open] .ft-faq__icon { transform: rotate(45deg); }

/* Slider mechanics */
.ft-slider__track { display: grid; }
.ft-quote { grid-area: 1 / 1; opacity: 0; visibility: hidden; transition: opacity .5s, visibility .5s; }
.ft-quote.is-active { opacity: 1; visibility: visible; }
.ft-slider__controls { display: flex; align-items: center; gap: 18px; margin-top: 36px; }
.ft-slider__arrow { background: none; border: 1px solid currentColor; border-radius: var(--ft-btn-radius); width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: inherit; opacity: .8; }
.ft-slider__arrow:hover { opacity: 1; }
.ft-slider__dots { display: flex; gap: 8px; align-items: center; }
.ft-slider__dot { width: 8px; height: 3px; border: 0; padding: 0; background: currentColor; opacity: .35; cursor: pointer; transition: width .3s, opacity .3s; }
.ft-slider__dot.is-active { width: 28px; opacity: 1; }

/* Generic text pages */
.ft-prose { font-size: 17px; }
.ft-prose > * + * { margin-top: 1.1em; }
.ft-prose h2, .ft-prose h3 { font-family: var(--ft-head); font-weight: 400; line-height: 1.2; margin-top: 1.6em; }
.ft-prose h2 { font-size: 30px; }
.ft-prose h3 { font-size: 23px; }
.ft-prose a { color: var(--ft-accent); }
.ft-prose ul, .ft-prose ol { padding-left: 1.3em; }
.ft-prose img { border-radius: var(--ft-radius); }

/* Lists of lines */
.ft-lines { display: grid; }

/* Privacy policy and terms */
.fl-legal { max-width: 760px; }
.fl-legal h2 { font-family: var(--ft-head); font-size: clamp(22px, 2.2vw, 28px); line-height: 1.25; margin: 2.2em 0 .6em; font-weight: 500; }
.fl-legal p, .fl-legal ul { margin: 0 0 1em; }
.fl-legal ul { padding-left: 1.2em; list-style: disc; }
.fl-legal li { margin-bottom: .5em; }
.fl-legal a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.fl-legal__updated { font-size: 13px; color: var(--ft-muted); }
.fl-legal__table { overflow-x: auto; margin: 1.4em 0; border: 1px solid var(--ft-line); border-radius: var(--ft-radius); }
.fl-legal table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 560px; }
.fl-legal th, .fl-legal td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--ft-line); vertical-align: top; }
.fl-legal th { font-weight: 600; background: var(--ft-surface); }
.fl-legal tr:last-child td { border-bottom: 0; }
.fl-legal code { font-size: 13px; background: none; padding: 0; }
.fl-legal td:nth-child(4), .fl-legal td:first-child { white-space: nowrap; }
.ft-legal-links a { white-space: nowrap; }
