.custom-news-wrapper {
    --cn-bg: #ffffff;
    --cn-surface: #ffffff;
    --cn-border: #e5e7eb;
    --cn-muted: #64748b;
    --cn-text: #111827;
    --cn-heading: #0f172a;
    --cn-accent: #e11d48;
    --cn-accent-contrast: #ffffff;
    --cn-soft: #f8fafc;
    --cn-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
    color: var(--cn-text);
}

.custom-news-wrapper[data-resolved-theme="dark"] {
    --cn-bg: #0f172a;
    --cn-surface: #111c31;
    --cn-border: #263247;
    --cn-muted: #a8b3c7;
    --cn-text: #e5e7eb;
    --cn-heading: #f8fafc;
    --cn-accent: #fb7185;
    --cn-accent-contrast: #111827;
    --cn-soft: #162235;
    --cn-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
}

.custom-news-wrapper *,
.custom-news-wrapper *::before,
.custom-news-wrapper *::after {
    box-sizing: border-box;
}

.custom-news-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    margin: 0;
    padding: 0;
}

.custom-news-list,
.custom-news-sidebar-list,
.magazine-list {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.custom-news-grid-item,
.custom-news-list-item,
.custom-news-sidebar-item,
.custom-news-magazine-item {
    background: var(--cn-surface);
    color: var(--cn-text);
    border: 1px solid var(--cn-border);
    overflow: hidden;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.custom-news-grid-item:hover,
.custom-news-list-item:hover,
.custom-news-sidebar-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--cn-shadow);
    border-color: var(--cn-accent);
}

.custom-news-grid-item {
    display: flex;
    flex-direction: column;
}

.custom-news-list-item {
    display: flex;
    align-items: stretch;
    gap: 20px;
    padding: 16px;
}

.custom-news-sidebar-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-width: 0 0 1px;
    background: transparent;
}

.news-thumbnail-wrap {
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    width: 100%;
    background: var(--cn-soft);
}

.custom-news-grid-item .news-thumbnail-wrap,
.layout-large .news-thumbnail-wrap,
.layout-medium .news-thumbnail-wrap,
.layout-small .news-thumbnail-wrap {
    aspect-ratio: 16 / 9;
}

.custom-news-list-item .news-thumbnail-wrap {
    flex: 0 0 35%;
    max-width: 35%;
    aspect-ratio: 4 / 3;
}

.custom-news-sidebar-item .news-thumbnail-wrap {
    flex: 0 0 90px;
    max-width: 90px;
    aspect-ratio: 1 / 1;
    border-radius: 6px;
}

.news-thumbnail-link,
.news-thumbnail-wrap > a:not(.news-category-badge):not(.news-category-inline):not(.overlay-cat) {
    display: block;
    width: 100%;
    height: 100%;
}

.news-thumbnail-wrap img,
.news-thumbnail-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: transform 0.45s ease, filter 0.35s ease;
}

.news-thumbnail-fallback {
    width: 100%;
    height: 100%;
    min-height: 150px;
    background:
        linear-gradient(135deg, rgba(225, 29, 72, 0.14), transparent 48%),
        var(--cn-soft);
}

.custom-news-hover-zoom-in:hover .news-thumbnail-wrap img {
    transform: scale(1.06);
}

.custom-news-hover-grayscale .news-thumbnail-wrap img {
    filter: grayscale(100%);
}

.custom-news-hover-grayscale:hover .news-thumbnail-wrap img {
    filter: grayscale(0%);
}

.news-content-wrap {
    flex: 1 1 auto;
    width: 100%;
    padding: 18px;
}

.custom-news-list-item .news-content-wrap,
.custom-news-sidebar-item .news-content-wrap {
    padding: 0;
}

.news-title {
    margin: 8px 0;
    color: var(--cn-heading);
    line-height: 1.35;
    font-weight: 700;
}

.news-title a {
    color: inherit;
    text-decoration: none;
    background-image: linear-gradient(currentColor, currentColor);
    background-position: 0 100%;
    background-repeat: no-repeat;
    background-size: 0 1px;
    transition: color 0.2s ease, background-size 0.2s ease;
}

.news-title a:hover {
    color: var(--cn-accent);
    background-size: 100% 1px;
}

.news-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 12px;
    margin-bottom: 10px;
    color: var(--cn-muted);
    font-size: 13px;
    line-height: 1.45;
}

.news-meta > * {
    position: relative;
}

.news-meta > * + *::before {
    content: "";
    position: absolute;
    left: -7px;
    top: 50%;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: currentColor;
    transform: translateY(-50%);
    opacity: 0.55;
}

.news-excerpt {
    color: var(--cn-muted);
    line-height: 1.65;
    margin: 0;
}

.news-category-badge,
.news-category-text,
.overlay-cat {
    color: var(--cn-accent-contrast);
    background: var(--cn-accent);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    max-width: calc(100% - 24px);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.news-category-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    padding: 7px 10px;
}

.news-category-inline {
    position: static;
    margin-bottom: 4px;
}

.news-category-text {
    margin-bottom: 8px;
    padding: 7px 10px;
}

.overlay-cat {
    padding: 6px 9px;
}

.news-category-badge:hover,
.news-category-text:hover,
.overlay-cat:hover {
    opacity: 0.88;
    transform: translateY(-1px);
}

/*
.custom-news-filter-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
}

.custom-news-filter-tab {
    min-height: 38px;
    padding: 0 15px;
    border: 1px solid var(--cn-border);
    border-radius: 999px;
    background: var(--cn-surface);
    color: var(--cn-text);
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.custom-news-filter-tab:hover,
.custom-news-filter-tab.is-active {
    background: var(--cn-accent);
    border-color: var(--cn-accent);
    color: var(--cn-accent-contrast);
    transform: translateY(-1px);
}
*/

/* --- Filter Tabs Scroll Layout (Mobile Fixed) --- */
.custom-news-filter-tabs {
    display: flex;
    flex-wrap: nowrap; /* আগের wrap পরিবর্তন করে nowrap করা হয়েছে */
    gap: 8px;
    margin-bottom: 22px;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none; /* Firefox এর স্ক্রলবার হাইড */
    -ms-overflow-style: none; /* IE এর স্ক্রলবার হাইড */
    -webkit-overflow-scrolling: touch; /* মোবাইলে স্মুথ স্ক্রলিং */
}

/* Chrome/Safari এর স্ক্রলবার হাইড */
.custom-news-filter-tabs::-webkit-scrollbar {
    display: none; 
}

