/* ==================
   1. CSS Variables & Global Styles
   ================== */
:root {
    /* Gradient Color Scheme */
    --primary-color: #4f46e5; /* Indigo */
    --secondary-color: #9333ea; /* Purple */
    --accent-color: #ec4899; /* Pink */
    --gradient-bg: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --gradient-text: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    
    /* Typography */
    --text-light: #f8fafc; /* Almost white */
    --text-dark: #333333;
    --text-dark-headings: #111827; /* Darker for headings */
    --text-muted: #6b7280;
    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Work Sans', sans-serif;
    
    /* Layout & Spacing */
    --header-height: 80px;
    --container-width: 1140px;
    --section-padding: 5rem 1.5rem;
    
    /* UI Elements */
    --border-radius: 12px;
    --card-shadow: 0 8px 24px rgba(23, 29, 41, 0.08);
    --transition-speed: 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Base Styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    background-color: var(--text-light);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Adaptive Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--text-dark-headings);
    line-height: 1.3;
    font-weight: 700;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.1);
}

h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.75rem); }
p { margin-bottom: 1rem; }
a { color: var(--primary-color); text-decoration: none; transition: var(--transition-speed); }
a:hover { color: var(--secondary-color); }
ul { list-style-type: none; }
img { max-width: 100%; height: auto; display: block; }

/* Layout Containers */
.container {
    max-width: var(--container-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}

.section {
    padding: var(--section-padding);
}

.section-light {
    background-color: #f9fafb;
}

.section-title {
    text-align: center;
    margin-bottom: 1rem;
}

.section-subtitle {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 3rem auto;
    color: var(--text-muted);
}

/* ScrollReveal Initialization state */
[data-scroll] {
    opacity: 1;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.6, 0.2, 0.1, 1);
}

[data-scroll="in"] {
    opacity: 1;
    transform: translateY(0);
}


/* ==================
   2. Global Components (Buttons, Cards)
   ================== */
.cta-button, .cta-button-outline {
    display: inline-block;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    padding: 14px 32px;
    border-radius: var(--border-radius);
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition-speed);
    text-align: center;
}

.cta-button {
    background: var(--gradient-bg);
    color: var(--text-light);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.cta-button:hover {
    color: var(--text-light);
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(0, 0, 0, 0.3);
}

.cta-button-outline {
    background-color: transparent;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.cta-button-outline:hover {
    background-color: var(--primary-color);
    color: var(--text-light);
}

.card {
    background: #fff;
    border-radius: var(--border-radius);
    box-shadow: var(--card-shadow);
    overflow: hidden;
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
    display: flex;
    flex-direction: column;
    text-align: center;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 16px 40px rgba(23, 29, 41, 0.12);
}

.card-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed);
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-content h3 {
    margin-bottom: 0.75rem;
}

.link-arrow {
    display: inline-block;
    margin-top: auto;
    font-weight: 600;
    color: var(--primary-color);
    transition: transform var(--transition-speed);
}

.link-arrow:hover {
    transform: translateX(5px);
}


/* ==================
   3. Header & Navigation
   ================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: var(--header-height);
    display: flex;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.9);
    transition: background-color var(--transition-speed), box-shadow var(--transition-speed);
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0.9);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--text-dark);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-bg);
    transition: width var(--transition-speed);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link-button {
    padding: 10px 24px;
    border-radius: var(--border-radius);
    background: var(--gradient-bg);
    color: var(--text-light);
}
.nav-link-button:hover {
    color: var(--text-light);
    transform: scale(1.05);
}
.nav-link-button::after {
    display: none;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: all 0.3s ease-in-out;
    background-color: var(--text-dark);
}


/* ==================
   4. Hero Section
   ================== */
.hero-section {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-light);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed; /* Parallax effect */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.7));
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    color: var(--text-light);
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    max-width: 700px;
    margin: 0 auto 2rem auto;
    opacity: 0.9;
}

/* ==================
   5. Section-specific Styles
   ================== */

/* Insights Section */
.insights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

/* Methodology Section */
.methodology-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    text-align: center;
}
.step-icon svg {
    width: 64px;
    height: 64px;
    stroke: var(--primary-color);
    margin-bottom: 1rem;
}

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
}
.project-card .card-content {
    text-align: left;
}

/* Events & Webinars Section */
.events-section {
    position: relative;
    background-position: center;
    background-size: cover;
    color: var(--text-light);
}
.section-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: var(--gradient-bg);
    opacity: 0.9;
}
.relative-z { position: relative; z-index: 2; }
.events-section .section-title, .events-section h3, .events-section h4, .events-section p {
    color: var(--text-light);
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}
.events-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    align-items: start;
}
.event-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
}
.event-item .link-arrow { color: var(--text-light); font-weight: bold; }
.calendar-list li {
    display: flex;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}
