/* ==========================================================================
   CONFIGURACIÓN DE VARIABLES (:ROOT)
   ========================================================================== */
:root {
    --primary-color: #d97706;
    --primary-hover: #b45309;
    --secondary-color: #374151;
    --whatsapp-color: #25D366;
    --whatsapp-hover: #20ba5a;
    --text-muted: #9ca3af;
    --bg-light: #f9fafb;
    --bg-accent: #fef3c7;
    --white: #ffffff;
    --dark: #1f2937;

    --font-main: 'Poppins', sans-serif;
    --font-heading: 'Playfair Display', serif;

    --radius-lg: 20px;
    --radius-md: 15px;
    --radius-full: 50px;
    --shadow-sm: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-md: 0 10px 30px rgba(0,0,0,0.1);
    --shadow-lg: 0 15px 40px rgba(0,0,0,0.2);

    --transition: all 0.3s ease;
}

/* ==========================================================================
   RESET Y ESTILOS GLOBALES
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    overflow-x: hidden;
    color: var(--secondary-color);
}

h1, h2, h3, h4, h5 {
    font-family: var(--font-heading);
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   ANIMACIONES (Scroll & Keyframes)
   ========================================================================== */
.scroll-animate,
.scroll-animate-left,
.scroll-animate-right,
.scroll-animate-scale {
    opacity: 0;
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.scroll-animate         { transform: translateY(50px); }
.scroll-animate-left    { transform: translateX(-50px); }
.scroll-animate-right   { transform: translateX(50px); }
.scroll-animate-scale   { transform: scale(0.85); transition-duration: 0.6s; }

.animate-in {
    opacity: 1;
    transform: translate(0) scale(1);
}

/* Delays */
.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }
.delay-400 { transition-delay: 0.4s; }
.delay-500 { transition-delay: 0.5s; }

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

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

.animate-float { animation: float 3s ease-in-out infinite; }

/* ==========================================================================
   NAVBAR
   ========================================================================== */
/* --- Tu Estilo de Navbar Base --- */
.navbar {
    background: var(--white) !important;
    box-shadow: var(--shadow-sm);
    padding: 1rem 0;
}

.navbar-brand {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color) !important;
}

.nav-link {
    font-weight: 500;
    color: var(--secondary-color) !important;
    margin: 0 0.5rem;
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--primary-color) !important;
}

/* --- BOTÓN HAMBURGUESA ELEGANTE (Añade esto) --- */

/* Eliminamos el recuadro y borde de Bootstrap */
.navbar-toggler {
    border: none !important;
    padding: 10px;
    box-shadow: none !important;
    outline: none !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px; /* Espacio entre las rayitas */
}

/* Creamos las 3 líneas manualmente */
.navbar-toggler-icon {
    background-image: none !important; /* Quitamos el icono feo de Bootstrap */
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--primary-color) !important;
    position: relative;
    transition: all 0.3s ease;
}

/* Línea superior e inferior usando pseudo-elementos */
.navbar-toggler-icon::before,
.navbar-toggler-icon::after {
    content: "";
    width: 24px;
    height: 2px;
    background-color: var(--primary-color);
    position: absolute;
    left: 0;
    transition: all 0.3s ease;
}

.navbar-toggler-icon::before { top: -8px; }
.navbar-toggler-icon::after { top: 8px; }

/* ANIMACIÓN: Transformación a X al abrir el menú */
.navbar-toggler:not(.collapsed) .navbar-toggler-icon {
    background-color: transparent !important; /* Desaparece la del medio */
}

.navbar-toggler:not(.collapsed) .navbar-toggler-icon::before {
    top: 0;
    transform: rotate(45deg);
}

.navbar-toggler:not(.collapsed) .navbar-toggler-icon::after {
    top: 0;
    transform: rotate(-45deg);
}

/* --- Navbar Mobile (Tu código actualizado) --- */
@media (max-width: 991px) {
    .navbar-brand { font-size: 1.4rem; }

    /* El contenedor que Bootstrap anima — sin padding ni radius */
    .navbar-collapse {
        margin-top: 0.5rem;
        overflow: hidden !important; /* evita el salto visual al final */
    }

    /* El padding y estilos van en el hijo, que no se anima */
    .navbar-nav {
        background: var(--white);
        padding: 0.75rem;
        border-radius: var(--radius-md);
        box-shadow: var(--shadow-md);
        border: 1px solid rgba(0,0,0,0.05);
    }

    .nav-link {
        margin: 0.25rem 0;
        padding: 0.6rem 1rem !important;
        border-radius: 8px;
    }

    .nav-link:hover {
        background: var(--bg-accent, #f8f9fa);
        color: var(--primary-color) !important;
    }
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    min-height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.6)),
                url('https://images.unsplash.com/photo-1517248135467-4c7edcad34c4?w=1920&h=1080&fit=crop');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    text-align: center;
    padding: 100px 1.5rem 60px;


}

.hero-section h1 {
    font-size: clamp(2.2rem, 7vw, 5rem);
    margin-bottom: 1.5rem;
    animation: fadeInUp 1s ease-out;
    line-height: 1.1;
}

