/*
    Theme: Neural Mesh
    Primary Colors: Dark Purple/Blue (#0a0514), Electric Blue (#00aaff), Magenta (#9c27b0)
    Fonts: Poppins (Headings), Roboto (Body)
*/

/* ------------------- */
/* ROOT & GLOBAL STYLES */
/* ------------------- */

:root {
    --bg-dark: #0a0514;
    --bg-dark-accent: #110920;
    --primary-color: #00aaff;
    --secondary-color: #9c27b0;
    --text-light: #e0e0e0;
    --text-medium: #a0a0c0;
    --text-dark: #1e1e3c;
    --border-color: rgba(0, 170, 255, 0.2);
    --glow-color-primary: rgba(0, 170, 255, 0.5);
    --glow-color-secondary: rgba(156, 39, 176, 0.5);

    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Roboto', sans-serif;

    --header-height: 80px;
    --border-radius: 8px;
    --transition-fast: 0.3s ease;
    --transition-slow: 0.5s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: #fff;
    font-weight: 600;
}

h1 {
    font-size: 3.5rem;
    line-height: 1.2;
}

h2 {
    font-size: 2.5rem;
    line-height: 1.3;
}

h3 {
    font-size: 1.5rem;
    line-height: 1.4;
}

h4 {
    font-size: 1.2rem;
    line-height: 1.4;
}

p {
    color: var(--text-medium);
    margin-bottom: 1rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: #fff;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.section {
    padding: 6rem 0;
}

.section-header {
    margin-bottom: 4rem;
}

.section-tag {
    display: inline-block;
    color: var(--primary-color);
    font-family: var(--font-heading);
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.section-title {
    margin-bottom: 1rem;
}

.section-intro {
    max-width: 600px;
    margin: 0 auto;
    color: var(--text-medium);
}

.text-center {
    text-align: center;
}

.highlight {
    color: var(--primary-color);
    text-shadow: 0 0 10px var(--glow-color-primary);
}


/* ------------------- */
/* PRELOADER */
/* ------------------- */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-dark);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.preloader-logo {
    animation: pulse 1.5s infinite ease-in-out;
}

.preloader-logo img {
    max-width: 150px;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
}

.preloader.fade-out {
    opacity: 0;
    pointer-events: none;
}


/* ------------------- */
/* HEADER */
/* ------------------- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    z-index: 1000;
    transition: background-color var(--transition-fast), box-shadow var(--transition-fast);
}

.header.scrolled {
    background-color: rgba(10, 5, 20, 0.8);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    height: 100px;
    transition: transform var(--transition-fast);
}

.logo:hover {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-link {
    color: var(--text-light);
    font-family: var(--font-heading);
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    transition: width var(--transition-fast);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-close {
    display: none;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-light);
}

/* ------------------- */
/* BUTTONS & CTAS */
/* ------------------- */

.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: var(--border-radius);
    font-family: var(--font-heading);
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden;
    border: 2px solid transparent;
}

.btn-primary {
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    color: #fff;
    box-shadow: 0 5px 20px -5px var(--glow-color-primary);
}

.btn-primary:hover {
    box-shadow: 0 5px 25px 0px var(--glow-color-primary);
    transform: translateY(-3px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-light);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: #fff;
    box-shadow: 0 0 15px var(--glow-color-primary);
}

.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
}

.btn-full {
    width: 100%;
}

/* Voltage Pulse Animation */
.btn .pulse {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    opacity: 0;
}

.btn:hover .pulse {
    animation: voltage-pulse 0.7s ease-out;
}

@keyframes voltage-pulse {
    0% {
        width: 0;
        height: 0;
        opacity: 0.5;
    }

    100% {
        width: 200%;
        height: 200%;
        opacity: 0;
    }
}


/* ------------------- */
/* HERO SECTION */
/* ------------------- */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

#neural-mesh {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    text-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 2.5rem auto;
    color: var(--text-light);
}

