/* Main container wrapping the cart */
.cart-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 100px); /* Adjust based on your header/navbar height */
    position: relative;
}

/* Scrollable items area - takes up remaining space and scrolls */
#cartItems {
    flex: 1;
    overflow-y: auto;
    padding-right: 6px;
    -webkit-overflow-scrolling: touch;
}

#cartItems::-webkit-scrollbar {
    width: 6px;
}

#cartItems::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 10px;
}

/* Sticky Bottom Cart Summary */
.cart-summary {
    position: sticky;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #fff; /* Ensure it doesn't overlap text transparently */
    padding: 15px;
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.08); /* Optional shadow for separation */
    z-index: 100;
}

/* Existing UI styles */
.total-bar span {
    font-weight: 600;
    font-size: 1.2rem;
}

.back-btn {
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 10px;
    font-size: 20px;
}

.order-type-btn {
    position: relative;
    border: 2px solid #ddd;
    border-radius: 10px;
    padding: 15px;
    cursor: pointer;
    transition: 0.2s ease;
    background: #fff;
    text-align: center;
}

.order-type-btn.active {
    border-color: #0d6efd;
    background: #0d6efd;
    color: #fff;
}

.order-type-btn.active .icon {
    filter: brightness(0) invert(1);
}

.check-icon {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    color: #0d6efd;
    font-size: 14px !important;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.order-type-btn.active .check-icon {
    display: flex;
}

.check-iconX {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: white;
    border: 1.5px solid black;
    color: #0d6efd;
    font-size: 14px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.order-type-btn.active .check-iconX {
    display: none;
}