/* ===================================
   Tammy's Bakery & Cafe — Custom Styles
   =================================== */

/* Base & Typography */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Montserrat', system-ui, sans-serif;
}

/* Selection Color */
::selection {
    background-color: #1a4d2e;
    color: #fefdf8;
}

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

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

::-webkit-scrollbar-thumb {
    background: #98c5a3;
    border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
    background: #6ba578;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scrollLine {
    0%, 100% {
        transform: scaleY(1);
        opacity: 0.5;
    }
    50% {
        transform: scaleY(0.5);
        opacity: 1;
    }
}

.animate-fadeIn {
    animation: fadeIn 0.8s ease-out forwards;
}

.animate-scrollLine {
    animation: scrollLine 2s ease-in-out infinite;
}

/* Scroll-triggered animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* Navbar Scrolled State */
.nav-scrolled {
    background-color: rgba(254, 253, 248, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(26, 77, 46, 0.08);
}

.nav-scrolled .font-serif {
    color: #1a4d2e !important;
}

.nav-scrolled .text-forest-700 {
    color: #1a4d2e !important;
}

.nav-scrolled .text-forest-600 {
    color: #2d6740 !important;
}

/* Mobile Menu Active State */
.mobile-menu-open #line1 {
    transform: translateY(7.5px) rotate(45deg);
}

.mobile-menu-open #line2 {
    opacity: 0;
}

.mobile-menu-open #line3 {
    transform: translateY(-7.5px) rotate(-45deg);
}

.mobile-menu-open #mobileMenu {
    opacity: 1 !important;
    pointer-events: all !important;
}

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

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

/* Smooth transitions for interactive elements */
button, a {
    transition: all 0.3s ease;
}

/* Reduce motion for users who prefer it */
@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;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* Print styles */
@media print {
    nav, #contact, footer, .animate-scrollLine {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
