﻿/* GEDIAN SPORTS: Index-only uncropped editorial and advertisement images.
   Loaded AFTER gedian-index-ads.css; no changes to card layout. */
.gedian-landing .gs-featured-news > img,
.gedian-landing .gs-featured-news-image img,
.gedian-landing .gs-small-news img,
.gedian-landing .gs-small-news-image img {
    object-fit: contain !important;
    object-position: center center !important;
    background-color: #f5f8f3;
}

/* Advertisement cards use their existing bounds; show the complete creative. */
.gedian-landing :is([class*="gs-ad-"], [class*="gs-ads-"], [class*="gedian-ad-"], [class*="gedian-ads-"]) img:not([class*="icon"]):not([class*="avatar"]) {
    object-fit: contain !important;
    object-position: center center !important;
}

.gedian-landing :is([class*="gs-ad-"], [class*="gs-ads-"], [class*="gedian-ad-"], [class*="gedian-ads-"])[style*="background-image"] {
    background-size: contain !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
}

.gedian-landing .gs-ad-card img,
.gedian-landing .gs-ad-slide img,
.gedian-landing .gs-ads-slide img,
.gedian-landing .gs-ad-image,
.gedian-landing .gs-ad-media img,
.gedian-landing .gedian-ad-image,
.gedian-landing .gedian-ad-card img {
    object-fit: contain !important;
    object-position: center center !important;
}

/* NEWS TAB: preserve complete editorial photographs rather than cropping them.
   This is scoped to the news tab; existing card layout and advertisements are untouched. */
.gedian-landing [data-panel="news"] .gs-featured-news > img,
.gedian-landing [data-panel="news"] .gs-featured-news-image img,
.gedian-landing [data-panel="news"] .gs-small-news img,
.gedian-landing [data-panel="news"] .gs-small-news-image img {
    object-fit: contain !important;
    object-position: 50% 50% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    background-color: #f5f8f3;
}
/* Some news templates display a photograph as a background instead of an img. */
.gedian-landing [data-panel="news"] .gs-featured-news-image[style*="background-image"],
.gedian-landing [data-panel="news"] .gs-small-news-image[style*="background-image"] {
    background-size: contain !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}
/* Fixed-height hero frames: height:auto avoids the image stretching to the
   card dimensions; max-height keeps both portrait and landscape shots visible. */
.gedian-landing [data-panel="news"] .gs-featured-news-image img {
    height: auto !important;
    max-height: 520px !important;
    align-self: center;
    justify-self: center;
}

.gedian-landing [data-panel="news"] .gs-small-news-image img {
    height: auto !important;
    max-height: 120px !important;
    align-self: center;
    justify-self: center;
}
