/* --- BỘ CỘNG TRỪ CHỐNG ĐÈ TUYỆT ĐỐI --- */
.qb-quantity-controls {
    display: flex !important;
    align-items: stretch !important;
    border: 1px solid #ccc !important;
    border-radius: 4px !important;
    height: 38px !important; /* Tăng thêm độ cao */
    background: #fff !important;
    width: 120px !important; /* Độ rộng chuẩn */
    min-width: 120px !important;
    overflow: hidden !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

.qty-btn {
    flex: 0 0 35px !important; /* Cố định nút 35px */
    width: 35px !important;
    height: 100% !important;
    border: none !important;
    background: #f1f1f1 !important;
    cursor: pointer !important;
    font-size: 20px !important;
    font-weight: bold !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #333 !important;
    padding: 0 !important;
    margin: 0 !important;
    line-height: 1 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}

.qty-btn:hover { background: #e2e2e2 !important; }

/* Ô nhập số chính giữa */
#qb_display_qty, .qb_static_qty {
    flex: 1 !important; /* Chiếm toàn bộ không gian còn lại */
    width: 50px !important; /* Ép độ rộng tối thiểu cho con số */
    min-width: 50px !important;
    height: 100% !important;
    border: none !important;
    border-left: 1px solid #ccc !important;
    border-right: 1px solid #ccc !important;
    text-align: center !important;
    font-size: 16px !important;
    font-weight: bold !important;
    background: #fff !important;
    color: #333 !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    -moz-appearance: textfield;
}

/* Xóa mũi tên tăng giảm của trình duyệt */
#qb_display_qty::-webkit-inner-spin-button, 
#qb_display_qty::-webkit-outer-spin-button,
.qb_static_qty::-webkit-inner-spin-button, 
.qb_static_qty::-webkit-outer-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
}

/* --- STYLE CHUNG --- */
.quickbuy-popup-wrapper { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.8); z-index: 999999; display: none; align-items: center; justify-content: center; }
.quickbuy-content { background: #fff; border-radius: 10px; width: 95%; max-width: 750px; display: flex; position: relative; overflow: hidden; box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.close-popup { position: absolute; top: 10px; right: 15px; font-size: 15px; color: #ccc; cursor: pointer; z-index: 100; }
.quickbuy-product-info { flex: 1; padding: 25px; background: #fafafa; border-right: 1px solid #eee; }
.qb-product-header { display: flex; gap: 15px; align-items: center; margin-bottom: 20px; }
.qb-product-image img { width: 80px; height: 80px; object-fit: cover; border-radius: 5px; }
.qb-product-details h4 { font-size: 15px; margin: 0; font-weight: bold; color: #333; }
.qb-product-details .price { margin-top: 5px; font-size: 14px; }
.qb-total-row { display: flex; justify-content: space-between; align-items: center; padding: 10px; background: #fff; border: 1px solid #eee; border-radius: 5px; margin-top: 15px; }
.quickbuy-form-side { flex: 1.2; padding: 25px; }
.quickbuy-form-side input { width: 100%; padding: 11px; margin-bottom: 10px; border: 1px solid #ddd; border-radius: 5px; box-sizing: border-box; }
.qb-note-small { width: 100%; height: 60px !important; padding: 10px; border: 1px solid #ddd; border-radius: 5px; margin-bottom: 10px; box-sizing: border-box; }
.button.alt { width: 100%; padding: 12px; color: #fff; border: none; border-radius: 5px; font-weight: bold; cursor: pointer; }

@media (max-width: 600px) {
    .quickbuy-content { flex-direction: column; max-height: 90vh; overflow-y: auto; }
    .quickbuy-product-info { border-right: none; border-bottom: 1px solid #eee; }
}

/* --- CSS THÊM CHO MÀN HÌNH THÀNH CÔNG --- */
.qb-success-screen { width: 100%; padding: 40px 20px; text-align: center; }
.qb-success-screen h2 { color: #4CAF50; margin: 15px 0; }
.qb-order-badge { display: inline-block; padding: 5px 15px; background: #f1f1f1; border-radius: 20px; font-weight: bold; color: #333; margin-top: 10px; }

/* TÍCH XANH ANIMATION */
.sa-icon.sa-success { width: 80px; height: 80px; border: 4px solid #4CAF50; border-radius: 50%; margin: 0 auto; position: relative; }
.sa-line { height: 5px; background-color: #4CAF50;close-popup display: block; border-radius: 2px; position: absolute; z-index: 2; }
.sa-line.sa-tip { width: 25px; left: 14px; top: 46px; transform: rotate(45deg); }
.sa-line.sa-long { width: 47px; right: 8px; top: 38px; transform: rotate(-45deg); }
.animateSuccessTip { animation: animateSuccessTip 0.75s; }
.animateSuccessLong { animation: animateSuccessLong 0.75s; }
@keyframes animateSuccessTip { 0% { width: 0; left: 1px; top: 19px; } 100% { width: 25px; left: 14px; top: 46px; } }
@keyframes animateSuccessLong { 0% { width: 0; right: 46px; top: 54px; } 100% { width: 47px; right: 8px; top: 38px; } }

@media (max-width: 600px) {
    .quickbuy-content { flex-direction: column; max-height: 95vh; overflow-y: auto; }
    .quickbuy-product-info { border-right: none; border-bottom: 1px solid #eee; }
}