/* CSS Variables */
:root {
    --color-primary: #0A84FF; /* Vibrant Blue */
    --color-primary-darker: #0060DF;
    --color-accent1: #FF9F0A; /* Warm Orange */
    --color-accent1-darker: #E88E00;
    --color-accent2: #30D158; /* Vibrant Green */
    --color-bg-dark: #121212;
    --color-bg-medium: #1c1c1e;
    --color-bg-light: #f0f2f3;
    --color-bg-glass: rgba(30, 30, 40, 0.6); /* Darker glass for better contrast with light text */
    --color-border-glass: rgba(255, 255, 255, 0.1);
    --color-text-light: #F5F5F7;
    --color-text-medium: #AEAEB2;
    --color-text-dark: #1D1D1F;
    --color-shadow: rgba(0, 0, 0, 0.3);

    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'DM Sans', sans-serif;

    --header-height: 80px;
    --border-radius-sm: 8px;
    --border-radius-md: 15px;
    --border-radius-lg: 20px;

    --transition-speed: 0.3s;
}

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

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

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

.main-wrapper {
    overflow-x: hidden; /* Prevents horizontal scroll from animations */
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--color-text-light);
    margin-bottom: 0.75em;
    line-height: 1.3;
    font-weight: 700;
    text-shadow: 1px 1px 2px var(--color-shadow);
}

h1 { font-size: clamp(2.5rem, 5vw, 3.8rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); text-align: center; margin-bottom: 1.5em; }
h3 { font-size: clamp(1.5rem, 3vw, 2rem); }
h4 { font-size: clamp(1.2rem, 2.5vw, 1.5rem); }

p {
    margin-bottom: 1.25em;
    color: var(--color-text-medium);
}

a {
    color: var(--color-accent1);
    text-decoration: none;
    transition: color var(--transition-speed) ease;
}

a:hover, a:focus {
    color: var(--color-accent1-darker);
    text-decoration: underline;
}

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

/* Layout */
.container {
    width: 90%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 15px;
    padding-right: 15px;
}

/* Sections */
.section {
    padding: 60px 0;
    position: relative;
}

.section-title {
    margin-bottom: 40px;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background-color: var(--color-primary);
    margin: 15px auto 0;
    border-radius: 2px;
}

.section-description {
    font-size: 1.1rem;
    color: var(--color-text-medium);
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 40px;
}

/* Glassmorphism */
.glassmorphic-element, .glassmorphic-section .container > *, .glassmorphic-form {
    background: var(--color-bg-glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px); /* Safari */
    border: 1px solid var(--color-border-glass);
    border-radius: var(--border-radius-md);
    padding: 20px;
    box-shadow: 0 8px 32px 0 var(--color-shadow);
}
.glassmorphic-section { /* For sections that are entirely glassmorphic background */
    background: var(--color-bg-glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px); /* Safari */
    border-top: 1px solid var(--color-border-glass);
    border-bottom: 1px solid var(--color-border-glass);
}
.glassmorphic-section .container > * { /* If content inside glass section needs separate glass elements */
   /* background: transparent;
    backdrop-filter: none;
    border: none;
    box-shadow: none; */
    /* This logic might need adjustment based on exact nesting. Often, the direct children are not glassmorphic if the parent section is. */
}


/* Buttons */
.cta-button, button[type="submit"] {
    display: inline-block;
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-darker));
    color: var(--color-text-light);
    padding: 12px 30px;
    border-radius: var(--border-radius-sm);
    font-family: var(--font-heading);
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
    font-size: 1rem;
    text-align: center;
}

.cta-button:hover, button[type="submit"]:hover {
    background: linear-gradient(135deg, var(--color-primary-darker), var(--color-primary));
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 6px 20px rgba(0, 123, 255, 0.5);
    color: #fff;
    text-decoration: none;
}

.cta-button:focus, button[type="submit"]:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 10px 0;
    transition: background-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.site-header.scrolled {
    background: var(--color-bg-glass); /* Uses the defined glassmorphic style */
    box-shadow: 0 2px 10px var(--color-shadow);
}

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

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-text-light);
    text-decoration: none;
}
.logo:hover {
    color: var(--color-primary);
}

.main-nav .nav-links {
    list-style: none;
    display: flex;
    gap: 25px;
}

.main-nav .nav-links a {
    color: var(--color-text-medium);
    font-weight: 500;
    padding: 8px 0;
    position: relative;
    text-decoration: none;
}

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

.main-nav .nav-links a:hover,
.main-nav .nav-links a.active {
    color: var(--color-text-light);
}

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

