@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@300;400;500;600;700;800;900&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #0ea5e9;
    --primary-light: #38bdf8;
    --primary-dark: #0284c7;
    --primary-glow: rgba(14, 165, 233, 0.4);
    --secondary: #6366f1;
    --dark: #020617;
    --dark-lighter: #0f172a;
    --light: #f8fafc;
    --glass: rgba(15, 23, 42, 0.6);
    --glass-border: rgba(255, 255, 255, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    overflow-x: hidden !important;
    position: relative;
    background-color: var(--dark);
    color: var(--light);
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    line-height: 1.6;
    scroll-behavior: smooth;
}

h1, h2, h3, h4, .font-heading {
    font-family: 'Outfit', sans-serif;
}

/* --- Smooth Scrolling --- */
html {
    scroll-behavior: smooth;
}

/* --- Hero Background Pattern --- */
.hero-gradient {
    background: radial-gradient(circle at 50% 50%, rgba(14, 165, 233, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(99, 102, 241, 0.1) 0%, transparent 40%);
}

/* --- Premium Glassmorphism --- */
.glass {
    background: var(--glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

/* --- Premium Header & Navigation --- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    background-color: var(--dark);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    display: flex;
    align-items: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-container {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
}

nav {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-list {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-item {
    position: relative;
}

.nav-link {
    text-decoration: none;
    color: #94a3b8;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding: 10px 0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link svg {
    width: 10px;
    height: 10px;
    transition: transform 0.3s ease;
    stroke-width: 3;
}

/* Dropdown Styling */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 260px;
    background-color: rgba(2, 6, 23, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    padding: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border: 1px solid var(--glass-border);
    z-index: 1001;
}

.nav-item:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-item:hover .nav-link svg {
    transform: rotate(180deg);
}

.dropdown-link {
    display: block;
    padding: 14px 20px;
    text-decoration: none;
    color: #94a3b8;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.dropdown-link:hover {
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--primary);
    padding-left: 25px;
}

/* Mobile Controls */
.mobile-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.hamburger-line {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--light);
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* Mobile Menu */
@media (max-width: 1024px) {
    .mobile-btn {
        display: block;
    }

    .nav-list {
        position: fixed;
        top: 0;
        right: -100%;
        width: 320px;
        height: 100vh;
        background-color: rgba(1, 4, 19, 0.98);
        backdrop-filter: blur(25px);
        -webkit-backdrop-filter: blur(25px);
        flex-direction: column;
        align-items: flex-start;
        padding: 100px 40px;
        gap: 10px;
        box-shadow: -20px 0 60px rgba(0, 0, 0, 0.8);
        transition: right 0.5s cubic-bezier(0.77, 0, 0.175, 1);
        border-left: 1px solid var(--glass-border);
        overflow-y: auto;
    }

    .nav-list.active {
        right: 0;
    }

    .nav-item {
        width: 100%;
    }

    .nav-link {
        width: 100%;
        padding: 15px 0;
        justify-content: space-between;
    }

    .dropdown {
        position: static;
        width: 100%;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease;
        background: transparent;
        border: none;
    }

    .dropdown.active {
        max-height: 500px;
        padding-top: 5px;
        margin-bottom: 10px;
    }

    .dropdown-link {
        padding-left: 15px;
        opacity: 0.7;
    }

    /* Hamburger Animation */
    .mobile-btn.active .hamburger-line:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }
    .mobile-btn.active .hamburger-line:nth-child(2) {
        opacity: 0;
    }
    .mobile-btn.active .hamburger-line:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }
}

/* --- Animated Borders --- */
.animated-border {
    position: relative;
}

