/* --- General Styles --- */
body {
    font-family: 'Heebo', sans-serif;
}

/* =========================================
   1. GLOBAL SETTINGS
   ========================================= */
html,
body {
    overflow-x: hidden;
    /* Prevents horizontal scrollbar */
    width: 100%;
    margin: 0;
    padding: 0;
}

/* Pushes content down so it doesn't hide behind the fixed header. */
body {
    padding-top: 140px;
}

/* =========================================
   2. HEADER SECTION (Container)
   ========================================= */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1020;
    background-color: white;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);

    /* Spacing Fixes */
    padding-top: 15px;
    padding-bottom: 0 !important;
    border-bottom: 0 !important;
}

/* =========================================
   3. TOP ROW (Logo & Donate Button)
   ========================================= */
.flex-align {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 10px;
}

.logo {
    height: 60px;
    width: auto;
}

.btn {
    font-size: 16px;
    font-weight: 700;
    border-radius: 20px;
    padding: 8px 20px;
}

.btn-dark {
    color: #fff;
    background-color: #343a40;
    border-color: #343a40;
}

/* =========================================
   4. NAVBAR STYLING
   ========================================= */
.header .navbar-default {
    background-color: #2b6cb0;
    border-color: #2a4365;
    border: none !important;
    margin-bottom: 0 !important;
    min-height: 50px;
    border-radius: 0 !important;
}

/* Link Styling */
.navbar-default .navbar-nav>li>a {
    color: #ffffff;
    font-weight: 700;
    font-size: 16px;
    padding: 15px 20px;
    line-height: 20px;
}

/* Hover Effects */
.navbar-default .navbar-nav>li>a:hover,
.navbar-default .navbar-nav>li>a:focus,
.navbar-default .navbar-nav>.open>a,
.navbar-default .navbar-nav>.open>a:hover,
.navbar-default .navbar-nav>.open>a:focus {
    color: #ffffff;
    background-color: #4299e1;
}

/* Dropdown Menu Styling */
.dropdown-menu {
    border: none;
    box-shadow: 0 6px 12px rgba(0, 0, 0, .175);
}

.dropdown-menu>li>a {
    font-weight: 500;
    color: #333;
    padding: 10px 20px;
}

/* Center Nav on Desktop */
@media (min-width: 768px) {
    .navbar-nav.center-nav {
        float: none;
        margin: 0 auto;
        display: inline-block;
    }

    .navbar-default .container {
        text-align: center;
    }
}

/* =========================================
   5. MOBILE RESPONSIVENESS (The Fix)
   ========================================= */
@media (max-width: 767px) {

    /* --- A. Fix Top Row (Logo & Donate on one line) --- */
    .flex-align {
        display: flex !important;
        flex-wrap: nowrap !important;
        /* Forces them side-by-side */
        justify-content: space-between !important;
        padding-bottom: 5px;
    }

    /* Resize columns to fit content */
    .header .col-xs-6 {
        width: auto !important;
        padding-left: 10px;
        padding-right: 10px;
    }

    /* Make logo smaller */
    .logo {
        height: 40px !important;
    }

    /* Make button smaller */
    .btn {
        font-size: 13px !important;
        padding: 6px 12px !important;
        margin-top: 0;
    }

    /* --- B. Fix Navbar (Hamburger & Collapsing) --- */

    /* Make Hamburger Lines White */
    .navbar-default .navbar-toggle .icon-bar {
        background-color: #fff;
    }

    .navbar-default .navbar-toggle {
        border-color: transparent;
        margin-right: 0;
    }

    .navbar-default .navbar-toggle:hover,
    .navbar-default .navbar-toggle:focus {
        background-color: #4299e1;
    }

    /* Navbar alignment fixes */
    .navbar-header {
        text-align: right;
        /* Puts hamburger on the right */
    }

    /* Collapsed Menu Styling */
    .navbar-nav.center-nav {
        margin: 0;
        text-align: left;
        /* Align links to left in menu */
    }

    .navbar-default .navbar-nav .open .dropdown-menu>li>a {
        color: #fff;
        /* White text inside mobile dropdown */
        padding: 10px 25px;
    }

    /* Reduce body padding for smaller header */
    body {
        padding-top: 110px !important;
    }
}



/* --- About Us Section (content_container_1) --- */
.content_container_1 {
    background-color: #2b6cb0;
    /* Sets the background color to blue */
    padding: 60px 0;
    /* Adds some space inside the blue section */
}

