/* styles/utilities/responsive.css */

/* styles/utilities/responsive.css - UPDATED Navigation Section */
@media (max-width: 768px) {
    /* Force hide nav links by default */
    .nav-links {
        display: none !important;
        position: fixed;
        top: 80px;
        right: 1rem; /* Changed from left: 0, right: 0 */
        left: auto; /* Allow it to size from the right */
        width: 180px; /* Set a fixed width */
        background: var(--bg-primary);
        flex-direction: column;
        padding: 1rem 0.5rem; /* Reduced padding */
        box-shadow: 0 4px 20px rgba(0,0,0,0.3);
        border-radius: 12px; /* Add rounded corners */
        z-index: 999;
        max-height: calc(100vh - 100px);
        overflow-y: auto;
        opacity: 0;
        transform: translateY(-20px);
        transition: opacity 0.3s ease, transform 0.3s ease;
        gap: 0.3rem; /* Reduced gap between items */
    }

    .nav-links.active {
        display: flex !important;
        opacity: 1;
        transform: translateY(0);
    }

    .nav-links li {
        margin: 0;
        width: 100%;
    }

    /* UPDATED: Remove background, add underline instead */
    .nav-links a {
        padding: 0.7rem 0.3rem; /* Reduced padding */
        display: block;
        width: 100%;
        border-radius: 8px; /* Smaller border radius */
        transition: all 0.3s ease;
        text-align: center;
        position: relative;
        font-size: 0.80rem; /* Slightly smaller text */
    }

    /* UPDATED: Remove background highlight, use underline */
    .nav-links a:hover,
    .nav-links a.active {
        background: transparent !important; /* No background */
        color: var(--primary);
    }

    /* NEW: Add underline for hover and active states */
    .nav-links a::after {
        content: '';
        position: absolute;
        bottom: 8px; /* Position from bottom */
        left: 50%;
        transform: translateX(-50%);
        width: 0;
        height: 2px;
        background: var(--primary);
        transition: width 0.3s ease;
    }

    /* Show underline on hover */
    .nav-links a:hover::after {
        width: 60%; /* Underline width - 60% of the link */
    }

    /* Show underline for active page */
    .nav-links a.active::after {
        width: 60%; /* Same width as hover */
    }

    /* Theme toggle container - centered, no text */
    .theme-toggle-container {
        display: flex !important;
        align-items: center;
        justify-content: center; /* Center the toggle */
        padding: 0.7rem 0.3rem;
    }

    .theme-toggle-container span {
        display: none; /* Hide the "Theme" text */
    }

    .theme-toggle-container .theme-toggle {
        margin: 0; /* Remove any margins */
    }

    /* Mobile menu icon */
    .mobile-menu {
        display: block !important;
        cursor: pointer;
        padding: 0.5rem;
        z-index: 1001;
        transition: transform 0.3s ease;
    }

    .mobile-menu i {
        font-size: 1rem;
        color: var(--text-primary);
        transition: transform 0.3s ease;
    }

    /* Rotate icon when menu is open */
    .mobile-menu.active i {
        transform: rotate(90deg);
    }

    /* Prevent body scroll when menu is open */
    body.menu-open {
        overflow: hidden;
        position: fixed;
        width: 100%;
        height: 100%;
    }

    /* Dark overlay when menu is open */
    body.menu-open::after {
        content: '';
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 998;
        animation: fadeIn 0.3s ease;
    }

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

@media (max-width: 768px) {
    .hero {
        min-height: auto;
        padding: 2rem 0;
    }

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

    /* Text styling */
    .hero-heading h1 {
        font-size: 2.2rem;
        line-height: 1.1;
    }

    .typed-container {
        min-height: 2.8rem;
        display: flex;
        align-items: center;
        justify-content: flex-start;
    }

    .typed-text {
        font-size: 2.2rem;
        min-width: 220px;
    }

    .hero-description {
        gap: 1.5rem;
    }

    .hero-description p {
        font-size: 1rem;
        line-height: 1.6;
    }

    /* Buttons */
    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
    }

    .btn-primary, 
    .btn-secondary {
        width: 100%;
        text-align: center;
        padding: 0.9rem 1.5rem;
    }

    /* Image adjustments */
    .hero-image {
        max-width: 100%;
        margin-top: 1rem;
    }

    .hero-image::after {
        top: 15px;
        left: 15px;
        right: -15px;
        bottom: -15px;
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .hero-heading h1 {
        font-size: 1.8rem;
    }

    .typed-text {
        font-size: 1.8rem;
        min-width: 180px;
    }

    .typed-container {
        min-height: 2.4rem;
    }

    .hero-description p {
        font-size: 0.95rem;
    }
}

    /* General Sections - Smaller fonts */
    .section-title {
        font-size: 1.8rem;
    }

    .section-subtitle {
        font-size: 0.95rem;
    }

    /* Schedule Section - List form instead of scroll */
    .schedule-cards {
        display: grid !important;
        grid-template-columns: 1fr;
        gap: 1.5rem;
        overflow: visible;
        scroll-snap-type: none;
        padding: 0;
    }
    
    .schedule-card {
        flex: none;
        scroll-snap-align: none;
        min-width: auto;
        width: 100%;
    }

    /* Stats Container - Keep scroll */
    .stats-container {
        display: flex !important;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        padding: 1rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    .stats-container::-webkit-scrollbar {
        display: none;
    }
    
    .stat-item {
        flex: 0 0 70%;
        scroll-snap-align: center;
        min-width: 200px;
    }

    /* Social Media Feed - Scroll form */
    .social-grid {
        display: flex !important;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        padding: 1rem 0;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        justify-content: flex-start;
    }
    
    .social-grid::-webkit-scrollbar {
        display: none;
    }
    
    .social-card {
        flex: 0 0 85%;
        scroll-snap-align: center;
        min-width: 280px;
    }

    /* Countdown */
    .countdown-timer {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Contact */
    .contact-grid {
        grid-template-columns: 1fr;
    }

    /* Lightbox */
    .lightbox-nav {
        width: 45px;
        height: 45px;
        font-size: 2rem;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }
    
    
    /* Footer Dropdowns - Fix functionality */
    .footer-section {
        position: relative;
    }
    
    .footer-section h3 {
        cursor: pointer;
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1rem 0;
        user-select: none;
        margin: 0;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .footer-section h3::after {
        content: '\f078';
        font-family: 'Font Awesome 6 Free';
        font-weight: 900;
        font-size: 0.8rem;
        transition: transform 0.3s ease;
        opacity: 0.7;
    }
    
    .footer-section.active h3::after {
        transform: rotate(180deg);
    }
    
    .footer-section > a,
    .footer-section > p {
        display: none;
        margin-top: 0.5rem;
        padding: 0.5rem 0;
        animation: slideDown 0.3s ease;
    }
    
    .footer-section.active > a,
    .footer-section.active > p {
        display: block;
    }
    
    .footer-section > a:last-child,
    .footer-section > p:last-child {
        border-bottom: none;
    }
    
    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    /* Social links on mobile - Center and visible */
    .social-links {
        display: flex;
        justify-content: center;
        gap: 1.5rem;
        margin: 1rem 0 !important;
        padding: 1.5rem 0 !important;
        border-top: 1px solid rgba(255,255,255,0.1);
    }
    
    .social-links a {
        font-size: 1.8rem !important;
        margin: 0 !important;
        background: rgba(255,255,255,0.15);
        width: 55px;
        height: 55px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
    }

    .social-links a:hover {
        background: white;
        color: var(--primary);
        transform: scale(1.1);
    }

    /* CTA Section */
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .cta-box {
        padding: 1.5rem;
    }

    .cta-section h2 {
        font-size: 2rem;
    }

    /* About Section */
    .welcome-box {
        padding: 2rem;
    }

    .about-details {
        text-align: center;
    }

    /* Donate Section */
    .donate-intro {
        padding: 2rem;
    }

    .payment-methods {
        grid-template-columns: 1fr;
    }

    /* FAQ Section */
    .faq-question {
        padding: 1.2rem 1.5rem;
        font-size: 1rem;
    }

    .faq-answer {
        padding: 0 1.5rem 1.2rem;
    }

    /* YouTube/Podcast Section */
    .youtube-section .video-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .video-info h3 {
        font-size: 1.1rem;
    }

    .video-info p {
        font-size: 0.9rem;
    }


/* Desktop - Ensure mobile menu button is hidden */
@media (min-width: 769px) {
    .mobile-menu {
        display: none !important;
    }

    .nav-links {
        display: flex !important;
        position: static;
        flex-direction: row;
        background: transparent;
        padding: 0;
        box-shadow: none;
        max-height: none;
        opacity: 1;
        transform: none;
    }
}

/* MOBILE ONLY: Mission and Events Cards Scroll */
@media (max-width: 768px) {
    /* Mission Cards - Scroll only on mobile */
    .mission-grid {
        display: flex !important;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        padding: 1rem 0;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    .mission-grid::-webkit-scrollbar {
        display: none;
    }
    
    .mission-card {
        flex: 0 0 85%;
        scroll-snap-align: center;
        min-width: 280px;
    }
    
    /* Events Grid - Scroll only on mobile */
    .events-grid {
        display: flex !important;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        padding: 1rem 0;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    .events-grid::-webkit-scrollbar {
        display: none;
    }
    
    .event-card {
        flex: 0 0 85%;
        scroll-snap-align: center;
        min-width: 280px;
    }
}

/* Smaller mobile devices */
@media (max-width: 480px) {
    .hero-heading h1 {
        font-size: 1.8rem;
    }

    .typed-text {
        font-size: 1.8rem;
        min-width: 180px;
    }

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

    .schedule-card,
    .mission-card,
    .event-card,
    .social-card {
        padding: 1.5rem;
    }

    .social-links a {
        width: 50px;
        height: 50px;
        font-size: 1.6rem !important;
    }
}

/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: white;
    border-radius: 50%;
    text-align: center;
    font-size: 30px;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
}

.whatsapp-float i {
    line-height: 1;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    transform: scale(1.1);
    box-shadow: 3px 3px 15px rgba(0,0,0,0.4);
}

@media (max-width: 768px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
        font-size: 25px;
    }
}

/* Logo styling */
.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo img {
    display: block !important;
    height: 40px;
    width: auto;
    border-radius: 8px;
    object-fit: cover;
    
    /* Glow effect */
    filter: drop-shadow(0 0 15px rgba(147, 51, 234, 0.8));
}

.logo img:hover {
    filter: drop-shadow(0 0 25px rgba(147, 51, 234, 1));
}

/* Dark mode logo glow */
[data-theme="dark"] .logo img {
    filter: drop-shadow(0 0 20px rgba(147, 51, 234, 0.9));
}

[data-theme="dark"] .logo img:hover {
    filter: drop-shadow(0 0 30px rgba(147, 51, 234, 1));
}

@media (max-width: 768px) {
    .logo img {
        height: 35px;
    }
}