/* ============================================
   NEWS STYLE - Khusus Konten Berita
   (Tanpa Navbar/Header)
   ============================================ */

/* ============================================
   ROOT VARIABLES
   ============================================ */
:root {
    --primary: #0056b3;
    --primary-dark: #003d82;
    --primary-light: #e8f0fe;
    --secondary: #f59e0b;
    --success: #10b981;
    --danger: #dc2626;
    --dark: #1a1a2e;
    --text: #2c3e50;
    --text-light: #666;
    --gray: #888;
    --gray-light: #f5f7fa;
    --border: #e8e8e8;
    --white: #ffffff;
    --shadow: 0 2px 15px rgba(0,0,0,0.08);
    --shadow-hover: 0 8px 30px rgba(0,0,0,0.12);
    --radius: 12px;
    --transition: all 0.3s ease;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ============================================
   RESET & BASE
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font);
    line-height: 1.6;
    color: var(--text);
    background-color: var(--gray-light);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   FEATURED SECTION
   ============================================ */
.featured-section {
    padding: 30px 0 20px;
}

.featured-article {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.featured-image {
    position: relative;
    min-height: 380px;
    background: var(--gray-light);
    overflow: hidden;
}

.featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}

.featured-label {
    position: absolute;
    top: 16px;
    left: 16px;
    background: var(--secondary);
    color: white;
    padding: 4px 16px;
    border-radius: 25px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 10px rgba(245, 158, 11, 0.3);
    z-index: 2;
}

.featured-content {
    padding: 35px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.category-badge {
    display: inline-block;
    margin-bottom: 12px;
}

.category-badge a {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 4px 16px;
    border-radius: 25px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: background 0.3s ease;
}

.category-badge a:hover {
    background: var(--primary-dark);
}

.featured-content h1 {
    font-size: 2rem;
    line-height: 1.2;
    margin-bottom: 12px;
}

.featured-content h1 a {
    color: var(--dark);
    transition: color 0.3s ease;
}

.featured-content h1 a:hover {
    color: var(--primary);
}

.featured-excerpt {
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 16px;
    font-size: 1.05rem;
}

.featured-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    color: var(--gray);
    font-size: 0.85rem;
    margin-bottom: 16px;
}

.featured-meta i {
    margin-right: 5px;
    color: var(--primary);
}

.read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 600;
    font-size: 0.95rem;
}

.read-more:hover {
    gap: 14px;
}

/* ============================================
   LATEST NEWS SECTION
   ============================================ */
.latest-news {
    padding: 30px 0 40px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.section-header h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--dark);
}

.section-header h2 i {
    color: var(--primary);
    margin-right: 10px;
}

.section-subtitle {
    color: var(--gray);
    font-size: 0.9rem;
    margin-top: 4px;
}

.view-all {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 600;
    white-space: nowrap;
}

.view-all:hover {
    gap: 12px;
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.news-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.news-image {
    position: relative;
    padding-bottom: 65%;
    overflow: hidden;
    background: var(--gray-light);
}

.news-image a {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.featured-tag {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    background: var(--secondary);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    box-shadow: 0 2px 10px rgba(245, 158, 11, 0.3);
}

.news-content {
    padding: 18px 20px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-content h3 {
    font-size: 1.05rem;
    line-height: 1.4;
    margin-bottom: 10px;
}

.news-content h3 a {
    color: var(--dark);
    transition: color 0.3s ease;
}

.news-content h3 a:hover {
    color: var(--primary);
}

.news-content p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 14px;
    flex: 1;
}

.news-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.8rem;
    color: var(--gray);
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.news-meta a {
    color: var(--primary);
    font-weight: 500;
}

.news-meta a:hover {
    text-decoration: underline;
}

.news-meta i {
    margin-right: 4px;
}

/* ============================================
   CATEGORY SECTION
   ============================================ */
.category-section {
    padding: 40px 0;
    background: var(--gray-light);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.category-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 25px 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.category-link {
    display: block;
    text-decoration: none;
    color: var(--dark);
}

.category-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary);
    margin: 0 auto 14px;
    transition: all 0.3s ease;
}

.category-card:hover .category-icon {
    background: var(--primary);
    color: white;
    transform: scale(1.05);
}

.category-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.category-view-all {
    display: inline-block;
    color: var(--primary);
    font-weight: 500;
    font-size: 0.85rem;
}

/* ============================================
   POPULAR SECTION
   ============================================ */
.popular-section {
    padding: 40px 0;
}

.popular-wrapper {
    background: var(--white);
    border-radius: var(--radius);
    padding: 30px;
    box-shadow: var(--shadow);
}

.popular-header {
    margin-bottom: 20px;
}

.popular-header h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--dark);
}

