/* =========================================================
   UPDATE BERITA
   Program Studi Sistem Informasi UNCEN
========================================================= */


/* =========================================================
   1. HALAMAN DAFTAR BERITA
========================================================= */

.public-news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.public-news-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(15, 55, 100, .07);
}

.public-news-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.public-news-card > div {
    padding: 22px;
}

.public-news-card h2 {
    font-size: 1.25rem;
    line-height: 1.35;
    margin: 8px 0;
}

.public-news-card h2 a {
    color: var(--ink);
    text-decoration: none;
}

.public-news-card h2 a:hover {
    color: #0b4da2;
}

.public-news-card p {
    color: var(--muted);
    line-height: 1.7;
}


/* =========================================================
   2. HALAMAN DETAIL BERITA
========================================================= */

.article-page {
    padding: 80px 0;
}

.article-container {
    max-width: 900px;
}

.article-container h1 {
    font-family: "Merriweather", serif;
    font-size: clamp(2rem, 5vw, 3.8rem);
    line-height: 1.15;
    margin: 14px 0 10px;
}

.article-author {
    color: var(--muted);
}

.article-cover {
    width: 100%;
    max-height: 520px;
    object-fit: cover;
    border-radius: 20px;
    margin: 30px 0;
}

.article-content {
    font-size: 1.08rem;
    line-height: 1.9;
    color: #2a374c;
}

.article-content br {
    display: block;
    content: "";
    margin-top: 12px;
}


/* =========================================================
   3. HOMEPAGE - AREA BERITA
========================================================= */

/*
   Berita utama berada di kiri.
   Berita lainnya berada di sebelah kanan.
*/

.news-grid {
    align-items: stretch;
}


/* =========================================================
   4. BERITA SAMPING HOMEPAGE
========================================================= */

.news-side {
    display: flex;
    flex-direction: column;
    gap: 0;

    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;

    overflow: hidden;
}


/* Setiap berita kecil */

.mini-news {
    display: grid;
    grid-template-columns: 145px 1fr;
    gap: 18px;

    align-items: center;

    padding: 18px;

    border-bottom: 1px solid #e5eaf1;

    background: #fff;
}

.mini-news:last-child {
    border-bottom: none;
}


/* =========================================================
   5. GAMBAR BERITA KECIL
========================================================= */

.mini-news-image {
    display: block;

    width: 145px;
    height: 105px;

    border-radius: 13px;

    overflow: hidden;

    background: #edf4fb;

    text-decoration: none;
}


/* gambar */

.mini-news-image img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    display: block;

    transition:
        transform .35s ease,
        filter .35s ease;
}


/* hover */

.mini-news:hover .mini-news-image img {
    transform: scale(1.06);
}


/* =========================================================
   6. PLACEHOLDER JIKA BERITA TIDAK PUNYA GAMBAR
========================================================= */

.mini-news-placeholder {
    width: 100%;
    height: 100%;

    display: flex;

    align-items: center;
    justify-content: center;

    background:
        linear-gradient(
            135deg,
            #eef5fc,
            #dfeefa
        );

    color: #0b4da2;

    font-size: 28px;
}


/* =========================================================
   7. CONTENT BERITA KECIL
========================================================= */

.mini-news-content {
    min-width: 0;
}


/* kategori + tanggal */

.mini-news-content > span {
    display: block;

    margin-bottom: 8px;

    color: #0b4da2;

    font-size: 11px;
    font-weight: 800;

    line-height: 1.5;

    letter-spacing: .04em;

    text-transform: uppercase;
}


/* judul */

.mini-news-content h3 {
    margin: 0;

    font-size: 16px;
    font-weight: 800;

    line-height: 1.45;
}


/* link judul */

.mini-news-content h3 a {
    color: var(--ink);

    text-decoration: none;

    transition: color .2s ease;
}

.mini-news-content h3 a:hover {
    color: #0b4da2;
}


/* =========================================================
   8. FEATURED NEWS HOMEPAGE
========================================================= */

.feature-news {
    overflow: hidden;
}


/* gambar utama */

.feature-news > img {
    width: 100%;

    display: block;

    object-fit: cover;
}


/* =========================================================
   9. TABLET
========================================================= */

@media (max-width: 900px) {

    /* halaman berita */

    .public-news-grid {
        grid-template-columns: 1fr 1fr;
    }


    /* berita samping */

    .mini-news {
        grid-template-columns: 130px 1fr;

        gap: 15px;
    }

    .mini-news-image {
        width: 130px;
        height: 95px;
    }

}


/* =========================================================
   10. MOBILE
========================================================= */

@media (max-width: 640px) {

    /* halaman daftar berita */

    .public-news-grid {
        grid-template-columns: 1fr;
    }


    /* detail berita */

    .article-page {
        padding: 45px 0;
    }


    /* card berita kecil */

    .mini-news {
        grid-template-columns: 105px 1fr;

        gap: 13px;

        padding: 14px;
    }


    /* thumbnail */

    .mini-news-image {
        width: 105px;
        height: 82px;

        border-radius: 10px;
    }


    /* meta */

    .mini-news-content > span {
        font-size: 9px;

        margin-bottom: 5px;
    }


    /* judul */

    .mini-news-content h3 {
        font-size: 14px;

        line-height: 1.4;
    }

}


/* =========================================================
   11. MOBILE SANGAT KECIL
========================================================= */

@media (max-width: 420px) {

    .mini-news {
        grid-template-columns: 90px 1fr;

        gap: 11px;
    }

    .mini-news-image {
        width: 90px;
        height: 72px;
    }

    .mini-news-content h3 {
        font-size: 13px;
    }

}
/* =========================================================
   FIX HEADER HALAMAN BERITA
========================================================= */

body.inner-page .site-header.inner-header {
    background: #ffffff !important;
    border-bottom: 1px solid #e6edf5 !important;
    box-shadow: 0 4px 20px rgba(15, 55, 100, 0.06) !important;
}

body.inner-page .site-header.inner-header .brand-kicker {
    color: #0b4da2 !important;
}

body.inner-page .site-header.inner-header .brand strong {
    color: #142033 !important;
}

body.inner-page .site-header.inner-header .nav-menu a {
    color: #142033 !important;
}

body.inner-page .site-header.inner-header .nav-menu a:hover {
    color: #0b4da2 !important;
}

body.inner-page .site-header.inner-header .nav-menu a.active {
    color: #0b4da2 !important;
}

body.inner-page .site-header.inner-header .nav-menu a.active::after {
    background: #0b4da2 !important;
}

body.inner-page .site-header.inner-header .nav-toggle {
    color: #142033 !important;
}