.rbt-query-results-wrap h3.card-title {
    font-size: clamp(18px, 1.94vw, 28px);
}

/* Featured Grid - Desktop */
.featured_grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    height: 435px;
    gap: 8px;
}

.featured_grid .featured-news-item:first-of-type {
    grid-column: 1 / 2;
    /* left column */
    grid-row: 1 / 3;
    /* span both rows */
}

.featured_grid .featured-news-item:nth-of-type(2) {
    grid-column: 2 / 3;
    grid-row: 1 / 2;
}

.featured_grid .featured-news-item:nth-of-type(3) {
    grid-column: 2 / 3;
    grid-row: 2 / 3;
}

.featured-news-item {
    position: relative;
    display: flex;
    gap: 15px;
}

.featured-news-image {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    width: 40%;
    height: 100%;
    background-color: #f9f9f9;
}

.featured-news-image img {
    position: absolute;
    inset: 0;
    /* shorthand: top/right/bottom/left = 0 */
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    z-index: 1;
}

.featured-news-categories {
    position: absolute;
    right: 20px;
    top: 20px;
    display: flex;
    list-style: none;
    flex-direction: row-reverse;
    gap: 4px;
    flex-wrap: wrap;
    max-width: 50%;
    z-index: 2;
}

/* First card gets hero treatment */
.featured_grid .featured-news-item:first-of-type {
    grid-row: span 2;
    gap: 0;
    flex-direction: column;
}

.featured-news-content>a {
    text-decoration: none;
}

.featured_grid .featured-news-item:first-of-type .featured-news-content {
    position: absolute;
    bottom: 30px;
    left: -15px;
    background-color: #fff;
    padding: 20px;
    border-left: 5px solid var(--wp--preset--color--primary);
    box-shadow: 0px 5px 0px var(--wp--preset--color--primary);
    width: 90%;
    gap: 10px;
}

.featured_grid .featured-news-item:first-of-type .featured-news-image {
    width: 100%;
    height: 100%;
}

/* Content */
.featured-news-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    ;
    gap: 8px;
    z-index: 2;
    width: 60%;
    gap: 15px;
}

.featured-news-categories li a.button-primary {
    font-size: 10px;
    padding: 4px 8px;
}

.featured-news-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.featured-news-excerpt {
    font-size: 14px;
    line-height: 1.4;
    color: #444;
}

.featured-news-categories {
    margin: 0;
    padding: 0;
    list-style: none;
}

.featured-news-categories li {
    display: inline;
    white-space: nowrap;
}

@media (max-width: 992px) {
    .featured_grid {
        display: flex;
        height: 100%;
        flex-direction: column;
        padding: 20px;
    }

    .featured-news-categories {
        max-width: unset;
    }

    .featured_grid .featured-news-item {
        position: relative;
        margin-bottom: 16px;
        width: 100%;
        display: flex;
        flex-direction: row;
        min-height: 150px;
    }

    .featured_grid .featured-news-item:first-of-type {
        min-height: 250px;
        flex-direction: column;
    }

    .featured_grid .featured-news-item .featured-news-image {
        width: 30%;
    }

    .featured_grid .featured-news-item .featured-news-content {
        justify-content: flex-start;
    }

    /* Give images predictable sizing or ratio */
    .featured_grid .featured-news-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: top;
    }
}

@media (max-width: 556px) {
    .featured-news-excerpt {
        display: none;
    }
}

/* End Featured Grid */