/* =========================================================================
   ESTILOS: Carrito Escáner QR, Checkout Mercado Pago y Portal de Clientes
   Proyecto: Catálogo Digital Maipú (digital-maipu <-> maipu)
   ========================================================================= */

/* -------------------------------------------------------------
   0. Visibilidad de Mi Cuenta y Carrito en Cabezote (Desktop vs Móvil)
   ------------------------------------------------------------- */
@media (min-width: 992px) {
    #ultimaColumna,
    header #ultimaColumna {
        display: flex !important;
        align-items: center;
        justify-content: flex-end;
        gap: 18px;
        padding-top: 15px;
    }
    #ultimaColumna #carritoCompras {
        display: inline-flex !important;
        position: relative;
        cursor: pointer !important;
        color: #303030;
    }
    #ultimaColumna #miCuenta {
        display: inline-flex !important;
        align-items: center;
        color: #303030;
        text-decoration: none !important;
    }
    #ultimaColumna #miCuenta i {
        font-size: 50px !important; /* +40% de tamaño */
        line-height: 1 !important;
    }
    #miCuenta .mi-cuenta-label {
        display: inline !important;
        font-size: 14px;
        margin-left: 8px;
    }
}

@media (max-width: 991px) {
    header #cabezote {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px !important;
        padding: 0 6px !important;
    }

    header #logotipo {
        flex: 0 0 auto !important;
        width: auto !important;
        max-width: 30% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    /* Columna intermedia contenedora del buscador */
    header #cabezote > div:nth-child(2) {
        flex: 1 1 auto !important;
        width: auto !important;
        min-width: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    /* Input de búsqueda en móvil y tablet con altura fija para simetría */
    header #buscador {
        margin: 0 !important;
        width: 100% !important;
    }

    header #buscador input {
        height: 46px !important;
        line-height: 46px !important;
        border-radius: 8px !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        box-sizing: border-box !important;
    }

    #ultimaColumna,
    header #ultimaColumna {
        flex: 0 0 auto !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: auto !important;
        height: auto !important;
        padding: 0 0 0 6px !important;
        margin: 0 !important;
    }

    /* Icono de Mi Cuenta limpio (sin recuadro, solo el icono) */
    #miCuenta,
    header #miCuenta {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        color: #344488 !important;
        text-decoration: none !important;
        padding: 0 !important;
        margin: 0 !important;
        width: auto !important;
        height: auto !important;
        min-width: 0 !important;
        min-height: 0 !important;
        transition: color 0.2s ease, transform 0.2s ease;
    }

    #miCuenta:hover,
    #miCuenta:active {
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
        color: #0284c7 !important;
        transform: scale(1.08);
    }

    #miCuenta i {
        font-size: 45px !important; /* +40% de tamaño (45px) */
        line-height: 1 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    #miCuenta .mi-cuenta-label {
        display: none !important; /* Oculta la etiqueta de texto en móviles y tablets */
    }

    #ultimaColumna #carritoCompras,
    header #ultimaColumna #carritoCompras {
        display: none !important; /* En móvil el carrito está en la barra inferior */
    }
}

.menuBarraSuperior ul li a#btnTopBarCompartir,
.menuBarraSuperior ul li a#btnTopBarCopiar {
    cursor: pointer;
    transition: color 0.2s;
}

.menuBarraSuperior ul li a#btnTopBarCompartir:hover,
.menuBarraSuperior ul li a#btnTopBarCopiar:hover {
    color: #38bdf8;
}

/* Botón Agregar al Carrito en Ficha de Producto (PDP) */
.pdp-purchase-actions-wrap {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.btn-agregar-carrito-pdp {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #0284c7;
    color: #ffffff !important;
    font-size: 15px;
    font-weight: 700;
    padding: 13px 20px;
    border: none;
    border-radius: 8px;
    text-decoration: none !important;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
    transition: all 0.2s ease;
    width: 100%;
}

.btn-agregar-carrito-pdp:hover {
    background: #0369a1;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(2, 132, 199, 0.45);
}

.btn-agregar-carrito-pdp i {
    font-size: 19px;
}

#carritoCompras {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer !important;
}

#carritoBadgeCount {
    position: absolute;
    top: -9px;
    right: -13px;
    background: #e11d48;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    min-width: 20px;
    height: 20px;
    line-height: 20px;
    padding: 0 5px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(225, 29, 72, 0.4);
    transition: transform 0.2s ease;
}

