.hdeng-wordpress-gravity-forms-critical-generate() {
    // Silence
}

.hdeng-wordpresss-gravity-forms-generate() {
    .gform_wrapper {
        margin: 0 0 @hdeng-spacing 0;
        padding: 0 !important;
        max-width: 100% !important;

        form {
            background: @hdeng-form-bg-color;
            border-radius: @hdeng-border-radius;
            padding: 40px;
            margin: 0 auto @hdeng-spacing auto;
        }

        h3.gform_title {
            font-size: 21px;
            color: @hdeng-body-font-default-color;
            font-weight: 400;
        }

        input[type="email"],
        input[type="number"],
        input[type="password"],
        input[type="tel"],
        input[type="text"],
        input[type="url"] {
            background-color: #FFF;
            background-image: none;
            border: 1px solid @hdeng-form-field-border-color;
            border-radius: @hdeng-border-radius;
            box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075) inset;
            transition: border-color 0.15s ease-in-out 0s, box-shadow 0.15s ease-in-out 0s;
        }

        select,
        textarea {
            background-color: #FFF;
            background-image: none;
            border: 1px solid @hdeng-form-field-border-color;
            border-radius: @hdeng-border-radius;
            box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075) inset;
            transition: border-color 0.15s ease-in-out 0s, box-shadow 0.15s ease-in-out 0s;
        }

        input[type="email"],
        input[type="number"],
        input[type="password"],
        input[type="tel"],
        input[type="text"],
        input[type="url"],
        select,
        textarea {
            padding: 6px 9px !important;

            &:focus {
                border-color: @hdeng-form-focus-color;
                outline: 0 none;
                box-shadow: 0 1px 1px rgba(0, 0, 0, 0.075) inset, 0 0 8px fade(@hdeng-form-focus-color, 40%);
            }
        }

        // Prepared to half address line if needed
        // .ginput_complex .address_line_1 {
        //     display: block;
        //     vertical-align: top;
        //     width: 48.5%;
        // }

        //== Fallback for not recommended left (or right) label layout
        .left_label {
            .gform_fileupload_multifile {
                margin-left: 30%;
            }
        }

        //== Field margin fix


        .gf_left_half.field_sublabel_above {
            margin-top:16px !important;
        }

        //== Mobile Devices
        @media (max-width: @hdeng-breakpoint-mobile) {
            form {
                padding: @hdeng-spacing;
            }

            .gf_left_half,
            .gf_right_half {
                width: 100% !important;
                float: left !important;
            }

            .ginput_complex {

                .ginput_full,
                .ginput_left,
                .ginput_right {
                    display: block;
                    width: 100%;
                    clear: both;
                    margin: 0;

                    input[type="email"],
                    input[type="number"],
                    input[type="password"],
                    input[type="tel"],
                    input[type="text"],
                    input[type="url"],
                    textarea,
                    select {
                        width: 100% !important;
                    }
                }

                &.ginput_container.has_first_name.has_middle_name.no_last_name span,
                &.ginput_container.has_first_name.no_middle_name.has_last_name span,
                &.ginput_container.no_first_name.has_middle_name.has_last_name span {
                    display: block;
                    width: 100%;
                    clear: both;
                }
            }

            input[type="email"],
            input[type="number"],
            input[type="password"],
            input[type="tel"],
            input[type="text"],
            input[type="url"],
            textarea,
            select {
                width: 100% !important;
            }

            //== Fallback for not recommended left (or right) label layout
            .left_label,
            .right_label {

                .gfield_label {
                    float: none;
                    clear: left !important;
                    width: 100%;
                    margin: 0;
                }

                div.ginput_complex {
                    width: 100%;
                }

                .gform_fileupload_multifile {
                    margin-left: 0;
                }

                ul.gfield_checkbox,
                ul.gfield_radio {
                    margin-left: 0 !important;
                }
            }
        }

        .gfield_checkbox li input[type="checkbox"],
        .gfield_radio li input[type="radio"] {
            display: -moz-inline-stack;
            display: inline-block;
            vertical-align: top;
            margin-left: 1px;
            margin-top: 5px;
        }
    }

    //== Validation
    .gform_wrapper {
        // Form Header
        div.validation_error {
            background-color: #F2DEDE;
            border-color: transparent;
            color: @hdeng-form-error-color;
            padding: floor(@hdeng-spacing / 2);
            margin-bottom: @hdeng-spacing;
            border-radius: @hdeng-border-radius;
            font-size: 14px;
            font-weight: 400;
        }

        // Error labels
        li.gfield_error div.ginput_complex.ginput_container label,
        li.gfield_error ul.gfield_checkbox, .gform_wrapper li.gfield_error ul.gfield_radio,
        .validation_message,
        .gfield_error .gfield_label {
            color: @hdeng-form-error-color;
        }

        // Form Field Wrapper
        li.gfield.gfield_error {
            background: none;
            border: none;
            padding: 0;
            margin: 0;
        }

        // Form Fields
        li.gfield.gfield_error {
            div.ginput_container,
            label.gfield_label,
            div.gfield_description,
            fieldset legend.gfield_label {
                margin-left: 0 !important;
            }
        }
    }
}