/* This helps to vertically align the text and image AND centers the content block */
.content_container_1 .row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    max-width: 1170px;
    /* Limits the width of the content */
    margin: 0 auto;
    /* Centers the content block horizontally */
}

/* Styles the "About Us" heading */
.content_container_1 h1 {
    font-size: 42px;
    /* Makes the text larger */
    font-weight: 800;
    /* Makes the text bold */
    color: #ffffff;
    /* Sets the text color to white */
    margin-bottom: 20px;
}

/* Styles the paragraph text */
.content_container_1 p {
    font-size: 16px;
    line-height: 1.7;
    color: #e2e8f0;
    /* A light gray/off-white for good readability */
}

/* Styles the image */
.about-image-style {
    border-radius: 15px;
}

/* Responsive adjustments for mobile */
@media (max-width: 991px) {

    .content_container_1 .col-md-7,
    .content_container_1 .col-md-5 {
        text-align: center;
    }

    .about-image-style {
        margin-top: 30px;
    }
}


/* --- Word Definition Section --- */

.definition-section {
    padding: 60px 20px;
    background-color: #2b6cb0;
    /* Blue background for this section */
    font-family: 'Heebo', sans-serif;
    text-align: center;
    /* Center all content within this section */
}

.definition-section .definition-box {
    /* Styles for the white box have been removed */
    max-width: 700px;
    margin: 0 auto;
}

.definition-section .word-header {
    display: flex;
    align-items: center;
    justify-content: center;
    /* Center the word and icon */
    gap: 15px;
    margin-bottom: 10px;
}

.definition-section .defined-word {
    font-size: 42px;
    font-weight: 700;
    color: #ffffff;
    /* Changed text to white */
    margin: 0;
}

.definition-section .audio-icon {
    font-size: 22px;
    cursor: pointer;
    color: #ffffff;
    /* Changed icon to white */
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.definition-section .audio-icon:hover {
    opacity: 1;
}

.definition-section .part-of-speech {
    font-size: 18px;
    font-weight: 500;
    font-style: italic;
    color: #e2e8f0;
    /* Changed text to light gray/off-white */
    margin-bottom: 20px;
}

.definition-section .definition-text {
    font-size: 16px;
    line-height: 1.7;
    color: #e2e8f0;
    /* Changed text to light gray/off-white */
}



/* --- New Impact Section --- */

/* This is the main container for the new sections */
.impact-section-wrapper {
    position: relative;
    /* Needed for positioning the white box */
    padding-top: 50px;
    /* Adds space above the white box */
}

/* This is the white floating box with the shadow */
.empower-box {
    background-color: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    /* The shadow effect */
    max-width: 800px;
    /* Limits the width of the box */
    margin: 0 auto;
    /* Centers the box */
    position: relative;
    /* Needed for z-index */
    z-index: 10;
    /* Ensures the white box stays on top of the blue banner */
    margin-bottom: -100px;
    /* This is the key to making it overlap the blue banner below */
    text-align: center;
}

.empower-box h2 {
    font-weight: 800;
    font-size: 36px;
    color: #000;
    margin-top: 0;
}

.empower-box p {
    color: #555;
    font-size: 16px;
    margin-bottom: 30px;
}

/* This is the blue banner that holds the three images */
.image-banner {
    background-color: #2b6cb0;
    /* The blue color you requested */
    padding: 150px 0 50px 0;
    /* Top padding makes space for the overlapping white box */
    position: relative;
}

/* Styles for the three images */
.impact-image {
    border-radius: 15px;
    width: 100%;
}

/* Responsive adjustments for mobile */
@media (max-width: 767px) {
    .empower-box {
        padding: 25px;
        margin-bottom: -70px;
        /* Adjust overlap for mobile */
    }

    .image-banner {
        padding-top: 120px;
        /* Adjust top padding for mobile */
    }

    .impact-image {
        margin-bottom: 20px;
        /* Stack images vertically on mobile and add space */
    }
}

/* Section container styling */
.awards-section {
    margin-top: 50px;
    margin-bottom: 50px;
    /* Adds space below the awards section */
}

/* Carousel images flat edges */
.carousel-inner>.item>img {
    height: 400px;
    /* adjust height as needed */
    width: auto;
    /* keep width proportional */
    margin: 0 auto;
    /* center the image horizontally if it's smaller than container */
    border-radius: 0;
    /* flat edges as before */
    object-fit: contain;
    /* ensures entire image is visible without distortion */
}

/* Indicators color (dots) */
.carousel-indicators li {
    background-color: #2b6cb0;
}

.carousel-indicators .active {
    background-color: #2b6cb0;
}

/* Controls (arrows) */
.carousel-control .glyphicon-chevron-left,
.carousel-control .glyphicon-chevron-right {
    color: #2b6cb0;
}

/* Heading style */
.awards-section h2 {
    color: #2b6cb0;
}

/* View more button */
.view-more-btn {
    margin-top: 20px;
    background-color: #2b6cb0;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    transition: background-color 0.3s;
}

/* Achievements */
.achievements-btn {
    margin-top: 20px;
    background-color: #2b6cb0;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    transition: background-color 0.3s;
    padding-left: 10px;
}

.view-more-btn:hover {
    background-color: #234e8c;
    /* slightly darker blue on hover */
}

.achievements-btn:hover {
    background-color: #234e8c;
    /* slightly darker blue on hover */
}

/* --- Milestones Banner Section --- */

.milestones-banner {
    background-image: url('mainpageimage5.png');
    background-size: cover;
    background-position: center center;
    position: relative;
    height: 250px;
    /* Force fixed height */
    overflow: hidden;
    /* Prevent stretching */
}

.milestones-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(43, 108, 176, 0.6);
    z-index: 1;
}

