/* 1. Global Reset & Variables */
:root {
    --font-heading: 'Barlow', sans-serif;
    --font-body: 'Manrope', sans-serif;
    
    /* Colors extracted from reference image */
    --color-primary: #0071bc; 
    --color-secondary: #ed1c24; 
    --color-dark: #1a1a1a;
    --color-light: #ffffff;
    --color-gray-bg: #f8f9fa;
    --color-text-gray: #555555;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.3;
    color: var(--color-dark);
    background-color: var(--color-light);
    -webkit-font-smoothing: antialiased; 
    width: 100%;
}

/* 2. Typography */
h1, h2, h3, h4, h5 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.0;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 32px;
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    text-align: center;
    border-radius: 15px;
    cursor: pointer;
    width: auto;
    border: none;
    /* NEW: Smooth animation for hover state */
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--color-primary);
    color: white;
}

/* Primary Hover (Blue) */
.btn-primary:hover {
    background-color: #005a96; /* Darker Blue */
    transform: translateY(-3px); /* Lifts up */
    box-shadow: 0 5px 15px rgba(0, 113, 188, 0.4); /* Blue glow */
}

.btn-secondary {
    background-color: var(--color-secondary);
    color: white;
}

/* Secondary Hover (Red) */
.btn-secondary:hover {
    background-color: #c41219; /* Darker Red */
    transform: translateY(-3px); /* Lifts up */
    box-shadow: 0 5px 15px rgba(237, 28, 36, 0.4); /* Red glow */
}

/* 3. Layout Utilities */
/* THIS IS THE KEY UPDATE: Full width with fixed 60px padding */
.container {
    width: 100%;
    max-width: none; /* Removes the center limit */
    margin: 0; 
    padding: 0 60px; /* Matches your story-left padding exactly */
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

/* 4. Navbar */
.navbar {
    padding: 15px 0;
    position: sticky;
    top: 0;
    width: 100%;
    background-color: white; 
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
}

.nav-logo-img {
    height: 50px; 
    width: auto;  
    display: block;
}

/* Visibility Utilities */
.mobile-only { display: none; }
.desktop-only { display: inline-block; }

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links li a {
    position: relative;
    text-decoration: none;
    color: var(--color-dark);
    font-weight: 300;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    padding: 5px 0;
}

.nav-links li a:hover,
.nav-links li a.active-link {
    color: var(--color-primary);
}

.nav-links li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--color-primary);
    transition: width 0.3s ease;
}

.nav-links li a:hover::after,
.nav-links li a.active-link::after {
    width: 100%;
}

/* --- Hamburger Icon Styling --- */
.hamburger {
    display: none; /* Hidden on desktop */
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.bar {
    display: block;
    width: 25px;
    height: 2px;
    background-color: var(--color-dark);
    transition: all 0.3s ease;
}

/* --- Responsive Layout (Mobile) --- */
@media (max-width: 992px) {
    /* Prevent horizontal scroll on the mobile view specifically */
    html, body {
        overflow-x: hidden;
        position: relative;
    }

    .hamburger {
        display: flex !important;
        z-index: 2000 !important;
    }

    .nav-links {
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        
        position: fixed !important;
        top: 0 !important;
        right: 0 !important; /* Keep right at 0 */
        
        width: 70% !important; 
        height: 100vh !important;
        
        background-color: rgba(255, 255, 255, 0.95) !important;
        backdrop-filter: blur(10px) !important;
        -webkit-backdrop-filter: blur(10px) !important;
        
        z-index: 1500 !important;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1) !important;

        /* THE FIX: Use transform instead of right: -100% */
        transform: translateX(100%) !important;
        visibility: hidden !important; 
        transition: transform 0.4s ease-in-out, visibility 0.4s !important;
    }

    /* Slide in using transform */
    .nav-links.active {
        transform: translateX(0) !important;
        visibility: visible !important;
    }

    .nav-links li {
        margin: 15px 0;
    }
}


/* 5. Hero Section (Text Overlay) */
.hero {
    position: relative;
    background-image: url(src/assets/hero-image.jpg); 
    background-size: cover;
    background-position: center;
    height: 80vh; 
    display: flex;
    align-items: center;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 113, 188, 0.65); 
    display: flex;
    align-items: center;
}

.hero-content-wrapper {
    color: white;
    width: 100%; 
    max-width: none; /* ensure it stretches to the padding limits */
    text-align: left; 
}