.calendar-list .date {
    background-color: rgba(255, 255, 255, 0.15);
    padding: 0.5rem;
    border-radius: 8px;
    margin-right: 1.5rem;
    font-weight: 700;
    text-align: center;
    min-width: 60px;
}
.calendar-list .event-name {
    font-weight: 500;
}

/* Awards & Accolades Section */
.accolades-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 3rem;
}
.accolade-item {
    text-align: center;
    max-width: 180px;
}
.accolade-item img {
    margin: 0 auto 1rem auto;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: var(--transition-speed);
}
.accolade-item:hover img {
    filter: grayscale(0%);
    opacity: 1;
}
.accolade-item p {
    font-weight: 500;
    color: var(--text-muted);
}

/* Pricing Section */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    align-items: stretch;
}
.pricing-card {
    border: 2px solid #e5e7eb;
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
}
.pricing-card.featured {
    border-color: var(--primary-color);
    transform: scale(1.05);
}
.pricing-card .price {
    font-size: 3rem;
    font-weight: 700;
    font-family: var(--font-heading);
    color: var(--text-dark-headings);
}
.price .price-unit {
    font-size: 1rem;
    color: var(--text-muted);
}
.price-desc {
    color: var(--text-muted);
    margin-bottom: 2rem;
}
.pricing-card ul {
    margin-bottom: 2rem;
    flex-grow: 1;
}
.pricing-card ul li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #e5e7eb;
}
.pricing-card ul li::before {
    content: '✓';
    color: var(--primary-color);
    margin-right: 0.5rem;
    font-weight: bold;
}

/* External Resources Section */
.resources-list .resource-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
    color: var(--text-dark);
    transition: var(--transition-speed);
}
.resources-list .resource-link:hover {
    border-color: var(--primary-color);
    background-color: #f9fafb;
    transform: translateX(5px);
}
.resource-link h4 {
    margin-bottom: 0.25rem;
}
.resource-link p {
    margin: 0;
    color: var(--text-muted);
}
.resource-arrow {
    font-size: 2rem;
    color: var(--primary-color);
    transition: transform var(--transition-speed);
}
.resource-link:hover .resource-arrow {
    transform: translateX(10px);
}

/* Contact Section */
.contact-wrapper {
    max-width: 700px;
    margin: 0 auto;
}
.contact-form .form-group {
    position: relative;
    margin-bottom: 2rem;
}
.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid #ccc;
    border-radius: var(--border-radius);
    background-color: #fff;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-speed);
}
.contact-form input:focus, .contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}
.contact-form label {
    position: absolute;
    top: 1rem;
    left: 1rem;
    color: var(--text-muted);
    pointer-events: none;
    transition: all 0.2s ease;
}
.contact-form input:focus + label,
.contact-form input:not(:placeholder-shown) + label,
.contact-form textarea:focus + label,
.contact-form textarea:not(:placeholder-shown) + label {
    top: -0.75rem;
    left: 0.75rem;
    font-size: 0.875rem;
    background-color: #f9fafb;
    padding: 0 0.25rem;
    color: var(--primary-color);
}
.contact-form button {
    width: 100%;
}

/* ==================
   6. Footer
   ================== */
.footer {
    background-color: #111827;
    color: #d1d5db;
    padding: 4rem 1.5rem 2rem 1.5rem;
}
.footer a {
    color: #d1d5db;
}
.footer a:hover {
    color: var(--text-light);
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}
.footer-col h3, .footer-col h4 {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}
.footer-col p {
    color: #9ca3af;
}
.footer-col ul li {
    margin-bottom: 0.75rem;
}
.footer-bottom {
    text-align: center;
    border-top: 1px solid #374151;
    padding-top: 2rem;
    color: #9ca3af;
}

/* ==================
   7. Specific Pages (Success, Privacy, etc.)
   ================== */
.success-page, .static-page {
    display: flex;
    flex-direction: column;
}
.success-container {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--section-padding);
}
.success-content {
    max-width: 600px;
}
.success-content h1 {
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1rem;
}

.static-page-content {
    padding-top: calc(var(--header-height) + 2rem);
    padding-bottom: 4rem;
}
.static-page-content h1 {
    margin-bottom: 2rem;
}
.static-page-content h2 {
    margin-top: 2.5rem;
    margin-bottom: 1rem;
}


/* ==================
   8. Media Queries (Responsiveness)
   ================== */
@media (max-width: 992px) {
    .events-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: var(--header-height);
        flex-direction: column;
        background-color: #fff;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-item {
        margin: 1.5rem 0;
    }

    .hamburger {
        display: block;
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

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

    .pricing-card.featured {
        transform: scale(1);
    }
}