/* Native Divi presets own page layout, typography, input decoration and primary
   button design. These scoped exceptions cover unavailable per-choice card,
   HTML-field heading, independent Back-button, and focus controls. Values read
   the same editable Apex Divi Variables; no !important overrides. */
.apex-form .gfield_html h1,.apex-form .gfield_html h2{font-family:var(--apex-heading-font),sans-serif;font-size:var(--apex-question-size);font-weight:var(--apex-heading-weight);line-height:var(--apex-heading-line);color:var(--apex-ink);text-align:center;margin:0 0 var(--apex-module-gap)}
.apex-form .apex-question-help{text-align:center;color:var(--apex-muted);font-size:var(--apex-body-size);line-height:var(--apex-body-line);margin:0 0 var(--apex-module-gap)}
.apex-form .gfield.apex-choice .gfield_radio{display:grid;grid-template-columns:1fr;gap:var(--apex-card-gap)}
.apex-form .gfield.apex-property .gfield_radio{grid-template-columns:repeat(2,minmax(0,1fr))}
.apex-form .gfield.apex-choice.apex-property .gchoice{align-items:stretch}
.apex-form .gfield.apex-choice .gchoice{position:relative;display:flex;align-items:center;min-height:var(--apex-control-height);border:var(--apex-border-width) solid var(--apex-border);border-radius:var(--apex-radius);background:var(--apex-white);transition:border-color .15s ease,box-shadow .15s ease}
/* Native radios remain focusable; the complete label is the visible choice. */
.apex-form .gfield.apex-choice .gchoice input[type=radio]{position:absolute;width:1px;height:1px;left:0;top:0;margin:-1px;padding:0;border:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.apex-form .gfield.apex-choice .gchoice label{display:block;flex:1;max-width:none;min-height:var(--apex-control-height);margin:0;padding:var(--apex-card-padding) var(--apex-control-padding);text-align:center;font-family:var(--apex-body-font),sans-serif;font-size:var(--apex-body-size);font-weight:700;line-height:1.4;color:var(--apex-ink);cursor:pointer}
/* Property-choice labels use native editable choice HTML. The form module has
   no separate title/subtext/icon controls inside an individual radio choice.
   Decorative original SVGs keep the native radio names and values unchanged.
   Clip these radios visually while preserving keyboard and screen-reader use. */
.apex-form .gfield.apex-choice.apex-property .gchoice label{margin:0;padding:var(--apex-control-padding);text-align:center}
.apex-form .gfield.apex-choice.apex-property .gchoice label::before{content:"";display:block;width:24px;height:24px;margin:0 auto 8px;background-color:currentColor;mask:center/contain no-repeat var(--apex-property-icon)}
.apex-form .apex-property .gchoice:has(input[value="My Home"]){--apex-property-icon:url("property-home.svg")}
.apex-form .apex-property .gchoice:has(input[value="My Business"]){--apex-property-icon:url("property-business.svg")}
.apex-form .apex-property .apex-property-title{display:block;font-size:var(--apex-body-size);font-weight:700;line-height:1.4;color:var(--apex-ink)}
.apex-form .apex-property .apex-property-subtext{display:block;margin-top:4px;font-size:calc(var(--apex-small-size) - 1px);font-weight:400;line-height:1.45;color:var(--apex-muted)}
.apex-form .gfield.apex-choice .gchoice:hover,.apex-form .gfield.apex-choice .gchoice:has(input:checked){border-color:var(--apex-gold-dark);box-shadow:0 0 0 1px var(--apex-gold-dark)}
.apex-form .gfield.apex-choice .gchoice:focus-within{outline:3px solid var(--apex-focus);outline-offset:3px}
.apex-form input:focus-visible,.apex-form button:focus-visible,.apex-form a:focus-visible{outline:3px solid var(--apex-focus);outline-offset:3px}
#page-container .apex-form .gform_footer .gform_button,#page-container .apex-form .gform_page_footer .gform_button,#page-container .apex-form .gform_next_button{width:100%;cursor:pointer}
/* Divi Essential enforces a block footer with !important. Use native block
   flow and spacing instead of fighting that vendor rule with another override. */
.apex-form .gform_page_footer{padding-top:var(--apex-module-gap)}
#page-container .apex-form .gform_page_footer .gform_previous_button{display:block;width:auto;margin:0 0 var(--apex-module-gap)}
.apex-form .gf_progressbar_wrapper{margin-bottom:28px}
.apex-form .gf_progressbar{height:4px;border-radius:var(--apex-radius);background:var(--apex-border);overflow:hidden}
.apex-form .gf_progressbar_percentage{height:4px;background:linear-gradient(90deg,var(--apex-gold),var(--apex-blue))}
.apex-form .gf_progressbar_percentage span{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.apex-form .gf_progressbar_title{font-size:var(--apex-small-size);text-align:center;letter-spacing:1px;text-transform:uppercase;color:var(--apex-muted)}
.apex-form .apex-selection-summary{background:var(--apex-surface);border:1px solid var(--apex-border);border-radius:var(--apex-radius);padding:var(--apex-control-padding);font-size:var(--apex-small-size);color:var(--apex-body);line-height:var(--apex-body-line);margin-bottom:var(--apex-module-gap)}
.apex-form .apex-privacy{font-size:var(--apex-small-size);line-height:var(--apex-body-line);color:var(--apex-muted)}
.apex-form .apex-privacy a{text-decoration:underline;color:var(--apex-focus)}
.apex-waitlist .apex-privacy,.apex-estimate .apex-privacy{text-align:center}
/* The module's description controls are shared; center only phone guidance. */
.apex-form .gfield--type-phone .gfield_description{text-align:center}
.apex-form .gform_confirmation_message{padding:var(--apex-card-padding);border:2px solid var(--apex-success);border-radius:var(--apex-radius);color:var(--apex-ink);background:var(--apex-surface);line-height:var(--apex-body-line)}
/* The module shares label alignment across field types. Size checkbox labels
   to their text so centered type cannot create an empty gap in a wide cell. */
#page-container .apex-form .gfield_checkbox .gchoice{width:fit-content;max-width:100%;margin-inline:auto}
#page-container .apex-form .gfield_checkbox label{width:fit-content;justify-self:start;margin-left:calc(var(--apex-control-padding) / 2);line-height:1.5}
@media(max-width:580px){.apex-form .gfield.apex-property .gfield_radio{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){.apex-form .gfield.apex-choice .gchoice{transition:none}}