.hero-subtitle {
    color: #4ade80; 
    font-weight: 700;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    letter-spacing: 1px;
    display: block;
    margin-bottom: 15px; 
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 2rem;
    line-height: 1.1; 
    max-width: 800px; /* Optional: Keeps the heading from getting too long to read on big screens, but alignment stays left */
}

/* 6. Our Story (Split) */
.our-story {
    display: block;
}

.story-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    min-height: 300px;
}

.story-left {
    background-color: var(--color-primary);
    color: white;
    padding: 60px; /* The master padding reference */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.story-left h2 {
    font-size: 3rem;
    color: #ffd700; 
}

.separator-line {
    width: 50px;
    height: 4px;
    background: white;
    margin: 20px 0;
}

.story-right {
    background-color: white;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* 7. Mission Bar Fixes */
.mission-bar {
    background-color: var(--color-primary);
    color: white;
    padding: 60px 0;
    
}

.mission-grid {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    width: 100% !important;
    gap: 40px !important;
}

.mission-item {
    flex: 1 !important;
    min-width: 0 !important; /* Prevents text from pushing the box wider than 33% */
    text-align: center !important;
}

.mission-item h4 {
    font-size: 1.5rem;
    color: #ffd700;
    margin-bottom: 12px;
    white-space: nowrap !important; /* Forces the heading to stay on one line */
}

.mission-item p {
    font-size: 1.1rem;
    line-height: 1.5;
    margin-bottom: 0;
}

/* --- Mission Bar Responsiveness --- */

@media (max-width: 992px) {
    .mission-grid {
        /* Remove the 'nowrap' and force vertical stacking */
        flex-direction: column !important;
        flex-wrap: wrap !important;
        gap: 40px !important;
        align-items: center !important;
        text-align: center !important;
    }

    .mission-item {
        width: 100% !important;
        max-width: 400px; /* Prevents text from stretching too wide on tablets */
    }

    .mission-item h4 {
        /* Allow headings to wrap on small screens so they don't bleed off-edge */
        white-space: normal !important;
        margin-bottom: 8px;
    }
    
    .mission-item p {
        font-size: 1rem;
    }
}


/* 8. Updates & Cards */
.updates {
    padding: 80px 0;
    background-color: white;
}

.updates .section-title {
    text-align: center;
    width: 100%;
    margin-bottom: 50px;
}

.updates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

/* Link Wrapper Styling */
.card-link {
    text-decoration: none;
    color: inherit; /* Prevents text from turning blue */
    display: block;
    transition: opacity 0.4s ease, transform 0.3s ease;
    opacity: 1; /* Default state */
} 

.update-card {
    border: 1px solid #eee;
    border-radius: 12px; /* Slightly more rounded for a modern feel */
    overflow: hidden;
    background: white;
    height: 100%; /* Ensures all cards in a row have equal height */
    transition: all 0.3s ease;
}

/* Hover Effect: Card lifts and shadow deepens */
.card-link:hover .update-card {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 113, 188, 0.1); /* Subtle brand-blue shadow */
    border-color: var(--color-primary);
}

.card-image {
    height: 220px;
    background-color: #ddd; 
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
}

/* Image zoom effect on hover */
.card-link:hover .card-image {
    transform: scale(1.05);
}

.card-content { 
    padding: 24px; 
}

.card-content h4 { 
    font-size: 1.3rem; 
    margin-bottom: 15px;
    color: var(--color-dark);
    line-height: 1.2;
    transition: color 0.3s ease;
}

/* Header turns blue on hover */
.card-link:hover h4 {
    color: var(--color-primary);
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--color-text-gray);
    border-top: 1px solid #eee;
    padding-top: 15px;
    margin-top: 10px;
}

.like-icon {
    color: var(--color-secondary); /* Brand Red */
    font-size: 1.1rem;
    transition: transform 0.2s ease;
}

.card-link:hover .like-icon {
    transform: scale(1.3);
}

.center-btn { 
    text-align: center;
    margin-top: 20px;
}

/* Image zoom effect on hover */
.card-link:hover .card-image {
    transform: scale(1.05);
}

.card-content { 
    padding: 24px; 
}

.card-content h4 { 
    font-size: 1.3rem; 
    margin-bottom: 15px;
    color: var(--color-dark);
    line-height: 1.2;
    transition: color 0.3s ease;
}

/* Header turns blue on hover */
.card-link:hover h4 {
    color: var(--color-primary);
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--color-text-gray);
    border-top: 1px solid #eee;
    padding-top: 15px;
    margin-top: 10px;
}

.like-icon {
    color: var(--color-secondary); /* Brand Red */
    font-size: 1.1rem;
    transition: transform 0.2s ease;
}

