/* Base Styles */
:root {
    --primary-color: #5B455E;
    --secondary-color: #8A6D8F;
    --light-color: #F5F5F5;
    --dark-color: #333;
    --danger-color: #E74C3C;
    --success-color: #2ECC71;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    color: var(--dark-color);
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

.cart-container {

    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    margin-top: 130px;
    margin-bottom: 30px;
}

/* Header Styles */
.cart-title {
    margin-top: 100px;
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 30px;
    font-size: 2rem;
    position: relative;
    padding-bottom: 10px;
}

.cart-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background-color: var(--secondary-color);
}

/* Back Button */
.back-btn {
    position: absolute;
    top: 20px;
    left: 20px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.back-btn:hover {
    background-color: var(--secondary-color);
    transform: translateX(-3px);
}

/* Cart Items Container */
.cart-items-container {
    margin: 20px 0;
    max-height: 500px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) var(--light-color);
}

.cart-items-container::-webkit-scrollbar {
    width: 8px;
}

.cart-items-container::-webkit-scrollbar-track {
    background: var(--light-color);
}

.cart-items-container::-webkit-scrollbar-thumb {
    background-color: var(--primary-color);
    border-radius: 10px;
}

/* Cart Items List */
#cart-items {
    list-style: none;
    padding: 0;
    margin: 0;
}

#cart-items li {
    display: flex;
    align-items: center;
    padding: 15px;
    margin-bottom: 15px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#cart-items li:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    margin-right: 20px;
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.cart-item-name {
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--dark-color);
}

.cart-item-price {
    color: var(--primary-color);
    font-weight: 500;
}

.delete-btn {
    background: none;
    border: none;
    color: var(--danger-color);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 8px;
    transition: transform 0.2s ease;
}

.delete-btn:hover {
    transform: scale(1.1);
}

/* Cart Summary */
.cart-summary {
    border-top: 2px solid var(--light-color);
    padding-top: 20px;
}

.cart-total {
    font-size: 1.3rem;
    font-weight: 600;
    text-align: right;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.cart-actions {
    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.clear-cart-btn, .checkout-btn {
    flex: 1;
    padding: 20px;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    
}

.clear-cart-btn {
    background-color: var(--light-color);
    color: var(--danger-color);
    height: 40px;
}

.clear-cart-btn:hover {
    background-color: var(--danger-color);
    color: white;
}

.checkout-btn {
    background-color: var(--primary-color);
    color: white;
}

.checkout-btn:hover {
    background-color: var(--secondary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .cart-container {
        margin: 15px;
        padding: 15px;
    }
    
    .cart-actions {
        flex-direction: column;
    }
    
    #cart-items li {
        flex-direction: column;
        text-align: center;
    }
    
    .cart-item-image {
        margin-right: 0;
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .cart-title {
        font-size: 1.5rem;
    }
    
    .cart-total {
        font-size: 1.1rem;
    }
}


.cart-item-details {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
}

.cart-item-quantity-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: #333;
  background-color: #efefef;
  border-radius: 40PX;
}

.cart-item-qty {
  font-weight: bold;
  font-size: 14px;
}

.cart-item-price {
  font-size: 14px;
  color: #333;
}

.qty-btn {
  background-color: transparent;
  color: #333;
  border: none;
  padding: 4px 10px;
  font-size: 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}


.cart-item-size {
    display: block;
    font-size: 14px;
    color: #666;
    margin: 4px 0;
}