/* ------------------------------------------------------------------ */
/* Gravity Form (form 1) — "Clean card" restyle, Aug 2026.              */
/*                                                                      */
/* Single source of truth for the quote/contact form everywhere it     */
/* renders: sidebar (#main .qcf-form, also the homepage #estimate      */
/* target), CTA bands on city/areas-hub/service/rebate-hub/commercial/ */
/* FAQ/FAQ-hub pages (#main .vl-cta-form), and the reviews page         */
/* (#main .vlr-cta-form). Markup is Gravity Forms LEGACY (data-form-    */
/* theme='legacy', gform-theme--no-framework) — fully theme-styled,     */
/* nothing here relies on GF's newer Orbital framework CSS.             */
/*                                                                      */
/* Enqueued sitewide, after phx-responsive (functions.php child_setup). */
/* Every rule is scoped under #main so it beats the phx `#main <el>`    */
/* specificity-101 rules (see style.css `#main article{...}`) and any   */
/* bare-class legacy selector still left in style.css/responsive.css/   */
/* city-landing.css/reviews.css.                                        */
/*                                                                      */
/* Copy changes (section title, submit button text, the mislabeled      */
/* field_1_6 "CAPTCHA" -> "What can we help with?") are applied via     */
/* PHP filters in functions.php, NOT here — this file only styles the   */
/* markup GF (and those filters) actually output.                       */
/* ------------------------------------------------------------------ */

/* ============================================================ */
/* 1. Card shell                                                 */
/* ============================================================ */
#main .gform_wrapper {
  background: #fff;
  border-radius: 14px;
  padding: 28px;
  box-shadow: 0 10px 30px rgba(20, 40, 20, .10);
  border: 1px solid #e6eae2;
  color: #1e241d;
  box-sizing: border-box;
  max-width: 100%;
}
#main .gform_wrapper * {
  box-sizing: border-box;
}

/* Sidebar (.qcf-form): same card, forced single column, tighter padding. */
#main .qcf-form .gform_wrapper {
  padding: 20px;
}

/* ============================================================ */
/* 2. Section title -> "Get a Free Quote" heading + lead          */
/* (markup injected by gform_field_content_1 in functions.php)   */
/* ============================================================ */
#main .gform_wrapper .vl-form-title {
  margin: 0 0 4px;
  font-size: 22px;
  line-height: 1.25;
  font-weight: 700;
  color: #006326;
  font-family: inherit;
}
#main .gform_wrapper .vl-form-lead {
  margin: 0 0 18px;
  font-size: 14px;
  color: #5f6b5a;
}

/* Defensive: Gravity Forms' own honeypot field (an extra decoy field, e.g.
   "Email"/"Instagram"/"X/Twitter" — GF rotates the fake label per render)
   is supposed to be hidden by GF's own plugin CSS/JS. Belt-and-suspenders
   theme-owned guarantee it never renders visibly regardless — off-screen,
   not display:none, so it stays in the DOM/tab order for the bots it's
   meant to catch. Purely cosmetic; does not touch spam-protection logic. */
#main .gform_wrapper .gfield--type-honeypot {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  margin: 0 !important;
}

/* ============================================================ */
/* 3. Field list layout                                          */
/* ============================================================ */
#main .gform_wrapper .gform_body,
#main .gform_wrapper .gform-body {
  display: block;
}
#main .gform_wrapper ul.gform_fields {
  display: block;
  margin: 0;
  padding: 0;
  list-style: none;
}
#main .gform_wrapper .gfield {
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
}
#main .gform_wrapper .gfield:last-child {
  margin-bottom: 0;
}

/* Name first/last: single column below 640px, two columns at/above it. */
#main .gform_wrapper .ginput_complex.ginput_container--name {
  display: block;
  margin: 0;
}
#main .gform_wrapper .ginput_complex.ginput_container--name > span {
  display: block;
  width: auto;
  margin: 0 0 12px;
}
#main .gform_wrapper .ginput_complex.ginput_container--name > span:last-child {
  margin-bottom: 0;
}

@media (min-width: 640px) {
  /* Phone + Email become a two-column row via grid auto-placement:
     every field spans the full row except phone/email, which each take
     one column and land side by side (they're adjacent in field order). */
  #main .gform_wrapper ul.gform_fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  #main .gform_wrapper .gfield {
    grid-column: 1 / -1;
    margin-bottom: 0;
  }
  #main .gform_wrapper #field_1_2,
  #main .gform_wrapper #field_1_3 {
    grid-column: span 1;
  }

  #main .gform_wrapper .ginput_complex.ginput_container--name {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  #main .gform_wrapper .ginput_complex.ginput_container--name > span {
    margin-bottom: 0;
  }
}

/* Sidebar override: always single column, regardless of viewport width —
   #main .qcf-form .gform_wrapper ... out-specifies the ≥640px rules above
   (extra .qcf-form class), so no !important / media-query duplication
   needed. Matters on tablet widths, where the sidebar reflows to a full-
   width single stacked column (responsive.css §11) that would otherwise
   be wide enough to trigger the two-column layout. */
