/* ========================================
   BayMarket Sales — Custom Styles
   ======================================== */

/* Base styles & smooth scrolling */
html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Selection color */
::selection {
    background-color: #C4704B;
    color: #ffffff;
}

/* ========================================
   Navbar scroll state
   ======================================== */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1.5px;
    background-color: #C4704B;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

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

/* ========================================
   Hero animations
   ======================================== */
.hero-content {
    animation: heroFadeUp 1s ease forwards;
}

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

/* ========================================
   Scroll reveal animations
   ======================================== */
.reveal-up {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-left {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-right {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* These are applied by JS for progressive enhancement */
.reveal-up.animated {
    opacity: 0;
    transform: translateY(40px);
}

.reveal-left.animated {
    opacity: 0;
    transform: translateX(-40px);
}

.reveal-right.animated {
    opacity: 0;
    transform: translateX(40px);
}

/* ========================================
   Mobile menu
   ======================================== */
.mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

.mobile-menu-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.mobile-menu.open .mobile-menu-link {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu.open .mobile-menu-link:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu.open .mobile-menu-link:nth-child(2) { transition-delay: 0.15s; }
.mobile-menu.open .mobile-menu-link:nth-child(3) { transition-delay: 0.2s; }
.mobile-menu.open .mobile-menu-link:nth-child(4) { transition-delay: 0.25s; }
.mobile-menu.open .mobile-menu-link:nth-child(5) { transition-delay: 0.3s; }

/* ========================================
   Product card hover effects
   ======================================== */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

/* ========================================
   Button ripple effect (subtle)
   ======================================== */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* ========================================
   Input focus animations
   ======================================== */
input:focus, textarea:focus {
    outline: none;
}

/* ========================================
   Reduced motion preferences
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    .hero-content {
        animation: none;
        opacity: 1;
        transform: none;
    }
    
    .group:hover .group-hover\:scale-110 {
        transform: none;
    }
    
    * {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

/* ========================================
   Responsive adjustments
   ======================================== */
@media (max-width: 767px) {
    .hero-content h1 {
        font-size: 2.75rem;
    }
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #9c8879;
}

/* ========================================
   Print styles
   ======================================== */
@media print {
    nav, footer, #contact-form, #mobile-menu-btn {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    .hero-content {
        animation: none;
    }
}
