/* ============================================
   KABAR NUSANTARA - Media Online Portal
   Premium News Portal Stylesheet
   ============================================ */

/* --- CSS Variables / Design Tokens --- */
:root {
    --primary: #1a3a5c;
    --primary-dark: #0f2440;
    --primary-light: #2a5a8c;
    --accent: #e63946;
    --accent-dark: #c1121f;
    --accent-light: #ff6b6b;
    --gold: #f0a500;
    --gold-light: #ffc947;
    --bg-body: #f0f2f5;
    --bg-white: #ffffff;
    --bg-card: #ffffff;
    --bg-dark: #1a1a2e;
    --text-primary: #1a1a2e;
    --text-secondary: #555770;
    --text-muted: #8b8fa3;
    --text-white: #ffffff;
    --border-light: #e4e6ea;
    --border-medium: #d1d5db;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 12px 40px rgba(0, 0, 0, 0.15);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    --font-heading: 'Merriweather', Georgia, serif;
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background: var(--bg-body);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Top Bar --- */
.top-bar {
    background: var(--primary-dark);
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.78rem;
    padding: 6px 0;
    border-bottom: 2px solid var(--accent);
}

.top-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.top-bar-left i {
    color: var(--gold);
    margin-right: 4px;
}

.top-bar-divider {
    opacity: 0.3;
}

.top-bar-right {
    display: flex;
    gap: 6px;
}

.top-bar-right a {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.72rem;
    transition: all var(--transition);
}

.top-bar-right a:hover {
    background: var(--accent);
    color: var(--text-white);
    transform: translateY(-2px);
}

/* --- Header --- */
.sticky-wrapper {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #000;
    transition: box-shadow 0.3s ease;
}

.main-header {
    background: transparent;
    padding: 16px 0;
    position: relative;
    z-index: 100;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 14px;
}

.logo-img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border-radius: 50%;
    box-shadow: var(--shadow-md);
}

.logo-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo-title {
    font-family: 'Brush Script MT', cursive;
    font-size: 3.8rem;
    font-weight: bold;
    color: #fff;
    letter-spacing: 1px;
    line-height: 1;
    margin: 0;
    padding: 0;
    text-transform: none;
}

.logo-title span {
    color: #ff0000;
}

.logo-tagline {
    font-family: var(--font-main);
    font-size: 1.1rem;
    color: #fff;
    font-weight: 500;
    letter-spacing: 0.5px;
    line-height: 1;
    margin-top: 3px;
    margin-bottom: 0;
    text-transform: none;
}

.header-ad {
    flex-shrink: 0;
}

.ad-placeholder {
    width: 468px;
    height: 60px;
    background: linear-gradient(135deg, #e8e8e8, #f5f5f5);
    border: 1px dashed var(--border-medium);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 2px;
}

.mobile-menu-btn {
    display: none;
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-size: 1.2rem;
    cursor: pointer;
}

/* --- Navigation --- */
.main-nav {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
}

.nav-list {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
}

.nav-list::-webkit-scrollbar {
    display: none;
}

.nav-link {
    display: block;
    padding: 14px 18px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    white-space: nowrap;
    position: relative;
    transition: all var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: var(--accent);
    border-radius: 3px 3px 0 0;
    transition: width var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-white);
    background: rgba(255, 255, 255, 0.08);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 70%;
}

.nav-link i {
    margin-right: 4px;
}

/* --- Breaking News Ticker --- */
.breaking-news {
    background: linear-gradient(90deg, var(--accent) 0%, var(--accent-dark) 100%);
    padding: 0;
    overflow: hidden;
}

.breaking-inner {
    display: flex;
    align-items: center;
    height: 42px;
}

.breaking-label {
    background: var(--gold);
    color: var(--primary-dark);
    padding: 4px 16px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 1px;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
    border-radius: var(--radius-sm);
    animation: pulse-label 2s ease-in-out infinite;
}

@keyframes pulse-label {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.85;
    }
}

.ticker-wrap {
    flex: 1;
    overflow: hidden;
    margin-left: 16px;
}

.ticker {
    display: flex;
    animation: ticker-scroll 30s linear infinite;
    white-space: nowrap;
}

.ticker:hover {
    animation-play-state: paused;
}

