/* WisnuNews - Frontend Styles (Indozone-inspired) */
:root {
    --primary: #E31E24;
    --primary-dark: #C4191F;
    --text: #1a1a1a;
    --text-muted: #666;
    --text-light: #999;
    --bg: #f5f5f5;
    --white: #ffffff;
    --border: #e8e8e8;
    --shadow: 0 2px 12px rgba(0,0,0,.08);
    --shadow-hover: 0 8px 24px rgba(0,0,0,.12);
    --radius: 8px;
    --radius-lg: 12px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --container: 1200px;
    --transition: .2s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

a { color: inherit; text-decoration: none; transition: color var(--transition); }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.site-header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    background: var(--primary);
    color: var(--white);
    font-size: 12px;
    padding: 6px 0;
}

.header-top-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-social { display: flex; gap: 12px; }
.header-social a { opacity: .85; font-weight: 600; font-size: 11px; }
.header-social a:hover { opacity: 1; }

.header-main { padding: 16px 0; }

.header-main-inner {
    display: flex;
    align-items: center;
    gap: 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.logo-icon {
    width: 42px;
    height: 42px;
    background: var(--primary);
    color: var(--white);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 20px;
}

.logo-text {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.logo-text span { color: var(--primary); }

.search-form {
    flex: 1;
    max-width: 400px;
    display: flex;
    border: 2px solid var(--border);
    border-radius: 50px;
    overflow: hidden;
    transition: border-color var(--transition);
}

.search-form:focus-within { border-color: var(--primary); }

.search-form input {
    flex: 1;
    border: none;
    padding: 10px 18px;
    font-family: var(--font);
    font-size: 14px;
    outline: none;
    background: transparent;
}

.search-form button {
    background: var(--primary);
    border: none;
    color: var(--white);
    padding: 0 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
}

.main-nav {
    border-top: 1px solid var(--border);
    overflow-x: auto;
}

.nav-list {
    display: flex;
    gap: 0;
}

.nav-list a {
    display: block;
    padding: 14px 18px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .3px;
    white-space: nowrap;
    border-bottom: 3px solid transparent;
    transition: all var(--transition);
}

.nav-list a:hover,
.nav-list a.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* Hero Section */
.hero-section {
    padding: 24px 0;
    background: var(--white);
    margin-bottom: 24px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 20px;
}

.hero-card { display: block; border-radius: var(--radius-lg); overflow: hidden; }
.hero-card-lg { position: relative; }

.hero-card-lg .hero-img {
    aspect-ratio: 16/9;
    overflow: hidden;
}

.hero-card-lg .hero-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.hero-card-lg:hover .hero-img img { transform: scale(1.05); }

.hero-card-lg .hero-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    background: linear-gradient(transparent, rgba(0,0,0,.85));
    color: var(--white);
}

.hero-card-lg h1 {
    font-size: 26px;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 8px;
}

.hero-card-lg p {
    font-size: 14px;
    opacity: .9;
    margin-bottom: 10px;
}

.hero-side { display: flex; flex-direction: column; gap: 16px; }

.hero-card-sm {
    display: flex;
    gap: 14px;
    background: var(--bg);
    border-radius: var(--radius);
    overflow: hidden;
    transition: box-shadow var(--transition);
}

.hero-card-sm:hover { box-shadow: var(--shadow); }

.hero-card-sm .hero-img {
    width: 140px;
    flex-shrink: 0;
    overflow: hidden;
}

.hero-card-sm .hero-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    min-height: 100px;
}

.hero-card-sm .hero-content { padding: 12px 12px 12px 0; }

.hero-card-sm h3 {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
    margin: 4px 0;
}

.category-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 4px;
    text-transform: uppercase;
}

.hero-img { position: relative; }

.category-tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.meta {
    display: flex;
    gap: 12px;
    font-size: 12px;
    opacity: .8;
}

/* Content Layout */
.content-section { padding-bottom: 40px; }

.content-grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 28px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-title span {
    font-size: 20px;
    font-weight: 800;
    padding-left: 12px;
    border-left: 4px solid var(--primary);
}

.see-all {
    font-size: 13px;
    font-weight: 600;
    color: var(--primary);
}

.see-all:hover { text-decoration: underline; }

.category-block { margin-top: 36px; }

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.news-grid-4 { grid-template-columns: repeat(4, 1fr); }

.news-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform var(--transition), box-shadow var(--transition);
}

.news-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.news-card-link { display: block; }