.custom-news-filter-tab {
    flex: 0 0 auto; /* ট্যাবগুলো যাতে চেপে না যায় */
    white-space: nowrap; /* টেক্সট যাতে নিচে না নামে */
    min-height: 38px;
    padding: 0 15px;
    border: 1px solid var(--cn-border);
    border-radius: 999px;
    background: var(--cn-surface);
    color: var(--cn-text);
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.custom-news-filter-tab:hover,
.custom-news-filter-tab.is-active {
    background: var(--cn-accent);
    border-color: var(--cn-accent);
    color: var(--cn-accent-contrast);
    transform: translateY(-1px);
}

.custom-news-ticker {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    margin-bottom: 22px;
    border: 1px solid var(--cn-border);
    border-radius: 8px;
    background: var(--cn-surface);
    overflow: hidden;
}

.custom-news-ticker-label {
    align-self: stretch;
    display: inline-flex;
    align-items: center;
    padding: 0 14px;
    background: var(--cn-accent);
    color: var(--cn-accent-contrast);
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0;
    white-space: nowrap;
}

.custom-news-ticker-viewport {
    min-width: 0;
    flex: 1;
    overflow: hidden;
}

.custom-news-ticker-track {
    display: inline-flex;
    align-items: center;
    gap: 28px;
    white-space: nowrap;
    animation: custom-news-ticker 28s linear infinite;
}

.custom-news-ticker-item {
    color: var(--cn-heading);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.custom-news-ticker-item:hover {
    color: var(--cn-accent);
}

@keyframes custom-news-ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.custom-news-theme-toggle-wrap {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 14px;
}

.custom-news-theme-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 0 12px;
    border: 1px solid var(--cn-border);
    border-radius: 999px;
    background: var(--cn-surface);
    color: var(--cn-text);
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
}

.custom-news-theme-toggle-icon {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--cn-accent);
    box-shadow: inset -5px -2px 0 rgba(255, 255, 255, 0.6);
}

.custom-news-wrapper[data-resolved-theme="dark"] .custom-news-theme-toggle-icon {
    box-shadow: inset 5px -2px 0 rgba(15, 23, 42, 0.9);
}

.custom-news-action-wrap {
    margin-top: 28px;
    text-align: center;
}

.custom-news-load-more,
.custom-news-view-all {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 22px;
    border: 1px solid var(--cn-accent);
    border-radius: 999px;
    background: var(--cn-accent);
    color: var(--cn-accent-contrast);
    cursor: pointer;
    font-weight: 700;
    text-decoration: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.custom-news-load-more:hover,
.custom-news-view-all:hover {
    color: var(--cn-accent-contrast);
    opacity: 0.9;
    transform: translateY(-1px);
}

.custom-news-load-more:disabled {
    cursor: wait;
    opacity: 0.72;
}

.infinite-scroll-trigger {
    width: 100%;
    height: 1px;
    visibility: hidden;
    pointer-events: none;
}

.custom-news-magazine {
    display: flex;
    gap: 30px;
}

.magazine-left,
.magazine-right {
    display: flex;
    flex-direction: column;
    width: 50%;
}

.magazine-right {
    gap: 20px;
}

.magazine-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--cn-border);
}

.custom-news-magazine-item {
    display: flex;
    background: transparent;
    border: 0;
}

.layout-large,
.layout-medium {
    flex-direction: column;
}

.layout-large .news-thumbnail-wrap,
.layout-medium .news-thumbnail-wrap {
    margin-bottom: 14px;
    border-radius: 8px;
}

.layout-large .news-title {
    font-size: 26px;
}

.layout-medium .news-title {
    font-size: 18px;
}

.layout-small {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    padding-bottom: 18px;
    border-bottom: 1px dashed var(--cn-border);
}

.layout-small:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.layout-small .news-content-wrap {
    padding: 0;
}

.layout-small .news-thumbnail-wrap {
    width: 140px;
    max-width: 140px;
    border-radius: 8px;
}

.layout-small .news-title {
    font-size: 16px;
}

.news-overlay-meta {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
}

.no-news-found {
    margin: 0;
    padding: 18px;
    border: 1px dashed var(--cn-border);
    border-radius: 8px;
    color: var(--cn-muted);
    background: var(--cn-soft);
}

@keyframes cn-shimmer {
    0% { background-position: -700px 0; }
    100% { background-position: 700px 0; }
}

.cn-skeleton {
    display: flex;
    overflow: hidden;
    border: 1px solid var(--cn-border);
    border-radius: 8px;
    background: var(--cn-surface);
}

.cn-skeleton.skin-grid,
.cn-skeleton.skin-magazine {
    flex-direction: column;
}

.cn-skeleton.skin-list {
    flex-direction: row;
}

.cn-skeleton.skin-sidebar {
    align-items: center;
    border-width: 0 0 1px;
    border-radius: 0;
    background: transparent;
}

