/* Custom styles for Hazel's Gourmet Coffee and Tea */

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

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

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

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

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

/* Navigation styles */
.nav-link {
    position: relative;
}

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

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

/* Active navigation state */
.nav-link.active {
    color: #1A4D52;
}

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

/* Navbar scroll state */
.navbar-scrolled {
    background-color: rgba(245, 242, 235, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}

/* Reveal on scroll animation */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* Staggered animation delays */
.reveal-on-scroll:nth-child(1) { transition-delay: 0.1s; }
.reveal-on-scroll:nth-child(2) { transition-delay: 0.2s; }
.reveal-on-scroll:nth-child(3) { transition-delay: 0.3s; }
.reveal-on-scroll:nth-child(4) { transition-delay: 0.4s; }

/* Hero section animations */
.hero-title,
.hero-subtitle,
.hero-description,
.hero-cta {
    opacity: 0;
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.hero-subtitle {
    animation: fadeInUp 0.8s ease-out 0.2s forwards;
}

.hero-title {
    animation: fadeInUp 0.8s ease-out 0.4s forwards;
}

.hero-description {
    animation: fadeInUp 0.8s ease-out 0.6s forwards;
}

.hero-cta {
    animation: fadeInUp 0.8s ease-out 0.8s forwards;
}

/* Image hover effects */
img {
    transition: transform 0.5s ease;
}

/* Button hover effects */
a {
    transition: all 0.3s ease;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #C5A059;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobile-menu.open {
    max-height: 400px;
}

/* Responsive typography adjustments */
@media (max-width: 768px) {
    .font-serif {
        line-height: 1.2;
    }
}

/* Print styles */
@media print {
    .reveal-on-scroll {
        opacity: 1;
        transform: none;
    }
    
    nav, footer {
        display: none;
    }
}

/* Reduced motion preference */
@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;
    }
}
