/* Custom styles for Axra Tutor website */

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

/* Custom 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);
    }
}

/* Animation classes */
.animate-fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

.animate-fade-in-left {
    animation: fadeInLeft 0.6s ease-out;
}

.animate-fade-in-right {
    animation: fadeInRight 0.6s ease-out;
}

/* Hover effects for cards */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Custom button styles */
.btn-primary {
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(30, 58, 138, 0.4);
}

.btn-secondary {
    background: linear-gradient(135deg, #047857 0%, #10b981 100%);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(4, 120, 87, 0.4);
}

/* Premium gradient backgrounds */
.premium-gradient {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
}

.premium-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(124, 58, 237, 0.4);
}

/* Glass morphism effect */
.glass-effect {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Professional card hover effects */
.professional-card {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.professional-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Floating WhatsApp Animation */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-6px); }
    100% { transform: translateY(0px); }
}

.floating-whatsapp {
    animation: float 3s ease-in-out infinite;
}

/* Enhanced mobile responsiveness */
@media (max-width: 768px) {
    .hero-bg {
        background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    }
    
    .service-card {
        padding: 1.5rem;
    }
    
    .location-card {
        padding: 1rem;
    }
}

/* Navigation active state */
.nav-link.active {
    color: #1e40af !important;
    font-weight: 600;
}

/* Hero section background */
.hero-bg {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0e7ff 100%);
}

/* Testimonials carousel */
.testimonials-container {
    max-height: 400px;
}

/* Modal backdrop */
.modal-backdrop {
    backdrop-filter: blur(4px);
}

/* Form validation styles */
.form-error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.form-success {
    border-color: #10b981 !important;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1) !important;
}

/* Loading spinner */
.spinner {
    border: 2px solid #f3f4f6;
    border-top: 2px solid #1e40af;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive image optimizations */
img {
    max-width: 100%;
    height: auto;
    loading: lazy;
}

/* Focus states for accessibility */
button:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #1e40af;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .bg-gray-50 {
        background-color: #ffffff !important;
    }
    
    .text-gray-600 {
        color: #000000 !important;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* Dark mode support (future enhancement) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles can be added here if needed */
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Selection styles */
::selection {
    background-color: #1e40af;
    color: white;
}

::-moz-selection {
    background-color: #1e40af;
    color: white;
}

/* Utility classes */
.text-shadow {
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.box-shadow-soft {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.transition-all {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Mobile-specific optimizations */
@media (max-width: 768px) {
    .hero-text {
        font-size: 2.5rem;
        line-height: 1.2;
    }
    
    .mobile-padding {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .mobile-text-center {
        text-align: center;
    }
}

/* Tablet-specific optimizations */
@media (min-width: 768px) and (max-width: 1024px) {
    .tablet-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large screen optimizations */
@media (min-width: 1280px) {
    .max-width-content {
        max-width: 1200px;
    }
}

/* Performance optimizations */
.will-change-transform {
    will-change: transform;
}

.gpu-accelerated {
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Intersection observer animations */
.fade-in-section {
    opacity: 0;
    transform: translateY(20px);
    visibility: hidden;
    transition: opacity 0.6s ease-out, transform 0.6s ease-out, visibility 0.6s ease-out;
}

.fade-in-section.is-visible {
    opacity: 1;
    transform: none;
    visibility: visible;
    /* background-color: black; */
}

/* WhatsApp button pulse animation */
.whatsapp-pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Error and success states */
.error-message {
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.success-message {
    color: #10b981;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

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

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f4f6;
    border-top-color: #1e40af;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
