/*
================================================
TABLE OF CONTENTS
================================================
1.  CSS VARIABLES & ROOT STYLES
2.  GENERAL & UTILITY STYLES
3.  TYPOGRAPHY
4.  LOADER
5.  HEADER & NAVIGATION (REVISED BASED ON IMAGE)
6.  MOBILE MENU
7.  MAIN CONTENT FIX
8.  FOOTER
9.  BUTTONS & FORMS (REVISED)
10. HERO SECTION
11. SERVICES SECTION
12. PROCESS SECTION (TIMELINE)
13. INDUSTRY EXPERTISE SECTION
14. TESTIMONIALS SECTION
15. CTA SECTION
16. PAGE-SPECIFIC STYLES (CONTACT, LEGAL)
17. INTERACTIVE WIDGETS (POPUP, CHAT)
18. ANIMATIONS & KEYFRAMES
19. RESPONSIVE DESIGN (MEDIA QUERIES)
================================================
*/


/* 1. CSS VARIABLES & ROOT STYLES
------------------------------------------------*/
:root {
    /* Updated colors to match the image's theme */
    --color-primary: #8A4DFF;
    --color-primary-hover: #A36BFF;
    --color-secondary: #0D0D1A;
    --color-background: #0D0D1A;
    --color-surface: #14142B;
    --color-surface-light: #1E1E3D;
    --color-text: #E0E0E0;
    --color-text-muted: #A0A0B8;
    --color-heading: #FFFFFF;
    --color-border: rgba(255, 255, 255, 0.1);
    --color-gradient-start: #6D55FF;
    --color-gradient-end: #A855FF;

    --font-heading: 'Orbitron', sans-serif;
    --font-body: 'Rajdhani', sans-serif;

    --header-height: 80px;
    --border-radius: 8px;
    --container-width: 1200px;
    --transition-speed: 0.3s;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--color-background);
    color: var(--color-text);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


/* 2. GENERAL & UTILITY STYLES
------------------------------------------------*/
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 100px 0;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    color: var(--color-primary);
    transition: color var(--transition-speed) ease;
}

a:hover {
    color: var(--color-primary-hover);
}

.text-gradient {
    background: linear-gradient(90deg, var(--color-gradient-start), var(--color-gradient-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
}

.section-header {
    margin-bottom: 60px;
}

.section-subtitle {
    display: block;
    font-family: var(--font-heading);
    color: var(--color-primary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.section-title {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.section-description {
    font-size: 1.1rem;
    color: var(--color-text-muted);
    max-width: 600px;
    margin: 0 auto;
}

.text-center {
    text-align: center;
}


/* 3. TYPOGRAPHY
------------------------------------------------*/
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-heading);
    line-height: 1.3;
    font-weight: 700;
}

h1 {
    font-size: 3.5rem;
}

h2 {
    font-size: 2.8rem;
}

h3 {
    font-size: 1.8rem;
}

h4 {
    font-size: 1.2rem;
}

p {
    margin-bottom: 1rem;
}


/* 4. LOADER
------------------------------------------------*/
.loader-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--color-secondary);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loader-wrapper.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-text {
    font-family: var(--font-heading);
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 20px;
    animation: pulse 1.5s infinite ease-in-out;
}

.loader-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
    width: 60px;
    height: 60px;
}

.loader-grid div {
    width: 100%;
    height: 100%;
    background-color: var(--color-primary);
    animation: loader-grid-animation 1.3s infinite ease-in-out;
}

.loader-grid div:nth-child(1) {
    animation-delay: 0.2s;
}

.loader-grid div:nth-child(2) {
    animation-delay: 0.3s;
}

.loader-grid div:nth-child(3) {
    animation-delay: 0.4s;
}

.loader-grid div:nth-child(4) {
    animation-delay: 0.1s;
}

.loader-grid div:nth-child(5) {
    animation-delay: 0.2s;
}

.loader-grid div:nth-child(6) {
    animation-delay: 0.3s;
}

.loader-grid div:nth-child(7) {
    animation-delay: 0.0s;
}

.loader-grid div:nth-child(8) {
    animation-delay: 0.1s;
}

.loader-grid div:nth-child(9) {
    animation-delay: 0.2s;
}


/* 5. HEADER & NAVIGATION (REVISED BASED ON IMAGE)
------------------------------------------------*/
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: var(--header-height);
    display: flex;
    align-items: center;
    transition: all var(--transition-speed) ease;
    /* Solid background color as per the image */
    background-color: var(--color-secondary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 1200px;
}

.logo img {
    height: 80px;
    filter: brightness(0) invert(1);
    /* Adjusted size to better match the image */
}

.main-nav .nav-list {
    display: flex;
    gap: 45px;
    /* Increased gap for better spacing */
}

.nav-link {
    font-family: var(--font-heading);
    color: var(--color-heading);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    /* Added letter spacing */
    position: relative;
    padding: 10px 0;
    font-size: 0.9rem;
}

/* Revised active/hover underline effect */
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    /* Positioned slightly below the text */
    left: 50%;
    width: 30px;
    /* Short underline */
    height: 3px;
    /* Thicker underline */
    background: linear-gradient(90deg, var(--color-gradient-start), var(--color-gradient-end));
    border-radius: 2px;
    transform: translateX(-50%) scaleX(0);
    /* Start hidden and scaled to 0 */
    transform-origin: center;
    transition: transform 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    transform: translateX(-50%) scaleX(1);
    /* Scale to full width on hover/active */
}

