/* ==========================================================================
   GLOBAL VARIABLES & RESET
   ========================================================================== */
:root {
    --bg-base: #030305;
    --bg-surface: #0a0a0f;
    --bg-surface-light: rgba(25, 25, 35, 0.6);
    --text-main: #ffffff;
    --text-muted: #a0a0b0;
    --accent-blue: #00f0ff;
    --accent-purple: #7000ff;
    --accent-glow: rgba(0, 240, 255, 0.2);
    --border-color: rgba(255, 255, 255, 0.08);
    --font-heading: 'Syncopate', sans-serif;
    --font-body: 'Inter', sans-serif;
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    background-color: var(--bg-base);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-smooth);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* ==========================================================================
   TYPOGRAPHY
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 4rem;
}

/* ==========================================================================
   HEADER & NAVIGATION (EXACT MATCH FOR ALL PAGES)
   ========================================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 5%;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition-smooth);
    background: transparent;
    border-bottom: 1px solid transparent;
}

.site-header.scrolled {
    background: rgba(3, 3, 5, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 5%;
}

.logo-container img {
    height: 55px;
    filter: invert(1);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links li a {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    padding: 0.5rem 0;
}

.nav-links li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-purple));
    transition: var(--transition-smooth);
}

.nav-links li a:hover::after {
    width: 100%;
}

.btn-primary {
    background: linear-gradient(45deg, var(--accent-blue), var(--accent-purple));
    color: #fff;
    padding: 0.8rem 2rem;
    border-radius: 30px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(45deg, var(--accent-purple), var(--accent-blue));
    opacity: 0;
    z-index: -1;
    transition: var(--transition-smooth);
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary:hover {
    box-shadow: 0 0 20px var(--accent-glow);
    transform: translateY(-2px);
}

.mobile-menu-btn {
    display: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ==========================================================================
   HERO SECTION (3D & PARTICLES)
   ========================================================================== */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 0 5%;
    overflow: hidden;
    perspective: 1000px;
}

.hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at center, rgba(112, 0, 255, 0.15) 0%, var(--bg-base) 70%);
    z-index: -2;
}

.hero-3d-element {
    position: absolute;
    width: 600px;
    height: 600px;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%) rotateX(60deg) rotateY(20deg);
    animation: rotate3D 20s linear infinite;
    z-index: -1;
    box-shadow: inset 0 0 50px var(--accent-glow);
}

.hero-3d-element::before {
    content: '';
    position: absolute;
    width: 100%; height: 100%;
    border: 1px dashed var(--accent-blue);
    border-radius: 50%;
    transform: scale(1.2) rotateZ(45deg);
}

.hero-content {
    text-align: center;
    max-width: 900px;
    z-index: 2;
    transform: translateZ(50px);
}

