@import url("//fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500&display=swap");

/* Carousel
   ========================================================================== */

/* Negative margin + slide padding give a 30px gutter while the outer edges
   still line up with the section. */
.featured-blogs__carousel {
    margin: 0 -15px;
    overflow: hidden;
    touch-action: pan-y;
    -webkit-user-select: none;
    user-select: none;
}

.featured-blogs__track {
    display: flex;
}

.featured-blogs__slide {
    flex: 0 0 50%;
    max-width: 50%;
    padding: 0 15px;
}

/* Post
   ========================================================================== */
/* Holds the gutter, so the ratio below resolves against the image width. */
.featured-blogs__media {
    padding-right: 15px;
}

/* padding-bottom keeps the 1200x680 crop reserved before the image loads. */
.featured-blogs__image {
    display: block;
    position: relative;
    padding-bottom: 60%;
    overflow: hidden;
}

/* Extra class needed to out-specify the theme's `img:not(...) { height: auto }`. */
.featured-blogs .featured-blogs__image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all .4s ease-in-out;
}

.featured-blogs__post:hover .featured-blogs__image img {
    transform: scale(1.1);
}

/* Pulled up over the image and inset on both sides. `top` keeps the 40px of
   whitespace the shifted box leaves behind, as the original did. */
.featured-blogs__body {
    position: relative;
    top: -40px;
    left: 40px;
    width: calc(100% - 80px);
    padding: 10px;
    background-color: #fff;
    text-align: center;
}

.featured-blogs__meta {
    margin: 0 0 20px;
    color: #9d9d9d;
    font-size: 10px;
    font-style: italic;
}

.featured-blogs__post-title {
    margin: 0;
    max-height: 90px;
    overflow: hidden;
    color: #000;
    font-family: 'Playfair Display', serif;
    font-size: 22px;
    font-weight: normal;
    line-height: 30px;
    text-transform: uppercase;
}

.featured-blogs__post-title a {
    display: block;
    color: inherit;
    transition: all .4s;
}

.featured-blogs__post-title a:hover {
    color: #000;
}

/* Breakpoints
   ========================================================================== */

@media (max-width: 991px) {
    .featured-blogs__media {
        padding-right: 10px;
    }

    .featured-blogs__body {
        top: 0;
        left: 0;
        width: 100%;
    }

    .featured-blogs__meta {
        margin-bottom: 10px;
    }
}

@media (max-width: 670px) {
    .featured-blogs__post-title {
        font-size: 15px;
        line-height: 20px;
        text-transform: none;
    }
}

@media (max-width: 480px) {
    .featured-blogs__media {
        margin-bottom: 15px;
        padding-right: 0;
    }
}

/* One post per view, mirroring the old slick `breakpoint: 480` step. */
@media (max-width: 479px) {
    .featured-blogs__slide {
        flex-basis: 100%;
        max-width: 100%;
    }
}
