/* ============================================
   CAPPY'S NORTHSIDE RESTAURANTS
   Custom Styles
   ============================================ */

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

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

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: #166534;
    color: #fefdf8;
}

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

#navbar.scrolled {
    background: rgba(254, 253, 248, 0.92);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(22, 101, 52, 0.08);
}

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

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

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

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

/* Hamburger */
.menu-line {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

#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;
}

/* ============================================
   HERO FLOATING CARDS
   ============================================ */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -1s;
}

.floating-card:nth-child(3) {
    animation-delay: -2s;
}

.floating-card:nth-child(4) {
    animation-delay: -3s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

/* ============================================
   MENU CARDS
   ============================================ */
.menu-card {
    transform: translateY(0);
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.5s ease;
}

.menu-card:hover {
    transform: translateY(-8px);
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.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; }

/* ============================================
   FORM STYLES
   ============================================ */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23166534' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px;
}

/* ============================================
   SMOOTH IMAGE LOADING
   ============================================ */
img {
    opacity: 1;
    transition: opacity 0.5s ease;
}

/* ============================================
   FOCUS VISIBLE
   ============================================ */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid #16a34a;
    outline-offset: 2px;
    border-radius: 8px;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 767px) {
    .floating-card {
        display: none;
    }

    #hero {
        min-height: auto;
        padding-top: 100px;
        padding-bottom: 60px;
    }

    #hero img {
        height: 350px !important;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .floating-card {
        display: none;
    }
}

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