.nav-toggle {
    display: none; /* Hidden by default, shown on mobile */
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001; /* Above nav links on mobile */
}

.hamburger {
    display: block;
    position: relative;
    width: 25px;
    height: 3px;
    background-color: var(--color-text-light);
    border-radius: 3px;
    transition: all var(--transition-speed) ease-in-out;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 25px;
    height: 3px;
    background-color: var(--color-text-light);
    border-radius: 3px;
    transition: all var(--transition-speed) ease-in-out;
}

.hamburger::before { transform: translateY(-8px); }
.hamburger::after { transform: translateY(8px); }

.nav-toggle.active .hamburger {
    background-color: transparent; /* Middle bar disappears */
}
.nav-toggle.active .hamburger::before {
    transform: translateY(0) rotate(45deg);
}
.nav-toggle.active .hamburger::after {
    transform: translateY(0) rotate(-45deg);
}


/* Hero Section */
.hero-section {
    min-height: 100vh; /* Make hero fill the viewport */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

.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));
    z-index: 1;
}

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

.hero-title {
    font-size: clamp(2.8rem, 6vw, 4.5rem);
    color: var(--color-text-light); /* Ensured white text */
    margin-bottom: 0.5em;
    text-shadow: 2px 2px 8px var(--color-shadow);
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    color: var(--color-text-light); /* Ensured white text */
    max-width: 800px;
    margin: 0 auto 1.5em auto;
    line-height: 1.8;
    text-shadow: 1px 1px 4px var(--color-shadow);
}

.scroll-down-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    animation: bounce 2s infinite;
}
.scroll-down-indicator svg {
    width: 30px;
    height: 30px;
    fill: var(--color-text-light);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* Parallax Background Sections */
.parallax-background {
    background-attachment: fixed; /* Simple parallax effect */
}


/* Innovation Section */
.innovation-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    align-items: center;
}
.innovation-text {
    flex: 1 1 500px; /* Grow and shrink, base width 500px */
}
.innovation-visual {
    flex: 1 1 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.innovation-visual img {
    border-radius: var(--border-radius-lg);
    box-shadow: 0 10px 30px var(--color-shadow);
    max-width: 100%;
}

/* History Section - Timeline */
.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.timeline::after { /* The central line */
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--color-primary);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: transparent; /* Items themselves are not the line */
    width: 50%;
}
.timeline-item:nth-child(odd) {
    left: 0;
}
.timeline-item:nth-child(even) {
    left: 50%;
}
.timeline-item::after { /* The circles on the line */
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: var(--color-bg-dark);
    border: 4px solid var(--color-primary);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
}
.timeline-item:nth-child(even)::after {
    left: -10px;
}

.timeline-icon { /* For the SVG icons */
    position: absolute;
    top: 20px; /* Adjust to align with circle */
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2; /* Above the line's circle */
}
.timeline-item:nth-child(odd) .timeline-icon {
    right: 15px; /* Position relative to item's edge */
}
.timeline-item:nth-child(even) .timeline-icon {
    left: 15px;
}
.timeline-icon svg {
    fill: var(--color-accent1);
    width: 24px;
    height: 24px;
}


.timeline-content {
    padding: 20px 30px;
    position: relative;
    border-radius: var(--border-radius-md); /* Already handled by glassmorphic-element */
}
.timeline-content h3 {
    margin-top: 0;
    color: var(--color-primary);
}

/* Success Stories / Cards Section */
.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.card {
    background-color: var(--color-bg-medium);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: 0 5px 15px var(--color-shadow);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
    display: flex;
    flex-direction: column;
    /* align-items: center; /* This centers the whole card content horizontally IF the card itself is narrower */
    /* text-align: center; /* This centers text within the card content */
}

.card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.card-image { /* Container for the image */
    width: 100%;
    height: 250px; /* Fixed height for image container */
    overflow: hidden; /* Important for object-fit */
    margin: 0 auto; /* Center if card is wider than image, but usually not needed with width 100% */
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Cover the area, crop if necessary */
    display: block;
}

.card-content {
    padding: 25px;
    flex-grow: 1; /* Allows content to fill space if cards have different text lengths */
    /* Glassmorphic styles will be applied by .glassmorphic-element if used directly on card-content */
    /* text-align: center; /* Center text if desired for all cards */
}
.card-content.glassmorphic-element {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-top: none; /* Avoid double border with image */
}

.card-content h3 {
    margin-top: 0;
    color: var(--color-primary);
    font-size: 1.4rem;
}

