.berita-section {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    padding: 60px 20px;
    min-height: 100vh;
}

.berita-container {
    max-width: 1200px;
    margin: 0 auto;
}

/* ================= HEADER ================= */
.berita-header {
    text-align: center;
    margin-bottom: 50px;
    animation: fadeInDown 0.6s ease-out;
}

.berita-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.berita-title i {
    font-size: 2.8rem;
    color: #3498db;
}

.berita-subtitle {
    font-size: 1.1rem;
    color: #7f8c8d;
    margin-top: 10px;
    font-weight: 500;
}

/* ================= GRID ================= */
.berita-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 30px;
    animation: fadeInUp 0.6s ease-out;
}

/* ================= CARD ================= */
.berita-card {
    background: white;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.berita-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

/* ================= IMAGE (FIX UTAMA) ================= */
.card-image-wrapper {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #eaeef3; /* fallback kalau gambar gagal */
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
    z-index: 1;
}

.berita-card:hover .card-image {
    transform: scale(1.08);
}

/* Overlay gradient (TIDAK nutup gambar) */
.card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.05),
        rgba(0, 0, 0, 0.45)
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 2;
    pointer-events: none;
}

.berita-card:hover .card-overlay {
    opacity: 1;
}

/* ================= CONTENT ================= */
.card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-meta {
    margin-bottom: 12px;
}

.badge-date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: #3498db;
    font-weight: 600;
}

.badge-date i {
    font-size: 0.75rem;
}

.card-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 12px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-excerpt {
    font-size: 0.95rem;
    color: #7f8c8d;
    line-height: 1.6;
    margin: 0 0 20px 0;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ================= BUTTON ================= */
.btn-read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    align-self: flex-start;
}

.btn-read-more:hover {
    background: linear-gradient(135deg, #2980b9, #1a5a7a);
    transform: translateX(4px);
    gap: 12px;
}

.btn-read-more i {
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}

.btn-read-more:hover i {
    transform: translateX(2px);
}

/* ================= EMPTY ================= */
.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 80px 40px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* ================= ANIMATION ================= */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ================= RESPONSIVE ================= */
@media (max-width: 768px) {
    .berita-title {
        font-size: 1.8rem;
    }

    .berita-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .berita-section {
        padding: 40px 15px;
    }

    .card-content {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .berita-title {
        font-size: 1.5rem;
        flex-direction: column;
        gap: 8px;
    }

    .card-title {
        font-size: 1.15rem;
    }

    .empty-state {
        padding: 60px 20px;
    }
}
