/* Botão Flutuante */
.mundom-cart-trigger {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #353535 0%, #1d1d1d 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 99998;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: bounceIn 0.6s ease-out;
}

.mundom-cart-trigger:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.mundom-cart-trigger i {
    color: white;
    font-size: 24px;
    transition: transform 0.3s ease;
}

.mundom-cart-trigger:hover i {
    transform: scale(1.1);
}

.mundom-cart-trigger .cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #ff4757;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    animation: pulse 2s infinite;
}

/* Overlay */
.mundom-cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 99998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mundom-cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Menu Principal */
.mundom-sidecart-menu {
    width: 420px;
    background: rgba(31, 32, 32, 0.95);
    backdrop-filter: blur(20px);
    position: fixed;
    right: 0;
    top: 0;
    bottom: 0;
    z-index: 99999;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.mundom-sidecart-menu.active {
    transform: translateX(0);
}

/* Header */
.cart-menu-header {
    padding: 1.5rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
}

.cart-menu-header .cart-menu-title {
    width: 100%;
    display: flex;
    justify-content: center;
}

.cart-menu-header .cart-menu-title h1 {
    display: flex;
    align-items: center;
    margin: 0;
    gap: 1rem;
    color: #fff;
    font-size: 1.4rem;
    text-align: center;
    text-transform: uppercase;
    font-weight: 300;
    letter-spacing: 1px;
}

.cart-menu-header .cart-menu-title h1 i {
    font-size: 2rem;
    color: #cfcfcf;
}

.cart-menu-action {
    position: absolute;
    right: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.cart-menu-action:hover {
    background: rgba(255, 255, 255, 0.1);
}

.cart-menu-action i {
    color: #fff;
    font-size: 1.8rem;
    transition: transform 0.3s ease;
}

.cart-menu-action:hover i {
    transform: rotate(90deg);
}

/* Conteúdo */
.cart-content {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 1rem;
}

/* Loading */
.cart-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: #fff;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

/* Carrinho Vazio */
.cart-empty {
    text-align: center;
    padding: 3rem 2rem;
    color: #fff;
}

.cart-empty .empty-icon i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 1rem;
}

.cart-empty h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    font-weight: 300;
}

.cart-empty p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* Itens do Carrinho */
.cart-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cart-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    transition: all 0.3s ease;
    animation: slideInRight 0.5s ease-out;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
}

.cart-item.removing {
    animation: slideOutRight 0.4s ease-in;
    transform: translateX(100%);
    opacity: 0;
}

.cart-item-image {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cart-item-name {
    color: #fff;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.3;
    margin: 0;
}

.cart-item-price {
    color: #667eea;
    font-size: 1rem;
    font-weight: 600;
}

.cart-item-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.3rem;
}

.quantity-btn {
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    color: #fff;
    cursor: pointer;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 14px;
}

.quantity-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.quantity-input {
    width: 40px;
    text-align: center;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 0.9rem;
    padding: 0.2rem;
}

.remove-btn {
    background: rgba(255, 71, 87, 0.2);
    border: none;
    color: #ff4757;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.remove-btn:hover {
    background: rgba(255, 71, 87, 0.3);
    transform: scale(1.1);
}

/* Rodapé */
.cart-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem 2rem;
    background: rgba(255, 255, 255, 0.05);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.total-label {
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
}

.total-value {
    color: #667eea;
    font-size: 1.3rem;
    font-weight: bold;
}

.cart-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.btn-continue-shopping {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.btn-continue-shopping:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
}

.checkout-actions {
    display: flex;
    gap: 0.8rem;
}

.btn-view-cart,
.btn-checkout {
    flex: 1;
    padding: 0.8rem 1rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.btn-view-cart {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-view-cart:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-checkout {
    background: linear-gradient(135deg, #303030 0%, #1d1d1d 100%);
    color: white;
}

.btn-checkout:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }

    70% {
        transform: scale(0.9);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInRight {
    0% {
        opacity: 0;
        transform: translateX(50px);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideOutRight {
    0% {
        opacity: 1;
        transform: translateX(0);
    }

    100% {
        opacity: 0;
        transform: translateX(100%);
    }
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

/* Responsivo */
@media (max-width: 480px) {
    .mundom-sidecart-menu {
        width: 100%;
        border-left: none;
    }

    .cart-menu-header {
        padding: 1rem 1.5rem;
    }

    .cart-menu-action {
        right: 1rem;
    }

    .cart-content {
        padding: 0.8rem;
    }

    .cart-footer {
        padding: 1rem 1.5rem;
    }

    .mundom-cart-trigger {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
    }

    .checkout-actions {
        flex-direction: column;
    }

    .cart-item {
        padding: 1rem;
    }
}