/*=================================
KATEGORI
SAMA DENGAN HALAMAN BERITA
==================================*/

.kategori-wrapper{

    display:grid;

    grid-template-columns:2fr 1fr;

    gap:22px;

    width:100%;
    max-width:1200px;

    margin:0 auto;

    padding:15px 12px 25px;

    overflow:visible;

}

.kategori-content{

    width:100%;

    min-width:0;

    overflow:visible;

}

.kategori-sidebar{

    width:100%;

    min-width:0;

    align-self:start;

}

.kategori-sidebar-inner{

    position:sticky;

    top:90px;

    display:flex;

    flex-direction:column;

    gap:25px;

}


/*==================================
FEATURED NEWS
===================================*/

.featured-news{
    margin-bottom:35px;
}

.featured-image{
    position:relative;
    display:block;
    width:100%;
    height:430px;
    overflow:hidden;
    border-radius:16px;
    background:#f1f5f9;
    box-shadow:0 10px 30px rgba(15,23,42,.08);
}

.featured-image img{
    width:100%;
    height:100%;
    object-fit:cover;
    transition:.45s;
}

.featured-image:hover img{
    transform:scale(1.05);
}


/*==================================
Overlay
===================================*/

.featured-overlay{

    position:absolute;
    left:0;
    right:0;
    bottom:0;

    padding:28px;

    background:linear-gradient(
        to top,
        rgba(0,0,0,.78) 0%,
        rgba(0,0,0,.35) 45%,
        rgba(0,0,0,0) 100%
    );

}


/*==================================
Badge
===================================*/

.featured-category{
    display:flex;
    gap:8px;
    flex-wrap:wrap;
    margin-bottom:14px;
}

.featured-category span{

    display:inline-flex;
    align-items:center;
    justify-content:center;

    padding:6px 12px;

    border-radius:4px;

    background:#2563eb;

    color:#fff;

    font-size:11px;

    font-weight:700;

    text-transform:uppercase;

}


/*==================================
Judul
===================================*/

.featured-overlay h1{

    margin:0 0 12px;

    font-size:22px;

    font-weight:700;

    line-height:1.35;

    color:#fff;

}

.featured-overlay h1 a{

    display:-webkit-box;

    -webkit-box-orient:vertical;

    -webkit-line-clamp:3;

    line-clamp:3;

    overflow:hidden;

    color:#fff;

    text-decoration:none;

    transition:.3s;

}

.featured-overlay h1 a:hover{

    color:#ffcc66;

}


/*==================================
Meta
===================================*/

.featured-meta{

    color:#fff;

    font-size:13px;

    font-weight:600;

    text-transform:uppercase;

    letter-spacing:.5px;

}

@media(max-width:992px){

    .featured-image{
        height:360px;
    }

    .featured-overlay{
        padding:22px;
    }

    .featured-overlay h1{
        font-size:20px;
    }

}

@media(max-width:768px){

    .featured-image{
        height:280px;
    }

    .featured-overlay{
        padding:18px;
    }

    .featured-overlay h1{
        font-size:18px;
        -webkit-line-clamp:3;
        line-clamp:3;
    }

}

@media(max-width:480px){

    .featured-image{
        height:230px;
        border-radius:12px;
    }

    .featured-overlay{
        padding:15px;
    }

    .featured-overlay h1{
        font-size:16px;
    }

}


/*=========================
GRID BERITA KECIL
=========================*/

.small-news-grid{

    display:grid;

    grid-template-columns:repeat(4,1fr);

    gap:25px;

}

.small-news{

    border-radius:12px;
    overflow:hidden;

}

.small-thumb{

    display:block;
    overflow:hidden;
    border-radius:12px;

}

.small-thumb img{

    width:100%;
    display:block;

    transition:.4s;

}

.small-thumb:hover img{

    transform:scale(1.05);

}

.small-content{

    padding-top:14px;

}

.small-category{

    display:inline-block;

    color:#2563eb;

    font-size:13px;

    font-weight:700;

    margin-bottom:10px;

}

.small-content h3{

    margin:0;
    line-height:1.5;

}

.small-content h3 a{

    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:3;
    line-clamp:3;

    overflow:hidden;
    text-overflow:ellipsis;

    text-decoration:none;
    color:#111;
    font-size:19px;
    line-height:1.5;
    transition:.3s;

}

.small-content h3 a:hover{

    color:#2563eb;

}


/*=========================
SIDEBAR
=========================*/

.kategori-sidebar{

    min-height:700px;

}


/*=========================
TABLET
=========================*/

@media(max-width:992px){

    .kategori-wrapper{

        display:block;

    }

    .kategori-content{

        margin-bottom:35px;

    }

}


/*=========================
MOBILE
=========================*/

