:root {
    --gold-primary: #FFCC00;
    --gold-glow: #ffae00;
    --bg-dark: #000000;
    --card-bg: #141414;
    --card-border: #262626;
    --text-light: #f5f5f5;
    --text-muted: #aaaaaa;
    --red-accent: #d9230f;
    --font-main: 'Segoe UI', system-ui, -apple-system, sans-serif;
    --cenefa-width: 32px; /* Variable para controlar el ancho de la cenefa */
}

/* Selector Universal Corregido (*) */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-dark) !important;
    color: var(--text-light);
    font-family: var(--font-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Relleno lateral calculado según el ancho de la cenefa para que el contenido no quede oculto detrás */
    padding: 15px calc(var(--cenefa-width) + 10px);
    overflow-x: hidden;
    position: relative;
    top: 0 !important; /* Mantiene la página pegada arriba si Google inyecta la barra superior */
}

/* --- CENEFAS LATERALES / MARCO BORDER --- */

/* Cenefa Izquierda */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: var(--cenefa-width);
    height: 100vh;
    background-image: url('../img/cenefa.png'); /* Ruta de la imagen */
    background-repeat: repeat-y;
    background-size: contain;
    background-position: top left;
    z-index: 999;
    pointer-events: none; /* Permite interactuar/hacer clic a través de ella */
}

/* Cenefa Derecha */
body::after {
    content: "";
    position: fixed;
    top: 0;
    right: 0;
    width: var(--cenefa-width);
    height: 100vh;
    background-image: url('../img/cenefa.png'); /* Ruta de la imagen */
    background-repeat: repeat-y;
    background-size: contain;
    background-position: top right;
    z-index: 999;
    pointer-events: none;
}

/* CONTENEDOR PRINCIPAL */
.main-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* HERO SECTION / ENCABEZADO */
.hero-section {
    position: relative;
    width: 100%;
    padding: 20px 10px 10px 10px;
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    z-index: 100; /* Permite que los elementos desplegables floten sobre la navegación */
}

.hero-container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 5;
    gap: 15px;
    width: 100%;
}

/* LOGO Y LLAMAS LATERALES */
.hero-logo-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-img {
    width: 100%;
    max-width: 480px;
    height: auto;
    display: block;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    z-index: 2;
    filter: drop-shadow(0 0 15px rgba(0, 0, 0, 0.9));
    image-rendering: -webkit-optimize-contrast;
}

.fire-side-logo {
    width: auto;
    height: 260px;
    max-height: 280px;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
    flex-shrink: 0;
    animation: flameAnimation 2.5s infinite alternate ease-in-out;
}

.fire-side-logo.left { margin-right: 0; }
.fire-side-logo.right { margin-left: 0; }

@keyframes flameAnimation {
    0% {
        opacity: 0.8;
        filter: brightness(0.95) drop-shadow(0 0 12px rgba(255, 100, 0, 0.4));
        transform: scale(0.97);
    }
    50% {
        opacity: 1;
        filter: brightness(1.25) drop-shadow(0 0 25px rgba(255, 150, 0, 0.8));
        transform: scale(1.03);
    }
    100% {
        opacity: 0.85;
        filter: brightness(1.05) drop-shadow(0 0 15px rgba(255, 80, 0, 0.5));
        transform: scale(0.98);
    }
}

/* AISLAMIENTO Y ESTILOS DE GOOGLE TRANSLATE */
.language-switcher-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 5px;
    margin-bottom: 5px;
    z-index: 20;
    width: 100%;
}

/* BOTONES DE ACCIÓN RÁPIDA */
.header-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    width: 100%;
    margin-top: 5px;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    background: linear-gradient(145deg, #1e1e1e, #111111);
    border: 1px solid rgba(255, 204, 0, 0.35);
    border-radius: 50px;
    color: #ffffff;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5), inset 0 1px 1px rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-action:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.7);
}

.btn-icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.25rem;
    transition: transform 0.3s ease;
}

.btn-action:hover .btn-icon-wrapper {
    transform: scale(1.1);
}

.btn-text { display: none; }

