/* ══════════════════════════════════════
   CARRITO - ESTILOS
══════════════════════════════════════ */

/* Variables CSS */
:root {
    /* Colores principales */
    --primary: #D47544;
    --primary-light: #f5e8e5;
    --primary-glow: rgba(212, 117, 68, 0.2);
    
    /* Fondos y superficies */
    --bg: #0a0908;
    --surface: #1a1916;
    --card: #2a2622;
    --card-hover: #35302a;
    
    /* Bordes y líneas */
    --border: #3a352f;
    
    /* Texto */
    --text: #ffffff;
    --muted: #888888;
    
    /* Bordes redondeados */
    --radius: 12px;
    --radius-sm: 8px;
}

/* Animaciones */
@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Botón Agregar al Carrito */
.btn-add-cart {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-light);
    border: 1px solid var(--primary-glow);
    color: var(--primary);
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
    flex-shrink: 0;
}

.btn-add-cart:hover {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 4px 14px var(--primary-glow);
}

/* ══════════════════════════════════════
   MODAL: AGREGAR AL CARRITO
══════════════════════════════════════ */

.modal-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 9999 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-end !important;
    align-items: center !important;
    overflow-y: auto !important;
    padding: 20px !important;
    animation: slideUp 0.3s ease !important;
    /* Ocultar scrollbar pero permitir scroll */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE y Edge */
}

/* Chrome, Safari y Opera */
.modal-overlay::-webkit-scrollbar {
    display: none;
}

@media (max-width: 768px) {
    .modal-overlay {
        padding: 0 !important;
        align-items: stretch !important;
    }
}

.modal-content {
    background: var(--bg);
    border: 2px solid var(--primary);
    border-bottom: none;
    width: 100%;
    max-width: 500px;
    border-radius: var(--radius) var(--radius) 0 0;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.5), 0 0 24px rgba(212, 119, 58, 0.2);
    animation: slideUp 0.3s ease;
    display: flex;
    flex-direction: column;
    max-height: 85vh;
    min-height: 0;
}

@media (max-width: 768px) {
    .modal-content {
        border: 1px solid var(--border);
        border-bottom: 1px solid var(--border);
        border-radius: 20px 20px 0 0;
        width: 100vw;
        max-width: 100vw;
        box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.3);
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
    }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .modal-header {
        padding: 16px 16px;
    }
}

/* Body lock cuando modal está abierto en mobile */
body.modal-open {
    overflow: hidden;
    height: 100vh;
}

@media (min-width: 769px) {
    body.modal-open {
        overflow: auto;
        height: auto;
    }
}

.modal-header h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: var(--muted);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.2s;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--text);
}

/* Modal Handle - Línea para cerrar en mobile (WhatsApp style) */
.modal-handle {
    display: none;
}

.modal-handle::before {
    content: '';
    position: absolute;
    width: 40px;
    height: 4px;
    background: var(--primary);
    border-radius: 2px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: background 0.2s;
}

.modal-handle:active::before {
    background: var(--primary-light);
}

/* Desktop: ocultar flecha, mostrar línea */
@media (min-width: 769px) {
    .modal-close-arrow {
        display: none;
    }
    .modal-handle {
        display: block;
    }
}

/* Mobile: ocultar flecha, mostrar línea */
@media (max-width: 768px) {
    .modal-close-arrow {
        display: none;
    }
    .modal-handle {
        display: block;
    }
}

.modal-body {
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
    min-height: 0;
}

.product-summary {
    background: var(--card);
    border: 1px solid var(--border);
    padding: 10px 12px;
    border-radius: var(--radius-sm);
}

.product-summary h4 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 4px 0;
}

.product-summary .price {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.55rem;
    color: var(--primary);
    font-weight: 700;
    margin: 0;
    line-height: 1;
}

.product-summary .price sup {
    font-size: 0.7em;
    font-family: 'DM Sans', sans-serif;
    font-weight: 500;
    vertical-align: super;
    margin-right: 1px;
    opacity: 0.8;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 2px;
}

.quantity-control {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 6px;
    width: 100%;
}

.quantity-control button {
    background: var(--primary-light);
    border: 1px solid var(--primary-glow);
    color: var(--primary);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.quantity-control button:hover:not(:disabled) {
    background: var(--primary);
    color: #fff;
}

.quantity-control button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.quantity-control input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text);
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    outline: none;
    font-family: 'DM Sans', sans-serif;
}

