﻿
/* ===================================
           MAIN CONTENT
   =================================== */

.cart-section {
    padding: 12rem 0;
    background-color: #ffffff;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 20px;
    text-align: center;
}

.section-subtitle {
    font-size: 1.1rem;
    color: #6b7280;
    margin-bottom: 40px;
    text-align: center;
}

.cart-content {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

/* ===================================
           CART ITEMS
           =================================== */
.cart-items {
    flex: 2;
    min-width: 300px;
}

.empty-cart {
    text-align: center;
    padding: 60px 20px;
    background: #f9fafb;
    border-radius: 12px;
}

    .empty-cart i {
        font-size: 4rem;
        color: #d1d5db;
        margin-bottom: 20px;
    }

    .empty-cart h3 {
        font-size: 1.5rem;
        color: #374151;
        margin-bottom: 10px;
    }

    .empty-cart p {
        color: #6b7280;
        margin-bottom: 20px;
    }

.cart-item {
    display: flex;
    align-items: center;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

    .cart-item:hover {
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    }

.cart-item-image {
    width: 100px;
    height: 100px;
    border-radius: 8px;
    overflow: hidden;
    margin-right: 20px;
    flex-shrink: 0;
}

    .cart-item-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.cart-item-details {
    flex: 1;
    padding: 0 20px;
}

    .cart-item-details h3 {
        font-size: 1.3rem;
        font-weight: 600;
        margin-bottom: 10px;
        color: #1f2937;
    }

.cart-item-price {
    font-size: 1.1rem;
    color: #3b82f6;
    font-weight: 600;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 20px;
}

    .cart-item-quantity .quantity-btn {
        background-color: #3b82f6;
        color: #ffffff;
        border: none;
        border-radius: 50%;
        width: 30px;
        height: 30px;
        font-size: 1rem;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
    }

        .cart-item-quantity .quantity-btn:hover {
            background-color: #2563eb;
            transform: scale(1.1);
        }

.quantity-input {
    width: 60px;
    padding: 8px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    text-align: center;
    font-size: 1rem;
}

.cart-item-total {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1f2937;
    padding: 0 20px;
}

.cart-item-remove {
    background: none;
    border: none;
    color: #ef4444;
    font-size: 1.3rem;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 10px;
}

    .cart-item-remove:hover {
        color: #dc2626;
        transform: scale(1.2);
    }

/* ===================================
           CART SUMMARY
           =================================== */
.cart-summary {
    flex: 1;
    min-width: 300px;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    height: fit-content;
    position: sticky;
    top: 160px;
}

    .cart-summary h2 {
        font-size: 1.6rem;
        font-weight: 600;
        margin-bottom: 20px;
    }

.summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 1rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e5e7eb;
}

.summary-total {
    font-weight: 700;
    font-size: 1.3rem;
    border-top: 2px solid #d1d5db;
    padding-top: 15px;
    margin-top: 10px;
}

.checkout-btn {
    display: block;
    width: 100%;
    background: linear-gradient(135deg, #2a3446 0%, #1b2432 100%); /* Professional soft gradient */
    color: white;
    border: none;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
    text-decoration: none;
}

    /* Premium soft shine effect */
    .checkout-btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient( 90deg, transparent, rgba(255, 255, 255, 0.15), transparent );
        transition: left 0.6s ease;
    }

    .checkout-btn:hover::before {
        left: 100%;
    }

    /* Hover effect: lighter, modern elevation */
    .checkout-btn:hover {
        transform: translateY(-3px);
        background: linear-gradient(135deg, #34425a 0%, #1f2938 100%); /* Brighter on hover */
        box-shadow: 0 10px 24px rgba(27, 36, 50, 0.45);
    }

    /* Tap feel */
    .checkout-btn:active {
        transform: translateY(0);
        box-shadow: 0 4px 12px rgba(27, 36, 50, 0.25);
    }

.continue-shopping {
    display: block;
    color: #3b82f6;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    transition: color 0.3s ease;
}

    .continue-shopping:hover {
        color: #2563eb;
    }

/* ===================================
           RESPONSIVE
           =================================== */
@media (max-width: 768px) {
    main {
        padding-top: 120px;
    }

    .navbar-top {
        flex-wrap: wrap;
        gap: 15px;
    }

    .search-container {
        order: 3;
        max-width: 100%;
        margin: 15px 0 0;
    }

    .cart-content {
        flex-direction: column;
    }

    .cart-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .cart-item-image {
        width: 80px;
        height: 80px;
    }

    .cart-item-details,
    .cart-item-total {
        padding: 0;
    }

    .cart-summary {
        position: relative;
        top: 0;
    }
}
