/* fix */
.wpcf7-form .cb{
    padding: 0;
}

aside:has(.hirlevel),
article:has(.hirlevel) {
    container-type: inline-size;
    container-name: hirlevel;
}


@container hirlevel (width <=768px) {
    .hirlevel {
        margin-block: 0 !important;
        background: transparent none!important;
        background-size: unset;

        .wpcf7-form {
            display: flex;
            flex-flow: column nowrap;
            height: 515px;
            max-width: 450px;
            margin-inline: auto;
            background: url(../images/hirlevel-bg-vert.jpg) center center no-repeat !important;

            .wpcf7-response-output {
                border-radius: 0 0 6px 6px;
                background-color: #ce1f1f!important;
                border-left: 0;
                color: #fff!important;
            }

            .hide_me_after_submit {
                flex-flow: column wrap;
                gap: 24px;
                
                h2{
                    text-align: center;
                }
                h2,
                .row {
                    margin: 0 auto!important;
                    width: calc(100% - 30px)!important;
                    max-width: 350px;
                }
            }
        }

        &.full .inner{
            padding: 0;
        }
    }
}

@container hirlevel (width >=768px) {
    .hirlevel.full {
        margin-block: 0 !important;
        min-height: 178px !important;
        display: flex;
        flex-flow: column nowrap;
        justify-content: center;
        align-items: center;

        .wpcf7-form {
            display: block;
            .wpcf7-response-output {
                border-radius: 6px 6px 0 0;
                background-color: #ce1f1f;
                border-left: 0;
                color: #fff;
                margin: 0 auto;
                width: fit-content;
            }

            .hide_me_after_submit {
                margin: calc(28px + 10px) 15px 0;
                width: calc(100% - 30px);
                position: relative;
                flex-flow: row wrap;
                row-gap: 10px;

                @media screen and (max-width: 768px) {
                    flex-flow: column wrap;
                    row-gap: 24px;
                }

                h2 {
                    margin-inline: 15px;
                }

                h2,
                .row {
                    width: calc(100% / 6 - 30px);

                    @media screen and (max-width: 1280px) {
                        width: calc(100% / 4 - 30px);
                    }

                    /*@media screen and (max-width: 768px) {
                            margin: 0 auto;
                            width: calc(100% - 30px);
                            max-width: 350px;
                        }*/
                }

                .row.cb {
                    position: relative;
                    width: fit-content;
                    order: 6;
                    left: 0;
                    top: 0;
                    transform: none;

                    .wpcf7-list-item-label:before {
                        background-color: transparent;
                        border-color: #fff;
                    }


                }
            }
        }
    }
}

.hirlevel {
    .wpcf7-form {

        p {
            margin: 0;
        }

        .hide_me_after_submit {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 100%;
            height: 100%;

            .row {
                padding: 0 !important;

                .wpcf7-text {
                    background-color: #fff;
                    height: 58px;

                    &::placeholder {
                        color: #B18139;
                    }
                }

                .wpcf7-submit {
                    background-color: #a02842;
                    color: #fff;
                    font-family: "BakerSignet";
                    font-weight: 500;
                    font-size: 18px;
                    cursor: pointer;
                    margin-bottom: 0;
                    letter-spacing: 1px;

                    &:hover {
                        background-color: #cd3253;
                    }
                }

                .wpcf7-spinner {
                    position: absolute;
                    top: calc(50% - 12px);
                    right: 24px;
                    margin: 0;
                }

                .wpcf7-not-valid-tip {
                    position: absolute;
                    top: 0;
                    right: 0;
                    left: unset;
                    font-size: 12px;
                    line-height: 16px;
                    padding: 0 4px;
                    border-radius: 4px;
                    border: 1px solid #CDBCA1;
                    color: #ce1f1f;
                    background-color: #fff;
                    width: fit-content;
                    transform: translate3d(10px, -10px, 0);
                    box-shadow: 0 0 4px 2px rgba(0, 0, 0, .1);

                    &:after {
                        content: '';
                        position: absolute;
                        bottom: -5px;
                        left: 15px;
                        width: 0;
                        height: 0;
                        border-top: 5px solid #fff;
                        border-left: 5px solid transparent;
                        border-right: 5px solid transparent;

                    }

                    &:before {
                        content: '';
                        position: absolute;
                        bottom: -6px;
                        left: 14px;
                        width: 0;
                        height: 0;
                        border-top: 6px solid #CDBCA1;
                        border-left: 6px solid transparent;
                        border-right: 6px solid transparent;

                    }
                }
            }

            .row.cb {
                .wpcf7-not-valid .wpcf7-list-item-label {
                    color: #fff;
                }

                .wpcf7-not-valid-tip {
                    transform: translate3d(-10px, -15px, 0);
                    left: 0;
                    right: unset;
                    z-index: 1;
                }
            }

            .row:last-of-type {
                order: 5
            }
        }
    }
}