/* DISEÑO PREMIUM BODEGA - Vinoteca Dobao */

:root {
    --primary: #8b4513;
    --primary-dark: #5d2f0e;
    --gold: #d4af37;
    --cream: #f5f5dc;
    --wood: #3e2723;
    --text-light: #f5f5dc;
    --text-dark: #2c1810;
    --shadow-strong: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-soft: 0 4px 16px rgba(0, 0, 0, 0.2);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Playfair Display', serif;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('assets/bodega_background.png') center/cover fixed;
    color: var(--text-light);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 0;
}

/* Contenedor Principal */
.app-container {
    width: 100%;
    max-width: 480px;
    min-height: 100vh;
    background: rgba(30, 20, 10, 0.85);
    backdrop-filter: blur(10px);
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.8);
    display: flex;
    flex-direction: column;
    padding-bottom: 100px;
}

/* Header Elegante */
.app-header {
    background: linear-gradient(180deg, rgba(139, 69, 19, 0.9) 0%, rgba(62, 39, 35, 0.9) 100%);
    padding: 2rem 1.5rem;
    text-align: center;
    border-bottom: 2px solid var(--gold);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    position: sticky;
    top: 0;
    z-index: 100;
}

#headerTitle {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--gold);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    letter-spacing: 0.05em;
    margin: 0;
}

.back-button {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(212, 175, 55, 0.2);
    border: 1px solid var(--gold);
    color: var(--gold);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.back-button:hover {
    background: rgba(212, 175, 55, 0.4);
    transform: translateY(-50%) scale(1.1);
}

/* Contenedor de Pasos */
.step-container {
    padding: 2rem 1.5rem;
}

.progress-indicator {
    text-align: center;
    margin-bottom: 2rem;
}

.progress-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.progress-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.3);
    transition: all 0.3s ease;
}

.progress-dot.active {
    background: var(--gold);
    box-shadow: 0 0 10px var(--gold);
}

.progress-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--gold);
    font-weight: 600;
}

.step-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-light);
    text-align: center;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.step-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: rgba(245, 245, 220, 0.7);
    text-align: center;
    margin-bottom: 2rem;
}

/* BOTONES CON IMÁGENES - ESTILO PREMIUM */
.character-grid-v2 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.character-card {
    position: relative;
    background: linear-gradient(135deg, rgba(62, 39, 35, 0.9) 0%, rgba(30, 20, 10, 0.9) 100%);
    border: 2px solid rgba(212, 175, 55, 0.3);
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-soft);
    min-height: 180px;
}

.character-card:hover {
    transform: translateY(-8px);
    border-color: var(--gold);
    box-shadow: 0 12px 40px rgba(212, 175, 55, 0.4);
}

.character-card:active {
    transform: translateY(-4px);
}

/* Imagen de fondo para cada botón */
.character-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0.3;
    transition: opacity 0.3s ease;
}

.character-card:hover::before {
    opacity: 0.5;
}

/* Imágenes específicas para cada tipo */
.character-card[data-type="tinto"]::before {
    background-image: url('assets/vino_tinto.png');
}

.character-card[data-type="blanco"]::before {
    background-image: url('assets/vino_blanco.png');
}

.character-card[data-type="espumoso"]::before {
    background-image: url('assets/vino_espumoso.png');
}

/* Perfiles de carácter */
.character-card[data-type="mineral"]::before {
    background-image: url('assets/perfil_mineral.png');
}

.character-card[data-type="aromatico"]::before {
    background-image: url('assets/perfil_aromatico.png');
}

.character-card[data-type="frutal"]::before {
    background-image: url('assets/perfil_frutal.png');
}

.character-card[data-type="elegante"]::before {
    background-image: url('assets/perfil_elegante.png');
}

.character-card[data-type="equilibrado"]::before {
    background-image: url('assets/perfil_equilibrado.png');
    opacity: 0.4;
}

/* Diferente opacidad temporalmente */
.character-card[data-type="robusto"]::before {
    background-image: url('assets/perfil_robusto.png');
}

/* Presupuesto / Ocasión */
.character-card[data-type="diario"]::before {
    background-image: url('assets/ocio_diario.png');
}

.character-card[data-type="especial"]::before {
    background-image: url('assets/experiencia_especial.png');
}

.character-card[data-type="autor"]::before {
    background-image: url('assets/vino_autor.png');
}

.character-content {
    position: relative;
    z-index: 2;
    padding: 2.5rem 1.5rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    background: rgba(30, 20, 10, 0.5);
    /* Overlay oscuro para legibilidad */
    transition: all 0.3s ease;
}

.character-card:hover .character-content {
    background: rgba(30, 20, 10, 0.3);
}

