/* ========================================
   Jan's Cake Place — Custom Styles
   ======================================== */

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

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

body {
    overflow-x: hidden;
}

::selection {
    background-color: rgba(4, 120, 87, 0.2);
    color: #064e3b;
}

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

#navbar.scrolled {
    background: rgba(254, 253, 248, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(6, 78, 59, 0.08), 0 4px 24px rgba(6, 78, 59, 0.06);
}

.nav-text {
    color: #fefdf8;
    transition: color 0.5s ease;
}

.nav-subtext {
    color: rgba(254, 240, 212, 0.7);
    transition: color 0.5s ease;
}

#navbar.scrolled .nav-text {
    color: #064e3b;
}

#navbar.scrolled .nav-subtext {
    color: #059669;
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: #059669;
    transition: width 0.3s ease;
}

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

#navbar.scrolled .nav-link {
    color: #065f46;
}

#navbar.scrolled .nav-link:hover {
    color: #047857;
}

/* Mobile Menu Button */
.nav-menu-btn {
    border-color: rgba(6, 78, 59, 0.2);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.nav-menu-btn:hover {
    background-color: rgba(6, 78, 59, 0.05);
    border-color: rgba(6, 78, 59, 0.4);
}

#navbar.scrolled .nav-menu-btn {
    border-color: rgba(6, 78, 59, 0.15);
}

#navbar.scrolled .nav-menu-btn:hover {
    background-color: rgba(6, 78, 59, 0.05);
}

/* Mobile Menu */
.mobile-link {
    opacity: 1;
}

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

/* ========================================
   Form Styles
   ======================================== */
select option {
    background: #064e3b;
    color: #fefdf8;
}

/* ========================================
   Image Hover Effects
   ======================================== */
img {
    display: block;
    max-width: 100%;
}

/* ========================================
   Focus Styles
   ======================================== */
:focus-visible {
    outline: 2px solid #34d399;
    outline-offset: 2px;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 768px) {
    .reveal {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   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;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
}