.hero-cta {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

/* ------------------- */
/* SERVICES SECTION */
/* ------------------- */
.services-section {
    background-color: var(--bg-dark-accent);
    position: relative;
}

.services-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100px;
    background: linear-gradient(180deg, var(--bg-dark), var(--bg-dark-accent));
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.service-card {
    background-color: var(--bg-dark);
    border-radius: var(--border-radius);
    padding: 2.5rem;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    transition: transform var(--transition-slow), box-shadow var(--transition-slow);
    transform-style: preserve-3d;
}

.service-card:hover {
    transform: translateY(-10px) perspective(1000px) rotateX(5deg) rotateY(-5deg);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.service-card::before {
    /* path spark effect */
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent, var(--glow-color-primary), transparent);
    transition: left var(--transition-slow);
}

.service-card:hover::before {
    left: 100%;
}

.service-card-inner {
    position: relative;
    z-index: 1;
    transform: translateZ(20px);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    display: inline-block;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.service-title {
    margin-bottom: 1rem;
}

.service-description {
    min-height: 80px;
}

.service-link {
    font-weight: 600;
    font-family: var(--font-heading);
}

.service-link i {
    margin-left: 0.5rem;
    transition: transform var(--transition-fast);
}

.service-link:hover i {
    transform: translateX(5px);
}

/* ------------------- */
/* ABOUT US SECTION */
/* ------------------- */
.about-section {
    padding: 6rem 0;
}

.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-features {
    margin-top: 2rem;
}

.about-features li {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    color: var(--text-light);
}

.about-features i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.about-visual {
    position: relative;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.node-cluster {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    perspective: 1500px;
}

.node {
    position: absolute;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    box-shadow: 0 0 15px var(--glow-color-primary);
    transition: transform 2s cubic-bezier(0.25, 1, 0.5, 1);
    /* FIX: Increased transition duration for smoother effect */
}

/* ------------------- */
/* INDUSTRIES SECTION */
/* ------------------- */
.industries-section {
    background-color: var(--bg-dark-accent);
}

.industry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
}

.industry-item {
    text-align: center;
    padding: 2rem;
    background-color: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    transition: all var(--transition-fast);
}

.industry-item:hover {
    transform: translateY(-8px);
    background-color: var(--bg-dark-accent);
    border-color: var(--primary-color);
    box-shadow: 0 0 20px var(--glow-color-primary);
}

.industry-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    transition: transform var(--transition-fast);
}

.industry-item:hover .industry-icon {
    transform: scale(1.1);
}

.industry-item p {
    margin: 0;
    font-family: var(--font-heading);
    font-weight: 500;
}

/* ------------------- */
/* TESTIMONIALS SECTION */
/* ------------------- */
.testimonial-slider-wrapper {
    position: relative;
    overflow: hidden;
    /* FIX: Moved overflow:hidden to the wrapper */
    max-width: 800px;
    /* Optional: constrain width for better reading */
    margin: 0 auto;
}

.testimonial-slider {
    display: flex;
    width: 300%;
    /* FIX: Set width to 100% * number of slides */
    transition: transform 0.5s ease-in-out;
    /* FIX: Added transition for smooth sliding */
}

.testimonial-card {
    flex: 0 0 33.333%;
    /* FIX: Set flex-basis to 100% / number of slides */
    padding: 3rem;
    box-sizing: border-box;
    /* ADDED: Ensure padding is included in width calculation */
}

.testimonial-card-inner {
    /* ADDED: Wrapper for content inside the card for padding */
    background-color: var(--bg-dark-accent);
    padding: 3rem;
    border-radius: var(--border-radius);
    border-left: 5px solid var(--primary-color);
}

.testimonial-quote-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    opacity: 0.5;
    margin-bottom: 1rem;
}

.testimonial-text {
    font-size: 1.1rem;
    font-style: italic;
    margin-bottom: 2rem;
    color: var(--text-light);
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-name {
    font-family: var(--font-heading);
    font-weight: 600;
    color: #fff;
    margin: 0;
}

.author-title {
    color: var(--text-medium);
    margin: 0;
    font-size: 0.9rem;
}

.slider-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.slider-btn {
    background-color: var(--bg-dark-accent);
    border: 1px solid var(--border-color);
    color: var(--text-light);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.slider-btn:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

/* ------------------- */
/* CTA SECTION */
/* ------------------- */
.cta-section {
    background: linear-gradient(rgba(10, 5, 20, 0.9), rgba(10, 5, 20, 0.9)), url('https://www.transparenttextures.com/patterns/cubes.png') var(--bg-dark);
    padding: 5rem 0;
}

.cta-title {
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

.cta-text {
    max-width: 600px;
    margin: 0 auto 2rem auto;
}


/* ------------------- */
/* FOOTER */
/* ------------------- */
.footer {
    background-color: var(--bg-dark-accent);
    padding: 5rem 0 2rem 0;
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    max-width: 150px;
    margin-bottom: 1rem;
}

.footer-about-text {
    color: var(--text-medium);
    margin-bottom: 1.5rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background-color: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    color: var(--text-light);
    transition: all var(--transition-fast);
}

.social-links a:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-col-title {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: #fff;
}

.footer-links ul li {
    margin-bottom: 0.8rem;
}

.footer-links ul li a {
    color: var(--text-medium);
}

.footer-links ul li a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-contact ul li {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
    color: var(--text-medium);
}

.footer-contact ul li i {
    margin-top: 5px;
    color: var(--primary-color);
}

.footer-contact a {
    color: var(--text-medium);
}

.footer-contact a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 2rem;
    text-align: center;
    color: var(--text-medium);
}


/* ------------------- */
/* LEGAL & CONTACT PAGES */
/* ------------------- */
.page-header {
    padding: 8rem 0 4rem 0;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-dark-accent) 0%, var(--bg-dark) 100%);
}

.page-header h1 {
    margin-bottom: 1rem;
}

.breadcrumbs a {
    color: var(--text-medium);
}

