/*
 * HubSpot V2 Form — Brand Style Overrides
 *
 * Enqueued late in the main stylesheet queue via gcs_enqueue_hubspot_overrides()
 * in functions.php. Selectors are scoped and use !important because HubSpot
 * injects runtime styles after the page loads.
 *
 * Anchor: .gcs-hubspot-wrap — outer <div> in the consultation block template
 * that HubSpot's embed script never touches. Selectors all hang off it.
 *
 * Brand reference (matches the plain-HTML form in the source design):
 * - Font:    Inter (400/500/600/700/800)
 * - Labels:  11px / 800 / uppercase / tracking 0.12em / #001F46 (gw-deep)
 * - Inputs:  48px tall / square / 1px #cbd5e1 border / 15px #334155 text
 * - Focus:   #0099D8 border + 2px gw-blue/20 ring
 * - Button:  48px / full-width / gradient #0099D8 → #00B4F0 / uppercase / arrow ::after
 */

/* --- 1. Strip HubSpot's outer chrome — the block already provides white card --- */
.gcs-hubspot-wrap .hsfc-Form,
.gcs-hubspot-wrap .hsfc-Step,
.gcs-hubspot-wrap .hsfc-Step__Content {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    font-family: 'Inter', system-ui, sans-serif !important;
}

/* --- 2. Row spacing --- */
.gcs-hubspot-wrap .hsfc-Step__Content {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 18px 16px !important;
}
.gcs-hubspot-wrap .hsfc-Row {
    display: flex !important;
    align-items: flex-start !important;
    width: 100% !important;
    margin: 0 !important;
    gap: 16px !important;
}
.gcs-hubspot-wrap .hsfc-Row > * {
    flex: 1 1 0 !important;
    min-width: 0 !important;
}
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(3),
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(4),
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(5),
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(6) {
    width: calc(50% - 8px) !important;
}
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(1),
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(2),
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(7),
.gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(n+8) {
    width: 100% !important;
}
.gcs-hubspot-wrap .hsfc-TextField,
.gcs-hubspot-wrap .hsfc-EmailField,
.gcs-hubspot-wrap .hsfc-PhoneField,
.gcs-hubspot-wrap .hsfc-DropdownField,
.gcs-hubspot-wrap .hsfc-TextareaField {
    min-width: 0 !important;
    width: 100% !important;
}
.gcs-hubspot-wrap .hsfc-RichText,
.gcs-hubspot-wrap .hsfc-TextareaField,
.gcs-hubspot-wrap .hsfc-DataPrivacyField,
.gcs-hubspot-wrap .hsfc-ReCaptchaV2,
.gcs-hubspot-wrap .hsfc-NavigationRow,
.gcs-hubspot-wrap .hsfc-HiddenField,
.gcs-hubspot-wrap [data-hsfc-id="HiddenField"] {
    width: 100% !important;
}

/* --- 3. "Fields marked with *" rich-text subtext --- */
.gcs-hubspot-wrap .hsfc-RichText,
.gcs-hubspot-wrap .hsfc-RichText p {
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    color: #64748b !important;
    font-style: italic !important;
    margin: 0 0 4px 0 !important;
    line-height: 1.4 !important;
}

/* --- 4. Labels: 11px extra-bold uppercase tracking, gw-deep --- */
.gcs-hubspot-wrap .hsfc-FieldLabel,
.gcs-hubspot-wrap .hsfc-FieldLabel > span,
.gcs-hubspot-wrap .hsfc-FieldLabel > span > span {
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.12em !important;
    color: #001F46 !important;
    line-height: 1.4 !important;
    font-style: normal !important;
}
.gcs-hubspot-wrap .hsfc-FieldLabel {
    display: block !important;
    margin: 0 0 8px 0 !important;
}
.gcs-hubspot-wrap .hsfc-FieldLabel__RequiredIndicator {
    color: #dc2626 !important;
    margin-left: 4px !important;
    font-weight: 800 !important;
}

