/* =========================================
   MODIFIKASI WIDGET CUSTOM HTML
   ========================================= */

.widget_custom_html {
    background-color: #f0f0f1;
    min-height: 250px;
    margin-bottom: 24px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

/* Style untuk Label Advertisement */
.widget_custom_html .ad-label {
    color: #9ca3af;
    font-family: 'Barlow', sans-serif;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin: 0;
}

/* Reset List di dalam Custom HTML */
.widget_custom_html ul {
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
}

.widget_custom_html ul li {
    margin: 0;
    padding: 0;
}

/* Widget Gambar Media */
.widget_media_image {
    margin-bottom: 20px;
}

/* ============================================
   WIDGET TERPOPULER
   ============================================ */

.terpopuler-widget {
    background: #ffffff;
    border-radius: 12px;
    margin-bottom: 24px;
}

/* ===== HEADER ===== */
.terpopuler-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    padding-bottom: 12px;
    
}

.terpopuler-accent {
    display: inline-block;
    width: 5px;
    height: 22px;
    background: #d32f2f;
    border-radius: 2px;
    transform: skewX(-15deg);
    flex-shrink: 0;
}

.terpopuler-title {
    font-size: 20px;
    font-weight: 900;
    font-style: italic;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0;
}

/* ===== LIST POSTINGS ===== */
.terpopuler-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.terpopuler-item {
    display: flex;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    padding-bottom: 16px;
    position: relative; /* Diperlukan untuk pseudo-element */
    transition: all 0.2s ease;
    align-items: center;
}

/* Garis dashed menggunakan teknik ::after */
.terpopuler-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    border-bottom: 1px dashed #ccc;
}

.terpopuler-item:last-child {
    padding-bottom: 0;
}

/* Hilangkan garis pada item terakhir */
.terpopuler-item:last-child::after {
    display: none;
}

.terpopuler-item:hover {
    transform: translateX(4px);
}
.terpopuler-thumb {
    flex-shrink: 0;
    width: 90px;
    height: 90px;
    border-radius: 8px;
    overflow: hidden;
    background: #f5f5f5;
}

.terpopuler-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.terpopuler-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

 
  .terpopuler-title-post {
    font-family: Barlow, sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 22px;
    letter-spacing: 0.4px;
    color: #1a1a1a;
    margin: 0 !important; /* ✅ Hapus margin default */
    padding: 0 !important; /* ✅ Hapus padding jika ada */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
 

.terpopuler-item:hover .terpopuler-title-post {
    color: #d32f2f;
}

.terpopuler-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    margin-top: 12px;
}

.terpopuler-category {
    background: #ddd;
    color: #000;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 600;
}

.terpopuler-date {
    color: #999;
    font-weight: 500;
}

/* ===== BUTTON SELENGKAPNYA ===== */
.terpopuler-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #d32f2f;
    color: #fff;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 20px;
    transition: all 0.25s ease;
}

.terpopuler-button svg {
    width: 16px;
    height: 16px;
    transition: transform 0.25s ease;
}

.terpopuler-button:hover {
    background: #b71c1c;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(211, 47, 47, 0.3);
}

.terpopuler-button:hover svg {
    transform: translateX(4px);
}

/* ===== RESPONSIVE MOBILE ===== */
@media (max-width: 480px) {
    .terpopuler-widget {
        padding: 16px;
        border-radius: 10px;
    }

    .terpopuler-title {
        font-size: 18px;
    }

    .terpopuler-accent {
        height: 28px;
    }

    .terpopuler-item {
        gap: 10px;
    }

    .terpopuler-thumb {
        width: 80px;
        height: 80px;
    }

    .terpopuler-title-post {
        font-size: 13px;
    }

    .terpopuler-button {
        padding: 12px 16px;
        font-size: 13px;
    }
}

@media (max-width: 360px) {
    .terpopuler-widget {
        padding: 14px;
    }

    .terpopuler-title {
        font-size: 16px;
    }

    .terpopuler-thumb {
        width: 70px;
        height: 70px;
    }

    .terpopuler-title-post {
        font-size: 12px;
        -webkit-line-clamp: 3;
    }
}

/* ============================================
   FEATURED ITEM (POST PERTAMA)
   ============================================ */
.terpopuler-item.featured {
    flex-direction: column; /* Ubah jadi vertikal: gambar di atas, teks di bawah */
    padding-bottom: 20px;
    margin-bottom: 4px; /* Jarak ekstra sebelum item berikutnya */
}

/* Gambar lebih besar untuk post pertama */
.terpopuler-item.featured .terpopuler-thumb {
    width: 100%;
    height: 180px; /* Tinggi gambar featured */
}

/* Judul sedikit lebih besar untuk post pertama */
.terpopuler-item.featured .terpopuler-title-post {
    font-size: 18px;
    margin-top: 10px;
    -webkit-line-clamp: 3; /* Batasi 2 baris agar rapi */
}

/* Meta data (kategori/tanggal) */
.terpopuler-item.featured .terpopuler-meta {
    margin-top: 6px;
}

/* Responsive untuk Mobile */
@media (max-width: 480px) {
    .terpopuler-item.featured .terpopuler-thumb {
        height: 150px;
    }
    .terpopuler-item.featured .terpopuler-title-post {
        font-size: 15px;
    }
}

/* ============================================
   WIDGET TAG POPULER (ISU TERKINI)
   Style persis seperti gambar referensi
   ============================================ */

.tag-populer-list {
    display: flex;
    flex-direction: column;
}

.tag-populer-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    text-decoration: none;
    color: inherit;
    position: relative;
    transition: all 0.2s ease;
}

/* Garis dashed di bawah setiap item */
.tag-populer-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    border-bottom: 1px dashed #ccc;
}

/* Hilangkan garis pada item terakhir */
.tag-populer-item:last-child::after {
    display: none;
}

.tag-populer-item:last-child {
    padding-bottom: 0;
}

.tag-populer-item:hover {
    transform: translateX(4px);
}

/* Nomor urut besar, bold, italic, warna merah */
.tag-number {
    font-size: 32px;
    font-weight: 900;
 
    color: #d32f2f;
    line-height: 1;
    flex-shrink: 0;
    letter-spacing: -1px;
}

/* Nama tag - bold hitam */
.tag-name {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    flex: 1;
}

.tag-populer-item:hover .tag-name {
    color: #d32f2f;
}

/* Responsive Mobile */
@media (max-width: 480px) {
    .tag-number {
        font-size: 20px;
    }
    
    .tag-name {
        font-size: 18px;
    }
    
    .tag-populer-item {
        gap: 12px;
        padding: 10px 0;
    }
}

@media (max-width: 360px) {
    .tag-number {
        font-size: 22px;
    }
    
    .tag-name {
        font-size: 16px;
    }
    
    .tag-populer-item {
        gap: 10px;
    }
}
 