.media-block {
    display: flex;
    flex-wrap: wrap;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 0 7px rgba(0,0,0,0.1);
    border: 1px solid #d2dbe0;
    overflow: hidden;
    margin-top: 25px;
}

.media-block:first-child {
    margin-top: 0;
}

.text {
    width: 405px;
    display: flex;
    flex-direction: column;
    padding: 40px;
}

@media(max-width: 1260px) {
    .text {
        padding: 30px;
    }
}

@media(max-width: 991px) {
    .text {
        width: 50%;
    }
}

@media(max-width: 767px) {
    .text {
        width: 100%;
    }
    .text h5, .text h6 {
        text-align: center;
    }
}

@media(max-width: 500px) {
    .text {
        padding-left: 15px;
        padding-right: 15px;
    }
}

.without-btns .text {
    flex-direction: row;
    align-items: center;
}

.media {
    width: 100%;
    min-height: 415px;
    flex: 1 1;
}

.reverse .text {
    order: 2;
}

@media(max-width: 767px) {
    .media {
        min-height: 300px;
        flex: none;
    }
    .reverse .text {
        order: -1;
    }
    .text h5, .text h6 {
        text-align: center;
    }
}

.text .btn-block {
    flex: 1 0 auto;
    align-items: flex-end;
    margin-top: 30px;
}

.text .btn {
    width: 100%;
    padding-left: 15px;
    padding-right: 15px;
}