section.testimonials{
    /* border: 1px solid black; */
    height: 919px;

}

.testimonials-wrapper{
    width: 1160px;
    height: 599px;
    /* border: 1px solid blue; */
    padding: 140px 0 180px 0;
}

.testimonials-wrapper > h3{
    margin-bottom: 47px;
    font-size: 36px;
    line-height: 46.8px;
    text-align: center;
    color: #333B41;
    vertical-align: top;
}

.testimonials-cars-row{
    display: flex;
    flex-direction: row;
    justify-content: space-between;

    width: 1160px;
    height: 391px;
    /* border: 1px solid red; */
    margin-bottom: 21px;

}

/*-------------*/

.testimonials-card{
    width: 268px;
    height: 391px;
    padding: 15px 15px 19px 16px;
    background-color: #F1F3F2;
    color: #767474;
    border: 2px solid rgba(254, 189, 171, 0.74);
    border-radius: 20px;
}

.card-top-container{
    display: flex;
    flex-direction: row;
    justify-content:left;
    padding-bottom:11px;
}

.icon-container{
    margin-right: 10px;
}

.icon-container img{
    height: 37px;
    width: 100%;
}

.card-heading-text-container{
    margin-bottom: 1px;
}


.heading-name{
    font-weight: 400;
    font-size: 16px;
    line-height: 19.2px;
    color: #000000;
}


.heading-location{
    font-weight: 300;
    font-size: 15px;
    line-height: 18px;
    text-align: left;
    vertical-align: top;
    color: #BDBDBD;
}

.card-description p{
    font-weight: 300;
    font-size: 15px;
    line-height: 18px;
    /* line-height: 120%; */
    text-align: left;
    vertical-align: top;
    margin: 0;
    color: #767474;
}
.card-modal-window{
    display: none;
}

/*-------------*/

.testimonial-card5,
.testimonial-card6,
.testimonial-card7,
.testimonial-card8,
.testimonial-card9,
.testimonial-card10,
.testimonial-card11{
    display: none;
}


.fade {
    animation-name: fade;
    animation-duration: 2s;
    /* animation-timing-function: ease-in-out;
    animation-iteration-count: 1; */
  }

@keyframes fade {
    from {
        opacity: 0.7;
        /* background-color: #898b8d; */
    }
    to {
        opacity: 1;
        /* background-color: #FF4136; */
    }
}


/*New version of scrol from W3school - https://www.w3schools.com/howto/howto_js_rangeslider.asp*/
.slidecontainer {
    width: 599px;
    border-color: red;
    margin-bottom: 32px;
    margin-left: auto;
    margin-right: auto;
  }

  .slider {
    -webkit-appearance: none;
    border-radius: 5px;
    width: 100%;
    height: 8px;

    background: #F5F7F6;
    background: #e6e5e5;
    outline: none;
    opacity: 0.7;
    -webkit-transition: .2s;
    transition: opacity .2s;
  }

  .slider:hover {
    opacity: 1;
  }

  .slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    border-radius: 5px;
    appearance: none;
    width: 75px;
    /* width: 12.5%; */
    height: 8px;
    background: #FE9013;
    cursor: pointer;
  }

  .slider::-moz-range-thumb {
    width: 75px;
    /* width: 12.5%; */
    height: 8px;
    background: #04AA6D;
    cursor: pointer;
  }
/*------*/
.testimonials-button{
    display: flex;
    justify-content: left;
}

/*here we will check the layout of width=1000px, container width = 940*/
@media screen and (max-width: 1440px) {
    section.testimonials{
        height: 842px;
    }
    .testimonials-wrapper > h3{
        margin-bottom: 30px;
        width: 940px;
    }
    .testimonials-wrapper{
        max-width: 842px;
        height: 842px;
        padding: 100px 0px 110px ;
        margin-left: 0;
        margin-right: 0;
        /* margin-left: auto;
        margin-right: auto; */
    }
    .testimonials-cars-row .testimonials-card:nth-child(7){
        display: none;
    }
    .testimonials-cars-row{
        max-width: 939px;
        justify-content: space-between;
        margin-bottom: 20px;
    }
    .testimonials-card{
        width: 293px;
    }
    .slidecontainer{
        width: 390px;
        margin-bottom: 50px;
    }
}