/* Ocultar spinners (flechas) del input number en Chrome, Safari, Edge */
.quantity-control input::-webkit-outer-spin-button,
.quantity-control input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Ocultar spinners en Firefox */
.quantity-control input[type="number"] {
    -moz-appearance: textfield;
}

textarea {
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif;
    font-size: 0.8rem;
    resize: vertical;
    outline: none;
    transition: border-color 0.2s;
    width: 100%;
    min-height: 50px;
}

textarea:focus {
    border-color: var(--primary);
}

textarea::placeholder {
    color: var(--muted);
}

.form-group small {
    font-size: 0.65rem;
    color: var(--muted);
    text-align: right;
    margin-top: 1px;
}

.form-section-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin: 4px 0 10px 0;
    padding-top: 6px;
    border-top: 1px solid var(--border);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

@media (max-width: 640px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"] {
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif;
    font-size: 0.8rem;
    outline: none;
    transition: border-color 0.2s;
    width: 100%;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus {
    border-color: var(--primary);
}

input[type="text"]::placeholder,
input[type="email"]::placeholder,
input[type="tel"]::placeholder,
input[type="number"]::placeholder {
    color: var(--muted);
}

input[type="text"]:disabled,
input[type="email"]:disabled,
input[type="tel"]:disabled,
input[type="number"]:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.order-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-weight: 600;
    color: var(--text);
    font-size: 0.8rem;
}

.order-total span:last-child {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.3rem;
    color: var(--primary);
    font-weight: 700;
}

.modal-footer {
    display: flex;
    gap: 10px;
    padding: 14px 20px;
    border-top: 1px solid var(--border);
    background: var(--surface);
    flex-shrink: 0;
    position: sticky;
    bottom: 0;
    z-index: 10;
}

.btn-cancel, .btn-confirm {
    flex: 1;
    padding: 11px 16px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-cancel {
    background: var(--card);
    color: var(--text);
    border: 1px solid var(--border);
}

.btn-cancel:hover {
    background: var(--card-hover);
}

.btn-confirm {
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-confirm:hover:not(:disabled) {
    background: #c06830;
    box-shadow: 0 6px 20px var(--primary-glow);
}

.btn-confirm:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ══════════════════════════════════════
   VISTA: CARRITO
══════════════════════════════════════ */

.container { 
    max-width: 1000px; 
    margin: 0 auto; 
    padding: 20px; 
}

header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10,9,8,0.96);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 14px 0;
}

.header-inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: var(--radius);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-back:hover { 
    background: var(--card-hover); 
    color: var(--text); 
}

.header-label {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.15rem;
    font-weight: 600;
}

.cart-empty {
    text-align: center;
    padding: 60px 20px;
}

.cart-empty-icon {
    font-size: 3rem;
    color: var(--muted);
    margin-bottom: 16px;
}

.cart-empty h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.8rem;
    margin-bottom: 8px;
    color: var(--text);
}

.cart-empty p {
    color: var(--muted);
    margin-bottom: 24px;
}

.btn-shop {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 10px 20px;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.btn-shop:hover { 
    background: #c06830; 
}

.cart-list {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.cart-item {
    display: flex;
    gap: 16px;
    padding: 16px;
    border-bottom: 1px solid var(--border);
    align-items: flex-start;
}

.cart-item:last-child { 
    border-bottom: none; 
}

.cart-item-image {
    width: 80px;
    height: 80px;
    background: var(--surface);
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
    min-width: 0;
}

.cart-item-name {
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text);
}

.cart-item-description {
    font-size: 0.8rem;
    color: var(--muted);
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cart-item-customization {
    font-size: 0.75rem;
    background: var(--surface);
    padding: 6px 10px;
    border-radius: 4px;
    max-height: 40px;
    overflow: hidden;
    color: var(--muted);
    border-left: 2px solid var(--primary);
}

.cart-item-qty {
    text-align: right;
    min-width: 100px;
}

.cart-item-qty p {
    font-size: 0.8rem;
    color: var(--muted);
    margin-bottom: 4px;
}

.cart-item-price {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
}

.cart-summary {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-top: 24px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 0.9rem;
}

.summary-row.total {
    border-top: 1px solid var(--border);
    padding-top: 12px;
    margin-top: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
}

.checkout-section {
    margin-top: 24px;
    display: flex;
    gap: 12px;
}

.btn-checkout {
    flex: 1;
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.9rem;
}

.btn-checkout:hover { 
    background: #c06830; 
}

.btn-continue {
    flex: 1;
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--border);
    padding: 12px 20px;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.9rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-continue:hover { 
    background: var(--card); 
}

/* ══════════════════════════════════════
   CART DRAWER: PANEL LATERAL
══════════════════════════════════════ */

.cart-drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cart-drawer {
    position: fixed;
    background: var(--bg);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* En Desktop: Drawer lateral (derecha) */
@media (min-width: 769px) {
    .cart-drawer {
        top: 0;
        right: 0;
        bottom: 0;
        left: auto;
        width: 400px;
        max-width: 100%;
        max-height: 100vh;
        transform: translateX(100%);
        border-left: 1px solid var(--border);
    }

    .cart-drawer.open {
        transform: translateX(0);
    }

    .cart-drawer-overlay {
        display: block;
        opacity: 0;
        pointer-events: none;
    }

    .cart-drawer.open ~ .cart-drawer-overlay {
        opacity: 1;
        pointer-events: auto;
    }
}

/* En Móvil: Bottom Sheet (desde abajo) */
@media (max-width: 768px) {
    .cart-drawer {
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        width: 100%;
        height: 85vh;
        max-height: 85vh;
        transform: translateY(100%);
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.3);
        border: none;
    }

    .cart-drawer.open {
        transform: translateY(0);
    }

    .cart-drawer-overlay {
        display: block;
        opacity: 0;
        pointer-events: none;
    }

    .cart-drawer.open ~ .cart-drawer-overlay {
        opacity: 1;
        pointer-events: auto;
    }
}

.drawer-header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
    gap: 12px;
    position: relative;
}

@media (max-width: 768px) {
    .drawer-header {
        justify-content: center;
    }
}

.drawer-header h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin: 0;
    flex: 1;
    text-align: center;
}