#carritoBadgeCount.anim-bump {
    transform: scale(1.35);
}

.scanner-header-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #0284c7;
    color: #ffffff !important;
    padding: 7px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none !important;
    margin-right: 12px;
    box-shadow: 0 2px 6px rgba(2, 132, 199, 0.35);
    transition: all 0.2s ease;
}

.scanner-header-btn:hover {
    background: #0369a1;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(2, 132, 199, 0.45);
}

/* -------------------------------------------------------------
   1. BARRA INFERIOR MÓVIL (Solo en Móviles y Tablets < 992px)
   ------------------------------------------------------------- */
@media (max-width: 991px) {
    body {
        padding-bottom: 75px !important;
    }

    .dm-bottom-nav {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: 60px;
        background: #ffffff;
        border-top: 1px solid #e2e8f0;
        display: flex !important;
        justify-content: space-around;
        align-items: center;
        z-index: 1050;
        box-shadow: 0 -3px 12px rgba(0, 0, 0, 0.07);
        padding: 0 4px;
        box-sizing: border-box;
    }

    .dm-nav-scan {
        display: flex !important;
    }

    #wp {
        bottom: 74px !important;
    }

    .dm-scroll-top-btn {
        bottom: 74px !important;
    }
}

/* En Computadoras de Escritorio (>= 992px): La barra flotante DESAPARECE */
@media (min-width: 992px) {
    .dm-bottom-nav {
        display: none !important;
    }

    body {
        padding-bottom: 0 !important;
    }

    #wp {
        bottom: 20px !important;
    }

    .dm-scroll-top-btn {
        bottom: 20px !important;
    }
}

#wp,
#wp i,
#icono-whatsapp {
    cursor: pointer !important;
}

#wp #icono-whatsapp {
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.18));
    transition: all 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#wp:hover #icono-whatsapp {
    filter: drop-shadow(0 8px 22px rgba(37, 211, 102, 0.75)) drop-shadow(0 2px 6px rgba(37, 211, 102, 0.45));
    transform: scale(1.12) translateY(-4px);
    color: #1ebe57 !important;
}

#wp:active #icono-whatsapp {
    transform: scale(0.95) translateY(0);
}

.dm-scroll-top-btn {
    width: 60px !important;
    height: 60px !important;
    font-size: 22px !important;
}

.dm-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #475569;
    font-size: 10.5px;
    font-weight: 600;
    text-decoration: none !important;
    cursor: pointer;
    position: relative;
    padding: 3px 6px;
    min-width: 48px;
    transition: color 0.2s, transform 0.2s;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.dm-nav-item i {
    font-size: 19px;
    line-height: 1;
    margin-bottom: 2px;
}

.dm-nav-item span {
    font-size: 10.5px;
    font-weight: 600;
    line-height: 1;
    display: block;
}

.dm-nav-item:hover,
.dm-nav-item.active {
    color: #0284c7;
    background: transparent;
}

.dm-nav-item:active {
    transform: scale(0.92);
}

/* Ítem Especial: Escanear (Acción destacada circular con texto) */
.dm-nav-scan {
    color: #0284c7;
    background: transparent !important;
}

.dm-scan-icon-wrap {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(2, 132, 199, 0.4);
    margin-top: -10px;
    margin-bottom: 2px;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s;
}

.dm-scan-icon-wrap i {
    font-size: 19px;
    color: #ffffff !important;
    margin: 0;
}

.dm-nav-scan:hover .dm-scan-icon-wrap {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(2, 132, 199, 0.55);
}

/* Ítem Carrito con Badge Contador */
.dm-nav-cart-icon-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.dm-nav-cart-icon-wrap i {
    font-size: 19px;
    line-height: 1;
    margin-bottom: 2px;
}

.dm-nav-item .dm-cart-badge {
    position: absolute;
    top: -9px;
    right: -13px;
    background: #e11d48;
    color: #ffffff;
    font-size: 10px;
    font-weight: 700;
    min-width: 17px;
    height: 17px;
    line-height: 17px;
    border-radius: 9px;
    text-align: center;
    padding: 0 4px;
    box-shadow: 0 2px 5px rgba(225, 29, 72, 0.4);
    transition: transform 0.2s ease;
}

.dm-cart-badge.anim-bump {
    transform: scale(1.35);
}

.btn-scanner-flotante i {
    font-size: 20px;
}

