/* AutoSolutions.ai Custom Styles */

/* Root Variables */
:root {
    --brand-primary: #fa50cb;
    --brand-dark: #e63eb7;
    --brand-light: #fc78d6;
    --gradient-brand: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-light) 100%);
    --gradient-brand-reverse: linear-gradient(135deg, var(--brand-light) 0%, var(--brand-primary) 100%);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background: #000000;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Custom Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(250, 80, 203, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(250, 80, 203, 0.6);
    }
}

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

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Utility Classes */
.animate-float {
    animation: float 6s ease-in-out infinite;
}

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

.gradient-text {
    background: var(--gradient-brand);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gradient-border {
    position: relative;
    background: transparent;
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 2px;
    background: var(--gradient-brand);
    border-radius: inherit;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    -webkit-mask-composite: xor;
}

/* Navigation Enhancements */
nav {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.3s ease;
}

nav.scrolled {
    background: rgba(0, 0, 0, 0.95);
    border-bottom: 1px solid rgba(250, 80, 203, 0.3);
}

/* Hero Section Enhancements */
#home {
    position: relative;
    background: radial-gradient(circle at 50% 50%, rgba(250, 80, 203, 0.1) 0%, transparent 50%);
}

#home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(250, 80, 203, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(252, 120, 214, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(250, 80, 203, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.hero-bg-element {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.6;
    animation: float 8s ease-in-out infinite;
}

.hero-bg-element:nth-child(1) {
    top: 10%;
    left: 10%;
    width: 300px;
    height: 300px;
    background: rgba(250, 80, 203, 0.2);
    animation-delay: 0s;
}

.hero-bg-element:nth-child(2) {
    top: 60%;
    right: 10%;
    width: 400px;
    height: 400px;
    background: rgba(252, 120, 214, 0.15);
    animation-delay: 2s;
}

.hero-bg-element:nth-child(3) {
    bottom: 20%;
    left: 30%;
    width: 250px;
    height: 250px;
    background: rgba(250, 80, 203, 0.25);
    animation-delay: 4s;
}

/* Button Enhancements */
.btn-primary {
    background: var(--gradient-brand);
    border: none;
    padding: 16px 32px;
    border-radius: 50px;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(250, 80, 203, 0.4);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--brand-primary);
    padding: 14px 30px;
    border-radius: 50px;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--gradient-brand);
    transition: left 0.3s ease;
    z-index: -1;
}

.btn-secondary:hover::before {
    left: 0;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    border-color: var(--brand-light);
}

