/* Custom styles for Gigi's Coffee Shop */

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

/* Custom selection color */
::selection {
    background-color: #7B3F6C;
    color: #FDF8F0;
}

/* Navbar scroll state */
nav.scrolled {
    background-color: rgba(253, 248, 240, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(107, 47, 91, 0.08);
}

nav.scrolled .nav-link {
    color: #4A1F40;
}

/* Hero scroll indicator animation */
@keyframes scrollBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

/* Fade-in on scroll (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .fade-up {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    }
    
    .fade-up.visible {
        opacity: 1;
        transform: translateY(0);
    }
    
    .fade-up.delay-1 { transition-delay: 0.1s; }
    .fade-up.delay-2 { transition-delay: 0.2s; }
    .fade-up.delay-3 { transition-delay: 0.3s; }
    .fade-up.delay-4 { transition-delay: 0.4s; }
}

/* Image hover effects */
img {
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Button focus states */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #7B3F6C;
    outline-offset: 2px;
    border-radius: 0.5rem;
}

/* Form input focus */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(123, 63, 108, 0.15);
}

/* Menu item hover */
.bg-plum-800\/50:hover {
    background-color: rgba(74, 31, 64, 0.6);
    border-color: rgba(155, 77, 138, 0.3);
}

/* Mobile menu transitions */
#mobileMenu {
    transition: opacity 0.3s ease, pointer-events 0.3s ease;
}

#mobileMenu.open {
    opacity: 1;
    pointer-events: auto;
}

/* Subtle grain texture overlay on hero */
#hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    opacity: 0.4;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #FDF8F0;
}
::-webkit-scrollbar-thumb {
    background: #D69BC8;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #C072B0;
}

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

/* Mobile menu backdrop */
#mobileMenu::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(253, 248, 240, 0.98);
    z-index: -1;
}
