/* Base Reset & Variables */
:root {
    /* Premium Palette */
    --color-primary: #064e3b;
    /* Deep Emerald - Trust & Nature */
    --color-primary-light: #438f78;
    /* Lighter Emerald for hover states */
    --color-secondary: #0f172a;
    /* Slate 900 - Tech/Modern Black */
    --color-accent: #d97706;
    /* Amber 600 - Gold/Premium Accent */
    --color-accent-hover: #b45309;

    /* Neutral Tones */
    --color-bg: #f8fafc;
    /* Slate 50 - Very Subtle Cool Gray Background */
    --color-surface: #ffffff;
    --color-text: #334155;
    /* Slate 700 - Softer than pure black */
    --color-text-heading: #0f172a;
    /* Deep Slate for headings */
    --color-border: #e2e8f0;
    /* Slate 200 */

    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing & Structure */
    --radius-sm: 6px;
    --radius-md: 12px;
    /* Modern "squircle" feel */
    --radius-lg: 24px;

    /* Effects */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --glass-bg: rgba(255, 255, 255, 0.9);
    --glass-border: 1px solid rgba(255, 255, 255, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    color: var(--color-text);
    line-height: 1.7;
    /* Increased for premium readability */
    background-color: var(--color-bg);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    /* Crisp text */
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-text-heading);
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.25;
    letter-spacing: -0.02em;
    /* Tight tracking for modern feel */
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

ul {
    list-style: none;
}

/* Utilities */
.container {
    max-width: 1280px;
    /* Slightly wider for modern screens */
    margin: 0 auto;
    padding: 0 2rem;
}

.text-center {
    text-align: center;
}

.bg-light {
    background-color: var(--color-bg);
}

/* Buttons - Premium Feel */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    box-shadow: var(--shadow-sm);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, #022c22 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-primary) 100%);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid rgba(255, 255, 255, 0.8);
    color: white;
    backdrop-filter: blur(4px);
}

.btn-secondary:hover {
    background-color: white;
    color: var(--color-primary);
    border-color: white;
}

/* Outline Button for Light Backgrounds */
.btn-outline {
    background-color: transparent;
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
}

.btn-outline:hover {
    background-color: var(--color-primary);
    color: white;
}

.btn-lime,
.btn-accent {
    background: #BED701;
    color: white;
}

.btn-lime:hover,
.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Specific button overrides for structure */
.btn.w-100 {
    width: 100%;
    border-radius: var(--radius-sm);
}


.btn-whatsapp {
    background-color: #25D366;
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 10px rgba(37, 211, 102, 0.3);
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    transform: translateY(-1px);
}

/* Header & Nav - Glassmorphism */
.header {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 0.75rem 0;
    transition: padding 0.3s ease;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-img {
    height: 55px;
    /* Refined size */
    transition: transform 0.3s;
}

.logo-img:hover {
    transform: scale(1.02);
}

/* Navbar */
.nav-list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--color-text-heading);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link.active {
    color: var(--color-primary);
}

.nav-link.active::after,
.nav-link:hover::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--color-accent);
    transform-origin: left;
    transform: scaleX(1);
    transition: transform 0.3s ease;
}

.nav-link::after {
    transform: scaleX(0);
}

/* Dropdown Menu - Premium Popover */
/* Dropdown Menu - Premium Popover */
.dropdown {
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
    /* Bridge gap safely */
    margin-bottom: -10px;
    /* Offset padding so layout doesn't break */
}

.dropdown-content {
    visibility: hidden;
    /* Use visibility instead of display for transitions */
    opacity: 0;
    position: absolute;
    background-color: white;
    min-width: 240px;
    box-shadow: var(--shadow-xl);
    z-index: 1000;
    border-radius: var(--radius-md);
    top: 100%;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    border: 1px solid var(--color-border);
    padding: 0.5rem;
    pointer-events: none;
    /* Prevent clicking while hidden */
}

/* Little arrow for dropdown */
.dropdown-content::before {
    content: "";
    position: absolute;
    top: -6px;
    left: 20px;
    width: 12px;
    height: 12px;
    background: white;
    transform: rotate(45deg);
    border-top: 1px solid var(--color-border);
    border-left: 1px solid var(--color-border);
}

.dropdown-content a {
    color: var(--color-text);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
    border-radius: var(--radius-sm);
    transition: all 0.2s;
    font-weight: 500;
}

.dropdown-content a:hover {
    background-color: #d1fae5;
    /* Stronger Emerald 100 */
    color: var(--color-primary);
    padding-left: 20px;
    /* Slide effect */
    font-weight: 600;
}

.dropdown:hover .dropdown-content {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    /* Enable clicking */
}

.dropdown>a i {
    font-size: 0.8em;
    margin-left: 4px;
    color: var(--color-accent);
}

/* Hero Section */
.hero,
.page-hero {
    height: 100vh;
    background-image: linear-gradient(rgba(6, 78, 59, 0.7), rgba(6, 78, 59, 0.5)), url('hero.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    position: relative;
    padding-top: 80px;
    /* Removed clip-path for straight edge */
    margin-bottom: 2rem;
}

.page-hero {
    height: 45vh;
    min-height: 350px;
    padding-top: 140px;
    /* Increased space for fixed header */
}

.hero-content {
    z-index: 2;
    max-width: 900px;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    letter-spacing: -0.04em;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    line-height: 1.1;
    color: #BED701;
}

.hero-subtitle {
    font-size: 1.35rem;
    font-weight: 300;
    margin-bottom: 3rem;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-cta {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Stats in Hero */
.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin-bottom: 3rem;
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem 3rem;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-count {
    font-size: 3rem;
    font-weight: 800;
    display: block;
    color: #BED701;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    opacity: 0.8;
}

/* Cards - Premium Elevation */
.problem-card,
.team-card,
.info-item,
.donation-card,
.stat-card,
.portal-sidebar,
.portal-main,
.form-box,
.auth-box {
    background: var(--color-surface);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--color-border);
}

.problem-card:hover,
.team-card:hover,
.donation-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-primary-light);
}

