/* General styles */
.box-options, .selected-boxes, .shortlisted-books-list, .price-breakdown, .box-books-container, .checkout-section {
    margin: 20px 0;
}
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.popup-content {
    background: white;
    padding: 20px;
    border-radius: 5px;
    text-align: center;
    width: 450px;
}

.box-options {
    display: flex;
    justify-content: space-around;
    margin: 20px 0;
}

.box-option {
    cursor: pointer;
}

.box-option img {
    width: 50px;
    height: 50px;
}

.box-option span {
    display: block;
    margin-top: 5px;
}

.popup-cancel {
    background: #ff4444;
    color: white;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
}
.box-options {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.box-option, .selected-box {
    border: 1px solid #ddd;
    padding: 15px;
    border-radius: 5px;
    width: 100%;
    max-width: 32%;
    text-align: center;
}

.quantity-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 10px 0;
}

.box-quantity {
    width: 60px;
    text-align: center;
}

.qty-plus, .qty-minus, .add-to-box-btn, .apply-coupon, .proceed-checkout, .update-cart-btn {
    padding: 8px 12px;
    cursor: pointer;
    border: none;
    border-radius: 3px;
    background-color: #0071a1;
    color: white;
}

.qty-plus:hover, .qty-minus:hover, .add-to-box-btn:hover, .apply-coupon:hover, .proceed-checkout:hover, .update-cart-btn:hover {
    background-color: #005f87;
}

.continue-button {
    display: block;
    margin: 20px auto;
    padding: 10px 20px;
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 3px;
    cursor: pointer;
}

.continue-button:hover {
    background-color: #218838;
}

.progress-bar {
    background-color: #f0f0f0;
    height: 10px;
    border-radius: 5px;
    overflow: hidden;
    margin: 10px 0;
}

.progress-fill {
    background-color: #28a745;
    height: 100%;
    transition: width 0.3s ease;
}

.fit-icons img {
    width: 30px;
    margin: 0 5px;
    cursor: pointer;
}

.fit-icons img:hover {
    opacity: 0.8;
}

.shortlist-controls {
    display: flex;
    gap: 10px;
    align-items: center;
}

.shortlist-quantity, .box-cart-quantity {
    width: 60px;
}

.shortlisted-books-list li, .box-books li, .box-books-list li {
    margin: 10px 0;
    list-style: none;
}

.remove-shortlist, .remove-book {
    color: #d9534f;
    text-decoration: none;
}

.remove-shortlist:hover, .remove-book:hover {
    text-decoration: underline;
}

.checkout-section form {
    max-width: 500px;
    margin: 0 auto;
}

.checkout-section p {
    margin: 10px 0;
}

.checkout-section label {
    display: block;
    margin-bottom: 5px;
}

.checkout-section input, .checkout-section select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.checkout-section input.error {
    border-color: #d9534f;
}

body.loading {
    cursor: progress;
}

body.loading::after {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    border: 4px solid #0071a1;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    transform: translate(-50%, -50%);
    z-index: 9999;
}

@keyframes spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .box-options {
        flex-direction: column;
        align-items: center;
    }

    .box-option, .selected-box {
        max-width: 100%;
    }
}