/* Custom styles for Caluja Tax Service */

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

/* Scroll reveal animations */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll-reveal hidden state — only applied via JS for progressive enhancement */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal[data-reveal] {
        opacity: 0;
        transform: translateY(30px);
    }
}

/* Navbar scroll state */
#navbar.scrolled {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #0f766e;
}

/* Selection color */
::selection {
    background: #0d9488;
    color: white;
}

/* Hero text animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#hero .animate-fade-in-up {
    animation: fadeInUp 0.8s ease forwards;
}

#hero .animate-fade-in-up:nth-child(2) {
    animation-delay: 0.2s;
}

#hero .animate-fade-in-up:nth-child(3) {
    animation-delay: 0.4s;
}

/* Pulse animation for trust indicator */
@keyframes soft-pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: soft-pulse 2s ease-in-out infinite;
}

/* Button hover effect */
button[type="submit"]:active {
    transform: scale(0.98);
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

/* Mobile menu transition */
#mobile-menu {
    animation: slideDown 0.3s ease;
}

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

#mobile-menu.closing {
    animation: slideUp 0.2s ease forwards;
}

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

/* Service card hover image */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* Reduce motion preference */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .scroll-reveal[data-reveal] {
        opacity: 1;
        transform: none;
    }
    
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