.btn-scanner-flotante:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 22px rgba(2, 132, 199, 0.6);
}

.btn-scanner-flotante:active {
    transform: scale(0.95);
}

@media (max-width: 767px) {
    #btnFlotanteScanner {
        bottom: 20px;
        right: 16px;
    }
    .btn-scanner-flotante {
        padding: 12px 18px;
        font-size: 14px;
    }
}

/* -------------------------------------------------------------
   2. Visor de Cámara para Escaneo QR
   ------------------------------------------------------------- */
.scanner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.94);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scanner-container {
    width: 100%;
    max-width: 480px;
    height: 100%;
    max-height: 850px;
    display: flex;
    flex-direction: column;
    position: relative;
    background: #000000;
}

.scanner-header {
    height: 58px;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    color: #ffffff;
    z-index: 10;
}

.scanner-title {
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.scanner-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-scanner-control, .btn-scanner-close {
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #ffffff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    transition: background 0.2s;
}

.btn-scanner-control:hover, .btn-scanner-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.scanner-viewport-wrap {
    flex: 1;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #090d16;
}

#qrReaderViewport {
    width: 100% !important;
    height: 100% !important;
}

#qrReaderViewport video {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

/* Mira / Retícula animada */
.scanner-reticle {
    position: absolute;
    width: 250px;
    height: 250px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 18px;
    box-shadow: 0 0 0 4000px rgba(0, 0, 0, 0.55);
    pointer-events: none;
    overflow: hidden;
}

.scanner-laser {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, rgba(2, 132, 199, 0) 0%, #38bdf8 50%, rgba(2, 132, 199, 0) 100%);
    box-shadow: 0 0 10px #38bdf8;
    animation: laserMove 2s infinite ease-in-out alternate;
}

@keyframes laserMove {
    0% { top: 4%; }
    100% { top: 96%; }
}

.scanner-corner {
    position: absolute;
    width: 22px;
    height: 22px;
    border-color: #38bdf8;
    border-style: solid;
}

.scanner-corner.top-left { top: -2px; left: -2px; border-width: 4px 0 0 4px; border-top-left-radius: 16px; }
.scanner-corner.top-right { top: -2px; right: -2px; border-width: 4px 4px 0 0; border-top-right-radius: 16px; }
.scanner-corner.bottom-left { bottom: -2px; left: -2px; border-width: 0 0 4px 4px; border-bottom-left-radius: 16px; }
.scanner-corner.bottom-right { bottom: -2px; right: -2px; border-width: 0 4px 4px 0; border-bottom-right-radius: 16px; }