.milestones-banner .container {
    position: relative;
    z-index: 2;
    height: 100%;
    /* Full height of banner */
    display: flex;
    align-items: center;
    /* Vertically center */
    justify-content: center;
    /* Horizontally center if needed */
}

.milestones-title-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.milestones-banner h2 {
    font-size: 24px;
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    margin: 0;
}

.milestone-item {
    text-align: center;
    color: #ffffff;
}

.milestone-item:not(:last-child) {
    border-right: 1px solid rgba(255, 255, 255, 0.4);
}

.milestone-number {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 5px;
}

.milestone-text {
    font-size: 12px;
    font-weight: 400;
    padding: 0 5px;
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .milestones-banner {
        height: auto;
        /* Allow flexible height on small devices */
        padding: 20px 0;
    }

    .milestones-banner .container {
        flex-direction: column;
    }

    .milestones-title-container {
        margin-bottom: 15px;
    }

    .milestone-item:not(:last-child) {
        border-right: none;
    }
}

/* --- Instagram Feed Section --- */
.instagram-section {
    padding: 60px 0;
    background-color: #ffffff;
    /* A clean white background */
}

.instagram-section h2 {
    text-align: center;
    color: #2b6cb0;
    /* Using your blue theme color */
    font-weight: 800;
    margin-bottom: 40px;
    font-size: 36px;
}

/* By default, the Elfsight widget is responsive and will fill its container.
   Since it's inside a .container-fluid, it will span the full width.
   No extra CSS is needed for the widget itself unless you want to override its default styles. */

/* --- Social Media Banner --- */
.social-banner {
    background-color: #2b6cb0;
    /* The blue color you requested */
    padding: 20px 0;
}

/* This helps vertically align the text and icons */
.social-banner .row {
    display: flex;
    align-items: center;
}

.social-banner-text h3 {
    color: #ffffff;
    font-weight: 700;
    font-size: 22px;
    margin: 0;
    /* Removes default margin */
}

.social-banner-icons {
    text-align: right;
    /* Aligns icons to the right */
}

.social-icon {
    height: 35px;
    /* Adjust size as needed */
    width: 35px;
    margin-left: 15px;
    /* Adds space between icons */
    transition: transform 0.2s ease-in-out;
    /* Smooth transition for hover effect */
}

.social-icon:hover {
    transform: scale(1.1);
    /* Slightly enlarges the icon on hover */
}

/* Responsive adjustments for mobile */
@media (max-width: 767px) {
    .social-banner .row {
        flex-direction: column;
        /* Stack text and icons vertically */
        text-align: center;
    }

    .social-banner-text {
        margin-bottom: 15px;
    }

    .social-banner-icons {
        text-align: center;
        /* Center icons on mobile */
    }

    .social-icon {
        margin: 0 10px;
        /* Adjust spacing for mobile */
    }
}

/* --- Locate Us Section --- */

