.cart-overlay {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    display: flex;
    justify-content: flex-end;
    transition: opacity 0.3s ease;
}

.cart-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.sidecart {
    position: relative;
    width: 400px;
    height: 100vh;
    background: #fff;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.cart-overlay.active .sidecart {
    transform: translateX(0);
}

.sidecart__header {
    padding: 24px;
    border-bottom: 1px solid #f5f5f5;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
}

.sidecart__title {
    margin: 0;
    font-size: 20px;
    font-weight: 500;
    color: #333;
}

.sidecart .cart-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.sidecart .cart-close:hover {
    color: #333;
}

.sidecart .cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    background: #fff;
}

.sidecart .cart-item {
    display: flex;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid #f5f5f5;
    position: relative;
}

.sidecart .cart-item__image {
    width: 120px;
    height: 120px;
    margin-right: 16px;
    border-radius: 4px;
    overflow: hidden;
    background: #f9f9f9;
}

.sidecart .cart-item__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidecart .cart-item__content {
    flex: 1;
    min-width: 0;
}

.sidecart .cart-item__title {
    margin: 0 0 4px 0;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidecart .cart-item__subtitle {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
}

.sidecart .cart-item__price {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-top: 8px;
}

.sidecart .cart-item__quantity {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sidecart .quantity-btn {
    width: 28px;
    height: 28px;
    border: 1px solid #e0e0e0;
    background: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    color: #666;
    font-size: 16px;
    transition: all 0.2s ease;
}

.sidecart .quantity-btn:hover {
    background: #f5f5f5;
}

.sidecart .quantity-input {
    width: 40px;
    height: 28px;
    text-align: center;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 14px;
    color: #333;
}

.sidecart .cart-item__remove {
    position: absolute;
    top: 16px;
    right: 0;
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 8px;
    font-size: 14px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.sidecart .cart-item__remove:hover {
    color: #ff4444;
    background-color: rgba(255, 68, 68, 0.1);
}

.sidecart__footer {
    padding: 24px;
    border-top: 1px solid #f5f5f5;
    background: #fff;
}

.sidecart .cart-coupon {
    margin-bottom: 16px;
    position: relative;
    display: flex;
    gap: 8px;
}

.sidecart .cart-coupon input {
    flex: 1;
    padding: 12px 12px 12px 40px;
    border: 1px solid #e0e0e0;
    font-size: 14px;
    transition: all 0.2s ease;
}

.sidecart .cart-coupon input:focus {
    outline: none;
    border-color: #333;
}

.sidecart .cart-coupon input::placeholder {
    color: #999;
}

.sidecart .cart-coupon::before {
    content: '\f3ff';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 16px;
    z-index: 1;
}

.sidecart .applied-coupon {
    padding: 10px;
    margin: 10px 0;
    border-radius: 4px;
    font-size: 14px;
}

.sidecart .applied-coupon__code {
    background: linear-gradient(135deg, #e1e1e1, #efefef);
    color: #1c1c1c;
    text-align: center;
    padding: 8px 13px;
    border-radius: 6px;
    position: relative;
    display: flex;
    align-items: center;
    gap: 2px;
    line-height: 0;
    font-size: 12px;
}

.sidecart .remove-coupon {
    background: none;
    border: none;
    padding: 0;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    font-size: 12px;
    transition: color 0.2s ease;
}

.sidecart .remove-coupon:hover {
    color: #ff4444;
}

.sidecart .circle1, .sidecart .circle2{
    background: #fff;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

.sidecart .circle1{
    left: -5px;
}
.sidecart .circle2{
    right: -5px;
}

.sidecart .coupon-discount {
    color: #28a745;
    font-size: 13px;
}

.sidecart .cart-subtotal,
.sidecart .cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 14px;
    color: #666;
    padding: 0 10px;
}

.sidecart .cart-total {
    margin: 6px 0;
    font-size: 16px;
    font-weight: 500;
    color: #333;
}

.sidecart .apply-coupon-btn {
    padding: 12px 24px;
    background: #333;
    border: none;
    cursor: pointer;
    font-size: 12px;
    color: #fff;
    transition: all 0.2s ease;
    white-space: nowrap;
    text-transform: uppercase;
}

.sidecart .apply-coupon-btn:hover {
    background: #000;
}

.sidecart .cart-buttons {
    margin-top: 16px;
}

.sidecart .checkout {
    display: block;
    width: 100%;
    padding: 14px;
    background: #333;
    color: #fff!important;
    text-align: center;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    text-transform: uppercase;
    font-weight: 300;
}

.sidecart .checkout:hover {
    background: #000;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

@media (max-width: 480px) {
    .sidecart {
        width: 100%;
    }
}

.sidecart .cart-discount {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 10px;
    border-bottom: 1px solid var(--border-color);
    color: #28a745;
    font-weight: 500;
    font-weight: 300;
    font-size: 14px;
    background: #ebfff2;
    
}

.empty-cart {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    width: 100%;
    border-radius: 10px;
    padding: 20px;
}