/*==========  Desktop First Method  ==========*/

@media only screen and (max-width : 1399px) {
    .container {
        width: 1270px;
    }
}

@media only screen and (max-width : 1299px) {
    .container {
        width: 1170px;
    }
}

/* Large Devices, Wide Screens */
@media only screen and (max-width : 1199px) {
    .container {
        width: 970px;
    }

    /*forms*/
    .form::before {
        left: -70px;
        border-bottom: 340px solid rgba(255,255,255, 0.45);
        border-left: 70px solid transparent;
    }

    .form::after {
        right: -70px;
        border-top: 340px solid rgba(255,255,255, 0.45);
        border-right: 70px solid transparent;
    }

    .form form {
        width: 300px;
        height: 340px;
        padding: 20px 10px;
    }

    header .right .menu li a {
        padding: 0 15px;
    }

    /*main block*/
    #main-block .form {
        margin-right: 100px;
    }

    /*about and bonus block*/
    #about .overlay .container .text {
        width: 350px;
    }

    #about .overlay .container .text::before {
        border-right: 350px solid transparent;
    }

    #about .overlay .container .text::after {
        border-left: 350px solid transparent;
    }

    /*references block*/
    #references .container .item {
        height: 600px;
    }

    #references .container .item .inner {
        width: 300px;
    }

    #references .container .item .content {
        height: 285px;
    }

    #references .container .item .content p {
        height: 210px;
    }

    #references .container .item .content a {
        width: 250px;
    }
}

/* Medium Devices, Desktops */
@media only screen and (max-width : 991px) {
    body {
        font-size: 15px;
    }

    .container {
        width: 750px;
    }

    h2 {
        font-size: 30px;
    }

    /*main block*/
    #main-block {
        height: 600px;
    }

    #main-block .overlay {
        padding-top: 80px;
    }

    #main-block .form {
        float: none;
        width: 300px;
        margin: 0 auto;
    }

    /*about and bonus block*/
    #about .overlay .container .text {
        font-size: 16px;
        margin-top: -80px;
        width: 320px;
        padding: 10px 15px;
    }

    #about .overlay .container .text::before {
        top: -100px;
        border-bottom: 100px solid #1199ff;
        border-right: 320px solid transparent;
    }

    #about .overlay .container .text::after,
    #bonus .overlay .container .text::after {
        display: none;
    }

    #about .overlay .container .text h2 {
        top: -60px;
        left: 15px;
    }

    #about .overlay .container .photo img,
    #bonus .overlay .container .photo img {
        width: 320px;
    }

    /*bonus block*/
    #bonus .overlay .container .text {
        width: 300px;
        margin-top: 60px;
        padding: 90px 15px 0 15px;
        font-size: 16px;
    }

    #bonus .overlay .container .text h2 {
        top: -15px;
        left: 15px;
    }

    #bonus .overlay .container .text::before {
        border-bottom: 90px solid #1199ff;
        border-left: 300px solid transparent;
        border-right: 0;
        top: -90px;
    }

    /*references block*/
    #references .container .item {
        height: 560px;
        width: 50%;
    }

    #references .container .item .inner {
        width: 330px;
    }

    #references .container .item .content {
        height: 250px;
    }

    #references .container .item .content p {
        height: 175px;
    }

    #references .container .item .content a {
        width: 250px;
    }

    /*contact block*/
    #contact .left img {
        width: 150px;
    }
}

/* Small Devices, Tablets */
@media only screen and (max-width : 767px) {

    body {
        font-size: 14px;
    }

    .container {
        width: 450px;
    }

    header .right .menu {
        width: 320px;
        position: fixed;
        top: 69px;
        right: -320px;
        background: rgba(0, 0, 0, 0.95);
        border-top: 1px solid #1199ff;
        border-left: 1px solid #1199ff;
        transition: right 300ms ease;
        height: calc(100vh - 70px);
    }

    header .right .menu.opened {
        right: 0;
    }

    header .right .menu li{
        display: block;
        border-bottom: 1px solid #1199ff;
        width: 100%;
        line-height: 60px;
    }

    header .right .menu li:nth-last-of-type(1) {
        border-bottom: none;
    }

    header .right .menu li a {
        height: 60px;
        display: block;
        width: 100%;
    }

    header .right .mobile-menu {
        display: block;
    }

    /*forms*/
    .form::before {
        display: none;
    }

    .form::after {
        display: none;
    }

    .form form {
        width: 100%;
        height: 320px;
        padding: 10px 15px;
    }

    .form form h2 {
        font-size: 21px;
    }

    /*main block*/
    #main-block {
        height: 620px;
    }

    #main-block .form {
        width: 280px;
    }

    /*about and bonus block*/
    #about .overlay {
        padding: 0;
    }

    #about .overlay .container,
    #bonus .overlay .container {
        flex-direction: column;
    }

    #about .overlay .container .text,
    #bonus .overlay .container .text {
        width: 320px;
    }

    #about .overlay .container .text::before {
        border-right: 320px solid transparent;
        top: -100px;
        border-bottom: 100px solid #1199ff;
    }

    #about .overlay .container .text h2 {
        top: -60px;
    }

    #about .overlay .container .photo img,
    #bonus .overlay .container .photo img {
        width: 320px;
        padding: 0;
    }

    /*products block*/

    #products img {
        width: 100%;
        margin-bottom: 20px;
    }

    #products img:nth-last-of-type(1) {
        margin-bottom: 0;
    }

    /*bonus block*/
    #bonus .overlay {
        padding: 0;
    }

    #bonus .overlay .container .text {
        padding: 115px 15px 10px 15px;
        margin: 0;
    }

    #bonus .overlay .container .text::before {
        display: none;
    }

    #bonus .overlay .container .text h2 {
        top: 0;
    }

    /*references block*/
    #references .container .item {
        height: 560px;
        width: 100%;
    }

    #references .container .item .inner {
        width: 280px;
    }

    #references .container .item .content a {
        width: 220px;
    }

    /*contact block*/
    #contact {
        background: #000;
        padding: 20px 0 15px 0;
    }

    #contact .container {
        flex-direction: column;
        padding: 0;
    }

    #contact .container .left {
        margin-bottom: 20px;
    }

    #contact .right {
        padding-right: 0;
    }
}

/* Extra Small Devices, Phones */
@media only screen and (max-width : 479px) {
    .container {
        width: 300px;
        padding: 0 10px;
    }
}

/* Custom, iPhone Retina */
@media only screen and (max-width : 320px) {

}


/*==========  Mobile First Method  ==========*/

/* Custom, iPhone Retina */
@media only screen and (min-width : 320px) {

}

/* Extra Small Devices, Phones */
@media only screen and (min-width : 480px) {

}

/* Small Devices, Tablets */
@media only screen and (min-width : 768px) {

}

/* Medium Devices, Desktops */
@media only screen and (min-width : 992px) {

}

/* Large Devices, Wide Screens */
@media only screen and (min-width : 1200px) {

}

@media only screen and (min-width : 1300px) {

}

@media only screen and (min-width : 1400px) {

}