/* NAMS Education Development Council - Modern Stylesheet */

/* CSS Variables */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --primary-green: #059669;
    /* Emerald 600 */
    --forest-green: #064e3b;
    /* Emerald 900 */
    --primary-glow: rgba(5, 150, 105, 0.4);

    --gold: #f59e0b;
    /* Amber 500 */
    --gold-hover: #d97706;
    --gold-glow: rgba(245, 158, 11, 0.4);

    --light-green: #ecfdf5;
    /* Emerald 50 */
    --white: #ffffff;
    --black: #020617;
    /* Slate 950 */

    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-800: #1e293b;

    --font-heading: 'Plus Jakarta Sans', 'Montserrat', sans-serif;
    --font-body: 'Plus Jakarta Sans', 'Open Sans', sans-serif;
    --font-accent: 'Lora', serif;

    --max-width: 1280px;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;

    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);

    --transition: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--gray-800);
    background-color: var(--gray-50);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.25rem;
    color: var(--black);
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: var(--max-width);
    width: 100%;
    margin: 0 auto;
    padding: 0 24px;
}

/* Base Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 1.05rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s var(--transition);
    border: 2px solid transparent;
    letter-spacing: 0.02em;
}

.btn-primary {
    background-color: var(--gold);
    color: var(--forest-green);
    box-shadow: 0 4px 14px var(--gold-glow);
}

.btn-primary:hover {
    background-color: var(--gold-hover);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 25px var(--gold-glow);
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background-color: var(--white);
    color: var(--forest-green);
    transform: translateY(-3px) scale(1.02);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-green);
    border: 2px solid var(--primary-green);
}

.btn-outline:hover {
    background-color: var(--primary-green);
    color: var(--white);
    box-shadow: 0 6px 20px var(--primary-glow);
    transform: translateY(-3px);
}

/* Header - Modern Glassmorphism */
.main-header {
    background-color: rgba(6, 78, 59, 0.85);
    /* Deep emerald with opacity */
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

.logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    padding: 4px 0;
}

.logo-image {
    height: 100px;
    width: auto;
    max-width: 300px;
    object-fit: contain;
    transition: all 0.4s var(--transition);
}

.logo-image:hover {
    transform: scale(1.05);
}

.logo-text-fallback {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.logo-text {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--white);
    line-height: 1;
    letter-spacing: -0.03em;
}

.logo-subtitle {
    font-size: 0.7rem;
    color: var(--gold);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Main Navigation */
.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-nav>ul {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.main-nav>ul>li>a {
    color: var(--white);
    font-weight: 600;
    padding: 0.75rem 1.2rem;
    display: block;
    border-radius: var(--radius-full);
    font-size: 0.95rem;
    position: relative;
    overflow: hidden;
}

.main-nav>ul>li>a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: var(--gold);
    transition: width 0.3s var(--transition);
    border-radius: 3px 3px 0 0;
}

.main-nav>ul>li>a:hover::after {
    width: 80%;
}

.nav-donate {
    background-color: var(--gold) !important;
    color: var(--forest-green) !important;
    padding: 0.8rem 1.8rem !important;
    border-radius: var(--radius-full) !important;
    font-weight: 800 !important;
    margin-left: 1rem;
    box-shadow: 0 4px 15px var(--gold-glow);
}

.nav-donate:hover {
    background-color: var(--gold-hover) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--gold-glow);
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-arrow {
    font-size: 0.7rem;
    margin-left: 0.35rem;
    display: inline-block;
    transition: transform 0.3s var(--transition);
}

.dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: calc(100% + 15px);
    left: 50%;
    transform: translateX(-50%) translateY(10px) scale(0.95);
    background-color: var(--white);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.05);
    /* Softer border */
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
    /* Softer, broader shadow */
    min-width: 260px;
    /* Slightly wider */
    border-radius: var(--radius-lg);
    /* More rounded */
    padding: 1rem 0;
    /* More padding top/bottom */
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

/* Tooltip arrow pointing up */
.dropdown-menu::after {
    content: '';
    position: absolute;
    bottom: 100%;
    /* Top of the dropdown */
    left: 50%;
    margin-left: -8px;
    border-width: 8px;
    border-style: solid;
    border-color: transparent transparent var(--white) transparent;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0) scale(1);
    pointer-events: auto;
}

.dropdown-menu a {
    color: var(--gray-600);
    /* Slightly lighter text normally */
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    z-index: 1;
    transition: all 0.2s ease;
}

