/* ============================================
   Karina's Artisan Bakery — Custom Styles
   ============================================ */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a1628;
}
::-webkit-scrollbar-thumb {
    background: #c8962e;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #d4a84b;
}

/* Selection */
::selection {
    background: rgba(200, 150, 46, 0.3);
    color: #0f2140;
}

/* Reveal Animations — progressive enhancement */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
    }
    .reveal.revealed,
    .reveal[data-revealed="true"] {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navbar scroll state */
.navbar-scrolled {
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Mobile menu button animation */
.menu-line {
    display: block;
    height: 2px;
    width: 24px;
    background-color: currentColor;
    transition: all 0.3s ease;
}

#menu-btn.active .menu-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
#menu-btn.active .menu-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
    width: 24px;
}

/* Mobile links */
.mobile-link {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.mobile-link:last-child {
    border-bottom: none;
}

/* Focus visible */
:focus-visible {
    outline: 2px solid #c8962e;
    outline-offset: 2px;
}

/* Input autofill styling */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px rgba(255, 255, 255, 0.05) inset !important;
    -webkit-text-fill-color: #ffffff !important;
}

/* Smooth image loading */
img {
    image-rendering: auto;
    loading: lazy;
}

/* Print styles */
@media print {
    nav, #contact-form, .reveal {
        display: none !important;
    }
    body {
        color: #000;
        background: #fff;
    }
}
