/* Mini Cart Side Drawer Styles */

.cart-drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cart-drawer-overlay.active {
    display: block;
    opacity: 1;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    height: 100%;
    background: #fff;
    z-index: 9999;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    transition: right 0.3s ease;
    display: flex;
    flex-direction: column;
}

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

.cart-drawer-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
}

.cart-drawer-header h2 {
    margin: 0;
    font-size: 1.25rem;
    color: #333;
}

.close-drawer {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    transition: color 0.2s;
}

.close-drawer:hover {
    color: #000;
}

.cart-drawer-items {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.mini-cart-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.mini-cart-img {
    width: 70px;
    height: 70px;
    border-radius: 5px;
    object-fit: cover;
    background: #eee;
}

.mini-cart-details {
    flex: 1;
}

.mini-cart-name {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 5px;
    display: block;
    color: #333;
}

.mini-cart-meta {
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 8px;
}

.mini-cart-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mini-cart-qty {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.mini-cart-qty button {
    background: none;
    border: none;
    padding: 2px 8px;
    cursor: pointer;
    font-weight: bold;
}

.mini-cart-qty span {
    width: 25px;
    text-align: center;
    font-size: 0.9rem;
}

.mini-cart-price {
    font-weight: 700;
    color: var(--primary-purple);
}

.remove-mini-item {
    color: #999;
    cursor: pointer;
    font-size: 0.9rem;
    margin-left: 10px;
}

.remove-mini-item:hover {
    color: #dc3545;
}

.cart-drawer-footer {
    padding: 20px;
    border-top: 1px solid #eee;
    background: #f8f9fa;
}

.drawer-subtotal {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-weight: 700;
    font-size: 1.1rem;
}

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

.btn-view-cart, .btn-checkout {
    text-align: center;
    padding: 12px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-view-cart {
    background: #fff;
    color: var(--text-dark);
    border: 1px solid #ddd;
}

.btn-view-cart:hover {
    background: #eee;
}

.btn-checkout {
    background: var(--purple-gradient);
    color: #fff;
    border: none;
}

.btn-checkout:hover {
    opacity: 0.9;
}

.empty-cart-msg {
    text-align: center;
    padding: 40px 0;
    color: #888;
}

.empty-cart-msg i {
    font-size: 3rem;
    display: block;
    margin-bottom: 15px;
    opacity: 0.3;
}

.empty-cart-msg a {
    color: var(--primary-purple) !important;
}

@media (max-width: 450px) {
    .cart-drawer {
        width: 100%;
        right: -100%;
    }
}
