.sesi-berita{
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 60px 20px 60px;
    flex-direction: column;
}
.container-berita {
            display: flex;
            width: 100%;
            gap: 30px;
        }

        /* --- SISI KIRI: BERITA UTAMA --- */
        .main-news-section {
            flex: 2;
            background: #fff;
            border: 1px solid #e0e0e0;
            border-radius: 8px;
            overflow: hidden;
        }

        .main-image-container {
            background-color: #000;
            width: 100%;
            display: flex;
            justify-content: center;
        }

        .main-image-container img {
            width: 100%;
            max-height: 400px;
            object-fit: cover;
            display: block;
        }

        .main-news-content {
            padding: 20px;
        }

        .time-stamp {
            font-size: 12px;
            color: #888;
            margin-bottom: 8px;
        }

        .main-title {
            font-size: 26px;
            font-weight: 700;
            color: #d64513; /* Warna oranye kemerahan khas */
            line-height: 1.3;
            margin-bottom: 25px;
            cursor: pointer;
        }

        /* Berita Kecil di Bawah Berita Utama */
        .sub-news-container {
            display: flex;
            border-top: 1px solid #e0e0e0;
        }

        .sub-news-item {
            flex: 1;
            padding: 15px;
            border-right: 1px solid #e0e0e0;
        }

        .sub-news-item:last-child {
            border-right: none;
        }

        .sub-news-title {
            font-size: 14px;
            font-weight: 600;
            color: #111;
            line-height: 1.4;
            margin-top: 5px;
            cursor: pointer;
        }

        /* --- SISI KANAN: TERPOPULER --- */
        .trending-section {
            flex: 1;
            background: #fff;
            padding: 10px 0;
            border-radius: 10px;
            border: 1px solid #e0e0e0;
        }

               .trending-header {
    position: relative;
    font-size: 18px;
    font-weight: 700;
    color: #000;
    padding-left: 10px;
    padding-bottom: 10px; /* Ruang untuk posisi garis di bawah */
    margin-bottom: 20px;
}

/* Membuat garis bawah custom */
.trending-header::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 10px;          /* Selaras dengan padding-left teks utama */
    
    /* Atur dimensi garis sesuai seleramu kawan */
    width: 50px;         /* Panjang garis bawah */
    height: 4px;         /* Ketebalan garis */
    background-color: #d64513;
    border-radius: 2px;  /* Ujung garis dibuat halus/round */
}

        .trending-list {
            display: flex;
            flex-direction: column;
        }

        .trending-item {
            display: flex;
            align-items: flex-start;
            padding: 15px 0;
            border-bottom: 1px solid #ededed;
        }

        .trending-item:last-child {
            border-bottom: none;
        }

        .trending-number {
            font-size: 42px;
            font-weight: 800;
            color: #f7ede8;
            stroke: #d64513;
            /* Membuat efek outline angka oranye lembut seperti di gambar */
            -webkit-text-stroke: 1px #e66f43; 
            line-height: 1;
            margin-right: 10px;
            margin-left: 10px;
            min-width: 35px;
            text-align: center;
            justify-content: center;
            align-items: center;
        }

        .trending-text {
            display: flex;
            flex-direction: column;
        }

        .trending-title {
            font-size: 14px;
            font-weight: 700;
            color: #111;
            line-height: 1.4;
            margin-bottom: 4px;
            cursor: pointer;
        }

        .trending-title:hover, .main-title:hover, .sub-news-title:hover {
            color: #0056b3;
        }

        /* Responsive untuk HP / Layar Kecil */
        @media (max-width: 768px) {
            .container {
                flex-direction: column;
            }
            .sub-news-container {
                flex-direction: column;
            }
            .sub-news-item {
                border-right: none;
                border-bottom: 1px solid #e0e0e0;
            }
        }


        /* Styling Tambahan untuk Grid Card Footer */
.content-container {
    position: relative;
    padding-left: 10px;
    padding-right: 10px;
}

.card-footer-meta {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: 12px;
    border-top: 1px solid #f1f5f9;
    width: 100%;
    height: 100%;
    
}

.meta-left {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-bottom: 8px;
    padding-top: 8px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #666666;
    font-size: 12px;
    font-family: 'Segoe UI', sans-serif;
}

.meta-item svg {
    color: #000000;
}

