:root {
    --primary: #c81e3a;
    --primary-dark: #a11730;
    --dark: #14161f;
    --text: #1f2430;
    --text-light: #6b7280;
    --border: #e8e9ec;
    --bg-alt: #f6f7f9;
    --white: #ffffff;
    --font-heading: 'Merriweather', Georgia, serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;
    --radius: 10px;
    --shadow: 0 2px 10px rgba(0,0,0,0.06);
    --shadow-md: 0 6px 24px rgba(0,0,0,0.10);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font-body);
    color: var(--text);
    background: var(--white);
    line-height: 1.6;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul { list-style: none; margin: 0; padding: 0; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ============ HEADER ============ */
.site-header { position: sticky; top: 0; z-index: 500; background: var(--white); box-shadow: var(--shadow); }
.topbar { background: var(--dark); color: #cfd2dc; font-size: 12.5px; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; padding: 7px 20px; }
.topbar-social { display: flex; gap: 14px; }
.topbar-social a { color: #cfd2dc; font-size: 13px; transition: color .15s; }
.topbar-social a:hover { color: var(--primary); }

.main-header-inner { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; }
.site-logo img { max-height: 48px; }
.site-logo-text { font-family: var(--font-heading); font-size: 26px; font-weight: 900; color: var(--primary); letter-spacing: -0.5px; }
.nav-toggle { display: none; background: none; border: none; font-size: 22px; cursor: pointer; color: var(--text); }

.main-nav { background: var(--primary); }
.nav-inner { display: flex; gap: 4px; overflow-x: auto; }
.nav-inner a { color: #fff; padding: 13px 16px; font-weight: 600; font-size: 14px; white-space: nowrap; transition: background .15s; }
.nav-inner a:hover, .nav-inner a.active { background: rgba(0,0,0,0.15); }
.nav-home { display: flex; align-items: center; gap: 6px; }

/* ============ HERO ============ */
.hero-section { display: grid; grid-template-columns: 1.6fr 1fr; gap: 20px; margin: 24px 0; }
.hero-main-link { position: relative; display: block; border-radius: var(--radius); overflow: hidden; height: 100%; box-shadow: var(--shadow-md); }
.hero-main img { width: 100%; height: 440px; object-fit: cover; transition: transform .4s; }
.hero-main-link:hover img { transform: scale(1.04); }
.hero-main-overlay { position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 26px 24px; background: linear-gradient(to top, rgba(0,0,0,0.88), rgba(0,0,0,0)); color: #fff; }
.hero-main-overlay h1 { font-family: var(--font-heading); font-size: 28px; line-height: 1.3; margin: 12px 0 8px; font-weight: 900; }
.hero-meta { font-size: 13px; opacity: 0.85; }
.news-card-cat { display: inline-block; background: var(--primary); color: #fff; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px; padding: 4px 10px; border-radius: 4px; }

.hero-side { display: flex; flex-direction: column; gap: 14px; }
.hero-side-item { display: flex; gap: 12px; background: var(--bg-alt); border-radius: var(--radius); overflow: hidden; padding: 8px; transition: background .15s; align-items: center; }
.hero-side-item:hover { background: #eef0f3; }
.hero-side-item img { width: 96px; height: 72px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.hero-side-cat { font-size: 10.5px; font-weight: 700; color: var(--primary); text-transform: uppercase; }
.hero-side-item h4 { font-size: 14px; margin: 4px 0 4px; line-height: 1.35; font-weight: 700; }
.hero-meta-small { font-size: 11.5px; color: var(--text-light); }

/* ============ LAYOUT ============ */
.content-layout { display: grid; grid-template-columns: 1fr 320px; gap: 34px; margin: 10px 0 40px; align-items: start; }
.section-block { margin-bottom: 38px; }
.section-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; padding-bottom: 10px; border-bottom: 3px solid var(--border); }
.section-title h2 { font-family: var(--font-heading); font-size: 21px; margin: 0; position: relative; padding-bottom: 10px; margin-bottom: -13px; border-bottom: 3px solid var(--primary); }
.see-all { font-size: 13px; font-weight: 600; color: var(--primary); display: flex; align-items: center; gap: 6px; }

/* ============ NEWS GRID / CARD ============ */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.news-card { border-radius: var(--radius); overflow: hidden; background: var(--white); box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; }
.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.news-card-img { position: relative; display: block; overflow: hidden; }
.news-card-img img { width: 100%; height: 180px; object-fit: cover; transition: transform .4s; }
.news-card:hover .news-card-img img { transform: scale(1.06); }
.news-card-img .news-card-cat { position: absolute; top: 10px; left: 10px; }
.news-card-body { padding: 14px 16px 16px; }
.news-card-body h3 { font-family: var(--font-heading); font-size: 16px; line-height: 1.4; margin: 0 0 8px; font-weight: 700; }
.news-card-body h3 a:hover { color: var(--primary); }
.news-card-excerpt { font-size: 13px; color: var(--text-light); margin: 0 0 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-card-meta { display: flex; gap: 14px; font-size: 12px; color: var(--text-light); }
.news-card-meta i { margin-right: 4px; }

/* ============ SIDEBAR ============ */
.sidebar-widget { background: var(--bg-alt); border-radius: var(--radius); padding: 20px; margin-bottom: 22px; }
.sidebar-title { font-family: var(--font-heading); font-size: 16px; margin: 0 0 16px; display: flex; align-items: center; gap: 8px; color: var(--primary); }
.sidebar-list { display: flex; flex-direction: column; gap: 14px; }
.sidebar-list-item { display: flex; gap: 12px; align-items: flex-start; }
.sidebar-rank { font-family: var(--font-heading); font-size: 20px; font-weight: 900; color: var(--border); flex-shrink: 0; width: 26px; }
.sidebar-list-item h5 { font-size: 13.5px; font-weight: 700; margin: 0 0 4px; line-height: 1.35; }
.sidebar-list-item span { font-size: 11.5px; color: var(--text-light); }
.sidebar-list-thumb { width: 60px; height: 60px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.footer-social-list { display: flex; flex-direction: column; gap: 8px; }
.footer-social-btn { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: var(--white); border-radius: 8px; font-size: 13.5px; font-weight: 600; transition: all .15s; }
.footer-social-btn:hover { background: var(--primary); color: #fff; }
.footer-social-btn i { width: 16px; }

/* ============ ARTICLE DETAIL ============ */
.breadcrumb { padding: 16px 0; font-size: 13px; color: var(--text-light); display: flex; gap: 8px; flex-wrap: wrap; }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb-current { color: var(--text); font-weight: 600; }
.article-cat-badge { display: inline-block; background: var(--primary); color: #fff; font-size: 12px; font-weight: 700; text-transform: uppercase; padding: 5px 12px; border-radius: 5px; margin-bottom: 14px; }
.article-title { font-family: var(--font-heading); font-size: 32px; line-height: 1.3; margin: 0 0 14px; font-weight: 900; }
.article-meta { display: flex; gap: 18px; font-size: 13px; color: var(--text-light); margin-bottom: 20px; padding-bottom: 20px; border-bottom: 1px solid var(--border); }
.article-image { border-radius: var(--radius); overflow: hidden; margin-bottom: 24px; }
.article-image img { width: 100%; max-height: 480px; object-fit: cover; }
.article-content { font-size: 16.5px; line-height: 1.85; color: #2a2f3a; }
.article-content p { margin: 0 0 18px; }
.article-content h2, .article-content h3 { font-family: var(--font-heading); margin: 28px 0 14px; }
.article-content img { border-radius: 8px; margin: 18px 0; }
.article-content blockquote { border-left: 4px solid var(--primary); margin: 20px 0; padding: 10px 20px; background: var(--bg-alt); font-style: italic; color: var(--text-light); }
.article-content ul, .article-content ol { margin: 0 0 18px; padding-left: 24px; }
.article-content a { color: var(--primary); text-decoration: underline; }

.article-share { display: flex; align-items: center; gap: 10px; margin: 30px 0 10px; padding-top: 24px; border-top: 1px solid var(--border); }
.article-share span { font-weight: 700; font-size: 14px; margin-right: 4px; }
.share-btn { width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 15px; transition: opacity .15s; }
.share-btn:hover { opacity: 0.85; }
.share-fb { background: #1877f2; }
.share-tw { background: #000; }
.share-wa { background: #25d366; }
.share-tg { background: #0088cc; }

/* ============ CATEGORY PAGE ============ */
.category-header { padding: 10px 0 20px; border-bottom: 1px solid var(--border); margin-bottom: 26px; }
.category-header h1 { font-family: var(--font-heading); font-size: 30px; margin: 0 0 4px; }
.category-header p { color: var(--text-light); margin: 0; font-size: 14px; }

.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 20px; }
.pagination a { padding: 9px 15px; border-radius: 8px; background: var(--bg-alt); font-weight: 600; font-size: 14px; }
.pagination a.active { background: var(--primary); color: #fff; }
.pagination a:hover:not(.active) { background: var(--border); }

/* ============ FOOTER ============ */
.site-footer { background: var(--dark); color: #b7bac6; margin-top: 40px; }
.footer-inner { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 32px; padding: 50px 20px 40px; }
.footer-logo { max-height: 42px; margin-bottom: 14px; }
.footer-logo-text { font-family: var(--font-heading); font-size: 22px; font-weight: 900; color: #fff; margin-bottom: 14px; }
.footer-brand p { font-size: 13.5px; line-height: 1.7; margin: 0 0 16px; }
.footer-social { display: flex; gap: 10px; }
.footer-social a { width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center; transition: background .15s; }
.footer-social a:hover { background: var(--primary); color: #fff; }
.footer-col h4 { color: #fff; font-size: 15px; margin: 0 0 16px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a:hover { color: #fff; }
.footer-col .footer-social-btn { background: rgba(255,255,255,0.06); color: #b7bac6; }
.footer-col .footer-social-btn:hover { background: var(--primary); color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); padding: 18px 20px; text-align: center; font-size: 13px; }

/* ============ MISC ============ */
.empty-state-front { text-align: center; padding: 70px 20px; color: var(--text-light); }
.empty-state-front i { font-size: 46px; color: var(--border); margin-bottom: 14px; }
.empty-state-front h2 { color: var(--text); margin: 10px 0; }
.btn-back-home { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; background: var(--primary); color: #fff; padding: 12px 22px; border-radius: 8px; font-weight: 700; }

.back-to-top { position: fixed; bottom: 26px; right: 26px; width: 46px; height: 46px; border-radius: 50%; background: var(--primary); color: #fff; border: none; font-size: 16px; cursor: pointer; box-shadow: var(--shadow-md); display: none; align-items: center; justify-content: center; z-index: 400; }
.back-to-top.show { display: flex; }

/* ============ RESPONSIVE ============ */
@media (max-width: 992px) {
    .content-layout { grid-template-columns: 1fr; }
    .hero-section { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
    .nav-toggle { display: block; }
    .main-nav { display: none; }
    .main-nav.show { display: block; }
    .nav-inner { flex-direction: column; }
    .news-grid { grid-template-columns: repeat(2, 1fr); }
    .hero-main img { height: 260px; }
    .hero-main-overlay h1 { font-size: 20px; }
    .article-title { font-size: 24px; }
    .footer-inner { grid-template-columns: 1fr; padding: 36px 20px 28px; }
    .topbar-date { font-size: 11px; }
}
@media (max-width: 480px) {
    .news-grid { grid-template-columns: 1fr; }
    .hero-side-item h4 { font-size: 13px; }
}
