@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    /* Colors - Breaking News Theme (High Urgency) */
    --primary: #DC2626;
    /* Red 600 - Urgency/Action */
    --primary-dark: #B91C1C;
    /* Red 700 */
    --secondary: #1E3A8A;
    /* Blue 900 - Trust/Authority */
    --accent: #F59E0B;
    /* Amber - Highlights */

    --bg-body: #F3F4F6;
    /* Gray 100 */
    --bg-card: #FFFFFF;
    --text-main: #111827;
    /* Gray 900 */
    --text-muted: #6B7280;
    /* Gray 500 */
    --border-color: #E5E7EB;
    /* Gray 200 */

    /* Spacing */
    --container-max: 1200px;
    --header-height: 70px;
    --radius: 12px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    padding-top: var(--header-height);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
    object-fit: cover;
}

/* Utilities */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 1rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-title::before {
    content: '';
    width: 6px;
    height: 24px;
    background: var(--primary);
    border-radius: 4px;
    display: block;
}

/* Header */
.main-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    height: var(--header-height);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.header-content {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: -0.05em;
}

.logo span {
    color: var(--text-main);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-main);
}

.nav-links a:hover {
    color: var(--primary);
}

.menu-btn {
    display: none;
    /* Show on mobile */
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding: 2rem 0;
}

/* Hover Effects for Interactive Elements */
a:active,
.hero-main a:active,
.hero-subs a:active,
.news-card a:active,
.ranking-item a:active {
    color: var(--primary-dark) !important;
}

/* Specific Hovers for Card Containers */
.hero-main:hover .hero-title,
.hero-subs:hover .hero-title,
.news-card:hover .card-title,
.ranking-item:hover .ranking-title {
    color: var(--primary);
    transition: color 0.2s ease;
}

.hero-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    height: 500px;
}

.hero-main {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.hero-main img {
    width: 100%;
    height: 100%;
}

.hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    padding: 2rem;
    color: white;
}

.hero-cat {
    background: var(--primary);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    display: inline-block;
}

.hero-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.hero-side {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 1.5rem;
}

.hero-subs {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.hero-subs img {
    width: 100%;
    height: 100%;
}

.hero-subs .hero-overlay {
    padding: 1.5rem;
}

.hero-subs .hero-title {
    font-size: 1.1rem;
}

/* Main Content Grid */
.main-layout {
    display: grid;
    grid-template-columns: 3fr 1fr;
    /* Content vs Sidebar */
    gap: 2rem;
    margin-bottom: 3rem;
}

/* Category Sections */
.category-section {
    margin-bottom: 3rem;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.news-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.news-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.card-image {
    height: 180px;
    width: 100%;
    overflow: hidden;
    /* Prevent spill */
    position: relative;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.news-card:hover .card-image img {
    transform: scale(1.05);
}

.card-content {
    padding: 1.25rem;
}

.card-cat {
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    display: block;
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 1rem;
    display: flex;
    justify-content: space-between;
}

/* Sidebar */
.sidebar-widget {
    background: var(--bg-card);
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 2rem;
}

.widget-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 0.5rem;
}

.ranking-list {
    counter-reset: rank;
}

.ranking-item {
    position: relative;
    padding-left: 2.5rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--bg-body);
    padding-bottom: 1rem;
}

.ranking-item::before {
    counter-increment: rank;
    content: counter(rank);
    position: absolute;
    left: 0;
    top: 0;
    width: 30px;
    height: 30px;
    background: var(--primary);
    /* Red matches site theme */
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.ranking-title {
    font-size: 0.95rem;
    font-weight: 600;
}

/* Footer */
footer {
    background: #000000;
    /* Pure Black */
    color: white;
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col h4 {
    color: white;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-col ul li {
    margin-bottom: 0.5rem;
}

.footer-col ul li a {
    color: #9CA3AF;
}

.footer-col ul li a:hover {
    color: var(--primary);
}

.footer-bottom {
    border-top: 1px solid #374151;
    padding-top: 2rem;
    text-align: center;
    color: #9CA3AF;
    font-size: 0.9rem;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .container {
        padding: 0 1.5rem;
    }

    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }

    /* Header Fixes */
    .logo {
        font-size: 1.25rem;
    }

    .menu-btn {
        display: block;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: var(--header-height);
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 1.5rem;
        box-shadow: var(--shadow-lg);
        border-bottom: 1px solid var(--border-color);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        width: 100%;
        border-bottom: 1px solid #f3f4f6;
        padding: 0.75rem 0;
    }

    .nav-links li:last-child {
        border-bottom: none;
    }

    /* Hero Fixes: Stack Content Below Image */
    .hero-grid {
        grid-template-columns: 1fr;
        height: auto;
        gap: 2rem;
    }

    /* Wrap the link to behave as a column container */
    .hero-main a,
    .hero-subs a {
        display: flex;
        flex-direction: column;
        height: 100%;
        color: inherit;
    }

    .hero-main,
    .hero-subs {
        height: auto;
        box-shadow: var(--shadow-sm);
        border-radius: var(--radius);
        overflow: hidden;
        background: var(--bg-card);
    }

    .hero-main img,
    .hero-subs img {
        height: 250px;
        width: 100%;
        object-fit: cover;
    }

    /* Disable Overlay on Mobile - Move text below */
    .hero-overlay,
    .hero-subs .hero-overlay {
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        right: auto !important;
        background: var(--bg-card) !important;
        color: var(--text-main) !important;
        padding: 1.5rem !important;
        background-image: none !important;
    }

    .hero-title,
    .hero-subs .hero-title {
        font-size: 1.35rem;
        /* Readable size */
        margin-top: 0.5rem;
        color: var(--text-main);
        line-height: 1.3;
    }

    .hero-meta {
        color: var(--text-muted);
        font-size: 0.85rem;
        margin-top: 0.5rem;
    }

    .hero-side {
        grid-template-columns: 1fr;
        gap: 2rem;
        height: auto;
    }

    /* Main Content */
    .main-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin-bottom: 2rem;
    }

    .cards-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    /* Article Page Fixes */
    .single-post h1 {
        font-size: 1.75rem !important;
        /* Smaller title */
        line-height: 1.3 !important;
    }

    .post-content p {
        font-size: 1rem !important;
        line-height: 1.6 !important;
    }

    .post-image img {
        max-height: 300px !important;
    }

    /* Footer */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
}