/* Badge Kotak Gradasi Oranye di Pojok Kanan Bawah */


/* Menjadikan pembungkus kartu sebagai acuan patokan koordinat absolute */
.news-card.pos-relative-card {
    position: relative !important;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%; /* Pastikan tinggi kartu seimbang */
}

/* Beri ruang bawah pada kontainer teks agar judul panjang tidak menabrak badge */
.content-container {
    padding: 15px;
    padding-bottom: 50px; /* Space wajib di bawah untuk area badge */
}

/* LOCK POSISI BADGE DI POJOK KANAN BAWAH (PERSIS GAMBAR CARD.PNG) */
.meta-date-badge {
    position: absolute !important;
    right: 5px;
    bottom: 5px;
    background: #8c029e; /* Warna jingga oranye khas */
    color: #ffffff;
    padding: 5px 10px;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 50px;
    z-index: 10;
    font-family: 'Segoe UI', Arial, sans-serif;
    margin-top: 10px;
}

.badge-text-top {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    line-height: 1.2;
}

.badge-text-bottom {
    font-size: 10px;
    font-weight: 400;
    opacity: 0.9;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    width: 100%;
    text-align: center;
    margin-top: 3px;
    padding-top: 2px;
}

.badge-text-top {
    display: block;
    font-size: 13px;
    letter-spacing: 0.3px;
}

.badge-text-bottom {
    display: block;
    font-size: 14px;
}








.line-2-news {
    display: flex;
    flex-direction: column; /* Mengubah arah susunan agar pagination berada di bawah grid */
    justify-content: center;
    align-items: center;
    padding: 10px 60px 10px 60px;
    width: 100%;
    box-sizing: border-box;
}

                /* Container utama grid */
.news-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 kolom sama rata, baris kedua otomatis terbentuk */
    gap: 10px; /* Jarak antar kartu berita */
    width: 100%;
    background: #ffffff;
    padding: 20px 15px 20px 15px;
    border-radius: 10px;
}

        /* Responsive: Mengubah jumlah kolom di layar yang lebih kecil */
        @media (max-width: 1024px) {
    .news-container { grid-template-columns: repeat(3, 1fr); }
    .line-2-news { padding: 20px 30px; }
}
@media (max-width: 768px) {
    .news-container { grid-template-columns: repeat(2, 1fr); }
    .line-2-news { padding: 20px 20px; }
}
@media (max-width: 480px) {
    .news-container { grid-template-columns: 1fr; }
}

        /* Kartu Berita */
.news-card {
    background-color: #ffffff;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid #dedede;
}

.news-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    color: #00f8ae;
}



        /* Bagian Gambar */
        .image-container {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #e0e0e0;
    overflow: hidden;
}

.image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Bagian Teks */
.content-container {
    padding: 12px 4px;
}

 .news-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: #111111;
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-time {
    font-size: 12px;
    color: #888888;
}

/* === CSS TAMBAHAN: PAGINATION STYLING (MENYESUAIKAN TEMA MODEREN) === */
.pagination-user {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 35px;
    width: 100%;
}

.pagination-user a {
    color: #475569;
    padding: 8px 14px;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    transition: all 0.2s ease;
}

.pagination-user a:hover, .pagination-user a.active {
    background-color: #1e293b;
    color: #ffffff;
    border-color: #1e293b;
}

.pagination-user a.disabled {
    color: #cbd5e1;
    pointer-events: none;
    background: #f8fafc;
    border-color: #e2e8f0;
}




a.news-card {
    text-decoration: none !important;
    display: block;
}
a.news-card:hover .news-title {
    color: #ff7f00; /* Memberikan efek warna biru khas saat card disorot pointer */
}



/* ==========================================================================
   KHUSUS RESPONSIVE SESI BERITA & GRID CARD (TABLET & MOBILE)
   ========================================================================== */

/* --- Layar Tablet / iPad (Max Width: 1024px) --- */
@media (max-width: 1024px) {
    .sesi-berita, 
    .line-2-news { 
        padding: 20px 30px; /* Kurangi padding samping desktop yang terlalu lebar */
    }

    .news-container { 
        grid-template-columns: repeat(3, 1fr); 
    }
}