.hero-section p {
    font-size: clamp(1rem, 3vw, 1.5rem);
    margin-bottom: 2rem;
    animation: fadeInUp 1.2s ease-out;
}

.hero-buttons {
    animation: fadeInUp 1.4s ease-out;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

/* Deshabilitar parallax en móvil (performance) */
@media (max-width: 768px) {
    .hero-section {
        background-attachment: scroll;
    }
}

/* ==========================================================================
   BOTONES Y COMPONENTES UI
   ========================================================================== */
.btn-whatsapp,
.btn-menu {
    padding: 0.85rem 2rem;
    border-radius: var(--radius-full);
    font-size: clamp(0.95rem, 2.5vw, 1.1rem);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-whatsapp { background: var(--whatsapp-color); color: var(--white); }
.btn-whatsapp:hover { background: var(--whatsapp-hover); transform: scale(1.05); color: var(--white); }

.btn-menu { background: var(--primary-color); color: var(--white); }
.btn-menu:hover { background: var(--primary-hover); transform: scale(1.05); color: var(--white); }

/* WhatsApp flotante */
.whatsapp-float {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    background: var(--whatsapp-color);
    color: var(--white);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.5);
    z-index: 1000;
    text-decoration: none;
    transition: var(--transition);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    color: var(--white);
    background: var(--whatsapp-hover);
}



@media (max-width: 480px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
        bottom: 1rem;
        right: 1rem;
    }
}

/* ==========================================================================
   SECCIÓN PRESENTACIÓN
   ========================================================================== */
@media (max-width: 768px) {
    .stats-card h3 { font-size: 1.8rem; }
    .stats-card p  { font-size: 0.85rem; }
    .stats-card    { padding: 1rem 0.5rem; }
}

/* Galería de imágenes en presentación */
@media (max-width: 575px) {
    .col-6 img { margin-top: 0 !important; }
}

/* ==========================================================================
   STATS CARDS
   ========================================================================== */
.stats-card {
    background: var(--white);
    padding: 2rem 1rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: var(--transition);
}

.stats-card:hover { transform: translateY(-5px); }

.stats-card h3 {
    color: var(--primary-color);
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    margin-bottom: 0.5rem;
}

/* ==========================================================================
   PLATILLOS CARDS
   ========================================================================== */
/* Estilos Base de la Tarjeta */
.platillo-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
    position: relative;
    border: 2px solid transparent;
    transition: var(--transition);
    
    /* --- Truco para altura uniforme --- */
    display: flex;
    flex-direction: column;
    height: 100%; 
}

/* Cuerpo de la tarjeta: Controla el crecimiento del texto */
.platillo-card .card-body {
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* Expande el cuerpo para llenar el espacio vacío */
    padding: 1.5rem;
}

/* Descripción: Empuja el botón hacia abajo */
.platillo-card .card-body p.text-muted {
    flex-grow: 1; /* Absorbe el espacio sobrante si el texto es corto */
    margin-bottom: 1.5rem;
}

/* Contenedor de Precio y Botón: Siempre al fondo */
.platillo-card .card-body .d-flex {
    margin-top: auto; 
}

/* Efectos de Hover y Brillo */
.platillo-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2),
                0 0 25px rgba(217, 119, 6, 0.4);
    border-color: rgba(217, 119, 6, 0.5);
}

.platillo-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255,255,255,0.3), transparent);
    transform: skewX(-25deg);
    transition: none;
    z-index: 1;
    pointer-events: none;
}

.platillo-card:hover::after {
    left: 150%;
    transition: all 0.9s ease;
}

/* Imagen */
.platillo-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
    display: block;
}

.platillo-card img:hover { 
    transform: scale(1.05); 
}

/* Badge de Rating */
.badge-rating {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--primary-color);
    color: var(--white);
    padding: 0.4rem 0.9rem;
    border-radius: 30px;
    font-size: 0.95rem;
    z-index: 2;
}

/* Estilos del Botón Ordenar */
#btn-ordenar {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1.5px solid transparent !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

#btn-ordenar:hover {
    border-color: var(--primary-color) !important;
    background-color: transparent !important;
    color: var(--primary-color) !important;
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(217, 119, 6, 0.2);
}

#btn-ordenar:active {
    transform: scale(0.95);
    filter: brightness(0.9);
}

/* Responsividad */
@media (max-width: 576px) {
    .platillo-card img { 
        height: 200px; 
    }

    .platillo-card .card-body .d-flex {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start !important;
    }

    #btn-ordenar { 
        width: 100%; 
        justify-content: center; 
    }
}

/* ==========================================================================
   INSTAGRAM SECTION
   ========================================================================== */
.instagram-section {
    background: linear-gradient(135deg, #833ab4 0%, #fd1d1d 50%, #fcb045 100%);
    color: var(--white);
    padding: 4rem 0;
    position: relative;
    overflow: hidden;
}

.instagram-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(255,255,255,0.1) 0%, transparent 50%);
}

