/* ==================== SONOS-STYLE CART ==================== */

/* CRITICAL: Force image sizes */
.cart-item img.cart-item-image,
.cart-items .cart-item img,
div.cart-item > img.cart-item-image {
    width: 100px !important;
    height: 100px !important;
    min-width: 100px !important;
    min-height: 100px !important;
    max-width: 100px !important;
    max-height: 100px !important;
    object-fit: cover !important;
    display: block !important;
}

/* CHASY.KG Cart - Sonos Style (No +/- Buttons) - Mobile Friendly */

/* Container */
.cart-container {
    max-width: 1200px;
    margin: 100px auto 60px;
    padding: 0 20px;
}

/* Content Layout */
.cart-content {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 40px;
    align-items: start;
}

/* Cart Items */
.cart-items {
    display: flex;
    flex-direction: column;
    gap: 1px;
    background: #e5e5e5;
}

/* Cart Item - ONE LINE */
.cart-item {
    background: #ffffff;
    padding: 20px 24px;
    display: grid;
    grid-template-columns: 100px 1fr auto auto auto;
    gap: 24px;
    align-items: center;
}

/* Image */
.cart-item-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 4px;
}

/* Info */
.cart-item-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cart-item-brand {
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #666666;
}

.cart-item-name {
    font-size: 16px;
    font-weight: 400;
    color: #000000;
    margin: 0;
    line-height: 1.3;
}

/* Price */
.cart-item-price {
    font-size: 16px;
    font-weight: 400;
    color: #000000;
    text-align: right;
    min-width: 120px;
}

/* Quantity - JUST NUMBER */
.cart-item-quantity {
    font-size: 24px;
    font-weight: 400;
    color: #000000;
    text-align: center;
    min-width: 40px;
}

