/* Custom Tailwind Configuration */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* Base Styles */
* {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    overflow-x: hidden; /* Prevent horizontal scrolling on body */
}

html {
    overflow-x: hidden; /* Prevent horizontal scrolling on html */
}

/* Custom Glassmorphism Card */
.glass-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 25px 45px rgba(0, 0, 0, 0.1);
}

/* Enhanced glassmorphism for product and service cards */
.product-card, .service-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.product-card:hover, .service-card:hover {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.15);
    transform: translateY(-5px);
}

/* Testimonial cards with glassmorphism */
.testimonial-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.12);
    transform: translateY(-3px);
}

/* Enhanced client logo hover effects */
.client-logo:hover {
    transform: translateY(-5px) scale(1.05);
    filter: grayscale(0%) brightness(1.1);
}

/* Navbar Glassmorphism Effect */
#navbar {
    transition: all 0.3s ease;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* Floating Shapes Animation */
.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.shape {
    position: absolute;
    opacity: 0.1;
    animation: float 20s infinite linear;
}

.shape-1 {
    top: 10%;
    left: 10%;
    width: 80px;
    height: 80px;
    background: linear-gradient(45deg, #3b82f6, #06b6d4);
    border-radius: 50%;
    animation-delay: 0s;
}

.shape-2 {
    top: 70%;
    left: 80%;
    width: 120px;
    height: 120px;
    background: linear-gradient(45deg, #06b6d4, #10b981);
    border-radius: 30%;
    animation-delay: 5s;
}

.shape-3 {
    top: 40%;
    left: 70%;
    width: 60px;
    height: 60px;
    background: linear-gradient(45deg, #8b5cf6, #3b82f6);
    border-radius: 50%;
    animation-delay: 10s;
}

.shape-4 {
    top: 20%;
    left: 60%;
    width: 100px;
    height: 100px;
    background: linear-gradient(45deg, #f59e0b, #ef4444);
    border-radius: 25%;
    animation-delay: 15s;
}

@keyframes float {
    0% {
        transform: translateY(0px) rotate(0deg);
    }
    33% {
        transform: translateY(-20px) rotate(120deg);
    }
    66% {
        transform: translateY(10px) rotate(240deg);
    }
    100% {
        transform: translateY(0px) rotate(360deg);
    }
}

/* Hero Section Animations */
.hero-content {
    animation: fadeInUp 1s ease-out 0.5s forwards;
}

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

/* CTA Button Animations */
.cta-button {
    position: relative;
    overflow: hidden;
}

.cta-button::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 ease;
}

.cta-button:hover::before {
    left: 100%;
}

/* Service Card Hover Effects */
.service-card {
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

/* Product Card Animations */
.product-card {
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Testimonial Card Effects */
.testimonial-card {
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* Stats Animation */
.stat-number {
    transition: all 0.3s ease;
}

/* Career Banner Animation */
.career-banner {
    position: relative;
    overflow: hidden;
}

.career-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 20px 20px;
    animation: moveBackground 20s linear infinite;
    opacity: 0.3;
}

@keyframes moveBackground {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(20px, 20px);
    }
}

/* Social Links Hover Effect */
.social-link {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.social-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.3s ease;
}

.social-link:hover::before {
    left: 100%;
}

/* Client Logo Hover Effects */
.client-logo {
    transition: all 0.3s ease;
}

.client-logo:hover {
    transform: scale(1.05);
}

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

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.6s ease;
}

.slide-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.6s ease;
}

.slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Mobile Navigation */
.mobile-menu {
    transition: all 0.3s ease;
}

.mobile-menu.active {
    display: block;
}

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

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Responsive Utilities */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
        line-height: 1.2;
    }
    
    .floating-shapes .shape {
        display: none;
    }
    
    .service-card,
    .product-card,
    .testimonial-card {
        margin-bottom: 1rem;
    }
}

@media (max-width: 640px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .cta-button,
    .cta-button-secondary {
        width: 100%;
        text-align: center;
    }
    
    .glass-card {
        padding: 1.5rem;
    }
}