.cn-sk-image,
.cn-sk-title,
.cn-sk-meta,
.cn-sk-excerpt {
    background-color: #e5e7eb;
    background-image: linear-gradient(90deg, #e5e7eb 0, #f8fafc 38%, #e5e7eb 75%);
    background-repeat: no-repeat;
    background-size: 700px 100%;
    animation: cn-shimmer 1.35s infinite linear;
}

.custom-news-wrapper[data-resolved-theme="dark"] .cn-sk-image,
.custom-news-wrapper[data-resolved-theme="dark"] .cn-sk-title,
.custom-news-wrapper[data-resolved-theme="dark"] .cn-sk-meta,
.custom-news-wrapper[data-resolved-theme="dark"] .cn-sk-excerpt {
    background-color: #253047;
    background-image: linear-gradient(90deg, #253047 0, #334158 38%, #253047 75%);
}

.cn-sk-image {
    flex-shrink: 0;
    width: 100%;
    height: 190px;
}

.skin-list .cn-sk-image {
    width: 35%;
    height: 160px;
}

.skin-sidebar .cn-sk-image {
    width: 90px;
    height: 90px;
    border-radius: 6px;
}

.cn-sk-body {
    flex: 1;
    padding: 16px;
}

.skin-sidebar .cn-sk-body {
    padding: 10px 0 10px 14px;
}

.cn-sk-meta {
    width: 36%;
    height: 12px;
    margin-bottom: 12px;
    border-radius: 999px;
}

.cn-sk-title {
    width: 82%;
    height: 20px;
    margin-bottom: 12px;
    border-radius: 5px;
}

.cn-sk-excerpt {
    width: 100%;
    height: 48px;
    border-radius: 5px;
}

.skin-sidebar .cn-sk-excerpt {
    display: none;
}

@media (max-width: 1024px) {
    .custom-news-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .custom-news-magazine {
        flex-direction: column;
    }

    .magazine-left,
    .magazine-right {
        width: 100%;
    }
}

@media (max-width: 767px) {
    .custom-news-grid,
    .magazine-grid {
        grid-template-columns: 1fr;
    }

    .custom-news-list-item,
    .layout-small {
        flex-direction: column;
    }

    .custom-news-list-item .news-thumbnail-wrap,
    .layout-small .news-thumbnail-wrap {
        width: 100% !important;
        max-width: 100% !important;
        flex-basis: auto !important;
    }

    .custom-news-sidebar-item {
        align-items: flex-start;
    }

    .custom-news-ticker {
        align-items: stretch;
        flex-direction: column;
        gap: 0;
    }

    .custom-news-ticker-label {
        min-height: 34px;
    }

    .custom-news-ticker-viewport {
        padding: 10px 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .custom-news-wrapper *,
    .custom-news-wrapper *::before,
    .custom-news-wrapper *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

/* Premium refresh for modern skins */
.custom-news-editorial-carousel-wrapper {
    --cn-carousel-gap: 24px;
}

.cn-editorial-track {
    gap: var(--cn-carousel-gap);
    align-items: stretch;
}

.cn-editorial-card {
    min-width: calc((100% - (var(--cn-carousel-gap) * (var(--cn-carousel-visible) - 1))) / var(--cn-carousel-visible));
    min-height: 520px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    transition: transform 0.28s ease, border-color 0.28s ease, box-shadow 0.28s ease;
}

.cn-editorial-card:hover {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--cn-accent) 52%, var(--cn-border));
    box-shadow: 0 18px 46px rgba(15, 23, 42, 0.13);
}

.cn-editorial-card-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
    padding: 24px 20px 20px;
}

.cn-editorial-card-top {
    min-height: 24px;
}

.cn-editorial-cat,
.cn-spotlight-hero-cat,
.cn-spotlight-item-cat,
.cn-mosaic-cat,
.cn-video-cat {
    color: var(--cn-accent);
    font-weight: 800;
    letter-spacing: 0;
    text-decoration: none;
}

.cn-editorial-title {
    margin: 8px 0 14px;
    font-size: 25px;
    line-height: 1.42;
    font-weight: 650;
}

.cn-editorial-excerpt {
    margin-bottom: 16px;
    color: var(--cn-text);
    line-height: 1.7;
}

.cn-editorial-extra-meta {
    margin-top: auto;
    margin-bottom: 0;
}

.cn-editorial-thumb {
    margin-top: auto;
    border-radius: 0;
}

.cn-carousel-controls {
    grid-template-columns: 44px minmax(140px, 1fr) 44px;
    gap: 16px;
    margin-top: 16px;
}

.cn-carousel-arrow {
    width: 42px;
    height: 42px;
    border: 1px solid rgba(148, 163, 184, 0.32);
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.1);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, opacity 0.22s ease;
}

.cn-carousel-arrow:hover:not(:disabled) {
    transform: translateY(-1px);
    border-color: var(--cn-accent);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
}

.cn-carousel-progress {
    position: relative;
    height: var(--cn-progress-height);
    overflow: hidden;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--cn-progress-track), color-mix(in srgb, var(--cn-progress-track) 62%, #ffffff));
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.42);
}

.cn-carousel-progress span {
    position: relative;
    min-width: var(--cn-progress-height);
    border-radius: inherit;
    background: linear-gradient(90deg, var(--cn-progress-color), color-mix(in srgb, var(--cn-progress-color) 64%, #ffffff));
    box-shadow: 0 0 18px color-mix(in srgb, var(--cn-progress-color) 42%, transparent);
    transition: width var(--cn-carousel-speed) cubic-bezier(0.22, 1, 0.36, 1);
}

.cn-carousel-progress span::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.58), transparent);
    transform: translateX(-100%);
    animation: cn-progress-sheen 1.8s ease-in-out infinite;
}

@keyframes cn-progress-sheen {
    100% {
        transform: translateX(100%);
    }
}

.cn-spotlight-layout {
    align-items: stretch;
    gap: 24px;
}

.cn-spotlight-hero {
    min-height: 500px;
    isolation: isolate;
    border-radius: 8px;
    box-shadow: 0 18px 52px rgba(15, 23, 42, 0.18);
    transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.cn-spotlight-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 62px rgba(15, 23, 42, 0.24);
}

.cn-spotlight-hero-media {
    background: #0f172a;
}

.cn-spotlight-hero-media::after {
    z-index: 1;
    background:
        radial-gradient(circle at 18% 28%, rgba(225, 29, 72, 0.26), transparent 30%),
        linear-gradient(90deg, rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.44) 54%, rgba(2, 6, 23, 0.2));
}

.cn-spotlight-hero-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 500px;
    padding: 56px 50px 44px;
}

.cn-spotlight-hero-cat {
    display: inline-flex;
    align-self: flex-start;
    margin-bottom: 18px;
    padding: 7px 11px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    backdrop-filter: blur(10px);
}

.cn-spotlight-hero-title {
    max-width: 720px;
    margin: 0 0 16px;
    font-size: 38px;
    line-height: 1.28;
    font-weight: 750;
}

.cn-spotlight-hero-excerpt {
    max-width: 680px;
    margin: 0 0 18px;
    font-size: 18px;
}

.cn-spotlight-hero .news-meta {
    color: rgba(255, 255, 255, 0.82);
}

.cn-spotlight-readmore {
    align-self: flex-start;
    margin-top: 6px;
    border-radius: 6px;
    box-shadow: 0 10px 24px rgba(225, 29, 72, 0.28);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.cn-spotlight-readmore:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 32px rgba(225, 29, 72, 0.34);
}

.cn-spotlight-side-list {
    gap: 12px;
}

.cn-spotlight-item {
    grid-template-columns: 142px minmax(0, 1fr);
    gap: 14px;
    min-height: 108px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.cn-spotlight-item:hover {
    transform: translateY(-2px);
    border-color: color-mix(in srgb, var(--cn-accent) 45%, var(--cn-border));
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.13);
}

.cn-spotlight-item.has-no-thumb {
    grid-template-columns: 1fr;
}

.cn-spotlight-item-thumb {
    height: 100%;
    min-height: 108px;
}

.cn-spotlight-item-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 12px 14px 12px 0;
}

.cn-spotlight-item-title {
    margin: 4px 0 6px;
    font-size: 16px;
    line-height: 1.45;
    font-weight: 650;
}

.cn-spotlight-item .news-meta {
    margin: 0;
    font-size: 12px;
}

.cn-mosaic-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.cn-mosaic-card {
    position: relative;
    display: flex;
    aspect-ratio: 1 / 1;
    min-height: 0;
    overflow: hidden;
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(225, 29, 72, 0.06), transparent 42%),
        var(--cn-surface);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.28s ease, border-color 0.28s ease, box-shadow 0.28s ease;
}