#main .qcf-form .gform_wrapper ul.gform_fields {
  display: block;
}
#main .qcf-form .gform_wrapper .gfield {
  grid-column: auto;
}
#main .qcf-form .gform_wrapper .ginput_complex.ginput_container--name {
  display: block;
}
#main .qcf-form .gform_wrapper .ginput_complex.ginput_container--name > span {
  margin: 0 0 12px;
}
#main .qcf-form .gform_wrapper .ginput_complex.ginput_container--name > span:last-child {
  margin-bottom: 0;
}

/* ============================================================ */
/* 4. Labels                                                     */
/* ============================================================ */
#main .gform_wrapper .gfield_label,
#main .gform_wrapper .gform-field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #33413a;
  margin: 0 0 6px;
}
#main .gform_wrapper .gfield_required_asterisk {
  color: #bb4e1a;
  margin-left: 2px;
}

/* Un-hide the visually-hidden labels on Phone / Email / Property Address /
   Details (field_1_6) so the "Clean card" shows real labels above each
   input, matching the approved mockup, instead of relying on placeholder
   text alone. This overrides Gravity Forms core's visually-hidden-label
   CSS (position/clip/size reset) for just these four fields — the Name
   field's own group label (also hidden_label) and the reCAPTCHA field are
   deliberately left alone: the mockup doesn't show a "Name" group label
   (only the already-visible First/Last sub-labels) or a captcha label.
   !important is required here to beat Gravity Forms' own plugin CSS. */
#main .gform_wrapper #field_1_2.hidden_label .gfield_label,
#main .gform_wrapper #field_1_3.hidden_label .gfield_label,
#main .gform_wrapper #field_1_4.hidden_label .gfield_label,
#main .gform_wrapper #field_1_6.hidden_label .gfield_label {
  position: static !important;
  width: auto !important;
  height: auto !important;
  overflow: visible !important;
  clip: auto !important;
  clip-path: none !important;
  white-space: normal !important;
  margin: 0 0 6px !important;
  padding: 0 !important;
  border: 0 !important;
  display: block !important;
}

/* The reverse: explicitly keep the Name field's own group label ("Name *")
   and the reCAPTCHA field's label ("CAPTCHA") visually hidden. Gravity
   Forms core is expected to already hide any `hidden_label` field via its
   own plugin CSS, but that depends on a stylesheet this theme doesn't
   control loading correctly in every context — this is a defensive,
   theme-owned guarantee that these two specific labels never render,
   regardless. Does not touch the reCAPTCHA widget itself (#input_1_5). */
#main .gform_wrapper #field_1_8 > .gfield_label,
#main .gform_wrapper #field_1_5 .gfield_label {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ============================================================ */
/* 5. Inputs / textarea                                          */
/* ============================================================ */
#main .gform_wrapper input[type=text],
#main .gform_wrapper input[type=email],
#main .gform_wrapper input[type=tel],
#main .gform_wrapper input[type=url],
#main .gform_wrapper input[type=number],
#main .gform_wrapper textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  border: 1.5px solid #d8ddd3;
  border-radius: 10px;
  padding: 10px 14px;
  font: inherit;
  font-size: 16px; /* >=16px stops iOS zoom-on-focus */
  background: #fbfcfa;
  color: #1e241d;
  -webkit-appearance: none;
  appearance: none;
}
#main .gform_wrapper textarea {
  min-height: 96px;
  resize: vertical;
}
#main .gform_wrapper input[type=text]:focus,
#main .gform_wrapper input[type=email]:focus,
#main .gform_wrapper input[type=tel]:focus,
#main .gform_wrapper input[type=url]:focus,
#main .gform_wrapper input[type=number]:focus,
#main .gform_wrapper textarea:focus {
  outline: none;
  border-color: #006326;
  box-shadow: 0 0 0 4px rgba(0, 99, 38, .12);
  background: #fff;
}
#main .gform_wrapper input::placeholder,
#main .gform_wrapper textarea::placeholder {
  color: #93a08c;
}

/* ============================================================ */
/* 6. "I'm a" New/Returning client — segmented pill toggle        */
/* Legacy markup order is input -> label (confirmed against the  */
/* live fragment), so :checked + label works directly.           */
/* ============================================================ */
#main .gform_wrapper .ginput_container_radio ul.gfield_radio {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  background: #eef2ea;
  border-radius: 999px;
  padding: 4px;
  margin: 0;
  list-style: none;
  width: max-content;
  max-width: 100%;
}
#main .gform_wrapper .ginput_container_radio ul.gfield_radio li.gchoice {
  margin: 0;
  padding: 0;
  list-style: none;
}
#main .gform_wrapper .ginput_container_radio input[type=radio] {
  /* Visually hidden, but still focusable and in the tab order. */
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
#main .gform_wrapper .ginput_container_radio input[type=radio] + label.gform-field-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  color: #33413a;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  flex: 1 1 auto;
  transition: background .15s ease, color .15s ease;
}
/* reCAPTCHA v2 checkbox: Gravity Forms' legacy CSS boxes .ginput_recaptcha at
   277px with overflow:hidden, but Google's widget is 304px wide -> the right
   edge (logo) was clipped. Let the container size to the widget. */