.character-icon {
    font-size: 3rem !important;
    color: var(--gold) !important;
    margin-bottom: 1rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.8));
}

.character-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffffff !important;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 1);
    display: block !important;
}

.character-sublabel {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--gold) !important;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.9);
}

.character-desc {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.95) !important;
    line-height: 1.4;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 1);
}

/* Wine Cards & Results */
.wine-card {
    background: linear-gradient(135deg, rgba(45, 30, 15, 0.95) 0%, rgba(20, 10, 5, 0.98) 100%);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 2rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.wine-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: var(--gold);
    box-shadow: 0 25px 60px rgba(212, 175, 55, 0.2);
}

.wine-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--gold);
    color: var(--wood);
    padding: 0.6rem 1.2rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    border-radius: 0 0 0 20px;
    z-index: 10;
    box-shadow: -4px 4px 15px rgba(0, 0, 0, 0.3);
}

.wine-image-container {
    width: 100%;
    height: 280px;
    overflow: hidden;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    position: relative;
}

.wine-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.wine-card:hover .wine-image-container img {
    transform: scale(1.1);
}

.wine-info {
    padding: 2rem;
}

.wine-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--gold);
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.wine-meta {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    color: rgba(245, 245, 220, 0.7);
    margin-bottom: 1.5rem;
    font-style: italic;
    display: block;
}

.ratings-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin: 1.5rem 0;
}

.badge-rating {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.price-container {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 2rem;
}

.wine-price {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--gold);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
    display: block;
}

.glass-badge {
    font-size: 0.9rem;
    font-weight: 600;
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold);
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.sommelier-review-box {
    background: rgba(212, 175, 55, 0.08);
    border-left: 4px solid var(--gold);
    padding: 1.5rem;
    border-radius: 4px 15px 15px 4px;
    margin: 1.5rem 0;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-style: italic;
    line-height: 1.7;
    color: rgba(245, 245, 220, 0.9);
}

.user-review-bubble {
    margin-top: 2rem;
    background: rgba(255, 255, 255, 0.03);
    padding: 1.5rem;
    border-radius: 20px;
    border: 1px dashed rgba(212, 175, 55, 0.2);
    position: relative;
}

.user-review-header {
    font-weight: 800;
    font-size: 0.7rem;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-review-text {
    font-style: italic;
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(245, 245, 220, 0.85);
}

.user-review-author {
    font-size: 0.85rem;
    font-weight: 700;
    margin-top: 1rem;
    color: var(--gold);
    text-align: right;
    display: block;
}

/* Food Selection Styles */
.food-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin: 2rem 1rem;
}

.food-suggestion-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.food-suggestion-card:hover {
    background: rgba(212, 175, 55, 0.1);
    border-color: var(--gold);
    transform: translateY(-5px);
}

.food-name {
    color: var(--text-light);
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    margin-top: 0.5rem;
}

.food-price {
    color: var(--gold);
    font-weight: 700;
    font-size: 1rem;
    margin-top: 0.5rem;
}

/* Summary Styles */
.summary-card {
    background: linear-gradient(135deg, rgba(45, 30, 15, 0.98) 0%, rgba(20, 10, 5, 0.98) 100%);
    border: 2px solid var(--gold);
    border-radius: 25px;
    padding: 2.5rem;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8);
    text-align: center;
}

.summary-icon-large {
    font-size: 5rem !important;
    color: var(--gold);
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 15px rgba(212, 175, 55, 0.4));
}

.summary-details {
    text-align: left;
    background: rgba(255, 255, 255, 0.03);
    padding: 2rem;
    border-radius: 15px;
    margin: 2rem 0;
    border: 1px solid rgba(212, 175, 55, 0.15);
}

.summary-item {
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.1);
}

.summary-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.summary-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--gold);
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.summary-value {
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--text-light);
}

.summary-price {
    color: var(--gold);
    font-weight: 800;
    font-size: 1.1rem;
    margin-top: 0.4rem;
}

.summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 2px solid rgba(212, 175, 55, 0.3);
}

.total-label {
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--gold);
}

.total-value {
    font-weight: 800;
    font-size: 2.2rem;
    color: var(--gold);
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

/* Tab Bar Premium */
.tab-bar {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    background: linear-gradient(180deg, rgba(62, 39, 35, 0.98) 0%, rgba(30, 20, 10, 0.98) 100%);
    backdrop-filter: blur(20px);
    border-top: 2px solid var(--gold);
    padding: 0.75rem 1rem 1.5rem;
    z-index: 1000;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5);
}

