/* Cart Page Styles */
.cart-main {
    padding: calc(var(--spacing-unit) * 8) 0 calc(var(--spacing-unit) * 20) 0;
    min-height: 60vh;
}

.page-header {
    text-align: center;
    margin-bottom: calc(var(--spacing-unit) * 16);
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: calc(var(--spacing-unit) * 4);
}

.page-header p {
    font-size: 1.1rem;
    color: var(--text-color);
    opacity: 0.7;
}

.cart-container {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: calc(var(--spacing-unit) * 12);
    align-items: start;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: calc(var(--spacing-unit) * 6);
}

.cart-item {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: calc(var(--spacing-unit) * 6);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.cart-item:hover {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.item-content {
    display: grid;
    grid-template-columns: 100px 1fr auto auto;
    gap: calc(var(--spacing-unit) * 4);
    align-items: center;
}

.item-image {
    width: 100px;
    height: 80px;
    background: linear-gradient(135deg, #f5f5f5 0%, #e5e5e5 100%);
    border-radius: calc(var(--border-radius) * 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.8rem;
    color: var(--secondary-color);
    font-weight: 500;
}

.item-details h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: calc(var(--spacing-unit) * 2);
    color: var(--text-color);
}

.item-details p {
    font-size: 0.9rem;
    color: var(--text-color);
    opacity: 0.7;
    line-height: 1.4;
}

.item-price {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: calc(var(--spacing-unit) * 3);
}

.quantity-btn {
    width: 32px;
    height: 32px;
    border: 2px solid var(--secondary-color);
    background: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.quantity-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.quantity-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.quantity-display {
    font-size: 1.1rem;
    font-weight: 600;
    min-width: 30px;
    text-align: center;
}

.remove-item {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 1.2rem;
    cursor: pointer;
    padding: calc(var(--spacing-unit) * 2);
    border-radius: 50%;
    transition: all 0.3s ease;
    margin-left: calc(var(--spacing-unit) * 3);
}

.remove-item:hover {
    background: rgba(220, 53, 69, 0.1);
    transform: scale(1.1);
}

.cart-summary {
    position: sticky;
    top: calc(var(--spacing-unit) * 20);
}

.summary-card {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: calc(var(--spacing-unit) * 8);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.summary-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: calc(var(--spacing-unit) * 6);
    text-align: center;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: calc(var(--spacing-unit) * 4);
    font-size: 1rem;
}

.summary-row.total-row {
    border-top: 2px solid var(--background-color);
    padding-top: calc(var(--spacing-unit) * 4);
    margin-top: calc(var(--spacing-unit) * 6);
    font-size: 1.2rem;
    font-weight: 700;
}

.summary-row.total-row span {
    color: var(--primary-color);
}

.checkout-btn {
    width: 100%;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: calc(var(--spacing-unit) * 4);
    border-radius: var(--border-radius);
    font-family: var(--font-family);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: calc(var(--spacing-unit) * 6) 0 calc(var(--spacing-unit) * 4) 0;
}

.checkout-btn:hover:not(:disabled) {
    background: #d1154a;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(235, 26, 78, 0.3);
}

.checkout-btn:disabled {
    background: var(--secondary-color);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.continue-shopping {
    display: block;
    text-align: center;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.continue-shopping:hover {
    color: var(--primary-color);
}

/* Empty Cart */
.empty-cart {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
}

.empty-cart-content {
    text-align: center;
    max-width: 400px;
}

.empty-cart-icon {
    font-size: 5rem;
    margin-bottom: calc(var(--spacing-unit) * 6);
    opacity: 0.5;
}

.empty-cart-content h2 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: calc(var(--spacing-unit) * 4);
    color: var(--text-color);
}

.empty-cart-content p {
    font-size: 1.1rem;
    color: var(--text-color);
    opacity: 0.7;
    margin-bottom: calc(var(--spacing-unit) * 8);
    line-height: 1.5;
}

/* Responsive Design */
@media (max-width: 968px) {
    .cart-container {
        grid-template-columns: 1fr;
        gap: calc(var(--spacing-unit) * 8);
    }
    
    .cart-summary {
        position: static;
        order: -1;
    }
}

@media (max-width: 768px) {
    .item-content {
        grid-template-columns: 80px 1fr;
        gap: calc(var(--spacing-unit) * 3);
    }
    
    .item-image {
        width: 80px;
        height: 60px;
    }
    
    .item-actions {
        grid-column: 1 / -1;
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-top: calc(var(--spacing-unit) * 4);
        padding-top: calc(var(--spacing-unit) * 4);
        border-top: 1px solid var(--background-color);
    }
    
    .cart-item {
        padding: calc(var(--spacing-unit) * 4);
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .cart-main {
        padding: calc(var(--spacing-unit) * 4) 0 calc(var(--spacing-unit) * 16) 0;
    }
    
    .item-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: calc(var(--spacing-unit) * 3);
    }
    
    .item-image {
        width: 100%;
        height: 120px;
    }
    
    .item-actions {
        justify-content: center;
        flex-wrap: wrap;
        gap: calc(var(--spacing-unit) * 4);
    }
    
    .summary-card {
        padding: calc(var(--spacing-unit) * 6);
    }
}