/* Accolades Section */
.accolades-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.accolade-item {
    padding: 25px;
    text-align: center;
}
.accolade-item.glassmorphic-element { /* Ensure consistent padding and glass effect */
    /* Already styled by .glassmorphic-element */
}

.accolade-icon {
    margin-bottom: 15px;
    display: flex;
    justify-content: center;
}
.accolade-icon img {
    width: 60px; /* Adjust size as needed */
    height: 60px;
    filter: drop-shadow(0 2px 5px var(--color-primary));
}
.accolade-item h3 {
    font-size: 1.3rem;
    color: var(--color-accent1);
}


/* External Resources Section */
.resources-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
}
.resource-item {
    padding: 20px;
}
.resource-item h4 a {
    font-size: 1.2rem;
    color: var(--color-primary);
    font-weight: bold;
}
.resource-item h4 a:hover {
    color: var(--color-primary-darker);
}
.resource-item p {
    font-size: 0.95rem;
    color: var(--color-text-medium);
    margin-bottom: 0;
}


/* Contact Section */
.contact-section {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}
.contact-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.8));
    z-index: 0;
}
.contact-section .container {
    position: relative;
    z-index: 1;
}
.contact-section .section-title,
.contact-section .section-description,
.contact-section .contact-email-info,
.contact-section .contact-email-info a {
    color: var(--color-text-light); /* Ensure text is light on dark background */
    text-shadow: 1px 1px 3px var(--color-shadow);
}
.contact-section .contact-email-info a:hover {
    color: var(--color-accent1-darker);
}

.contact-form {
    max-width: 700px;
    margin: 40px auto 0;
    padding: 30px; /* Padding from glassmorphic-form */
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--color-text-medium);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border-radius: var(--border-radius-sm);
    border: 1px solid var(--color-border-glass); /* Subtle border */
    background-color: rgba(255, 255, 255, 0.05); /* Slightly lighter than form background */
    color: var(--color-text-light);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(var(--color-primary), 0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-submit-button {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
}

.contact-email-info {
    text-align: center;
    margin-top: 30px;
}


/* Footer */
.site-footer {
    padding: 40px 0 20px;
    text-align: center;
}
.site-footer.glassmorphic-element { /* Ensure padding is inside the glass effect */
    /* Padding applied directly to .site-footer */
}

.footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 30px;
    margin-bottom: 30px;
    text-align: left;
}

.footer-nav, .footer-social, .footer-contact-info {
    flex: 1;
    min-width: 200px; /* Ensure they don't get too squished */
}

.footer-nav h4, .footer-social h4, .footer-contact-info h4 {
    font-size: 1.2rem;
    color: var(--color-primary);
    margin-bottom: 15px;
}

.footer-nav ul, .footer-social ul {
    list-style: none;
}

.footer-nav ul li a, .footer-social ul li a {
    color: var(--color-text-medium);
    display: block;
    padding: 5px 0;
    transition: color var(--transition-speed) ease;
}

.footer-nav ul li a:hover, .footer-social ul li a:hover {
    color: var(--color-text-light);
    text-decoration: none; /* Keep consistent */
}

.footer-contact-info p {
    margin-bottom: 8px;
    color: var(--color-text-medium);
    font-size: 0.95rem;
}
.footer-contact-info p a {
    color: var(--color-accent1);
}
.footer-contact-info p a:hover {
    color: var(--color-accent1-darker);
}

.copyright {
    padding-top: 20px;
    border-top: 1px solid var(--color-border-glass);
    font-size: 0.9rem;
    color: var(--color-text-medium);
}

/* Privacy & Terms Pages Specific Styling */
.privacy-page-content, .terms-page-content {
    padding-top: calc(var(--header-height) + 40px); /* Header height + extra space */
    padding-bottom: 40px;
    color: var(--color-text-light); /* Ensure text is light */
}
.privacy-page-content .container, .terms-page-content .container {
    background-color: var(--color-bg-medium);
    padding: 30px;
    border-radius: var(--border-radius-md);
    box-shadow: 0 5px 15px var(--color-shadow);
}
.privacy-page-content h1, .terms-page-content h1 {
    text-align: center;
    margin-bottom: 1.5em;
    color: var(--color-primary);
}
.privacy-page-content h2, .terms-page-content h2 {
    text-align: left;
    color: var(--color-accent1);
    margin-top: 1.5em;
    font-size: 1.8rem;
}
.privacy-page-content p, .terms-page-content p,
.privacy-page-content li, .terms-page-content li {
    color: var(--color-text-medium);
}
.privacy-page-content ul, .terms-page-content ul {
    margin-left: 20px;
    margin-bottom: 1em;
}

