/* LFCU forms: Gravity Forms drawn like the Next.js FormRenderer (labelled inputs, pill choices, the orange pill
   button, inline errors). Gravity Forms' own CSS is off (includes/modules/forms.php), so everything it needs is here.
   Scoped to .lfcu-gf_wrapper (the forms seeded from the Next.js build carry the lfcu-gf class). */

:root .lfcu-form { max-width: 760px; }
:root .lfcu-form__title { margin: 0 0 8px; font-size: 28px; font-weight: 700; }
@media (max-width: 720px) { :root .lfcu-form__title { font-size: 24px; } }
:root .lfcu-form__intro { max-width: 60ch; margin: 0 0 20px; font-size: 17px; line-height: 1.55; color: var(--lfcu-muted); }
:root .lfcu-form__title + .lfcu-form__card { margin-top: 20px; }
:root .lfcu-form__card { padding: 28px; background: #fff; border: 1px solid var(--lfcu-line); border-radius: var(--lfcu-radius-tile); box-shadow: var(--lfcu-shadow-tile); }
@media (max-width: 720px) { :root .lfcu-form__card { padding: 20px; } }
:root .lfcu-form--closed { max-width: 72ch; padding: 20px 24px; background: var(--lfcu-sky); border-radius: var(--lfcu-radius-card-lg); }
:root .lfcu-form--closed .lfcu-form__title { font-size: 22px; }
:root .lfcu-form__closed-text p { margin: 0; font-size: 17px; line-height: 1.55; color: var(--lfcu-ink); }
:root .lfcu-form__missing { padding: 16px; background: var(--lfcu-sky); border-radius: 8px; }

/* What Gravity Forms' own CSS would hide. */
:root .lfcu-gf_wrapper .gform_validation_container,
:root .lfcu-gf_wrapper .gfield_visibility_hidden,
:root .lfcu-gf_wrapper .gform_hidden,
:root .lfcu-gf_wrapper input[type="hidden"],
:root .lfcu-gf_wrapper .gform_required_legend,
:root .lfcu-gf_wrapper .gfield_required,
:root .lfcu-gf_wrapper .ginput_counter,
:root .lfcu-gf_wrapper .gform_ajax_spinner,
:root .lfcu-gf_wrapper .gform_heading:empty { display: none !important; }
:root .lfcu-gf_wrapper .hidden_label > .gfield_label,
:root .lfcu-gf_wrapper .screen-reader-text,
:root .lfcu-gf_wrapper .gform_heading { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; white-space: nowrap; }
:root .lfcu-gf_wrapper .gform_heading { position: static !important; }

/* Layout: two columns from 640px; half-width fields side by side. */
:root .lfcu-gf_wrapper form { margin: 0; }
:root .lfcu-gf_wrapper .gform_fields { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; margin: 0; padding: 0; }
@media (min-width: 640px) {
  :root .lfcu-gf_wrapper .gform_fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  :root .lfcu-gf_wrapper .gfield { grid-column: 1 / -1; }
  :root .lfcu-gf_wrapper .gfield--width-half { grid-column: span 1; }
}
:root .lfcu-gf_wrapper .gfield { display: grid; align-content: start; gap: 8px; min-width: 0; margin: 0; padding: 0; border: 0; }
:root .lfcu-gf_wrapper fieldset.gfield { min-inline-size: 0; }

/* Labels, hints, errors. */
:root .lfcu-gf_wrapper .gfield_label { display: block; margin: 0; padding: 0; font-size: 15px; font-weight: 600; color: var(--lfcu-ink); line-height: 1.35; }
:root .lfcu-gf_wrapper legend.gfield_label { margin-bottom: 8px; }
:root .lfcu-gf_wrapper .lfcu-form__optional { font-weight: 400; color: var(--lfcu-muted); }
:root .lfcu-gf_wrapper .gfield_description { margin: 0; padding: 0; font-size: 13.5px; line-height: 1.45; color: var(--lfcu-muted); }
:root .lfcu-gf_wrapper .gfield_description.validation_message,
:root .lfcu-gf_wrapper .gfield_validation_message { margin: 0; padding: 0; background: none; border: 0; font-size: 14px; font-weight: 500; color: var(--lfcu-alert); }
:root .lfcu-gf_wrapper .gform_validation_errors { margin: 0 0 20px; padding: 12px 16px; background: #fdf0ef; border-left: 4px solid var(--lfcu-alert); border-radius: 8px; }
:root .lfcu-gf_wrapper .gform_validation_errors h2, :root .lfcu-gf_wrapper .gform_submission_error { margin: 0; font-size: 15px; font-weight: 600; color: var(--lfcu-alert); line-height: 1.45; }
:root .lfcu-gf_wrapper .gform_validation_errors h2 .gform-icon { display: none; }
:root .lfcu-gf_wrapper .gform_validation_errors ol { margin: 6px 0 0; padding-left: 20px; font-size: 14px; }
:root .lfcu-gf_wrapper .gform_validation_errors a { color: var(--lfcu-alert); }

/* Inputs. */
:root .lfcu-gf_wrapper .ginput_container input:not([type="radio"]):not([type="checkbox"]):not([type="hidden"]),
:root .lfcu-gf_wrapper .ginput_container select,
:root .lfcu-gf_wrapper .ginput_container textarea { display: block; box-sizing: border-box; width: 100%; min-height: 50px; margin: 0; padding: 0 16px; background: #fff; border: 2px solid var(--lfcu-line); border-radius: var(--lfcu-radius-card); font: 400 16px/1.4 var(--lfcu-font); color: var(--lfcu-ink); box-shadow: none; transition: border-color .15s; }
:root .lfcu-gf_wrapper .ginput_container textarea { min-height: 140px; padding: 12px 16px; resize: vertical; }
:root .lfcu-gf_wrapper .ginput_container select { padding-right: 44px; cursor: pointer; appearance: none; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230c4e97' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center / 18px; }
:root .lfcu-gf_wrapper .ginput_container :is(input, select, textarea):hover { border-color: #b7c3d4; }
:root .lfcu-gf_wrapper .ginput_container :is(input, select, textarea):focus { border-color: var(--lfcu-blue); }
:root .lfcu-gf_wrapper .ginput_container :is(input, select, textarea)[aria-invalid="true"] { border-color: var(--lfcu-alert); }
:root .lfcu-gf_wrapper .ginput_container ::placeholder { color: #6b7686; }
:root .lfcu-gf_wrapper .ginput_container_date input { max-width: 260px; }

/* Radio choices as pills (native radios, so arrow keys and screen readers work). */
:root .lfcu-gf_wrapper .gfield_radio { display: flex; flex-wrap: wrap; gap: 8px; }
:root .lfcu-gf_wrapper .gfield_radio .gchoice { position: relative; display: flex; }
:root .lfcu-gf_wrapper .gfield_radio input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
:root .lfcu-gf_wrapper .gfield_radio label { display: grid; place-items: center; min-height: 44px; margin: 0; padding: 6px 16px; border: 2px solid var(--lfcu-line); border-radius: 999px; background: #fff; font-size: 15px; font-weight: 600; line-height: 1.2; color: var(--lfcu-navy); cursor: pointer; transition: background-color .15s, border-color .15s, color .15s; }
:root .lfcu-gf_wrapper .gfield_radio .gchoice:hover label { border-color: var(--lfcu-navy); }
:root .lfcu-gf_wrapper .gfield_radio input:checked + label { background: var(--lfcu-navy); border-color: var(--lfcu-navy); color: #fff; }
:root .lfcu-gf_wrapper .gfield_radio input:focus-visible + label { outline: 3px solid var(--lfcu-gold); outline-offset: 2px; }
:root .lfcu-gf_wrapper .gfield_error .gfield_radio label { border-color: #e7b7b2; }

/* A single checkbox: the box beside its statement. */
:root .lfcu-gf_wrapper .gfield_checkbox .gchoice { display: flex; align-items: flex-start; gap: 12px; }
:root .lfcu-gf_wrapper .gfield_checkbox input { flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--lfcu-navy); cursor: pointer; }
:root .lfcu-gf_wrapper .gfield_checkbox label { margin: 0; font-size: 16px; line-height: 1.45; color: var(--lfcu-ink); cursor: pointer; }

/* Message blocks inside a form. */
:root .lfcu-gf_wrapper .lfcu-form__message, :root .lfcu-gf_wrapper .gfield--type-html { font-size: 15.5px; line-height: 1.55; color: var(--lfcu-muted); }
:root .lfcu-gf_wrapper .gfield--type-html p { margin: 0 0 .6em; }
:root .lfcu-gf_wrapper .gfield--type-html p:last-child { margin-bottom: 0; }
:root .lfcu-gf_wrapper .gfield--type-html a { color: var(--lfcu-blue-ink); }

/* Button row. */
:root .lfcu-gf_wrapper .gform_footer { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin: 20px 0 0; padding: 0; }
:root .lfcu-gf_wrapper .lfcu-form__submit { cursor: pointer; }
:root .lfcu-gf_wrapper .lfcu-form__submit[aria-disabled="true"] { opacity: .7; cursor: progress; }
:root .lfcu-gf_wrapper .lfcu-form__note { margin: 0; font-size: 13.5px; line-height: 1.45; color: var(--lfcu-muted); }
@media (max-width: 760px) { :root .lfcu-gf_wrapper .lfcu-form__submit { width: 100%; } }

/* Thank-you message: replaces the form inside the card, with a check mark. */
:root .lfcu-form__done { display: grid; justify-items: start; gap: 12px; font-size: 16.5px; line-height: 1.6; color: var(--lfcu-muted); }
:root .lfcu-form__done::before { content: ''; width: 40px; height: 40px; background: #1f7a4d; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='m9 12 2 2 4-4'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='m9 12 2 2 4-4'/%3E%3C/svg%3E") center / contain no-repeat; }
:root .lfcu-form__done .lfcu-form__done-title, :root .lfcu-form__done h3 { margin: 0; font-size: 24px; color: var(--lfcu-navy); outline: none; }
:root .lfcu-form__done p { margin: 0 0 .8em; }
:root .lfcu-form__done p:last-child { margin-bottom: 0; }
:root .lfcu-form__done a { color: var(--lfcu-blue-ink); }

/* reCAPTCHA v3's floating badge is hidden (it widened phone pages); Google's required wording sits under each form
   instead (.lfcu-form__recaptcha, added in includes/modules/forms.php), as Google's terms allow. */
:root .grecaptcha-badge { visibility: hidden !important; position: fixed !important; right: 0 !important; width: 0 !important; overflow: hidden !important; }
:root .lfcu-gf_wrapper .lfcu-form__recaptcha { flex-basis: 100%; margin: 0; font-size: 12.5px; line-height: 1.45; color: var(--lfcu-muted); }
:root .lfcu-gf_wrapper .lfcu-form__recaptcha a { color: var(--lfcu-blue-ink); }