@media(max-width:768px){

    .kategori-wrapper{

        display:block;

    }

    .kategori-content{

        margin-bottom:35px;

    }

    .featured-image{

        height:270px;

    }

    .featured-overlay{

        padding:18px;

    }

    .featured-overlay h1{

        font-size:22px;

        line-height:1.35;

    }

}

/*=========================
HP KECIL
=========================*/

@media(max-width:480px){

    .featured-image{

        height:220px;

        border-radius:12px;

    }

    .featured-overlay{

        padding:15px;

    }

    .featured-overlay h1{

        font-size:18px;

        line-height:1.35;

    }

}

/*=================================
LAYOUT SAMA DENGAN HALAMAN BERITA
==================================*/

.featured-image,
.small-thumb{

    display:block;

}

.featured-image img,
.small-thumb img{

    width:100%;

    display:block;

}

.kategori-content{

    overflow:hidden;

}

.kategori-sidebar{

    position:sticky;

    top:90px;

    align-self:start;

}

/* ==========================================
FORCE GRID SMALL NEWS
========================================== */

.small-news-grid{

    display:grid !important;

    grid-template-columns:repeat(4,minmax(0,1fr));

    gap:22px;

}

.small-news{

    display:block;

    width:100%;

}

/* Thumbnail */

.small-thumb{

    position:relative;

    display:block;

    width:100%;

    height:120px;

    overflow:hidden;

    border-radius:10px;

    text-decoration:none;

}

.small-thumb img{

    width:100%;

    height:100%;

    object-fit:cover;

    display:block;

    transition:.35s ease;

}

.small-thumb:hover img{

    transform:scale(1.06);

}

/* Gradient */

.small-thumb::after{

    content:"";

    position:absolute;

    inset:0;

    background:linear-gradient(
        transparent 45%,
        rgba(0,0,0,.55)
    );

    pointer-events:none;

}

/* Konten */

.small-content{

    padding-top:8px;

}

.small-content h3{

    margin:0;
    line-height:1.5;

}

.small-content h3 a{

    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:3;
    line-clamp:3;

    overflow:hidden;
    text-overflow:ellipsis;

    text-decoration:none;

    color:#111827;

    font-size:16px;

    font-weight:700;

    line-height:1.45;

    transition:.3s;

}

.small-content h3 a:hover{

    color:#2563eb;

}

/* ==========================
TABLET
========================== */

@media(max-width:1100px){

    .small-news-grid{

        grid-template-columns:repeat(2,minmax(0,1fr));

        gap:20px;

    }

    .small-thumb{

        height:135px;

    }

}

/* ==========================
MOBILE
========================== */

@media(max-width:768px){

    .small-news-grid{

        grid-template-columns:repeat(2,minmax(0,1fr));

        gap:16px;

    }

    .small-thumb{

        height:120px;

    }

    .small-category{

        top:8px;

        left:8px;

        padding:4px 8px;

        font-size:9px;

    }

    .small-content{

        padding-top:8px;

    }

    .small-content h3 a{

        font-size:15px;

    }

}

/* ==========================
HP KECIL
========================== */

@media(max-width:480px){

    .small-thumb{

        height:105px;

        border-radius:8px;

    }

    .small-category{

        top:7px;

        left:7px;

        padding:4px 7px;

        font-size:8px;

    }

    .small-content h3 a{

        font-size:14px;

        line-height:1.4;

    }

}

/* ==========================================
SAMAKAN DENGAN HALAMAN BERITA
========================================== */

.kategori-container{

    width:100%;

    max-width:1300px;

    margin:0 auto;

    overflow:visible;

}

.kategori-content{

    background:transparent !important;

    border:none !important;

    box-shadow:none !important;

}

body.dark-mode .kategori-content{

    background:transparent !important;

    border:none !important;

    box-shadow:none !important;

}

/* ==========================================
CONTAINER KATEGORI FEATURED
========================================== */

.featured-category{

    display:flex;
    flex-wrap:wrap;
    gap:8px;
    margin-bottom:14px;

}

/* Badge masing-masing kategori */

.featured-category span{

    display:inline-flex;
    align-items:center;
    justify-content:center;

    padding:7px 14px;

    background:#2563eb;

    color:#fff;

    border-radius:6px;

    font-size:11px;

    font-weight:700;

    text-transform:uppercase;

    line-height:1;

    white-space:nowrap;

    box-shadow:0 4px 12px rgba(0,0,0,.18);

}

/* Posisi badge di thumbnail */

.small-category{

    position:absolute;

    top:10px;

    left:10px;

    z-index:10;

}

/* ==========================================
WARNA BERDASARKAN KATEGORI
========================================== */

/* Nasional */

.featured-category.nasional,
.small-category.nasional{

    background:#2563eb;

}

/* Daerah */

.featured-category.daerah,
.small-category.daerah{

    background:#16a34a;

}

/* Politik */

