/* Menú 3D Realista tipo Libro */
.book-modal-content {
    max-width: 95vw;
    max-height: 95vh;
    padding: 1rem;
    background: transparent;
    box-shadow: none;
}

.book-container {
    perspective: 3000px;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.book {
    position: relative;
    width: 100%;
    height: 80vh;
    max-height: 800px;
    transform-style: preserve-3d;
    margin: 2rem auto;
}

.book-spine {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 100%;
    background: linear-gradient(90deg, #3a2414, #2a1810, #3a2414);
    box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
    z-index: 100;
}

.book-pages {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-spread {
    display: flex;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.page-spread.active {
    opacity: 1;
    pointer-events: all;
}

.page {
    flex: 1;
    background: linear-gradient(to right, #faf8f3 0%, #fff 5%, #fff 95%, #f5f3ee 100%);
    padding: 3rem 2rem;
    box-shadow: 
        0 10px 40px rgba(0,0,0,0.2),
        inset 0 0 30px rgba(139,0,0,0.05);
    position: relative;
    overflow-y: auto;
    border: 1px solid #e8d7c3;
}

.page-left {
    border-right: none;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
    background: linear-gradient(to left, #f5f3ee 0%, #fff 5%, #fff 95%, #faf8f3 100%);
    box-shadow: 
        -5px 0 15px rgba(0,0,0,0.1),
        inset -10px 0 20px rgba(0,0,0,0.05);
}

.page-right {
    border-left: none;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
    box-shadow: 
        5px 0 15px rgba(0,0,0,0.1),
        inset 10px 0 20px rgba(0,0,0,0.05);
}

/* Efecto de páginas previas apiladas */
.page-left::before,
.page-right::after {
    content: '';
    position: absolute;
    top: 5px;
    width: calc(100% - 10px);
    height: calc(100% - 10px);
    background: #f0ebe5;
    z-index: -1;
    border: 1px solid #d8cfc0;
}

.page-left::before {
    left: -5px;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
    box-shadow: -2px 0 5px rgba(0,0,0,0.1);
}

.page-right::after {
    right: -5px;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

/* Contenido de la página - Pizza */
.pizza-page {
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 1rem 0;
}

.pizza-name {
    font-size: 1.8rem;
    color: var(--primary-red);
    font-weight: 700;
    margin: 0 0 1.5rem 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.pizza-image-container {
    width: 280px;
    height: 280px;
    margin: 0 auto 1.5rem auto;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(139,0,0,0.05), rgba(160,0,28,0.05));
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.pizza-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pizza-emoji {
    font-size: 8rem;
    filter: drop-shadow(0 5px 10px rgba(0,0,0,0.2));
}

.pizza-description {
    color: var(--medium-gray);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0 0 1.5rem 0;
    padding: 0 1rem;
    flex-grow: 1;
}

.pizza-prices {
    background: linear-gradient(135deg, rgba(139,0,0,0.08), rgba(160,0,28,0.08));
    padding: 1.2rem;
    border-radius: 10px;
    margin-top: auto;
}

.pizza-prices h4 {
    color: var(--primary-red);
    margin-bottom: 1rem;
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
}

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.7rem 0;
    border-bottom: 1px solid rgba(139,0,0,0.1);
}

.price-row:last-child {
    border-bottom: none;
}

.price-label {
    font-weight: 700;
    color: var(--dark-gray);
    font-size: 1rem;
}

.price-portions {
    display: block;
    font-size: 0.75rem;
    color: var(--medium-gray);
    font-weight: 400;
    margin-top: 0.2rem;
}

.price-value {
    font-weight: 700;
    color: var(--primary-red);
    font-size: 1.2rem;
}

/* Navegación del libro */
.book-navigation {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    align-items: center;
}

.book-nav-btn {
    background: linear-gradient(135deg, var(--primary-red), var(--secondary-red));
    color: white;
    border: none;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(139,0,0,0.3);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.book-nav-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(139,0,0,0.4);
}

.book-nav-btn:disabled {
    background: var(--light-gray);
    color: var(--medium-gray);
    cursor: not-allowed;
    box-shadow: none;
}

.page-indicator {
    font-size: 1.1rem;
    color: var(--dark-gray);
    font-weight: 600;
    padding: 0.5rem 1.5rem;
    background: white;
    border-radius: 25px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

/* Animación de voltear página */
@keyframes pageFlipLeft {
    0% {
        transform: rotateY(0deg);
    }
    100% {
        transform: rotateY(-180deg);
    }
}

@keyframes pageFlipRight {
    0% {
        transform: rotateY(0deg);
    }
    100% {
        transform: rotateY(180deg);
    }
}

.flipping-left {
    animation: pageFlipLeft 0.8s ease-in-out;
}

.flipping-right {
    animation: pageFlipRight 0.8s ease-in-out;
}

/* Responsive */
@media (max-width: 1024px) {
    .page {
        padding: 1.5rem 1rem;
    }

    .pizza-name {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .pizza-image-container {
        width: 220px;
        height: 220px;
        margin-bottom: 1rem;
    }

    .pizza-emoji {
        font-size: 6rem;
    }

    .pizza-description {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }

    .pizza-prices {
        padding: 1rem;
    }

    .price-label {
        font-size: 0.9rem;
    }

    .price-value {
        font-size: 1.1rem;
    }
}

@media (max-width: 768px) {
    .book-modal-content {
        padding: 0.5rem;
        max-width: 100vw;
    }

    .book {
        height: auto;
        min-height: 70vh;
        max-height: none;
    }

    .page {
        padding: 1rem 0.8rem;
        overflow-y: auto;
        max-height: 70vh;
    }

    .pizza-name {
        font-size: 1.2rem;
        margin-bottom: 0.8rem;
    }

    .pizza-image-container {
        width: 180px;
        height: 180px;
        margin-bottom: 0.8rem;
    }

    .pizza-emoji {
        font-size: 5rem;
    }

    .pizza-description {
        font-size: 0.8rem;
        line-height: 1.4;
        margin-bottom: 0.8rem;
        padding: 0 0.5rem;
    }

    .pizza-prices {
        padding: 0.8rem;
    }

    .pizza-prices h4 {
        font-size: 0.9rem;
        margin-bottom: 0.6rem;
    }

    .price-row {
        padding: 0.5rem 0;
    }

    .price-label {
        font-size: 0.85rem;
    }

    .price-portions {
        font-size: 0.7rem;
    }

    .price-value {
        font-size: 1rem;
    }

    .book-nav-btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }

    .book-navigation {
        gap: 1rem;
        margin-top: 1rem;
    }

    .page-indicator {
        font-size: 0.9rem;
        padding: 0.4rem 1rem;
    }

    .book-spine {
        width: 15px;
    }

    /* Hacer que el libro use toda la pantalla en móvil */
    .page-spread {
        flex-direction: column;
    }

    .page-left,
    .page-right {
        width: 100%;
        border-radius: 10px;
        margin: 0.5rem 0;
    }

    .page-left::before,
    .page-right::after {
        display: none;
    }
}

/* Sección de bebidas */
.bebidas-section {
    margin-top: 3rem;
}

.bebidas-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
}

.bebida-card {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    text-align: center;
}

.bebida-emoji {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.bebida-name {
    font-size: 1.2rem;
    color: var(--primary-red);
    font-weight: 700;
    margin: 0.5rem 0;
}

.bebida-price {
    font-size: 1.5rem;
    color: var(--dark-gray);
    font-weight: 700;
}

.bebida-sabores {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--medium-gray);
}

@media (max-width: 768px) {
    .bebidas-grid {
        grid-template-columns: 1fr;
    }
}
