:root {
    /* Light Mode Colors */
    --primary: #2E8B57;
    --primary-dark: #21663e;
    --secondary: #e67e22;
    --bg-main: #FEFBEA;
    --bg-alt: #FDF5E6;
    --text-main: #1a1a1a;
    --text-muted: #555;
    --white: #ffffff;
    --header-bg: rgba(254, 251, 234, 0.95);
    --card-bg: #ffffff;
    --shadow: 0 4px 20px rgba(0,0,0,0.08);
    --glow: rgba(46, 139, 87, 0.4);
}

body.dark-mode {
    --primary: #2dd4bf;
    --primary-dark: #0d9488;
    --secondary: #fb923c;
    --bg-main: #121212;
    --bg-alt: #1e1e1e;
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --white: #1a1a1a;
    --header-bg: rgba(18, 18, 18, 0.95);
    --card-bg: #242424;
    --shadow: 0 4px 20px rgba(0,0,0,0.4);
    --glow: rgba(45, 212, 191, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

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

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

/* Header */
header {
    background-color: var(--header-bg);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
    box-shadow: var(--shadow);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo img {
    height: 45px;
    width: auto;
}

.logo h1 {
    font-size: 1.4rem;
    color: var(--primary);
    font-weight: 800;
    letter-spacing: -0.5px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 10px;
}

nav a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

nav a:hover, nav a.active {
    background-color: var(--primary);
    color: var(--white);
    box-shadow: 0 0 15px var(--glow);
}

.nav-donate {
    background-color: var(--secondary);
    color: white !important;
}

.nav-donate:hover {
    background-color: var(--secondary);
    filter: brightness(1.1);
}

/* Theme Toggle */
.theme-btn {
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: background 0.3s;
}

.theme-btn:hover {
    background: rgba(128, 128, 128, 0.1);
}

/* Hero */
.hero {
    padding: 160px 0; /* Increased height for desktop */
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('https://images.unsplash.com/photo-1469571486292-0ba58a3f068b?auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
}

.hero-content {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 50px 40px;
    border-radius: 30px;
    display: inline-block;
    max-width: 850px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    margin: 0 auto;
}

[data-theme="dark"] .hero-content {
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.badge {
    background: var(--primary);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 20px;
    display: inline-block;
}

.hero h2 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    line-height: 1.2;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
    opacity: 0.95;
    color: #fff;
}

/* Buttons */
.btn {
    padding: 12px 30px;
    border-radius: 12px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
}

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

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px var(--glow);
}

.btn-outline {
    border: 2px solid white;
    color: white;
}

.btn-outline:hover {
    background: white;
    color: black;
}

.btn-glow:hover {
    box-shadow: 0 0 25px var(--primary);
}

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

.bg-alt {
    background-color: var(--bg-alt);
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.underline {
    width: 60px;
    height: 4px;
    background: var(--primary);
    margin: 0 auto;
    border-radius: 2px;
}

/* About Grid */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.stat-card {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    text-align: center;
    margin-bottom: 20px;
}

.stat-card h3 {
    font-size: 2.5rem;
    color: var(--primary);
}

/* Causes Grid */
.causes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.cause-card {
    background: var(--card-bg);
    padding: 40px 30px;
    border-radius: 24px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: transform 0.3s;
}

.cause-card:hover {
    transform: translateY(-10px);
}

.cause-icon {
    font-size: 2.5rem;
    color: var(--secondary);
    margin-bottom: 20px;
}

/* Donate Section */
.donate-section {
    background-color: var(--bg-main);
}

.donate-box {
    background: var(--card-bg);
    padding: 60px;
    border-radius: 30px;
    text-align: center;
    box-shadow: var(--shadow);
}

.donate-box p {
    max-width: 800px;
    margin: 20px auto 40px;
}

/* Footer */
footer {
    background: var(--bg-alt);
    padding: 80px 0 30px;
    border-top: 1px solid rgba(128,128,128,0.1);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 50px;
}

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

.footer-links a {
    text-decoration: none;
    color: var(--text-muted);
    transition: color 0.3s;
}

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

.footer-contact p {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(128,128,128,0.1);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: var(--bg-main);
    margin: 10% auto;
    padding: 40px;
    border-radius: 24px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    position: relative;
}

.close {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 24px;
    cursor: pointer;
}

#qrcode {
    margin: 20px auto;
    display: flex;
    justify-content: center;
}

/* Scroll Top */
.scroll-top-btn {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    display: none;
    justify-content: center;
    align-items: center;
    box-shadow: 0 5px 15px var(--glow);
    z-index: 1000;
    transition: all 0.3s;
}

.scroll-top-btn:hover {
    transform: translateY(-5px);
}

/* Mobile Menu */
.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
        position: fixed;
        top: 20px;
        right: 20px;
        z-index: 2000;
        background: var(--bg-main);
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 10px;
        box-shadow: var(--shadow);
    }

    .theme-btn {
        position: fixed;
        top: 20px;
        right: 75px;
        z-index: 2000;
        background: var(--bg-main);
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 10px;
        box-shadow: var(--shadow);
    }

    nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: var(--bg-main);
        padding: 100px 30px;
        transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -10px 0 30px rgba(0,0,0,0.2);
        z-index: 1500;
    }

    nav.active {
        right: 0;
    }

    nav ul {
        flex-direction: column;
        gap: 20px;
    }

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

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

    .hero-content {
        padding: 30px 20px;
        width: 90%;
        border-radius: 20px;
    }

    .hero {
        padding: 80px 0; /* Keep it compact on mobile */
    }

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