/* Custom Styles for Qamaria Yemeni Coffee Co. */

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

/* Custom Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

@keyframes slideLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

/* Animation Classes */
.animate-fade-in {
    animation: fadeIn 1s ease-out forwards;
}

.animate-fade-in-delay {
    animation: fadeIn 1s ease-out 0.3s forwards;
    opacity: 0;
}

.animate-slide-up {
    animation: slideUp 0.8s ease-out forwards;
}

.animate-fade-in-up-delay {
    animation: slideUp 0.8s ease-out 0.6s forwards;
    opacity: 0;
}

/* Reveal Animations (Progressive Enhancement) */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-up {
        animation: slideUp 0.8s ease-out forwards;
    }
    
    .reveal-left {
        animation: slideLeft 0.8s ease-out forwards;
    }
    
    .reveal-right {
        animation: slideRight 0.8s ease-out forwards;
    }
    
    .reveal-up.hidden,
    .reveal-left.hidden,
    .reveal-right.hidden {
        opacity: 0;
    }
    
    .reveal-up.hidden {
        transform: translateY(30px);
    }
    
    .reveal-left.hidden {
        transform: translateX(-30px);
    }
    
    .reveal-right.hidden {
        transform: translateX(30px);
    }
}

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

#navbar.scrolled .font-serif {
    color: #1e293b;
}

/* Mobile Menu Transitions */
#mobile-menu {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-menu.open {
    transform: translateX(0);
}

/* Hover Effects */
a {
    transition: all 0.3s ease;
}

/* Selection Color */
::selection {
    background-color: #115e59;
    color: white;
}

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

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

::-webkit-scrollbar-thumb {
    background: #115e59;
    border-radius: 4px;
}

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

/* Image Optimization */
img {
    max-width: 100%;
    height: auto;
}

/* Focus Styles for Accessibility */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #14b8a6;
    outline-offset: 2px;
}

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

/* Print Styles */
@media print {
    #navbar,
    #mobile-menu,
    footer {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
