/* Container */
#rss_container {
    width: 100%;
    height: auto;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}

/* Swiper wrapper */
#rss_wrapper {
    background-color: #ffffff;
    border-radius: 25px;
    width: 100%;
    height: auto;
}

/* Prevent peek-through during fades */
.gf-blog-slider .swiper-slide {
    overflow: hidden;
}

/* Card layout */
.rss-content-wrapper {
    display: flex;
    align-items: stretch;
    gap: 12px;
    width: 100%;
    height: 100%;
    padding: 8px 8px 12px 8px;
    box-sizing: border-box;
}

/* DESKTOP/TABLET image box */
.rss-image {
    width: 300px;
    height: 176px; /* baseline */
    max-height: 465px; /* requested cap */
    margin-right: 10px;
    position: relative;
    flex: 0 0 auto;
    border-radius: 10px;
    overflow: hidden;
    top: 11px;
}

    /* Anchor fills the box so the image can absolutely position inside it */
    .rss-image a {
        position: absolute;
        inset: 0;
        display: block;
    }

        /* Zoom-to-fill: always cover the box, even if the source is small */
        .rss-image a img {
            position: absolute;
            inset: 0; /* shorthand: top/right/bottom/left: 0 */
            width: 100% !important; /* fill both axes */
            height: 100% !important;
            object-fit: cover !important; /* zoom/crop to cover (no distortion) */
            object-position: center; /* center the crop */
            display: block;
            max-width: none !important; /* defeat global img rules */
        }


/* Text column */
.rss-content {
    flex: 1 1 auto;
    padding: 12px 16px 24px 8px;
    background-color: #ffffff;
    box-sizing: border-box;
    border-radius: 0 25px 25px 0;
    min-width: 0;
}

.rss-date {
    color: #46B4FE;
    font-size: 0.75rem;
    font-weight: bold;
    margin: 0 0 2px 0;
}

.rss-title {
    margin: 8px 0;
    line-height: 1rem;
    text-align: right;
}

    .rss-title > a {
        color: #f26522;
        text-decoration: none;
        font-weight: bold;
        font-size: 1rem;
    }

.rss-body p {
    color: #363636;
    font-size: 0.9rem;
    font-weight: normal;
    text-align: right;
    line-height: 1.2rem;
    margin: 0;
}

/* Right-justify bullets */
.gf-blog-slider .swiper-pagination {
    left: 0;
    right: 0;
    width: 100%;
    display: flex;
    justify-content: flex-end;
    gap: 6px;
    padding: 0 12px 6px 12px;
    pointer-events: auto;
}

.gf-blog-slider .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    opacity: .5;
}

.gf-blog-slider .swiper-pagination-bullet-active {
    opacity: 1;
}

/* Tablet tweak */
@media (max-width: 991px) {
    .rss-content-wrapper {
        gap: 10px;
    }
}

/* MOBILE: keep side-by-side; image ~33% and SQUARE; same crop behavior */
@media (max-width: 767px) {
    #rss_wrapper {
        border-radius: 15px;
    }

    .rss-content-wrapper {
        flex-direction: row;
        align-items: stretch;
        gap: 10px;
        padding: 10px;
    }

    .rss-image {
        flex: 0 0 33%;
        max-width: 33%;
        aspect-ratio: 1 / 1; /* square thumbnail */
        margin-right: 0;
        top: 0;
        border-radius: 12px;
    }

        .rss-image a {
            inset: 0;
        }
            /* keep anchor filling the square */

            .rss-image a img {
                height: 100% !important;
                width: auto !important;
                left: 50%;
                transform: translateX(-50%);
            }

    .rss-content {
        flex: 1 1 67%;
        min-width: 0;
        padding: 9px 10px 18px 10px;
        border-radius: 12px;
    }

    .rss-title > a {
        font-size: 0.9rem;
    }
}

/* Very small phones */
@media (max-width: 359px) {
    .rss-title > a {
        font-size: 0.82rem;
    }

    .rss-body p {
        font-size: 0.78rem;
        line-height: 1.05rem;
    }
}