/* --- 5. Text / email / tel inputs: 48px tall, square, slate border --- */
.gcs-hubspot-wrap .hsfc-TextInput,
.gcs-hubspot-wrap input[type="text"],
.gcs-hubspot-wrap input[type="email"],
.gcs-hubspot-wrap input[type="tel"] {
    width: 100% !important;
    height: 48px !important;
    box-sizing: border-box !important;
    border-radius: 0 !important;
    border: 1px solid #cbd5e1 !important;
    background-color: #ffffff !important;
    background-image: none !important;
    color: #334155 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 15px !important;
    font-weight: 400 !important;
    padding: 0 16px !important;
    box-shadow: none !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}
.gcs-hubspot-wrap .hsfc-TextInput::placeholder,
.gcs-hubspot-wrap input::placeholder,
.gcs-hubspot-wrap textarea::placeholder {
    color: #94a3b8 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
}

/* --- 6. Textarea: multi-line project field, square corners --- */
.gcs-hubspot-wrap .hsfc-TextareaInput,
.gcs-hubspot-wrap textarea {
    width: 100% !important;
    height: 96px !important;
    min-height: 96px !important;
    box-sizing: border-box !important;
    border-radius: 0 !important;
    border: 1px solid #cbd5e1 !important;
    background-color: #ffffff !important;
    color: #334155 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 15px !important;
    line-height: 1.45 !important;
    padding: 12px 16px !important;
    box-shadow: none !important;
    resize: vertical !important;
}

/* --- 7. Dropdown (combobox) — Area of Service --- */
.gcs-hubspot-wrap .hsfc-DropdownInput {
    position: relative !important;
}
.gcs-hubspot-wrap .hsfc-DropdownInput .hsfc-TextInput--button {
    cursor: pointer !important;
    padding-right: 40px !important;
}
.gcs-hubspot-wrap .hsfc-DropdownInput__Caret {
    position: absolute !important;
    right: 16px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    pointer-events: none !important;
}
.gcs-hubspot-wrap .hsfc-DropdownInput__Caret > span {
    display: inline-block !important;
    border: 5px solid transparent !important;
    border-top-color: #64748b !important;
    border-bottom: 0 !important;
}
.gcs-hubspot-wrap .hsfc-DropdownOptions {
    border-radius: 0 !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    box-shadow: 0 12px 32px rgba(0, 31, 70, 0.12) !important;
    max-height: 280px !important;
    z-index: 10000 !important;
}
.gcs-hubspot-wrap .hsfc-DropdownOptions__List__ListItem {
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 14px !important;
    color: #334155 !important;
    padding: 10px 16px !important;
}
.gcs-hubspot-wrap .hsfc-DropdownOptions__List__ListItem:hover,
.gcs-hubspot-wrap .hsfc-DropdownOptions__List__ListItem--selected {
    background: #e6f4fb !important;
    color: #0099D8 !important;
}

/* --- 8. Phone field — flag selector + input together in one 48px row --- */
.gcs-hubspot-wrap .hsfc-PhoneInput {
    display: flex !important;
    align-items: stretch !important;
    height: 48px !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    box-sizing: border-box !important;
}
.gcs-hubspot-wrap .hsfc-PhoneInput .hsfc-TextInput {
    flex: 1 !important;
    height: 100% !important;
    border: none !important;
    padding: 0 16px !important;
}
.gcs-hubspot-wrap .hsfc-PhoneInput__FlagAndCaret {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 0 12px !important;
    border-right: 1px solid #cbd5e1 !important;
    cursor: pointer !important;
    font-size: 16px !important;
    color: #334155 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
}
.gcs-hubspot-wrap .hsfc-PhoneInput__FlagAndCaret__Caret {
    width: 0 !important;
    height: 0 !important;
    border: 4px solid transparent !important;
    border-top-color: #64748b !important;
    border-bottom: 0 !important;
}

/* --- 9. Focus state: gw-blue border + soft ring --- */
.gcs-hubspot-wrap .hsfc-TextInput:focus,
.gcs-hubspot-wrap .hsfc-TextareaInput:focus,
.gcs-hubspot-wrap textarea:focus,
.gcs-hubspot-wrap input[type="text"]:focus,
.gcs-hubspot-wrap input[type="email"]:focus,
.gcs-hubspot-wrap input[type="tel"]:focus {
    outline: none !important;
    border-color: #0099D8 !important;
    box-shadow: 0 0 0 2px rgba(0, 153, 216, 0.20) !important;
}
.gcs-hubspot-wrap .hsfc-PhoneInput:focus-within {
    border-color: #0099D8 !important;
    box-shadow: 0 0 0 2px rgba(0, 153, 216, 0.20) !important;
}