.btn-action-address { border-color: rgba(217, 35, 15, 0.4); }
.btn-action-address .btn-icon-wrapper {
    background: linear-gradient(135deg, #ff4b4b, #d9230f);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(217, 35, 15, 0.4);
}

.btn-action-facebook { 
    border-color: rgba(24, 119, 242, 0.4); 
}

.btn-action-facebook .btn-icon-wrapper {
    background: linear-gradient(135deg, #1877f2, #0d52b3);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(24, 119, 242, 0.4);
}

.btn-action-whatsapp { border-color: rgba(37, 211, 102, 0.4); }
.btn-action-whatsapp .btn-icon-wrapper {
    background: linear-gradient(135deg, #25d366, #128c7e);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(37, 211, 102, 0.4);
}

.btn-action-tiktok { 
    border-color: rgba(254, 44, 85, 0.4); 
}

.btn-action-tiktok .btn-icon-wrapper {
    background: linear-gradient(135deg, #00f2fe, #fe2c55);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(254, 44, 85, 0.4);
}

.btn-action-maps { border-color: rgba(66, 133, 244, 0.4); }
.btn-action-maps .btn-icon-wrapper {
    background: linear-gradient(135deg, #4285f4, #1a73e8);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(66, 133, 244, 0.4);
}

/* DESPLEGABLE DE DIRECCIÓN */
.dropdown-address {
    position: relative;
    display: inline-block;
}

.address-card {
    position: absolute;
    top: calc(100% + 8px);
    left: 0; /* Alineado al borde izquierdo del botón en pantallas grandes */
    width: 260px;
    max-width: calc(100vw - 40px); /* Garantiza que no sobrepase la pantalla */
    padding: 15px;
    background-color: #1a1a1a;
    border: 1px solid var(--gold-primary);
    color: var(--text-light);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.8);
    border-radius: 12px;
    z-index: 1000;
    font-size: 0.85rem;
    text-align: center;
    line-height: 1.4;
}

.address-card strong { color: var(--gold-primary); }
.address-card small { display: block; margin-top: 6px; color: var(--text-muted); }
.address-card.hidden { display: none !important; }

/* CATEGORÍAS */
.category-nav {
    position: relative;
    z-index: 1; /* Nivel inferior para ser cubierto por los desplegables superiores */
    display: flex;
    justify-content: flex-start;
    gap: 10px;
    margin-bottom: 25px;
    width: 100%;
    overflow-x: auto;
    padding: 5px 0 10px 0;
    scrollbar-width: thin;
    scrollbar-color: var(--gold-primary) var(--bg-dark);
}

.category-nav::-webkit-scrollbar { height: 4px; }
.category-nav::-webkit-scrollbar-thumb { background: var(--gold-primary); border-radius: 4px; }

@media (min-width: 768px) {
    .category-nav {
        justify-content: center;
        flex-wrap: wrap;
        overflow-x: visible;
    }
}

.category-badge {
    background: var(--card-bg);
    border: 1px solid var(--gold-primary);
    color: var(--text-light);
    padding: 8px 18px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    transition: all 0.25s ease;
}

.category-badge.active,
.category-badge:hover {
    background: var(--gold-primary);
    color: #000;
    box-shadow: 0 0 10px rgba(255, 204, 0, 0.4);
}

/* GRID Y TARJETAS */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
    width: 100%;
}

.food-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    max-width: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.food-card:hover {
    transform: translateY(-6px);
    border-color: var(--gold-primary);
    box-shadow: 0 8px 20px rgba(255, 204, 0, 0.2);
}

.img-wrapper {
    width: 100%;
    height: 180px;
    overflow: hidden;
    position: relative;
    background-color: #000;
}

.food-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.food-card:hover .food-card-img { transform: scale(1.06); }

.food-card-body {
    padding: 15px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    justify-content: space-between;
}

.badge-cat {
    font-size: 0.7rem;
    text-transform: uppercase;
    background: var(--gold-glow);
    color: #fff;
    padding: 3px 8px;
    border-radius: 4px;
    display: inline-block;
    margin-bottom: 8px;
    font-weight: bold;
}

.food-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 6px;
}

.food-description {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin-bottom: 12px;
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.food-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.food-price {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--gold-primary);
}

/* MODAL DE DETALLE */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    padding: 15px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-card {
    background: #141414;
    border: 1px solid var(--gold-primary);
    border-radius: 16px;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.9);
}

.modal-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    object-position: center;
}

.modal-body { padding: 20px; }