.locate-us-section {
    padding: 60px 0;
    text-align: center;
}

.locate-us-section h2 {
    font-weight: 800;
    font-size: 36px;
    color: #000;
    margin-bottom: 10px;
}

.locate-us-section .section-subtitle {
    font-size: 16px;
    color: #555;
    margin-bottom: 40px;
}

/* Add display:flex to the row to make columns equal height */
.locate-us-section .row {
    display: flex;
    flex-wrap: wrap;
}

.location-card {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    /* A very light background */
    padding: 25px;
    border-left: 5px solid #2b6cb0;
    /* The blue accent you requested */
    text-align: left;
    height: 100%;
    /* Makes the card fill the column height */
}

.location-icon {
    font-size: 32px;
    color: #2b6cb0;
    /* Matching the blue accent */
    margin-right: 20px;
}

.location-text h4 {
    font-size: 20px;
    font-weight: 700;
    color: #000;
    margin: 0 0 5px 0;
}

.location-text p {
    font-size: 15px;
    color: #555;
    margin: 0;
}

/* This makes the Google Maps iframe responsive and match the column height */
.map-responsive {
    position: relative;
    height: 100%;
    /* Make the map container fill the column height */
    min-height: 350px;
    /* Set a minimum height so it looks good */
}

.map-responsive iframe {
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    position: absolute;
}

/* Responsive adjustments for mobile */
@media (max-width: 991px) {
    .location-card {
        margin-bottom: 30px;
        height: auto;
        /* Revert height on mobile */
    }
}



/* --- Certificate Banner Styling --- */
.cert-banner-section {
    background: linear-gradient(135deg, #2b6cb0 0%, #2c5282 100%);
    padding: 80px 0;
    /* Increased padding slightly to fit taller collage */
    font-family: 'Heebo', sans-serif;
    color: #ffffff;
    overflow: hidden;
}

.flex-vertical-center {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

/* Typography */
.cert-title {
    font-size: 42px;
    font-weight: 800;
    margin-top: 0;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.cert-subtitle {
    font-size: 20px;
    font-weight: 400;
    opacity: 0.9;
    line-height: 1.6;
}

/* Link Styling */
.cert-link {
    color: #ffd700;
    font-weight: 700;
    text-decoration: none;
    border-bottom: 2px solid rgba(255, 215, 0, 0.5);
    margin-left: 5px;
    transition: all 0.3s ease;
    display: inline-block;
}

.cert-link:hover {
    color: #ffffff;
    border-bottom-color: #ffffff;
    text-decoration: none;
    transform: translateX(5px);
}

.cert-link .glyphicon {
    font-size: 14px;
    margin-left: 5px;
}

/* --- 5-Image Collage Styling --- */
.collage-wrapper {
    position: relative;
    height: 320px;
    /* Increased height for 5 images */
    width: 100%;
    margin-top: 20px;
}

.collage-card {
    position: absolute;
    border: 4px solid #ffffff;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.25);
    border-radius: 4px;
    transition: transform 0.4s ease, z-index 0s;
    background: white;
    width: 160px;
    /* Slightly smaller to fit 5 nicely */
    height: 110px;
}

.collage-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* --- Positioning 5 Cards --- */

/* LAYER 1: Background Cards */

/* Card 4: Community (Top Left) */
.card-4 {
    left: 10px;
    top: 0;
    z-index: 1;
    transform: rotate(-8deg);
}

/* Card 5: Donation (Top Right) */
.card-5 {
    right: 10px;
    top: 10px;
    z-index: 1;
    transform: rotate(6deg);
}

/* LAYER 2: Foreground Cards */

/* Card 1: Plantation (Bottom Left) */
.card-1 {
    left: 0;
    bottom: 10px;
    z-index: 2;
    transform: rotate(-12deg);
}

/* Card 3: Education (Bottom Right) */
.card-3 {
    right: 0;
    bottom: 20px;
    z-index: 2;
    transform: rotate(10deg);
}

/* LAYER 3: The Centerpiece */

/* Card 2: Organisation (Center) */
.card-2 {
    left: 50%;
    top: 60px;
    /* Pushed down to sit in the middle of the cluster */
    z-index: 10;
    /* Highest Z-Index */
    transform: translateX(-50%) rotate(0deg);
    width: 190px;
    /* Main image is larger */
    height: 130px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
    /* Stronger shadow */
}

/* Hover Effect */
.collage-card:hover {
    z-index: 50;
    /* Bring to very front */
    transform: scale(1.15) rotate(0deg) !important;
    border-color: #ffd700;
    cursor: pointer;
}

/* --- Responsive Adjustments --- */
@media (max-width: 991px) {
    .cert-banner-section {
        text-align: center;
    }

    .collage-wrapper {
        margin: 50px auto 0 auto;
        max-width: 400px;
    }

    .cert-title {
        font-size: 32px;
    }
}

@media (max-width: 480px) {

    /* Shrink cards for mobile screens */
    .collage-card {
        width: 120px;
        height: 85px;
    }

    .card-2 {
        width: 140px;
        height: 100px;
    }
}

/* Animation Helper */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}



/* --- Site Footer Existing Styles --- */
.site-footer {
    background-color: #1A202C;
    color: #A0AEC0;
    padding-top: 60px;
    font-size: 15px;
}

.footer-logo {
    max-width: 150px;
    margin-bottom: 15px;
}

.footer-tagline {
    font-style: italic;
    margin-bottom: 25px;
}

.footer-contact-info p {
    margin-bottom: 10px;
}

.footer-contact-info a {
    color: #A0AEC0;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-contact-info a:hover {
    color: #ffffff;
}

.footer-contact-info .glyphicon {
    margin-right: 10px;
    color: #4299e1;
}

.footer-social-icons {
    margin-top: 25px;
}

.footer-social-icons a img {
    height: 32px;
    width: 32px;
    margin-right: 15px;
    opacity: 0.8;
    transition: all 0.2s ease-in-out;
}

.footer-social-icons a:hover img {
    opacity: 1;
    transform: translateY(-2px);
}

.site-footer h4 {
    color: #ffffff;
    font-weight: 700;
    font-size: 18px;
    margin-bottom: 25px;
    text-transform: uppercase;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #A0AEC0;
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: #ffffff;
}

.developer-credit {
    text-align: right;
    font-style: italic;
    color: #A0AEC0;
}

/* Make the name clickable */
#dev-credit-link {
    color: #4299e1;
    /* Light Blue to show it is clickable */
    text-decoration: none;
    border-bottom: 1px dashed #4299e1;
    cursor: pointer;
}

#dev-credit-link:hover {
    color: #ffffff;
    border-bottom: 1px solid #ffffff;
}

