/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #4A90D9;
    --primary-dark: #357ABD;
    --secondary: #FF9F43;
    --text: #2D3436;
    --text-light: #636E72;
    --bg: #FFFFFF;
    --bg-alt: #F8F9FA;
    --border: #DFE6E9;
    --success: #00B894;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s;
}

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

/* Header & Navigation */
header {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
}

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

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text);
    font-weight: 500;
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
}

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

/* Main Content */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--bg-alt) 0%, var(--bg) 100%);
    margin: 0 -2rem;
    padding: 4rem 2rem;
    margin-bottom: 3rem;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--text);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: background 0.2s, transform 0.1s;
}

.cta-button:hover {
    background: var(--primary-dark);
    color: white;
    transform: translateY(-2px);
}

/* Topics Section */
.topics {
    margin-bottom: 4rem;
}

.topics h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.topics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.topic-card {
    background: var(--bg-alt);
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.topic-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.topic-card .icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.topic-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.topic-card p {
    color: var(--text-light);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.topic-card a {
    font-weight: 600;
}

/* Latest Articles */
.latest-articles {
    margin-bottom: 4rem;
}

.latest-articles h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
}

.articles-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.article-preview {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.5rem;
    transition: box-shadow 0.2s;
}

.article-preview:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
}

.article-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
}

.category {
    background: var(--primary);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 500;
}

time {
    color: var(--text-light);
}

.article-preview h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.article-preview h3 a {
    color: var(--text);
}

.article-preview h3 a:hover {
    color: var(--primary);
}

.article-preview p {
    color: var(--text-light);
}

/* Age Groups */
.age-groups {
    margin-bottom: 4rem;
}

.age-groups h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.age-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.age-card {
    background: linear-gradient(135deg, var(--bg-alt) 0%, var(--bg) 100%);
    border: 1px solid var(--border);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.age-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.age-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 0.5rem;
}

.age-card h3 {
    color: var(--text);
    margin-bottom: 0.25rem;
}

.age-card p {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Newsletter */
.newsletter {
    background: var(--bg-alt);
    padding: 3rem;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 3rem;
}

.newsletter h2 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.newsletter p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.newsletter-form {
    display: flex;
    gap: 0.5rem;
    max-width: 400px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
}

.newsletter-form button {
    background: var(--primary);
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.newsletter-form button:hover {
    background: var(--primary-dark);
}

/* Footer */
footer {
    background: var(--text);
    color: white;
    margin-top: 3rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.footer-section h4 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: rgba(255,255,255,0.8);
}

.footer-section a:hover {
    color: white;
}

.footer-section p {
    color: rgba(255,255,255,0.8);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 1.5rem 2rem;
    text-align: center;
    color: rgba(255,255,255,0.6);
    font-size: 0.875rem;
}

/* Article Page Styles */
.article-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.article-content h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.article-content h2 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.article-content h3 {
    font-size: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.article-content p {
    margin-bottom: 1rem;
}

.article-content ul, .article-content ol {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.article-content blockquote {
    border-left: 4px solid var(--primary);
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: var(--text-light);
}

/* Responsive */
@media (max-width: 768px) {
    nav {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .topics-grid {
        grid-template-columns: 1fr;
    }
}

/* Table of Contents */
.toc {
    background: var(--bg-alt);
    padding: 1.5rem;
    border-radius: 8px;
    margin: 2rem 0;
}

.toc h4 {
    margin-bottom: 1rem;
}

.toc ul {
    list-style: none;
}

.toc li {
    margin-bottom: 0.5rem;
}

.toc a {
    color: var(--text);
}

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

/* Pros/Cons Box */
.pros-cons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 1.5rem 0;
}

.pros, .cons {
    padding: 1rem;
    border-radius: 8px;
}

.pros {
    background: rgba(0, 184, 148, 0.1);
    border: 1px solid var(--success);
}

.cons {
    background: rgba(255, 159, 67, 0.1);
    border: 1px solid var(--secondary);
}

.pros h4, .cons h4 {
    margin-bottom: 0.75rem;
}

@media (max-width: 600px) {
    .pros-cons {
        grid-template-columns: 1fr;
    }
}
