@media(max-width:1700px){
    .bg_main{
        right: -400px;
    }
}

@media(max-width:1540px){
    :root{
        --container: 1240px;
    }
}

@media(max-width:1300px){
    :root{
        --container: 1100px;
    }
    .logo p, .logo span{
        display: none;
    }
    .bg_main {
        right: -50%;
    }
    .about_img{
        aspect-ratio: .8;
    }
    .how_div{
        height: 280px;
    }
    #zayavka .container img{
        right: -10%;
    }
    #zayavka input, #zayavka button{
        width: 100%;
    }
    .preim_div{
        width: 45%;
    }
}

@media(max-width:1140px){
    :root{
        --container: 900px;
    }
    .how_div{
        flex-grow: 1;
    }
    #about .container{
        flex-direction: column;
    }
    .about_img, .about_text{
        width: 100%;
    }
    .about_img{
        aspect-ratio: 16/11;
    }
    #zayavka .container img{
        display: none;
    }
    .zayavka_text{
        width: 100%;
    }
    #zayavka .container{
        padding: 60px 40px;
        background: var(--main);
    }
    #cont{
        padding: 80px 0px;
    }
    .bg_main{
        right: -60%;
    }
}

@media(max-width:991px){
    :root{
        --container: 700px;
    }
    header{
        border-bottom: 1px solid var(--gray);
    }
    ul.nav{
        flex-direction: column
    }
    .burger{
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 6px;
        height: 44px;
        width: 44px;
        border-radius: 4px;
        background: var(--main);
    }
    .burger span{
        display: block;
        height: 1px;
        width: 28px;
        background: #fff;
        transition: .3s;
    }
    .burger_active span:first-child{
        transform: translate(0, 7px) rotate(45deg);
    }
    .burger_active span:nth-child(2){
        opacity: 0;
    }
    .burger_active span:last-child{
        transform: translate(0, -7px) rotate(-45deg);
    }
    .secret_menu{
        position: fixed;
        top: 0;
        left: -110%;
        width: 100%;
        height: 100%;
        background: #fff;
        transition: .3s;
        display: block;
        z-index: 90;
        padding: 120px 0px;
        overflow: hidden;
    }
    .secret_menu_active{
        left: 0;
    }
    .main_img img{
       right: 0;
       height: auto;
       width: 80%;
       position: relative;
    }
    .main_img, .main_text{
        width: 100%;
    }
    #main .container{
        flex-direction: column-reverse;
        gap: 40px;
    }
    #main{
        height: auto;
    }
    .top_page{
        padding-top: 140px;
    }
    .bg_main{
        background-size: contain;
        height: 70%;
        width: 100%;
        top: 0;
        right: auto;
        left: 20%;
    }
    .nav li a{
        font-size: 18px;
    }
    h1{
        max-width: 100%;
        font-size: 36px;
    }
    h2{
        font-size: 28px;
    }
    h3{
        font-size: 20px;
    }
    section{
        padding-top: 80px;
    }
    #cont{
        margin-top: 80px;
    }
    footer{
        padding: 60px 0px;
    }
    footer .container{
        flex-direction: column;
        justify-content: start;
        align-items: start;
        gap: 20px;
    }
    #faq .container{
        flex-direction: column;
        align-items: start;
        justify-content: start;
    }
    #faq h2, .faq_row{
        width: 100%;
    }
    .header_mail, header .btn_main,
    .header_bottom{
        display: none;
    }
    .modal_content{
        padding: 40px 24px;
    }
    img.toggle_modal, img.toggle_modal_about{
        top: 10px;
        right: 10px;
        height: 24px;
    }
}

@media(max-width:770px){
    :root{
        --container: 540px;
    }
    .header_social{
        display: none;
    }
    .header_phone{
        flex-grow: 1;
    }
    .bg_main, .main_img{
        display: none;
    }
    #main p{
        font-size: 16px;
    }
    .uslugi_div, .how_div, .preim_div{
        width: 100%;
    }
    .how_div p.numb{
        font-size: 48px;
        bottom: 5px;
    }
    .how_div::before{
        height: 60px;
        width: 220px;
    }
    .how_div, .preim_div{
        height: 220px;
    }
    .uslugi_div:hover{
        background: var(--light-gray);
    }
    #zayavka .container{
        padding: 40px 24px;
    }
    .preim_div p.numb{
        font-size: 96px;
    }
    #cont iframe{
        position: relative;
        margin-top: 60px;
        height: auto;
        aspect-ratio: 16/11;
        display: none !important;
    }
    #cont{
        padding: 0px;
    }
    .cont_container{
        width: 100%;
        padding: 0;
        background: transparent;
        border: 0px;
    }
    .cont_container{
        gap: 20px;
    }
    .map_mobile{
        display: block;
    }
    #cont .map_mobile iframe{
        display: block !important;
    }
}

@media(max-width:500px){
    :root{
        --container: 540px;
    }
    .container{
        padding-left: 20px;
        padding-right: 20px;
    }
    .header_top .container{
        gap: 20px;
    }
    .logo h2{
        font-size: 24px;
    }
    .header_phone .flex{
        display: none;
    }
    .header_phone a, .header_mail a{
        font-size: 16px;
    }
    .burger{
        height: 36px;
        width: 36px;
    }
    .top_page{
        padding-top: 120px;
    }
    h1{
        font-size: 28px;
    }
    h2{
        font-size: 24px;
    }
    #zayavka{
        padding-left: 20px;
        padding-right: 20px;
    }
    footer{
        padding: 40px 0px;
    }
    .burger span{
        width: 24px;
    }
    p{
        line-height: 1.3;
    }
}

@media(max-width:420px){
    .header_top .container{
        gap: 10px;
    }
    img.toggle_modal, img.toggle_modal_about{
        height: 24px;
    }
    .preim_div{
        height: 260px;
    }
    .uslugi_div, .how_div, .preim_div{
        padding: 24px;
    }
    .preim_div p.numb{
        font-size: 64px;
        bottom: 0;
    }
    .faq_div_header p,
    .cont_div p:last-child, .cont_div a{
        font-size: 16px;
    }
}