/* ================= CARRITO LATERAL ================= */

/* Overlay oscuro */
.cart-sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.cart-sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Panel lateral */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 450px;
    height: 100%;
    background-color: var(--nav-top-bg);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.5);
}

.cart-sidebar.active {
    right: 0;
}

/* Header del carrito */
.cart-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    border-bottom: 1px solid #2a2b30;
    background-color: var(--nav-bottom-bg);
}

.cart-sidebar-title {
    font-family: 'Chakra Petch', sans-serif;
    font-size: 20px;
    color: var(--text-white);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.cart-sidebar-title i {
    color: var(--accent-orange);
    font-size: 22px;
}

.cart-sidebar-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 28px;
    cursor: pointer;
    padding: 5px;
    transition: all 0.3s ease;
}

.cart-sidebar-close:hover {
    color: var(--text-white);
    transform: rotate(90deg);
}

/* Contenido scrolleable */
.cart-sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px 30px;
}

.cart-sidebar-content::-webkit-scrollbar {
    width: 8px;
}

.cart-sidebar-content::-webkit-scrollbar-track {
    background: #25262b;
}

.cart-sidebar-content::-webkit-scrollbar-thumb {
    background: #3a3b40;
    border-radius: 4px;
}

.cart-sidebar-content::-webkit-scrollbar-thumb:hover {
    background: #45464c;
}

/* Grupos de marca/submarca */
.cart-group {
    margin-bottom: 25px;
}

.cart-group-header {
    font-family: 'Chakra Petch', sans-serif;
    font-size: 13px;
    color: var(--accent-orange);
        font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid rgba(255, 87, 34, 0.3);
}

/* Items del carrito */
.cart-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    background-color: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
}

.cart-item:hover {
    background-color: rgba(255, 255, 255, 0.04);
}

.cart-item-image {
    width: 80px;
    height: auto;
    max-height: 100px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background-color: rgba(255, 255, 255, 0.03);
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cart-item-name {
    font-family: 'Chakra Petch', sans-serif;
    font-size: 14px;
    color: var(--text-white);
    font-weight: 800;
    line-height: 1.3;
}

.cart-item-meta {
    font-size: 12px;
    color: var(--text-muted);
}

.cart-item-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 10px;
}

.qty-btn {
    background-color: #3a3b40;
    border: none;
    color: var(--text-white);
    width: 28px;
    height: 28px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.qty-btn:hover {
    background-color: var(--accent-orange);
}

.qty-value {
    font-size: 14px;
    color: var(--text-white);
	font-weight: 700;
    min-width: 30px;
    text-align: center;
}

.cart-item-price {
    font-size: 16px;
	font-weight: 700;
    color: var(--accent-orange);
}

.cart-item-remove {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 18px;
    cursor: pointer;
    padding: 5px;
    transition: all 0.3s ease;
}

.cart-item-remove:hover {
    color: #f44336;
    transform: scale(1.2);
}

/* Carrito vacío */
.cart-empty {
    text-align: center;
    padding: 60px 20px;
}

.cart-empty i {
    font-size: 80px;
    color: var(--text-muted);
    opacity: 0.3;
    margin-bottom: 20px;
}

.cart-empty-text {
    font-family: 'Chakra Petch', sans-serif;
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 25px;
}

/* Footer del carrito */
.cart-sidebar-footer {
    padding: 25px 30px;
    border-top: 1px solid #2a2b30;
    background-color: var(--nav-bottom-bg);
}

.cart-sidebar-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
	    font-weight: 700;
    font-size: 20px;
    color: var(--text-white);
}

.cart-total-amount {
    color: var(--accent-orange);
    font-size: 24px;
}

.btn-continue-shopping {
    width: 100%;
    padding: 14px;
    background-color: transparent;
    border: 1px solid var(--text-muted);
    border-radius: 6px;
    color: var(--text-white);
    font-family: 'Chakra Petch', sans-serif;
    font-size: 13px;
        font-weight: 800;
    text-transform: uppercase;
    cursor: pointer;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-continue-shopping:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: var(--text-white);
}

.btn-checkout {
        font-weight: 800;
    width: 100%;
    padding: 14px;
    background-color: var(--accent-orange);
    border: none;
    border-radius: 6px;
    color: var(--text-white) !important;
    font-family: 'Chakra Petch', sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(255, 87, 34, 0.3);
}

.btn-checkout:hover {
    background-color: #ff6b3d;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 87, 34, 0.4);
}

/* Responsive */
@media (max-width: 768px) {
    .cart-sidebar {
        width: 100%;
        right: -100%;
    }
    
    .cart-item-image {
        width: 70px;
        max-height: 90px;
    }
    
    .cart-item-image img {
        max-height: 90px;
    }
}
/* ========================================
   GHOST LOADER INLINE - CARRITO
   ======================================== */

.loading-cart-ghost {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    padding: 60px 20px;
    text-align: center;
    width: 100%;
}

.loading-cart-ghost .ghost-loader-inline {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.loading-cart-ghost .ghost-svg {
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 0 20px rgba(0, 255, 255, 0.5));
    animation: ghostFloatInline 3s ease-in-out infinite;
}

.loading-cart-ghost .ghost-body {
    fill: white;
    opacity: 0.9;
}

.loading-cart-ghost .ghost-eye {
    fill: black;
    animation: eyePulseInline 2s ease-in-out infinite;
    transform-origin: center;
}

.loading-cart-ghost .left-eye {
    animation-delay: 0s;
}

.loading-cart-ghost .right-eye {
    animation-delay: 0.1s;
}

.loading-cart-ghost .ghost-loading-text-inline {
    font-family: 'Chakra Petch', sans-serif;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #00ffff;
    animation: textPulseInline 2s ease-in-out infinite;
}

/* Responsive */
@media (max-width: 768px) {
    .loading-cart-ghost {
        min-height: 200px;
        padding: 40px 20px;
    }
    
    .loading-cart-ghost .ghost-loader-inline {
        width: 60px;
        height: 60px;
    }
    
    .loading-cart-ghost .ghost-loading-text-inline {
        font-size: 12px;
    }
}

/* Animaciones que faltaban */
@keyframes ghostFloatInline {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-15px);
    }
}

@keyframes eyePulseInline {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.3);
    }
}

@keyframes textPulseInline {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}