/* Remove Button */
.cart-item-remove {
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    color: #666666;
    font-size: 18px;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item-remove:hover {
    background: #f5f5f5;
    color: #000000;
}

/* Summary */
.cart-summary {
    position: sticky;
    top: 100px;
}

.summary-card {
    background: #ffffff;
    padding: 32px;
    border-radius: 0;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    font-size: 15px;
    color: #666666;
}

.summary-row span:last-child {
    color: #000000;
    font-weight: 400;
}

.summary-divider {
    height: 1px;
    background: #e5e5e5;
    margin: 16px 0;
}

.summary-total {
    font-size: 18px;
    font-weight: 500;
    color: #000000;
}

.summary-total span {
    color: #000000;
}

/* Buttons */
.checkout-btn {
    width: 100%;
    padding: 16px;
    margin-top: 24px;
    background: #000000;
    color: #ffffff;
    border: none;
    border-radius: 0;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    display: block;
    text-align: center;
    transition: opacity 0.2s;
}

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

.clear-btn {
    width: 100%;
    padding: 14px;
    margin-top: 12px;
    background: transparent;
    color: #666666;
    border: 1px solid #e5e5e5;
    border-radius: 0;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.clear-btn:hover {
    border-color: #000000;
    color: #000000;
}

/* Empty Cart */
.empty-cart {
    text-align: center;
    padding: 80px 20px;
}

.empty-cart-icon {
    font-size: 64px;
    margin-bottom: 24px;
    opacity: 0.3;
}

.empty-cart h2 {
    font-size: 24px;
    font-weight: 400;
    color: #000000;
    margin-bottom: 12px;
}

.empty-cart p {
    color: #666666;
    margin-bottom: 32px;
}

.continue-btn {
    display: inline-block;
    padding: 14px 32px;
    background: #000000;
    color: #ffffff;
    text-decoration: none;
    border-radius: 0;
    font-weight: 400;
    transition: opacity 0.2s;
}

.continue-btn:hover {
    opacity: 0.8;
}

/* Notification */
.cart-notification {
    position: fixed;
    top: 24px;
    right: 24px;
    background: #000000;
    color: #ffffff;
    padding: 16px 24px;
    border-radius: 0;
    font-size: 14px;
    font-weight: 400;
    z-index: 10000;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* Tablet */
@media (max-width: 1024px) {
    .cart-content {
        grid-template-columns: 1fr 360px;
        gap: 32px;
    }
    
    .cart-item {
        grid-template-columns: 80px 1fr auto auto auto;
        gap: 16px;
    }
    
    .cart-item-image {
        width: 80px;
        height: 80px;
    }
}

/* Mobile - IMPROVED! */
@media (max-width: 768px) {
    .cart-container {
        margin-top: 80px;
        padding: 0 16px;
    }
    
    .cart-content {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .cart-item {
        grid-template-columns: 90px 1fr;
        grid-template-areas:
            "image info"
            "image price"
            "quantity remove";
        gap: 14px;
        padding: 20px;
    }
    
    .cart-item-image {
        grid-area: image;
        width: 90px;
        height: 90px;
    }
    
    /* IMPROVED INFO BLOCK */
    .cart-item-info {
        grid-area: info;
        gap: 6px;
    }
    
    .cart-item-brand {
        font-size: 12px;
        letter-spacing: 1.2px;
        font-weight: 600;
    }
    
    .cart-item-name {
        font-size: 17px;
        font-weight: 400;
        line-height: 1.4;
    }
    
    .cart-item-price {
        grid-area: price;
        text-align: left;
        font-size: 18px;
        font-weight: 500;
        margin-top: 4px;
    }
    
    .cart-item-quantity {
        grid-area: quantity;
        text-align: left;
        font-size: 28px;
        font-weight: 400;
    }
    
    .cart-item-remove {
        grid-area: remove;
        justify-self: end;
        align-self: center;
        width: 48px;
        height: 48px;
        font-size: 22px;
    }
    
    .summary-card {
        padding: 24px;
    }
}

/* Small Mobile - EXTRA FRIENDLY */
@media (max-width: 480px) {
    .cart-container {
        padding: 0 12px;
        margin-top: 60px;
    }
    
    .cart-item {
        padding: 16px;
        gap: 12px;
    }
    
    .cart-item-image {
        width: 80px;
        height: 80px;
    }
    
    /* EXTRA FRIENDLY INFO */
    .cart-item-info {
        gap: 8px;
    }
    
    .cart-item-brand {
        font-size: 13px;
        letter-spacing: 1.5px;
    }
    
    .cart-item-name {
        font-size: 18px;
        line-height: 1.5;
    }
    
    .cart-item-price {
        font-size: 19px;
        font-weight: 500;
        margin-top: 6px;
    }
    
    .cart-item-quantity {
        font-size: 30px;
    }
}

/* Кнопка очистить корзину */
.clear-btn {
    width: 100%;
    padding: 14px;
    margin-top: 12px;
    background: transparent;
    color: #d32f2f;
    border: 1px solid #ffcdd2;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.clear-btn:hover {
    background: #ffebee;
    border-color: #d32f2f;
    transform: translateY(-1px);
}

.clear-btn:active {
    transform: translateY(0);
}

/* Empty Cart Container */
.empty-cart {
    text-align: center;
    padding: 80px 20px;
    grid-column: 1 / -1;
}

/* Animated Icon with Gradient */
.empty-cart-icon {
    width: 120px;
    height: 120px;
    margin: 0 auto 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 60px;
    animation: bounceEmpty 2s infinite;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

@keyframes bounceEmpty {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Heading with Gradient */
.empty-cart h2 {
    font-size: 28px;
    font-weight: 600;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
}

/* Description */
.empty-cart p {
    color: #666666;
    font-size: 16px;
    margin-bottom: 32px;
    line-height: 1.6;
}

/* Beautiful Button */
.continue-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 16px 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 500;
    font-size: 15px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

.continue-btn:active {
    transform: translateY(0);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .empty-cart {
        padding: 60px 20px;
    }
    
    .empty-cart-icon {
        width: 100px;
        height: 100px;
        font-size: 50px;
    }
    
    .empty-cart h2 {
        font-size: 24px;
    }
    
    .empty-cart p {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .empty-cart {
        padding: 40px 16px;
    }
    
    .empty-cart-icon {
        width: 90px;
        height: 90px;
        font-size: 45px;
    }
    
    .empty-cart h2 {
        font-size: 22px;
    }
    
    .continue-btn {
        padding: 14px 32px;
        font-size: 14px;
    }
}