@media (max-width: 768px) {
    .drawer-header h3 {
        display: none;
    }
}

.btn-close-drawer {
    background: none;
    border: none;
    color: var(--muted);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.2s;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-close-drawer:hover {
    color: var(--text);
}

.btn-back-drawer {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.btn-back-drawer:hover {
    transform: translateX(-3px);
    opacity: 0.8;
}

/* Drawer Handle - Línea para cerrar (WhatsApp style) */
.drawer-handle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

.drawer-handle::before {
    content: '';
    position: absolute;
    width: 40px;
    height: 4px;
    background: var(--primary);
    border-radius: 2px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: background 0.2s;
}

.drawer-handle:active::before {
    background: var(--primary-light);
}

/* Desktop: mostrar flecha, ocultar línea */
@media (min-width: 769px) {
    .btn-back-drawer {
        display: flex;
    }
    .drawer-handle {
        display: none !important;
    }
}

/* Mobile: ocultar flecha, mostrar línea */
@media (max-width: 768px) {
    .btn-back-drawer {
        display: none;
    }
    .drawer-handle {
        display: block;
    }
}

.drawer-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 16px 0;
    display: flex;
    flex-direction: column;
    /* Ocultar scrollbar pero permitir scroll */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE y Edge */
}

/* Chrome, Safari y Opera */
.drawer-body::-webkit-scrollbar {
    display: none;
}

.drawer-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    color: var(--muted);
    text-align: center;
    padding: 40px 20px;
}

.drawer-empty i {
    font-size: 3rem;
    margin-bottom: 12px;
    opacity: 0.5;
}

.drawer-empty p {
    margin: 4px 0;
    font-size: 0.9rem;
}

.empty-hint {
    font-size: 0.8rem !important;
    opacity: 0.6;
}

.drawer-items {
    padding: 0 12px;
}

.drawer-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 10px;
    background: var(--card);
    align-items: flex-start;
}

.drawer-item-img {
    width: 80px;
    height: 80px;
    background: var(--surface);
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
}

.drawer-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.drawer-item-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    justify-content: space-between;
}

.drawer-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
}

.drawer-item-name {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.2;
    margin: 0;
    flex: 1;
}

.drawer-item-qty-badge {
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-align: right;
    white-space: nowrap;
}

.drawer-item-qty-badge small {
    color: var(--muted);
    font-size: 0.7rem;
    font-weight: 500;
}

.drawer-item-qty-badge strong {
    color: var(--text);
    font-weight: 700;
    font-size: 0.85rem;
}

.drawer-item-desc {
    font-size: 0.75rem;
    color: var(--muted);
    line-height: 1.3;
    margin: 0;
}

.drawer-item-custom {
    font-size: 0.75rem;
    background: var(--surface);
    padding: 6px 8px;
    border-radius: 4px;
    color: var(--muted);
    border-left: 2px solid var(--primary);
    line-height: 1.3;
    margin: 0;
}