.ticker-item {
    color: var(--text-white);
    font-size: 0.85rem;
    font-weight: 500;
    padding: 0 40px;
    flex-shrink: 0;
}

.ticker-item::before {
    content: '●';
    margin-right: 10px;
    color: var(--gold);
}

@keyframes ticker-scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* --- Main Content Grid --- */
.main-content {
    padding: 28px 0 40px;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 28px;
}

/* --- Featured Section --- */
.featured-section {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 32px;
}

.featured-card {
    position: relative;
    display: block;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.featured-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.featured-card:hover img {
    transform: scale(1.05);
}

.featured-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
    color: var(--text-white);
}

.featured-card--big {
    min-height: 420px;
}

.featured-card--big img {
    height: 100%;
}

.featured-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.35;
    margin-top: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.featured-title-sm {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.35;
    margin-top: 8px;
}

.featured-meta {
    display: flex;
    gap: 16px;
    margin-top: 10px;
    font-size: 0.78rem;
    opacity: 0.85;
}

.featured-meta i {
    margin-right: 4px;
}

.featured-side {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.featured-card--small {
    flex: 1;
    min-height: 200px;
}

.featured-card--small img {
    height: 100%;
}

.featured-card--small .featured-overlay {
    padding: 16px;
}

/* --- Category Badges --- */
.category-badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.badge-politik {
    background: #3b82f6;
    color: white;
}

.badge-hukum {
    background: #8b5cf6;
    color: white;
}

.badge-ekonomi {
    background: #10b981;
    color: white;
}

.badge-pendidikan {
    background: #f59e0b;
    color: white;
}

.badge-lingkungan {
    background: #06b6d4;
    color: white;
}

.badge-olahraga {
    background: #ef4444;
    color: white;
}

.badge-budaya {
    background: #ec4899;
    color: white;
}

.badge-kesehatan {
    background: #14b8a6;
    color: white;
}

/* --- Section Block --- */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--accent);
}

.section-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-dark);
}

.section-title i {
    color: var(--accent);
    margin-right: 8px;
}

.see-all {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

.see-all:hover {
    color: var(--accent-dark);
}

/* --- News Grid --- */
.news-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.news-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition);
    border: 1px solid var(--border-light);
}

.news-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.news-card-img-wrap {
    position: relative;
    display: block;
    height: 160px;
    background: #f1f5f9;
    overflow: hidden;
}

.news-card-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-card-img-wrap .category-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
}

.news-card-body {
    padding: 16px;
}