/* Print Styles */
@media print {
    .floating-shapes,
    nav,
    .cta-button,
    .social-link {
        display: none;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: black;
        page-break-after: avoid;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .glass-card {
        background: rgba(255, 255, 255, 0.95);
        border: 2px solid #000;
    }
    
    .text-gray-600 {
        color: #000;
    }
    
    .text-gray-400 {
        color: #333;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .floating-shapes {
        display: none;
    }
}

/* Focus Indicators */
.nav-link:focus,
.cta-button:focus,
.cta-button-secondary:focus,
.social-link:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Custom CSS Animations for Performance */
.will-change-transform {
    will-change: transform;
}

.will-change-opacity {
    will-change: opacity;
}

/* Gradient Text Effects */
.gradient-text {
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Mobile slider enhancements */
@media (max-width: 1023px) {
    .overflow-x-auto {
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE 10+ */
    }
    
    .overflow-x-auto::-webkit-scrollbar {
        display: none; /* WebKit */
    }
    
    /* Mobile card sizing - ensure proper width for single card display */
    .mobile-card {
        width: calc(100vw - 80px); /* Full viewport width minus padding */
        max-width: 360px; /* Max width for better readability */
        min-width: 300px; /* Minimum width for very small screens */
        margin-left: auto;
        margin-right: auto;
    }
    
    /* Ensure slider container allows proper centering */
    #services-slider .flex,
    #products-slider .flex {
        padding-left: max(1rem, calc((100vw - 360px) / 2));
    }
    
    /* Add subtle scroll hints */
    .overflow-x-auto {
        position: relative;
    }
    
    .overflow-x-auto::after {
        content: '';
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 20px;
        background: linear-gradient(to left, rgba(255,255,255,0.9), transparent);
        pointer-events: none;
        z-index: 10;
    }
}

/* Slider arrows and navigation */
@media (max-width: 1023px) {
    /* Arrow buttons */
    .services-arrow, .products-arrow {
        transition: all 0.2s ease;
        cursor: pointer;
        backdrop-filter: blur(8px);
        min-width: 44px; /* Minimum touch target size */
        min-height: 44px;
        border: 2px solid rgba(255, 255, 255, 0.3);
    }
    
    .services-arrow:hover, .products-arrow:hover {
        transform: scale(1.05);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        border-color: rgba(255, 255, 255, 0.5);
    }
    
    .services-arrow:active, .products-arrow:active {
        transform: scale(0.95);
        background: rgba(255, 255, 255, 1);
    }
    
    /* Dot indicators */
    .services-dot, .products-dot {
        cursor: pointer;
        min-width: 20px;
        min-height: 20px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
    }
    
    .services-dot:hover, .products-dot:hover {
        transform: scale(1.3);
    }
    
    .services-dot:active, .products-dot:active {
        transform: scale(0.9);
    }
    
    /* Add touch feedback */
    .services-dot::after, .products-dot::after {
        content: '';
        position: absolute;
        width: 30px;
        height: 30px;
        border-radius: 50%;
        background: transparent;
        border: 2px solid transparent;
        transition: all 0.2s ease;
    }
    
    .services-dot:active::after, .products-dot:active::after {
        border-color: rgba(59, 130, 246, 0.3);
        background: rgba(59, 130, 246, 0.1);
    }
}

/* Single card view for very small screens */
@media (max-width: 480px) {
    .mobile-card {
        width: calc(100vw - 80px); /* Adjust for smaller screens */
        max-width: none;
        min-width: calc(100vw - 80px);
    }
    
    /* Adjust arrow position for smaller screens */
    .services-arrow-left, .products-arrow-left {
        left: 8px;
    }
    
    .services-arrow-right, .products-arrow-right {
        right: 8px;
    }
}

/* Medium mobile screens optimization */
@media (min-width: 481px) and (max-width: 640px) {
    .mobile-card {
        width: calc(100vw - 100px);
        max-width: 340px;
    }
}

/* Large mobile screens optimization */
@media (min-width: 641px) and (max-width: 767px) {
    .mobile-card {
        width: calc(100vw - 120px);
        max-width: 380px;
    }
}

/* Tablet optimization */
@media (min-width: 768px) and (max-width: 1023px) {
    .mobile-card {
        width: 400px;
        max-width: 400px;
    }
}

/* Ensure smooth transitions on all devices */
.product-card, .service-card {
    will-change: transform, box-shadow;
}

/* Icon loading enhancement */
.fas, .fab {
    font-display: swap;
}

/* Ensure icons are visible while loading */
i[class*="fa-"]:before {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands", serif;
    font-weight: 900;
}