.footer-bottom-bar {
    padding: 20px 0;
    margin-top: 40px;
    border-top: 1px solid #2D3748;
    text-align: center;
    font-size: 13px;
    color: #718096;
}

/* Responsive adjustments for mobile */
@media (max-width: 991px) {
    .site-footer {
        text-align: center;
    }

    .footer-logo {
        margin-left: auto;
        margin-right: auto;
    }

    .col-md-2,
    .col-md-3,
    .col-md-4 {
        margin-bottom: 40px;
    }

    .developer-credit {
        text-align: center;
    }
}

/* --- NEW: Modal Popup Styles --- */
.modal-overlay {
    display: none;
    /* Hidden by default */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    /* Semi-transparent black */
    backdrop-filter: blur(2px);
    /* Slight blur effect */
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    /* 15% from the top and centered */
    padding: 0;
    border: 1px solid #888;
    width: 90%;
    max-width: 400px;
    /* Max width of the popup card */
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: slideDown 0.3s ease-out;
    font-family: 'Heebo', sans-serif;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Header (Blue part) */
.modal-header {
    background-color: #2b6cb0;
    /* Your theme blue */
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
}

.close-modal {
    color: white;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
}

.close-modal:hover {
    color: #e2e8f0;
}

/* Body (White part) */
.modal-body {
    padding: 25px 20px;
    text-align: center;
    color: #333;
}

.modal-subtitle {
    color: #718096;
    font-weight: 500;
    margin-bottom: 20px;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.modal-contact-item {
    margin-bottom: 15px;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.modal-contact-item a {
    color: #2b6cb0;
    text-decoration: none;
    font-weight: 600;
}

.modal-contact-item a:hover {
    text-decoration: underline;
}

.modal-contact-item .glyphicon {
    color: #4a5568;
}

/* Instagram Icon Area */
.modal-icon-area {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.modal-insta-logo {
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: transform 0.2s;
}

.modal-insta-logo:hover {
    transform: scale(1.1);
}