.drawer-item-info {
    display: flex;
    gap: 12px;
    font-size: 0.8rem;
    margin-top: 2px;
}

.info-qty,
.info-unitario {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.info-qty small,
.info-unitario small {
    color: var(--muted);
    font-size: 0.7rem;
}

.info-qty strong,
.info-unitario strong {
    color: var(--text);
    font-weight: 600;
    font-size: 0.85rem;
}

.drawer-item-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

.drawer-item-footer .info-unitario,
.drawer-item-footer .info-subtotal {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.drawer-item-footer .info-unitario small,
.drawer-item-footer .info-subtotal small {
    color: var(--muted);
    font-size: 0.65rem;
    font-weight: 500;
}

.drawer-item-footer .info-unitario strong {
    font-family: 'Cormorant Garamond', serif;
    color: var(--text);
    font-weight: 700;
    font-size: 1rem;
}

.drawer-item-footer .info-subtotal strong {
    font-family: 'Cormorant Garamond', serif;
    color: var(--primary);
    font-weight: 700;
    font-size: 1.1rem;
}

.drawer-item-price {
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-align: center;
}

.drawer-item-price strong {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
}

.drawer-item-controls {
    display: flex;
    gap: 6px;
    align-items: center;
}

.btn-qty {
    background: var(--primary-light);
    border: 1px solid var(--primary-glow);
    color: var(--primary);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.65rem;
    transition: all 0.2s;
}

.btn-qty:hover:not(:disabled) {
    background: var(--primary);
    color: #fff;
}

.btn-qty:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-remove {
    background: rgba(224, 92, 92, 0.15);
    border: 1px solid rgba(224, 92, 92, 0.25);
    color: #e05c5c;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.65rem;
    transition: all 0.2s;
}

.btn-remove:hover {
    background: #e05c5c;
    color: #fff;
}

.drawer-footer {
    padding: 16px;
    border-top: 1px solid var(--border);
    background: var(--surface);
    flex-shrink: 0;
}

.drawer-summary {
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.summary-line {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    margin-bottom: 6px;
    color: var(--text);
}

.summary-line.total {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
}

.drawer-actions {
    display: flex;
    gap: 10px;
}

.btn-drawer-clear,
.btn-drawer-checkout {
    flex: 1;
    padding: 11px 14px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.btn-drawer-clear {
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--border);
}

.btn-drawer-clear:hover {
    background: var(--card-hover);
    border-color: var(--primary);
}

.btn-drawer-checkout {
    background: var(--primary);
    color: #fff;
}

.btn-drawer-checkout:hover:not(:disabled) {
    background: #c06830;
    box-shadow: 0 4px 12px var(--primary-glow);
}

.btn-drawer-checkout:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ══════════════════════════════════════
   CONFIRMACIÓN DE ORDEN
══════════════════════════════════════ */
.drawer-confirm-order {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex: 1;
    padding: 24px 16px;
    text-align: center;
    animation: slideUp 0.3s ease;
}

.confirm-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 24px;
}

.confirm-header i {
    font-size: 48px;
    color: var(--primary);
    margin-bottom: 12px;
}

.confirm-header h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text);
    margin: 0;
}

.confirm-body {
    margin-bottom: 32px;
    width: 100%;
}

.confirm-items-summary {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px;
    margin-bottom: 16px;
    max-height: 200px;
    overflow-y: auto;
    /* Ocultar scrollbar pero permitir scroll */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE y Edge */
}

/* Chrome, Safari y Opera */
.confirm-items-summary::-webkit-scrollbar {
    display: none;
}

.confirm-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.8rem;
}

.confirm-item:last-child {
    border-bottom: none;
}

.confirm-item-left {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
}

.confirm-item-name {
    color: var(--text);
    font-weight: 500;
    word-break: break-word;
}

.confirm-item-qty {
    color: var(--muted);
    font-size: 0.75rem;
}

.confirm-item-price {
    font-family: 'Cormorant Garamond', serif;
    color: var(--primary);
    font-weight: 700;
    text-align: right;
    white-space: nowrap;
    margin-left: 12px;
    font-size: 1.05rem;
}

.confirm-total {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--card);
    padding: 16px;
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
    border: 1px solid var(--border);
}