.card-link:hover .like-icon {
    transform: scale(1.3);
}

.center-btn { 
    text-align: center;
    margin-top: 20px;
}
/* 9. Partners Section - Infinite Scroll */
.partners {
    padding: 60px 0;
    background: #fafafa;
    overflow: hidden;
}

.partners .section-title {
    text-align: center;
    width: 100%;
    margin-bottom: 50px;
}

.partners-scroll-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    /* Optional: Adds a soft fade effect at the edges */
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.partners-animate {
    display: flex;
    align-items: center;
    gap: 60px; /* Space between logos */
    width: max-content;
    animation: partners-scroll 25s linear infinite;
}

.partner-logo {
    max-height: 80px;
    width: auto;
    filter: grayscale(100%); /* Optional: makes logos gray */
    opacity: 0.7;
    transition: all 0.3s ease;
}

.partner-logo:hover {
    filter: grayscale(0%); /* Returns color on hover */
    opacity: 1;
    transform: scale(1.1);
}

/* Animation Keyframes */
@keyframes partners-scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Pause on hover */
.partners-scroll-container:hover .partners-animate {
    animation-play-state: paused;
}

/* 10. Quote Section */
.quote-bar {
    background-color: var(--color-primary);
    color: white;
    text-align: center;
    padding: 60px 0;
}
.quote-bar p { font-size: 1.25rem; max-width: 800px; margin: 0 auto 20px; font-style: italic; }
.quote-bar cite { font-weight: 700; font-family: var(--font-heading); color: #ffd700; }

/* 11. Infinite Scroll Gallery */
.gallery {
    padding: 40px 0;
    background-color: var(--color-light); /* Match the red background from reference */
    overflow: hidden; /* Hides the scrollbars */
}

.gallery-scroll-container {
    display: flex;
    flex-direction: column;
    gap: 15px; /* Space between the two rows */
}

.gallery-row {
    display: flex;
    white-space: nowrap; /* Forces images to stay in a single line */
    gap: 15px; /* Space between images in a row */
    will-change: transform; /* Performance optimization for animation */
}

.gallery-item {
    flex: 0 0 auto; /* Ensures items don't shrink */
    width: 300px;   /* Fixed width for each image tile */
    height: 200px;  /* Fixed height */
    overflow: hidden;
    border-radius: 4px;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gallery-header {
    text-align: center !important;
    width: 100%;
    margin-bottom: 40px;
}

/* --- Responsiveness Patch --- */

/* For Tablets and Small Desktops (Below 1024px) */
@media (max-width: 1024px) {
    .container {
        padding: 0 40px; /* Reduced from 60px */
    }

    .hero h1, .updates-hero h1, .article-header h1 {
        font-size: 2.8rem;
    }

    .story-grid, .join-us, .content-wrapper, .mission-grid {
        grid-template-columns: 1fr; /* Stacks side-by-side elements */
    }

    .impact-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* For Mobile Phones (Below 768px) */
@media (max-width: 768px) {
    .container {
        padding: 0 20px; /* Tight padding for small screens */
    }

    .nav-links {
        display: none; /* Hides desktop navigation */
    }

    .hero h1, .updates-hero h1, .about-hero h1, .article-header h1 {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.8rem;
        text-align: center;
    }

    .story-left, .story-right, .join-content, .featured-text {
        padding: 40px 20px;
        text-align: center;
    }

    .separator-line {
        margin: 20px auto; /* Centers the line */
    }

    .mission-grid, .impact-grid, .partners-flex, .footer-grid, .partners-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .featured-flex {
        flex-direction: column;
    }

    .featured-image {
        min-height: 250px;
    }

    .footer-bottom-flex {
        flex-direction: column;
        gap: 10px;
    }

    .main-featured-image {
        height: 300px;
    }
}

/* --- ANIMATIONS --- */

/* Define the animation for scrolling left */
@keyframes scroll-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); } /* Move by half the width (the length of one original set) */
}

/* Define the animation for scrolling right */
@keyframes scroll-right {
    0% { transform: translateX(-50%); } /* Start halfway to the left */
    100% { transform: translateX(0); }  /* Move back to the start */
}

/* Apply animations to the rows */
.scroll-left {
    /* Duration: 30s, Timing: Linear (smooth), Iteration: Infinite */
    animation: scroll-left 30s linear infinite;
}

.scroll-right {
    /* Same settings, just a different animation name */
    animation: scroll-right 30s linear infinite;
}

/* Pause animation on hover for better user experience */
.gallery-row:hover {
    animation-play-state: paused;
}

/* 12. Join Us (Split) */
.join-us {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 400px;
}

