/* ============================================
   CATEGORY PAGE - DESKTOP LAYOUT
   ============================================ */

/* Layout Grid Utama: Konten + Sidebar */
.category-grid-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    align-items: start;
}

.home-index { min-width: 0; }

.desktop-sidebar {
    position: sticky;
    top: 100px;
}

/* ============================================
   CATEGORY HEADER
   ============================================ */
.category-header {
     
}

.category-breadcrumb {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
}

.category-breadcrumb a { color: #666; transition: color 0.2s ease; }
.category-breadcrumb a:hover { color: #d32f2f; }
.category-breadcrumb .separator { margin: 0 8px; color: #ccc; }
.category-breadcrumb .current-cat { color: #d32f2f; font-weight: 600; }

.category-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0 0 10px 0;
    line-height: 1.2;
    text-transform: capitalize;
    font-family: 'Manrope', sans-serif;
}

.category-description {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
    max-width: 800px;
}

/* ============================================
   FEATURED LAYOUT (TINGGI 450px PRESISI)
   ============================================ */
.category-featured-layout {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 24px;
    height: 450px;
    margin-bottom: 40px;
      overflow: hidden;
}

/* Featured Main (Kiri) */
.featured-main {
    display: flex;
    flex-direction: column;
    height: 100%;
    
}

.featured-thumb {
    display: block;
    width: 100%;
    height: 310px;
    min-height: 310px;
    overflow: hidden;
    border-radius: 8px;
    background: #f5f5f5;
    margin-bottom: 16px;
    flex-shrink: 0;
}

.featured-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.featured-thumb:hover img { transform: scale(1.03); }

.featured-content { display: flex; flex-direction: column; flex: 1; overflow: hidden; }

.featured-category {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    color: #d32f2f;
    text-transform: capitalize;
    margin-bottom: 8px;
    line-height: 1;
    flex-shrink: 0;
}

.featured-title {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.3;
    margin: 0;
    color: #1a1a1a;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.featured-title a { color: #1a1a1a; text-decoration: none; transition: color 0.2s ease; }
.featured-title a:hover { color: #d32f2f; }

/* Featured Side List (Kanan) */
.featured-side-list {
    display: flex;
    flex-direction: column;
    height: 100%;
    gap: 12px;
    overflow: hidden;
}

.side-list-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.side-list-thumb {
    display: block;
    width: 120px;
    min-width: 120px;
    height: 95px;
    overflow: hidden;
    border-radius: 6px;
    background: #f5f5f5;
    flex-shrink: 0;
}

.side-list-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.side-list-thumb:hover img { transform: scale(1.05); }
.no-thumb-small { width: 100%; height: 100%; background: #e8e8e8; }

.side-list-content { display: flex; flex-direction: column; flex: 1; min-width: 0; overflow: hidden; justify-content: flex-start; padding-top: 2px; }

.side-list-category {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    color: #d32f2f;
    text-transform: capitalize;
    margin-bottom: 4px;
    line-height: 1;
    flex-shrink: 0;
}

.side-list-title {
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.side-list-title a { color: #1a1a1a; text-decoration: none; transition: color 0.2s ease; }
.side-list-title a:hover { color: #d32f2f; }

/* ============================================
   LATEST NEWS LIST (POST KE-6 dst)
   ============================================ */
.latest-news-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
     
}

.latest-news-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #d32f2f;
    border-radius: 6px;
    flex-shrink: 0;
}

.latest-news-icon svg { width: 18px; height: 18px; }

.latest-news-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0;
    font-family: 'Manrope', sans-serif;
}

.category-list-wrapper { display: flex; flex-direction: column; }

.category-list-item {
    display: flex;
    gap: 16px;
    padding: 20px 0;
    border-bottom: 1px solid #f0f0f0;
    align-items: flex-start;
    transition: background 0.2s ease;
}

.category-list-item:first-child { padding-top: 0; }
.category-list-item:last-child { border-bottom: none; }

.category-list-item:hover {
    background: #fafafa;
    margin: 0 -16px;
    padding-left: 16px;
    padding-right: 16px;
    border-radius: 8px;
}

.list-item-thumb {
    display: block;
    width: 140px;
    min-width: 140px;
    height: 100px;
    overflow: hidden;
    border-radius: 8px;
    background: #f5f5f5;
    flex-shrink: 0;
}

.list-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.category-list-item:hover .list-item-thumb img { transform: scale(1.05); }

.no-thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
}

.no-thumb-placeholder svg { width: 32px; height: 32px; }

.list-item-content { display: flex; flex-direction: column; flex: 1; min-width: 0; }

.list-item-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    gap: 12px;
}

.list-item-category {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    color: #d32f2f;
    text-transform: capitalize;
    line-height: 1;
    flex-shrink: 0;
}

.list-item-time {
    font-size: 0.8rem;
    color: #888;
    font-weight: 400;
    flex-shrink: 0;
}

.list-item-title {
    font-size: 1.15rem;
    font-weight: 800;
    line-height: 1.35;
    margin: 0;
    color: #1a1a1a;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.list-item-title a { color: #1a1a1a; text-decoration: none; transition: color 0.2s ease; }
.list-item-title a:hover { color: #d32f2f; }

/* ============================================
   PAGINATION & EMPTY STATE
   ============================================ */
.category-pagination {
    margin-top: 40px;
    display: flex;
    justify-content: center;
}

.category-pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }

.category-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    background: #fff;
}

.category-pagination .page-numbers:hover { border-color: #d32f2f; color: #d32f2f; }
.category-pagination .page-numbers.current { background: #d32f2f; border-color: #d32f2f; color: #fff; }

.no-posts-found {
    text-align: center;
    padding: 80px 20px;
    background: #fafafa;
    border-radius: 8px;
    border: 1px dashed #e8e8e8;
    color: #666;
    font-size: 1.1rem;
}

/* ============================================
   SEMBUNYIKAN IKLAN DI MOBILE (CATEGORY PAGE)
   ============================================ */
@media (max-width: 767px) {

    /* Sembunyikan Ads Top */
    .category-page .ads-top,
    .category-page [class*="ads-top"],
    .category-page .ad-top,
    .category-page .top-ad,
    .category-page .ads-wrapper-top {
        display: none !important;
    }

    /* Sembunyikan Ads Center */
    .category-page .ads-center,
    .category-page [class*="ads-center"],
    .category-page .ad-center,
    .category-page .center-ad,
    .category-page .ads-wrapper-center {
        display: none !important;
    }

    /* Fallback: Sembunyikan semua elemen iklan di dalam category page */
    .category-page .ads,
    .category-page .ad,
    .category-page [class*="advertisement"],
    .category-page [class*="ads-"],
    .category-page [class*="ad-"] {
        display: none !important;
    }
}