/* === Custom Styles for Rose Cottage Bakery === */

/* Base resets */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    background-color: #1a1410;
    color: #e8d4b8;
    font-family: 'Inter', system-ui, sans-serif;
    overflow-x: hidden;
}

/* Selection color */
::selection {
    background-color: #c4623a;
    color: #f5efe6;
}

/* === Scroll Reveal Animations === */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .reveal.revealed {
        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; }
    .reveal-delay-5 { transition-delay: 0.5s; }
}

/* === Navbar === */
#navbar {
    background: transparent;
    transition: background-color 0.5s ease, backdrop-filter 0.5s ease, box-shadow 0.5s ease;
}

#navbar.scrolled {
    background: rgba(18, 14, 10, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(201, 168, 76, 0.1);
}

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

#mobile-menu.open .mobile-link {
    animation: fadeUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
}

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

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

/* === Hamburger Animation === */
.menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

.menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

.menu-btn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.25rem;
}

/* === Gold shimmer effect on hover for cards === */
.group:hover .group-hover\:scale-105 {
    will-change: transform;
}

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

::-webkit-scrollbar-track {
    background: #120e0a;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #c9a84c50;
}

/* === Image loading placeholder === */
img {
    background-color: #1a1410;
}

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

/* === Responsive adjustments === */
@media (max-width: 767px) {
    html {
        scroll-padding-top: 70px;
    }
}

/* === Print styles === */
@media print {
    #navbar,
    #mobile-menu,
    .reveal {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
}
