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

:root {
    --primary-color: #10b981;
    --primary-dark: #059669;
    --primary-light: #34d399;
    --secondary-color: #3b82f6;
    --accent-color: #8b5cf6;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --background-light: #f8fafc;
    --background-white: #ffffff;
    --border-color: #e5e7eb;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    /* Removed background-color to allow image to show */
}

html {
    background: transparent; /* Ensure html background is transparent */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
}

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

.navbar {
    padding: 1rem 0;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

.nav-link {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-icon {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 1.1rem;
    transition: var(--transition);
}

.nav-icon:hover {
    color: var(--primary-color);
}

/* Buttons */
.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.cta-button.primary {
    background: var(--primary-color);
    color: white;
}

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

.cta-button.secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.cta-button.secondary:hover {
    background: var(--primary-color);
    color: white;
}

.cta-button.small {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.cta-button.white {
    background: white;
    color: var(--primary-color);
}

.cta-button.white:hover {
    background: var(--primary-color);
    color: white;
}

/* Hero Section */
.hero {
    position: relative;
    padding: 140px 0 80px;
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.hero-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><polygon fill="rgba(16, 185, 129, 0.05)" points="0,1000 1000,0 1000,1000"/></svg>');
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

.highlight {
    color: var(--primary-color);
    position: relative;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30%;
    background: var(--primary-light);
    opacity: 0.3;
    z-index: -1;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: var(--text-light);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    gap: 2rem;
}

.stat h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.stat p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin: 0;
}

.hero-image {
    position: relative;
}

.hero-image img {
    width: 100%;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
}

.floating-card {
    position: absolute;
    top: 20px;
    right: -20px;
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    text-align: center;
    animation: float 3s ease-in-out infinite;
}

.floating-card i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.floating-card h4 {
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.floating-card p {
    font-size: 0.9rem;
    color: var(--text-light);
    margin: 0;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* Animations */
.animate-fade-in {
    animation: fadeIn 1s ease-out;
}

.animate-fade-in-delay {
    animation: fadeIn 1s ease-out 0.3s both;
}

.animate-slide-up {
    animation: slideUp 1s ease-out 0.6s both;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { 
        opacity: 0;
        transform: translateY(30px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Sections */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

/* Health Categories */
.health-categories {
    background: rgba(255, 255, 255, 0.3); /* Semi-transparent white/greenish */
    backdrop-filter: blur(8px); /* Glass effect */
    border-radius: var(--border-radius); /* Ensure consistent corners */
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* Featured Articles */
.featured-articles {
    background: rgba(255, 255, 255, 0.3); /* Semi-transparent white/greenish */
    backdrop-filter: blur(8px); /* Glass effect */
    border-radius: var(--border-radius); /* Consistent corners */
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* Emergency Resources */
.emergency-resources {
    background: rgba(255, 255, 255, 0.3); /* Semi-transparent white/greenish */
    backdrop-filter: blur(8px); /* Glass effect */
    border-radius: var(--border-radius); /* Consistent corners */
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* Newsletter CTA */
.newsletter-cta {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.6), rgba(139, 92, 246, 0.6)); /* More transparent gradient */
    backdrop-filter: blur(8px); /* Glass effect */
    border-radius: var(--border-radius); /* Consistent corners */
    margin-top: 2rem;
    margin-bottom: 2rem;
}

/* Dynamic Content Pages */
.dynamic-content-page {
    padding-top: 120px; /* Adjust for fixed header */
    padding-bottom: 80px;
    background: rgba(255, 255, 255, 0.3); /* Semi-transparent white/greenish */
    backdrop-filter: blur(8px); /* Glass effect */
    border-radius: var(--border-radius); /* Consistent corners */
    margin-top: 2rem;
    margin-bottom: 2rem;
}

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

.category-card {
    display: block;
    text-align: center;
    padding: 2rem;
    background: var(--background-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-decoration: none;
    color: var(--text-dark);
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    color: var(--text-dark);
    border-color: var(--primary-light);
}

.category-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 2rem;
}

.category-card h3 {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

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

.category-count {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--primary-light);
    color: white;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Featured Articles */
.featured-articles {
    background: var(--background-light);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.article-card {
    background: var(--background-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.article-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.article-card:hover .article-image img {
    transform: scale(1.1);
}

.article-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--primary-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.article-content {
    padding: 1.5rem;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

.article-content h3 {
    margin-bottom: 1rem;
    color: var(--text-dark);
    line-height: 1.4;
}

.article-content p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.read-article {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.read-article:hover {
    gap: 1rem;
}

/* Health Tips */
.health-tips {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
}

.tips-container {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.tips-header h2 {
    color: white;
    margin-bottom: 1rem;
}

.tips-header p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3rem;
}

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

.tip-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.tip-icon {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.5rem;
}

.tip-item p {
    color: white;
    margin: 0;
    font-weight: 500;
}

/* Emergency Resources */
.emergency-resources {
    background: var(--background-light);
}

.resources-card {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    border-radius: var(--border-radius);
    padding: 3rem;
    text-align: center;
    box-shadow: var(--shadow);
}

.resources-content h2 {
    color: #dc2626;
    margin-bottom: 1rem;
}

.resources-content p {
    color: #7f1d1d;
    margin-bottom: 2rem;
}

.emergency-contacts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.contact-item i {
    width: 50px;
    height: 50px;
    background: #dc2626;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.contact-item h4 {
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.contact-item p {
    color: var(--text-light);
    margin: 0;
}

/* Newsletter CTA */
.newsletter-cta {
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    color: white;
    text-align: center;
}

.cta-content h2 {
    color: white;
    margin-bottom: 1rem;
}

.cta-content p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
    font-size: 1.2rem;
}

/* Footer */
.footer {
    background: var(--text-dark);
    color: white;
    padding: 60px 0 0;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-section h4 {
    color: white;
    margin-bottom: 1.5rem;
}

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

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

.footer-section ul li a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

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

.contact-info p {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    color: #94a3b8;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.footer-bottom {
    border-top: 1px solid #374151;
    padding: 2rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #94a3b8;
    flex-wrap: wrap;
    gap: 1rem;
}

.disclaimer {
    font-size: 0.9rem;
    opacity: 0.7;
    margin-left: 1rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

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

/* Search Overlay */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.search-overlay.active {
    display: flex;
}

.search-container {
    position: relative;
    width: 90%;
    max-width: 600px;
}

.search-close {
    position: absolute;
    top: -60px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
}

.search-form {
    display: flex;
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.search-input {
    flex: 1;
    padding: 1.5rem;
    border: none;
    outline: none;
    font-size: 1.1rem;
}

.search-submit {
    padding: 0 2rem;
    background: var(--primary-color);
    color: white;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.search-submit:hover {
    background: var(--primary-dark);
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.bar {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    transition: var(--transition);
}

/* Text Center */
.text-center {
    text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: white;
        width: 100%;
        text-align: center;
        transition: var(--transition);
        box-shadow: var(--shadow);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .section-title {
        font-size: 2rem;
    }

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

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

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

    .emergency-contacts {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero {
        padding: 120px 0 60px;
    }

    section {
        padding: 60px 0;
    }

    .resources-card {
        padding: 2rem;
    }

    .contact-item {
        flex-direction: column;
        text-align: center;
    }
}

/* Dynamic Content Pages */
.dynamic-content-page {
    padding-top: 120px; /* Adjust for fixed header */
    padding-bottom: 80px;
    background-color: var(--background-light);
}

.dynamic-content-page .section-header {
    margin-bottom: 2rem;
}

.dynamic-content-page .section-title {
    font-size: 2.2rem;
}

.dynamic-content-page .section-subtitle {
    font-size: 1.1rem;
}

.dynamic-content-page .articles-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.dynamic-content-page .article-card {
    height: auto;
}

.dynamic-content-page .article-content h4 {
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: var(--primary-dark);
}

.dynamic-content-page .article-content ul {
    list-style: disc inside;
    padding-left: 1rem;
    margin-bottom: 1rem;
    color: var(--text-light);
}

.dynamic-content-page .article-content ul li {
    margin-bottom: 0.3rem;
}

.error-page {
    padding-top: 120px;
    padding-bottom: 120px;
    text-align: center;
}

.error-page .section-title {
    color: var(--danger-color);
}

    .error-page .section-subtitle {
        margin-bottom: 2rem;
    }

/* Global Background Image */
body {
    background-image: url('https://images.unsplash.com/photo-1465146344425-ad42a8e7218c?q=80&w=2070&auto=format&fit=crop&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D'); /* New nature-related image */
    background-size: cover;
    background-position: center bottom;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

/* Glassmorphism Effect for Cards - applied to relevant elements */
.category-card,
.article-card,
.contact-item {
    background: rgba(100, 200, 150, 0.2); /* Semi-transparent green */
    backdrop-filter: blur(10px); /* Glass effect */
    border: 1px solid rgba(255, 255, 255, 0.4); /* Subtle border for glossy look */
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.2); /* Enhanced shadow for glossiness */
    border-radius: 12px; /* Ensure rounded corners */
}

/* Adjustments for specific elements to fit the new aesthetic */
.tip-item {
    background: rgba(0, 128, 0, 0.1); /* Lighter semi-transparent green */
    backdrop-filter: blur(8px); /* Slightly less blur */
    border: 1px solid rgba(255, 255, 255, 0.3); /* Subtle border */
    box-shadow: 0 4px 16px 0 rgba(0, 0, 0, 0.1); /* Lighter shadow */
}

/* Ensure header remains readable */
.header {
    background: rgba(255, 255, 255, 0.85); /* Slightly more opaque for readability */
    backdrop-filter: blur(8px); 
}
.footer {
    background: rgba(31, 41, 55, 0.85); /* Slightly transparent dark background */
    backdrop-filter: blur(8px);
}

/* Adjust hero section background as it might clash */
.hero {
    background: transparent; /* Let the body background show through */
}

.hero-background {
    display: none; /* Hide previous hero background elements */
}