.hero-title {
    font-size: clamp(3rem, 8vw, 6rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    text-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.hero-desc {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* ==========================================================================
   SERVICES SECTION (3D TILT CARDS)
   ========================================================================== */
.services-section {
    padding: 8rem 5%;
    position: relative;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 3rem 2rem;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.1s ease, box-shadow 0.3s ease;
    backdrop-filter: blur(10px);
}

.service-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px var(--accent-glow);
    border-color: rgba(0, 240, 255, 0.3);
}

.service-icon {
    font-size: 3rem;
    color: var(--accent-blue);
    margin-bottom: 1.5rem;
    transform: translateZ(30px);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    transform: translateZ(20px);
}

.service-card p {
    color: var(--text-muted);
    transform: translateZ(10px);
}

/* ==========================================================================
   CAMPAIGN REPORTS (CSS DRAWN CHARTS)
   ========================================================================== */
.reports-section {
    padding: 8rem 5%;
    background: linear-gradient(180deg, var(--bg-base) 0%, var(--bg-surface) 100%);
}

.chart-container {
    background: rgba(25, 25, 35, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 3rem;
    display: flex;
    align-items: flex-end;
    gap: 2%;
    height: 400px;
    position: relative;
}

.chart-bar {
    flex: 1;
    background: linear-gradient(180deg, var(--accent-purple), var(--accent-blue));
    border-radius: 10px 10px 0 0;
    position: relative;
    height: 0; /* Animated via JS */
    transition: height 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.chart-bar::after {
    content: attr(data-value);
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.9rem;
    font-weight: bold;
    opacity: 0;
    transition: opacity 0.5s 1.5s;
}

.chart-container.active .chart-bar::after {
    opacity: 1;
}

.chart-grid-lines {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 3rem 0;
    pointer-events: none;
}

.chart-grid-line {
    width: 100%;
    height: 1px;
    background: var(--border-color);
}

/* ==========================================================================
   SERVICE CALCULATOR (INTERACTIVE)
   ========================================================================== */
.calculator-section {
    padding: 8rem 5%;
}

.calc-wrapper {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 4rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.range-slider {
    width: 100%;
    -webkit-appearance: none;
    background: var(--border-color);
    height: 6px;
    border-radius: 3px;
    outline: none;
    margin: 2rem 0;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: var(--accent-blue);
    cursor: pointer;
    box-shadow: 0 0 15px var(--accent-glow);
}

.calc-result {
    text-align: center;
    padding: 3rem;
    background: rgba(0, 240, 255, 0.05);
    border: 1px solid var(--accent-blue);
    border-radius: 20px;
}

.calc-result h4 {
    font-size: 1.2rem;
    color: var(--text-muted);
}

.calc-result .est-roi {
    font-size: 4rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 20px var(--accent-glow);
    margin: 1rem 0;
}

/* ==========================================================================
   INDUSTRIES (TABS INTERACTION)
   ========================================================================== */
.industries-section {
    padding: 8rem 5%;
    background: var(--bg-surface);
}

.tabs-header {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
    overflow-x: auto;
    padding-bottom: 1rem;
}

.tab-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-main);
    padding: 1rem 2rem;
    border-radius: 30px;
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition-smooth);
}

.tab-btn.active, .tab-btn:hover {
    background: var(--accent-blue);
    color: #000;
    border-color: var(--accent-blue);
}

.tab-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.tab-content.active {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.tab-img {
    width: 100%;
    height: 400px;
    background: linear-gradient(45deg, rgba(0,240,255,0.1), rgba(112,0,255,0.1));
    border: 1px solid var(--border-color);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

/* ==========================================================================
   TESTIMONIALS
   ========================================================================== */
.testimonials-section {
    padding: 8rem 5%;
}

.testi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.testi-card {
    background: var(--bg-surface);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    position: relative;
}

.testi-card::before {
    content: '\"';
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 6rem;
    color: rgba(255,255,255,0.05);
    font-family: serif;
}

.client-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

.client-avatar {
    width: 50px;
    height: 50px;
    background: var(--border-color);
    border-radius: 50%;
}

/* ==========================================================================
   CONTACT FORM / QUOTE
   ========================================================================== */
.contact-section {
    padding: 8rem 5%;
    background: var(--bg-surface);
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h3 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.contact-details {
    margin-top: 3rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.form-group {
    margin-bottom: 1.5rem;
    position: relative;
}

.form-control {
    width: 100%;
    padding: 1.2rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: #fff;
    font-size: 1rem;
    outline: none;
    transition: var(--transition-smooth);
}

.form-control:focus {
    border-color: var(--accent-blue);
    background: rgba(0, 240, 255, 0.05);
}

textarea.form-control {
    height: 150px;
    resize: none;
}

/* ==========================================================================
   LIVE CHAT SUPPORT WIDGET
   ========================================================================== */
.chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--accent-blue), var(--accent-purple));
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 30px var(--accent-glow);
    font-size: 1.5rem;
    transition: transform 0.3s;
}

.chat-toggle:hover {
    transform: scale(1.1);
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    transform: scale(0);
    transform-origin: bottom right;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.chat-window.open {
    transform: scale(1);
}

.chat-header {
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-purple));
    padding: 1.2rem;
    color: #fff;
    font-weight: bold;
}

.chat-body {
    height: 300px;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.chat-msg {
    max-width: 80%;
    padding: 1rem;
    border-radius: 15px;
    font-size: 0.9rem;
}

.chat-msg.bot {
    background: rgba(255,255,255,0.05);
    align-self: flex-start;
    border-bottom-left-radius: 0;
}

.chat-input {
    display: flex;
    border-top: 1px solid var(--border-color);
    padding: 1rem;
}

.chat-input input {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    outline: none;
}

.chat-input button {
    background: transparent;
    border: none;
    color: var(--accent-blue);
    cursor: pointer;
    font-weight: bold;
}

/* ==========================================================================
   LEGAL PAGES SPECIFIC
   ========================================================================== */
.legal-page {
    padding: 12rem 5% 6rem;
    max-width: 900px;
    margin: 0 auto;
}

.legal-content h1 {
    font-size: 3rem;
    margin-bottom: 2rem;
    color: var(--accent-blue);
}

.legal-content h2 {
    font-size: 1.5rem;
    margin: 2rem 0 1rem;
    color: var(--accent-purple);
}

.legal-content p {
    margin-bottom: 1.2rem;
    color: var(--text-muted);
}

.legal-content ul {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
    list-style: disc;
    color: var(--text-muted);
}

/* ==========================================================================
   FOOTER (EXACT MATCH FOR ALL PAGES)
   ========================================================================== */
.site-footer {
    background: var(--bg-base);
    border-top: 1px solid var(--border-color);
    padding: 6rem 5% 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-brand img {
    height: 55px;
    filter: invert(1);
    margin-bottom: 1.5rem;
}

.footer-desc {
    color: var(--text-muted);
    max-width: 300px;
}

.footer-heading {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    color: #fff;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--text-muted);
}

.footer-links a:hover {
    color: var(--accent-blue);
    padding-left: 5px;
}

.footer-contact p {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.legal-links {
    display: flex;
    gap: 1.5rem;
}

/* ==========================================================================
   ANIMATIONS & KEYFRAMES
   ========================================================================== */
@keyframes rotate3D {
    0% { transform: translate(-50%, -50%) rotateX(60deg) rotateY(0deg) rotateZ(0deg); }
    100% { transform: translate(-50%, -50%) rotateX(60deg) rotateY(360deg) rotateZ(360deg); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   MEDIA QUERIES
   ========================================================================== */
@media (max-width: 1024px) {
    .calc-wrapper { grid-template-columns: 1fr; }
    .contact-container { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0; right: -100%;
        width: 100%; height: 100vh;
        background: rgba(3, 3, 5, 0.98);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: var(--transition-smooth);
    }
    .nav-links.nav-active { right: 0; }
    .mobile-menu-btn { display: block; z-index: 1001; }
    .footer-grid { grid-template-columns: 1fr; }
    .chart-container { height: 300px; }
    .tab-content.active { grid-template-columns: 1fr; }
}