.tab-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tab-item {
    background: none;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    color: rgba(212, 175, 55, 0.6);
    cursor: pointer;
    flex: 1;
    transition: all 0.3s ease;
}

.tab-item:hover {
    color: var(--gold);
}

.tab-item .material-symbols-outlined {
    font-size: 1.5rem;
}

.tab-label {
    font-family: 'Inter', sans-serif;
    font-size: 0.65rem;
    font-weight: 600;
}

.tab-item-center {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: -30px;
    cursor: pointer;
}

.tab-center-button {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--gold) 0%, #b8860b 100%);
    color: var(--wood);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5);
    border: 4px solid rgba(30, 20, 10, 0.98);
    transition: all 0.3s ease;
}

.tab-center-button:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 30px rgba(212, 175, 55, 0.7);
}

.tab-center-label {
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--gold);
    margin-top: 4px;
}

/* Panel de Acción */
.action-panel {
    background: linear-gradient(135deg, rgba(62, 39, 35, 0.9) 0%, rgba(30, 20, 10, 0.9) 100%);
    border: 2px solid var(--gold);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    margin: 2rem 0;
    box-shadow: var(--shadow-soft);
}

.panel-icon {
    font-size: 4rem !important;
    color: var(--gold);
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.8));
}

.panel-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-light);
    margin: 1rem 0;
}

.panel-description {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: rgba(245, 245, 220, 0.8);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

/* Animaciones */
.slide-up {
    animation: slideUp 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Utilidades */
.hidden {
    display: none !important;
}

/* Chips de Filtro (Carta de Bodega) */
.filter-chips-wrapper {
    width: 100%;
    overflow-x: auto;
    padding: 1rem 0;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
    scrollbar-width: thin;
    scrollbar-color: rgba(212, 175, 55, 0.75) rgba(255, 255, 255, 0.08);
}

.filter-chips-wrapper::-webkit-scrollbar {
    height: 8px;
}

.filter-chips-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 999px;
}

.filter-chips-wrapper::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.7), rgba(197, 160, 40, 0.9));
    border-radius: 999px;
    border: 1px solid rgba(30, 20, 10, 0.5);
}

.filter-chips-wrapper::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(90deg, rgba(229, 192, 72, 0.85), rgba(212, 175, 55, 1));
}

.filter-chips {
    display: flex;
    gap: 0.75rem;
    padding: 0.5rem;
}

.chip {
    padding: 0.6rem 1.2rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--gold);
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.chip.active {
    background: var(--gold);
    color: var(--wood);
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
}

.badge-rating {
    font-size: 0.65rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

/* Responsive */
@media (max-width: 480px) {
    .character-card {
        min-height: 160px;
    }

    .character-title {
        font-size: 1.4rem;
    }

    .step-title {
        font-size: 1.4rem;
    }
}

/* Buttons Premium Style - Added Fix */
.btn-primary {
    background: linear-gradient(135deg, #d4af37 0%, #c5a028 100%);
    color: #1e140a;
    border: none;
    border-radius: 50px;
    padding: 1rem 2rem;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.6);
    background: linear-gradient(135deg, #e5c048 0%, #d4af37 100%);
}

.btn-primary:active {
    transform: translateY(1px);
}

.btn-secondary {
    background: rgba(30, 20, 10, 0.4);
    color: #d4af37;
    border: 1px solid rgba(212, 175, 55, 0.5);
    border-radius: 50px;
    padding: 1rem 2rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-secondary:hover {
    border-color: #d4af37;
    background: rgba(212, 175, 55, 0.1);
    color: #fff;
}

/* Rating Badges Premium Override */
.badge-rating {
    padding: 0.5rem 0.9rem;
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid transparent;
}

.badge-rating:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.5);
}

/* Vivino: Cl�sico Rojo */
.badge-vivino {
    background-color: #be1e2d;
    color: white;
    border: 1px solid #a0101d;
}

/* Parker: Negro y Oro (Premium) */
.badge-parker {
    background-color: #101010;
    color: #d4af37;
    border: 1px solid #d4af37;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.2);
}

/* Pe��n: Dorado con texto oscuro (Contraste) */
.badge-penin {
    background: linear-gradient(135deg, #d4af37 0%, #c5a028 100%);
    color: #1a0f00;
    border: 1px solid #e5c048;
    text-shadow: none;
}

/* Wine Spectator: Burdeos oscuro */
.badge-ws {
    background-color: #58181f;
    color: white;
    border: 1px solid #7a2323;
}

/* Autor: Transparente con borde */
.badge-autor {
    background: rgba(212, 175, 55, 0.1);
    color: #d4af37;
    border: 1px solid #d4af37;
    backdrop-filter: blur(5px);
}