:root {
    --font-family: 'Poppins', sans-serif;
    --dark-bg-start: #0A1128; /* Deep dark blue */
    --dark-bg-end: #1B263B;   /* Darker blue/gray */
    --glass-bg: rgba(255, 255, 255, 0.1); /* Translucent white */
    --glass-border: rgba(255, 255, 255, 0.2); /* Slightly less translucent border */
    --text-color: #E0E0E0; /* Light gray for general text */
    --heading-color: #FFFFFF; /* White for headings */
    --accent-color: #6a89cc; /* A soft, elegant blue accent */
    --light-glow: rgba(255, 255, 255, 0.15); /* Subtle white glow */
    --button-bg: #6a89cc;
    --button-hover-bg: #5c7cb8;
    --button-text: #FFFFFF;
    --link-color: #8bbcdc; /* Slightly lighter blue for links */
}

/* Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 70px; /* Account for fixed navbar */
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-color);
    background: linear-gradient(135deg, var(--dark-bg-start), var(--dark-bg-end));
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
    position: relative;
    overflow: hidden; /* For blurred backdrop effect */
    margin: 40px auto;
    border-radius: 15px;
    transition: transform 0.3s ease-out, box-shadow 0.3s ease-out;
    max-width: 1400px;
}

.section:not(.hero-section) {
    background: var(--glass-bg);
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

.section h2 {
    text-align: center;
    color: var(--heading-color);
    font-size: 2.8em;
    margin-bottom: 60px;
    font-weight: 600;
    letter-spacing: 1px;
    position: relative;
}

.section h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-color);
    margin: 15px auto 0;
    border-radius: 2px;
}

h1, h3, h4 {
    color: var(--heading-color);
    font-weight: 500;
}

a {
    color: var(--link-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--button-bg);
}

