/* ============================================
   EL CHARRO VIEJO — Custom Styles
   Classic & Elegant Mexican Restaurant
   ============================================ */

/* Base Reset & Smooth Scrolling */
*, *::before, *::after {
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

/* Custom Selection Color */
::selection {
    background-color: #2b482d;
    color: #FAF9F6;
}

/* ============================================
   NAVIGATION
   ============================================ */
#navbar {
    backdrop-filter: blur(0px);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#navbar.scrolled {
    background-color: rgba(250, 249, 246, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(43, 72, 45, 0.1);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #4a7a4b;
    transition: width 0.3s ease;
}

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

#navbar.scrolled .nav-link {
    color: #2b482d;
}

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

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

.mobile-link {
    font-family: 'Cormorant Garamond', Georgia, serif;
}

/* Hamburger Animation */
.menu-line {
    transform-origin: center;
}

#mobile-menu-btn.active .menu-line:nth-child(1) {
    transform: translateY(5px) rotate(45deg);
}

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

#mobile-menu-btn.active .menu-line:nth-child(3) {
    transform: translateY(-5px) rotate(-45deg);
    width: 24px;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-headline {
    line-height: 0.95;
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.reveal-on-scroll.revealed:nth-child(2) {
    transition-delay: 0.1s;
}

.reveal-on-scroll.revealed:nth-child(3) {
    transition-delay: 0.2s;
}

.reveal-on-scroll.revealed:nth-child(4) {
    transition-delay: 0.3s;
}

/* ============================================
   IMAGE HOVER EFFECTS
   ============================================ */
img {
    max-width: 100%;
    height: auto;
}

/* ============================================
   FORM STYLES
   ============================================ */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 1px #4a7a4b;
}

/* ============================================
   BUTTON HOVER EFFECTS
   ============================================ */
button, a {
    cursor: pointer;
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 768px) {
    .hero-headline {
        font-size: 2.5rem;
    }
    
    .hero-headline {
        font-size: 3rem;
    }
    
    #hero {
        padding-top: 80px;
    }
}

@media (max-width: 640px) {
    .hero-headline {
        font-size: 2.25rem;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
@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-on-scroll {
        opacity: 1;
        transform: none;
    }
}

/* Focus visible for keyboard navigation */
:focus-visible {
    outline: 2px solid #2b482d;
    outline-offset: 2px;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #4a7a4b;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    nav, button, #mobile-menu-btn {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    .reveal-on-scroll {
        opacity: 1;
        transform: none;
    }
}