.news-card-body h3 {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 8px;
    color: var(--text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-body h3 a:hover {
    color: var(--accent);
}

.news-excerpt {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-meta {
    display: flex;
    gap: 14px;
    font-size: 0.75rem;
    color: var(--text-muted);
    border-top: 1px solid var(--border-light);
    padding-top: 10px;
}

.news-meta i {
    margin-right: 3px;
    color: var(--accent);
}

/* News Detail Body */
.news-body {
    font-size: 1rem;
    line-height: 1.15 !important;
    color: #334155;
}

/* Memastikan spasi baris (line-height) selalu 1.15 untuk semua elemen di dalam isi berita, baik artikel lama maupun baru */
.news-body,
.news-body * {
    line-height: 1.15 !important;
}

.news-body p {
    margin-bottom: 0.8rem;
    text-align: left;
}

/* Menghilangkan margin bawah pada paragraf terakhir di dalam kontainer tertentu (seperti caption foto) */
.news-detail div p:last-child,
.news-body div p:last-child {
    margin-bottom: 0 !important;
}

.news-body p,
.news-body span,
.news-body div,
.news-body a,
.news-body li {
    font-size: 1rem;
}


/* Collapse spacing for empty paragraphs that often appear from editor */
.news-body p:empty,
.news-body p > br:only-child,
.news-body p > &nbsp;:only-child {
    margin: 0;
    height: 0;
    line-height: 0;
    visibility: hidden;
}

/* If a paragraph is just a non-breaking space, give it a smaller line-height so it acts as a normal gap */
.news-body p {
    min-height: 1em;
}


/* Penyesuaian Gambar dan Perataan dari Editor */
.news-body img {
    max-width: 100%;
    height: auto !important;
    border-radius: 6px;
    margin-top: 10px;
    margin-bottom: 10px;
}

.news-body .align-center,
.news-body .text-center,
.news-body [style*="text-align:center"],
.news-body [style*="text-align: center"] {
    text-align: center !important;
    display: block;
}

.news-body .align-center img,
.news-body .text-center img,
.news-body [style*="text-align:center"] img,
.news-body [style*="text-align: center"] img,
.news-body img.align-center,
.news-body img[style*="margin:auto"],
.news-body img[style*="margin: auto"] {
    margin-left: auto !important;
    margin-right: auto !important;
    display: block !important;
    float: none !important;
}

.news-body .align-left {
    float: left;
    margin: 0 20px 20px 0;
}

.news-body .align-right {
    float: right;
    margin: 0 0 20px 20px;
}

@media (max-width: 768px) {
    .news-body {
        font-size: 0.95rem;
    }

    .news-body p,
    .news-body span,
    .news-body div,
    .news-body a,
    .news-body li {
        font-size: 0.95rem;
    }
}

/* Load More */
.load-more-wrap {
    text-align: center;
    margin-top: 28px;
}

.btn-load-more {
    background: var(--primary);
    color: var(--text-white);
    border: none;
    padding: 12px 36px;
    border-radius: var(--radius-md);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-load-more:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* --- Sidebar --- */
.content-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.sidebar-widget {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
}

.widget-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 14px 18px;
}

.widget-header h3 {
    color: var(--text-white);
    font-size: 0.92rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.widget-header h3 i {
    color: var(--gold);
}

/* Popular List */
.popular-list {
    padding: 4px 0;
}

.popular-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-light);
    transition: background var(--transition);
}

.popular-item:last-child {
    border-bottom: none;
}

.popular-item:hover {
    background: #f8f9fa;
}

.popular-rank {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 0.82rem;
    font-weight: 800;
    color: var(--text-white);
    background: var(--primary-light);
}

.popular-item:nth-child(1) .popular-rank {
    background: var(--accent);
}

.popular-item:nth-child(2) .popular-rank {
    background: var(--gold);
    color: var(--primary-dark);
}

.popular-item:nth-child(3) .popular-rank {
    background: #10b981;
}

.popular-content h4 {
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.popular-meta {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 4px;
    display: inline-block;
}

.popular-meta i {
    margin-right: 3px;
}

/* Photo News */
.photo-news-list {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.photo-news-item {
    display: flex;
    gap: 12px;
    align-items: center;
    transition: opacity var(--transition);
}

.photo-news-item:hover {
    opacity: 0.85;
}

.photo-news-item img {
    width: 90px;
    height: 65px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
}

.photo-news-item p {
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.35;
    color: var(--text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Category List */
.category-list {
    padding: 6px 0;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 11px 18px;
    border-bottom: 1px solid var(--border-light);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all var(--transition);
}

.category-item:last-child {
    border-bottom: none;
}

.category-item:hover {
    background: linear-gradient(90deg, rgba(230, 57, 70, 0.06), transparent);
    padding-left: 24px;
    color: var(--accent);
}

.cat-count {
    background: var(--bg-body);
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    color: #64748b;
}

/* Ad Sidebar */
.ad-placeholder--sidebar {
    width: 100%;
    height: 250px;
}

/* --- Footer --- */
.main-footer {
    background: var(--bg-dark);
    color: rgba(255, 255, 255, 0.75);
    margin-top: 40px;
}

.footer-top {
    padding: 48px 0 36px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: 36px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.footer-logo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: contain;
}

.footer-brand h3 {
    font-family: 'Brush Script MT', cursive;
    font-size: 2.2rem;
    font-weight: bold;
    color: var(--text-white);
    text-transform: none;
}

.footer-brand h3 span {
    color: #ff0000;
}

.footer-desc {
    font-size: 0.82rem;
    line-height: 1.6;
    margin-bottom: 16px;
}

.footer-social {
    display: flex;
    gap: 8px;
}

.footer-social a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
    transition: all var(--transition);
}

.footer-social a:hover {
    background: var(--accent);
    color: white;
    transform: translateY(-3px);
}

.footer-col h4 {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
}

.footer-col ul li {
    margin-bottom: 8px;
}

.footer-col ul li a {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.65);
    transition: all var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-col ul li a:hover {
    color: var(--gold);
    padding-left: 4px;
}

.contact-list li {
    font-size: 0.82rem;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.contact-list li i {
    color: var(--accent);
    margin-top: 3px;
    flex-shrink: 0;
}

.footer-registered {
    margin-top: 18px;
}

.registered-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    font-weight: 700;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.footer-bottom {
    background: rgba(0, 0, 0, 0.3);
    padding: 16px 0;
    text-align: center;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.45);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .content-grid {
        grid-template-columns: 1fr;
    }

    .featured-section {
        grid-template-columns: 1fr;
    }

    .featured-card--big {
        min-height: 320px;
    }

    .featured-side {
        flex-direction: row;
    }

    .ad-placeholder {
        width: 300px;
        height: 50px;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .top-bar-inner {
        flex-direction: column;
        gap: 10px;
        padding: 8px 0;
    }

    .top-bar-left {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .top-bar-right {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .top-bar-right form {
        margin-right: 0 !important;
        margin-bottom: 8px;
        width: 100%;
        justify-content: center;
    }

    .top-bar-right input[name="q"] {
        width: 70% !important;
    }

    .header-ad {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .nav-list {
        display: none;
        flex-direction: column;
    }

    .nav-list.active {
        display: flex;
    }

    .nav-link {
        padding: 12px 20px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }

    .logo-img {
        width: 56px;
        height: 56px;
    }

    .logo-title {
        font-size: 2.5rem;
    }

    .news-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .news-card-img-wrap {
        height: 110px;
    }

    .news-card-body {
        padding: 10px;
    }

    .news-card-body h3 {
        font-size: 0.82rem;
        -webkit-line-clamp: 2;
    }

    .news-excerpt {
        display: none;
    }

    .news-meta {
        font-size: 0.7rem;
        gap: 6px;
        flex-wrap: wrap;
    }

    .featured-side {
        flex-direction: column;
    }

    .featured-card--big {
        min-height: 260px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }

    .logo-title {
        font-size: 2rem;
    }

    .logo-tagline {
        font-size: 0.85rem;
    }

    .section-title {
        font-size: 1rem;
    }

    .featured-title {
        font-size: 1.1rem;
    }
}

/* --- Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.news-card {
    animation: fadeInUp 0.5s ease both;
}

.news-card:nth-child(2) {
    animation-delay: 0.1s;
}

.news-card:nth-child(3) {
    animation-delay: 0.2s;
}

.news-card:nth-child(4) {
    animation-delay: 0.3s;
}

.news-card:nth-child(5) {
    animation-delay: 0.4s;
}

.news-card:nth-child(6) {
    animation-delay: 0.5s;
}

/* Scroll to top button */
.scroll-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 44px;
    height: 44px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
    box-shadow: var(--shadow-md);
    z-index: 1000;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    background: var(--accent-dark);
    transform: translateY(-3px);
}

/* --- News Detail Responsive --- */
.detail-container {
    background: var(--bg-card); 
    padding: 30px; 
    border-radius: 8px; 
    box-shadow: var(--shadow-sm); 
    margin-bottom: 30px;
}

.detail-header {
    margin-bottom: 20px;
}

.category-badge {
    margin-bottom: 15px; 
    display: inline-block;
}

.detail-title {
    font-size: 2rem; 
    font-weight: 800; 
    color: #1e293b; 
    line-height: 1.3; 
    margin-bottom: 15px;
}

.detail-meta {
    display: flex; 
    gap: 20px; 
    color: var(--text-muted); 
    font-size: 0.9rem; 
    border-bottom: 1px solid #e2e8f0; 
    padding-bottom: 15px;
}

.detail-meta i {
    color: var(--accent);
}

@media (max-width: 768px) {
    .detail-container {
        padding: 15px 12px;
    }
    
    .detail-title {
        font-size: 1.5rem;
    }
    
    .detail-meta {
        gap: 10px;
        flex-wrap: wrap;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .detail-container {
        padding: 10px 8px;
    }
    
    .detail-title {
        font-size: 1.35rem;
    }
}