/* Base styles and variables */
:root {
    --primary: #6C3BFF;
    --primary-gradient: linear-gradient(135deg, #6C3BFF, #9F6BFF);
    --dark: #0A0A12;
    --dark-surface: #151525;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: var(--dark);
    color: rgba(255, 255, 255, 0.9);
}

/* Mesh Background */
.mesh-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-color: var(--dark);
    background-image:
        radial-gradient(at 0% 0%, hsla(253, 100%, 20%, 0.4) 0, transparent 60%),
        radial-gradient(at 50% 0%, hsla(225, 100%, 15%, 0.3) 0, transparent 60%),
        radial-gradient(at 100% 0%, hsla(270, 100%, 25%, 0.4) 0, transparent 60%),
        radial-gradient(at 50% 50%, hsla(253, 100%, 10%, 0.2) 0, transparent 60%),
        radial-gradient(at 0% 100%, hsla(253, 100%, 20%, 0.3) 0, transparent 60%),
        radial-gradient(at 100% 100%, hsla(225, 100%, 15%, 0.3) 0, transparent 60%);
    filter: blur(60px);
}

.bg-grid {
    background-image: radial-gradient(rgba(108, 59, 255, 0.15) 1px, transparent 1px);
    background-size: 40px 40px;
}

.bg-dots {
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 20px 20px;
}

/* Custom Components */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    background: var(--primary-gradient);
    color: white;
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 14px 0 rgba(108, 59, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(108, 59, 255, 0.5);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    transform: translateY(-2px);
}

/* Glassmorphism utils */
.glass-panel {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
}

@media (max-width: 768px) {
    .glass-panel {
        padding: 1.5rem !important;
        border-radius: 1.5rem !important;
    }
}

/* Service Cards */
.service-card {
    background: rgba(255, 255, 255, 0.02);
    padding: 2.5rem;
    border-radius: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 768px) {
    .service-card {
        padding: 1.5rem !important;
        border-radius: 1.5rem !important;
    }
}

.service-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(108, 59, 255, 0.4);
    box-shadow: 0 20px 60px -10px rgba(0, 0, 0, 0.6);
    transform: translateY(-10px);
}

.service-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1rem;
    background: rgba(108, 59, 255, 0.1);
    color: #6C3BFF;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    background: var(--primary-gradient);
    color: white;
    transform: scale(1.1) rotate(5deg);
}

.service-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: #FFFFFF;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.service-desc {
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.7;
}

/* Section Headings */
.section-subtitle {
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.2em;
    color: #6C3BFF;
    text-transform: uppercase;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.section-subtitle::before {
    content: '';
    display: block;
    width: 1.5rem;
    height: 2px;
    background: #6C3BFF;
    border-radius: 2px;
}

.section-title {
    font-size: 2rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    color: #FFFFFF;
    margin-bottom: 2rem;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

@media (min-width: 768px) {
    .section-title {
        font-size: 2.75rem;
    }
}

@media (min-width: 1024px) {
    .section-title {
        font-size: 3.5rem;
    }
}

/* Animations */
@keyframes blob {
    0% {
        transform: translate(0px, 0px) scale(1);
    }

    33% {
        transform: translate(30px, -50px) scale(1.1);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }

    100% {
        transform: translate(0px, 0px) scale(1);
    }
}

.animate-blob {
    animation: blob 7s infinite alternate;
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0px);
    }
}

.tech-float {
    animation: float 6s ease-in-out infinite;
}

/* Reveal Animations */
.reveal-element {
    transition: all 1s cubic-bezier(0.2, 0.8, 0.2, 1);
    opacity: 0;
    transform: translateY(30px);
}

.reveal-element.active {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

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

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

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

.reveal-right.active {
    opacity: 1 !important;
    transform: translateX(0) !important;
}

/* Glow Pulse Animation */
@keyframes glow-pulse {
    0% {
        filter: drop-shadow(0 0 5px rgba(108, 59, 255, 0.2));
    }

    50% {
        filter: drop-shadow(0 0 20px rgba(108, 59, 255, 0.5));
    }

    100% {
        filter: drop-shadow(0 0 5px rgba(108, 59, 255, 0.2));
    }
}

.animate-glow {
    animation: glow-pulse 3s infinite ease-in-out;
}

.hover-glow:hover {
    filter: drop-shadow(0 0 15px rgba(108, 59, 255, 0.4));
}

.glow-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 0;
    pointer-events: none;
    opacity: 0.15;
    animation: blob 10s infinite alternate;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0.5;
    animation: bounce 2s infinite;
}

/* Sticky Navbar Styles */
#navbar {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#navbar.scrolled {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

/* Tech Line Decorations */
.tech-line {
    position: absolute;
    background: linear-gradient(90deg, transparent, rgba(108, 59, 255, 0.2), transparent);
    height: 1px;
    width: 100%;
    z-index: 0;
}

.tech-line-v {
    position: absolute;
    background: linear-gradient(180deg, transparent, rgba(108, 59, 255, 0.2), transparent);
    width: 1px;
    height: 100%;
    z-index: 0;
}

.code-decoration {
    font-family: 'Courier New', Courier, monospace;
    font-size: 10px;
    color: rgba(108, 59, 255, 0.1);
    white-space: pre;
    pointer-events: none;
    user-select: none;
    position: absolute;
    z-index: 0;
}

#navbar.scrolled .container {
    background: rgba(10, 10, 18, 0.8) !important;
    backdrop-filter: blur(16px) !important;
    border-color: rgba(108, 59, 255, 0.2);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
}

.nav-link {
    font-size: 0.875rem;
    letter-spacing: 0.02em;
    font-weight: 600;
}

.hover-underline {
    position: relative;
}

.hover-underline::after {
    content: '';
    position: absolute;
    width: 100%;
    transform: scaleX(0);
    height: 2px;
    bottom: -4px;
    left: 0;
    background: var(--primary-gradient);
    transform-origin: bottom right;
    transition: transform 0.25s ease-out;
}

.hover-underline:hover::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}