/* Cart Page Specific Styles - Redesigned V2 */

.cart-page.redesigned .page-main-title {
    color: var(--dark-text);
    font-family: var(--font-display);
}

.cart-items-column .cart-header {
    font-weight: 500;
}

.cart-item-v2.card {
    border: 1px solid var(--border-color);
    transition: box-shadow 0.2s ease-in-out;
}
.cart-item-v2.card:hover {
    box-shadow: var(--box-shadow-sm) !important;
}

.cart-item-v2 .cart-item-image {
    width: 70px; /* Slightly smaller image for a cleaner row */
    height: 88px; /* Maintain aspect ratio */
    object-fit: cover;
}
.cart-item-v2 .cart-item-title a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--dark-text);
}
.cart-item-v2 .cart-item-title a:hover {
    color: var(--primary-color);
}
.cart-item-v2 .cart-item-meta {
    font-size: 0.8rem;
}
.cart-item-v2 .cart-item-price,
.cart-item-v2 .cart-item-subtotal {
    font-size: 0.95rem;
}

.cart-quantity .quantity-btn {
    width: 28px; /* Smaller buttons */
    height: 28px;
    padding: 0;
    line-height: 26px;
    font-size: 0.75rem;
}
.cart-quantity .quantity-input {
    width: 36px; /* Smaller input */
    height: 28px;
    text-align: center;
    border-left: none;
    border-right: none;
    border-radius: 0;
    font-size: 0.85rem;
}
.cart-quantity .quantity-input::-webkit-outer-spin-button,
.cart-quantity .quantity-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.cart-quantity .quantity-input[type=number] {
  -moz-appearance: textfield; /* Firefox */
}

.cart-item-remove {
    opacity: 0.7;
    transition: opacity 0.2s ease;
}
.cart-item-remove:hover {
    opacity: 1;
}
.cart-item-remove i {
    font-size: 1.1rem; /* Slightly larger remove icon */
}

.cart-actions .continue-shopping-link-v2,
.cart-actions .clear-cart-btn {
    font-weight: 500;
}

.order-summary-card-v2 {
    background-color: var(--light-bg); /* Light background for summary */
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
}
.order-summary-card-v2 .card-header {
    border-bottom: 1px solid rgba(var(--bs-light-rgb), 0.5); /* Use light for dark header */
}
.order-summary-card-v2 .card-header h5 {
    font-family: var(--font-primary);
}
.order-summary-card-v2 .summary-item-list .list-group-item {
    padding: 0.6rem 0;
    border-bottom: 1px dashed #e0e0e0;
}
.order-summary-card-v2 .summary-item-list .list-group-item:last-child {
    border-bottom: none;
}
.order-summary-card-v2 .coupon-section a {
    color: var(--link-color-default);
}
.order-summary-card-v2 .coupon-section a:hover {
    color: var(--link-color-hover);
}
.order-summary-card-v2 .checkout-btn-v2 {
    font-size: 1.05rem;
    padding: 0.65rem 1.25rem;
    font-weight: 700; /* Bolder checkout button */
}

.cart-empty-message-v2 i {
    font-size: 5rem; /* Even larger icon */
    opacity: 0.5;
}
.cart-empty-message-v2 h3 {
    font-family: var(--font-display);
}

/* Responsive adjustments for cart items */
@media (max-width: 767.98px) {
    .cart-items-column .cart-header {
        display: none; /* Hide header row on small screens */
    }
    .cart-item-v2 .card-body .row > div {
        margin-bottom: 0.5rem; /* Add some space between elements when stacked */
    }
    .cart-item-v2 .cart-item-image {
        width: 60px;
        height: 75px;
        margin-bottom: 0.5rem; /* Space below image when stacked */
    }
     .cart-item-v2 .col-md-5.col-12.d-flex.align-items-center {
        flex-direction: column; /* Stack image and title on small screens */
        align-items: flex-start !important;
    }
    .cart-item-v2 .cart-item-title {
        font-size: 0.9rem;
    }
    .cart-item-v2 .cart-item-price,
    .cart-item-v2 .cart-item-subtotal {
        font-size: 0.9rem;
        text-align: left !important; /* Align left on mobile */
        display: inline-block !important; /* Ensure they are on same line if possible */
        width: auto !important; /* Reset width */
    }
     .cart-item-v2 .cart-item-price::before {
        content: "单价: ";
        font-weight: normal;
        color: var(--muted-text);
        font-size: 0.8rem;
        display: inline-block;
        margin-right: 0.25rem;
    }
    .cart-item-v2 .cart-item-subtotal::before {
        content: "小计: ";
        font-weight: normal;
        color: var(--muted-text);
        font-size: 0.8rem;
        display: inline-block;
        margin-right: 0.25rem;
    }

    .cart-quantity {
        margin: 0.5rem 0 !important; /* Center and add vertical margin on mobile */
    }
    .order-summary-card-v2.sticky-top {
        position: static !important; /* Disable sticky on smaller screens */
    }
}