/* Card Enhancements */
.service-card {
    background: rgba(17, 24, 39, 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(250, 80, 203, 0.2);
    border-radius: 20px;
    padding: 32px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(250, 80, 203, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.service-card:hover::before {
    opacity: 1;
}

.service-card:hover {
    transform: translateY(-8px);
    border-color: rgba(250, 80, 203, 0.5);
    background: rgba(17, 24, 39, 0.7);
    box-shadow: 0 20px 60px rgba(250, 80, 203, 0.2);
}

.service-icon {
    width: 64px;
    height: 64px;
    background: var(--gradient-brand);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 10px 30px rgba(250, 80, 203, 0.4);
}

/* Form Enhancements */
.form-input {
    background: rgba(31, 41, 55, 0.5);
    border: 1px solid rgba(250, 80, 203, 0.2);
    border-radius: 12px;
    padding: 16px;
    color: white;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-input:focus {
    border-color: var(--brand-primary);
    outline: none;
    box-shadow: 0 0 20px rgba(250, 80, 203, 0.3);
    background: rgba(31, 41, 55, 0.7);
}

.form-input::placeholder {
    color: rgba(156, 163, 175, 0.7);
}

/* Technology Grid */
.tech-item {
    background: rgba(17, 24, 39, 0.3);
    border: 1px solid rgba(250, 80, 203, 0.1);
    border-radius: 16px;
    padding: 24px;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.tech-item:hover {
    border-color: rgba(250, 80, 203, 0.3);
    background: rgba(17, 24, 39, 0.5);
    transform: translateY(-4px);
}

.tech-item i {
    font-size: 3rem;
    color: var(--brand-primary);
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.tech-item:hover i {
    transform: scale(1.2);
    color: var(--brand-light);
}

/* About Section */
.about-image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
}

.about-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(45deg, rgba(250, 80, 203, 0.2) 0%, transparent 50%);
    pointer-events: none;
}

.floating-badge {
    position: absolute;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(250, 80, 203, 0.3);
    border-radius: 50%;
    padding: 16px;
    animation: float 6s ease-in-out infinite;
}

.floating-badge:first-child {
    animation-delay: 0s;
}

.floating-badge:last-child {
    animation-delay: 3s;
}

/* Testimonials Carousel */
.testimonials-container {
    position: relative;
}

.testimonials-track {
    width: 100%;
}

.testimonial-slide {
    transition: opacity 0.3s ease;
}

.testimonial-indicator {
    cursor: pointer;
}

.testimonial-indicator.active {
    background-color: var(--brand-primary);
    transform: scale(1.2);
}

.testimonial-indicator:hover {
    background-color: var(--brand-light);
    transform: scale(1.1);
}

/* Testimonial Card Animations */
.testimonial-slide .bg-gray-900\/50 {
    position: relative;
    overflow: hidden;
}

.testimonial-slide .bg-gray-900\/50::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, transparent, rgba(250, 80, 203, 0.2), transparent);
    z-index: -1;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.testimonial-slide .bg-gray-900\/50:hover::before {
    opacity: 1;
}

/* Responsive testimonials */
@media (max-width: 768px) {
    .testimonials-track {
        flex-direction: column;
    }
    
    .testimonial-slide {
        width: 100% !important;
        margin-bottom: 2rem;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .testimonial-slide {
        width: 50% !important;
    }
}

/* Auto-scroll animation */
.testimonials-auto-scroll {
    animation: testimonialScroll 20s linear infinite;
}

@keyframes testimonialScroll {
    0% { transform: translateX(0); }
    25% { transform: translateX(-33.333%); }
    50% { transform: translateX(-66.666%); }
    75% { transform: translateX(-33.333%); }
    100% { transform: translateX(0); }
}

/* Pause animation on hover */
.testimonials-container:hover .testimonials-auto-scroll {
    animation-play-state: paused;
}

/* Chatbot Styles */
#chatbot-container {
    font-family: 'Inter', sans-serif;
}

#chatbot-toggle {
    position: relative;
    overflow: hidden;
}

#chatbot-toggle::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, var(--brand-primary), var(--brand-light), var(--brand-primary));
    animation: gradient-shift 3s linear infinite;
    z-index: -1;
}

#chatbot-toggle::after {
    content: '';
    position: absolute;
    inset: 2px;
    background: var(--gradient-brand);
    border-radius: 50%;
    z-index: -1;
}

#chatbot-window {
    background: rgba(17, 24, 39, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(250, 80, 203, 0.3);
}

.chat-message {
    animation: slideInUp 0.3s ease-out;
}

.chat-message.user {
    animation: slideInDown 0.3s ease-out;
}

.typing-indicator {
    display: flex;
    align-items: center;
    space: 4px;
}

.typing-dot {
    width: 8px;
    height: 8px;
    background: var(--brand-primary);
    border-radius: 50%;
    animation: typing 1.5s ease-in-out infinite;
}

.typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

/* Scroll Animations */
.scroll-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.scroll-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Loading States */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(250, 80, 203, 0.2), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-bg-element {
        display: none;
    }
    
    .service-card {
        padding: 24px;
    }
    
    #chatbot-window {
        width: 90vw;
        right: 5vw;
        left: 5vw;
    }
    
    .floating-badge {
        display: none;
    }
}

@media (max-width: 480px) {
    .btn-primary,
    .btn-secondary {
        width: 100%;
        text-align: center;
    }
    
    .service-icon {
        width: 48px;
        height: 48px;
    }
    
    .tech-item i {
        font-size: 2rem;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .service-card {
        border-width: 2px;
    }
    
    .form-input {
        border-width: 2px;
    }
    
    .tech-item {
        border-width: 2px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hero-bg-element,
    .floating-badge {
        animation: none;
    }
}

/* Dark mode optimizations */
@media (prefers-color-scheme: dark) {
    body {
        color: #f9fafb;
    }
    
    .service-card {
        background: rgba(17, 24, 39, 0.6);
    }
    
    .form-input {
        background: rgba(31, 41, 55, 0.6);
    }
}

/* Print styles */
@media print {
    #chatbot-container,
    nav,
    footer {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .gradient-text {
        color: var(--brand-primary) !important;
        -webkit-text-fill-color: var(--brand-primary) !important;
    }
}