input[type=submit] {
    background: none;
    border: none;
}

:is(
nf-fields-wrap,
.wp-block-woocommerce-checkout-fields-block .wc-block-components-form .wc-block-components-text-input
) :is(
input[type=email],
input[type=number],
input[type=password],
input[type=tel],
input[type=text],
input[type=url],
textarea
) {
    padding: 20px 40px;
    height: auto;
    border-radius: var(--wp--custom--border-radius--button);
    font-size: 17px;
    font-weight: 600;
    line-height: 1;
    border: 1px solid var(--wp--preset--color--accent-4);
    background-color: transparent;
}

:is(
nf-fields-wrap,
.wp-block-woocommerce-checkout-fields-block .wc-block-components-form .wc-block-components-text-input
) :is(
input[type=email]:focus,
input[type=number]:focus,
input[type=password]:focus,
input[type=tel]:focus,
input[type=text]:focus,
input[type=url]:focus,
textarea:focus
) {
    padding: 20px 40px;
    margin: 0;
    border-radius: var(--wp--custom--border-radius--button);
    font-size: 17px;
    font-weight: 600;
    border-color: var(--wp--preset--color--accent-2);
    border-width: 1px;
    border-style: solid;
    outline: 1px solid var(--wp--preset--color--accent-2);
    background-color: transparent;
}

textarea {
    padding: 40px;
}

nf-fields-wrap textarea {
    min-height: 280px;
}

.wc-blocks-components-select__container,
.wc-block-components-form .wc-block-components-text-input,
.wc-block-components-text-input {
    margin-top: 0;
}

/*:is(*/
/*.wc-block-components-validation-error*/
/*) :is(*/
/*input[type=email],*/
/*input[type=number],*/
/*input[type=password],*/
/*input[type=tel],*/
/*input[type=text],*/
/*input[type=url],*/
/*textarea*/
/*),*/
.wc-block-components-form .wc-block-components-text-input.has-error input:not(:active, :focus),
/*.wc-block-components-form .wc-block-components-text-input.has-error input:active,*/
.wc-block-components-form .wc-block-components-text-input.has-error input:hover,
.wc-block-components-text-input.has-error input:not(:active, :focus),
/*.wc-block-components-text-input.has-error input:active,*/
/*.wc-block-components-text-input.has-error input:focus,*/
.wc-block-components-text-input.has-error input:hover,
.nf-error input[type=text],
.nf-error input[type=email],
.nf-error textarea {
    margin-bottom: 0;
    line-height: 1;
    border-color: var(--wp--preset--color--accent-1) !important;
    outline: 1px solid var(--wp--preset--color--accent-1);
}

.nf-error input[type=text]:focus,
.nf-error input[type=email]:focus,
.nf-error textarea:focus {
    border-color: var(--wp--preset--color--accent-2) !important;
}

.nf-error textarea {
    grid-column-end: 2;
}

.nf-error-msg, .ninja-forms-req-symbol {
    color: var(--wp--preset--color--accent-1);
}

.nf-form-content {
    container: contact-form / inline-size;
}

.submit-wrap,
nf-field:has(.req_note) {
    color: var(--wp--preset--color--accent-5);
}

nf-fields-wrap {
    display: grid;
    gap: 30px;
    /*grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));*/
    grid-template-areas:
        'input'
        'input'
        'input'
        'input'
        'textarea'
        'footer'
        'footer'
    ;
}

.submit-wrap {
    display: block;

    .nf-field-label {
        display: none;
    }
}

nf-field:has(.req_note),
nf-field:has(.submit-wrap) {
    justify-content: center;
}

@container (min-width: 500px) {
    nf-field:has(.req_note),
    nf-field:has(.submit-wrap) {
        display: flex;
        align-items: center;
        margin-block-start: 10px;
    }
}

@container (min-width: 600px) {
    nf-fields-wrap {
        gap: 20px;
        grid-template-columns: repeat(2, 1fr);
        grid-template-areas:
            'input input'
            'input input'
            'textarea textarea'
            'footer footer'
        ;
    }

    .submit-wrap,
    nf-field:has(.req_note) {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    nf-field:has(.submit-wrap) {
        justify-content: flex-start;
    }

    nf-field:has(.req_note) {
        justify-content: flex-end;
    }
}

nf-fields-wrap *,
nf-field {
    line-height: 1;
}

nf-field:has(.textarea-container) {
    grid-area: textarea;
}

/*nf-field:has(.textarea-container) {*/
/*    grid-row-start: 3;*/
/*    grid-column-start: 1;*/
/*    grid-row-end: 3;*/
/*    grid-column-end: 3;*/
/*}*/

.nf-input-limit,
#ninja_forms_required_items,
.nf-field-container {
    margin-bottom: 0;
}

.nf-field-container.req_note {
    font-size: var(--wp--preset--font-size--small);
}

.nf-after-field,
.nf-error-msg,
.nf-form-fields-required {
    display: none;
}

.wc-blocks-components-select {
    .wc-blocks-components-select__container {
        svg {
            display: none;
        }
    }

    .wc-blocks-components-select__select {
        background-image: url('../images/arrow-dropdown.svg');
        background-repeat: no-repeat;
        background-position: calc(100% - 20px) 50%;
    }
}