#main .gform_wrapper .gfield--type-captcha {
  margin: 4px 0 14px;
}
#main .gform_wrapper .ginput_container.ginput_recaptcha {
  width: auto !important;
  max-width: 100% !important;
  overflow: visible !important;
}
/* Very narrow columns (<340px content): scale the fixed-size widget down. */
@media (max-width: 359px) {
  #main .gform_wrapper .ginput_container.ginput_recaptcha > div {
    transform: scale(.88);
    transform-origin: 0 0;
  }
}
#main .gform_wrapper .ginput_container_radio input[type=radio]:checked + label.gform-field-label {
  background: #006326;
  color: #fff;
}
#main .gform_wrapper .ginput_container_radio input[type=radio]:focus-visible + label.gform-field-label {
  outline: 2px solid #006326;
  outline-offset: 2px;
}

/* ============================================================ */
/* 7. Validation states                                          */
/* ============================================================ */
#main .gform_wrapper .validation_error {
  background: #fff6f0;
  border: 1px solid #f0d3b8;
  color: #8a3e12;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 16px;
}
#main .gform_wrapper .gfield_error {
  margin-bottom: 12px;
}
#main .gform_wrapper .gfield_error input[type=text],
#main .gform_wrapper .gfield_error input[type=email],
#main .gform_wrapper .gfield_error input[type=tel],
#main .gform_wrapper .gfield_error textarea {
  border-color: #bb4e1a;
  background: #fff8f4;
}
#main .gform_wrapper .gfield_error input[type=text]:focus,
#main .gform_wrapper .gfield_error input[type=email]:focus,
#main .gform_wrapper .gfield_error input[type=tel]:focus,
#main .gform_wrapper .gfield_error textarea:focus {
  box-shadow: 0 0 0 4px rgba(187, 78, 26, .14);
}
#main .gform_wrapper .validation_message {
  color: #bb4e1a;
  font-size: 12.5px;
  font-weight: 600;
  margin: 4px 0 0;
}

/* ============================================================ */
/* 8. Confirmation (success) message                             */
/* GF's ajax response keeps the same #gform_wrapper_N / .gform_wrapper */
/* card and swaps the inner content for the confirmation markup, so   */
/* the white card shell above still applies; this styles the message  */
/* itself as a green success panel inside it.                         */
/* ============================================================ */
#main .gform_wrapper .gform_confirmation_message {
  background: #eef7ee;
  border: 1px solid #bfe3c0;
  color: #0b3d1f;
  border-radius: 10px;
  padding: 16px 18px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
}

/* ============================================================ */
/* 9. Footer / submit button                                     */
/* ============================================================ */
#main .gform_wrapper .gform_footer,
#main .gform_wrapper .gform-footer {
  margin: 6px 0 0;
  padding: 0;
  text-align: left;
}
#main .gform_wrapper .gform_footer input[type=submit],
#main .gform_wrapper .gform_footer button,
#main .gform_wrapper input.gform_button {
  display: block;
  width: 100%;
  margin: 0;
  background: #bb4e1a;
  color: #fff;
  border: 0;
  border-radius: 999px;
  padding: 15px 24px;
  font-family: inherit;
  font-size: 17px;
  font-weight: 700;
  line-height: 24px;
  cursor: pointer;
  transition: background .18s ease, transform .12s ease;
}
#main .gform_wrapper .gform_footer input[type=submit]:hover,
#main .gform_wrapper input.gform_button:hover {
  background: #9a3d0f;
}
#main .gform_wrapper .gform_footer input[type=submit]:active,
#main .gform_wrapper input.gform_button:active {
  transform: translateY(1px);
}
#main .gform_wrapper .gform_footer input[type=submit]:focus-visible,
#main .gform_wrapper input.gform_button:focus-visible {
  outline: 3px solid rgba(0, 99, 38, .4);
  outline-offset: 2px;
}

/* Fine print, appended after the footer (button + hidden fields render
   nothing visible, so this reads directly under the button). Only shows
   while the <form> (and its .gform_footer) is present — correctly absent
   on the confirmation/success state. Escaped unicode so the source file
   stays plain-ASCII-safe regardless of editor/encoding. */
#main .gform_wrapper .gform_footer::after {
  content: "Protected by reCAPTCHA \00B7 Licensed & insured \00B7 ROC #207713";
  display: block;
  margin-top: 10px;
  font-size: 12px;
  color: #7a8676;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  #main .gform_wrapper .gform_footer input[type=submit],
  #main .gform_wrapper input.gform_button,
  #main .gform_wrapper .ginput_container_radio input[type=radio] + label.gform-field-label {
    transition: none;
  }
  #main .gform_wrapper .gform_footer input[type=submit]:active,
  #main .gform_wrapper input.gform_button:active {
    transform: none;
  }
}