/* Success Page Specific Styling */
.success-page-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, var(--color-bg-dark), #0f1015);
}
.success-content {
    background: var(--color-bg-glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--color-border-glass);
    border-radius: var(--border-radius-lg);
    padding: 40px;
    max-width: 600px;
    box-shadow: 0 8px 32px 0 var(--color-shadow);
}
.success-content h1 {
    color: var(--color-accent2); /* Green for success */
    font-size: 2.5rem;
    margin-bottom: 0.5em;
}
.success-content p {
    font-size: 1.2rem;
    color: var(--color-text-light);
    margin-bottom: 1.5em;
}
.success-content .cta-button {
    background: linear-gradient(135deg, var(--color-accent2), #28a745); /* Green button */
    box-shadow: 0 4px 15px rgba(48, 209, 88, 0.4);
}
.success-content .cta-button:hover {
    background: linear-gradient(135deg, #28a745, var(--color-accent2));
    box-shadow: 0 6px 20px rgba(48, 209, 88, 0.5);
}

/* Read More Link Style */
a.read-more {
    display: inline-block;
    margin-top: 10px;
    font-weight: bold;
    color: var(--color-primary);
    text-decoration: none;
    position: relative;
    padding-right: 20px; /* Space for arrow */
}
a.read-more::after {
    content: '→';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    transition: right var(--transition-speed) ease;
}
a.read-more:hover {
    color: var(--color-primary-darker);
    text-decoration: underline;
}
a.read-more:hover::after {
    right: -5px;
}


/* Animations (using Animate.css classes via JS) */
.animate__animated {
    visibility: hidden; /* Hide until animation starts */
}
.animate__animated.animate__fadeInUp {
    visibility: visible;
}


/* Responsive Styles */
@media (max-width: 992px) {
    .timeline::after {
        left: 31px; /* Move central line to the left */
    }
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        left: 0; /* All items to the right of the line */
    }
    .timeline-item::after { /* Circles */
        left: -10px; /* Position relative to the central line */
    }
    .timeline-item:nth-child(odd) .timeline-icon,
    .timeline-item:nth-child(even) .timeline-icon {
        left: 5px; /* Icons to the left of the content block, near the line */
    }
}


@media (max-width: 768px) {
    h1 { font-size: clamp(2rem, 6vw, 3rem); }
    h2 { font-size: clamp(1.8rem, 5vw, 2.5rem); }

    .nav-toggle {
        display: block; /* Show hamburger */
    }

    .main-nav .nav-links {
        position: fixed;
        top: 0;
        left: -100%; /* Start off-screen */
        width: 70%;
        max-width: 300px;
        height: 100vh;
        flex-direction: column;
        background-color: var(--color-bg-medium); /* Solid background for mobile menu */
        padding: calc(var(--header-height) + 20px) 30px 30px;
        box-shadow: 5px 0 15px var(--color-shadow);
        transition: left var(--transition-speed) ease-in-out;
        gap: 15px;
        align-items: flex-start;
    }

    .main-nav .nav-links.active {
        left: 0; /* Slide in */
    }

    .main-nav .nav-links a {
        font-size: 1.2rem;
        width: 100%;
        padding: 10px 0;
    }
    .main-nav .nav-links a::after { /* Full underline for mobile nav items */
        height: 1px;
    }

    .hero-section {
        padding-top: var(--header-height); /* Account for fixed header */
    }

    .innovation-content {
        flex-direction: column;
    }
    .innovation-visual img {
        max-width: 80%;
    }
    
    .footer-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .footer-nav, .footer-social, .footer-contact-info {
        width: 100%;
        max-width: 350px;
        text-align: center;
    }
    .footer-nav ul, .footer-social ul {
        padding-left: 0; /* Remove default ul padding */
    }
}

@media (max-width: 480px) {
    .container {
        width: 95%;
    }
    .section {
        padding: 40px 0;
    }
    .timeline-item {
        padding-left: 55px;
        padding-right: 15px;
    }
    .timeline::after {
        left: 20px;
    }
     .timeline-item::after { /* Circles */
        left: -10px; /* Relative to timeline line */
        width: 16px;
        height: 16px;
    }
    .timeline-item:nth-child(odd) .timeline-icon,
    .timeline-item:nth-child(even) .timeline-icon {
        left: -5px; /* Adjust icon position */
        width: 30px;
        height: 30px;
    }
    .timeline-icon svg {
        width: 18px;
        height: 18px;
    }
}

*{
    opacity: 1 !important;
}