.featured-category.politik,
.small-category.politik{

    background:#dc2626;

}

/* Ekonomi */

.featured-category.ekonomi,
.small-category.ekonomi{

    background:#f59e0b;

}

/* Olahraga */

.featured-category.olahraga,
.small-category.olahraga{

    background:#0ea5e9;

}

/* Teknologi */

.featured-category.teknologi,
.small-category.teknologi{

    background:#7c3aed;

}

/* Internasional */

.featured-category.internasional,
.small-category.internasional{

    background:#db2777;

}

/* Hiburan */

.featured-category.hiburan,
.small-category.hiburan{

    background:#ec4899;

}

/* Pendidikan */

.featured-category.pendidikan,
.small-category.pendidikan{

    background:#0891b2;

}

/* Kesehatan */

.featured-category.kesehatan,
.small-category.kesehatan{

    background:#14b8a6;

}

/* Hukum */

.featured-category.hukum,
.small-category.hukum{

    background:#4b5563;

}

/* Lifestyle */

.featured-category.lifestyle,
.small-category.lifestyle{

    background:#f97316;

}

/* ==========================================
DARK MODE
========================================== */

body.dark-mode .featured-category,
body.dark-mode .small-category{

    color:#fff !important;

    box-shadow:0 4px 15px rgba(0,0,0,.45);

}

/* ==========================================
DARK MODE
========================================== */

/* Judul berita kecil */

body.dark-mode .small-content h3 a{

    color:#ffffff !important;

}

body.dark-mode .small-content h3 a:hover{

    color:#60a5fa !important;

}

/* Judul berita utama */

body.dark-mode .featured-overlay h1 a{

    color:#ffffff !important;

}

body.dark-mode .featured-overlay h1 a:hover{

    color:#93c5fd !important;

}

/*==================================
LIST BERITA
==================================*/

.kategori-list-news{

    margin-top:35px;

}

.list-news-item{

    display:flex;

    align-items:flex-start;

    gap:18px;

    padding:16px 0;

    border-top:1px solid #ececec;

}

.list-news-item:last-child{

    border-bottom:1px solid #ececec;

}

.list-thumb{

    flex:0 0 250px;

    height:140px;

    border-radius:12px;

    overflow:hidden;

}


.list-excerpt{

    margin-top:8px;

    font-size:15px;

    line-height:1.6;

    color:#555;

    display:-webkit-box;

    -webkit-box-orient:vertical;

    -webkit-line-clamp:2;

    line-clamp:2;

    overflow:hidden;

    text-overflow:ellipsis;

}

.list-thumb img{

    width:100%;

    height:100%;

    object-fit:cover;

    display:block;

    transition:.35s ease;

}

.list-thumb:hover img{

    transform:scale(1.06);

}

.list-content{

    flex:1;

    min-width:0;

}

.list-top{

    display:flex;

    flex-wrap:wrap;

    align-items:center;

    gap:4px;

    margin-bottom:4px;

}

.list-category{

    color:#2563eb;

    font-size:13px;

    font-weight:700;

    text-transform:uppercase;

}

.list-date{

    margin-left:6px;

    color:#777;

    font-size:13px;

}

.list-content h2{

    margin:0 0 8px;

    line-height:1.3;

}

.list-content h2 a{

    display:block;

    color:#111827;

    text-decoration:none;

    font-size:21px;

    font-weight:700;

    line-height:1.3;

    letter-spacing:-.2px;

    transition:.3s;

}

.list-content h2 a:hover{

    color:#2563eb;

}

.list-author{

    margin:0;

    font-size:14px;

    color:#444;

    line-height:1.45;

}

.list-desc{

    margin:0;

    font-size:15px;

    color:#555;

    line-height:1.55;

}

/*=========================
Dark Mode
=========================*/

body.dark-mode .list-news-item{

    border-color:#2c2c2c;

}

body.dark-mode .list-content h2 a{

    color:#fff;

}

body.dark-mode .list-content h2 a:hover{

    color:#60a5fa;

}

body.dark-mode .list-author,
body.dark-mode .list-desc{

    color:#d1d5db;

}

body.dark-mode .list-date{

    color:#9ca3af;

}

/*=========================
TABLET
=========================*/

@media(max-width:992px){

    .list-news-item{

        gap:14px;

        padding:14px 0;

    }

    .list-thumb{

        flex:0 0 165px;

        height:105px;

    }

    .list-top{

        margin-bottom:3px;

    }

    .list-category{

        font-size:11px;

    }

    .list-date{

        font-size:11px;

        margin-left:4px;

    }

    .list-content h2{

        margin-bottom:6px;

        line-height:1.28;

    }

    .list-content h2 a{

        font-size:18px;

        line-height:1.28;

    }

    .list-excerpt{

        display:none;

    }

}

/*=========================
MOBILE
=========================*/