.animated-border::before {
    content: '';
    position: absolute;
    inset: -2px;
    background: linear-gradient(45deg, var(--primary), var(--secondary), var(--primary));
    background-size: 200% 200%;
    z-index: -1;
    border-radius: inherit;
    animation: borderRotate 4s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.animated-border:hover::before {
    opacity: 1;
}

@keyframes borderRotate {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* --- Button Styling --- */
.btn-premium {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-premium::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300%;
    height: 300%;
    background: white;
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
    transform: translate(-50%, -50%) rotate(45deg) scale(0);
    z-index: -1;
    opacity: 0.1;
}

.btn-premium:hover::before {
    transform: translate(-50%, -50%) rotate(45deg) scale(1);
}

/* --- Card Hover Interactivity --- */
.service-card {
    transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.service-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: rgba(14, 165, 233, 0.4);
    background: rgba(30, 41, 59, 0.5);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(14, 165, 233, 0.1);
}

/* --- Reveal Animations --- */
.reveal {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
    transition: opacity 1s cubic-bezier(0.2, 0.8, 0.2, 1), 
                transform 1s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform, opacity;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: all 1s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

/* --- High Impact Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes pulse-slow {
    0%, 100% { opacity: 0.15; transform: scale(1.1); }
    50% { opacity: 0.25; transform: scale(1.15); }
}

.animate-pulse-slow {
    animation: pulse-slow 8s ease-in-out infinite;
}

@keyframes background-animate {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.background-animate {
    background-size: 200% 200%;
    animation: background-animate 5s ease infinite;
}

@keyframes bounce-slow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.animate-bounce-slow {
    animation: bounce-slow 4s ease-in-out infinite;
}

/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--dark);
}

::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* --- Mobile Navigation --- */
@media (max-width: 768px) {
    .mobile-menu-active {
        overflow: hidden;
    }
    
    #navContent.mobile-active {
        display: block !important;
        position: fixed;
        inset: 0;
        background: rgba(2, 6, 23, 0.98);
        backdrop-filter: blur(25px);
        -webkit-backdrop-filter: blur(25px);
        z-index: 100;
        overflow-y: auto;
        padding: 5rem 1.5rem 2rem 1.5rem;
    }

    #navContent.mobile-active .flex-col {
        margin-left: 0 !important;
        align-items: flex-start !important;
        width: 100%;
        gap: 0.5rem !important;
    }
    
    #navContent.mobile-active a {
        font-size: 0.8rem !important;
        text-transform: uppercase;
        letter-spacing: 0.15em;
        width: 100%;
        text-align: left;
        padding: 0.6rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }
    
    .mobile-services-list {
        padding-left: 1.5rem;
        width: 100%;
        display: none;
    }
    
    .mobile-services-list.active {
        display: block;
    }
    
    .mobile-services-list a {
        font-size: 0.75rem !important;
        opacity: 0.7;
        border-bottom: none !important;
    }
}

/* --- Social Icons --- */
.social-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    color: #94a3b8;
}

.social-icon:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(14, 165, 233, 0.3);
}

.nav-link-hover {
    position: relative;
    padding: 0.5rem 0;
}

.nav-link-hover::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1.5px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-link-hover:hover::after {
    width: 100%;
}

/* --- Responsive Layout Fixes --- */
@media (max-width: 768px) {
    .hero-gradient h1 {
        font-size: 3rem !important;
        line-height: 1.2 !important;
    }
    
    .stats-section {
        margin-top: 4rem !important;
        gap: 2rem !important;
    }
    
    .service-card {
        padding: 2rem !important;
    }
}

@media (max-width: 640px) {
    footer .grid {
        grid-template-columns: 1fr !important;
        text-align: center;
    }

    footer .flex.justify-between {
        flex-direction: column;
        gap: 1.5rem;
    }
}

.blob {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    filter: blur(60px);
    z-index: -1;
    pointer-events: none;
    animation: move 20s infinite alternate;
}

@keyframes move {
    0% { transform: translate(-10%, -10%); }
    100% { transform: translate(10%, 10%); }
}

/* --- GLOBAL HERO DARK FILTER OVERLAY --- */
section > div.absolute.inset-0.z-0::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(1, 4, 19, 0.75), rgba(0, 0, 0, 0.9));
    z-index: 25;
    pointer-events: none;
}

section > div.relative.z-10 {
    z-index: 30 !important;
}

section > div.relative.z-30 {
    z-index: 40 !important;
}

/* --- ENHANCED HOVER EFFECTS & UI/UX --- */
.group.relative:hover, .glass:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(14, 165, 233, 0.6);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 30px rgba(14, 165, 233, 0.2) !important;
}

.btn-premium:hover {
    box-shadow: 0 0 45px rgba(14, 165, 233, 0.7) !important;
    transform: translateY(-4px) scale(1.05) !important;
}

/* Enhanced Gradient Animation */
.background-animate {
    background-size: 300% 300% !important;
    animation: text-gradient-bg 4s ease infinite alternate !important;
}
@keyframes text-gradient-bg {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