.modal-close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid var(--gold-primary);
    color: var(--gold-primary);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
}

.modal-close-btn:hover {
    background: var(--gold-primary);
    color: #000;
}

.modal-title {
    font-size: 1.4rem;
    color: #fff;
    margin: 8px 0;
}

.modal-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 15px;
}

.modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 12px;
}

.modal-price {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--gold-primary);
}

/* RESPONSIVO MÓVIL CON CENEFAS VISIBLES */
@media (max-width: 768px) {
    :root {
        /* Se reduce un poco el ancho en pantallas móviles para no restar tanto espacio útil */
        --cenefa-width: 20px;
    }

    body {
        /* Ajuste de margen interno proporcional al ancho reducidode la cenefa */
        padding-left: calc(var(--cenefa-width) + 6px);
        padding-right: calc(var(--cenefa-width) + 6px);
    }
}

@media (max-width: 600px) {
    :root {
        --cenefa-width: 16px;
    }

    .hero-logo-wrapper { gap: 4px; }
    .hero-img { max-width: 190px; }
    .fire-side-logo { height: 130px; max-height: 130px; }
    .menu-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .img-wrapper { height: 120px; }
    .food-card-body { padding: 10px; }
    .food-title { font-size: 0.95rem; line-height: 1.2; }
    .food-description { font-size: 0.75rem; line-height: 1.3; margin-bottom: 8px; }
    .food-price { font-size: 1rem; }
    .badge-cat { font-size: 0.65rem; padding: 2px 6px; }
}

@media (max-width: 380px) {
    :root {
        --cenefa-width: 12px;
    }

    .hero-logo-wrapper { gap: 2px; }
    .hero-img { max-width: 155px; }
    .fire-side-logo { height: 105px; max-height: 105px; }
    .menu-grid { gap: 8px; }
    .img-wrapper { height: 100px; }
    .food-card-body { padding: 8px; }
}

/* AJUSTE RESPONSIVO PARA PANTALLAS PEQUEÑAS (Móviles) */
@media (max-width: 600px) {
    .address-card {
        position: fixed;
        top: auto;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 85% !important;
        max-width: 320px;
        z-index: 2500; /* Asegura que quede por encima de otros elementos */
    }
}

/* --- ESTILOS FORZADOS PARA GOOGLE TRANSLATE (.goog-te-combo) --- */

/* Ocultar la barra superior y marcos no deseados de Google */
.goog-te-banner-frame, 
.skiptranslate > iframe,
.goog-te-gadget-icon,
#goog-gt-tt {
    display: none !important;
    visibility: hidden !important;
}

/* Quitar envoltorios nativos */
.goog-te-gadget-simple,
.goog-te-gadget {
    background-color: transparent !important;
    border: none !important;
    padding: 0 !important;
    color: transparent !important;
    font-size: 0px !important;
}

.goog-te-gadget span {
    display: none !important;
}

/* Forzar apariencia personalizada en el desplegable nativo */
select.goog-te-combo {
    background-color: #141414 !important;
    color: #FFCC00 !important;
    border: 1px solid #FFCC00 !important;
    border-radius: 20px !important;
    padding: 6px 30px 6px 14px !important;
    font-family: var(--font-main) !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    outline: none !important;
    cursor: pointer !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6) !important;
    
    /* Quita los estilos por defecto (azul/gris) del sistema operativo */
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    
    /* Flecha personalizada en color dorado */
    background-image: url('../img/flecha-dorada.svg') !important;
    background-repeat: no-repeat !important;
    background-position: right 10px center !important;
}

/* Estilos de las opciones dentro del menú desplegable */
select.goog-te-combo option {
    background-color: #141414 !important;
    color: #ffffff !important;
    padding: 8px !important;
}
/* --- ESTILOS PARA PLATOS NO DISPONIBLES --- */

/* Tarjeta deshabilitada cuando el plato no está disponible */
.food-card.plato-no-disponible {
    opacity: 0.65;
    cursor: not-allowed;
    filter: grayscale(30%);
}

.food-card.plato-no-disponible:hover {
    transform: none;
    border-color: var(--card-border);
    box-shadow: none;
}

/* Franja / Etiqueta Roja de No Disponible */
.badge-no-disponible {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--red-accent);
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 800;
    padding: 6px 14px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
    z-index: 5;
}