.cn-mosaic-card:hover {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--cn-accent) 42%, var(--cn-border));
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.16);
}

.cn-mosaic-media {
    position: absolute;
    inset: 0;
    z-index: 2;
    aspect-ratio: auto;
    opacity: 0;
    transform: scale(1.04);
    transition: opacity 0.34s ease, transform 0.48s ease;
}

.cn-mosaic-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.62));
}

.cn-mosaic-card:hover .cn-mosaic-media,
.cn-mosaic-card:focus-within .cn-mosaic-media {
    opacity: 1;
    transform: scale(1);
}

.cn-mosaic-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: center;
    padding: 20px;
    transition: opacity 0.22s ease, transform 0.22s ease;
}

.cn-mosaic-card:hover .cn-mosaic-content,
.cn-mosaic-card:focus-within .cn-mosaic-content {
    opacity: 0;
    transform: translateY(10px);
}

.cn-mosaic-cat {
    margin-bottom: 8px;
}

.cn-mosaic-title {
    margin: 6px 0 12px;
    font-size: 22px;
    line-height: 1.38;
    font-weight: 680;
}

.cn-mosaic-excerpt {
    line-height: 1.58;
}

.cn-mosaic-read {
    z-index: 3;
    top: 12px;
    left: 12px;
    padding: 6px 9px;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.7);
    backdrop-filter: blur(8px);
}

.cn-video-layout {
    grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.95fr);
    gap: 22px;
}

.cn-video-card {
    border-radius: 8px;
    background: var(--cn-surface);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.26s ease, border-color 0.26s ease, box-shadow 0.26s ease;
}

.cn-video-card:hover {
    transform: translateY(-2px);
    border-color: color-mix(in srgb, var(--cn-accent) 45%, var(--cn-border));
    box-shadow: 0 16px 38px rgba(15, 23, 42, 0.14);
}

.cn-video-card.is-featured {
    box-shadow: 0 18px 52px rgba(15, 23, 42, 0.16);
}

.cn-video-media {
    overflow: hidden;
    background: #020617;
}

.cn-video-media video,
.cn-video-media iframe,
.cn-video-thumb,
.cn-video-thumb img {
    display: block;
    width: 100%;
    height: 100%;
}

.cn-video-media video {
    object-fit: cover;
}

.cn-video-content {
    padding: 18px 20px 20px;
}

.cn-video-cat {
    display: inline-flex;
    margin: 0 0 10px;
    font-size: 13px;
}

.cn-video-title {
    margin: 0 0 10px;
    font-size: 26px;
    line-height: 1.35;
    font-weight: 720;
}

.cn-video-card:not(.is-featured) {
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 14px;
    min-height: 112px;
}

.cn-video-card:not(.is-featured) .cn-video-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 12px 14px 12px 0;
}

.cn-video-card:not(.is-featured) .cn-video-title {
    font-size: 16px;
    line-height: 1.42;
}

.cn-video-card:not(.is-featured) .news-meta {
    margin: 0;
    font-size: 12px;
}

.cn-video-badge {
    display: none !important;
}

.cn-video-play {
    width: 56px;
    height: 56px;
    background: rgba(225, 29, 72, 0.95);
    transition: transform 0.24s ease, background 0.24s ease;
}

.cn-video-thumb:hover .cn-video-play {
    transform: scale(1.08);
}

.cn-video-duration {
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(8px);
}

@media (max-width: 1024px) {
    .cn-editorial-card {
        min-width: calc((100% - var(--cn-carousel-gap)) / 2);
    }

    .cn-spotlight-layout,
    .cn-video-layout {
        grid-template-columns: 1fr;
    }

    .cn-mosaic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .cn-editorial-card {
        min-width: 100%;
        min-height: 0;
    }

    .cn-editorial-card-body {
        min-height: 0;
    }

    .cn-editorial-title {
        font-size: 22px;
    }

    .cn-spotlight-hero,
    .cn-spotlight-hero-content {
        min-height: 380px;
    }

    .cn-spotlight-hero-content {
        padding: 36px 22px 28px;
    }

    .cn-spotlight-hero-title {
        font-size: 27px;
    }

    .cn-spotlight-item,
    .cn-video-card:not(.is-featured) {
        grid-template-columns: 118px minmax(0, 1fr);
    }

    .cn-mosaic-grid {
        grid-template-columns: 1fr;
    }

    .cn-mosaic-card {
        min-height: 280px;
    }
}

/* Responsive hardening for badges, thumbnails, and text flow */
.custom-news-list-item,
.custom-news-sidebar-item,
.custom-news-magazine-item,
.cn-spotlight-item,
.cn-video-card:not(.is-featured) {
    min-width: 0;
}

.news-thumbnail-wrap,
.news-content-wrap,
.cn-editorial-card-body,
.cn-spotlight-hero-content,
.cn-spotlight-item-content,
.cn-mosaic-content,
.cn-video-content {
    min-width: 0;
}

.news-title,
.news-excerpt,
.news-meta,
.cn-editorial-title,
.cn-spotlight-hero-title,
.cn-spotlight-item-title,
.cn-mosaic-title,
.cn-video-title {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: normal;
}

.news-meta > * {
    max-width: 100%;
    white-space: nowrap;
}

.news-category-badge,
.news-category-text,
.overlay-cat,
.cn-editorial-cat,
.cn-spotlight-hero-cat,
.cn-spotlight-item-cat,
.cn-mosaic-cat,
.cn-video-cat {
    display: inline-block;
    max-width: min(150px, calc(100% - 16px));
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.1;
    vertical-align: top;
}

.news-category-badge {
    top: 8px;
    left: 8px;
    padding: 6px 9px;
}

.news-category-inline,
.news-category-text,
.cn-editorial-cat,
.cn-spotlight-item-cat,
.cn-mosaic-cat,
.cn-video-cat {
    max-width: 100%;
}

.custom-news-sidebar-item .news-category-inline {
    max-width: min(100%, 130px);
}

.custom-news-list-item .news-thumbnail-wrap .news-category-badge,
.custom-news-sidebar-item .news-thumbnail-wrap .news-category-badge,
.cn-spotlight-item-thumb .news-category-badge,
.cn-video-card:not(.is-featured) .news-category-badge {
    max-width: calc(100% - 10px);
    top: 5px;
    left: 5px;
    padding: 5px 7px;
    font-size: 10px;
}