.news-card-img {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.news-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.news-card:hover .news-card-img img { transform: scale(1.06); }

.news-card-img .category-badge {
    top: 10px;
    left: 10px;
    font-size: 10px;
    padding: 3px 8px;
}

.news-card-body { padding: 16px; }

.news-card-body h3 {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-body p {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-light);
    font-weight: 500;
}

/* Sidebar */
.sidebar-widget {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.widget-title {
    font-size: 16px;
    font-weight: 800;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--primary);
}

.trending-list li {
    display: flex;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.trending-list li:last-child { border-bottom: none; }

.trending-num {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary);
    opacity: .4;
    line-height: 1;
    min-width: 28px;
}

.trending-content a {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
    display: block;
    margin-bottom: 4px;
}

.trending-content a:hover { color: var(--primary); }

.trending-meta { font-size: 11px; color: var(--text-light); }

.ad-placeholder {
    background: var(--bg);
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    padding: 40px 20px;
    text-align: center;
    color: var(--text-light);
}

.ad-placeholder span { font-weight: 700; display: block; margin-bottom: 4px; }

/* Article Page */
.article-page { padding: 24px 0 40px; }

.breadcrumb {
    display: flex;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.breadcrumb a:hover { color: var(--primary); }

.category-badge-inline {
    display: inline-block;
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 4px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.article-title {
    font-size: 32px;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 16px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.article-featured-img {
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 28px;
}

.article-featured-img img { width: 100%; max-height: 480px; object-fit: cover; }

.article-content {
    font-size: 16px;
    line-height: 1.8;
    color: #333;
}

.article-content p { margin-bottom: 16px; }
.article-content h2, .article-content h3 { margin: 24px 0 12px; font-weight: 700; }
.article-content img { border-radius: var(--radius); margin: 16px 0; }

.article-share {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 32px 0;
    padding: 16px;
    background: var(--bg);
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 600;
}

.article-share a {
    padding: 6px 14px;
    background: var(--white);
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid var(--border);
}

.article-share a:hover { background: var(--primary); color: var(--white); border-color: var(--primary); }

.related-articles { margin-top: 40px; }
.related-articles h3 { font-size: 20px; font-weight: 800; margin-bottom: 20px; }

/* Category & Search Pages */
.category-page, .search-page { padding: 24px 0 40px; }

.page-header {
    background: var(--white);
    padding: 24px;
    border-radius: var(--radius-lg);
    margin-bottom: 24px;
    border-left: 4px solid var(--primary);
    box-shadow: var(--shadow);
}

.page-header h1 { font-size: 28px; font-weight: 800; margin-bottom: 4px; }
.page-header p { color: var(--text-muted); font-size: 14px; }

.empty-state {
    background: var(--white);
    padding: 60px 20px;
    text-align: center;
    border-radius: var(--radius-lg);
    color: var(--text-muted);
}

/* Pagination */
.pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-top: 32px;
}

.pagination a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    background: var(--white);
    font-weight: 600;
    font-size: 14px;
    box-shadow: var(--shadow);
}

.pagination a.active,
.pagination a:hover {
    background: var(--primary);
    color: var(--white);
}

/* Footer */
.site-footer {
    background: #1a1a1a;
    color: #ccc;
    padding: 48px 0 24px;
    margin-top: 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 32px;
}

.footer-brand p { font-size: 14px; line-height: 1.7; margin-top: 16px; color: #999; }
.footer-brand .logo-text { color: var(--white); }

.footer-links h4 {
    color: var(--white);
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.footer-links li { margin-bottom: 8px; }
.footer-links a { font-size: 14px; color: #999; }
.footer-links a:hover { color: var(--primary); }

.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 20px;
    text-align: center;
    font-size: 13px;
    color: #666;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero-grid { grid-template-columns: 1fr; }
    .content-grid { grid-template-columns: 1fr; }
    .news-grid { grid-template-columns: repeat(2, 1fr); }
    .news-grid-4 { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .header-main-inner { flex-wrap: wrap; }
    .search-form { order: 3; max-width: 100%; flex: 1 1 100%; }
    .mobile-menu-btn { display: flex; margin-left: auto; }
    .main-nav { display: none; }
    .main-nav.open { display: block; }
    .nav-list { flex-direction: column; }
    .nav-list a { border-bottom: none; border-left: 3px solid transparent; }
    .news-grid, .news-grid-4 { grid-template-columns: 1fr; }
    .article-title { font-size: 24px; }
    .footer-grid { grid-template-columns: 1fr; }
    .hero-card-lg h1 { font-size: 20px; }
}