.breadcrumbs span {
    color: var(--text-light);
}

.breadcrumbs i {
    font-size: 0.8rem;
    margin: 0 0.5rem;
}

.legal-content,
.contact-page-section {
    padding: 5rem 0;
}

.page-content {
    max-width: 800px;
    margin: 0 auto;
    background-color: var(--bg-dark-accent);
    padding: 3rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.page-content h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--primary-color);
}

.page-content p {
    line-height: 1.8;
}

/* Contact Page Specifics */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 3rem;
    background: var(--bg-dark-accent);
    padding: 3rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.contact-info-panel h3 {
    margin-bottom: 1rem;
}

.contact-details-list {
    margin-top: 2rem;
}

.contact-details-list li {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.contact-details-list i {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-top: 5px;
}

.contact-details-list h4 {
    margin-bottom: 0.2rem;
}

/* Form Styles */
.contact-form .form-row {
    display: flex;
    gap: 1.5rem;
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
    width: 100%;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem;
    background-color: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 10px var(--glow-color-primary);
}

.form-group label {
    position: absolute;
    top: 1rem;
    left: 1rem;
    color: var(--text-medium);
    pointer-events: none;
    transition: all var(--transition-fast);
}

.form-group input:focus+label,
.form-group input:not(:placeholder-shown)+label,
.form-group textarea:focus+label,
.form-group textarea:not(:placeholder-shown)+label {
    top: -0.7rem;
    left: 0.8rem;
    font-size: 0.8rem;
    background-color: var(--bg-dark-accent);
    padding: 0 0.3rem;
    color: var(--primary-color);
}

.form-group select {
    color: var(--text-medium);
    cursor: pointer;
}

.form-group select:required:invalid {
    color: var(--text-medium);
}

.form-group select option {
    background-color: var(--bg-dark);
    color: var(--text-light);
}

.form-group select option[value=""] {
    color: var(--text-medium);
}

/* Success Popup */
.popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition-fast), visibility var(--transition-fast);
}

.popup.show {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background-color: var(--bg-dark-accent);
    padding: 3rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    text-align: center;
    max-width: 450px;
    transform: scale(0.9);
    transition: transform var(--transition-fast);
}

.popup.show .popup-content {
    transform: scale(1);
}

.popup-icon {
    font-size: 4rem;
    color: #28a745;
    margin-bottom: 1rem;
}

/* ------------------- */
/* ANIMATIONS */
/* ------------------- */
.animate-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.animate-in[data-animation="fade-in-down"] {
    transform: translateY(-30px);
}

.animate-in[data-animation="fade-in-up"] {
    transform: translateY(30px);
}

.animate-in[data-animation="fade-in-left"] {
    transform: translateX(-30px);
}

.animate-in[data-animation="fade-in-right"] {
    transform: translateX(30px);
}

/* ------------------- */
/* MISCELLANEOUS */
/* ------------------- */
.live-chat-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: linear-gradient(45deg, var(--secondary-color), var(--primary-color));
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.8rem;
    cursor: pointer;
    box-shadow: 0 5px 20px var(--glow-color-primary);
    transition: transform var(--transition-fast);
    z-index: 999;
}

.live-chat-widget:hover {
    transform: scale(1.1);
}

/* ------------------- */
/* RESPONSIVENESS */
/* ------------------- */

/* Tablets (up to 992px) */
@media (max-width: 992px) {
    h1 {
        font-size: 2.8rem;
    }

    h2 {
        font-size: 2.2rem;
    }

    .hero-title {
        font-size: 3rem;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .about-visual {
        margin-top: 2rem;
        height: 300px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
    }
}

/* Mobile (up to 768px) */
@media (max-width: 768px) {
    html {
        font-size: 15px;
    }

    .section {
        padding: 4rem 0;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: var(--bg-dark-accent);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        box-shadow: -5px 0 20px rgba(0, 0, 0, 0.3);
        transition: right var(--transition-slow);
        z-index: 1001;
    }

    .nav-menu.show {
        right: 0;
    }

    .nav-list {
        flex-direction: column;
        gap: 2rem;
    }

    .nav-link {
        font-size: 1.2rem;
    }

    .nav-close {
        display: block;
        position: absolute;
        top: 1.5rem;
        right: 1.5rem;
        font-size: 2.5rem;
        color: var(--text-light);
        background: none;
        border: none;
        cursor: pointer;
    }

    .menu-toggle {
        display: block;
    }

    .header-actions .contactButton {
        display: none;
    }

    .hero {
        height: 90vh;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-cta {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .industry-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .testimonial-card {
        padding: 1rem;
        /* Adjust padding for mobile */
    }

    .testimonial-card-inner {
        padding: 2rem;
        /* Adjust padding for mobile */
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-about,
    .footer-links,
    .footer-contact {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .social-links {
        justify-content: center;
    }

    .footer-contact ul li {
        justify-content: center;
    }

    .contact-form .form-row {
        flex-direction: column;
        gap: 0;
    }
}