/* ----- ESTILOS GENERALES ----- */
:root {
    --gold-color: #d4af37;
    --dark-gold-color: #a98c57;
    --background-color: #1a1a1a;
    --text-color: #e0e0e0;
    --subtle-text-color: #a7a7a7;
    --card-background: rgba(20, 20, 20, 0.9);
}

body {
    margin: 0;
    font-family: 'Lato', sans-serif;
    background-color: var(--background-color);
    background-image: url('https://www.transparenttextures.com/patterns/dark-matter.png');
    color: var(--text-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ----- CONTENEDOR PRINCIPAL ----- */
.menu-card {
    max-width: 800px;
    margin: 50px auto;
    background-color: var(--card-background);
    border: 1px solid var(--gold-color);
    border-radius: 4px;
    padding: 30px 50px;
    box-shadow: 0 0 40px rgba(212, 175, 55, 0.1);
}

/* ----- CABECERA CON EL LOGO ----- */
.menu-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 10px 0;
}
.logo {
    max-width: 280px;
    height: auto;
}

/* ----- TÍTULOS DE SECCIÓN ----- */
.section-title {
    font-family: 'Cinzel', serif;
    font-weight: 400;
    font-size: 1.8em;
    text-align: center;
    color: #ffffff;
    margin: 60px 0 35px 0;
    line-height: 1.4;
    letter-spacing: 1px;
}
.section-title::before {
    content: '';
    display: block;
    width: 80px;
    height: 1px;
    background: var(--gold-color);
    margin: 0 auto 15px auto;
}
.section-title span {
    font-size: 0.7em;
    color: var(--dark-gold-color);
    display: block;
}
.subsection-title {
    font-family: 'Cinzel', serif;
    font-weight: 400;
    color: var(--dark-gold-color);
    margin-top: 40px;
    margin-bottom: 20px;
    border-bottom: 1px solid #444;
    padding-bottom: 8px;
    font-size: 1.3em;
}

/* ----- ESTILO DE CADA PLATO ----- */
.menu-item {
    margin-bottom: 25px;
}
.item-header {
    display: flex;
    align-items: baseline;
    font-size: 1.1em;
    font-weight: 400;
    margin-bottom: 5px;
}
.item-name {
    color: #f5f5f5;
    order: 1;
}
.item-price {
    color: var(--gold-color);
    order: 3;
    padding-left: 10px;
}
.item-dots {
    order: 2;
    flex-grow: 1;
    border-bottom: 1px dotted #555;
    margin: 0 10px;
    transform: translateY(-3px);
}
.item-description {
    font-size: 0.9em;
    line-height: 1.6;
    color: var(--subtle-text-color);
    margin: 0;
    padding: 0;
    font-weight: 300;
}

/* ----- ESTILOS PARA PLATOS CON IMAGEN ----- */
.menu-item.with-image {
    display: flex;
    align-items: center;
    gap: 25px;
}
.item-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
    border: 1px solid var(--dark-gold-color);
}
.item-content {
    flex-grow: 1;
}

/* ----- ESTILOS PARA VINOS (COPA Y BOTELLA) ----- */
.item-price-group {
    display: flex;
    gap: 20px;
    white-space: nowrap;
    order: 3;
    padding-left: 10px;
}
.item-price-group .item-price {
    color: var(--gold-color);
    font-size: 1em;
}
.item-price-group .price-label {
    font-size: 0.8em;
    color: var(--dark-gold-color);
    margin-right: 8px;
    font-weight: 400;
}

/* ----- GRID PARA BEBIDAS Y LISTAS LARGAS ----- */
.beverage-grid {
    display: grid;
    gap: 40px;
}
.beverage-grid.three-columns { grid-template-columns: repeat(3, 1fr); }
.beverage-category h4 {
    font-family: 'Cinzel', serif;
    font-weight: 400;
    color: var(--dark-gold-color);
    margin-top: 0;
    margin-bottom: 15px;
    border-bottom: 1px solid #444;
    padding-bottom: 8px;
    font-size: 1.1em;
}
.beverage-category ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.beverage-category li {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.95em;
    color: var(--text-color);
}
.beverage-category li span:first-child { margin-right: 10px; }
.beverage-category li span:last-child {
    white-space: nowrap;
    font-weight: 700;
    color: #f5f5f5;
}

/* ----- ESTILOS PARA ALÉRGENOS (NUEVO) ----- */
.allergen-icons {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.allergen-icon {
    width: 24px;
    height: 24px;
}
.allergen-legend {
    margin-top: 30px;
}
.legend-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px 20px;
    margin-top: 25px;
}
.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9em;
    color: var(--subtle-text-color);
}
.legend-item .allergen-icon {
    width: 28px;
    height: 28px;
}

/* ----- FOOTER ----- */
footer {
    text-align: center;
    padding: 20px 0 0 0;
    margin-top: 40px;
    border-top: 1px solid #333;
}
footer > p {
    font-size: 0.85em;
    color: var(--subtle-text-color);
}

/* ----- DISEÑO ADAPTABLE (RESPONSIVE) ----- */
@media (max-width: 768px) {
    .menu-card {
        width: 90%;
        margin: 20px auto;
        padding: 20px 25px;
    }
    .logo { max-width: 200px; }
    .section-title { font-size: 1.5em; }
    .item-header { font-size: 1em; }
    
    .beverage-grid.three-columns {
        grid-template-columns: 1fr;
    }
    .item-image {
        width: 80px;
        height: 80px;
    }
    .menu-item.with-image { gap: 15px; }
    .item-description { font-size: 0.85em; }
    .allergen-icon { width: 20px; height: 20px; }

    .legend-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    .legend-item .allergen-icon { width: 24px; height: 24px;}

    .wine-item .item-header { flex-wrap: wrap; }
    .wine-item .item-header .item-name { flex-basis: 100%; margin-bottom: 8px; }
    .wine-item .item-header .item-dots { display: none; }
    .wine-item .item-header .item-price-group { padding-left: 0; margin-left: auto; }
}