/* --- 10. Submit button — full-width, 48px, gradient, uppercase, arrow ::after --- */
.gcs-hubspot-wrap .hsfc-NavigationRow {
    margin-top: 24px !important;
}
.gcs-hubspot-wrap .hsfc-NavigationRow__Buttons {
    width: 100% !important;
    justify-content: stretch !important;
}
.gcs-hubspot-wrap .hsfc-Button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    height: 48px !important;
    padding: 0 2rem !important;
    color: #ffffff !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.06em !important;
    border: none !important;
    border-radius: 0 !important;
    background-color: transparent !important;
    background-image: linear-gradient(to right, #0099D8, #00B4F0) !important;
    box-shadow: 0 10px 24px rgba(0, 180, 240, 0.24) !important;
    cursor: pointer !important;
    transition: background-image 0.3s ease !important;
    text-align: center !important;
}
.gcs-hubspot-wrap .hsfc-Button::after {
    content: " \2192" !important;  /* arrow → */
    margin-left: 14px !important;
    font-size: 22px !important;
    line-height: 1 !important;
    font-weight: 400 !important;
}
.gcs-hubspot-wrap .hsfc-Button:not([disabled]):hover {
    background-image: linear-gradient(to right, #001F46, #001F46) !important;
    transform: none !important;
}
.gcs-hubspot-wrap .hsfc-Button:focus-visible {
    outline: 2px solid #00B4F0 !important;
    outline-offset: 2px !important;
}
.gcs-hubspot-wrap .hsfc-Button[disabled] {
    opacity: 0.6 !important;
    cursor: not-allowed !important;
}

@media (max-width: 640px) {
    .gcs-hubspot-wrap .hsfc-Step__Content {
        display: block !important;
    }

    .gcs-hubspot-wrap .hsfc-Row,
    .gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(3),
    .gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(4),
    .gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(5),
    .gcs-hubspot-wrap .hsfc-Step__Content > .hsfc-Row:nth-of-type(6) {
        display: block !important;
        width: 100% !important;
        margin-bottom: 18px !important;
    }
}

/* --- 11. Errors --- */
.gcs-hubspot-wrap .hsfc-ErrorAlert {
    color: #dc2626 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    margin-top: 6px !important;
}

/* --- 12. reCAPTCHA: center it --- */
.gcs-hubspot-wrap .hsfc-ReCaptchaV2 {
    display: flex !important;
    justify-content: center !important;
    margin: 12px 0 !important;
}

/* --- 13. Checkbox / radio (legal consent) --- */
.gcs-hubspot-wrap .hsfc-CheckboxInput,
.gcs-hubspot-wrap .hsfc-RadioInput {
    accent-color: #0099D8 !important;
    width: 1.15rem !important;
    height: 1.15rem !important;
    margin-right: 8px !important;
}

/* Privacy/consent body text — NOT uppercase, NOT small */
.gcs-hubspot-wrap .hsfc-CheckboxField .hsfc-FieldLabel,
.gcs-hubspot-wrap .hsfc-CheckboxField .hsfc-FieldLabel > span,
.gcs-hubspot-wrap .hsfc-CheckboxField .hsfc-FieldLabel > span > span,
.gcs-hubspot-wrap .hsfc-DataPrivacyField .hsfc-RichText,
.gcs-hubspot-wrap .hsfc-DataPrivacyField .hsfc-RichText p {
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    color: #64748b !important;
    line-height: 1.5 !important;
    font-weight: 400 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-style: normal !important;
}
.gcs-hubspot-wrap .hsfc-DataPrivacyField .hsfc-RichText a {
    color: #001F46 !important;
    text-decoration: underline !important;
    text-underline-offset: 2px !important;
    font-weight: 600 !important;
}

/* --------------------------------------------------------------------------
   Inline HubSpot developer embed (.hs-form-html)

   The newer .hs-form-frame embed renders the form inside an iframe, so theme CSS
   cannot reach the fields. The consultation block uses the same developer embed
   as the previous theme, which outputs stylable HTML into .gcs-hubspot-wrap.
   -------------------------------------------------------------------------- */

.gcs-hubspot-wrap,
.gcs-hubspot-wrap *,
.gcs-hubspot-wrap *::before,
.gcs-hubspot-wrap *::after {
    box-sizing: border-box !important;
}

.gcs-hubspot-wrap iframe {
    width: 100% !important;
    border: 0 !important;
}

.gcs-hubspot-wrap .hs-form-html {
    width: 100% !important;
}

.gcs-hubspot-wrap .submitted-message {
    color: #001F46 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 1rem !important;
    line-height: 1.6 !important;
}

.gcs-hubspot-wrap form.hs-form,
.gcs-hubspot-wrap form.gcs-hubspot-form {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 18px 16px !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    color: #001F46 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
}

.gcs-hubspot-wrap form.hs-form fieldset {
    display: contents !important;
    max-width: none !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
}

.gcs-hubspot-wrap form.hs-form .hs-form-field,
.gcs-hubspot-wrap form.hs-form .field {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.gcs-hubspot-wrap form.hs-form .hs-richtext,
.gcs-hubspot-wrap form.hs-form .hs-richtext p {
    grid-column: 1 / -1 !important;
    margin: -2px 0 4px !important;
    color: #64748b !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    font-style: italic !important;
    font-weight: 500 !important;
    line-height: 1.4 !important;
}

.gcs-hubspot-wrap form.hs-form .hs-fieldtype-textarea,
.gcs-hubspot-wrap form.hs-form .hs_message,
.gcs-hubspot-wrap form.hs-form .hs_project_description,
.gcs-hubspot-wrap form.hs-form .hs_describe_your_project,
.gcs-hubspot-wrap form.hs-form .hs_submit,
.gcs-hubspot-wrap form.hs-form .legal-consent-container,
.gcs-hubspot-wrap form.hs-form .hs-dependent-field,
.gcs-hubspot-wrap form.hs-form .hs_recaptcha,
.gcs-hubspot-wrap form.hs-form .hs_error_rollup {
    grid-column: 1 / -1 !important;
}

.gcs-hubspot-wrap form.hs-form label,
.gcs-hubspot-wrap form.hs-form label span {
    display: inline-block !important;
    margin: 0 !important;
    color: #001F46 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 11px !important;
    font-style: normal !important;
    font-weight: 800 !important;
    letter-spacing: 0.12em !important;
    line-height: 1.4 !important;
    text-transform: uppercase !important;
}

.gcs-hubspot-wrap form.hs-form label {
    margin-bottom: 8px !important;
}

.gcs-hubspot-wrap form.hs-form .hs-form-required,
.gcs-hubspot-wrap form.hs-form .hs_required {
    color: #dc2626 !important;
    margin-left: 2px !important;
}

.gcs-hubspot-wrap form.hs-form .input {
    width: 100% !important;
    margin: 0 !important;
}

.gcs-hubspot-wrap form.hs-form input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
.gcs-hubspot-wrap form.hs-form select,
.gcs-hubspot-wrap form.hs-form textarea,
.gcs-hubspot-wrap form.hs-form .hs-input {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    height: 48px !important;
    margin: 0 !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 0 !important;
    background-color: #ffffff !important;
    background-image: none !important;
    box-shadow: none !important;
    color: #334155 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 15px !important;
    font-weight: 400 !important;
    line-height: 48px !important;
    padding: 0 16px !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.gcs-hubspot-wrap form.hs-form select {
    appearance: auto !important;
    cursor: pointer !important;
}

.gcs-hubspot-wrap form.hs-form textarea {
    height: auto !important;
    min-height: 96px !important;
    line-height: 1.45 !important;
    padding: 12px 16px !important;
    resize: vertical !important;
}

.gcs-hubspot-wrap form.hs-form input::placeholder,
.gcs-hubspot-wrap form.hs-form textarea::placeholder {
    color: #94a3b8 !important;
    opacity: 1 !important;
}

.gcs-hubspot-wrap form.hs-form input:not([type="submit"]):focus,
.gcs-hubspot-wrap form.hs-form select:focus,
.gcs-hubspot-wrap form.hs-form textarea:focus,
.gcs-hubspot-wrap form.hs-form .hs-input:focus {
    outline: none !important;
    border-color: #0099D8 !important;
    box-shadow: 0 0 0 2px rgba(0, 153, 216, 0.20) !important;
}

.gcs-hubspot-wrap form.hs-form .hs_submit {
    margin-top: 2px !important;
}

.gcs-hubspot-wrap form.hs-form .actions {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

.gcs-hubspot-wrap form.hs-form input[type="submit"],
.gcs-hubspot-wrap form.hs-form button[type="submit"],
.gcs-hubspot-wrap form.hs-form .hs-button,
.gcs-hubspot-wrap form.hs-form .gcs-hubspot-submit {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 48px !important;
    margin: 0 !important;
    padding: 0 2rem !important;
    border: 0 !important;
    border-radius: 0 !important;
    background-color: #0099D8 !important;
    background-image: linear-gradient(to right, #0099D8, #00B4F0) !important;
    box-shadow: 0 10px 24px rgba(0, 180, 240, 0.24) !important;
    color: #ffffff !important;
    cursor: pointer !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 15px !important;
    font-weight: 800 !important;
    letter-spacing: 0.06em !important;
    line-height: 48px !important;
    text-align: center !important;
    text-transform: uppercase !important;
    transition: background-image 0.25s ease !important;
    white-space: normal !important;
}

.gcs-hubspot-wrap form.hs-form input[type="submit"]:hover,
.gcs-hubspot-wrap form.hs-form button[type="submit"]:hover,
.gcs-hubspot-wrap form.hs-form .hs-button:hover,
.gcs-hubspot-wrap form.hs-form .gcs-hubspot-submit:hover {
    background-color: #001F46 !important;
    background-image: linear-gradient(to right, #001F46, #001F46) !important;
}

.gcs-hubspot-wrap form.hs-form input[type="submit"]:focus-visible,
.gcs-hubspot-wrap form.hs-form button[type="submit"]:focus-visible,
.gcs-hubspot-wrap form.hs-form .hs-button:focus-visible {
    outline: 2px solid #00B4F0 !important;
    outline-offset: 2px !important;
}

.gcs-hubspot-wrap form.hs-form .hs-error-msgs,
.gcs-hubspot-wrap form.hs-form .hs-error-msgs.inputs-list,
.gcs-hubspot-wrap form.hs-form .no-list {
    list-style: none !important;
    margin: 6px 0 0 !important;
    padding: 0 !important;
}

.gcs-hubspot-wrap form.hs-form .hs-error-msg,
.gcs-hubspot-wrap form.hs-form .hs-error-msgs label,
.gcs-hubspot-wrap form.hs-form .hs-main-font-element {
    color: #dc2626 !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    font-style: normal !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
    line-height: 1.35 !important;
    text-transform: none !important;
}

.gcs-hubspot-wrap form.hs-form .legal-consent-container {
    color: #64748b !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
    margin-top: 2px !important;
}

.gcs-hubspot-wrap form.hs-form .legal-consent-container p,
.gcs-hubspot-wrap form.hs-form .legal-consent-container span,
.gcs-hubspot-wrap form.hs-form .legal-consent-container label {
    color: #64748b !important;
    font-family: 'Inter', system-ui, sans-serif !important;
    font-size: 13px !important;
    font-style: normal !important;
    font-weight: 400 !important;
    letter-spacing: 0 !important;
    line-height: 1.5 !important;
    text-transform: none !important;
}

.gcs-hubspot-wrap form.hs-form .legal-consent-container a {
    color: #001F46 !important;
    font-weight: 800 !important;
    text-decoration: underline !important;
    text-underline-offset: 2px !important;
}

.gcs-hubspot-wrap form.hs-form input[type="checkbox"],
.gcs-hubspot-wrap form.hs-form input[type="radio"] {
    accent-color: #0099D8 !important;
    height: 18px !important;
    margin: 0 8px 0 0 !important;
    width: 18px !important;
}

@media (max-width: 640px) {
    .gcs-hubspot-wrap form.hs-form,
    .gcs-hubspot-wrap form.gcs-hubspot-form {
        grid-template-columns: 1fr !important;
    }

    .gcs-hubspot-wrap form.hs-form .hs-richtext,
    .gcs-hubspot-wrap form.hs-form .hs-fieldtype-textarea,
    .gcs-hubspot-wrap form.hs-form .hs_message,
    .gcs-hubspot-wrap form.hs-form .hs_project_description,
    .gcs-hubspot-wrap form.hs-form .hs_describe_your_project,
    .gcs-hubspot-wrap form.hs-form .hs_submit,
    .gcs-hubspot-wrap form.hs-form .legal-consent-container,
    .gcs-hubspot-wrap form.hs-form .hs-dependent-field,
    .gcs-hubspot-wrap form.hs-form .hs_recaptcha,
    .gcs-hubspot-wrap form.hs-form .hs_error_rollup {
        grid-column: auto !important;
    }
}

/* --------------------------------------------------------------------------
   Hero quick-estimate HubSpot form

   Matches the expanded hero form:
   row 1: first, last, email, submit
   row 2: phone, company, area, submit
   row 3: project textarea across the field area, submit
   -------------------------------------------------------------------------- */

.gcs-hero-quick-estimate {
    margin-bottom: 5rem;
    margin-top: 3rem;
}

.gcs-hubspot-wrap--hero .hs-form-html,
.gcs-hubspot-wrap--hero .hsfc-Form,
.gcs-hubspot-wrap--hero .hsfc-Step {
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

.gcs-hubspot-wrap--hero {
    max-width: 100% !important;
    min-width: 0 !important;
    position: relative !important;
}

.gcs-hubspot-wrap--hero .hsfc-Step__Content {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) 288px !important;
    gap: 10px 16px !important;
    align-items: end !important;
    min-width: 0 !important;
}

.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row {
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row {
    display: flex !important;
    align-items: flex-start !important;
    gap: 16px !important;
    margin: 0 !important;
    max-width: 100% !important;
    min-width: 0 !important;
    width: 100% !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row > * {
    flex: 1 1 0 !important;
    min-width: 0 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has(> .hsfc-RichText),
.gcs-hubspot-wrap--hero .hsfc-HiddenField,
.gcs-hubspot-wrap--hero [data-hsfc-id="HiddenField"] {
    display: none !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextField + .hsfc-TextField) {
    grid-column: 1 / span 2 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-EmailField) {
    grid-column: 3 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-PhoneField) {
    grid-column: 4 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-EmailField):has(.hsfc-PhoneField) {
    grid-column: 3 / span 2 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextField):not(:has(.hsfc-TextField + .hsfc-TextField)) {
    grid-column: 1 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-DropdownField) {
    grid-column: 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextField):has(.hsfc-DropdownField) {
    grid-column: 1 / span 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has([name$="/area_of_service"]) {
    grid-column: 1 / span 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has([name$="/area_of_service"]) {
    grid-column: 1 / span 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextareaField) {
    grid-column: 3 / span 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-ReCaptchaV2),
.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-ErrorAlert),
.gcs-hubspot-wrap--hero .hsfc-ReCaptchaV2,
.gcs-hubspot-wrap--hero .hsfc-ErrorAlert {
    grid-column: 1 / -1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-ReCaptchaV2) {
    display: block !important;
    height: 1px !important;
    margin: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
    position: absolute !important;
    right: 0 !important;
    top: 0 !important;
    visibility: hidden !important;
    width: 1px !important;
    z-index: -1 !important;
}

.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has(.hsfc-ReCaptchaV2) {
    display: block !important;
    height: 1px !important;
    margin: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
    position: absolute !important;
    right: 0 !important;
    top: 0 !important;
    visibility: hidden !important;
    width: 1px !important;
    z-index: -1 !important;
}

.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has([name$="/firstname"]),
.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has([name$="/email"]),
.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has([name$="/company"]) {
    display: contents !important;
}

.gcs-hubspot-wrap--hero .hsfc-TextField:has([name$="/firstname"]) {
    grid-column: 1 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-TextField:has([name$="/lastname"]) {
    grid-column: 2 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-EmailField:has([name$="/email"]) {
    grid-column: 3 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-PhoneField:has([name$="/phone"]) {
    grid-column: 1 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-TextField:has([name$="/company"]) {
    grid-column: 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero .hsfc-DropdownField:has([name$="/area_of_service"]) {
    grid-column: 3 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has(.hsfc-TextareaField) {
    grid-column: 1 / span 3 !important;
    grid-row: 3 !important;
}

.gcs-hubspot-wrap.gcs-hubspot-wrap--hero .hsfc-Step__Content > .hsfc-Row:has(.hsfc-DataPrivacyField) {
    border-top: 1px solid #e2e8f0 !important;
    display: block !important;
    grid-column: 1 / -1 !important;
    grid-row: 4 !important;
    margin-top: 8px !important;
    padding-top: 14px !important;
}

.gcs-hubspot-wrap--hero .hsfc-DataPrivacyField,
.gcs-hubspot-wrap--hero .hsfc-DataPrivacyField .hsfc-Row,
.gcs-hubspot-wrap--hero .hsfc-DataPrivacyField .hsfc-RichText {
    display: block !important;
    margin: 0 !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow-wrap: anywhere !important;
    white-space: normal !important;
    width: 100% !important;
}

.gcs-hubspot-wrap--hero .hsfc-DataPrivacyField .hsfc-RichText p,
.gcs-hubspot-wrap--hero .hsfc-RichText p {
    max-width: 100% !important;
    min-width: 0 !important;
    overflow-wrap: anywhere !important;
    white-space: normal !important;
}

.gcs-hubspot-wrap--hero .hsfc-ReCaptchaV2 {
    display: block !important;
    justify-content: flex-start !important;
    margin: 0 !important;
    min-height: 0 !important;
    position: absolute !important;
    right: 0 !important;
    top: 0 !important;
    width: 256px !important;
}

.gcs-hubspot-wrap--hero .grecaptcha-badge {
    transform: none !important;
    transform-origin: top right !important;
    visibility: hidden !important;
    zoom: 1 !important;
}

.gcs-hubspot-wrap--hero .hsfc-NavigationRow {
    align-self: stretch !important;
    grid-column: 4 !important;
    grid-row: 1 / span 3 !important;
    margin: 0 !important;
    min-height: 250px !important;
}

.gcs-hubspot-wrap--hero .hsfc-NavigationRow__Buttons {
    display: flex !important;
    height: 100% !important;
    width: 100% !important;
}

.gcs-hubspot-wrap--hero .hsfc-Button {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    height: 100% !important;
    min-height: 250px !important;
    width: 100% !important;
    padding: 18px 14px !important;
    font-size: 0 !important;
    line-height: 1.1 !important;
    white-space: normal !important;
}

.gcs-hubspot-wrap--hero .hsfc-Button::before {
    content: "" !important;
    display: block !important;
    width: 28px !important;
    height: 28px !important;
    background-color: currentColor !important;
    -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M229.7 25.9a12 12 0 0 0-12.1-2.1L29.7 91.5a12 12 0 0 0 .9 22.8l83.1 28 28 83.1a12 12 0 0 0 11.1 8.2h.5a12 12 0 0 0 11.1-7.3l67.7-187.9a12 12 0 0 0-2.4-12.5ZM153.6 186.4l-19.2-57a12 12 0 0 0-7.6-7.6l-57-19.2 128.6-46.3Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
    mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M229.7 25.9a12 12 0 0 0-12.1-2.1L29.7 91.5a12 12 0 0 0 .9 22.8l83.1 28 28 83.1a12 12 0 0 0 11.1 8.2h.5a12 12 0 0 0 11.1-7.3l67.7-187.9a12 12 0 0 0-2.4-12.5ZM153.6 186.4l-19.2-57a12 12 0 0 0-7.6-7.6l-57-19.2 128.6-46.3Z'/%3E%3C/svg%3E") center / contain no-repeat !important;
}

.gcs-hubspot-wrap--hero .hsfc-Button::after {
    content: var(--gcs-hero-submit-line-1, "GET A") "\A" var(--gcs-hero-submit-line-2, "QUOTE") !important;
    display: block !important;
    font-size: 15px !important;
    font-weight: 800 !important;
    line-height: 1.15 !important;
    margin: 0 !important;
    white-space: pre !important;
}

.gcs-hubspot-wrap--hero .hsfc-TextareaInput,
.gcs-hubspot-wrap--hero textarea {
    height: 96px !important;
    min-height: 96px !important;
    overflow: auto !important;
    resize: vertical !important;
}

.gcs-hubspot-wrap--hero form.hs-form {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) 288px !important;
    gap: 10px 16px !important;
    align-items: end !important;
}

.gcs-hubspot-wrap--hero form.hs-form fieldset {
    display: contents !important;
    max-width: none !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs-richtext,
.gcs-hubspot-wrap--hero form.hs-form .legal-consent-container,
.gcs-hubspot-wrap--hero form.hs-form .hs-dependent-field {
    display: none !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_firstname {
    grid-column: 1 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_lastname {
    grid-column: 2 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_email {
    grid-column: 3 !important;
    grid-row: 1 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_phone {
    grid-column: 1 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_company {
    grid-column: 2 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs-fieldtype-select {
    grid-column: 3 !important;
    grid-row: 2 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs-fieldtype-textarea,
.gcs-hubspot-wrap--hero form.hs-form .hs_message,
.gcs-hubspot-wrap--hero form.hs-form .hs_project_description,
.gcs-hubspot-wrap--hero form.hs-form .hs_describe_your_project {
    grid-column: 1 / span 3 !important;
    grid-row: 3 !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_submit {
    align-self: stretch !important;
    grid-column: 4 !important;
    grid-row: 1 / span 3 !important;
    min-height: 250px !important;
}

.gcs-hubspot-wrap--hero form.hs-form .hs_submit .actions,
.gcs-hubspot-wrap--hero form.hs-form input[type="submit"],
.gcs-hubspot-wrap--hero form.hs-form button[type="submit"],
.gcs-hubspot-wrap--hero form.hs-form .hs-button {
    height: 100% !important;
    min-height: 250px !important;
}

@media (max-width: 1023px) {
    .gcs-hubspot-wrap--hero .hsfc-Step__Content {
        display: block !important;
    }

    .gcs-hubspot-wrap--hero .hsfc-Row,
    .gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextField + .hsfc-TextField),
    .gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-EmailField),
    .gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-PhoneField),
    .gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextField):not(:has(.hsfc-TextField + .hsfc-TextField)),
    .gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-DropdownField),
    .gcs-hubspot-wrap--hero .hsfc-Row:has(.hsfc-TextareaField),
    .gcs-hubspot-wrap--hero .hsfc-NavigationRow {
        display: block !important;
        margin-bottom: 10px !important;
        max-width: 100% !important;
        min-width: 0 !important;
        min-height: 0 !important;
        width: 100% !important;
    }

    .gcs-hubspot-wrap--hero .hsfc-Button {
        min-height: 48px !important;
    }

    .gcs-hubspot-wrap--hero form.hs-form {
        display: block !important;
    }

    .gcs-hubspot-wrap--hero form.hs-form fieldset {
        display: block !important;
    }

    .gcs-hubspot-wrap--hero form.hs-form .hs-form-field,
    .gcs-hubspot-wrap--hero form.hs-form .hs_submit {
        width: 100% !important;
        margin-bottom: 10px !important;
        min-height: 0 !important;
    }

    .gcs-hubspot-wrap--hero form.hs-form .hs_submit .actions,
    .gcs-hubspot-wrap--hero form.hs-form input[type="submit"],
    .gcs-hubspot-wrap--hero form.hs-form button[type="submit"],
    .gcs-hubspot-wrap--hero form.hs-form .hs-button {
        min-height: 48px !important;
    }
}
