/* ==========================
   1. Design Tokens
   ========================== */
:root {
    --brand-primary: #0d6efd; /* Bootstrap blue - can customize */
    --brand-secondary: #495057; /* Neutral dark gray */
    --brand-accent: #20c997; /* Teal accent */
    --bg-light: #f8f9fa; /* Page background */
    --bg-dark: #212529; /* Dark sections */
    --text-dark: #212529;
    --text-muted: #6c757d;
    --radius: 12px;
    --shadow-sm: 0 2px 6px rgba(0,0,0,0.05);
    --shadow-md: 0 6px 16px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 32px rgba(0,0,0,0.12);
    --transition: all 0.25s ease-in-out;
}

/* ==========================
   2. Base Typography
   ========================== */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-dark);
    background-color: var(--bg-light);
    margin: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

p {
    margin-bottom: 1rem;
    color: var(--text-dark);
    font-size: 1rem;
}

.hero-section {
    width: 100%;
    margin: 0;
    padding: 0;
}

.hero-img {
    width: 100%;
    height: auto;
    max-height: 450px; /* keep it slim like a banner */
    object-fit: fill;
    display: block;
}

/* ==========================
   3. Header / Navbar
   ========================== */
.navbar {
    /*background-color: var(--brand-primary);*/
    background-color: #edf1f0;
    box-shadow: var(--shadow-sm);
    padding: 0.75rem 1rem;
}

    .navbar .navbar-brand {
        font-weight: 700;
        font-size: 1.3rem;
        color: #231d2a !important;
        letter-spacing: -0.5px;
    }

    .navbar .nav-link {
        color: #000 !important;
        margin-left: 1.25rem;
        font-weight: 500;
        transition: var(--transition);
    }

        .navbar .nav-link:hover,
        .navbar .nav-link.active {
            color: #0d6efd !important;
            text-decoration: underline;
        }

/* ==========================
   4. Footer
   ========================== */
footer {
    background-color: var(--bg-dark);
    color: white;
    padding: 2rem 0;
    font-size: 0.95rem;
}

    footer a {
        color: #dee2e6;
        margin: 0 0.5rem;
        transition: var(--transition);
        text-decoration: none;
    }

        footer a:hover {
            color: #fff;
        }

/* ==========================
   5. Section Titles
   ========================== */
.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    position: relative;
    margin-bottom: 1.5rem;
    color: var(--brand-secondary);
}

    .section-title::after {
        content: "";
        position: absolute;
        left: 0;
        bottom: -6px;
        width: 50px;
        height: 3px;
        background: var(--brand-accent);
        border-radius: 3px;
    }

/* ==========================
   6. Article & Country Cards
   ========================== */
.article-card, .country-card {
    background: #fff;
    border-radius: var(--radius);
    padding: 1.25rem;
    border: 1px solid #e9ecef;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

    .article-card:hover, .country-card:hover {
        transform: translateY(-6px);
        box-shadow: var(--shadow-md);
    }

    .article-card h5 {
        font-size: 1.1rem;
        font-weight: 600;
        margin-bottom: 0.75rem;
        color: var(--brand-primary);
    }

    .article-card p {
        font-size: 0.95rem;
        color: var(--text-muted);
        flex-grow: 1;
    }

    .country-card img {
        width: 48px;
        height: auto;
        margin-bottom: 0.75rem;
    }

    .country-card span {
        font-weight: 500;
        font-size: 1rem;
        color: var(--text-dark);
    }

/* ==========================
   7. Article Details Page
   ========================== */
.article-details {
    background: #fff;
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 2rem;
}

    .article-details h1 {
        font-size: 1.9rem;
        font-weight: 700;
        margin-bottom: 1rem;
    }

    .article-details .meta {
        font-size: 0.9rem;
        color: var(--text-muted);
        margin-bottom: 1.5rem;
    }

    .article-details p {
        font-size: 1rem;
        margin-bottom: 1.25rem;
        color: var(--text-dark);
    }

/* ==========================
   8. Recommended Articles
   ========================== */
.recommended-articles {
    margin-top: 2.5rem;
}

    .recommended-articles h3 {
        font-size: 1.2rem;
        font-weight: 600;
        margin-bottom: 1rem;
        border-bottom: 2px solid #e9ecef;
        padding-bottom: 0.5rem;
    }

    .recommended-articles .article-card {
        padding: 1rem;
        border: 1px solid #e9ecef;
        margin-bottom: 0.75rem;
    }

/* ==========================
   9. Buttons
   ========================== */
.btn-custom {
    background-color: var(--brand-primary);
    color: #fff;
    font-weight: 500;
    border-radius: 6px;
    padding: 0.5rem 1rem;
    transition: var(--transition);
    border: none;
}

    .btn-custom:hover {
        background-color: #0b5ed7;
        color: #fff;
        transform: translateY(-2px);
        box-shadow: var(--shadow-sm);
    }

.btn-outline-custom {
    border: 2px solid var(--brand-primary);
    color: var(--brand-primary);
    font-weight: 500;
    border-radius: 6px;
    padding: 0.5rem 1rem;
    transition: var(--transition);
}

    .btn-outline-custom:hover {
        background-color: var(--brand-primary);
        color: #fff;
    }

/* ==========================
   10. Utilities
   ========================== */
.text-muted-small {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.shadow-hover:hover {
    box-shadow: var(--shadow-lg) !important;
}

.rounded-lg {
    border-radius: var(--radius) !important;
}

/* Table of Contents (TOC) box */
.toc-box {
    background-color: #f8f9fa;
    border-radius: 12px;
}

    .toc-box ol li a {
        transition: color 0.3s ease, padding-left 0.2s ease;
    }

        .toc-box ol li a:hover {
            color: #0d6efd;
            padding-left: 4px;
        }

/* Article section styling */
.article-section {
    scroll-margin-top: 100px;
}

..article-section-text {
    font-family: 'Poppins';
}

.article-section-text a {
    text-decoration: none;
}

.section-heading {
    font-size: 1.4rem;
    font-weight: 600;
    border-left: 4px solid #0d6efd;
    padding-left: 10px;
    color: #212529;
}

.article-image {
    max-height: 380px;
    object-fit: cover;
    border-radius: 8px;
}

.text-muted-small {
    font-size: 0.85rem;
    color: #6c757d;
}

/* Tag Pills */
.tag-pill {
    transition: all 0.25s ease-in-out;
    color: #333;
    text-decoration: none;
}

    .tag-pill:hover {
        background-color: #0d6efd;
        color: #6763c3 !important;
        border-color: #0d6efd;
    }