@media (max-width: 767px) {
    .custom-news-wrapper {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    .news-category-badge,
    .news-category-text,
    .overlay-cat,
    .cn-editorial-cat,
    .cn-spotlight-hero-cat,
    .cn-spotlight-item-cat,
    .cn-mosaic-cat,
    .cn-video-cat {
        max-width: min(130px, calc(100% - 12px));
        font-size: 11px;
        line-height: 1.1;
    }

    .news-category-badge {
        top: 6px;
        left: 6px;
        padding: 5px 8px;
    }

    .custom-news-list-item .news-thumbnail-wrap .news-category-badge,
    .custom-news-sidebar-item .news-thumbnail-wrap .news-category-badge {
        max-width: calc(100% - 8px);
        top: 4px;
        left: 4px;
        padding: 5px 6px;
        font-size: 10px;
    }

    .news-meta {
        gap: 4px 10px;
        font-size: 12px;
        line-height: 1.4;
    }

    .news-excerpt {
        line-height: 1.55;
    }
}

@media (max-width: 480px) {
    .custom-news-list-item,
    .custom-news-sidebar-item {
        gap: 12px;
    }

    .custom-news-list-item {
        padding: 12px;
    }

    .custom-news-list-item .news-thumbnail-wrap,
    .custom-news-sidebar-item .news-thumbnail-wrap {
        min-width: 76px;
    }

    .news-category-badge,
    .news-category-text,
    .overlay-cat,
    .cn-editorial-cat,
    .cn-spotlight-hero-cat,
    .cn-spotlight-item-cat,
    .cn-mosaic-cat,
    .cn-video-cat {
        max-width: min(112px, calc(100% - 10px));
        font-size: 10px;
    }
}

/* Editorial carousel drag and mobile swipe polish */
.cn-editorial-viewport {
    cursor: grab;
    touch-action: pan-y;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
}

.cn-editorial-viewport.is-dragging {
    cursor: grabbing;
}

.cn-editorial-viewport.is-dragging .cn-editorial-track {
    transition: none;
}

.cn-editorial-track {
    user-select: none;
    -webkit-user-select: none;
}

.cn-editorial-card img {
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
    -webkit-user-select: none;
}

@media (max-width: 767px) {
    .cn-editorial-track {
        transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    }
}

/* Archive-aware tabs and context header */
.custom-news-archive-context {
    margin-bottom: 18px;
}

.custom-news-archive-title {
    margin: 0 0 8px;
    color: var(--cn-heading);
    font-size: 28px;
    line-height: 1.25;
    font-weight: 750;
}

.custom-news-archive-description {
    max-width: 780px;
    color: var(--cn-muted);
    line-height: 1.65;
}

.custom-news-filter-tabs {
    display: flex;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
}

.custom-news-filter-tab {
    flex: 0 0 auto;
    white-space: nowrap;
}

.custom-news-filter-tab:focus-visible {
    outline: 2px solid var(--cn-accent);
    outline-offset: 2px;
}

@media (max-width: 767px) {
    .custom-news-archive-title {
        font-size: 23px;
    }

    .custom-news-filter-tabs {
        padding-bottom: 4px;
    }
}

/* Editorial Carousel Skin */
.custom-news-editorial-carousel-wrapper {
    --cn-progress-color: #ef3d32;
    --cn-progress-track: #f5bbb6;
    --cn-progress-height: 4px;
    --cn-carousel-visible: 3;
    --cn-carousel-speed: 380ms;
}

.cn-editorial-tabs {
    border-bottom: 1px solid var(--cn-border);
    gap: 0;
    margin-bottom: 12px;
}

.cn-editorial-tabs .custom-news-filter-tab {
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--cn-muted);
    min-height: 50px;
    padding: 0 28px;
    transform: none;
    border-bottom: 2px solid transparent;
}

.cn-editorial-tabs .custom-news-filter-tab:hover,
.cn-editorial-tabs .custom-news-filter-tab.is-active {
    background: transparent;
    color: var(--cn-accent);
    border-bottom-color: var(--cn-accent);
    transform: none;
}

.cn-editorial-viewport {
    overflow: hidden;
}

.cn-editorial-track {
    display: flex;
    gap: 24px;
    transition: transform var(--cn-carousel-speed) ease;
    will-change: transform;
}

.cn-editorial-card {
    min-width: calc((100% - (24px * (var(--cn-carousel-visible) - 1))) / var(--cn-carousel-visible));
    border: 1px solid var(--cn-border);
    background: var(--cn-surface);
    display: flex;
    flex-direction: column;
}

.cn-editorial-card-body {
    min-height: 248px;
    padding: 22px 16px 18px;
}

.cn-editorial-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
}

.cn-editorial-cat,
.cn-editorial-date {
    color: var(--cn-accent);
    text-decoration: none;
    font-size: 13px;
}

.cn-editorial-date {
    color: var(--cn-muted);
}

.cn-editorial-title {
    margin: 0 0 42px;
    font-size: 26px;
    line-height: 1.45;
    font-weight: 500;
    color: var(--cn-heading);
}

.cn-editorial-title a,
.cn-spotlight-hero-title a,
.cn-spotlight-item-title a,
.cn-mosaic-title a,
.cn-video-title a {
    color: inherit;
    text-decoration: none;
}

.cn-editorial-title a:hover,
.cn-spotlight-hero-title a:hover,
.cn-spotlight-item-title a:hover,
.cn-mosaic-title a:hover,
.cn-video-title a:hover {
    color: var(--cn-accent);
}

.cn-editorial-excerpt {
    color: var(--cn-text);
    line-height: 1.75;
    margin: 0;
}

.cn-editorial-thumb {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.cn-editorial-thumb a {
    display: block;
    height: 100%;
}

.cn-editorial-read {
    position: absolute;
    left: 12px;
    top: 12px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}

.cn-carousel-controls {
    display: grid;
    grid-template-columns: 44px minmax(120px, 1fr) 44px;
    gap: 18px;
    align-items: center;
    margin-top: 10px;
}

.cn-carousel-arrow {
    width: 40px;
    height: 40px;
    border: 1px solid var(--cn-border);
    border-radius: 50%;
    background: var(--cn-surface);
    cursor: pointer;
    position: relative;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

.cn-carousel-arrow::before {
    content: "";
    position: absolute;
    inset: 0;
    margin: auto;
    width: 11px;
    height: 11px;
    border-top: 2px solid var(--cn-heading);
    border-right: 2px solid var(--cn-heading);
}

.cn-carousel-prev::before {
    transform: rotate(-135deg);
    left: 4px;
}

.cn-carousel-next::before {
    transform: rotate(45deg);
    right: 4px;
}

.cn-carousel-arrow:disabled {
    opacity: 0.35;
    cursor: default;
}

.cn-carousel-progress {
    height: var(--cn-progress-height);
    background: var(--cn-progress-track);
    overflow: hidden;
}

.cn-carousel-progress span {
    display: block;
    width: 0;
    height: 100%;
    background: var(--cn-progress-color);
    transition: width var(--cn-carousel-speed) ease;
}

/* Spotlight Skin */
.cn-spotlight-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
    gap: 22px;
}

.cn-spotlight-hero {
    min-height: 440px;
    position: relative;
    overflow: hidden;
    background: #111827;
    box-shadow: var(--cn-shadow);
}

.cn-spotlight-hero-media,
.cn-spotlight-hero-media img {
    display: block;
    width: 100%;
    height: 100%;
}

.cn-spotlight-hero-media {
    position: absolute;
    inset: 0;
}

.cn-spotlight-hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.2));
}