.nav-link:hover,
.nav-link.active {
    color: white;
}

.header-actions .btn {
    display: flex;
}

.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.hamburger-box {
    width: 30px;
    height: 24px;
    position: relative;
}

.hamburger-inner,
.hamburger-inner::before,
.hamburger-inner::after {
    width: 30px;
    height: 3px;
    background-color: var(--color-heading);
    border-radius: 3px;
    position: absolute;
    transition: transform 0.2s ease-in-out;
}

.hamburger-inner {
    top: 50%;
    transform: translateY(-50%);
}

.hamburger-inner::before,
.hamburger-inner::after {
    content: '';
}

.hamburger-inner::before {
    top: -10px;
}

.hamburger-inner::after {
    bottom: -10px;
}

.mobile-menu-toggle.is-active .hamburger-inner {
    transform: rotate(45deg);
}

.mobile-menu-toggle.is-active .hamburger-inner::before {
    top: 0;
    opacity: 0;
}

.mobile-menu-toggle.is-active .hamburger-inner::after {
    bottom: 0;
    transform: rotate(-90deg);
}


/* 6. MOBILE MENU
------------------------------------------------*/
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--color-secondary);
    z-index: 999;
    display: flex;
    justify-content: center;
    align-items: center;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.77, 0, 0.175, 1);
}

.mobile-menu.is-open {
    transform: translateX(0);
}

.mobile-nav-list {
    text-align: center;
}

.mobile-nav-list li {
    margin: 20px 0;
}

.mobile-nav-link {
    font-family: var(--font-heading);
    color: var(--color-heading);
    font-size: 1.8rem;
    font-weight: 700;
    text-transform: uppercase;
    transition: color var(--transition-speed) ease;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: var(--color-primary);
}

/* 7. MAIN CONTENT FIX
------------------------------------------------*/
main {
    padding-top: var(--header-height);
}


/* 8. FOOTER
------------------------------------------------*/
.footer {
    background-color: var(--color-secondary);
    padding: 80px 0 0;
    border-top: 1px solid var(--color-border);
}

.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 40px;
    padding-bottom: 40px;
}

.footer-col h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--color-heading);
    font-family: var(--font-heading);
}

.about-col .footer-logo img {
    height: 80px;
    filter: brightness(0) invert(1);
    margin-bottom: 20px;
}