.join-content {
    background-color: var(--color-primary);
    color: white;
    padding: 10%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.join-content h2 { font-size: 3rem; margin-bottom: 20px; }
.join-content p { font-size: 1.2rem; margin-bottom: 30px; }

.join-image {
    background-color: #ddd;
    background-size: cover;
    background-position: center;
}

/* 13. Footer */
.main-footer {
    background-color: white;
    padding-top: 60px;
    padding-bottom: 0;
    border-top: 5px solid var(--color-primary);
}

.footer-logo-link {
    display: inline-block; /* Allows margins to work */
    margin-bottom: 5px;   /* Spacing between logo and the paragraph text */
}

.footer-logo-img {
    height: 60px; /* Usually looks good slightly larger than the navbar logo */
    width: auto;
    display: block;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.5fr;
    gap: 40px;
}

.footer-desc {
    margin-bottom: 20px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--color-text-gray);
}

.footer-contact p {
    margin-bottom: 5px; /* Tighter spacing for contact lines */
    font-size: 0.95rem;
    color: var(--color-dark);
}

.footer-contact strong {
    color: var(--color-primary); /* Makes "Email:", "Phone:" Blue */
    font-weight: 700;
    margin-right: 5px;
}

.footer-contact a {
    text-decoration: none;
    color: inherit; /* Keeps it dark gray by default */
    transition: color 0.3s ease;
}

.footer-contact a:hover {
    color: var(--color-primary); /* Turns Blue on hover */
    text-decoration: underline;  /* Adds underline for clarity */
    cursor: pointer;
}
.footer-links h2 {
    color: var(--color-secondary); /* Brand Red */
    font-weight: 800; /* Extra bold */
    text-transform: uppercase;
    font-size: 1.4rem;
    margin-bottom: 25px; /* Spacing below the header */
}

/* 2. The Links: Base Style */
.footer-links ul li {
    margin-bottom: 12px; /* Spacing between links */
}

.footer-links a {
    text-decoration: none;
    color: var(--color-text-gray); /* Default gray */
    font-weight: 500;
    transition: all 0.3s ease; /* Smooth animation */
    display: inline-block; /* Required for the slide effect to work */
}

/* 3. The Hover Effect: Turns Blue & Slides Right */
.footer-links a:hover {
    color: var(--color-primary); /* Brand Blue */
    transform: translateX(5px);  /* Slides 5px to the right */
}

/* Social Icons Styling */
.socials {
    margin-top: 25px;
    display: flex;
    gap: 20px; /* Space between icons */
}

.socials a {
    font-size: 1.5rem; /* Makes the icons larger and easier to click */
    color: var(--color-primary); /* Blue by default */
    transition: all 0.3s ease;
}

/* Hover Effect: Turns Red and Pops up */
.socials a:hover {
    color: var(--color-secondary); /* Changes to Red */
    transform: translateY(-3px);   /* Moves up slightly */
}

.footer-brand p { font-size: 0.9rem; margin: 20px 0; color: var(--color-text-gray); }
.socials a { margin-right: 15px; font-weight: 700; color: var(--color-primary); }

.footer-links ul li { margin-bottom: 10px; }
.footer-links a { color: var(--color-text-gray); }

.form-group { margin-bottom: 15px; }
.form-group label { display: block; font-size: 0.8rem; font-weight: 700; color: var(--color-primary); margin-bottom: 5px; }
.form-group input, .form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd; 
    border-radius: 4px;
}
.full-width { width: 100%; }

/* Form Header */
.form-title {
    color: var(--color-secondary); /* Brand Red */
    font-size: 1.8rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 20px;
}

/* Form Styling */
.form-group { 
    margin-bottom: 20px; 
}

.form-group label { 
    display: block; 
    font-size: 0.95rem; 
    font-weight: 700; 
    color: var(--color-primary); /* Blue Labels */
    margin-bottom: 8px; 
}

.form-group input, 
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc; /* Subtle gray border */
    border-radius: 6px; /* Rounded corners like the screenshot */
    font-family: var(--font-body);
    font-size: 1rem;
    background-color: #fff;
    transition: border-color 0.3s ease;
}

/* Focus Effect: Blue Border when typing */
.form-group input:focus, 
.form-group textarea:focus {
    border-color: var(--color-primary);
    outline: none;
    box-shadow: 0 0 5px rgba(0, 113, 188, 0.2);
}

/* Button Full Width override for form */
.full-width { 
    width: 100%; 
    padding: 12px;
    font-size: 1rem;
}