.cn-spotlight-hero-content {
    position: relative;
    z-index: 2;
    max-width: 620px;
    padding: 70px 48px 42px;
    color: #fff;
}

.cn-spotlight-hero-title {
    margin: 0 0 22px;
    font-size: 34px;
    line-height: 1.35;
    color: #fff;
}

.cn-spotlight-hero-excerpt {
    margin: 0 0 28px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 20px;
    line-height: 1.6;
}

.cn-spotlight-readmore {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 22px;
    background: var(--cn-accent);
    color: var(--cn-accent-contrast);
    text-decoration: none;
    font-weight: 800;
}

.cn-spotlight-side-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cn-spotlight-item {
    display: grid;
    grid-template-columns: 132px minmax(0, 1fr);
    gap: 12px;
    border: 1px solid var(--cn-border);
    background: var(--cn-surface);
    min-height: 90px;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
}

.cn-spotlight-item-thumb {
    position: relative;
    display: block;
    height: 90px;
    overflow: hidden;
}

.cn-spotlight-item-time {
    position: absolute;
    top: 6px;
    left: 6px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.55);
}

.cn-spotlight-item-content {
    padding: 10px 10px 8px 0;
}

.cn-spotlight-item-cat {
    color: var(--cn-accent);
    font-size: 13px;
    text-decoration: none;
}

.cn-spotlight-item-title {
    margin: 5px 0 0;
    font-size: 15px;
    line-height: 1.55;
    color: var(--cn-heading);
    font-weight: 500;
}

.cn-spotlight-ad {
    margin-top: 8px;
    min-height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cn-muted);
    border-top: 1px solid var(--cn-border);
    font-size: 12px;
}

/* Compact Mosaic Skin */
.cn-mosaic-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.cn-mosaic-card {
    min-height: 165px;
    border: 1px solid var(--cn-border);
    background: var(--cn-surface);
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.08);
    overflow: hidden;
}

.cn-mosaic-card.is-featured {
    display: flex;
    flex-direction: column;
}

.cn-mosaic-media {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.cn-mosaic-content {
    padding: 13px 12px;
}

.cn-mosaic-cat {
    display: block;
    color: var(--cn-accent);
    text-decoration: none;
    font-size: 13px;
    margin-bottom: 4px;
}

.cn-mosaic-date {
    display: block;
    color: var(--cn-muted);
    font-size: 12px;
    margin-bottom: 9px;
}

.cn-mosaic-title {
    margin: 0 0 12px;
    color: var(--cn-heading);
    font-size: 21px;
    line-height: 1.45;
    font-weight: 500;
}

.cn-mosaic-excerpt {
    margin: 0;
    color: var(--cn-muted);
    font-size: 13px;
    line-height: 1.55;
}

.cn-mosaic-read {
    position: absolute;
    left: 10px;
    top: 10px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

/* Video Skin */
.cn-video-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(300px, 1fr);
    gap: 24px;
}

.cn-video-card {
    background: var(--cn-surface);
    border: 1px solid var(--cn-border);
    overflow: hidden;
}

.cn-video-card.is-featured {
    box-shadow: var(--cn-shadow);
}

.cn-video-media {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #111827;
}

.cn-video-media iframe,
.cn-video-thumb,
.cn-video-thumb img {
    display: block;
    width: 100%;
    height: 100%;
}

.cn-video-media iframe {
    border: 0;
}

.cn-video-play {
    position: absolute;
    inset: 0;
    margin: auto;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: rgba(239, 61, 50, 0.94);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.28);
}

.cn-video-play::before {
    content: "";
    position: absolute;
    left: 23px;
    top: 18px;
    border-left: 17px solid #fff;
    border-top: 11px solid transparent;
    border-bottom: 11px solid transparent;
}

.cn-video-duration {
    position: absolute;
    right: 10px;
    bottom: 10px;
    padding: 4px 7px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.78);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}

.cn-video-content {
    padding: 16px;
}

.cn-video-badge,
.cn-video-cat {
    display: inline-flex;
    margin-right: 7px;
    margin-bottom: 8px;
    color: var(--cn-accent);
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
}

.cn-video-badge {
    color: var(--cn-accent-contrast);
    background: var(--cn-accent);
    padding: 4px 8px;
    border-radius: 999px;
}

.cn-video-title {
    margin: 0 0 10px;
    color: var(--cn-heading);
    font-size: 23px;
    line-height: 1.45;
}

.cn-video-card:not(.is-featured) {
    display: grid;
    grid-template-columns: 136px minmax(0, 1fr);
    gap: 12px;
}

.cn-video-card:not(.is-featured) .cn-video-media {
    aspect-ratio: 4 / 3;
}

.cn-video-card:not(.is-featured) .cn-video-content {
    padding: 10px 12px 8px 0;
}

.cn-video-card:not(.is-featured) .cn-video-title {
    font-size: 15px;
    line-height: 1.45;
}

.cn-video-playlist {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

@media (max-width: 1024px) {
    .cn-editorial-card {
        min-width: calc((100% - 24px) / 2);
    }

    .cn-spotlight-layout,
    .cn-video-layout {
        grid-template-columns: 1fr;
    }

    .cn-mosaic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .cn-editorial-card {
        min-width: 100%;
    }

    .cn-editorial-title {
        font-size: 22px;
        margin-bottom: 28px;
    }

    .cn-carousel-controls {
        grid-template-columns: 40px 1fr 40px;
        gap: 12px;
    }

    .cn-spotlight-hero {
        min-height: 360px;
    }

    .cn-spotlight-hero-content {
        padding: 42px 24px 28px;
    }

    .cn-spotlight-hero-title {
        font-size: 26px;
    }

    .cn-spotlight-item,
    .cn-video-card:not(.is-featured) {
        grid-template-columns: 112px minmax(0, 1fr);
    }

    .cn-mosaic-grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .custom-news-wrapper *,
    .custom-news-wrapper *::before,
    .custom-news-wrapper *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

/* Final modern skin overrides */
.custom-news-editorial-carousel-wrapper {
    --cn-carousel-gap: 24px;
}

.cn-editorial-track {
    gap: var(--cn-carousel-gap);
    align-items: stretch;
}

.cn-editorial-card {
    min-width: calc((100% - (var(--cn-carousel-gap) * (var(--cn-carousel-visible) - 1))) / var(--cn-carousel-visible));
    min-height: 520px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    transition: transform 0.28s ease, border-color 0.28s ease, box-shadow 0.28s ease;
}

.cn-editorial-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 18px 46px rgba(15, 23, 42, 0.13);
}

.cn-editorial-card-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
    padding: 24px 20px 20px;
}