.popular-header h2 i {
    color: var(--danger);
    margin-right: 10px;
    animation: pulse-fire 2s infinite;
}

@keyframes pulse-fire {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

.popular-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.popular-item {
    display: flex;
    gap: 15px;
    padding: 14px 0;
    border-bottom: 1px solid var(--gray-light);
    align-items: flex-start;
}

.popular-item:last-child {
    border-bottom: none;
}

.popular-rank {
    flex-shrink: 0;
    width: 35px;
}

.rank-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: var(--gray-light);
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--gray);
}

.rank-number.rank-top {
    color: white;
}

.popular-item:nth-child(1) .rank-number.rank-top {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.popular-item:nth-child(2) .rank-number.rank-top {
    background: linear-gradient(135deg, #94a3b8, #cbd5e1);
    box-shadow: 0 4px 15px rgba(148, 163, 184, 0.3);
}

.popular-item:nth-child(3) .rank-number.rank-top {
    background: linear-gradient(135deg, #d97706, #f59e0b);
    box-shadow: 0 4px 15px rgba(217, 119, 6, 0.3);
}

.popular-content {
    flex: 1;
}

.popular-title {
    color: var(--dark);
    font-weight: 500;
    display: block;
    margin-bottom: 4px;
    transition: color 0.3s ease;
}

.popular-title:hover {
    color: var(--primary);
}

.popular-meta {
    display: flex;
    gap: 14px;
    font-size: 0.8rem;
    color: var(--gray);
    flex-wrap: wrap;
}

.popular-meta i {
    margin-right: 4px;
}

/* ============================================
   NEWSLETTER SECTION
   ============================================ */
.newsletter-section {
    padding: 45px 0;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    margin-top: 20px;
}

.newsletter-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
}

.newsletter-content {
    flex: 1;
}

.newsletter-content h2 {
    font-size: 1.5rem;
    margin-bottom: 6px;
}

.newsletter-content h2 i {
    margin-right: 10px;
}

.newsletter-content p {
    opacity: 0.9;
    margin: 0;
}

.newsletter-form {
    flex: 1;
    max-width: 500px;
}

.newsletter-form .form-group {
    display: flex;
    gap: 10px;
}

.newsletter-form input {
    flex: 1;
    padding: 12px 18px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    outline: none;
    font-family: var(--font);
}

.newsletter-form input:focus {
    box-shadow: 0 0 0 3px rgba(255,255,255,0.3);
}

.btn-subscribe {
    padding: 12px 25px;
    background: var(--secondary);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
    white-space: nowrap;
    font-family: var(--font);
}

.btn-subscribe:hover {
    background: #d97706;
}

.newsletter-form small {
    display: block;
    margin-top: 8px;
    opacity: 0.8;
    font-size: 0.8rem;
}

.newsletter-form small i {
    margin-right: 5px;
}

/* ============================================
   PAGINATION
   ============================================ */
.pagination {
    margin-top: 35px;
    display: flex;
    justify-content: center;
}

.pagination ul {
    display: flex;
    list-style: none;
    gap: 5px;
    flex-wrap: wrap;
    padding: 0;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    background: var(--white);
    color: var(--dark);
    border-radius: 8px;
    font-weight: 500;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.pagination a:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.pagination a.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.pagination span {
    border: none;
    background: transparent;
}

/* ============================================
   EMPTY STATE
   ============================================ */
.empty-state {
    text-align: center;
    padding: 60px 20px;
}

.empty-state i {
    font-size: 3.5rem;
    color: #ccc;
    margin-bottom: 15px;
}

.empty-state p {
    color: var(--gray);
    font-size: 1.1rem;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    background: var(--dark);
    color: #ffffff;
    padding: 40px 0 20px;
    margin-top: 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-section h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.footer-section p {
    color: #aaa;
    font-size: 0.95rem;
}

.footer-bottom {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    color: #888;
    font-size: 0.85rem;
}

.footer-bottom a {
    color: var(--gray);
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Tablet: 768px - 991px */
@media (max-width: 991px) and (min-width: 768px) {
    .featured-article {
        grid-template-columns: 1fr;
    }
    
    .featured-image {
        min-height: 300px;
        height: 300px;
    }
    
    .featured-content {
        padding: 30px;
    }
    
    .featured-content h1 {
        font-size: 1.6rem;
    }
    
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile: < 768px */
@media (max-width: 767px) {
    .featured-article {
        grid-template-columns: 1fr;
    }
    
    .featured-image {
        min-height: 200px;
        height: 200px;
    }
    
    .featured-content {
        padding: 20px;
    }
    
    .featured-content h1 {
        font-size: 1.3rem;
    }
    
    .featured-excerpt {
        font-size: 0.95rem;
    }
    
    .featured-meta {
        gap: 12px;
        font-size: 0.8rem;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .section-header h2 {
        font-size: 1.3rem;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    
    .news-content h3 {
        font-size: 1rem;
    }
    
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .category-card {
        padding: 18px 14px;
    }
    
    .category-icon {
        width: 48px;
        height: 48px;
        font-size: 1.2rem;
    }
    
    .popular-wrapper {
        padding: 18px;
    }
    
    .popular-item {
        flex-direction: column;
        gap: 6px;
        padding: 12px 0;
    }
    
    .popular-rank {
        width: auto;
    }
    
    .newsletter-wrapper {
        flex-direction: column;
        text-align: center;
    }
    
    .newsletter-form {
        max-width: 100%;
        width: 100%;
    }
    
    .newsletter-form .form-group {
        flex-direction: column;
    }
    
    .pagination a,
    .pagination span {
        min-width: 34px;
        height: 34px;
        font-size: 0.85rem;
        padding: 0 10px;
    }
}

/* Small Mobile: < 480px */
@media (max-width: 480px) {
    .container {
        padding: 0 14px;
    }
    
    .featured-image {
        min-height: 160px;
        height: 160px;
    }
    
    .featured-content {
        padding: 16px;
    }
    
    .featured-content h1 {
        font-size: 1.1rem;
    }
    
    .category-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    
    .category-card {
        padding: 14px 10px;
        border-radius: 10px;
    }
    
    .category-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .category-card h3 {
        font-size: 0.85rem;
    }
    
    .news-content {
        padding: 14px 16px 16px;
    }
    
    .news-content h3 {
        font-size: 0.95rem;
    }
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.news-card {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
}

.news-card:nth-child(1) { animation-delay: 0.05s; }
.news-card:nth-child(2) { animation-delay: 0.1s; }
.news-card:nth-child(3) { animation-delay: 0.15s; }
.news-card:nth-child(4) { animation-delay: 0.2s; }
.news-card:nth-child(5) { animation-delay: 0.25s; }
.news-card:nth-child(6) { animation-delay: 0.3s; }
.news-card:nth-child(7) { animation-delay: 0.35s; }
.news-card:nth-child(8) { animation-delay: 0.4s; }
.news-card:nth-child(9) { animation-delay: 0.45s; }