/* 2. The Blue Strip Background */
.footer-bottom {
    background-color: var(--color-primary); /* Brand Blue */
    color: white;
    padding: 20px 0; /* Vertical height of the strip */
    margin-top: 20px; /* Space between white footer content and blue strip */
    font-size: 0.85rem;
}

/* 3. Layout for the Content */
.footer-bottom-flex {
    display: flex;
    justify-content: space-between; /* Pushes text to left, links to right */
    align-items: center;
    flex-wrap: wrap; /* Safety for mobile screens */
    gap: 15px;
}

/* 4. Legal Links Styling */
.footer-legal {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-legal a {
    color: white;
    text-decoration: none;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.footer-legal a:hover {
    opacity: 1;
    text-decoration: underline;
}

.separator {
    opacity: 0.5; /* Makes the "|" symbol subtle */
}

/* --- UPDATES PAGE SPECIAL STYLES --- */

.updates-hero {
    position: relative;
    padding: 120px 0; /* More padding to show off the image */
    background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('src/assets/activity images/IMG_0076.JPG');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Optional: adds a parallax effect */
    color: white;
    text-align: center;
    display: flex;
    align-items: center;
    min-height: 400px;
}

.updates-hero .container {
    position: relative;
    z-index: 2; /* Ensures text is above the overlay */
}

.updates-hero h1 {
    font-size: 4rem;
    color: white;
    margin-bottom: 20px;
    font-weight: 800;
    text-transform: uppercase;
}

.updates-hero p {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.5;
}

/* Adjusting for mobile screens */
@media (max-width: 768px) {
    .updates-hero h1 {
        font-size: 2.5rem;
    }
    .updates-hero p {
        font-size: 1.1rem;
    }
}

.updates-content {
    padding: 80px 0;
}

/* Featured Section */
.featured-update {
    margin-bottom: 80px;
}

.featured-link {
    text-decoration: none;
    color: inherit;
}

.featured-flex {
    display: flex;
    background: var(--color-primary); /* Changed from white to Brand Blue */
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0, 113, 188, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.featured-flex:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0, 113, 188, 0.3);
}

.featured-image {
    flex: 1.2;
    min-height: 400px;
    background-size: cover;
    background-position: center;
}

.featured-text {
    flex: 1;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: white; /* Ensures overall text contrast */
}

.featured-text .tag {
    background-color: var(--color-secondary); /* Brand Red background */
    color: white; /* White text for the tag */
    padding: 5px 15px;
    border-radius: 5px;
    font-weight: 800;
    font-family: var(--font-heading);
    text-transform: uppercase;
    margin-bottom: 15px;
    display: inline-block;
    width: fit-content;
}

.featured-text h2 {
    font-size: 2.5rem;
    color: white; /* White heading */
    margin-bottom: 20px;
    line-height: 1.1;
}

/* Added specific styling for the paragraph for better legibility */
.featured-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 0;
}

.featured-text .meta {
    margin-top: 25px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8); /* Lighter white for meta info */
    display: flex;
    gap: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.2); /* Subtle divider */
    padding-top: 20px;
}