.cn-editorial-title {
    margin: 8px 0 14px;
    font-size: 25px;
    line-height: 1.42;
    font-weight: 650;
}

.cn-editorial-excerpt {
    margin-bottom: 16px;
    color: var(--cn-text);
    line-height: 1.7;
}

.cn-editorial-extra-meta {
    margin-top: auto;
    margin-bottom: 0;
}

.cn-editorial-thumb {
    margin-top: auto;
    border-radius: 0;
}

.cn-carousel-progress {
    position: relative;
    height: var(--cn-progress-height);
    overflow: hidden;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--cn-progress-track), color-mix(in srgb, var(--cn-progress-track) 62%, #ffffff));
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.42);
}

.cn-carousel-progress span {
    position: relative;
    min-width: var(--cn-progress-height);
    border-radius: inherit;
    background: linear-gradient(90deg, var(--cn-progress-color), color-mix(in srgb, var(--cn-progress-color) 64%, #ffffff));
    box-shadow: 0 0 18px color-mix(in srgb, var(--cn-progress-color) 42%, transparent);
    transition: width var(--cn-carousel-speed) cubic-bezier(0.22, 1, 0.36, 1);
}

.cn-carousel-progress span::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.58), transparent);
    transform: translateX(-100%);
    animation: cn-progress-sheen 1.8s ease-in-out infinite;
}

.cn-spotlight-hero {
    min-height: 500px;
    isolation: isolate;
    border-radius: 8px;
    box-shadow: 0 18px 52px rgba(15, 23, 42, 0.18);
}

.cn-spotlight-hero-media::after {
    z-index: 1;
    background:
        radial-gradient(circle at 18% 28%, rgba(225, 29, 72, 0.26), transparent 30%),
        linear-gradient(90deg, rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.44) 54%, rgba(2, 6, 23, 0.2));
}

.cn-spotlight-hero-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 500px;
    max-width: 760px;
    padding: 56px 50px 44px;
}

.cn-spotlight-hero-cat {
    display: inline-flex;
    align-self: flex-start;
    margin-bottom: 18px;
    padding: 7px 11px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    font-weight: 800;
    backdrop-filter: blur(10px);
}

.cn-spotlight-hero-title {
    margin: 0 0 16px;
    font-size: 38px;
    line-height: 1.28;
    font-weight: 750;
}

.cn-spotlight-hero-excerpt {
    margin: 0 0 18px;
    font-size: 18px;
}

.cn-spotlight-hero .news-meta {
    color: rgba(255, 255, 255, 0.82);
}

.cn-spotlight-readmore {
    align-self: flex-start;
    margin-top: 6px;
    border-radius: 6px;
    box-shadow: 0 10px 24px rgba(225, 29, 72, 0.28);
}

.cn-spotlight-item {
    grid-template-columns: 142px minmax(0, 1fr);
    gap: 14px;
    min-height: 108px;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.cn-spotlight-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.13);
}

.cn-spotlight-item.has-no-thumb {
    grid-template-columns: 1fr;
}

.cn-spotlight-item-thumb {
    height: 100%;
    min-height: 108px;
}

.cn-spotlight-item-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 12px 14px 12px 0;
}

.cn-spotlight-item-title {
    margin: 4px 0 6px;
    font-size: 16px;
    line-height: 1.45;
    font-weight: 650;
}

.cn-spotlight-item .news-meta {
    margin: 0;
    font-size: 12px;
}

.cn-mosaic-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.cn-mosaic-card {
    position: relative;
    display: flex;
    aspect-ratio: 1 / 1;
    min-height: 0;
    overflow: hidden;
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(225, 29, 72, 0.06), transparent 42%),
        var(--cn-surface);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.cn-mosaic-media {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: block;
    aspect-ratio: auto;
    opacity: 0;
    transform: scale(1.04);
    transition: opacity 0.34s ease, transform 0.48s ease;
}

.cn-mosaic-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.62));
}

.cn-mosaic-card:hover .cn-mosaic-media {
    opacity: 1;
    transform: scale(1);
}

.cn-mosaic-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: center;
    padding: 20px;
    transition: opacity 0.22s ease, transform 0.22s ease;
}

.cn-mosaic-card:hover .cn-mosaic-content {
    opacity: 0;
    transform: translateY(10px);
}

.cn-mosaic-card.has-no-media:hover .cn-mosaic-content {
    opacity: 1;
    transform: none;
}

.cn-mosaic-card:focus-within:not(:hover) .cn-mosaic-media {
    opacity: 0;
    transform: scale(1.04);
}

.cn-mosaic-card:focus-within:not(:hover) .cn-mosaic-content {
    opacity: 1;
    transform: none;
}

.cn-mosaic-title {
    margin: 6px 0 12px;
    font-size: 22px;
    line-height: 1.38;
    font-weight: 680;
}

.cn-mosaic-read {
    z-index: 3;
    top: 12px;
    left: 12px;
    padding: 6px 9px;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.7);
    backdrop-filter: blur(8px);
}

.cn-video-layout {
    grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.95fr);
    gap: 22px;
}

.cn-video-card {
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.26s ease, box-shadow 0.26s ease;
}

.cn-video-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 38px rgba(15, 23, 42, 0.14);
}

.cn-video-card.is-featured {
    box-shadow: 0 18px 52px rgba(15, 23, 42, 0.16);
}

.cn-video-media {
    overflow: hidden;
    background: #020617;
}

.cn-video-media video,
.cn-video-media iframe,
.cn-video-thumb,
.cn-video-thumb img {
    display: block;
    width: 100%;
    height: 100%;
}

.cn-video-media video {
    object-fit: cover;
}

.cn-video-content {
    padding: 18px 20px 20px;
}

.cn-video-cat {
    display: inline-flex;
    margin: 0 0 10px;
    color: var(--cn-accent);
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
}

.cn-video-title {
    margin: 0 0 10px;
    font-size: 26px;
    line-height: 1.35;
    font-weight: 720;
}

.cn-video-card:not(.is-featured) {
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 14px;
    min-height: 112px;
}

