/* ===== ROOT VARIABLES ===== */
:root {
    --primary: #2A5C8B;
    --primary-dark: #1E466B;
    --secondary: #E8B44D;
    --accent: #25A575;
    --light: #F8F9FA;
    --dark: #333333;
    --gray: #6C757D;
    --light-gray: #E9ECEF;
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s ease;
}

/* ===== RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background-color: #fff;
}

h1, h2, h3, h4, h5 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

h1 {
    font-size: 2.8rem;
    line-height: 1.2;
}

h2 {
    font-size: 2.2rem;
    position: relative;
    padding-bottom: 10px;
}

h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 70px;
    height: 3px;
    background-color: var(--secondary);
}

h3 {
    font-size: 1.6rem;
}

p {
    margin-bottom: 1.2rem;
    color: var(--gray);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    background-color: var(--primary);
    color: white;
    border-radius: 4px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1rem;
}

.btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background-color: var(--secondary);
    color: var(--dark);
}

.btn-secondary:hover {
    background-color: #d6a037;
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: white;
}

/* ===== HEADER STYLES ===== */
header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icon {
    color: var(--primary);
    font-size: 1.8rem;
}

.logo-text {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary);
}

.logo-text span {
    color: var(--secondary);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

nav a {
    font-weight: 500;
    position: relative;
}

nav a:hover {
    color: var(--primary);
}

nav a.active {
    color: var(--primary);
}

nav a:after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary);
    transition: var(--transition);
}

nav a:hover:after,
nav a.active:after {
    width: 100%;
}

.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===== HERO SECTION ===== */
.hero {
    background: linear-gradient(rgba(42, 92, 139, 0.85), rgba(42, 92, 139, 0.9)), url('https://images.unsplash.com/photo-1560518883-ce09059eeffa?ixlib=rb-4.0.3&auto=format&fit=crop&w=1773&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 80px 20px;
    text-align: center;
}

.hero h1 {
    color: white;
    max-width: 800px;
    margin: 0 auto 20px;
}

.hero p {
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto 30px;
    font-size: 1.1rem;
}

.hero-btns {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

/* ===== CATEGORIES SECTION ===== */
.categories {
    padding: 80px 0;
    background-color: var(--light);
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    display: inline-block;
}

.section-title h2:after {
    left: 50%;
    transform: translateX(-50%);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.category-card {
    background-color: white;
    border-radius: 8px;
    padding: 30px 20px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: block;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.category-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 20px;
}

.category-card h3 {
    margin-bottom: 10px;
    font-size: 1.4rem;
}

/* ===== ARTICLES SECTION ===== */
.featured-articles {
    padding: 80px 0;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.article-card {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: block;
}

.article-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.article-img {
    height: 200px;
    width: 100%;
    background-size: cover;
    background-position: center;
}

.article-content {
    padding: 25px;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 15px;
}

.article-tag {
    background-color: var(--light-gray);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* ===== TOOLS SECTION ===== */
.tools {
    padding: 80px 0;
    background-color: var(--light);
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.tool-card {
    background-color: white;
    border-radius: 8px;
    padding: 30px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: center;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.tool-icon {
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 20px;
}

/* ===== CTA SECTION ===== */
.cta {
    background-color: var(--primary-dark);
    color: white;
    padding: 80px 0;
    text-align: center;
}

.cta h2 {
    color: white;
}

.cta h2:after {
    background-color: var(--secondary);
    left: 50%;
    transform: translateX(-50%);
}

.cta p {
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto 30px;
}

/* ===== FOOTER STYLES ===== */
footer {
    background-color: #1a3650;
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 15px;
}

.footer-logo span {
    color: var(--secondary);
}

.footer-about p {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links h3, .footer-contact h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: white;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links a:hover {
    color: var(--secondary);
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: var(--transition);
}

.social-icons a:hover {
    background-color: var(--secondary);
    color: var(--dark);
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

.copyright a {
    color: var(--secondary);
}

.copyright a:hover {
    text-decoration: underline;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 992px) {
    h1 {
        font-size: 2.4rem;
    }
    
    h2 {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .mobile-toggle {
        display: block;
    }
    
    nav {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        background-color: white;
        padding: 20px;
        box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
    }
    
    nav.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    nav ul {
        flex-direction: column;
        gap: 15px;
    }
    
    .hero-btns {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-btns .btn {
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 576px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    .hero, .categories, .featured-articles, .tools, .cta {
        padding: 60px 0;
    }
}