/* =========================================================================
   RijNOSlink Elementor Widgets
   ========================================================================= */

/* --- Livestreams widget -------------------------------------------------- */

.rls-widget {
    font-family: inherit;
}

.rls-widget__heading {
    margin-top: 0;
    margin-bottom: 14px;
}

.rls-widget__empty {
    color: #787c82;
    font-style: italic;
    margin: 0;
}

/* Card grid: all streams are col-6, live streams are visually distinguished by badge/outline/title size */
.rls-widget__list {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-start;
}

/* --- Reusable live / liveblog badges ------------------------------------- */

.rls-live-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    padding: 3px 7px;
    border-radius: 4px;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    pointer-events: none;
}

/* Positioned on top of a thumbnail */
.rls-live-badge--overlay {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 3;
}

.rls-live-badge--live {
    background-color: #d63638;
}

.rls-live-badge--liveblog {
    background-color: #e67e00;
}

.rls-live-badge--upcoming {
    background-color: #2271b1;
}

/* Larger variant for header / block widgets and hero cards */
.rls-live-badge--lg {
    font-size: 14px;
    padding: 5px 11px;
    gap: 7px;
    border-radius: 3px;
}

/* Pulsing dot inside LIVE badges */
.rls-live-dot {
    width: 6px;
    height: 6px;
    background: #fff;
    border-radius: 50%;
    flex-shrink: 0;
    animation: rls-pulse 1.2s ease-in-out infinite;
}

.rls-live-badge--lg .rls-live-dot {
    width: 9px;
    height: 9px;
}

@keyframes rls-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.25; }
}

/* --- Single card item ---------------------------------------------------- */

/* All stream cards: half-width (col-6) */
.rls-item {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: calc(50% - 8px);
}

/* --- Thumbnail: fixed 16:9 ratio, anchors the overlay ------------------- */

.rls-item__thumb {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 4px;
    background: #111; /* placeholder when no image */
    text-decoration: none;
    flex-shrink: 0;
}

.rls-item__thumb img {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    max-width: none !important;
    max-height: none !important;
    display: block !important;
}

/* Red outline on live cards */
.rls-item--live .rls-item__thumb {
    outline: 2px solid #d63638;
    outline-offset: 2px;
}

/* --- Gradient overlay: title + meta on top of the image ----------------- */

.rls-item__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 36px 12px 12px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.80) 0%, rgba(0, 0, 0, 0) 100%);
    border-radius: 0 0 4px 4px;
}

.rls-item__meta {
    margin-bottom: 4px;
}

.rls-status {
    display: inline-block;
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.3;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.rls-status--live {
    color: #ff9494;
}

.rls-item__title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.35;
    color: #fff;
}

/* Hero live stream: slightly larger title */
.rls-item--hero .rls-item__title {
    font-size: 1.5rem;
}

/* --- Fixed-ratio image wrapper for block widget -------------------------- */
/* aspect-ratio lives on the <img> itself so theme `height: auto` rules are harmless */

.rls-thumb-wrap {
    position: relative; /* anchor for .rls-live-badge--overlay */
    display: block;
    width: 100%;
    overflow: hidden;
    line-height: 0; /* collapse inline gap */
}

.rls-thumb-wrap img {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4 / 3 !important;
    object-fit: cover !important;
    max-width: none !important;
    max-height: none !important;
}

/* --- Responsive: single column on narrow screens ------------------------ */

@media (max-width: 480px) {
    .rls-item {
        width: 100%;
    }
}
