/* Custom styles for Nails by Jessica Brown */

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

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #719e71;
}

/* Section eyebrow */
.section-eyebrow {
    display: block;
    margin-bottom: 0.75rem;
}

.section-eyebrow-light {
    display: block;
    margin-bottom: 0.75rem;
}

/* Service card hover effects */
.service-card {
    will-change: transform;
}

/* Gallery item hover */
.gallery-item {
    cursor: pointer;
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(45, 65, 41, 0);
    transition: background 0.3s ease;
    border-radius: inherit;
}

.gallery-item:hover::after {
    background: rgba(45, 65, 41, 0.2);
}

/* Testimonial card hover */
.testimonial-card {
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-family: 'Playfair Display', serif;
    font-size: 6rem;
    color: #e3ede3;
    line-height: 1;
    z-index: 0;
}

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

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

/* Navigation active state */
.nav-link-active {
    color: #4f7d4f;
}

/* Mobile menu animation */
#mobileMenu {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#mobileMenu.hidden {
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
}

#mobileMenu:not(.hidden) {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}

/* Navbar transition */
#navbar {
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

#navbar.scrolled {
    background-color: rgba(250, 248, 245, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

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

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

/* Stagger delays for grid items */
.scroll-reveal:nth-child(1) { transition-delay: 0.05s; }
.scroll-reveal:nth-child(2) { transition-delay: 0.1s; }
.scroll-reveal:nth-child(3) { transition-delay: 0.15s; }
.scroll-reveal:nth-child(4) { transition-delay: 0.2s; }
.scroll-reveal:nth-child(5) { transition-delay: 0.25s; }
.scroll-reveal:nth-child(6) { transition-delay: 0.3s; }

/* Form styles */
input:focus,
textarea:focus {
    outline: none;
    border-color: #4f7d4f;
    box-shadow: 0 0 0 3px rgba(79, 125, 79, 0.1);
}

/* Success message */
.success-message {
    animation: fadeInUp 0.5s ease forwards;
}

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

/* Loading state */
.btn-loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Image loading placeholder */
img {
    background: linear-gradient(90deg, #e3ede3 25%, #f2f7f2 50%, #e3ede3 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

img[src] {
    animation: none;
    background: none;
}
