body {
    background-color: #F7F3E6;
    color: #16120F;
    overflow-x: hidden;
}

/* --- PRELOADER --- */
#preloader {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    background-color: #16120F; z-index: 9999;
    display: flex; justify-content: center; align-items: center; flex-direction: column;
    transition: opacity 1s ease, visibility 1s ease;
}
.loader-logo-img { height: 70px; width: auto; object-fit: contain; animation: fadePulse 2s infinite alternate; filter: brightness(0) invert(1); }
@keyframes fadePulse { 0% { opacity: 0.3; } 100% { opacity: 1; } }

/* --- NAV STICKY SMOOTH --- */
.nav-transparent { background-color: transparent; border-bottom: 1px solid rgba(255,255,255,0.1); padding: 2.5rem 0; }
.nav-solid { background-color: rgba(247, 243, 230, 0.98); backdrop-filter: blur(15px); border-bottom: 1px solid rgba(0,0,0,0.05); padding: 1.2rem 0; box-shadow: 0 10px 30px rgba(0,0,0,0.02); }
.nav-text-light { color: #F7F3E6; }
.nav-text-dark { color: #16120F; }

/* Inversión de logo en nav */
.nav-transparent .nav-logo-img { filter: brightness(0) invert(1); } 
.nav-solid .nav-logo-img { filter: none; } 

/* --- ANIMACIONES OPTIMIZADAS (GPU ACELERADA) --- */
.reveal-on-scroll {
    opacity: 0; 
    transform: translateY(40px);
    /* Transición ultra suave tipo "Ease-Out Expo" */
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform; /* Evita el Lag obligando a usar la tarjeta gráfica */
}
.reveal-on-scroll.is-visible { 
    opacity: 1; 
    transform: translateY(0); 
}

/* Clases de retraso para animaciones en cascada (Staggered) */
.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }

/* --- HERO SLIDER (Efecto Ken Burns Elegante) --- */
.hero-slide {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0; visibility: hidden;
    transition: opacity 2s ease-in-out, visibility 2s ease-in-out;
}
.hero-slide.active {
    opacity: 1; visibility: visible; z-index: 1;
}
.hero-slide img {
    width: 100%; height: 100%; object-fit: cover;
    transform: scale(1);
    transition: transform 8s ease-out; /* Movimiento lento y majestuoso */
    will-change: transform, opacity;
}
.hero-slide.active img {
    transform: scale(1.08); /* Zoom in sutil */
}

/* SCROLL DOWN INDICATOR */
.scroll-indicator { position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; z-index: 20; opacity: 0.7; transition: opacity 0.3s; }
.scroll-indicator:hover { opacity: 1; }
.scroll-line { width: 1px; height: 60px; background: rgba(255,255,255,0.2); position: relative; overflow: hidden; margin-top: 10px; }
.scroll-line::before { content: ''; position: absolute; top: -50%; left: 0; width: 100%; height: 50%; background: #C46031; animation: scrollLine 2s ease-in-out infinite; }
@keyframes scrollLine { 0% { top: -50%; } 100% { top: 100%; } }

/* --- ACORDEÓN INTERACTIVO DE MENÚ --- */
.menu-accordion { display: flex; width: 100%; height: 65vh; gap: 4px; overflow: hidden; }
.menu-panel {
    position: relative; flex: 1; overflow: hidden; cursor: pointer;
    transition: flex 0.8s cubic-bezier(0.25, 1, 0.5, 1);
    border-left: 1px solid rgba(255,255,255,0.1);
}
.menu-panel:first-child { border-left: none; }

.menu-panel img { 
    width: 100%; height: 100%; object-fit: cover; 
    transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1), filter 0.8s cubic-bezier(0.25, 1, 0.5, 1); 
    filter: grayscale(60%) brightness(0.5); 
    will-change: transform, filter;
}
.menu-panel:hover { flex: 3.5; }
.menu-panel:hover img { transform: scale(1.05); filter: grayscale(0%) brightness(0.9); }

.menu-panel-content { 
    position: absolute; bottom: 0; left: 0; width: 100%; padding: 40px 30px;
    background: linear-gradient(to top, rgba(22,18,15,0.9) 0%, rgba(22,18,15,0) 100%);
    color: white; opacity: 0.8; transition: opacity 0.5s; 
}
.menu-panel:hover .menu-panel-content { opacity: 1; }

.panel-title { 
    font-family: 'Playfair Display', serif; font-size: 1.5rem; letter-spacing: 0.05em; font-weight: 400;
    white-space: nowrap; transform-origin: left bottom; transition: all 0.5s ease;
}
.menu-panel:hover .panel-title { font-size: 2.5rem; font-style: italic; margin-bottom: 0.5rem; color: #F7F3E6; }

.panel-desc { 
    font-family: 'Lato', sans-serif; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.2em; 
    opacity: 0; transform: translateY(10px); transition: all 0.5s ease 0.2s; color: #C46031; 
}
.menu-panel:hover .panel-desc { opacity: 1; transform: translateY(0); }

/* --- OVERLAYS (FULLSCREEN MODALS) --- */
.overlay-fullscreen {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    z-index: 100; transform: translateY(100%);
    transition: transform 0.8s cubic-bezier(0.86, 0, 0.07, 1);
    overflow-y: auto;
    will-change: transform;
}
.overlay-carta { background-color: #F7F3E6; }
.overlay-reserva { background-color: #16120F; }
.overlay-fullscreen.open { transform: translateY(0); }

/* --- TABS DE LA CARTA --- */
.carta-tab-content { display: none; opacity: 0; transition: opacity 0.6s ease; }
.carta-tab-content.active { display: block; opacity: 1; animation: fadeIn 0.8s ease forwards; }

.carta-tab-btn { 
    color: #5A5A5A; position: relative; padding-bottom: 5px; transition: all 0.3s; 
}
.carta-tab-btn::after {
    content: ''; position: absolute; width: 0; height: 1px; bottom: 0; left: 50%;
    transform: translateX(-50%); background-color: #C46031; transition: width 0.3s ease;
}
.carta-tab-btn:hover { color: #16120F; }
.carta-tab-btn.active { color: #C46031; font-weight: bold; }
.carta-tab-btn.active::after { width: 100%; }

/* --- ESTILOS LISTA DE MENÚ CLÁSICA (ROSA NÁUTICA) --- */
.menu-list-item { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 1.5rem; }
.menu-list-text { flex-grow: 0; max-width: 75%; }
.menu-list-title { font-family: 'Playfair Display', serif; font-size: 1.15rem; color: #16120F; margin-bottom: 0.2rem; }
.menu-list-desc { font-family: 'Lato', sans-serif; font-size: 0.7rem; color: #5A5A5A; text-transform: uppercase; letter-spacing: 0.1em; line-height: 1.4; }
.menu-list-dots { flex-grow: 1; border-bottom: 1px dotted #C46031; margin: 0 15px; position: relative; top: -8px; opacity: 0.4; }
.menu-list-price { font-family: 'Lato', sans-serif; font-size: 1rem; color: #16120F; font-weight: bold; white-space: nowrap; }

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

/* --- WIZARD RESERVAS (ESTILO CLÁSICO EDITORIAL) --- */
.reserva-step { display: none; opacity: 0; transform: translateY(20px); transition: all 0.5s ease; }
.reserva-step.active { display: block; opacity: 1; transform: translateY(0); }

/* Select personalizado para mantener estilo editorial */
select.reserva-select {
    -webkit-appearance: none;
    -moz-appearance: none;
    background: transparent;
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23C46031' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/><path d='M0 0h24v24H0z' fill='none'/></svg>");
    background-repeat: no-repeat;
    background-position-x: 100%;
    background-position-y: 5px;
    border: none;
    border-bottom: 1px solid #D1D5DB;
    border-radius: 0;
    padding-right: 2rem;
    cursor: pointer;
}
select.reserva-select:focus {
    border-bottom-color: #C46031;
    outline: none;
}

/* --- BOTONES CLÁSICOS EDITORIALES --- */
.btn-editorial {
    display: inline-block; padding: 14px 40px; font-family: 'Lato', sans-serif; font-size: 10px;
    text-transform: uppercase; letter-spacing: 0.3em; color: #16120F; background-color: transparent;
    border: 1px solid #16120F; transition: all 0.4s ease; position: relative; overflow: hidden; cursor: pointer;
}
.btn-editorial::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-color: #16120F; transform: scaleX(0); transform-origin: right;
    transition: transform 0.4s cubic-bezier(0.86, 0, 0.07, 1); z-index: -1;
}
.btn-editorial:hover { color: #F7F3E6; border-color: #16120F; }
.btn-editorial:hover::before { transform: scaleX(1); transform-origin: left; }

.btn-editorial-light {
    color: #F7F3E6; border-color: rgba(247,243,230,0.5);
}
.btn-editorial-light::before { background-color: #F7F3E6; }
.btn-editorial-light:hover { color: #16120F; border-color: #F7F3E6; }

.btn-editorial-accent {
    color: #F7F3E6; border-color: #C46031; background-color: #C46031;
}
.btn-editorial-accent::before { background-color: #16120F; }
.btn-editorial-accent:hover { color: #F7F3E6; border-color: #16120F; }

/* Estilo de enlaces sutiles */
.link-hover-underline { position: relative; text-decoration: none; padding-bottom: 4px; cursor: pointer;}
.link-hover-underline::after {
    content: ''; position: absolute; width: 0; height: 1px; bottom: 0; left: 50%;
    transform: translateX(-50%); background-color: currentColor; transition: width 0.4s ease;
}
.link-hover-underline:hover::after { width: 100%; }

/* Adorno Clásico (Rombo) */
.ornament { display: flex; align-items: center; justify-content: center; gap: 15px; margin: 2rem 0; opacity: 0.6; }
.ornament-line { height: 1px; width: 40px; background-color: currentColor; }
.ornament-diamond { width: 6px; height: 6px; background-color: currentColor; transform: rotate(45deg); }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #F7F3E6; }
::-webkit-scrollbar-thumb { background: #16120F; }

/* --- ESTILOS PANEL DE ADMINISTRACIÓN --- */
body.has-admin-bar {
    padding-top: 48px;
}
@media (min-width: 768px) {
    body.has-admin-bar nav#navbar {
        top: 48px;
        margin-top: 0 !important;
    }
}

.admin-actions {
    position: absolute;
    right: 0;
    top: -22px;
    display: flex;
    gap: 6px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    transform: translateY(5px);
    z-index: 10;
}
body.admin-logged-in .menu-list-item:hover .admin-actions {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}
.admin-action-btn {
    background-color: #16120F;
    color: #F7F3E6;
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 3px 6px;
    font-size: 7.5px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.admin-action-btn-edit:hover {
    background-color: #C46031;
    color: white;
    border-color: #C46031;
}
.admin-action-btn-delete:hover {
    background-color: #EF4444;
    color: white;
    border-color: #EF4444;
}

/* Indicador de cámara/plato visual */
.camera-indicator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #C46031;
    margin-left: 6px;
    vertical-align: middle;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s, transform 0.2s;
    background-color: rgba(196, 96, 49, 0.08);
    padding: 3px;
    border-radius: 4px;
}
.camera-indicator:hover {
    opacity: 1;
    transform: scale(1.1);
    background-color: rgba(196, 96, 49, 0.15);
}

/* Modales */
.modal-overlay {
    background-color: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(6px);
    transition: opacity 0.3s ease;
}
.modal-overlay.hidden {
    display: none !important;
}

/* Estilos adicionales para modales */
#admin-dish-modal input, #admin-dish-modal select, #admin-dish-modal textarea {
    border-radius: 0;
}
#admin-dish-modal input:focus, #admin-dish-modal select:focus, #admin-dish-modal textarea:focus {
    border-color: #C46031;
    box-shadow: 0 0 0 2px rgba(196, 96, 49, 0.1);
}