.confirm-total span {
    font-size: 0.75rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.confirm-total strong {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.8rem;
    color: var(--primary);
    font-weight: 700;
}

.confirm-text {
    font-size: 0.9rem;
    color: var(--muted);
    margin: 0;
    line-height: 1.4;
}

.confirm-actions {
    display: flex;
    gap: 12px;
    width: 100%;
}

.btn-confirm-no,
.btn-confirm-yes {
    flex: 1;
    padding: 14px 16px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'DM Sans', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.btn-confirm-no {
    background: transparent;
    color: var(--muted);
    border: 1px solid var(--border);
}

.btn-confirm-no:hover {
    background: var(--card-hover);
    border-color: var(--muted);
    color: var(--text);
}

.btn-confirm-yes {
    background: var(--primary);
    color: #fff;
    border: none;
}

.btn-confirm-yes:hover:not(:disabled) {
    background: #c06830;
    box-shadow: 0 4px 12px var(--primary-glow);
}

.btn-confirm-yes:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Botón danger para confirmaciones peligrosas */
.btn-confirm-danger {
    background: var(--primary) !important;
    color: #fff !important;
}

.btn-confirm-danger:hover:not(:disabled) {
    background: #c06830 !important;
    box-shadow: 0 4px 12px var(--primary-glow) !important;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* NOTIFICACIONES MEJORADAS */
@keyframes notificationSlideIn {
    from {
        transform: translateX(400px) translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateX(0) translateY(0);
        opacity: 1;
    }
}

@keyframes notificationSlideOut {
    from {
        transform: translateX(0) translateY(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px) translateY(-20px);
        opacity: 0;
    }
}

@keyframes progressBar {
    from {
        width: 100%;
    }
    to {
        width: 0%;
    }
}

.notification-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 11000;
    pointer-events: none;
    font-family: 'DM Sans', sans-serif;
}

.notification-item {
    background: linear-gradient(135deg, #161310 0%, #1D1914 100%);
    border: 1px solid rgba(212, 119, 58, 0.3);
    border-left: 4px solid var(--primary);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 12px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.7), 0 0 20px rgba(212, 119, 58, 0.1);
    animation: notificationSlideIn 0.4s cubic-bezier(0.22, 0.68, 0, 1.2);
    pointer-events: auto;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    min-width: 300px;
    max-width: 380px;
    position: relative;
    overflow: hidden;
}

.notification-item.fade-out {
    animation: notificationSlideOut 0.4s cubic-bezier(0.22, 0.68, 0, 1.2);
}

.notification-item.fade-out .notification-progress {
    animation: none !important;
    opacity: 0;
}

.notification-item.success {
    border-left-color: #D4773A;
}

.notification-item.error {
    border-left-color: #B8532D;
}

.notification-item.warning {
    border-left-color: #E8956F;
}

.notification-item.info {
    border-left-color: #D4773A;
}

.notification-content {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.notification-icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    flex-shrink: 0;
    background: rgba(212, 119, 58, 0.1);
    border: 1px solid rgba(212, 119, 58, 0.2);
}

.notification-item.success .notification-icon-wrapper {
    background: rgba(212, 119, 58, 0.1);
    border-color: rgba(212, 119, 58, 0.2);
}

.notification-item.error .notification-icon-wrapper {
    background: rgba(184, 83, 45, 0.1);
    border-color: rgba(184, 83, 45, 0.2);
}

.notification-icon-wrapper i {
    font-size: 18px;
    color: var(--primary);
}

.notification-item.success .notification-icon-wrapper i {
    color: #D4773A;
}

.notification-item.error .notification-icon-wrapper i {
    color: #B8532D;
}

.notification-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #f5f0e8;
    margin: 0;
    line-height: 1.3;
    word-break: break-word;
}

.notification-message {
    font-size: 0.85rem;
    color: #888888;
    margin: 0;
    line-height: 1.4;
    word-break: break-word;
}

.notification-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary) 0%, rgba(212, 119, 58, 0.3) 100%);
    animation: progressBar 5.5s linear forwards;
}

.notification-item.success .notification-progress {
    background: linear-gradient(90deg, #D4773A 0%, rgba(212, 119, 58, 0.3) 100%);
}

.notification-item.error .notification-progress {
    background: linear-gradient(90deg, #B8532D 0%, rgba(184, 83, 45, 0.3) 100%);
}

@media (max-width: 480px) {
    .notification-item {
        min-width: auto;
        max-width: calc(100vw - 32px);
        margin-left: 16px;
        margin-right: 16px;
    }
}

/* ══════════════════════════════════════
   BLOQUEAR SCROLL DEL BODY EN MÓVIL
══════════════════════════════════════ */
@media (max-width: 768px) {
    body.cart-drawer-open {
        overflow: hidden;
        height: 100vh;
    }
}