.scanner-footer-hint {
    background: rgba(15, 23, 42, 0.9);
    padding: 14px 16px;
    color: #cbd5e1;
    font-size: 13.5px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.scanner-footer-hint p { margin: 0; }

/* -------------------------------------------------------------
   3. Bottom Sheet (Tarjeta Rápida de Producto)
   ------------------------------------------------------------- */
.bottom-sheet {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 10001;
    display: flex;
    justify-content: center;
    pointer-events: none;
}

.bottom-sheet-content {
    pointer-events: auto;
    width: 100%;
    max-width: 520px;
    background: #ffffff;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    padding: 16px 20px 24px;
    box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.28);
    position: relative;
    animation: slideUpSheet 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideUpSheet {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.bottom-sheet-handle {
    width: 44px;
    height: 5px;
    background: #cbd5e1;
    border-radius: 3px;
    margin: 0 auto 12px;
}

.btn-close-sheet {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 26px;
    color: #64748b;
    cursor: pointer;
    line-height: 1;
}

.bs-product-header {
    display: flex;
    gap: 16px;
    align-items: center;
}

.bs-product-img-wrap {
    width: 84px;
    height: 84px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.bs-product-img-wrap img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.bs-product-info {
    flex: 1;
    min-width: 0;
}

.bs-brand {
    font-size: 11.5px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.bs-title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin: 2px 0 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bs-price-wrap {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.bs-price-label {
    font-size: 12px;
    color: #64748b;
}

.bs-price-val {
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
}

.bs-qty-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #f1f5f9;
}

.bs-qty-label {
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin: 0;
}

.bs-qty-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #f1f5f9;
    padding: 4px 6px;
    border-radius: 12px;
}

.btn-bs-qty {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: none;
    background: #ffffff;
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    cursor: pointer;
}

.btn-bs-qty:active {
    background: #e2e8f0;
}

.bs-qty-controls input {
    width: 40px;
    text-align: center;
    border: none;
    background: transparent;
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
}

.bs-actions-row {
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-bs-add-cart {
    background: #0284c7;
    color: #ffffff;
    border: none;
    border-radius: 12px;
    padding: 13px;
    font-size: 15.5px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
    transition: background 0.2s;
}

.btn-bs-add-cart:hover {
    background: #0369a1;
}

.btn-bs-view-detail {
    text-align: center;
    font-size: 13px;
    color: #64748b;
    text-decoration: underline;
    cursor: pointer;
}

/* -------------------------------------------------------------
   4. Drawer Lateral del Carrito (Offcanvas)
   ------------------------------------------------------------- */
.drawer-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.6);
    z-index: 10001;
    backdrop-filter: blur(2px);
}

.drawer-cart {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    max-width: 420px;
    height: 100vh;
    height: 100dvh;
    background: #ffffff;
    z-index: 10002;
    box-shadow: -6px 0 25px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    animation: drawerSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes drawerSlideIn {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

.drawer-header {
    height: 64px;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e2e8f0;
}

.drawer-title {
    font-size: 17px;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.badge-count {
    background: #0284c7;
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    border-radius: 12px;
    padding: 2px 8px;
}

.btn-close-drawer {
    background: none;
    border: none;
    font-size: 18px;
    color: #64748b;
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
}

.btn-close-drawer:hover {
    background: #f1f5f9;
}

.drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
}

.cart-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
}

.cart-empty-state i {
    font-size: 54px;
    display: block;
    margin-bottom: 12px;
    opacity: 0.7;
}

.cart-empty-state p {
    font-size: 16px;
    font-weight: 700;
    color: #475569;
    margin-bottom: 4px;
}

.cart-items-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cart-item-card {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 10px 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.cart-item-img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    background: #ffffff;
    border: 1px solid #edf2f7;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-img img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.cart-item-info {
    flex: 1;
    min-width: 0;
}

.cart-item-title {
    font-size: 13.5px;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-price {
    font-size: 14px;
    font-weight: 700;
    color: #0284c7;
}

.cart-item-qty-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
}

.btn-item-qty {
    width: 24px;
    height: 24px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
    color: #334155;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.item-qty-val {
    font-size: 13px;
    font-weight: 700;
    color: #0f172a;
    min-width: 18px;
    text-align: center;
}

.btn-item-remove {
    background: none;
    border: none;
    color: #ef4444 !important; /* Rojo visible siempre */
    cursor: pointer;
    padding: 6px;
    font-size: 18px;
    transition: all 0.2s ease;
}

.btn-item-remove:hover {
    color: #b91c1c !important;
    transform: scale(1.18);
}

/* Banner de alerta rojo dentro del drawer del carrito */
.cart-drawer-alert {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
    font-size: 13px;
    font-weight: 600;
    padding: 9px 12px;
    border-radius: 10px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.08);
    animation: fadeInAlert 0.25s ease;
}

.cart-drawer-alert i {
    font-size: 16px;
    color: #ef4444;
}

@keyframes fadeInAlert {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

.drawer-footer {
    padding: 16px 20px;
    border-top: 1px solid #e2e8f0;
    background: #ffffff;
}

.drawer-total-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.total-label {
    font-size: 15px;
    font-weight: 600;
    color: #64748b;
}

.total-amount {
    font-size: 22px;
    font-weight: 800;
    color: #0f172a;
}

.drawer-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.btn-drawer-checkout {
    background: #10b981;
    color: #ffffff;
    border: none;
    border-radius: 12px;
    padding: 14px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
    transition: background 0.2s;
}

.btn-drawer-checkout:hover {
    background: #059669;
}

.btn-drawer-scan-more {
    background: #f1f5f9;
    color: #334155;
    border: none;
    border-radius: 12px;
    padding: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-drawer-keep-shopping {
    background: #f1f5f9;
    color: #334155;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: background 0.2s;
}

.btn-drawer-keep-shopping:hover {
    background: #e2e8f0;
}

@media (min-width: 992px) {
    #btnDrawerSeguirEscaneando,
    .btn-drawer-scan-more {
        display: none !important;
    }
}

/* -------------------------------------------------------------
   5. Modal de Checkout en Salón
   ------------------------------------------------------------- */
.checkout-modal-content {
    border-radius: 20px;
    overflow: hidden;
    border: none;
}

.checkout-modal-header {
    background: #0284c7;
    color: #ffffff;
    padding: 16px 20px;
}

.checkout-modal-header .close {
    color: #ffffff;
    opacity: 0.9;
    font-size: 24px;
}

.checkout-summary-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.checkout-summary-box strong {
    font-size: 20px;
    color: #0284c7;
}

.checkout-section-title {
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 16px 0 12px;
}

.section-step {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #0284c7;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.payment-methods-selector {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 14px;
}

.payment-method-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.payment-method-card:hover {
    border-color: #93c5fd;
    background: #f8fafc;
}

.payment-method-card.active {
    border-color: #0284c7;
    background: #f0f9ff;
}

.copy-field-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.btn-copy {
    border-radius: 6px;
    font-weight: 600;
}

.btn-mp-open {
    background: #009ee3;
    color: #ffffff;
    font-weight: 700;
    border-radius: 10px;
    padding: 10px;
    margin: 10px 0;
}

.btn-mp-open:hover {
    background: #0087c2;
    color: #ffffff;
}

/* -------------------------------------------------------------
   6. Modal de Éxito
   ------------------------------------------------------------- */
.modal-exito-content {
    border-radius: 20px;
    padding: 10px;
}

.exito-icon-wrap i {
    font-size: 64px;
}

.exito-title {
    font-size: 22px;
    font-weight: 800;
    color: #0f172a;
    margin-top: 8px;
}

.exito-orden-badge {
    display: inline-block;
    background: #f1f5f9;
    border: 2px dashed #0284c7;
    color: #0284c7;
    font-size: 18px;
    font-weight: 800;
    padding: 6px 16px;
    border-radius: 12px;
    margin: 8px 0;
}

.exito-instrucciones {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 13px;
    color: #475569;
    margin-top: 12px;
    text-align: left;
}

/* -------------------------------------------------------------
   7. Portal "Mi Cuenta" y Órdenes
   ------------------------------------------------------------- */
.portal-modal-content {
    border-radius: 20px;
    overflow: hidden;
}

.portal-modal-header {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 12px 16px;
}

.portal-nav-tabs {
    margin: 0;
}

.portal-nav-tabs > li > a {
    border-radius: 10px;
    font-weight: 600;
    color: #64748b;
}

.portal-nav-tabs > li.active > a, .portal-nav-tabs > li.active > a:focus, .portal-nav-tabs > li.active > a:hover {
    background: #0284c7;
    color: #ffffff;
}

.portal-user-welcome {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f8fafc;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.portal-orders-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 480px;
    overflow-y: auto;
}

.portal-order-card {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 14px;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.portal-order-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.portal-order-id {
    font-weight: 700;
    color: #0f172a;
    font-size: 15px;
}

.order-badge-status {
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
}

.order-badge-por-pagar { background: #fef3c7; color: #92400e; }
.order-badge-validada { background: #d1fae5; color: #065f46; }
.order-badge-entregada { background: #e0f2fe; color: #075985; }

/* -------------------------------------------------------------
   8. Modal SweetAlert2 Confirmación Eliminar (Estilo Revendedores)
   ------------------------------------------------------------- */
.dm-swal-drawer-popup {
    border-radius: 20px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 15px 40px rgba(15, 23, 42, 0.35) !important;
    font-family: 'Poppins', sans-serif !important;
}

.dm-swal-drawer-popup .swal2-title {
    font-size: 19px !important;
    font-weight: 800 !important;
    color: #0f172a !important;
    padding-top: 10px !important;
}

.dm-swal-drawer-popup .swal2-icon.swal2-warning {
    border-color: #f59e0b !important;
    color: #f59e0b !important;
}

.dm-swal-drawer-popup .swal2-actions {
    margin-top: 14px !important;
    gap: 10px !important;
}

.dm-swal-drawer-popup .swal2-confirm {
    background-color: #ef4444 !important;
    border-radius: 10px !important;
    font-weight: 700 !important;
    font-size: 13.5px !important;
    padding: 10px 18px !important;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3) !important;
}

.dm-swal-drawer-popup .swal2-cancel {
    background-color: #94a3b8 !important;
    border-radius: 10px !important;
    font-weight: 700 !important;
    font-size: 13.5px !important;
    padding: 10px 18px !important;
}