.button {
    display: inline-block;
    padding: 12px 28px;
    background: var(--button-bg);
    color: var(--button-text);
    border-radius: 50px;
    font-weight: 500;
    transition: background 0.3s ease, transform 0.2s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.button:hover {
    background: var(--button-hover-bg);
    transform: translateY(-2px);
}

.button-secondary {
    background: transparent;
    border: 1px solid var(--button-bg);
    color: var(--button-bg);
    box-shadow: none;
}

.button-secondary:hover {
    background: var(--button-bg);
    color: var(--button-text);
    transform: translateY(-2px);
}

.text-link {
    display: inline-block;
    margin-top: 15px;
    color: var(--link-color);
    font-weight: 500;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.text-link:hover {
    color: var(--button-bg);
}


/* Glass Card Base */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    z-index: 1;
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8em;
    font-weight: 700;
    color: var(--heading-color);
    letter-spacing: 0.5px;
}

.nav-links {
    list-style: none;
    display: flex;
}

.nav-links li {
    margin-left: 30px;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 30px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 100%;
    height: 3px;
    background: var(--heading-color);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle:hover span {
    background: var(--accent-color);
}

.nav-links a {
    color: var(--text-color);
    font-weight: 400;
    position: relative;
    padding: 5px 0;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--accent-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    bottom: 0;
    left: 0;
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}


/* Hero Section */
.hero-section {
    position: relative;
    height: 60vh; /* Compact height */
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: url('images/image_25.jpg') no-repeat center center/cover;
    background-attachment: fixed; /* Parallax effect */
    flex-shrink: 0;
    margin-top: 0;
    padding-top: 70px; /* Add padding to account for fixed navbar */
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6); /* Dark overlay */
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.hero-content {
    position: relative;
    z-index: 2;
    color: var(--heading-color);
    max-width: 800px;
    padding: 20px;
}

.hero-content h1 {
    font-size: 3.5em;
    margin-bottom: 20px;
    font-weight: 700;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

.hero-content p {
    font-size: 1.3em;
    margin-bottom: 30px;
    font-weight: 300;
}


/* Mission Section - Timeline Layout */
.mission-section {
    padding-top: 100px;
    padding-bottom: 100px;
}

.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background: var(--glass-border);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

.timeline-item {
    padding: 10px 0;
    position: relative;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
    padding-right: 30px;
    text-align: right;
}

.timeline-item:nth-child(even) {
    left: 50%;
    padding-left: 30px;
    text-align: left;
}

.timeline-point {
    position: absolute;
    width: 20px;
    height: 20px;
    background: var(--accent-color);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    border: 3px solid var(--glass-border);
    z-index: 1;
}

.timeline-item:nth-child(odd) .timeline-point {
    right: -10px;
}

.timeline-item:nth-child(even) .timeline-point {
    left: -10px;
}

.timeline-content {
    padding: 25px;
    background: var(--glass-bg);
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.timeline-content h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
    color: var(--heading-color);
}
.timeline-content p {
    font-size: 0.95em;
}


/* Services Section - Feature Highlights */
.services-section .feature-blocks {
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.feature-block {
    display: flex;
    align-items: center;
    gap: 40px;
    padding: 20px;
    border-radius: 15px;
    position: relative;
}

.feature-block .feature-image {
    width: 50%;
    border-radius: 12px;
    object-fit: cover;
    height: 350px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.feature-block .feature-image:hover {
    transform: scale(1.02);
}

.feature-block .feature-content {
    flex: 1;
    padding: 40px;
    border-radius: 15px;
    transform: translateX(0);
    transition: transform 0.3s ease;
}

.feature-block.reverse {
    flex-direction: row-reverse;
}

.feature-block h3 {
    font-size: 2em;
    margin-bottom: 15px;
}
.feature-block p {
    font-size: 1.05em;
    margin-bottom: 20px;
}


/* Solutions Section - Step by Step */
.solutions-section .step-by-step {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Enforce 3 cards per row */
    gap: 30px;
    text-align: center;
}

.step {
    padding: 40px;
    transition: all 0.3s ease;
}

.step:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.step-number {
    font-size: 3em;
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 20px;
    position: relative;
    display: inline-block;
    padding: 5px 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border: 1px solid var(--glass-border);
}

.step h3 {
    font-size: 1.8em;
    margin-bottom: 15px;
}
.step p {
    font-size: 1em;
}


/* Showcase Section - Success Stories */
.showcase-section .success-stories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Enforce 3 cards per row */
    gap: 30px;
}

.story-card {
    padding: 0;
    text-align: center;
    overflow: hidden;
}

.story-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    margin-bottom: 20px;
    transition: transform 0.4s ease;
}

.story-card:hover .story-image {
    transform: scale(1.05);
}

.story-content {
    padding: 20px 30px 30px;
}

.story-content h3 {
    font-size: 1.6em;
    margin-bottom: 15px;
}

.story-content p {
    font-size: 0.95em;
    margin-bottom: 20px;
}

.story-content blockquote {
    font-style: italic;
    color: var(--link-color);
    margin-top: 20px;
    padding: 10px 0;
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
    font-size: 0.9em;
}
.story-content cite {
    display: block;
    margin-top: 10px;
    font-size: 0.85em;
    color: var(--text-color);
    font-style: normal;
}


/* Gallery Section - Category Tabs & Interactive Zoom */
.gallery-tabs {
    text-align: center;
    margin-bottom: 50px;
}

.gallery-tab-button {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-color);
    padding: 10px 25px;
    margin: 0 10px;
    border-radius: 30px;
    cursor: pointer;
    font-family: var(--font-family);
    font-size: 1.1em;
    transition: all 0.3s ease;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.gallery-tab-button:hover {
    background: var(--button-hover-bg);
    color: var(--button-text);
    border-color: var(--button-hover-bg);
}

.gallery-tab-button.active {
    background: var(--button-bg);
    color: var(--button-text);
    border-color: var(--button-bg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Enforce 3 cards per row */
    gap: 30px;
}

.gallery-item {
    cursor: pointer;
    padding: 15px;
    overflow: hidden;
}

.gallery-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* Image Modal */
.image-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.image-modal.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 80%;
    max-height: 80%;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    opacity: 1;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.image-modal.active .modal-content {
    transform: scale(1);
    opacity: 1;
}

.close-button {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.close-button:hover,
.close-button:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}


/* Clients Section - Card Grid */
.clients-section .client-testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Enforce 3 cards per row */
    gap: 30px;
}

.testimonial-card {
    text-align: center;
    padding: 40px 30px;
}

.client-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 20px;
    border: 3px solid var(--accent-color);
    box-shadow: 0 0 0 5px rgba(255, 255, 255, 0.1);
}

.testimonial-card blockquote {
    font-size: 1.1em;
    font-style: italic;
    margin-bottom: 20px;
    line-height: 1.7;
    color: var(--text-color);
}

.testimonial-card .client-name {
    font-weight: 600;
    color: var(--heading-color);
    font-size: 1em;
}


/* Team Section - Department Sections */
.team-section .department {
    margin-bottom: 60px;
    text-align: center;
}

.team-section .department h3 {
    font-size: 2.2em;
    margin-bottom: 40px;
    color: var(--accent-color);
    position: relative;
    display: inline-block;
}

.team-section .department h3::after {
    content: '';
    display: block;
    width: 50%;
    height: 2px;
    background: var(--glass-border);
    margin: 10px auto 0;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Enforce 3 cards per row */
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.team-member {
    text-align: center;
    padding: 30px;
}

.team-member img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
    border: 4px solid var(--glass-border);
    box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.08);
}

.team-member h4 {
    font-size: 1.4em;
    margin-bottom: 5px;
}

.team-member p {
    font-size: 0.95em;
    color: var(--link-color);
}


/* Support Section - Side by Side */
.support-section .support-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.support-info-block {
    padding: 50px;
    text-align: center;
}

.support-info-block h3 {
    font-size: 2em;
    margin-bottom: 20px;
    color: var(--heading-color);
}

.support-info-block p {
    font-size: 1.1em;
    margin-bottom: 25px;
    line-height: 1.7;
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    padding: 30px 0;
    text-align: center;
    color: var(--text-color);
    font-size: 0.9em;
    margin-top: auto;
    border-top: 1px solid var(--glass-border);
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
    .container {
        padding: 0 15px;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background: rgba(0, 0, 0, 0.95);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        flex-direction: column;
        align-items: flex-start;
        padding: 80px 30px 30px;
        transition: right 0.3s ease;
        z-index: 999;
        box-shadow: -5px 0 20px rgba(0, 0, 0, 0.5);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links li {
        margin: 0 0 20px 0;
        width: 100%;
    }

    .nav-links a {
        font-size: 1.2em;
        padding: 10px 0;
        display: block;
        width: 100%;
    }

    .navbar .container {
        justify-content: space-between;
    }
    
    .hero-section {
        padding-top: 60px;
    }
    
    /* Overlay when menu is open */
    body.menu-open::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 998;
        pointer-events: none;
    }

    .hero-content h1 {
        font-size: 2.8em;
    }

    .hero-content p {
        font-size: 1.1em;
    }

    .section h2 {
        font-size: 2.2em;
        margin-bottom: 40px;
    }

    /* Mission Section */
    .timeline::after {
        left: 20px; /* Align timeline line to left */
    }

    .timeline-item {
        width: 100%;
        padding-left: 50px;
        padding-right: 0;
        text-align: left;
    }

    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        left: 0;
        padding-right: 0;
    }

    .timeline-item:nth-child(odd) .timeline-point,
    .timeline-item:nth-child(even) .timeline-point {
        left: 10px;
        right: auto;
    }

    /* Services Section */
    .feature-block,
    .feature-block.reverse {
        flex-direction: column;
        text-align: center;
    }

    .feature-block .feature-image {
        width: 100%;
        height: 250px;
        margin-bottom: 20px;
    }

    .feature-block .feature-content {
        padding: 30px;
    }

    /* All grid sections should stack to 1 column */
    .solutions-section .step-by-step,
    .showcase-section .success-stories-grid,
    .gallery-grid,
    .clients-section .client-testimonials-grid,
    .team-grid {
        grid-template-columns: 1fr; /* Stack to 1 column */
    }

    .gallery-tabs button {
        margin: 5px;
        padding: 8px 18px;
        font-size: 1em;
    }

    /* Support Section */
    .support-section .support-grid {
        grid-template-columns: 1fr; /* Stack to 1 column */
    }

    .support-info-block {
        padding: 40px;
    }
}

