/*
  Digital Marketing Agency CSS
  Author: AI Assistant
  Version: 1.0
*/

/* ---------------------------------- */
/* 1. Global Styles & Variables       */
/* ---------------------------------- */
:root {
    --primary-color: #1A0F0F;
    /* Deep Burgundy Black - For backgrounds */
    --secondary-color: #2C1A1A;
    /* Dark Wine - For cards/sections */
    --accent-color: #E63946;
    /* Crimson Red - For CTAs and highlights */
    --accent-hover-color: #C71F37;
    /* Darker Crimson */
    --text-color: #F3E9E9;
    /* Warm Off-White - For main text */
    --heading-color: #FFFFFF;
    /* Bright White - For headings */
    --border-color: #4A2B2B;
    /* Subtle Wine Border */
    --font-primary: 'Poppins', sans-serif;
    --header-height: 80px;
}


/* Import Poppins font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-primary);
    background-color: var(--primary-color);
    color: var(--text-color);
    line-height: 1.7;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--heading-color);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3.5rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    max-width: 70ch;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--accent-hover-color);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

section {
    padding: 80px 0;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.text-center {
    text-align: center;
}

.section-title {
    margin-bottom: 4rem;
}

.section-title h2 {
    margin-bottom: 0.5rem;
}

.section-title p {
    font-size: 1.1rem;
    color: var(--text-color);
    margin-left: auto;
    margin-right: auto;
}

/* ---------------------------------- */
/* 2. Buttons & Forms                 */
/* ---------------------------------- */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 50px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--accent-color);
    color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--accent-hover-color);
    color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(20, 184, 166, 0.2);
}

.btn-secondary {
    background-color: transparent;
    color: var(--heading-color);
    border-color: var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--accent-color);
    color: var(--primary-color);
    border-color: var(--accent-color);
}

.btn-tertiary {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-tertiary:hover {
    background: var(--accent-color);
    color: var(--primary-color);
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.1rem;
}

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    background-color: var(--secondary-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--heading-color);
    font-family: var(--font-primary);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.3);
}


/* ---------------------------------- */
/* 3. Header & Navigation             */
/* ---------------------------------- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0 20px;
    height: var(--header-height);
    display: flex;
    align-items: center;
    background-color: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo a {
    display: block;
}

.logo img {
    height: 50px;
    filter: brightness(0) invert(1);
    width: auto;
}

.main-nav ul {
    display: flex;
    gap: 2rem;
}

.main-nav a {
    color: var(--text-color);
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.main-nav a:hover::after,
.main-nav a.active::after {
    width: 100%;
}

.main-nav a.active,
.main-nav a:hover {
    color: var(--heading-color);
}

.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.hamburger {
    display: block;
    position: relative;
    width: 25px;
    height: 2px;
    background-color: var(--heading-color);
    transition: all 0.3s ease;
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 25px;
    height: 2px;
    background-color: var(--heading-color);
    transition: all 0.3s ease;
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    bottom: -8px;
}

/* ---------------------------------- */
/* 4. Footer                          */
/* ---------------------------------- */
.site-footer {
    background-color: var(--secondary-color);
    padding: 60px 0 20px;
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-column h4 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--heading-color);
}

.footer-column.about .footer-logo img {
    height: 50px;
    filter: brightness(0) invert(1);
    margin-bottom: 1rem;
}

.footer-column ul li {
    margin-bottom: 0.75rem;
}

.footer-column ul li a {
    color: var(--text-color);
}

.footer-column ul li a:hover {
    padding-left: 5px;
}

.footer-column.contact p {
    margin-bottom: 0.75rem;
}