@media(max-width:768px){

    .list-news-item{

        gap:10px;

        padding:12px 0;

    }

    .list-thumb{

        flex:0 0 100px;

        height:75px;

        border-radius:8px;

    }

    .list-top{

        gap:2px;

        margin-bottom:2px;

    }

    .list-category{

        font-size:9px;

    }

    .list-date{

        margin-left:3px;

        font-size:9px;

    }

    .list-content h2{

        margin-bottom:5px;

        line-height:1.25;

    }

    .list-content h2 a{

        font-size:15px;

        line-height:1.25;

    }

    .list-excerpt{

        display:none;

    }

}

/*=========================
HP KECIL
=========================*/

@media(max-width:480px){

    .list-news-item{

        gap:10px;

        padding:10px 0;

    }

    .list-thumb{

        flex:0 0 90px;

        height:68px;

    }

    .list-category{

        font-size:8px;

    }

    .list-date{

        font-size:8px;

    }

    .list-content h2{

        margin-bottom:4px;

        line-height:1.2;

    }

    .list-content h2 a{

        font-size:14px;

        line-height:1.2;

    }

    .list-excerpt{

        display:none;

    }

}

/*==================================
BANNER
==================================*/

.kategori-banner{

    width:100%;

    margin:30px 0;

    overflow:hidden;

    border-radius:12px;

    background:#f3f4f6;

}

.kategori-banner a{

    display:block;

}

.kategori-banner img{

    width:100%;

    height:auto;

    display:block;

    transition:.35s ease;

}

.kategori-banner:hover img{

    transform:scale(1.02);

}

/*=========================
Dark Mode
=========================*/

body.dark-mode .kategori-banner{

    background:#202020;

}

/*=========================
Tablet
=========================*/

@media(max-width:992px){

    .kategori-banner{

        margin:22px 0;

        border-radius:10px;

    }

}

/*=========================
Mobile
=========================*/

@media(max-width:768px){

    .kategori-banner{

        margin:18px 0;

        border-radius:8px;

    }

}

/* ==========================================
FIX JARAK MOBILE & TABLET
========================================== */

@media (max-width:992px){

    .kategori-wrapper{
        display:block !important;
    }

    .kategori-sidebar{
        display:block !important;
        position:static !important;
        min-height:auto !important;
        height:auto !important;
        margin:20px 0 15px !important;
        padding:0 !important;
    }

    .kategori-sidebar-inner{
        position:static !important;
        top:auto !important;
    }

    .kategori-list-news-2{
        margin-top:15px !important;
        padding-top:0 !important;
    }

}

body.dark-mode .list-excerpt{

    color:#d1d5db;

}

.pagination{

display:flex;

justify-content:center;

gap:8px;

margin:40px 0;

flex-wrap:wrap;

}

.pagination a{

width:42px;

height:42px;

display:flex;

align-items:center;

justify-content:center;

border-radius:8px;

text-decoration:none;

background:#fff;

border:1px solid #ddd;

font-weight:600;

color:#222;

transition:.25s;

}

.pagination a:hover{

background:#e60000;

color:#fff;

}

.pagination a.active{

background:#e60000;

color:#fff;

border-color:#e60000;

}

/* ==========================================
   SKELETON LOADING
========================================== */

.load-more-loader{
    display:none;
    flex-direction:column;
    gap:24px;
    margin:30px 0;
}

.skeleton-news{
    display:flex;
    gap:18px;
    align-items:flex-start;
}

.skeleton-thumb{
    width:240px;
    height:150px;
    border-radius:10px;
    overflow:hidden;
    position:relative;
    background:#ececec;
    flex-shrink:0;
}

.skeleton-content{
    flex:1;
}

.skeleton-line{
    height:14px;
    border-radius:6px;
    background:#ececec;
    margin-bottom:14px;
    position:relative;
    overflow:hidden;
}

.skeleton-line.short{
    width:110px;
}

.skeleton-line.medium{
    width:70%;
}

.skeleton-line:not(.short):not(.medium){
    width:100%;
}

/* Efek Shimmer */

.skeleton-thumb::after,
.skeleton-line::after{

    content:'';

    position:absolute;

    top:0;
    left:-150%;

    width:60%;
    height:100%;

    background:linear-gradient(
        90deg,
        transparent,
        rgba(255,255,255,.8),
        transparent
    );

    animation:skeletonShimmer 1.2s infinite;

}

@keyframes skeletonShimmer{

    100%{
        left:160%;
    }

}

/* ==========================================
   ANIMASI BERITA BARU
========================================== */

.list-news-item.new-item{

    opacity:0;

    transform:translateY(30px);

    animation:fadeNews .45s ease forwards;

}

@keyframes fadeNews{

    from{

        opacity:0;

        transform:translateY(30px);

    }

    to{

        opacity:1;

        transform:translateY(0);

    }

}
