/* Custom styles for Óptica Salobreña */

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

/* Floating animation for stat cards */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
}

@keyframes float-delayed2 {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

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

.animate-float-delayed {
    animation: float-delayed 3.5s ease-in-out infinite;
    animation-delay: 0.5s;
}

.animate-float-delayed2 {
    animation: float-delayed2 4s ease-in-out infinite;
    animation-delay: 1s;
}

/* Navbar scroll effect */
nav.scrolled {
    background: rgba(254, 253, 248, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 30px rgba(6, 95, 70, 0.1);
}

/* Service card hover */
.service-card {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.service-card:hover {
    box-shadow: 0 20px 60px rgba(6, 95, 70, 0.2);
}

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

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

/* Scroll reveal animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Input focus styles */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

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

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

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

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

/* Nav link underline animation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #065f46;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Active section highlight */
.nav-link.active::after {
    width: 100%;
}
