/* ===================================
   SHOPPING CART PAGE - COMPLETE STYLES
   =================================== */

/* Hero Section */
.page-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 3rem 0;
    color: white;
}

.page-hero .breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.page-hero .breadcrumb a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
}

.page-hero .breadcrumb a:hover {
    color: white;
    text-decoration: underline;
}

.page-hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0;
}

/* Cart Section */
.cart-section {
    padding: 3rem 0;
    background: #f8f9fa;
}

.cart-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

/* === CART ITEMS COLUMN === */
.cart-items {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.cart-header {
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e9ecef;
}

.items-count {
    font-size: 1.125rem;
    font-weight: 600;
    color: #333;
}

/* Cart Item */
.cart-item {
    display: grid;
    grid-template-columns: 100px 1fr 150px 100px;
    gap: 1.5rem;
    padding: 1.5rem 0;
    border-bottom: 1px solid #e9ecef;
    align-items: start;
}

.cart-item:last-child {
    border-bottom: none;
}

/* Item Image */
.cart-item .item-image {
    width: 100px;
    height: 100px;
}

.cart-item .image-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 8px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item .image-placeholder .badge {
    position: absolute;
    top: 6px;
    right: 6px;
    background: white;
    color: #333;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Item Details */
.cart-item .item-details h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
    color: #333;
}

.cart-item .item-meta {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: #666;
}

.cart-item .item-actions {
    display: flex;
    gap: 1rem;
}

.cart-item .item-actions button {
    background: none;
    border: none;
    padding: 0;
    font-size: 0.875rem;
    cursor: pointer;
    color: #667eea;
    transition: color 0.2s;
}

.cart-item .item-actions button:hover {
    text-decoration: underline;
}

.cart-item .remove-btn {
    color: #dc3545;
}

.cart-item .remove-btn:hover {
    color: #c82333;
}

/* Item Quantity */
.cart-item .item-quantity {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.cart-item .item-quantity label {
    font-size: 0.875rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.cart-item .quantity-selector {
    display: flex;
    align-items: center;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
}

.cart-item .qty-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: #f8f9fa;
    cursor: pointer;
    font-size: 1.125rem;
    color: #333;
    transition: all 0.2s;
}

.cart-item .qty-btn:hover {
    background: #667eea;
    color: white;
}

.cart-item .quantity-selector input {
    width: 50px;
    height: 36px;
    border: none;
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    background: white;
}

.cart-item .quantity-selector input:focus {
    outline: none;
}

/* Item Price */
.cart-item .item-price {
    text-align: right;
}

.cart-item .item-price .price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #333;
}

/* Empty Cart */
.empty-cart {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-cart .empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.empty-cart h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.empty-cart p {
    color: #666;
    margin-bottom: 2rem;
}

/* === CART SUMMARY COLUMN === */
.cart-summary {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 100px;
    height: fit-content;
}

.cart-summary h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1.5rem 0;
    color: #333;
}

/* Discount Section */
.discount-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.discount-form {
    display: flex;
    gap: 0.5rem;
}

.discount-form input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 0.875rem;
}

.discount-form input:focus {
    outline: none;
    border-color: #667eea;
}

/* Price Breakdown */
.price-breakdown {
    margin-bottom: 1.5rem;
}

.price-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    color: #333;
}

.price-row.total {
    border-top: 2px solid #e9ecef;
    margin-top: 0.5rem;
    padding-top: 1rem;
    font-size: 1.25rem;
    font-weight: 700;
}

.shipping-price {
    color: #28a745;
    font-weight: 600;
}

/* Buttons */
.btn-checkout {
    width: 100%;
    margin-bottom: 1rem;
}

.continue-shopping {
    display: block;
    text-align: center;
    color: #667eea;
    text-decoration: none;
    padding: 0.75rem;
    transition: color 0.2s;
}

.continue-shopping:hover {
    color: #5568d3;
    text-decoration: underline;
}

/* Trust Badges */
.trust-badges {
    margin: 2rem 0;
    padding: 1.5rem 0;
    border-top: 1px solid #e9ecef;
    border-bottom: 1px solid #e9ecef;
}

.badge-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    font-size: 0.875rem;
    color: #666;
}

.badge-item span:first-child {
    font-size: 1.25rem;
}

/* Payment Methods */
.payment-methods {
    text-align: center;
}

.payment-methods p {
    font-size: 0.875rem;
    color: #666;
    margin-bottom: 0.75rem;
}

.payment-icons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.75rem;
}

.payment-icons span {
    padding: 0.5rem 0.75rem;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

/* === SAVED ITEMS SECTION === */
.saved-items {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 3rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.saved-items h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1.5rem 0;
    color: #333;
}

.saved-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.saved-grid .empty-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 2rem;
    color: #999;
}

/* === RECOMMENDED PRODUCTS === */
.recommended-products {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.recommended-products h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 1.5rem 0;
    color: #333;
}

/* Override product grid styles for cart page */
.cart-section .products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.cart-section .product-card {
    background: #f8f9fa;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s;
    border: 1px solid #e9ecef;
}

.cart-section .product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
}

.cart-section .product-image {
    position: relative;
}

.cart-section .product-placeholder {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-section .product-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: white;
    color: #333;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.cart-section .product-actions {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    display: flex;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity 0.3s;
}

.cart-section .product-card:hover .product-actions {
    opacity: 1;
}

.cart-section .product-actions button {
    flex: 1;
    padding: 0.5rem;
    border: none;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.cart-section .product-actions .quick-view {
    background: white;
    color: #333;
}

.cart-section .product-actions .quick-view:hover {
    background: #f8f9fa;
}

.cart-section .product-actions .add-to-cart {
    background: #667eea;
    color: white;
}

.cart-section .product-actions .add-to-cart:hover {
    background: #5568d3;
}

.cart-section .product-info {
    padding: 1rem;
    background: white;
}

.cart-section .product-title {
    font-size: 0.9375rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
    color: #333;
    line-height: 1.3;
}

.cart-section .product-price {
    font-size: 1.125rem;
    font-weight: 700;
    color: #667eea;
    margin: 0;
}

/* === RESPONSIVE === */
@media (max-width: 1200px) {
    .cart-section .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .cart-layout {
        grid-template-columns: 1fr;
    }

    .cart-summary {
        position: static;
    }

    .cart-section .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .page-hero {
        padding: 2rem 0;
    }

    .page-hero h1 {
        font-size: 1.75rem;
    }

    .cart-item {
        grid-template-columns: 80px 1fr;
        gap: 1rem;
    }

    .cart-item .item-image {
        width: 80px;
        height: 80px;
    }

    .cart-item .item-quantity,
    .cart-item .item-price {
        grid-column: 1 / -1;
    }

    .cart-item .item-quantity {
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }

    .cart-item .item-quantity label {
        margin-bottom: 0;
    }

    .discount-form {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .cart-section .products-grid {
        grid-template-columns: 1fr;
    }
}
