/* Custom Styles for E Vision Infotech */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #4f46e5;
}

* {
    scroll-behavior: smooth;
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
}

html {
    scroll-behavior: smooth;
}

a, button {
    cursor: pointer;
}

img {
    max-width: 100%;
    height: auto;
}

/* Section Padding */
.section-padding {
    padding: 80px 0;
}

@media (max-width: 768px) {
    .section-padding {
        padding: 60px 0;
    }
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background-color: #2563eb;
    color: #fff;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
    border: none;
    font-size: 1rem;
}

.btn-primary:hover {
    background-color: #1d4ed8;
    color: #fff;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-primary-small {
    padding: 8px 16px;
    font-size: 0.875rem;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background-color: #fff;
    color: #2563eb;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 2px solid #2563eb;
    font-size: 1rem;
}

.btn-secondary:hover {
    background-color: #eff6ff;
    color: #1d4ed8;
    text-decoration: none;
}

.btn-secondary.bg-transparent {
    background-color: transparent;
    color: #fff;
    border-color: #fff;
}

.btn-secondary.bg-transparent:hover {
    background-color: rgba(255,255,255,0.1);
    color: #fff;
}

.btn-secondary.border-white {
    border-color: #fff;
}

/* Cards */
.card {
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.service-card {
    padding: 24px;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
    transition: all 0.3s ease;
    border: 1px solid #f3f4f6;
}

.service-card:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.pricing-card {
    padding: 24px;
    background-color: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.pricing-card:hover {
    border-color: #2563eb;
    transform: translateY(-4px);
}

.pricing-card.popular {
    border-color: #2563eb;
    position: relative;
}

.pricing-card.popular::before {
    content: 'Most Popular';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 12px;
    background-color: #2563eb;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 9999px;
}

/* Feature Icon */
.feature-icon {
    width: 56px;
    height: 56px;
    background-color: #dbeafe;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #2563eb;
    margin: 0 auto 16px;
}

/* Testimonial Card */
.testimonial-card {
    padding: 32px;
    background-color: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Badge */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.badge-blue {
    background-color: #dbeafe;
    color: #1e40af;
}

.badge-green {
    background-color: #dcfce7;
    color: #166534;
}

.badge-purple {
    background-color: #f3e8ff;
    color: #6b21a8;
}

/* Form Elements */
.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-slide-up {
    animation: slideUp 0.6s ease-out;
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Mobile Responsive Fixes */
@media (max-width: 768px) {
    .btn-primary,
    .btn-secondary {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .testimonial-card,
    .service-card,
    .pricing-card {
        padding: 20px;
    }
    
    .feature-icon {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
    }
}

/* ============================================
   MODERN ANIMATIONS SYSTEM
   ============================================ */

/* --- Page Load Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero Animation */
@keyframes heroFadeIn {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes heroSlideIn {
    0% {
        opacity: 0;
        transform: translateX(-30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Initial states */
.animate-on-load {
    opacity: 0;
}

.animate-on-load.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

.animate-on-load.fade-in-left {
    animation: fadeInLeft 0.6s ease-out forwards;
}

.animate-on-load.fade-in-right {
    animation: fadeInRight 0.6s ease-out forwards;
}

.animate-on-load.scale-in {
    animation: scaleIn 0.6s ease-out forwards;
}

/* Staggered delays */
.delay-1 { animation-delay: 0.1s !important; }
.delay-2 { animation-delay: 0.2s !important; }
.delay-3 { animation-delay: 0.3s !important; }
.delay-4 { animation-delay: 0.4s !important; }
.delay-5 { animation-delay: 0.5s !important; }
.delay-6 { animation-delay: 0.6s !important; }

/* --- Scroll Animations --- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    will-change: opacity, transform;
}

.animate-on-scroll.fade-in-up {
    transform: translateY(30px);
}

.animate-on-scroll.fade-in-left {
    transform: translateX(-30px);
}

.animate-on-scroll.fade-in-right {
    transform: translateX(30px);
}

.animate-on-scroll.scale-in {
    transform: scale(0.9);
}

.animate-on-scroll.zoom-in {
    transform: scale(0.9);
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translate(0) scale(1);
}

/* Scroll animation for hero */
.animate-hero {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s ease-out;
}

.animate-hero.visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Hover Effects --- */

/* Button hover - scale & shadow */
.btn-primary,
.btn-secondary {
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-primary:hover,
.btn-secondary:hover {
    transform: translateY(-2px);
}

.btn-primary:active,
.btn-secondary:active {
    transform: translateY(0) scale(0.98);
}

/* Card hover - lift & shadow */
.card,
.service-card,
.pricing-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover,
.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.12);
}

.card,
.service-card {
    will-change: transform, box-shadow;
}

/* Feature icon hover */
.feature-icon {
    transition: all 0.3s ease;
}

.feature-icon:hover {
    transform: scale(1.1);
}

/* Link hover - underline */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #2563eb;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 70%;
}

/* --- Micro-interactions --- */

/* Button click feedback */
button,
a.btn {
    position: relative;
    overflow: hidden;
}

button::after,
a.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
}

button:active::after,
a.btn:active::after {
    width: 200%;
    height: 200%;
}

/* Form input focus */
.form-input {
    transition: all 0.25s ease;
}

.form-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
    transform: translateY(-1px);
}

/* Navbar scroll effect */
.navbar {
    transition: all 0.3s ease;
}

.navbar.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* Logo hover */
.navbar-brand {
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.02);
}

/* Section title animation */
.section-title {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.section-title.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Card staggered entrance */
.stagger-card {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease-out;
}

.stagger-card.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Smooth reveal for sections */
.section-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s ease-out;
}

.section-reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Mobile fix for horizontal scroll */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden;
        max-width: 100vw;
    }
    .section-reveal {
        transform: none !important;
        opacity: 1 !important;
        transition: none !important;
    }
    .animate-on-scroll {
        transform: none !important;
        opacity: 1 !important;
        transition: none !important;
    }
    .stagger-card {
        opacity: 1 !important;
        transform: none !important;
    }
    .section-title {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* Optimized animations */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Hover lift effect */
.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

/* Testimonial card animation */
.testimonial-card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.testimonial-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Pricing card special hover */
.pricing-card.popular {
    transition: all 0.3s ease;
}

.pricing-card.popular:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(37, 99, 235, 0.2);
}

/* Hardware product card */
.hardware-card {
    transition: all 0.3s ease;
}

.hardware-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

/* Stat counter animation */
.stat-number {
    transition: all 0.3s ease;
}

.stat-number:hover {
    transform: scale(1.1);
}

/* Smooth scroll offset for fixed navbar */
html {
    scroll-padding-top: 80px;
}