/* --- Layar HP Android & iOS Umum (Max Width: 768px) --- */
@media (max-width: 768px) {
    /* 1. Pengaturan Sesi Utama Berita */
    .sesi-berita {
        padding: 15px; /* Rampingkan padding agar area baca konten di HP maksimal */
    }

    /* Perbaikan Typo: Mengubah layout kolom desktop menjadi baris menumpuk ke bawah */
    .container-berita {
        flex-direction: column;
        gap: 25px;
    }

    /* 2. Optimasi Sisi Kiri: Berita Utama */
    .main-news-section {
        width: 100%;
    }

    .main-image-container img {
        max-height: 250px; /* Batasi tinggi gambar utama di HP agar tidak memenuhi satu layar full */
    }

    .main-news-content {
        padding: 15px; /* Kompres ruang padding konten di dalam kartu */
    }

    /* HEADING / JUDUL UTAMA BERITA: Disesuaikan agar proposional dan estetik */
    .main-title {
        font-size: 19px; /* Turunkan dari 26px agar pas di layar HP */
        line-height: 1.4;
        margin-bottom: 15px;
    }

    /* Susunan 2 berita kecil di bawah berita utama ditumpuk vertikal */
    .sub-news-container {
        flex-direction: column;
    }

    .sub-news-item {
        border-right: none; /* Hilangkan sekat pembatas kanan */
        border-bottom: 1px solid #e0e0e0; /* Ganti dengan sekat pembatas bawah */
        padding: 15px 10px;
    }

    .sub-news-item:last-child {
        border-bottom: none;
    }

    /* 3. Optimasi Sisi Kanan: Berita Terpopuler (Trending) */
    .trending-section {
        width: 100%;
        margin-top: 10px;
    }

    .trending-header {
        font-size: 17px;
        margin-bottom: 15px;
    }

    .trending-item {
        padding: 12px 10px;
    }

    /* Perkecil sedikit angka outline agar tidak terlalu mencolok di HP */
    .trending-number {
        font-size: 34px;
        min-width: 30px;
    }

    .trending-title {
        font-size: 13px;
    }

    /* 4. Optimasi Sesi Grid Berita Bawah (Line 2) & Pagination */
    .line-2-news { 
        padding: 15px; 
    }

    .news-container { 
        grid-template-columns: repeat(2, 1fr); /* Tetap 2 kolom di tablet-HP portrait */
        gap: 12px; /* Jarak antar card dibuat sedikit lebih rapat */
    }

    /* Atur tombol pagination agar tidak meluber keluar layar HP jika jumlah halaman banyak */
    .pagination-user {
        gap: 6px;
        margin-top: 25px;
        flex-wrap: wrap; /* Izinkan tombol turun ke bawah secara rapi jika space tidak muat */
    }

    .pagination-user a {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
}

/* --- Layar HP Kecil / Mode Potret Maksimal (Max Width: 480px) --- */
/* --- Layar HP Kecil / Mode Potret Maksimal (Max Width: 480px) --- */
@media (max-width: 480px) {
    /* SOLUSI: Mengunci grid kartu berita agar tetap 2 kolom di HP */
    .news-container { 
        grid-template-columns: repeat(2, 1fr); 
        gap: 10px; /* Jarak antar kartu sedikit dirapatkan agar pas di layar HP */
    }

    /* Rampingkan padding kontainer teks agar space tulisan lebih luas */
    .content-container {
        padding: 10px 6px;
        padding-bottom: 45px; /* Jarak aman di bawah agar judul tidak menabrak badge tanggal */
    }

    /* Sesuaikan ukuran font judul berita agar muat rapi dalam 2 kolom */
    .news-title {
        font-size: 13px;
        line-height: 1.3;
        margin-bottom: 4px;
        -webkit-line-clamp: 2; /* Tetap batasi maksimal 2 baris teks */
    }

    .news-time {
        font-size: 11px;
    }

    /* Sesuaikan ukuran badge ungu di pojok kanan bawah agar lebih minimalis */
    .meta-date-badge {
        right: 4px;
        bottom: 4px;
        padding: 3px 6px;
        min-width: 40px;
        border-radius: 4px;
    }

    .badge-text-top {
        font-size: 10px;
    }
    
    .badge-text-bottom {
        font-size: 11px;
        margin-top: 1px;
        padding-top: 1px;
    }
}