.instagram-grid img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: var(--radius-lg);
    transition: var(--transition);
    cursor: pointer;
    display: block;
}

.instagram-grid img:hover { transform: scale(1.05); }

@media (max-width: 576px) {
    .instagram-grid img { height: 160px; }
}

/* ==========================================================================
   FORMULARIOS Y RESERVAS
   ========================================================================== */
.form-control,
.form-select {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    border: 2px solid #e5e7eb;
    font-size: 1rem;
    transition: var(--transition);
    width: 100%;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(217, 119, 6, 0.25);
    outline: none;
}

.btn-submit {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    color: var(--white);
    padding: 0.85rem 1rem;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1.1rem;
    font-weight: 600;
    width: 100%;
    transition: var(--transition);
    cursor: pointer;
}

.btn-submit:hover {
    transform: scale(1.02);
    box-shadow: 0 10px 30px rgba(217, 119, 6, 0.3);
}

/* Reservas mobile */
@media (max-width: 768px) {
    #reservaForm { padding: 1.5rem !important; }
}

@media (max-width: 576px) {
    #reservaForm { padding: 1.25rem !important; }

    .form-control,
    .form-select { font-size: 0.95rem; }

    .btn-submit { font-size: 1rem; padding: 0.9rem; }
}

/* ==========================================================================
   CONTACTO
   ========================================================================== */
.contact-info-card {
    background: var(--bg-light);
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-lg);
    margin-bottom: 1rem;
    transition: var(--transition);
}

.contact-info-card:hover { background: var(--bg-accent); }
.contact-info-card i { font-size: 1.5rem; color: var(--primary-color); }

/* Mapa */
.map-container {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    height: 500px;
}

.map-container iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

@media (max-width: 991px) {
    .map-container { height: 400px; }
}

@media (max-width: 576px) {
    .map-container { height: 300px; }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
footer {
    background-color: #111827;
    padding: 60px 0 30px;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: #9ca3af;
}

footer h5 {
    color: var(--white);
    font-weight: 700;
    margin-bottom: 1.25rem;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

footer h5 i {
    color: var(--primary-color);
    margin-right: 8px;
}

footer p { line-height: 1.7; }

footer ul li a {
    color: #9ca3af;
    text-decoration: none;
    transition: var(--transition);
    display: inline-block;
}

footer ul li a:hover {
    color: var(--primary-color);
    transform: translateX(8px);
}

/* Iconos sociales */
.social-icon {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-right: 10px;
    font-size: 1.2rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: #fff;
    border: 1px solid #eee;
    color: #4b5563 !important;
}

.social-icon:hover {
    transform: translateY(-5px);
    color: #fff !important;
    box-shadow: 0 10px 20px rgba(217, 119, 6, 0.2);
}

.social-instagram:hover {
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285aeb 90%);
}

.social-whatsapp:hover { background: #25d366; }

/* Divisor y bottom */
.footer-divider {
    margin: 40px 0 25px;
    opacity: 0.1;
    border-top: 1px solid var(--white);
}

.footer-bottom {
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    color: rgba(255,255,255,0.5);
}

/* Link Damian Coria */
#link-footer {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    position: relative;
    display: inline-block;
}

#link-footer:hover {
    color: var(--primary-color);
    text-shadow: 0 0 8px rgba(255,255,255,0.3);
}

#link-footer::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -2px;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

#link-footer:hover::after { width: 100%; }

/* Footer responsive */
@media (max-width: 991px) {
    footer {
        text-align: center;
        padding: 40px 0 20px;
    }

    footer [class*="col-"] {
        margin-bottom: 2rem;
    }

    footer ul li a:hover {
        transform: translateY(-3px);
    }

    .social-icon {
        margin: 0 6px;
    }
}

@media (max-width: 576px) {
    footer { padding: 30px 0 15px; }

    footer h5 { font-size: 0.95rem; }

    .footer-divider { margin: 25px 0 15px; }

    .footer-bottom { font-size: 0.8rem; }
}

/* ==========================================================================
   UTILIDADES RESPONSIVE EXTRA
   ========================================================================== */

/* Evitar overflow horizontal en cualquier sección */
section, footer, nav {
    overflow-x: hidden;
}

/* Tipografía fluida para headings */
.display-4 {
    font-size: clamp(1.8rem, 5vw, 3.5rem) !important;
    line-height: 1.2;
}

.display-6 {
    font-size: clamp(1.4rem, 4vw, 2.5rem) !important;
    line-height: 1.2;
}

/* Padding de secciones más compacto en mobile */
@media (max-width: 768px) {
    .py-5 { padding-top: 3rem !important; padding-bottom: 3rem !important; }
    .my-5 { margin-top: 2rem !important; margin-bottom: 2rem !important; }
    .mb-5 { margin-bottom: 2rem !important; }

    .hero-buttons .btn-whatsapp,
    .hero-buttons .btn-menu {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .py-5 { padding-top: 2rem !important; padding-bottom: 2rem !important; }
    .my-5 { margin-top: 1.5rem !important; margin-bottom: 1.5rem !important; }
}