/*here we will check the layout of width=640px, container width = 600*/
@media screen and (max-width: 999px) {
    section.testimonials{
        height: 669px;
    }
    .testimonials-wrapper{
        padding-top: 60px;
        padding-bottom: 80px;
        height: 669px;
        width: 600px;
    }
    .testimonials-wrapper > h3{
        width: 600px;
    }
    .testimonials-cars-row{
        width: 600px;
        flex-direction: column;
        justify-content: flex-start;
        margin-bottom: 40px;
    }
    .testimonials-card{
        width: 600px;
        height: 109px;
        overflow: hidden;
        /* pointer-events: auto; */
    }
    .testimonials-cars-row .testimonials-card:nth-child(1),
    .testimonials-cars-row .testimonials-card:nth-child(3){
        margin-bottom: 15px;
    }
    .testimonials-cars-row .testimonials-card:nth-child(5){
        margin-bottom: 40px;
    }
    .slidecontainer{
        display: none;
    }
    .testimonials-button{
        width: 600px;
        margin-top: -35px;
        /* justify-content: center; */
        margin-left: auto;
        margin-right: auto;
        width: 240px;
        height: 54px;
    }

    /*Popup handling*/
     .card-modal-window{


        /* display: block; */
        display: none; /*Hidden by default */

        position: fixed; /* Stay in place */
        z-index: 20; /* Sit on top */
        padding-top: 50%; /* Location of the box */
        left: 0;
        top: 0;
        width: 100%; /* Full width */
        height: 100%; /* Full height */
        overflow: auto; /* Enable scroll if needed */
        background-color: rgb(0,0,0); /* Fallback color */
        background-color: rgba(0,0,0,0.4); /* Black w/ opacity */


    }

    .modal-content{
        display: flex;
        justify-content: space-between;
        background-color: #F5F7F6;
        padding: 20px 10px 17px 17px;
        width: 320px;
        height: 428px;
        margin: auto;
    }


    .modal-content >.testimonials-card{
        width: 267px;
        height: 391px;

        background-color: #F5F7F6;
        margin: auto;
        padding: 20px;
        /* width: 50%; */
    }

    .modal-content .modal-close-button{
        margin-top: -20px;
        font-size: 28px;
        color:  #333B41;
        align-self: flex-start;
    }
    .card-modal-window .modal-close-button:hover,
    .card-modal-window .modal-close-button:focus{
        color:#E47209;
        transition: 0.1s s ease-in-out;
    }
    .card-modal-window .modal-close-button:active{
        color:#4B9200;
        transition: 0.1s ease-in-out;
    }
    /*// Popup handling*/
}

/*here we will check the layout of width=320px, container width = 320*/
@media screen and (max-width: 639px) {
    section.testimonials{
        height: 580px;
    }
    .testimonials-wrapper{
        padding-top: 30px;
        padding-bottom: 60px;
        height: 580px;
        width: 320px;
    }
    .testimonials-wrapper > h3{
        width: 320px;
        margin-bottom: 20px;
        font-size: 24px;
        line-height: 28.8px;
    }
    .testimonials-cars-row{
        width: 320px;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        margin-bottom: 40px;
    }
    .testimonials-card{
        width: 299px;
        height: 109px;
        overflow: hidden;
        padding: 11px 12px 12px;
    }
    .testimonials-cars-row .testimonials-card:nth-child(1),
    .testimonials-cars-row .testimonials-card:nth-child(3){
        margin-bottom: 15px;
    }
    .testimonials-cars-row .testimonials-card:nth-child(5){
        margin-bottom: 30px;
    }
    .testimonials-button{
        width: 320px;
        margin-top: -48px;
        justify-content: center;
        margin-left: auto;
        margin-right: auto;
        width: 240px;
        height: 54px;
    }
}