.dropdown-menu a::before {
    content: '';
    position: absolute;
    left: 12px;
    right: 12px;
    top: 4px;
    bottom: 4px;
    background: var(--light-green);
    /* Very light emerald hover */
    border-radius: var(--radius-sm);
    z-index: -1;
    opacity: 0;
    transform: scale(0.98);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.dropdown-menu a:hover {
    color: var(--primary-green);
    transform: translateX(3px);
    /* Gentle nudge right */
}

.dropdown-menu a:hover::before {
    opacity: 1;
    transform: scale(1);
}

/* Mobile Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 30px;
    height: 3px;
    background-color: var(--white);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 3px;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -5px);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    overflow: hidden;
    padding: 4rem 20px;
    background: linear-gradient(rgba(3, 53, 38, 0.85), rgba(3, 53, 38, 0.75)), url('../images/education_hero.png') center/cover no-repeat;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 60%);
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background-image: url('data:image/svg+xml,%3Csvg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"%3E%3Cg fill="none" fill-rule="evenodd"%3E%3Cg fill="%23ffffff" fill-opacity="0.03"%3E%3Cpath d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E');
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
}

.hero h1 {
    color: var(--white);
    margin-bottom: 1.5rem;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: fadeUp 1s ease forwards;
}

.hero p {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    margin-bottom: 2.5rem;
    line-height: 1.8;
    color: var(--gray-100);
    max-width: 750px;
    margin-inline: auto;
    font-weight: 500;
    animation: fadeUp 1s ease 0.2s forwards;
    opacity: 0;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeUp 1s ease 0.4s forwards;
    opacity: 0;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stats Section */
.stats {
    background-color: var(--white);
    padding: 6rem 0;
    position: relative;
    z-index: 10;
    margin-top: -60px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    max-width: var(--max-width);
    margin-inline: auto;
    width: calc(100% - 48px);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}

.stat-item {
    padding: 1.5rem;
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-green), var(--forest-green));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
    font-family: var(--font-heading);
}

.stat-label {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Mission Section */
.mission {
    padding: 5rem 0;
    background-color: var(--gray-50);
}

.mission-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 3rem;
}

.mission-card {
    background: var(--white);
    padding: 3rem 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: left;
    transition: all 0.4s var(--transition);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--gray-100);
    display: flex;
    flex-direction: column;
}

.mission-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-green), var(--gold));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s var(--transition);
}

.mission-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-xl);
}

.mission-card:hover::before {
    transform: scaleX(1);
}

.mission-icon {
    font-size: 3.5rem;
    margin-bottom: 2rem;
    background: var(--light-green);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
}

.mission-card h3 {
    margin-bottom: 1rem;
    font-size: 1.75rem;
}

.mission-card p {
    color: var(--gray-500);
    font-size: 1.05rem;
}

/* About Teaser */
.about-teaser {
    background: var(--white);
    color: var(--black);
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.about-flex {
    display: flex;
    align-items: center;
    gap: 4rem;
    flex-wrap: wrap;
}

.about-image {
    flex: 1;
    min-width: 300px;
}

.about-text {
    flex: 1.2;
    min-width: 300px;
}

.rounded-image {
    border-radius: var(--radius-lg);
    width: 100%;
    height: auto;
    object-fit: cover;
    box-shadow: var(--shadow-xl);
}

.about-teaser h2 {
    color: var(--forest-green);
    margin-bottom: 2rem;
}

.about-teaser p {
    font-size: 1.15rem;
    color: var(--gray-600);
    line-height: 1.8;
    margin-bottom: 2.5rem;
}

/* Donate Banner */
.donate-banner {
    background: linear-gradient(135deg, var(--forest-green) 0%, var(--primary-green) 100%);
    padding: 4.5rem 0;
    text-align: center;
    color: var(--white);
    position: relative;
}

.donate-banner h2 {
    color: var(--white);
    margin-bottom: 1.5rem;
}

.donate-banner p {
    font-size: 1.3rem;
    margin-bottom: 2.5rem;
    max-width: 700px;
    margin-inline: auto;
    font-weight: 600;
}

/* Sports Preview */
.sports-preview {
    padding: 5rem 0;
    background-color: var(--white);
}

.sports-preview h2 {
    text-align: center;
    margin-bottom: 4rem;
}

.sports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2.5rem;
}

.sport-card {
    background: var(--gray-50);
    padding: 2.5rem 2rem;
    border-radius: var(--radius-lg);
    text-align: center;
    transition: all 0.4s var(--transition);
    border: 1px solid var(--gray-100);
    display: flex;
    flex-direction: column;
}

.sport-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    background: var(--white);
    border-color: var(--primary-green);
}

.sport-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

.sport-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.sport-card p {
    color: var(--gray-500);
    margin-bottom: 2rem;
    flex-grow: 1;
}

.sport-card a {
    color: var(--primary-green);
    font-weight: 700;
    padding: 10px 20px;
    border-radius: var(--radius-full);
    background: var(--light-green);
    align-self: center;
}

.sport-card a:hover {
    background: var(--primary-green);
    color: var(--white);
}