@media (max-width: 768px) {
    .hero-section {
        height: 50vh;
    }
    .hero-content h1 {
        font-size: 2.2em;
    }
    .hero-content p {
        font-size: 1em;
    }
    .section {
        padding: 60px 0;
    }
    .section h2 {
        font-size: 2em;
    }
    .footer {
        padding: 20px 0;
    }
}

@media (max-width: 480px) {
    .hero-section {
        height: 40vh;
    }
    .hero-content h1 {
        font-size: 1.8em;
    }
    .hero-content p {
        font-size: 0.9em;
    }
    .section {
        padding: 40px 0;
    }
    .section h2 {
        font-size: 1.8em;
    }
    .navbar .logo {
        font-size: 1.5em;
    }
    .button {
        padding: 10px 20px;
        font-size: 0.9em;
    }
    .gallery-tabs button {
        display: block;
        width: 80%;
        margin: 10px auto;
    }
}

/* Visible state helpers */
.animate-fade-in-up.visible,
.animate-fade-in-left.visible,
.animate-fade-in-right.visible,
.animate-bounce-y.visible,
.section-scroll-animate.visible,
.text-animate-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Enhanced: Team grid stabilization */
.team-grid { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 24px; 
}

@media (max-width: 900px) { 
    .team-grid { 
        grid-template-columns: repeat(2, 1fr); 
    } 
}

@media (max-width: 600px) { 
    .team-grid { 
        grid-template-columns: 1fr; 
    } 
}

/* Enhanced: Missing animation classes from JS */
.animate-on-scroll {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Safe visibility overrides (auto-added) */
:root, html, body, main, header, footer, section, .container, .content {
  opacity: 1 !important;
  visibility: visible !important;
}
