/* ============================================================
   Hopeful Charity Foundation Trust - Main Stylesheet
   Premium NGO Website | Bootstrap 5 Based
   ============================================================ */

/* ---- CSS Variables ---- */
:root {
    --primary: #1B6B3E;
    --primary-dark: #145230;
    --primary-light: #28a060;
    --secondary: #F59E0B;
    --secondary-dark: #D97706;
    --accent: #E63946;
    --dark: #1a1a2e;
    --dark-light: #2d2d44;
    --gray-900: #212529;
    --gray-700: #495057;
    --gray-500: #6c757d;
    --gray-300: #dee2e6;
    --gray-100: #f8f9fa;
    --white: #ffffff;
    --body-bg: #ffffff;
    --font-primary: 'Poppins', sans-serif;
    --font-heading: 'Playfair Display', serif;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
    --radius: 8px;
    --radius-lg: 16px;
    --transition: all 0.3s ease;
}

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-primary);
    font-size: 15px;
    line-height: 1.7;
    color: var(--gray-700);
    background: var(--body-bg);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--dark);
    line-height: 1.3;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}
a:hover { color: var(--primary-dark); }

img { max-width: 100%; height: auto; }

/* ---- Skip Link (Accessibility) ---- */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--primary);
    color: #fff;
    padding: 10px 20px;
    z-index: 99999;
    transition: top 0.3s;
}
.skip-link:focus { top: 0; color: #fff; }

/* ---- Preloader ---- */
.preloader {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: #fff;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease;
}
.preloader.loaded { opacity: 0; pointer-events: none; }
.preloader-icon {
    width: 50px; height: 50px;
    border: 4px solid var(--gray-300);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- Top Bar ---- */
.top-bar {
    background: var(--dark);
    padding: 8px 0;
    font-size: 13px;
    color: #ccc;
}
.top-bar a { color: #ddd; }
.top-bar a:hover { color: var(--secondary); }
.top-bar-social a {
    width: 28px; height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 12px;
}
.top-bar-social a:hover { background: var(--primary); color: #fff; }

/* ---- Navbar ---- */
.main-navbar {
    background: #fff;
    box-shadow: var(--shadow-sm);
    padding: 12px 0;
    transition: var(--transition);
    z-index: 9999;
}
.main-navbar.scrolled {
    padding: 8px 0;
    box-shadow: var(--shadow-md);
}
.logo-img { max-height: 50px; width: auto; }
.brand-text {
    font-family: var(--font-heading);
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
    line-height: 1.2;
    white-space: nowrap;
}
.navbar-nav .nav-link {
    font-weight: 500;
    font-size: 14.5px;
    color: var(--dark);
    padding: 8px 16px !important;
    position: relative;
    transition: var(--transition);
}
.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active { color: var(--primary); }
.navbar-nav .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 2px; left: 16px; right: 16px;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
}
.dropdown-menu {
    border: none;
    box-shadow: var(--shadow-md);
    border-radius: var(--radius);
    padding: 10px 0;
    min-width: 200px;
}
.dropdown-item {
    padding: 8px 20px;
    font-size: 14px;
    transition: var(--transition);
}
.dropdown-item:hover {
    background: var(--primary);
    color: #fff;
}
.btn-donate {
    background: var(--accent);
    color: #fff !important;
    font-weight: 600;
    padding: 10px 24px;
    border-radius: 50px;
    font-size: 14px;
    box-shadow: 0 4px 12px rgba(230,57,70,0.3);
    transition: var(--transition);
}
.btn-donate:hover {
    background: #c62833;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(230,57,70,0.4);
}

/* ---- Section Styling ---- */
section { padding: 80px 0; }
.section-title {
    text-align: center;
    margin-bottom: 50px;
}
.section-title h2 {
    font-size: 36px;
    margin-bottom: 12px;
    color: var(--dark);
}
.section-title p {
    font-size: 16px;
    color: var(--gray-500);
    max-width: 600px;
    margin: 0 auto;
}
.section-title .title-line {
    width: 60px; height: 3px;
    background: var(--primary);
    margin: 12px auto 0;
    border-radius: 3px;
}
.section-title .title-line::after {
    content: '';
    display: block;
    width: 30px; height: 3px;
    background: var(--secondary);
    margin: 5px auto 0;
    border-radius: 3px;
}
.bg-light-section { background: var(--gray-100); }
.bg-primary-section { background: var(--primary); color: #fff; }

/* ---- Hero Slider ---- */
.hero-slider { position: relative; overflow: hidden; padding: 0; }
.hero-slide {
    position: relative;
    height: 600px;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
}
.hero-slide::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(27,107,62,0.75) 0%, rgba(26,26,46,0.6) 100%);
}
.hero-content {
    position: relative;
    z-index: 2;
    max-width: 650px;
    color: #fff;
}
.hero-content h1 {
    font-size: 48px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 16px;
    line-height: 1.2;
}
.hero-content p {
    font-size: 18px;
    margin-bottom: 28px;
    opacity: 0.9;
}
.hero-content .btn {
    padding: 14px 32px;
    font-weight: 600;
    font-size: 15px;
    border-radius: 50px;
}
.btn-hero-primary {
    background: var(--secondary);
    color: var(--dark);
    border: none;
}
.btn-hero-primary:hover { background: var(--secondary-dark); color: #fff; }
.btn-hero-outline {
    border: 2px solid #fff;
    color: #fff;
    background: transparent;
}
.btn-hero-outline:hover { background: #fff; color: var(--dark); }
.hero-slider .swiper-pagination-bullet { background: #fff; opacity: 0.5; width: 12px; height: 12px; }
.hero-slider .swiper-pagination-bullet-active { opacity: 1; background: var(--secondary); }

/* ---- Stats / Counter Section ---- */
.stats-section {
    background: var(--primary);
    padding: 60px 0;
    position: relative;
    margin-top: -50px;
    z-index: 10;
    border-radius: var(--radius-lg);
}
.stat-card {
    text-align: center;
    color: #fff;
    padding: 20px;
}
.stat-card .stat-icon { font-size: 36px; margin-bottom: 10px; color: var(--secondary); }
.stat-card .stat-number { font-size: 42px; font-weight: 800; font-family: var(--font-primary); }
.stat-card .stat-label { font-size: 14px; opacity: 0.85; margin-top: 4px; }

/* ---- Services / Programs ---- */
.service-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 35px 25px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
    border: 1px solid transparent;
}
.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}
.service-card .service-icon {
    width: 75px; height: 75px;
    display: inline-flex;
    align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    color: #fff;
    font-size: 28px;
    border-radius: 50%;
    margin-bottom: 20px;
}
.service-card h4 { font-size: 18px; margin-bottom: 12px; }
.service-card p { font-size: 14px; color: var(--gray-500); }

/* ---- Projects ---- */
.project-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}
.project-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.project-card img { width: 100%; height: 220px; object-fit: cover; }
.project-card .project-body { padding: 20px; }
.project-card .project-category {
    display: inline-block;
    background: var(--primary);
    color: #fff;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 50px;
    margin-bottom: 10px;
    font-weight: 500;
}
.project-card h4 { font-size: 17px; margin-bottom: 8px; }
.project-card p { font-size: 13.5px; color: var(--gray-500); }
.project-progress {
    height: 6px;
    background: var(--gray-300);
    border-radius: 6px;
    overflow: hidden;
    margin-top: 12px;
}
.project-progress .progress-bar { background: var(--primary); border-radius: 6px; }

/* ---- Gallery ---- */
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.gallery-item {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
}
.gallery-item img { width: 100%; height: 220px; object-fit: cover; transition: var(--transition); }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item .gallery-overlay {
    position: absolute; inset: 0;
    background: rgba(27,107,62,0.7);
    display: flex; align-items: center; justify-content: center;
    opacity: 0;
    transition: var(--transition);
}
.gallery-item:hover .gallery-overlay { opacity: 1; }
.gallery-overlay i { font-size: 28px; color: #fff; }

/* ---- Testimonials ---- */
.testimonial-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: var(--shadow-sm);
    position: relative;
}
.testimonial-card::before {
    content: '\201C';
    font-size: 60px;
    color: var(--primary);
    opacity: 0.2;
    position: absolute;
    top: 10px; left: 20px;
    font-family: serif;
    line-height: 1;
}
.testimonial-card p { font-size: 15px; font-style: italic; color: var(--gray-700); margin-bottom: 16px; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-author img { width: 50px; height: 50px; border-radius: 50%; object-fit: cover; }
.testimonial-author h5 { font-size: 15px; margin: 0; font-family: var(--font-primary); }
.testimonial-author small { font-size: 12px; color: var(--gray-500); }
.testimonial-stars { color: var(--secondary); font-size: 13px; margin-bottom: 12px; }

/* ---- CTA Section ---- */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 80px 0;
    color: #fff;
    text-align: center;
}
.cta-section h2 { color: #fff; font-size: 36px; margin-bottom: 16px; }
.cta-section p { font-size: 17px; opacity: 0.9; margin-bottom: 30px; max-width: 600px; margin-left: auto; margin-right: auto; }
.btn-cta {
    background: var(--secondary);
    color: var(--dark);
    font-weight: 700;
    padding: 14px 36px;
    border-radius: 50px;
    font-size: 16px;
    border: none;
    transition: var(--transition);
}
.btn-cta:hover { background: #fff; color: var(--primary); transform: translateY(-3px); }

/* ---- News Cards ---- */
.news-card {
    background: #fff;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}
.news-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.news-card img { width: 100%; height: 200px; object-fit: cover; }
.news-card .news-body { padding: 20px; }
.news-card .news-date { font-size: 12px; color: var(--primary); font-weight: 600; margin-bottom: 8px; }
.news-card h4 { font-size: 16px; margin-bottom: 10px; line-height: 1.4; }
.news-card p { font-size: 13.5px; color: var(--gray-500); }

/* ---- Newsletter Section ---- */
.newsletter-section { background: var(--dark); padding: 60px 0; color: #fff; }
.newsletter-section h3 { color: #fff; margin-bottom: 8px; }
.newsletter-section p { opacity: 0.7; margin-bottom: 20px; }
.newsletter-form .form-control {
    padding: 14px 20px;
    border-radius: 50px 0 0 50px;
    border: none;
    font-size: 15px;
}
.newsletter-form .btn {
    border-radius: 0 50px 50px 0;
    padding: 14px 30px;
    font-weight: 600;
    background: var(--secondary);
    border: none;
    color: var(--dark);
}
.newsletter-form .btn:hover { background: var(--primary-light); color: #fff; }

/* ---- Footer ---- */
.site-footer { background: var(--dark); color: #b0b0b0; }
.footer-top { padding: 70px 0 40px; }
.footer-widget-title {
    color: #fff;
    font-size: 18px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 12px;
    font-family: var(--font-primary);
    font-weight: 600;
}
.footer-widget-title::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 40px; height: 2px;
    background: var(--primary);
}
.footer-about-text { font-size: 14px; line-height: 1.8; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: #b0b0b0; font-size: 14px; }
.footer-links a:hover { color: var(--secondary); padding-left: 5px; }
.footer-contact { list-style: none; padding: 0; margin: 0; }
.footer-contact li { display: flex; gap: 12px; margin-bottom: 14px; font-size: 14px; }
.footer-contact i { color: var(--primary-light); margin-top: 4px; }
.footer-social a {
    width: 36px; height: 36px;
    display: inline-flex;
    align-items: center; justify-content: center;
    background: rgba(255,255,255,0.08);
    color: #fff;
    border-radius: 50%;
    margin-right: 8px;
    transition: var(--transition);
}
.footer-social a:hover { background: var(--primary); color: #fff; transform: translateY(-3px); }
.footer-newsletter .form-control {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    font-size: 13px;
    padding: 10px 14px;
    border-radius: var(--radius) 0 0 var(--radius);
}
.footer-newsletter .btn { border-radius: 0 var(--radius) var(--radius) 0; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 20px 0;
    font-size: 13px;
}
.footer-bottom-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    flex-wrap: wrap;
}
.footer-bottom-links a { color: #aaa; }
.footer-bottom-links a:hover { color: var(--secondary); }

/* ---- WhatsApp Float ---- */
.whatsapp-float {
    position: fixed;
    bottom: 30px; right: 30px;
    width: 56px; height: 56px;
    display: flex;
    align-items: center; justify-content: center;
    background: #25D366;
    color: #fff;
    font-size: 28px;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(37,211,102,0.4);
    z-index: 9990;
    transition: var(--transition);
    animation: pulse-wa 2s infinite;
}
.whatsapp-float:hover { transform: scale(1.1); color: #fff; }
@keyframes pulse-wa {
    0%, 100% { box-shadow: 0 0 0 0 rgba(37,211,102,0.4); }
    50% { box-shadow: 0 0 0 12px rgba(37,211,102,0); }
}

/* ---- Back to Top ---- */
.back-to-top {
    position: fixed;
    bottom: 100px; right: 30px;
    width: 44px; height: 44px;
    display: none;
    align-items: center; justify-content: center;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 16px;
    cursor: pointer;
    z-index: 9990;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}
.back-to-top.show { display: flex; }
.back-to-top:hover { background: var(--primary-dark); transform: translateY(-3px); }

/* ---- Page Banner ---- */
.page-banner {
    background: linear-gradient(135deg, var(--primary) 0%, var(--dark) 100%);
    padding: 80px 0 60px;
    text-align: center;
    color: #fff;
    position: relative;
}
.page-banner h1 { color: #fff; font-size: 38px; margin-bottom: 12px; }
.page-banner .breadcrumb { justify-content: center; margin: 0; }
.page-banner .breadcrumb-item a { color: rgba(255,255,255,0.7); }
.page-banner .breadcrumb-item.active { color: var(--secondary); }
.page-banner .breadcrumb-item+.breadcrumb-item::before { color: rgba(255,255,255,0.5); }

/* ---- Forms ---- */
.form-control, .form-select {
    padding: 12px 16px;
    border-radius: var(--radius);
    border: 1px solid var(--gray-300);
    font-size: 14px;
    transition: var(--transition);
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(27,107,62,0.1);
}
.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
    font-weight: 600;
    padding: 12px 28px;
    border-radius: var(--radius);
}
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-secondary-custom {
    background: var(--secondary);
    border: none;
    color: var(--dark);
    font-weight: 600;
    padding: 12px 28px;
    border-radius: var(--radius);
}
.btn-secondary-custom:hover { background: var(--secondary-dark); color: #fff; }

/* ---- Donate Page ---- */
.donate-form-wrapper {
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 40px;
}
.amount-btn {
    padding: 12px 20px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius);
    background: transparent;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.amount-btn:hover, .amount-btn.active {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
}
.payment-gateway-card {
    border: 2px solid var(--gray-300);
    border-radius: var(--radius);
    padding: 16px;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
}
.payment-gateway-card:hover, .payment-gateway-card.selected {
    border-color: var(--primary);
    background: rgba(27,107,62,0.05);
}

/* ---- Team ---- */
.team-card {
    text-align: center;
    padding: 30px 20px;
    border-radius: var(--radius-lg);
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}
.team-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.team-card img {
    width: 120px; height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--primary);
    margin-bottom: 16px;
}
.team-card h5 { font-size: 16px; margin-bottom: 4px; font-family: var(--font-primary); font-weight: 600; }
.team-card small { color: var(--primary); font-weight: 500; }
.team-card .team-social a {
    width: 32px; height: 32px;
    display: inline-flex;
    align-items: center; justify-content: center;
    border-radius: 50%;
    background: var(--gray-100);
    color: var(--gray-700);
    margin: 0 4px;
    font-size: 13px;
}
.team-card .team-social a:hover { background: var(--primary); color: #fff; }

/* ---- Events ---- */
.event-card {
    display: flex;
    gap: 20px;
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 20px;
    transition: var(--transition);
}
.event-card:hover { box-shadow: var(--shadow-md); }
.event-date-box {
    min-width: 70px;
    text-align: center;
    background: var(--primary);
    color: #fff;
    border-radius: var(--radius);
    padding: 12px 8px;
    flex-shrink: 0;
}
.event-date-box .day { font-size: 28px; font-weight: 800; line-height: 1; }
.event-date-box .month { font-size: 12px; text-transform: uppercase; }

/* ---- FAQ ---- */
.faq-accordion .accordion-item {
    border: 1px solid var(--gray-300);
    border-radius: var(--radius) !important;
    margin-bottom: 12px;
    overflow: hidden;
}
.faq-accordion .accordion-button {
    font-weight: 600;
    font-size: 15px;
    color: var(--dark);
    padding: 16px 20px;
}
.faq-accordion .accordion-button:not(.collapsed) { background: var(--primary); color: #fff; }
.faq-accordion .accordion-body { font-size: 14px; color: var(--gray-700); padding: 16px 20px; }

/* ---- Partners ---- */
.partner-logo {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100px;
    filter: grayscale(1);
    opacity: 0.6;
    transition: var(--transition);
}
.partner-logo:hover { filter: grayscale(0); opacity: 1; }
.partner-logo img { max-height: 60px; max-width: 140px; }

/* ---- About Page ---- */
.about-image-wrapper { position: relative; }
.about-image-wrapper img { border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.about-badge {
    position: absolute;
    bottom: -20px; right: -20px;
    background: var(--secondary);
    color: var(--dark);
    padding: 16px 24px;
    border-radius: var(--radius);
    font-weight: 700;
    font-size: 18px;
    box-shadow: var(--shadow-md);
}
.mission-vision-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--primary);
    height: 100%;
}
.mission-vision-card h4 { color: var(--primary); margin-bottom: 12px; }

/* ---- Contact Page ---- */
.contact-info-card {
    text-align: center;
    padding: 30px 20px;
    border-radius: var(--radius-lg);
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    height: 100%;
}
.contact-info-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.contact-info-card .icon {
    width: 60px; height: 60px;
    display: inline-flex;
    align-items: center; justify-content: center;
    background: rgba(27,107,62,0.1);
    color: var(--primary);
    border-radius: 50%;
    font-size: 22px;
    margin-bottom: 16px;
}

/* ---- Policy Pages ---- */
.policy-content h2 { font-size: 22px; color: var(--primary); margin-top: 30px; margin-bottom: 12px; }
.policy-content h3 { font-size: 18px; margin-top: 24px; margin-bottom: 10px; }
.policy-content p { margin-bottom: 14px; }
.policy-content ul { padding-left: 20px; margin-bottom: 14px; }
.policy-content ul li { margin-bottom: 6px; }

/* ---- Volunteer Form ---- */
.volunteer-benefits li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
}
.volunteer-benefits li i { color: var(--primary); font-size: 18px; margin-top: 2px; }

/* ---- Utility ---- */
.text-primary-custom { color: var(--primary) !important; }
.bg-primary-custom { background: var(--primary) !important; }
.fw-600 { font-weight: 600; }
.letter-spacing-1 { letter-spacing: 1px; }
.hover-lift { transition: var(--transition); }
.hover-lift:hover { transform: translateY(-5px); }