.about-col p {
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

.links-col ul li {
    margin-bottom: 10px;
}

.links-col a {
    color: var(--color-text-muted);
    font-weight: 500;
    position: relative;
    padding-left: 15px;
}

.links-col a::before {
    content: '\f105';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    color: var(--color-primary);
    transition: left var(--transition-speed) ease;
}

.links-col a:hover {
    color: var(--color-heading);
}

.links-col a:hover::before {
    left: 3px;
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 15px;
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

.footer-contact i {
    color: var(--color-primary);
    font-size: 1rem;
    margin-right: 15px;
    width: 20px;
    text-align: center;
    margin-top: 4px;
}

.footer-bottom {
    border-top: 1px solid var(--color-border);
    padding: 30px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

.footer-legal-links a {
    color: var(--color-text-muted);
    margin-left: 20px;
    font-weight: 500;
}

.footer-legal-links a:hover {
    color: var(--color-heading);
}


/* 9. BUTTONS & FORMS (REVISED)
------------------------------------------------*/
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    /* Slightly adjusted padding */
    border: none;
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: linear-gradient(90deg, var(--color-gradient-start), var(--color-gradient-end));
    color: white;
    border-radius: 12px;
    /* Rounded corners like the image */
    box-shadow: 0 0 20px rgba(175, 77, 255, 0.4);
    /* Glow effect */
}

.btn-primary:hover {
    box-shadow: 0 0 30px rgba(175, 77, 255, 0.6);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
    border-radius: 12px;
}

.btn-secondary:hover {
    background: var(--color-primary);
    color: white;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 1rem;
}

.btn-block {
    width: 100%;
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: flex;
    gap: 20px;
}

.form-row .form-group {
    flex: 1;
}

input[type="text"],
input[type="email"],
textarea {
    width: 100%;
    padding: 15px;
    background: var(--color-surface-light);
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius);
    color: var(--color-text);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(138, 77, 255, 0.3);
}

textarea {
    resize: vertical;
}

::placeholder {
    color: var(--color-text-muted);
}


/* 10. HERO SECTION
------------------------------------------------*/
.hero-section {
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding: 60px 0;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(20, 20, 43, 0.8) 0%, var(--color-background) 70%);
    z-index: -1;
}

.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 900;
    margin-bottom: 20px;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--color-text-muted);
    max-width: 500px;
    margin-bottom: 40px;
}

.hero-cta {
    display: flex;
    gap: 20px;
}

.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 500px;
}

.hero-3d-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
    transform-style: preserve-3d;
    animation: rotate3d 30s infinite linear;
}

.hero-3d-element {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100px;
    height: 100px;
    background: rgba(138, 77, 255, 0.1);
    border: 1px solid var(--color-primary);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-origin: center;
    box-shadow: 0 0 20px rgba(138, 77, 255, 0.3), inset 0 0 10px rgba(138, 77, 255, 0.2);
}

.hero-3d-element i {
    font-size: 2.5rem;
    color: var(--color-primary);
    text-shadow: 0 0 10px var(--color-primary);
}

.hero-3d-element:nth-child(1) {
    transform: rotateY(0deg) translateZ(200px);
}

.hero-3d-element:nth-child(2) {
    transform: rotateY(120deg) translateZ(200px);
}

.hero-3d-element:nth-child(3) {
    transform: rotateY(240deg) translateZ(200px);
}


/* 11. SERVICES SECTION
------------------------------------------------*/
.services-section {
    background-color: var(--color-secondary);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: transparent;
    aspect-ratio: 1 / 1.1;
    perspective: 1000px;
}

.service-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.service-card:hover .service-card-inner {
    transform: rotateY(180deg);
}

.service-card-front,
.service-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 30px;
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    background: linear-gradient(145deg, var(--color-surface), var(--color-secondary));
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.service-card-back {
    transform: rotateY(180deg);
    justify-content: space-around;
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--color-primary);
}

.service-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
}