/* Ensures icons in meta are also white */
.featured-text .meta i {
    color: white;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap; /* Essential for mobile wrapping */
    align-items: flex-start; /* Changed from center to prevent clipping on multiple lines */
    gap: 12px;
    height: auto; /* Ensures the container expands as rows are added */
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.filter-label {
    font-weight: 700;
    font-family: var(--font-heading);
    text-transform: uppercase;
    flex-shrink: 0; /* Keeps the label from squashing */
    margin-right: 5px;
}

.filter-btn {
    padding: 8px 20px;
    border: 1px solid #ddd;
    background: white;
    border-radius: 20px;
    font-family: var(--font-heading);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap; /* Prevents text within a button from breaking */
}

.filter-btn.active, .filter-btn:hover {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

/* Pagination */
.pagination {
    margin-top: 60px;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.page-num, .prev, .next {
    padding: 10px 18px;
    border: 1px solid #eee;
    text-decoration: none;
    color: var(--color-dark);
    font-weight: 700;
    border-radius: 5px;
}

.page-num.active {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

/* Responsive adjustments */
@media (max-width: 900px) {
    .featured-flex {
        flex-direction: column;
    }
    .featured-image {
        min-height: 250px;
    }
    .featured-text {
        padding: 40px;
    }
}

.pagination a.disabled {
    pointer-events: none;
    opacity: 0.5;
    background-color: #eee;
    cursor: not-allowed;
}

/* Ensure smooth fade when switching pages */
.card-link {
    transition: opacity 0.4s ease;
}


/* --- 12. Article View & Typography --- */

.article-header {
    padding: 80px 0 60px;
    background-color: var(--color-gray-bg);
    border-bottom: 1px solid #eee;
}

.breadcrumb {
    font-size: 0.9rem;
    color: var(--color-text-gray);
    margin-bottom: 20px;
    font-family: var(--font-heading);
}

.breadcrumb a {
    text-decoration: none;
    color: var(--color-primary);
    font-weight: 700;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--color-secondary);
}

.breadcrumb i {
    font-size: 0.7rem;
    margin: 0 10px;
}

.article-header h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 25px;
    color: var(--color-dark);
    max-width: 900px;
}

.article-meta-top {
    display: flex;
    gap: 30px;
    color: var(--color-text-gray);
    font-size: 0.95rem;
}

.article-meta-top i {
    color: var(--color-primary);
    margin-right: 8px;
}

/* Article Body Layout */
.article-body {
    padding: 60px 0 100px;
}

.main-featured-image {
    width: 100%;
    height: 550px;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 60px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.main-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.content-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr; /* 2 parts text, 1 part sidebar */
    gap: 80px;
}

/* Typography for Article Content */
.article-text {
    font-family: var(--font-main);
    font-size: 1.2rem;
    line-height: 1.8;
    color: #333;
}

.article-text .lead {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--color-dark);
    line-height: 1.5;
    margin-bottom: 40px;
}

.article-text h2 {
    font-size: 2.2rem;
    margin: 50px 0 25px;
    color: var(--color-primary);
    font-family: var(--font-heading);
}

.article-text p {
    margin-bottom: 30px;
}

/* Article Blockquote */
blockquote {
    border-left: 6px solid var(--color-secondary);
    padding: 40px;
    margin: 50px 0;
    background: #fdfdfd;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.02);
    font-style: italic;
    font-size: 1.5rem;
    line-height: 1.4;
    color: var(--color-dark);
}

blockquote cite {
    display: block;
    margin-top: 20px;
    font-weight: 800;
    color: var(--color-primary);
    font-style: normal;
    font-size: 1.1rem;
    text-transform: uppercase;
}

/* Sticky Sidebar */
.article-sidebar {
    position: sticky;
    top: 120px; /* Aligns with sticky navbar + some breathing room */
    height: fit-content;
}

.sidebar-box {
    background: white;
    border: 1px solid #eee;
    padding: 35px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.sidebar-box h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    font-family: var(--font-heading);
    text-transform: uppercase;
    color: var(--color-dark);
}

.sidebar-box p {
    margin-bottom: 12px;
    font-size: 1rem;
    color: var(--color-text-gray);
}

.sidebar-box strong {
    color: var(--color-dark);
}

.share-socials {
    display: flex;
    gap: 15px;
}

.share-socials a {
    width: 45px;
    height: 45px;
    background: var(--color-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.share-socials a:hover {
    background: var(--color-secondary);
    transform: translateY(-3px);
}

/* Responsive Handling */
@media (max-width: 1024px) {
    .content-wrapper {
        gap: 40px;
    }
}

@media (max-width: 900px) {
    .content-wrapper {
        grid-template-columns: 1fr; /* Stack vertically on tablets/phones */
    }

    .article-sidebar {
        position: static;
        order: 2; /* Content first, then sidebar */
    }

    .article-header h1 {
        font-size: 2.8rem;
    }

    .main-featured-image {
        height: 350px;
    }
}

@media (max-width: 600px) {
    .article-header h1 {
        font-size: 2.2rem;
    }
    
    .article-meta-top {
        flex-direction: column;
        gap: 10px;
    }
}

.related-articles {
    padding: 80px 0;
    background-color: white;
    border-top: 1px solid #eee;
}

.section-title {
    font-size: 2.5rem;
    font-family: var(--font-heading);
    color: var(--color-dark);
    margin-bottom: 40px;
    text-transform: uppercase;
    text-align: left;
}

/* Ensure the grid doesn't break the container on smaller screens */
@media (max-width: 768px) {
    .related-articles {
        padding: 60px 0;
    }
    .section-title {
        font-size: 1.8rem;
    }
}

/* --- 13. About Page Styles --- */

.about-hero {
    padding: 120px 0;
    background: linear-gradient(rgba(0, 113, 188, 0.8), rgba(0, 113, 188, 0.8)), url('src/assets/activity images/IMG_4328.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
}

.mission-vision {
    padding: 100px 0;
    background: white;
}

.mission-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}

.mission-item {
    text-align: left;
}

.icon-circle {
    width: 60px;
    height: 60px;
    background: var(--color-gray-bg);
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.5rem;
    margin-bottom: 25px;
}

.partnership-section {
    padding: 100px 0;
    background-color: var(--color-gray-bg);
}

.partners-flex {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 50px;
}

.partner-card {
    background: white;
    padding: 40px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

.partner-card:hover {
    transform: translateY(-5px);
}

.partner-logo img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.partner-tag {
    color: var(--color-secondary);
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.section-title.center {
    text-align: center;
}

.partnership-section {
    padding: 80px 0; /* Slightly reduced padding for mobile breathing room */
    background-color: var(--color-gray-bg);
}

.partners-flex {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Desktop: 2 columns */
    gap: 30px;
    margin-top: 50px;
}

.partner-card {
    background: white;
    padding: 40px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

/* --- Responsiveness Patch --- */

@media (max-width: 992px) {
    .partnership-section {
        padding: 60px 0;
    }

    .partners-flex {
        grid-template-columns: 1fr; /* Stacks cards vertically */
        gap: 20px;
    }

    .partner-card {
        padding: 30px; /* More compact padding for mobile */
        text-align: center; /* Center-aligning content often looks better in stacks */
    }

    .partner-logo {
        display: flex;
        justify-content: center;
    }
}

/* Impact Cards */
.about-impact {
    padding: 100px 0;
    background: white;
}

.impact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.impact-card {
    padding: 40px;
    border-radius: 15px;
    background: var(--color-gray-bg);
    text-align: center;
    transition: background 0.3s ease;
}

.impact-card i {
    font-size: 2.5rem;
    color: var(--color-primary);
    margin-bottom: 20px;
}

.impact-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
}

/* Timeline Styles */
.project-timeline {
    padding: 100px 0;
    background-color: var(--color-primary);
    color: white;
}

.project-timeline .section-title {
    color: white;
}

.timeline-container {
    position: relative;
    max-width: 800px;
    margin: 50px auto 0;
    padding-left: 40px;
    border-left: 2px solid rgba(255, 255, 255, 0.2);
}

.timeline-item {
    position: relative;
    margin-bottom: 60px;
}

.timeline-dot {
    position: absolute;
    left: -51px;
    top: 5px;
    width: 20px;
    height: 20px;
    background: var(--color-gray-bg);
    border-radius: 50%;
    border: 4px solid var(--color-text-gray);
}

.timeline-item.current .timeline-dot {
    background: #00ff00; /* Bright indicator for active phase */
    box-shadow: 0 0 15px #00ff00;
}

.timeline-date {
    font-weight: 800;
    color: #ffd700;
    text-transform: uppercase;
    font-size: 0.9rem;
    display: block;
    margin-bottom: 5px;
}

.timeline-content h4 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.timeline-content p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
}

@media (max-width: 768px) {
    .impact-grid { grid-template-columns: 1fr; }
}

.about-cta {
    padding: 100px 0;
    background-color: white;
}

.cta-card {
    background-color: var(--color-primary);
    padding: 80px 60px;
    border-radius: 20px;
    text-align: center;
    color: white;
    box-shadow: 0 20px 40px rgba(0, 113, 188, 0.2);
}

.cta-content h2 {
    font-size: 3rem;
    color: white;
    margin-bottom: 20px;
}

.cta-content p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 40px;
    color: rgba(255, 255, 255, 0.9);
}

.cta-btns {
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* Specific button overrides for the CTA area */
.cta-btns .btn-secondary {
    border-radius: 15px; /* Matching the pill shape you requested earlier */
    padding: 15px 40px;
}

.btn-outline {
    background: transparent;
    border: 2px solid white;
    color: white;
    padding: 15px 40px;
    border-radius: 15px;
    font-weight: 800;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background: white;
    color: var(--color-primary);
}

/* --- Responsiveness Patch --- */
@media (max-width: 768px) {
    .cta-card {
        padding: 50px 30px;
    }

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

    .cta-btns {
        flex-direction: column;
        align-items: center;
    }

    .cta-btns .btn {
        width: 100%;
        max-width: 300px;
    }
}


/* --- Resource Page Specifics --- */

.resource-hero {
    height: 50vh;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('src/assets/hero-image.jpg');
    background-size: cover;
    background-position: center;
    position: relative; /* Anchors the overlay inside this box */
}

/* New styling for the overlay to fix the overflow/height issue */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%; /* Inherits the 50vh from parent, preventing spillover */
    display: flex;
    align-items: center; /* Centers the text vertically */
}

.hero-subtitle {
    font-family: var(--font-heading);
    color: #4ade80; /* Light green */
    font-size: 1.2rem;
    display: block;
    margin-bottom: 1rem;
    font-weight: 700;
}

/* The rest of your grid styling remains the same */
.resource-section {
    padding: 100px 0;
    background-color: var(--color-gray-bg);
}

.resource-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.resource-card {
    background: var(--color-light);
    border-radius: 15px;
    padding: 40px;
    position: relative;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease;
}

.resource-card:hover {
    transform: translateY(-5px);
}

.res-tag {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--color-primary);
    color: white;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.7rem;
    font-family: var(--font-heading);
    font-weight: 700;
}

.res-label {
    color: var(--color-secondary);
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 0.85rem;
    display: block;
    margin-bottom: 10px;
}

.res-content p {
    color: var(--color-text-gray);
    margin: 20px 0;
    font-weight: 300;
}

.res-action {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.file-size {
    font-size: 0.8rem;
    color: var(--color-text-gray);
    font-family: var(--font-body);
}

/* --- Responsiveness & Container Adjustments --- */

@media (max-width: 1024px) {
    .resource-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px; 
    }

    .resource-section {
        padding: 60px 0;
    }

    .resource-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .resource-card {
        padding: 30px;
    }

    /* The overlay automatically adjusts to this new height */
    .resource-hero {
        height: 40vh;
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
}

/* --- Contact Page Specifics --- */

.contact-hero {
    height: 40vh; /* Shorter hero for contact page */
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('src/assets/activity images/IMG_4370.jpg'); /* Use a relevant image */
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    position: relative;
}

.contact-section {
    padding: 80px 0;
    background-color: white;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr; /* Form is slightly wider */
    gap: 60px;
    align-items: start;
}

/* Left Column: Info */
.contact-intro {
    font-size: 1.1rem;
    color: var(--color-text-gray);
    margin-bottom: 40px;
    line-height: 1.6;
}

.info-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.info-item i {
    font-size: 1.5rem;
    color: var(--color-secondary); /* Brand Red Icon */
    margin-top: 5px;
}

.info-item h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: var(--color-dark);
}

.info-item p, .info-item a {
    color: var(--color-text-gray);
    font-size: 1rem;
    font-weight: 400;
}

.map-container {
    margin-top: 40px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Right Column: Form Styling */
.contact-form-wrapper {
    background: var(--color-gray-bg);
    padding: 40px;
    border-radius: 15px;
}

.main-form .form-group {
    margin-bottom: 20px;
}

.main-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    font-family: var(--font-heading);
    color: var(--color-dark);
    font-size: 0.9rem;
}

.main-form input, 
.main-form select, 
.main-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: 0.3s;
}

/* Focus State: Glow Blue */
.main-form input:focus, 
.main-form select:focus, 
.main-form textarea:focus {
    border-color: var(--color-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 113, 188, 0.1);
}

/* Form Row for Side-by-Side inputs */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Mobile Responsiveness */
@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr; /* Stack vertically */
        gap: 40px;
    }
    
    .contact-hero {
        height: 35vh;
    }
    
    .contact-form-wrapper {
        padding: 30px 20px; /* Reduce padding on mobile */
    }
    
    .form-row {
        grid-template-columns: 1fr; /* Stack Name/Org inputs on mobile */
    }
}

/* --- Responsive Footer --- */

@media (max-width: 900px) {
    /* Stack the main footer columns */
    .footer-grid {
        display: flex;
        flex-direction: column;
        gap: 50px;
        text-align: center;
    }

    /* Center the branding and description */
    .footer-brand p, 
    .footer-desc {
        margin-left: auto;
        margin-right: auto;
    }

    /* Fix social icons centering */
    .socials {
        justify-content: center;
    }

    /* Ensure form inputs go full width */
    .footer-form {
        width: 100%;
        max-width: 400px;
        margin: 0 auto; /* Centers the form block */
    }

    /* Stack the bottom legal bar */
    .footer-bottom-flex {
        flex-direction: column;
        gap: 15px;
        text-align: center;
        padding: 20px 0;
    }

    .footer-legal {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    
    /* Hide the vertical separator lines in legal menu on mobile */
    .footer-legal .separator {
        display: none;
    }
}

/* --- Back to Top Button --- */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--color-primary); /* Use your BES-TVET Blue */
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    z-index: 2000;
    
    /* Initially hidden */
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--color-secondary); /* Brand Red for hover */
    transform: translateY(-5px);
}

/* Ensure it doesn't overlap content on very small screens */
@media (max-width: 600px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
    }
}