/* Cart Page Styles */

.page-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 40px 0;
    margin-bottom: 40px;
}

.page-header h1 {
    font-size: 32px;
    margin-bottom: 10px;
}

.breadcrumb {
    font-size: 14px;
    opacity: 0.9;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.cart-section {
    padding: 40px 0 80px;
    min-height: 60vh;
}

/* Empty Cart */
.empty-cart {
    text-align: center;
    padding: 80px 20px;
}

.empty-cart i {
    font-size: 120px;
    color: var(--border-color);
    margin-bottom: 30px;
}

.empty-cart h2 {
    font-size: 28px;
    color: var(--text-dark);
    margin-bottom: 15px;
}

.empty-cart p {
    color: var(--text-light);
    margin-bottom: 30px;
    font-size: 16px;
}

/* Cart Container */
.cart-container {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 40px;
    align-items: start;
}

/* Cart Items */
.cart-items h2 {
    font-size: 24px;
    margin-bottom: 25px;
    color: var(--text-dark);
}

.cart-item {
    display: grid;
    grid-template-columns: 120px 1fr 150px 120px 50px;
    gap: 20px;
    align-items: center;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    margin-bottom: 15px;
    transition: all 0.3s;
}

.cart-item:hover {
    box-shadow: var(--shadow-hover);
}

.item-image img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
}

.item-details h3 {
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--text-dark);
}

.item-price {
    font-size: 16px;
    color: var(--text-light);
}

/* Quantity Controls */
.item-quantity {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-light);
    padding: 8px;
    border-radius: 50px;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: white;
    color: var(--text-dark);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 14px;
}

.qty-btn:hover {
    background: var(--primary-color);
    color: white;
}

.qty-input {
    width: 50px;
    text-align: center;
    border: none;
    background: transparent;
    font-size: 16px;
    font-weight: 600;
    font-family: 'Prompt', sans-serif;
    color: var(--text-dark);
}

.qty-input:focus {
    outline: none;
}

/* Remove input spinner */
.qty-input::-webkit-inner-spin-button,
.qty-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.item-total {
    text-align: right;
}

.total-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-color);
}

.btn-remove {
    width: 40px;
    height: 40px;
    border: none;
    background: #fee;
    color: #e74c3c;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-remove:hover {
    background: #e74c3c;
    color: white;
    transform: scale(1.1);
}

/* Cart Summary */
.cart-summary {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 100px;
}

.cart-summary h2 {
    font-size: 22px;
    margin-bottom: 25px;
    color: var(--text-dark);
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 16px;
    color: var(--text-dark);
}

.summary-row.total {
    margin-top: 20px;
    font-size: 20px;
    font-weight: 700;
}

.total-amount {
    color: var(--primary-color);
    font-size: 24px;
}

.summary-divider {
    height: 1px;
    background: var(--border-color);
    margin: 20px 0;
}

.btn-checkout {
    width: 100%;
    background: var(--primary-color);
    color: white;
    padding: 10px 30px;
    margin-top: 20px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
}

.btn-checkout:hover {
    background: var(--secondary-color);
}

.btn-continue {
    width: 100%;
    background: transparent;
    color: var(--text-dark);
    border: 2px solid var(--border-color);
    padding: 10px 30px;
    margin-top: 10px;
    font-size: 15px;
    text-align: center;
}

.btn-continue:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* Trust Badges */
.trust-badges {
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid var(--border-color);
}

.trust-badges .badge {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: var(--text-light);
    font-size: 14px;
}

.trust-badges .badge i {
    color: var(--primary-color);
    font-size: 18px;
}

/* Responsive */
@media (max-width: 1024px) {
    .cart-container {
        grid-template-columns: 1fr;
    }
    
    .cart-summary {
        position: static;
    }
}

@media (max-width: 768px) {
    .cart-item {
        grid-template-columns: 80px 1fr;
        gap: 15px;
    }
    
    .item-image {
        grid-row: 1 / 3;
    }
    
    .item-details {
        grid-column: 2;
    }
    
    .item-quantity {
        grid-column: 2;
        justify-self: start;
    }
    
    .item-total {
        grid-column: 2;
        text-align: left;
    }
    
    .item-remove {
        grid-column: 2;
        justify-self: end;
        grid-row: 1;
    }
}

/* Modal Base Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: slideUp 0.3s ease;
    position: relative;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Delete Confirmation Modal */
.delete-modal {
    text-align: center;
    max-width: 450px;
    padding: 40px;
}

.modal-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    animation: scaleIn 0.3s ease;
}

.modal-icon i {
    font-size: 36px;
    color: white;
}

.delete-modal h3 {
    font-size: 24px;
    color: var(--text-dark);
    margin-bottom: 15px;
    font-weight: 600;
}

.delete-modal p {
    font-size: 16px;
    color: var(--text-light);
    margin-bottom: 30px;
    line-height: 1.6;
}

.modal-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.modal-buttons button {
    flex: 1;
    padding: 14px 25px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Prompt', sans-serif;
}

.btn-cancel {
    background: #f5f5f5;
    color: var(--text-dark);
}

.btn-cancel:hover {
    background: #e0e0e0;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.btn-confirm {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
}

.btn-confirm:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(231,76,60,0.4);
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}