/* Footer */
.main-footer {
    background-color: var(--black);
    color: var(--white);
    padding: 5rem 0 2rem;
    border-top: 5px solid var(--primary-green);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-section h3,
.footer-section h4 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.footer-section p {
    color: var(--gray-400);
    line-height: 1.6;
    margin-bottom: 0.8rem;
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 1rem;
    color: var(--gray-400);
    line-height: 1.5;
}

.footer-contact-item i {
    font-size: 1.25rem;
    color: var(--primary-green);
    margin-top: 3px;
    flex-shrink: 0;
}

.footer-bank-details p {
    margin-bottom: 0.5rem;
}

.footer-bank-details strong {
    color: var(--white);
    font-weight: 600;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 1rem;
}

.footer-section ul li a {
    color: var(--gray-400);
    font-weight: 500;
}

.footer-section a:hover {
    color: var(--gold);
    padding-left: 5px;
}

.footer-tagline {
    font-style: italic;
    color: var(--gold);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
    gap: 2rem;
    color: var(--gray-500);
}

.footer-legal,
.footer-social {
    display: flex;
    gap: 1.5rem;
}

.footer-legal a,
.footer-social a {
    color: var(--gray-400);
}

.footer-legal a:hover,
.footer-social a:hover {
    color: var(--white);
}

.footer-social a i {
    font-size: 1.5rem;
}

.footer-copyright {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 2rem;
    padding-top: 2rem;
    color: var(--gray-500);
    font-size: 0.9rem;
}

.footer-credit {
    margin-top: 0.5rem;
}

.footer-credit a {
    color: var(--gold);
    font-weight: 600;
}

.footer-credit a:hover {
    color: var(--white);
}

/* Responsive */
@media (max-width: 1024px) {
    .main-nav ul {
        gap: 0.5rem;
    }

    .main-nav>ul>li>a {
        padding: 0.5rem 0.8rem;
    }

    .nav-donate {
        padding: 0.6rem 1.2rem !important;
    }
}

@media (max-width: 768px) {
    .header-content {
        padding: 1rem 0;
    }

    .logo-image {
        height: 45px;
    }

    .logo-text {
        font-size: 1.4rem;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--forest-green);
        backdrop-filter: blur(25px);
        padding: 0.5rem 0 2rem;
        box-shadow: 0 10px 40px rgba(0,0,0,0.3);
        border-bottom: 3px solid var(--gold);
        height: calc(100vh - 75px); /* Forces it to fill the screen exactly */
        max-height: none;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    }



    .main-nav.active {
        display: block;
        animation: slideInDown 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    @keyframes slideInDown {
        from {
            opacity: 0;
            transform: translateY(-20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .main-nav ul {
        flex-direction: column;
        align-items: stretch;
        padding: 0;
        margin: 0;
        list-style: none;
    }


    .main-nav li {
        width: 100%;
    }

    .main-nav>ul>li>a {
        padding: 0.8rem 1.5rem;
        font-size: 1.1rem;
        text-align: center;
        display: block;
    }

    .main-nav>ul>li>a::after {
        display: none;
    }

    .dropdown-menu {
        position: static;
        box-shadow: none;
        background: transparent;
        border: none;
        padding: 0 !important;
        margin: 0 !important;
        width: 100% !important;
        min-width: 0;
        display: none;
        pointer-events: auto;
        border-radius: 0;
        transform: none !important;
        opacity: 1;
        visibility: visible;
        text-align: center;
    }

    .dropdown-menu li {
        width: 100% !important;
        display: block;
    }


    .dropdown-menu::after {
        display: none;
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    .dropdown-menu a {
        color: var(--gray-100);
        padding: 0.8rem 1.5rem !important;
        font-size: 0.95rem;
        font-weight: 600;
        position: relative;
        text-align: center !important;
        display: block !important; 
        width: 100% !important;
    }




    .dropdown-menu a::before {
        display: none; /* Disable hover highlight box on mobile */
    }

    .dropdown-menu a:hover {
        transform: none; /* Disable text shifting to right on mobile */
        color: var(--gold); /* Highlight with gold instead of dark green */
    }

    .dropdown-menu li:not(:last-child) a::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 20%; 
        right: 20%; 
        height: 1px;
        background: rgba(255, 255, 255, 0.08);
    }




    .nav-donate {
        margin: 1rem 1.5rem 0 !important;
        text-align: center;
        justify-content: center;
        padding: 0.7rem 1.5rem !important;
    }

    h1 {
        font-size: 2.5rem;
    }

    .stats {
        width: 100%;
        border-radius: 0;
        margin-top: 0;
        box-shadow: none;
        border-bottom: 1px solid var(--gray-200);
    }

    .mission,
    .sports-preview {
        padding: 5rem 0;
    }
}