.problem-icon,
.team-avatar i,
.info-item i {
    font-size: 3rem;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
    display: inline-block;
}

/* Compact About Cards Layout */
.problem-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    /* Force 3 columns side-by-side */
    gap: 1.5rem;
    margin-top: 2rem;
}

.problem-card {
    padding: 1.5rem !important;
    /* Override shared padding */
    text-align: center;
}

.problem-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.problem-card p {
    font-size: 0.9rem;
    line-height: 1.5;
}

.problem-card .problem-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .problem-grid {
        grid-template-columns: 1fr;
        /* Stack on mobile */
    }
}

/* Form Styles - Clean & Modern */
.form-group {
    margin-bottom: 1.75rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-text-heading);
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
    background-color: var(--color-bg);
    transition: all 0.3s;
    color: var(--color-secondary);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(6, 78, 59, 0.1);
    /* Primary glow */
    background-color: white;
}

/* Checkbox styling */
input[type="checkbox"] {
    accent-color: var(--color-primary);
    width: 18px;
    height: 18px;
    margin-right: 8px;
}

/* Tabs */
.tabs {
    background: var(--color-bg);
    padding: 0.5rem;
    border-radius: var(--radius-md);
    border: none !important;
    /* Override inline styles from previous */
}

.tabs button {
    border-radius: var(--radius-sm);
    flex: 1;
    font-weight: 600;
    border: none;
    transition: all 0.3s;
}

.tabs button.active,
.tabs button:focus {
    /* Logic handled by JS, but style support */
    background: white;
    box-shadow: var(--shadow-sm);
    color: var(--color-primary);
}

/* Footer - Dark & Clean */
.footer {
    background-color: var(--color-secondary);
    color: #94a3b8;
    /* Slate 400 */
    padding: 5rem 0 2rem;
}

.footer h4 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.footer a {
    color: #cbd5e1;
}

.footer a:hover {
    color: var(--color-accent);
}

.newsletter-form input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
}

.newsletter-form input:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
}

/* Mobile Responsive */
.mobile-menu-toggle {
    display: none;
    font-size: 1.5rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-secondary);
}

@media (max-width: 960px) {
    .header-container {
        padding: 0 1.5rem;
    }

    .hero-title {
        font-size: 2.8rem;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        padding: 2rem;
        box-shadow: var(--shadow-xl);
        transform: translateY(-150%);
        opacity: 0;
        transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
        z-index: 900;
        border-top: 1px solid var(--color-border);
    }

    .nav.active {
        transform: translateY(0);
        opacity: 1;
    }

    .nav-list {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-link {
        font-size: 1.1rem;
    }

    .nav-link.active::after {
        display: none;
    }

    /* Simpler active state for mobile */
    .nav-link.active {
        color: var(--color-primary);
        font-weight: 700;
    }

    .dropdown {
        width: 100%;
        text-align: center;
    }

    .dropdown-content {
        position: relative;
        box-shadow: none;
        background: var(--color-bg);
        margin: 0.5rem 0 1.5rem;
        width: 100%;
        border: none;
        opacity: 1;
        transform: none;
        display: none;
        /* JS or CSS override needed for click to show? Hover inconsistent on touch */
    }

    .dropdown:hover .dropdown-content {
        display: block;
    }

    /* Basic fallback */

    .hero-stats {
        flex-direction: column;
        background: transparent;
        border: none;
        padding: 0;
        backdrop-filter: none;
    }

    /* Fix for Hero Overlap on Mobile */
    .hero {
        height: auto;
        min-height: 100vh;
        padding-top: 120px;
        padding-bottom: 4rem;
    }

    .page-hero {
        height: auto;
        min-height: 300px;
        padding-top: 180px;
        padding-bottom: 4rem;
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
}

/* About Page Layout */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
}

@media (max-width: 960px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        /* Ensures space between text/button and image */
    }
}

/* Partner Carousel Animation */
@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.carousel-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    padding: 2rem 0;
}

#partners-track {
    display: flex;
    gap: 4rem;
    width: max-content;
    animation: scroll 30s linear infinite;
    /* Slower for premium feel */
}

/* Pause animation on hover for user interaction */
#partners-track:hover {
    animation-play-state: paused;
}

.partner-item {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.partner-item img {
    max-height: 80px;
    /* Retain original colors */
    filter: none;
    opacity: 1;
    transition: all 0.4s ease;
    cursor: pointer;
}

.partner-item img:hover {
    transform: scale(1.1);
}

/* Donation Portal Styles */
.portal-container {
    max-width: 800px;
    margin: 4rem auto;
    padding: 0 1rem;
}

.donation-options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.donation-card {
    /* Base styles inherited from generic card, adding specifics */
    border: 2px solid var(--color-border);
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: 0.3s;
}

.donation-card:hover,
.donation-card.selected {
    border-color: var(--color-accent);
    background: #f0fff4;
    transform: translateY(-5px);
}

.donation-card h3 {
    color: var(--color-primary);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
    .donation-options {
        grid-template-columns: 1fr;
        /* Stack on mobile */
    }
}