﻿/* CONTENEDOR */
.pedido-ticket {
    max-width: 600px;
    margin: auto;
    padding: 1rem;
    border-radius: 16px;
    background: var(--rz-base-default);
}

/* HEADER */
.ticket-header {
    text-align: center;
    margin-bottom: 1rem;
}

    .ticket-header h2 {
        font-weight: 800;
    }

/* META */
.ticket-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .6rem;
    font-size: .85rem;
    color: var(--rz-text-secondary-color);
}

    /* ESTADO */
    .ticket-meta .estado {
        font-weight: bold;
        color: var(--rz-primary);
    }

/* LISTA */
.ticket-body {
    display: flex;
    flex-direction: column;
    gap: .6rem;
}

/* ITEM */
.ticket-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    padding: .6rem .8rem;
    border-radius: 12px;
    background: var(--rz-base);
    border: 1px solid rgba(var(--rz-base-contrast-rgb), .08);

    transition: transform .18s ease, box-shadow .18s ease, background .2s ease;
}

    .ticket-item:hover {
        transform: translateY(-3px) scale(1.01);
        box-shadow: 0 10px 25px rgba(0,0,0,.12);
    }
        .ticket-item:hover .producto {
            color: var(--rz-info-dark);
        }
html.dark .ticket-item:hover,
.rz-dark .ticket-item:hover {
    box-shadow: 0 10px 25px rgba(0,0,0,.4);
}

.modo-cocina .ticket-item {
    animation: subtleFloat 6s ease-in-out infinite;
}

@keyframes subtleFloat {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-2px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* CANTIDAD */
.cantidad {
    background: var(--rz-info-dark);
    color: white;
    padding: .2rem .6rem;
    border-radius: 8px;
    font-weight: bold;
}

/* PRODUCTO */
.producto {
    font-weight: 600;
}

/* NOTA */
.nota {
    display: block;
    font-size: .80rem;
    color: var(--rz-warning-dark);
    font-weight: bold;
    border-left: 3px solid var(--rz-warning);
    padding-left: 8px;
    margin-top: 4px;
}

.badge-nuevo {
    background-color: var(--rz-danger); /* Rojo o Naranja para captar atención */
    color: white;
    font-size: 0.90rem;
    font-weight: 900;
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
    animation: pulse-red 2s infinite; /* Opcional: un pulso sutil */
    vertical-align: middle;
    line-height: 1;
    display: inline-flex;
    align-items: center;
}

@keyframes pulse-red {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 45, 85, 0.7);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(255, 45, 85, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(255, 45, 85, 0);
    }
}

/* TOTAL ITEM */
.item-right {
    font-weight: bold;
    color: var(--rz-success);
}

/* TOTAL GENERAL */
.ticket-total {
    margin-top: 1rem;
    padding-top: .5rem;
    border-top: 1px dashed rgba(var(--rz-base-contrast-rgb), .2);
    text-align: right;
    font-size: 1.2rem;
    font-weight: 800;
}

/* ACCIONES */
.ticket-actions {
    margin-top: 1rem;
    text-align: center;
}
/* ========================= */
/* MODO COCINA */
/* ========================= */
.pedido-ticket.modo-cocina {
    max-width: 900px;
    font-size: 1.2rem;
}

/* HEADER MÁS GRANDE */
.modo-cocina .ticket-header h2 {
    font-size: 2rem;
}

/* META */
.modo-cocina .ticket-meta {
    font-size: 1rem;
    gap: 1rem;
}

/* ITEMS */
.modo-cocina .ticket-item {
    padding: 1rem;
    border-radius: 16px;
}

/* PRODUCTO */
.modo-cocina .producto {
    font-size: 1.3rem;
    font-weight: 700;
}

/* CANTIDAD */
.modo-cocina .cantidad {
    font-size: 1.4rem;
}

/* TOTAL ITEM */
.modo-cocina .item-right {
    font-size: 1.2rem;
}

/* TOTAL GENERAL */
.modo-cocina .ticket-total {
    font-size: 1.5rem;
}

.ticket-item.nuevo {
    animation: fadeSlideIn .3s ease;
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.ticket-item.updated {
    animation: pulseSoft .25s ease;
}

@keyframes pulseSoft {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.04);
    }

    100% {
        transform: scale(1);
    }
}

.ticket-item.destacado {
    border-left: 5px solid var(--rz-warning);
    background: rgba(var(--rz-warning-rgb), .08);
}