/* --- GLOBAL STYLES & VARIABLES --- */
:root {
    --color-primary: #ed1c24; /* Vibrant Red */
    --color-secondary: #0054a6; /* Deep Blue */
    --color-accent: #0054a6; /* Deep Blue */
    --color-dark: #1a202c;
    --color-light: #f7fafc;
    --color-text: #4a5568;
    --color-white: #ffffff;
    --font-family: 'Poppins', sans-serif;
    --header-height: 110px;
    --border-radius: 8px;
    --box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    --transition-speed: 0.3s ease;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-family);
    line-height: 1.7;
    color: var(--color-text);
    background-color: var(--color-white);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

h1, h2, h3, h4 {
    font-weight: 700;
    color: var(--color-dark);
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.1rem; }

p { margin-bottom: 1rem; }
a { text-decoration: none; color: var(--color-accent); transition: color var(--transition-speed); }
a:hover { color: var(--color-primary); }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

.section-padding { padding: 6rem 0; }
.bg-light { background-color: var(--color-light); }
.text-center { text-align: center; }
.section-header { margin-bottom: 4rem; }
.section-header p { max-width: 600px; margin-left: auto; margin-right: auto; }

/* --- BUTTONS --- */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    border: 2px solid transparent;
    transition: all var(--transition-speed);
    cursor: pointer;
    text-align: center;
}

.btn-primary { background-color: var(--color-primary); color: var(--color-white); }
.btn-primary:hover { background-color: transparent; color: var(--color-primary); border-color: var(--color-primary); }

.btn-secondary { background-color: var(--color-secondary); color: var(--color-white); }
.btn-secondary:hover { background-color: transparent; color: var(--color-secondary); border-color: var(--color-secondary); }

.btn-large { padding: 1rem 2.5rem; font-size: 1.1rem; }

/* --- HEADER --- */
.header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    height: var(--header-height);
    transition: all var(--transition-speed);
}
.header.scrolled {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    background-color: var(--color-white);
}

.main-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}
.logo img { height: 85px; }
.nav-links { display: flex; gap: 2rem; }
.nav-links a { font-weight: 600; color: var(--color-dark); position: relative; padding: 5px 0; }
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-primary);
    transition: width var(--transition-speed);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-buttons { display: flex; gap: 1rem; }
.hamburger { display: none; font-size: 1.5rem; background: none; border: none; cursor: pointer; color: var(--color-dark); z-index: 1001;}

/* --- HERO SECTION --- */
.hero-section {
    position: relative;
    height: calc(100vh - var(--header-height));
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    overflow: hidden;
}
.hero-video-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background-size: cover;
    background-position: center;
}
.hero-video-bg iframe {
    position: absolute;
    top: 0;
    left: 50%;
    width: 100vw;
    height: 56.25vw; /* 16:9 aspect ratio */
    min-width: 177.77vh; /* 16:9 aspect ratio for portrait screens */
    min-height: 100vh;
    transform: translateX(-50%);
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(26, 32, 44, 0.6);
    z-index: -1;
}
.hero-content { position: relative; z-index: 1; }
.hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: var(--color-white);
}
.hero-content p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 2rem;
    color: rgba(255, 255, 255, 0.9);
}
.hero-cta .btn { margin: 0 0.5rem; }

/* --- GRIDS --- */
.grid-2-col { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.grid-3-col { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-4-col { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }

/* --- FOUNDER'S STORY --- */
.founder-image img {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    width: 100%;
}
.founder-story-content blockquote {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--color-dark);
    border-left: 4px solid var(--color-primary);
    padding-left: 1.5rem;
    margin: 2rem 0;
}

/* --- MISSION & VISION --- */
.icon-feature {
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: 1rem;
    display: inline-block;
}
.mission-item p { max-width: 300px; margin: 0 auto; }

/* --- PROGRAMS & CARDS --- */
.card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
    display: flex;
    flex-direction: column;
}
.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}
.card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}
.card-content { padding: 2rem; flex-grow: 1; display: flex; flex-direction: column;}
.card-content h3 { color: var(--color-secondary); }
.card-content p { flex-grow: 1; }
.card-content .btn { margin-top: 1rem; }

/* --- PROGRAM DETAILS --- */
.program-details-section .grid-2-col { gap: 5rem; }
.program-details-image img { border-radius: var(--border-radius); box-shadow: var(--box-shadow); }

/* --- VIDEO CONTAINER for Program Details --- */
.video-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}
.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}


/* --- IMPACT COUNTER --- */
.parallax-bg {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    position: relative;
    color: var(--color-white);
}
.parallax-bg::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(0, 84, 166, 0.85); /* Deep Blue overlay */
}
.counter-item { position: relative; }
.counter-item h3 {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--color-white);
}
.counter-item p { font-size: 1.1rem; font-weight: 600; }

/* --- BOARD MEMBERS --- */
.board-members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 2rem;
}
.board-member-card { transition: transform var(--transition-speed); }
.board-member-card:hover { transform: translateY(-5px); }
.board-member-avatar {
    width: 150px;
    height: 150px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 4px solid var(--color-white);
}
.board-member-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.board-member-name { margin-bottom: 0.25rem; }
.board-member-title { font-size: 0.9rem; color: var(--color-text); }


/* --- GALLERY & PROGRAM SLIDERS --- */
.gallery-slider-wrapper,
.program-slider-wrapper {
    position: relative;
    max-width: 900px;
    margin: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
}

.gallery-slider .slide,
.program-slider .slide { 
    display: none; 
}
.gallery-slider .slide.active,
.program-slider .slide.active { 
    display: block; 
    animation: fadeIn 0.5s ease-in-out; 
}

.gallery-slider .slide img,
.program-slider .slide img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    display: block;
}
.program-slider .slide img {
    height: auto; /* Adjust for program slider aspect ratio */
}

.slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    padding: 3rem 1.5rem 1.5rem;
    font-weight: 600;
    font-size: 1.1rem;
}
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.8);
    border: none;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    font-size: 1.3rem;
    cursor: pointer;
    transition: all var(--transition-speed);
    color: var(--color-dark);
}
.slider-btn:hover { background-color: var(--color-primary); color: white; }
.slider-btn.prev { left: 1rem; }
.slider-btn.next { right: 1rem; }

/* --- GET INVOLVED --- */
.involve-card {
    padding: 2.5rem;
    transition: all var(--transition-speed);
    border-radius: var(--border-radius);
}
.involve-card:hover {
    background: var(--color-white);
    box-shadow: var(--box-shadow);
    transform: translateY(-5px);
}
.involve-card .btn { margin-top: 1rem; }

/* --- DONATE SECTION --- */
.donate-section {
    background-color: var(--color-accent);
    color: var(--color-white);
}
.donate-section h2 { color: var(--color-white); }
.donate-section p { max-width: 700px; margin: 0 auto 2rem; }
.donate-options {
    margin: 2rem 0;
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.btn-donate-option {
    padding: 0.8rem 1.5rem;
    background-color: transparent;
    border: 2px solid rgba(255,255,255,0.5);
    color: var(--color-white);
    border-radius: 50px;
    cursor: pointer;
    transition: all var(--transition-speed);
    font-weight: 600;
}
.btn-donate-option.active, .btn-donate-option:hover {
    background-color: var(--color-white);
    color: var(--color-accent);
}
.btn-donate-main { margin-top: 1rem; }

/* --- FORMS --- */
#contact-join.section-padding { padding-bottom: 6rem; }
.grid-2-col-forms { grid-template-columns: 1fr 1fr; gap: 4rem; align-items: flex-start; }
.form-container {
    background-color: var(--color-light);
    padding: 2.5rem;
    border-radius: var(--border-radius);
}
.form-container h3 { margin-bottom: 2rem; }
.form-group { margin-bottom: 1.5rem; }
.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-dark);
}
.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: var(--font-family);
    transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
    font-size: 1rem;
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(0, 84, 166, 0.25);
}
.form-response {
    margin-top: 1rem;
    padding: 0.8rem;
    border-radius: 5px;
    display: none;
    text-align: center;
}
.form-response.success { background-color: #d4edda; color: #155724; border: 1px solid #c3e6cb;}
.form-response.error { background-color: #f8d7da; color: #721c24; border: 1px solid #f5c6cb;}

/* --- FOOTER --- */
.main-footer {
    background-color: var(--color-dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 4rem 0 2rem;
}
.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--color-text);
    padding-bottom: 3rem;
}
.footer-logo { max-width: 120px; margin-bottom: 1rem; filter: brightness(0) invert(1); }
.footer-links h4, .footer-social h4 {
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--color-white);
}
.footer-links ul li { margin-bottom: 0.5rem; }
.footer-links a { color: rgba(255, 255, 255, 0.7); }
.footer-links a:hover { color: var(--color-white); }
.social-icons { display: flex; gap: 1rem; }
.social-icons a {
    color: var(--color-light);
    font-size: 1.5rem;
    width: 44px; height: 44px;
    display: grid;
    place-items: center;
    border: 1px solid var(--color-text);
    border-radius: 50%;
    transition: all var(--transition-speed);
}
.social-icons a:hover {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    transform: translateY(-3px);
}
.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    font-size: 0.9rem;
}

/* --- ANIMATIONS --- */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* --- RESPONSIVE DESIGN --- */
@media (max-width: 1024px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    .grid-3-col, .grid-4-col { grid-template-columns: 1fr 1fr; }
    .footer-content { grid-template-columns: 1fr 1fr; }
    .footer-about { grid-column: 1 / -1; }
    .program-details-section .grid-2-col { grid-template-columns: 1fr; }
    .program-details-image { margin-top: 3rem; }
    #program-details-carnival .program-details-image { order: -1; margin-top: 0; margin-bottom: 3rem; }
}

@media (max-width: 768px) {
    .section-padding { padding: 4rem 0; }
    .nav-buttons { display: none; }
    .hamburger { display: block; }
    
    .hero-video-bg iframe {
        display: none; /* Hide video on mobile for performance and data saving */
    }
    
    /* Mobile Nav Styles */
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background-color: var(--color-dark);
        flex-direction: column;
        align-items: flex-start;
        padding: 6rem 2rem 2rem;
        box-shadow: -10px 0 20px rgba(0,0,0,0.2);
        transition: right 0.4s cubic-bezier(0.23, 1, 0.32, 1);
        gap: 1.5rem;
    }
    .nav-links.active { right: 0; }
    .nav-links a { color: var(--color-white); font-size: 1.2rem;}
    .nav-links a::after { background-color: var(--color-primary); bottom: 0; }
    
    .hero-content h1 { font-size: 8vw; }
    .grid-2-col, .grid-2-col-forms { grid-template-columns: 1fr; }
    .founder-image { margin-bottom: 2rem; order: -1; }
    .counter-item:nth-child(n+3) { margin-top: 2rem; }
}

@media (max-width: 480px) {
    .grid-3-col, .grid-4-col { grid-template-columns: 1fr; }
    .counter-item:not(:first-child) { margin-top: 2rem; }
    .footer-content { grid-template-columns: 1fr; text-align: center; }
    .social-icons { justify-content: center; }
    .btn-large { padding: 0.8rem 1.8rem; font-size: 1rem; }
    .hero-cta { display: flex; flex-direction: column; gap: 1rem; align-items: center;}
    .board-members-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
    .board-member-avatar { width: 120px; height: 120px; }
}

