.cart-page {
    padding-top: 4rem;
    padding-bottom: 6rem;
    min-height: 60vh;
}

.page-header {
    margin-bottom: 3rem;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 0.5rem;
}

.page-header p {
    color: #64748b;
    font-size: 1.1rem;
}

/* Empty Cart */
.empty-cart {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

.empty-cart h2 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.empty-cart p {
    margin-bottom: 2rem;
    color: #64748b;
}

/* Cart Layout */
.cart-container {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 2.5rem;
    align-items: flex-start;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.cart-item {
    display: grid;
    grid-template-columns: 100px 1fr auto auto auto auto;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: white;
    border-radius: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(226, 232, 240, 0.6);
    transition: transform 0.2s;
}

.cart-item:hover {
    transform: translateX(5px);
    border-color: hsl(var(--primary) / 0.3);
}

.item-image img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 0.75rem;
    background: #f1f5f9;
}

.item-details h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: #0f172a;
}

.item-meta {
    font-size: 0.875rem;
    color: #64748b;
}

.item-price {
    font-weight: 600;
    color: #0f172a;
    min-width: 80px;
}

.item-total {
    font-weight: 700;
    color: hsl(var(--primary));
    font-size: 1.1rem;
    min-width: 100px;
    text-align: right;
}

.item-quantity {
    display: flex;
    align-items: center;
    background: #f1f5f9;
    padding: 0.25rem;
    border-radius: 0.5rem;
    gap: 0.5rem;
}

.item-quantity input {
    width: 40px;
    text-align: center;
    border: none;
    background: transparent;
    font-weight: 700;
    -moz-appearance: textfield;
    appearance: textview;
}

.qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    border: none;
    background: white;
    cursor: pointer;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.qty-btn:hover {
    background: hsl(var(--primary));
    color: white;
}

.item-remove button {
    background: transparent;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.2s;
}

.item-remove button:hover {
    color: #ef4444;
}

/* Summary */
.summary-card {
    background: white;
    padding: 2rem;
    border-radius: 1.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(226, 232, 240, 0.8);
    position: sticky;
    top: 100px;
}

.summary-card h3 {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    color: #64748b;
}

.summary-row .free {
    color: #10b981;
    font-weight: 700;
}

.summary-total {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 2px dashed #f1f5f9;
    font-size: 1.25rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 2rem;
}

.summary-card .btn {
    margin-bottom: 1rem;
}

@media (max-width: 900px) {
    .cart-container {
        grid-template-columns: 1fr;
    }

    .cart-item {
        grid-template-columns: 80px 1fr auto;
        grid-template-areas:
            "img details remove"
            "img price total"
            "qty qty qty";
        gap: 1rem;
    }

    .item-image {
        grid-area: img;
    }

    .item-details {
        grid-area: details;
    }

    .item-remove {
        grid-area: remove;
        text-align: right;
    }

    .item-price {
        grid-area: price;
    }

    .item-total {
        grid-area: total;
    }

    .item-quantity {
        grid-area: qty;
        justify-content: center;
    }
}