.service-card p {
    color: var(--color-text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

.btn-outline {
    background: transparent;
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
    padding: 8px 16px;
    font-size: 0.8rem;
    border-radius: 8px;
}

.btn-outline:hover {
    background-color: var(--color-primary);
    color: white;
}


/* 12. PROCESS SECTION (TIMELINE)
------------------------------------------------*/
.process-section {
    position: relative;
    overflow: hidden;
}

.process-timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.process-timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background: linear-gradient(to bottom, var(--color-gradient-start), var(--color-gradient-end));
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    z-index: -1;
    box-shadow: 0 0 15px var(--color-primary);
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-content {
    padding: 30px;
    background-color: var(--color-surface);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    position: relative;
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.timeline-item:hover .timeline-content {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(138, 77, 255, 0.3);
}

.timeline-content h3 {
    margin-bottom: 10px;
}

.timeline-content p {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin: 0;
}

.timeline-step {
    position: absolute;
    top: -25px;
    right: -25px;
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    border-radius: 50%;
    color: white;
    font-family: var(--font-heading);
    font-weight: 700;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    border: 4px solid var(--color-background);
}


/* 13. INDUSTRY EXPERTISE SECTION
------------------------------------------------*/
.industry-section {
    background-color: var(--color-secondary);
}

.industry-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.industry-item {
    background-color: var(--color-surface);
    padding: 40px;
    text-align: center;
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease, border-color var(--transition-speed) ease;
}

.industry-item:hover {
    transform: translateY(-10px);
    border-color: var(--color-primary);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.industry-item i {
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: 20px;
    display: block;
}

.industry-item h4 {
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.industry-item p {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    margin: 0;
}


/* 14. TESTIMONIALS SECTION
------------------------------------------------*/
.testimonial-slider-wrapper {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
}

.testimonial-slider {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.testimonial-card {
    flex: 0 0 100%;
    padding: 40px;
    text-align: center;
    background-color: var(--color-surface);
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
}

.testimonial-quote {
    font-size: 1.2rem;
    font-style: italic;
    color: var(--color-heading);
    margin-bottom: 30px;
    position: relative;
}

.testimonial-quote::before,
.testimonial-quote::after {
    font-family: var(--font-heading);
    color: var(--color-primary);
    font-size: 4rem;
    position: absolute;
    opacity: 0.3;
}

.testimonial-quote::before {
    content: '“';
    top: -20px;
    left: 0;
}

.testimonial-quote::after {
    content: '”';
    bottom: -40px;
    right: 0;
}

.testimonial-author {
    display: inline-flex;
    align-items: center;
    gap: 15px;
}

.author-info h4 {
    margin: 0;
    color: var(--color-heading);
}

.author-info span {
    color: var(--color-text-muted);
    font-size: 0.9rem;
}

.slider-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    left: 0;
    pointer-events: none;
}

.slider-btn {
    background-color: var(--color-primary);
    color: white;
    border: none;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: background-color var(--transition-speed) ease;
    pointer-events: all;
}

.slider-btn:hover {
    background-color: var(--color-primary-hover);
}


/* 15. CTA SECTION
------------------------------------------------*/
.cta-section {
    background: url('https://www.transparenttextures.com/patterns/cubes.png'), linear-gradient(45deg, var(--color-secondary), var(--color-surface));
    background-attachment: fixed;
}

.cta-content {
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.cta-text {
    color: var(--color-text-muted);
    margin-bottom: 40px;
}


/* 16. PAGE-SPECIFIC STYLES (CONTACT, LEGAL)
------------------------------------------------*/
.page-header-section {
    padding: 80px 0;
    text-align: center;
    background: linear-gradient(rgba(13, 13, 26, 0.8), rgba(13, 13, 26, 0.8)), url('https://www.transparenttextures.com/patterns/futuristic-armor.png');
    border-bottom: 1px solid var(--color-border);
}

.page-title {
    font-size: 3.5rem;
}

.page-subtitle {
    font-size: 1.2rem;
    color: var(--color-text-muted);
    max-width: 600px;
    margin: 10px auto 0;
}

/* Contact Page */
.contact-section-standalone {
    padding: 100px 0;
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 60px;
    background-color: var(--color-surface);
    padding: 50px;
    border-radius: var(--border-radius);
    border: 1px solid var(--color-border);
}

.contact-info .section-header {
    text-align: left;
    margin-bottom: 40px;
}

.contact-info .section-header .section-description {
    margin: 0;
    max-width: 100%;
}

.contact-details .contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.contact-icon {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    color: white;
    margin-right: 20px;
}

.contact-text h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.contact-text p {
    color: var(--color-text-muted);
    margin: 0;
}

/* Legal Pages */
.legal-content {
    padding: 80px 0;
    max-width: 800px;
    margin: 0 auto;
}

.legal-section {
    margin-bottom: 40px;
}

.legal-section h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--color-primary);
    padding-bottom: 10px;
    border-bottom: 1px solid var(--color-border);
}

.legal-section p {
    color: var(--color-text-muted);
    line-height: 1.8;
}

.legal-section strong {
    color: var(--color-heading);
}

/* 17. INTERACTIVE WIDGETS (POPUP, CHAT)
------------------------------------------------*/
/* 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 0.3s ease, visibility 0.3s ease;
}

.popup.show {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background-color: var(--color-surface);
    padding: 40px;
    border-radius: var(--border-radius);
    text-align: center;
    max-width: 450px;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.popup.show .popup-content {
    transform: scale(1);
}

.popup-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-text-muted);
}

.popup-icon {
    font-size: 4rem;
    color: var(--color-primary);
    margin-bottom: 20px;
}

.popup h3 {
    margin-bottom: 10px;
}

.popup p {
    color: var(--color-text-muted);
    margin-bottom: 30px;
}

/* Live Chat */
.chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 998;
}

.chat-bubble {
    width: 60px;
    height: 60px;
    background: linear-gradient(45deg, var(--color-gradient-start), var(--color-gradient-end));
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.8rem;
    color: white;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(138, 77, 255, 0.4);
    transition: transform 0.3s ease;
}

.chat-bubble:hover {
    transform: scale(1.1);
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 320px;
    background-color: var(--color-surface);
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--color-border);
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
}

.chat-window.open {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.chat-header {
    background-color: var(--color-surface-light);
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h4 {
    margin: 0;
}

.close-chat {
    background: none;
    border: none;
    color: var(--color-text);
    font-size: 1.5rem;
    cursor: pointer;
}

.chat-body {
    padding: 20px;
    font-size: 0.9rem;
    min-height: 100px;
}

.chat-footer {
    display: flex;
    border-top: 1px solid var(--color-border);
}

.chat-footer input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 15px;
    color: var(--color-text);
    outline: none;
}

.chat-footer button {
    background: transparent;
    border: none;
    color: var(--color-primary);
    padding: 0 15px;
    font-size: 1.2rem;
    cursor: pointer;
}


/* 18. ANIMATIONS & KEYFRAMES
------------------------------------------------*/
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

@keyframes loader-grid-animation {

    0%,
    70%,
    100% {
        transform: scale3D(1, 1, 1);
    }

    35% {
        transform: scale3D(0, 0, 1);
    }
}

@keyframes rotate3d {
    from {
        transform: rotateY(0deg);
    }

    to {
        transform: rotateY(360deg);
    }
}

/* Scroll Animations */
[data-animation] {
    opacity: 0;
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

[data-animation="fade-up"] {
    transform: translateY(50px);
}

[data-animation="fade-down"] {
    transform: translateY(-50px);
}

[data-animation="fade-right"] {
    transform: translateX(-50px);
}

[data-animation="fade-left"] {
    transform: translateX(50px);
}

[data-animation="zoom-in"] {
    transform: scale(0.9);
}

[data-animation].is-visible {
    opacity: 1;
    transform: translate(0, 0) scale(1);
}


/* 19. RESPONSIVE DESIGN (MEDIA QUERIES)
------------------------------------------------*/

/* Tablets and larger devices */
@media (max-width: 1024px) {
    .header-inner {
        padding: 0 20px;
    }

    .main-nav,
    .header-actions {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .hero-title {
        font-size: 3.5rem;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-subtitle {
        margin: 20px auto 40px;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-visual {
        height: 400px;
        margin-top: 40px;
    }

    .hero-3d-wrapper {
        width: 250px;
        height: 250px;
    }

    .hero-3d-element:nth-child(1) {
        transform: rotateY(0deg) translateZ(150px);
    }

    .hero-3d-element:nth-child(2) {
        transform: rotateY(120deg) translateZ(150px);
    }

    .hero-3d-element:nth-child(3) {
        transform: rotateY(240deg) translateZ(150px);
    }

    .process-timeline::after {
        left: 30px;
    }

    .timeline-item,
    .timeline-item:nth-child(even) {
        width: 100%;
        left: 0;
        padding-left: 80px;
        padding-right: 20px;
    }

    .industry-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-top {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-col {
        margin: 0 auto;
        max-width: 400px;
    }

    .footer-contact li {
        justify-content: center;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 15px;
    }
}

/* Mobile devices */
@media (max-width: 767px) {
    section {
        padding: 60px 0;
    }

    .section-title,
    .page-title {
        font-size: 2.2rem;
    }

    h1.hero-title {
        font-size: 2.5rem;
    }

    .hero-section {
        padding: 40px 0;
        min-height: auto;
    }

    .hero-visual {
        height: 300px;
    }

    .hero-3d-wrapper {
        width: 200px;
        height: 200px;
    }

    .hero-3d-element {
        width: 80px;
        height: 80px;
    }

    .hero-3d-element i {
        font-size: 2rem;
    }

    .hero-3d-element:nth-child(1) {
        transform: rotateY(0deg) translateZ(120px);
    }

    .hero-3d-element:nth-child(2) {
        transform: rotateY(120deg) translateZ(120px);
    }

    .hero-3d-element:nth-child(3) {
        transform: rotateY(240deg) translateZ(120px);
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .services-grid,
    .industry-grid {
        grid-template-columns: 1fr;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
        padding: 30px;
    }

    .form-row {
        flex-direction: column;
        gap: 0;
    }

    .slider-controls {
        display: none;
    }

    .chat-widget {
        bottom: 20px;
        right: 20px;
    }

    .chat-window {
        width: calc(100vw - 40px);
    }
}