.cn-video-card:not(.is-featured) .cn-video-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 12px 14px 12px 0;
}

.cn-video-card:not(.is-featured) .cn-video-title {
    font-size: 16px;
    line-height: 1.42;
}

.cn-video-card:not(.is-featured) .news-meta {
    margin: 0;
    font-size: 12px;
}

.cn-video-badge {
    display: none !important;
}

.cn-video-duration {
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(8px);
}

@media (max-width: 1024px) {
    .cn-editorial-card {
        min-width: calc((100% - var(--cn-carousel-gap)) / 2);
    }

    .cn-spotlight-layout,
    .cn-video-layout {
        grid-template-columns: 1fr;
    }

    .cn-mosaic-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .cn-editorial-card {
        min-width: 100%;
        min-height: 0;
    }

    .cn-spotlight-hero,
    .cn-spotlight-hero-content {
        min-height: 380px;
    }

    .cn-spotlight-hero-content {
        padding: 36px 22px 28px;
    }

    .cn-spotlight-hero-title {
        font-size: 27px;
    }

    .cn-spotlight-item,
    .cn-video-card:not(.is-featured) {
        grid-template-columns: 118px minmax(0, 1fr);
    }

    .cn-mosaic-grid {
        grid-template-columns: 1fr;
    }

    .cn-mosaic-card {
        min-height: 280px;
    }
}

/* Final responsive hardening for badges, thumbnails, and text flow */
.custom-news-list-item,
.custom-news-sidebar-item,
.custom-news-magazine-item,
.cn-spotlight-item,
.cn-video-card:not(.is-featured) {
    min-width: 0;
}

.news-thumbnail-wrap,
.news-content-wrap,
.cn-editorial-card-body,
.cn-spotlight-hero-content,
.cn-spotlight-item-content,
.cn-mosaic-content,
.cn-video-content {
    min-width: 0;
}

.news-title,
.news-excerpt,
.news-meta,
.cn-editorial-title,
.cn-spotlight-hero-title,
.cn-spotlight-item-title,
.cn-mosaic-title,
.cn-video-title {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: normal;
}

.news-meta > * {
    max-width: 100%;
    white-space: nowrap;
}

.news-category-badge,
.news-category-text,
.overlay-cat,
.cn-editorial-cat,
.cn-spotlight-hero-cat,
.cn-spotlight-item-cat,
.cn-mosaic-cat,
.cn-video-cat {
    display: inline-block;
    max-width: min(150px, calc(100% - 16px));
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.1;
    vertical-align: top;
}

.news-category-badge {
    top: 8px;
    left: 8px;
    padding: 6px 9px;
}

.news-category-inline,
.news-category-text,
.cn-editorial-cat,
.cn-spotlight-item-cat,
.cn-mosaic-cat,
.cn-video-cat {
    max-width: 100%;
}

.custom-news-sidebar-item .news-category-inline {
    max-width: min(100%, 130px);
}

.custom-news-list-item .news-thumbnail-wrap .news-category-badge,
.custom-news-sidebar-item .news-thumbnail-wrap .news-category-badge,
.cn-spotlight-item-thumb .news-category-badge,
.cn-video-card:not(.is-featured) .news-category-badge {
    max-width: calc(100% - 10px);
    top: 5px;
    left: 5px;
    padding: 5px 7px;
    font-size: 10px;
}

@media (max-width: 767px) {
    .custom-news-wrapper {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    .news-category-badge,
    .news-category-text,
    .overlay-cat,
    .cn-editorial-cat,
    .cn-spotlight-hero-cat,
    .cn-spotlight-item-cat,
    .cn-mosaic-cat,
    .cn-video-cat {
        max-width: min(130px, calc(100% - 12px));
        font-size: 11px;
        line-height: 1.1;
    }

    .news-category-badge {
        top: 6px;
        left: 6px;
        padding: 5px 8px;
    }

    .custom-news-list-item .news-thumbnail-wrap .news-category-badge,
    .custom-news-sidebar-item .news-thumbnail-wrap .news-category-badge {
        max-width: calc(100% - 8px);
        top: 4px;
        left: 4px;
        padding: 5px 6px;
        font-size: 10px;
    }

    .news-meta {
        gap: 4px 10px;
        font-size: 12px;
        line-height: 1.4;
    }

    .news-excerpt {
        line-height: 1.55;
    }
}

@media (max-width: 480px) {
    .custom-news-list-item,
    .custom-news-sidebar-item {
        gap: 12px;
    }

    .custom-news-list-item {
        padding: 12px;
    }

    .custom-news-list-item .news-thumbnail-wrap,
    .custom-news-sidebar-item .news-thumbnail-wrap {
        min-width: 76px;
    }

    .news-category-badge,
    .news-category-text,
    .overlay-cat,
    .cn-editorial-cat,
    .cn-spotlight-hero-cat,
    .cn-spotlight-item-cat,
    .cn-mosaic-cat,
    .cn-video-cat {
        max-width: min(112px, calc(100% - 10px));
        font-size: 10px;
    }
}


/* --- Video Carousel Specific Styles --- */
.cn-video-carousel-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #eee;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.cn-video-carousel-card:hover {
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
    transform: translateY(-4px);
}

.cn-video-carousel-card .cn-video-media {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #111;
}

.cn-video-carousel-card .cn-video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0.9;
    transition: transform 0.5s ease, opacity 0.3s;
}

.cn-video-carousel-card:hover .cn-video-thumb img {
    transform: scale(1.05);
    opacity: 1;
}

/* Play Button Overlay */
.cn-video-carousel-card .cn-video-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 44px;
    height: 44px;
    background: rgba(237, 28, 36, 0.9); /* Brand Red */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.2s ease;
}

.cn-video-carousel-card:hover .cn-video-play-icon {
    transform: translate(-50%, -50%) scale(1.15);
}

.cn-video-carousel-card .cn-video-play-icon::before {
    content: "";
    margin-left: 4px;
    border-left: 14px solid #fff;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

/* Duration Badge */
.cn-video-carousel-card .cn-video-duration-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    pointer-events: none;
}

/* Category Badge */
.cn-video-carousel-card .cn-video-cat-badge {
    display: inline-block;
    color: #ed1c24;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 8px;
    text-decoration: none;
}

/* Content Area */
.cn-video-carousel-card .cn-editorial-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.cn-video-carousel-card .cn-video-title {
    font-size: 18px;
    font-weight: 800;
    line-height: 1.4;
    margin: 0 0 10px;
}

.cn-video-carousel-card .cn-video-title a {
    color: #111;
    text-decoration: none;
    transition: color 0.2s;
}

.cn-video-carousel-card:hover .cn-video-title a {
    color: #ed1c24;
}