.footer-column.contact a {
    color: var(--text-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    font-size: 0.9rem;
    color: var(--text-color);
}


/* ---------------------------------- */
/* 5. Hero Section                    */
/* ---------------------------------- */
.hero-section {
    padding: 180px 0 120px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-section .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.hero-content {
    max-width: 600px;
}

.hero-content h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    background: -webkit-linear-gradient(45deg, #fff, var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-3d-element-container {
    perspective: 1000px;
}

.hero-3d-element {
    width: 250px;
    height: 250px;
    position: relative;
    transform-style: preserve-3d;
    animation: rotate-cube 20s infinite linear;
}

.hero-3d-element .face {
    position: absolute;
    width: 250px;
    height: 250px;
    background: rgba(20, 184, 166, 0.1);
    border: 1px solid var(--accent-color);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 5rem;
    color: var(--accent-color);
}

.face.front {
    transform: rotateY(0deg) translateZ(125px);
}

.face.back {
    transform: rotateY(180deg) translateZ(125px);
}

.face.left {
    transform: rotateY(-90deg) translateZ(125px);
}

.face.right {
    transform: rotateY(90deg) translateZ(125px);
}

.face.top {
    transform: rotateX(90deg) translateZ(125px);
}

.face.bottom {
    transform: rotateX(-90deg) translateZ(125px);
}

@keyframes rotate-cube {
    0% {
        transform: rotateX(0) rotateY(0);
    }

    100% {
        transform: rotateX(360deg) rotateY(360deg);
    }
}

.hero-bg-shapes .shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(20, 184, 166, 0.1);
    filter: blur(100px);
}

.shape-1 {
    width: 400px;
    height: 400px;
    top: -100px;
    left: -100px;
}

.shape-2 {
    width: 300px;
    height: 300px;
    bottom: -50px;
    right: -50px;
}

.shape-3 {
    width: 200px;
    height: 200px;
    top: 50%;
    right: 20%;
}


/* ---------------------------------- */
/* 6. Services Section                */
/* ---------------------------------- */
.services-section {
    background-color: var(--secondary-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.service-card {
    background-color: transparent;
    perspective: 1000px;
    height: 350px;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.service-card:hover .card-inner {
    transform: rotateY(180deg);
}

.card-front,
.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;
    padding: 2rem;
    border-radius: 12px;
    background-color: var(--primary-color);
    border: 1px solid var(--border-color);
}

.card-back {
    transform: rotateY(180deg);
    background-color: #2a3a55;
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.service-card h3 {
    margin-bottom: 1rem;
}

.card-back ul {
    text-align: left;
    margin-bottom: 1.5rem;
    width: 100%;
}

.card-back ul li {
    margin-bottom: 0.5rem;
    padding-left: 20px;
    position: relative;
}

.card-back ul li::before {
    content: '✓';
    color: var(--accent-color);
    position: absolute;
    left: 0;
}

/* ---------------------------------- */
/* 7. Process Section                 */
/* ---------------------------------- */
.process-timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.process-timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--border-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

.process-step {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
    margin-bottom: 2rem;
}

.process-step:nth-child(odd) {
    left: 0;
    text-align: right;
}

.process-step:nth-child(even) {
    left: 50%;
}

.process-step::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 25px;
    right: -15px;
    background-color: var(--primary-color);
    border: 4px solid var(--accent-color);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
}

.process-step:nth-child(even)::after {
    left: -11px;
}

.step-number {
    position: absolute;
    font-size: 3rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.1);
    z-index: -1;
}

.process-step:nth-child(odd) .step-number {
    right: 40px;
    top: -10px;
}

.process-step:nth-child(even) .step-number {
    left: 40px;
    top: -10px;
}

.step-content {
    padding: 20px 30px;
    background-color: var(--secondary-color);
    position: relative;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

/* ---------------------------------- */
/* 8. Industries Section              */
/* ---------------------------------- */
.industries-section {
    background-color: var(--secondary-color);
}

.industries-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem;
}

.industry-item {
    background: var(--primary-color);
    padding: 2rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

.industry-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
    border-color: var(--accent-color);
}

.industry-item .icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* ---------------------------------- */
/* 9. Testimonials Section            */
/* ---------------------------------- */
.testimonial-slider-container {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.testimonial-slider {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.testimonial-slide {
    min-width: 100%;
    padding: 2.5rem;
    background-color: var(--secondary-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    text-align: center;
}

.testimonial-slide p {
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 1.5rem;
    max-width: 60ch;
    margin-left: auto;
    margin-right: auto;
}

.testimonial-slide p::before {
    content: '“';
    font-size: 4rem;
    color: var(--accent-color);
    line-height: 0;
    position: relative;
    top: 20px;
    left: -10px;
}

.testimonial-author h4 {
    margin: 0;
    color: var(--heading-color);
}

.testimonial-author span {
    color: var(--accent-color);
    font-size: 0.9rem;
}

.slider-controls {
    text-align: center;
    margin-top: 2rem;
}

.slider-controls button {
    background: var(--secondary-color);
    border: 1px solid var(--border-color);
    color: var(--heading-color);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    margin: 0 10px;
    transition: all 0.3s;
}

.slider-controls button:hover {
    background: var(--accent-color);
    color: var(--primary-color);
}


/* ---------------------------------- */
/* 10. Calculator Section             */
/* ---------------------------------- */
.calculator-section {
    background-color: var(--secondary-color);
}

.calculator-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    background: var(--primary-color);
    padding: 4rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.calculator-content h2 {
    color: var(--accent-color);
}

.roi-results {
    margin-top: 2rem;
    background: var(--secondary-color);
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--accent-color);
    display: none;
    /* Initially hidden */
}

.roi-results.show {
    display: block;
}

.roi-results p {
    margin-bottom: 0.5rem;
}

.roi-results .roi-highlight {
    font-size: 1.2rem;
    font-weight: 600;
    margin-top: 1rem;
}

.roi-highlight span {
    color: var(--accent-color);
}

/* ---------------------------------- */
/* 11. CTA Section                    */
/* ---------------------------------- */
.cta-section {
    background-color: var(--primary-color);
    background-image:
        radial-gradient(circle at 10% 20%, rgba(20, 184, 166, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 80% 90%, rgba(20, 184, 166, 0.15) 0%, transparent 40%);
}

.cta-section h2 {
    font-size: 2.8rem;
}

.cta-section p {
    max-width: 600px;
    margin: 1rem auto 2rem;
}


/* ---------------------------------- */
/* 12. Contact Page                   */
/* ---------------------------------- */
.page-hero {
    padding-top: 160px;
    padding-bottom: 60px;
    background-color: var(--secondary-color);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    margin-top: 3rem;
}

.contact-form-container,
.contact-info-container {
    background: var(--primary-color);
    padding: 2.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.contact-info-container h2,
.contact-form-container h2 {
    margin-top: 0;
}

.contact-details li {
    display: flex;
    margin-bottom: 1.5rem;
}

.contact-details li strong {
    flex-shrink: 0;
    width: 80px;
}

.map-placeholder {
    height: 200px;
    background: var(--secondary-color);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 8px;
    margin-top: 2rem;
}

/* ---------------------------------- */
/* 13. Legal Pages                    */
/* ---------------------------------- */
.legal-page-section {
    padding-top: 160px;
    padding-bottom: 80px;
}

.legal-page-section .container {
    max-width: 800px;
}

.legal-page-section h1 {
    margin-bottom: 2rem;
    font-size: 2.8rem;
}

.legal-page-section h2 {
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-size: 1.8rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
}

.legal-page-section p,
.legal-page-section ul {
    margin-bottom: 1.5rem;
}

.legal-page-section ul {
    list-style: disc;
    padding-left: 25px;
}


/* ---------------------------------- */
/* 14. Live Chat Widget               */
/* ---------------------------------- */
.live-chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
}

.chat-button {
    width: 60px;
    height: 60px;
    background-color: var(--accent-color);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(20, 184, 166, 0.3);
    transition: transform 0.3s;
}

.chat-button:hover {
    transform: scale(1.1);
}

.chat-button svg {
    width: 32px;
    height: 32px;
    color: var(--primary-color);
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    background: var(--secondary-color);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: translateY(20px) scale(0.9);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.live-chat-widget.open .chat-window {
    transform: translateY(0) scale(1);
    opacity: 1;
    visibility: visible;
}

.chat-header {
    padding: 1rem;
    background: var(--primary-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h3 {
    margin: 0;
    font-size: 1.1rem;
}

.close-chat {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.5rem;
    cursor: pointer;
}

.chat-body {
    padding: 1.5rem;
    flex-grow: 1;
    height: 200px;
}

.chat-footer {
    padding: 1rem;
    display: flex;
    border-top: 1px solid var(--border-color);
}

.chat-footer input {
    flex-grow: 1;
    border: none;
    background: var(--primary-color);
    padding: 10px;
    border-radius: 20px;
    color: var(--text-color);
}

.chat-footer input:focus {
    outline: none;
}

.chat-footer button {
    background: var(--accent-color);
    border: none;
    color: var(--primary-color);
    padding: 0 15px;
    border-radius: 20px;
    margin-left: 10px;
    cursor: pointer;
}

/* ---------------------------------- */
/* 15. 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="slide-in-left"] {
    transform: translateX(-50px);
}

[data-animation="slide-in-right"] {
    transform: translateX(50px);
}

[data-animation="zoom-in"] {
    transform: scale(0.9);
}

.in-view {
    opacity: 1;
    transform: none;
}


/* ---------------------------------- */
/* 16. Responsiveness                 */
/* ---------------------------------- */

/* Tablet */
@media (max-width: 992px) {
    h1 {
        font-size: 2.8rem;
    }

    h2 {
        font-size: 2rem;
    }

    .hero-section .container {
        flex-direction: column;
        text-align: center;
    }

    .hero-content {
        order: 2;
    }

    .hero-3d-element-container {
        order: 1;
        margin-bottom: 3rem;
    }

    .hero-3d-element,
    .hero-3d-element .face {
        width: 200px;
        height: 200px;
    }

    .face.front {
        transform: rotateY(0deg) translateZ(100px);
    }

    .face.back {
        transform: rotateY(180deg) translateZ(100px);
    }

    .face.left {
        transform: rotateY(-90deg) translateZ(100px);
    }

    .face.right {
        transform: rotateY(90deg) translateZ(100px);
    }

    .face.top {
        transform: rotateX(90deg) translateZ(100px);
    }

    .face.bottom {
        transform: rotateX(-90deg) translateZ(100px);
    }

    .hero-buttons {
        justify-content: center;
    }

    .process-timeline::after {
        left: 31px;
    }

    .process-step {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    .process-step:nth-child(odd) {
        left: 0;
        text-align: left;
    }

    .process-step:nth-child(even) {
        left: 0;
    }

    .process-step::after {
        left: 17px;
    }

    .process-step:nth-child(odd) .step-number {
        left: 70px;
        right: auto;
    }

    .calculator-wrapper {
        grid-template-columns: 1fr;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .header-cta {
        display: none;
    }

    .mobile-nav-toggle {
        display: block;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: 0;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: var(--secondary-color);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transform: translateX(100%);
        transition: transform 0.4s ease-in-out;
    }

    .main-nav.open {
        transform: translateX(0);
    }

    .main-nav ul {
        flex-direction: column;
        text-align: center;
        gap: 2.5rem;
    }

    .main-nav a {
        font-size: 1.2rem;
    }

    .mobile-nav-toggle.open .hamburger {
        background-color: transparent;
    }

    .mobile-nav-toggle.open .hamburger::before {
        transform: rotate(45deg);
        top: 0;
    }

    .mobile-nav-toggle.open .hamburger::after {
        transform: rotate(-45deg);
        bottom: 0;
    }

    h1 {
        font-size: 2.2rem;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    section {
        padding: 60px 0;
    }

    .hero-section {
        padding: 140px 0 80px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-column.about .footer-logo {
        margin: 0 auto;
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
    }

    .chat-window {
        width: calc(100vw - 40px);
    }
}