/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Baloo 2', sans-serif;
    line-height: 1.6;
    color: #444444;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: #00E676;
    z-index: 10000;
    transition: width 0.3s ease;
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

.scroll-to-top.show {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    background: #66BB6A;
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 25px rgba(76, 175, 80, 0.4);
}

/* Animation Classes */
.animate-in {
    animation: slideInUp 0.8s ease-out forwards;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Ripple Effect */
.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    transform: scale(0);
    animation: rippleAnimation 0.6s linear;
    pointer-events: none;
}

@keyframes rippleAnimation {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Button Enhancements */
button, .explore-btn, .signup-btn, .follow-btn {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    transition: all 0.3s ease;
}

button:hover, .explore-btn:hover, .signup-btn:hover, .follow-btn:hover {
    transform: scale(1.05);
}

/* Lazy Loading */
img.lazy {
    opacity: 0;
    transition: opacity 0.3s;
}

img.lazy.loaded {
    opacity: 1;
}

/* Initial Animation States */
.hero-content > * {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.about-images img {
    opacity: 0;
    transform: translateY(30px) scale(0.8);
    transition: all 0.6s ease;
}

.program-images img {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.6s ease;
}

.section-title {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

section {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

/* Enhanced Hover Effects */
.hero-image img:hover {
    transform: scale(1.05) rotate(2deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.about-images img:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

/* Mobile Toggle Button */
.mobile-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    width: 30px;
    height: 30px;
    justify-content: space-between;
}

.mobile-toggle span {
    display: block;
    height: 3px;
    width: 100%;
    background: #212121;
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Navigation Bar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: #FFFFFF;
    backdrop-filter: blur(10px);
    z-index: 9999;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transform: translateY(0);
}

.navbar.scrolled {
    padding: 0.5rem 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
    position: relative;
}

.nav-logo img {
    height: 80px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.navbar.scrolled .nav-logo img {
    height: 50px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    transition: all 0.3s ease;
}

.nav-menu a {
    text-decoration: none;
    color: #212121;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    padding: 0.5rem 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background: #4CAF50;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-menu a:hover::after {
    width: 100%;
}

.nav-menu a:hover {
    color: #4CAF50;
    transform: translateY(-2px);
}

/* ALL SECTIONS - Keep original background sizing, adjust only on mobile */
.hero-section,
.about-section,
.services-section,
.mission-section,
.purpose-section,
.program-section {
    width: 100%;
    height: 100vh;
    background-size: 100% 100%; /* Keep original stretching behavior */
    background-attachment: fixed;
    background-repeat: no-repeat;
    background-position: center;
    display: flex;
    align-items: center;
    padding: 2rem 1rem;
    position: relative;
    overflow: hidden;
}

/* Hero section specific padding */
.hero-section {
    background-image: url('./img/section\ 1-01.jpg');
    padding: 1rem;
}

/* Individual Section Backgrounds */
.about-section {
    background-image: url('./img/section\ 2-01.jpg');
}

.services-section {
    background-image: url('./img/section\ 3-01.jpg');
}

.mission-section {
    background-image: url('./img/section\ 4-01.jpg');
}

.purpose-section {
    background-image: url('./img/section\ 5-01.jpg');
}

.program-section {
    background-image: url('./img/section\ 6-01.jpg');
}

/* Hero Section Specific */
.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    gap: 2rem;
    align-items: center;
    position: relative;
    z-index: 2;
    padding-top: 100px;
    width: 100%;
}

.hero-image img {
    width: 100%;
    max-width: 400px;
    height: auto;
    aspect-ratio: 1;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

.hero-image img:hover {
    transform: scale(1.05) rotate(2deg);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
}

.hero-content {
    text-align: left;
    color: #212121;
}

.hero-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
    color: #212121;
    font-family: 'Baloo 2', sans-serif;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { text-shadow: 0 0 20px rgba(76, 175, 80, 0.3); }
    to { text-shadow: 0 0 30px rgba(76, 175, 80, 0.5); }
}

.hero-subtitle {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    text-decoration: underline;
    color: #333333;
    font-weight: 600;
    animation: slideInLeft 1s ease-out 0.3s both;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: #444444;
    animation: slideInLeft 1s ease-out 0.6s both;
}

.hero-main-text {
    font-size: 1.5rem;
    line-height: 1.4;
    margin-bottom: 2rem;
    border: 3px solid #4CAF50;
    padding: 1.5rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    font-weight: 600;
    color: #212121;
    animation: slideInRight 1s ease-out 0.9s both;
    position: relative;
    overflow: hidden;
}

.hero-main-text::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(76, 175, 80, 0.1), transparent);
    transition: left 2s;
}

.hero-main-text:hover::before {
    left: 100%;
}

.explore-btn {
    background: #26A69A;
    color: #FFFFFF;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 25px rgba(38, 166, 154, 0.3);
    position: relative;
    overflow: hidden;
    animation: slideInUp 1s ease-out 1.2s both;
}

.explore-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    transition: all 0.4s ease;
    transform: translate(-50%, -50%);
}

.explore-btn:hover::before {
    width: 200px;
    height: 200px;
}

.explore-btn:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 40px rgba(38, 166, 154, 0.4);
    background: #1E88E5;
}

.hero-spacer {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    text-decoration: underline;
    color: #4CAF50;
    font-weight: 600;
}

/* Common Section Styles */
.section-container {
    
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    padding: 0 2rem;
}

.section-title {
    font-size: 104.0929px;
    text-align: center;
    margin-bottom: 3rem;
    color: #212121;
    font-weight: 400;
    font-family: 'Baloo 2', sans-serif;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

/* Section-specific title colors */
.about-title {
    color: #448D22 !important;
}

.services-title {
    color: #0D7AA4 !important;
}

.mission-title {
    color: #E7801C !important;
}

.purpose-title {
    color: #448D22 !important;
}

.program-title {
    color: #448D22 !important;
}

/* Content boxes */
.about-content,
.services-content,
.mission-content,
.purpose-content,
.program-content {
    background: rgba(255, 255, 255, 0.9);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    margin-bottom: 3rem;
}

/* About section - has border */
.about-content {
    border: 2px solid #448D22;
}

/* Other sections - no border */
.services-content,
.mission-content,
.purpose-content,
.program-content {
    border: none;
}

.about-content p,
.services-content p,
.mission-content p,
.purpose-content p,
.program-content p {
    font-size: 40px;
    line-height: 1.8;
    color: #648091;
    text-align: justify;
    font-family: 'Baloo 2', sans-serif;
}

.mission-content p {
    text-align: center;
    font-weight: 500;
}

/* About Images */
.about-images {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    justify-items: center;
    width: 100%;
}

.about-images img {
    width: 100%;
    max-width: 250px;
    height: auto;
    border-radius: 15px;
    transition: transform 0.4s ease;
    object-fit: contain;
}

.about-images img:hover {
    transform: scale(1.1);
}

/* Program Images */
.program-images {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.program-images img {
    width: 100%;
    max-width: 300px;
    height: auto;
    transition: transform 0.3s ease;
}

.rotated-img-1 {
    transform: rotate(-5deg);
}

.rotated-img-2 {
    transform: rotate(5deg);
}

.program-images img:hover {
    transform: scale(1.1) rotate(0deg);
}

/* Footer */
.footer {
    background: #1E1E1E;
    color: #CCCCCC;
    padding: 3rem 2rem 1rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.footer-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.follow-btn {
    background: #66BB6A;
    color: #FFFFFF;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    width: fit-content;
    position: relative;
    overflow: hidden;
}

.follow-btn:hover {
    background: #4CAF50;
    transform: translateY(-2px) scale(1.05);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    color: #CCCCCC;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #26A69A;
}

.footer-year {
    font-size: 1.2rem;
    font-weight: 600;
    color: #FFFFFF;
}

.footer-column:nth-child(2) {
    text-align: center;
}

.copyright {
    font-size: 0.9rem;
    color: #CCCCCC;
}

.footer-column:nth-child(3) {
    text-align: right;
}

.social-icons {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-bottom: 1rem;
}

.social-icons a {
    font-size: 1.5rem;
    color: #CCCCCC;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    color: #4CAF50;
    transform: scale(1.2);
}

.footer-settings {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    font-size: 0.9rem;
    color: #CCCCCC;
}

/* RESPONSIVE DESIGN - Proper scaling with smaller sizes */

/* Large Desktop */
@media (min-width: 1400px) {
    .section-container, .nav-container, .footer-container {
        max-width: 1400px;
    }
}

/* Desktop */
@media (max-width: 1200px) {
    .section-title { font-size: 70px; }
    .about-content p, .services-content p, .mission-content p, .purpose-content p, .program-content p { font-size: 28px; }
    .hero-image img { max-width: 350px; }
}

/* Large Tablet */
@media (max-width: 1024px) {
    .section-title { font-size: 50px; margin-bottom: 2rem; }
    .about-content p, .services-content p, .mission-content p, .purpose-content p, .program-content p { font-size: 20px; line-height: 1.5; }
    .about-content, .services-content, .mission-content, .purpose-content, .program-content { padding: 1.8rem; margin-bottom: 2rem; }
    
    .hero-container { grid-template-columns: 1fr 1.5fr; gap: 1.5rem; padding-top: 70px; }
    .hero-title { font-size: 1.8rem; }
    .hero-subtitle { font-size: 1.4rem; }
    .hero-description { font-size: 1rem; }
    .hero-main-text { font-size: 1.1rem; padding: 1rem; }
    .explore-btn { font-size: 0.95rem; padding: 0.8rem 1.5rem; }
    .hero-image img { max-width: 280px; }
    
    .about-images { grid-template-columns: repeat(2, 1fr); gap: 1.2rem; }
    .about-images img { max-width: 150px; }
    .program-images img { max-width: 200px; }
}

/* Mobile - Remove background sizing, use natural dimensions */
@media (max-width: 768px) {
    /* Remove fixed attachment on mobile, no background sizing */
    .hero-section, .about-section, .services-section, .mission-section, .purpose-section, .program-section {
        background-attachment: scroll; /* Remove fixed for mobile performance */
        /* background-size removed - natural image dimensions */
        padding: 1.5rem 0.8rem;
        overflow: hidden;
    }
    
    /* Mobile Navigation */
    .mobile-toggle { display: flex; }
    .nav-menu {
        position: absolute; top: 100%; left: 0; width: 100%; flex-direction: column; background: #FFFFFF;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1); padding: 1.5rem; gap: 0.8rem;
        transform: translateY(-100%); opacity: 0; visibility: hidden; transition: all 0.3s ease;
    }
    .nav-menu.active { transform: translateY(0); opacity: 1; visibility: visible; }
    .nav-logo img { height: 45px; }
    .navbar.scrolled .nav-logo img { height: 30px; }
    
    /* Content Scaling - Mobile */
    .section-title { font-size: 32px; margin-bottom: 1.2rem; }
    .about-content p, .services-content p, .mission-content p, .purpose-content p, .program-content p { 
        font-size: 14px; line-height: 1.4; text-align: left; 
    }
    .about-content, .services-content, .mission-content, .purpose-content, .program-content { 
        padding: 1.2rem; margin-bottom: 1.2rem; max-width: calc(100% - 1.6rem); /* Ensure stays inside padding */
    }
    
    /* Hero Mobile */
    .hero-container { grid-template-columns: 1fr; text-align: center; gap: 1.5rem; padding-top: 70px; }
    .hero-title { font-size: 1.3rem; }
    .hero-subtitle { font-size: 1.1rem; }
    .hero-description { font-size: 0.9rem; }
    .hero-main-text { font-size: 0.95rem; padding: 0.8rem; }
    .explore-btn { font-size: 0.85rem; padding: 0.7rem 1.3rem; }
    .hero-image img { max-width: 180px; }
    
    /* Images Mobile */
    .about-images { grid-template-columns: repeat(2, 1fr); gap: 0.8rem; }
    .about-images img { max-width: 90px; }
    .program-images { flex-direction: column; align-items: center; gap: 1rem; }
    .program-images img { max-width: 150px; }
    
    /* Sections Mobile - Content must stay inside padding */
    .section-container { padding: 0 0.8rem; max-width: calc(100% - 1.6rem); }
    
    /* Footer Mobile */
    .footer { padding: 1.5rem 0.8rem 0.8rem; }
    .footer-container { grid-template-columns: 1fr; text-align: center; gap: 1.2rem; }
    .footer-column:nth-child(3) { text-align: center; }
    .social-icons { justify-content: center; }
    .footer-settings { justify-content: center; font-size: 0.8rem; }
    .follow-btn { font-size: 0.9rem; padding: 0.7rem 1.4rem; }
    .footer-links a { font-size: 0.85rem; }
    .footer-year { font-size: 1rem; }
    .copyright { font-size: 0.8rem; }
    .scroll-to-top { bottom: 12px; right: 12px; width: 35px; height: 35px; font-size: 14px; }
}

/* Small Mobile - No background sizing */
@media (max-width: 480px) {
    /* No background sizing, use natural dimensions */
    .hero-section, .about-section, .services-section, .mission-section, .purpose-section, .program-section {
        /* background-size removed - natural image dimensions */
        padding: 1.2rem 0.8rem;
    }
    
    .section-title { font-size: 26px; margin-bottom: 1rem; }
    .about-content p, .services-content p, .mission-content p, .purpose-content p, .program-content p { font-size: 12px; line-height: 1.3; }
    .about-content, .services-content, .mission-content, .purpose-content, .program-content { 
        padding: 1rem; max-width: calc(100% - 1.6rem); 
    }
    
    .hero-title { font-size: 1.1rem; }
    .hero-subtitle { font-size: 0.95rem; }
    .hero-description { font-size: 0.8rem; }
    .hero-main-text { font-size: 0.85rem; padding: 0.7rem; }
    .explore-btn { font-size: 0.8rem; padding: 0.6rem 1.2rem; }
    .hero-image img { max-width: 140px; }
    .hero-container { gap: 1.2rem; }
    
    .about-images { grid-template-columns: 1fr; gap: 0.8rem; }
    .about-images img { max-width: 100px; }
    .program-images img { max-width: 120px; }
    
    .section-container { padding: 0 0.8rem; max-width: calc(100% - 1.6rem); }
}

/* Extra Small Mobile - No background sizing */
@media (max-width: 360px) {
    /* No background sizing, use natural dimensions */
    .hero-section, .about-section, .services-section, .mission-section, .purpose-section, .program-section {
        /* background-size removed - natural image dimensions */
        padding: 1rem 0.6rem;
    }
    
    .section-title { font-size: 22px; margin-bottom: 0.8rem; }
    .about-content p, .services-content p, .mission-content p, .purpose-content p, .program-content p { font-size: 11px; line-height: 1.2; }
    .about-content, .services-content, .mission-content, .purpose-content, .program-content { 
        padding: 0.8rem; max-width: calc(100% - 1.2rem); 
    }
    
    .hero-title { font-size: 1rem; }
    .hero-subtitle { font-size: 0.85rem; }
    .hero-description { font-size: 0.75rem; }
    .hero-main-text { font-size: 0.8rem; padding: 0.6rem; }
    .explore-btn { font-size: 0.75rem; padding: 0.5rem 1rem; }
    .hero-image img { max-width: 120px; }
    
    .about-images img { max-width: 85px; }
    .program-images img { max-width: 100px; }
    
    .nav-container, .section-container { padding: 0 0.6rem; max-width: calc(100% - 1.2rem); }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    *, .hero-image img { animation: none !important; transition-duration: 0.01ms !important; }
    body { scroll-behavior: auto !important; }
}