/* ============================================================
   1. LAYOUT TỔNG THỂ & HIỆU ỨNG BLUR
   ============================================================ */
.booking-layout { display: flex; gap: 32px; margin-top: 20px; }
.booking-left { width: 65%; }
.booking-right { width: 35%; }

/* Hiệu ứng mờ nền khi hiện Popup */
#booking-main-content.content-blurred {
    opacity: 0.15;
    filter: blur(10px);
    pointer-events: none; /* Chặn click vào nội dung chính khi đang chọn ngày */
    user-select: none;
}

/* ============================================================
   2. POPUP CHỌN NGÀY (MODAL) - FIX LỖI KHÔNG CHỌN ĐƯỢC
   ============================================================ */
#date-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.1);
    z-index: 9999; /* Để thấp hơn lịch Flatpickr */
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index:99999;
}

.date-modal {
    background: #fff;
    padding: 35px 25px;
    border-radius: 24px;
    text-align: center;
    max-width: 380px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    position: relative;
    z-index: 10000;
}

/* ÉP LỊCH FLATPICKR LUÔN HIỆN TRÊN CÙNG ĐỂ BẤM ĐƯỢC */
.flatpickr-calendar {
    z-index: 999999 !important;
}

.date-modal h3 { font-size: 22px; font-weight: 800; color: #111; margin: 15px 0 5px; }
.date-modal p { color: #666; font-size: 14px; margin-bottom: 20px; }

/* Ô nhập ngày (Đảm bảo to rõ) */
.booking_date_input {
    width: 100% !important;
    padding: 14px !important;
    font-size: 17px !important;
    text-align: center !important;
    border: 2px solid #ff4500 !important;
    border-radius: 12px !important;
    background: #fff !important;
    font-weight: 700 !important;
    color: #ff4500 !important;
    pointer-events: auto !important; /* Cho phép click vào ô này */
}

#btn-confirm-date {
    margin-top: 15px; width: 100%; padding: 15px;
    border-radius: 12px; border: none;
    background: #eee; color: #999;
    font-weight: 700; cursor: not-allowed; transition: 0.3s;
}
#btn-confirm-date.active {
    background: #ff4500; color: #fff; cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 69, 0, 0.3);
}

/* ============================================================
   3. BỘ ĐIỀU KHIỂN SỐ LƯỢNG (GIỮ NGUYÊN CỦA GIANG)
   ============================================================ */
.qty-control{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:6px;
    width:fit-content;
    margin:0 auto;
    background:#f1f1f1;
    border-radius:30px;
    padding:4px;
}

.qty-control button{
    width:32px !important;
    min-width:32px !important;
    max-width:32px !important;

    height:32px !important;
    min-height:32px !important;
    max-height:32px !important;

    flex:0 0 32px !important;   /* giữ nguyên kích thước */
    border-radius:50% !important;

    display:flex;
    align-items:center;
    justify-content:center;

    padding:0 !important;
    margin:0 !important;
    border:none !important;
    background:#fff !important;
    color:#ff4500 !important;
    font-size:18px;
    font-weight:700;
    line-height:1;
}

.qty-control input{
    width:34px !important;
    height:32px !important;
    border:none !important;
    background:transparent !important;
    text-align:center !important;
    padding:0 !important;
    margin:0 !important;
    font-weight:700;
}

/* ============================================================
   4. DÒNG VÉ & GROUP
   ============================================================ */
.booking-group { border: 1px solid #eee; border-radius: 14px; margin-bottom: 16px; overflow: hidden; background: #fff; }
.group-header { 
    padding: 16px; font-weight: 700; background: #fafafa; 
    display: flex; justify-content: space-between; cursor: pointer;
}
.group-header.header-active { color: #ff4500; background: #fff7f4; }
.group-content { display: none; padding: 0 16px; }
.group-content.active { display: block; }

.ticket-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 18px 0; border-bottom: 1px solid #f2f2f2; gap: 15px;
}
.ticket-row:last-child { border-bottom: 0; }
.ticket-name { font-weight: 600; font-size: 15px; color: #333; line-height: 1.4; }
.ticket-price { font-weight: 700; color: #ff4500; font-size: 17px; }

/* ============================================================
   5. MOBILE & FOOTER TIỀN (CHỈ HIỆN TRÊN MOBILE)
   ============================================================ */

/* Mặc định ẩn footer trên Desktop */
#booking-sticky-footer { display: none !important; }

@media(max-width: 768px) {
    .booking-layout { display: block; }
    .booking-left, .booking-right { width: 100%; }
    
    /* Ẩn cột bên phải của Desktop khi xem Mobile */
    .booking-right { display: none !important; } 
    
    #booking-sticky-footer {
        display: block !important; /* Hiện trên mobile */
        position: fixed;
        left: 0; right: 0; bottom: 0;
        background: #fff;
        box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
        padding: 12px 16px;
        z-index: 10001 !important; 
        border-radius: 15px 15px 0 0;
        z-index:9999;
    }
    
    .sticky-inner { display: flex; gap: 12px; align-items: center; justify-content: space-between; }
    #display-total-mobile { font-size: 20px; font-weight: 700; color: #ff4500; }
    body { padding-bottom: 100px !important; }
}

/* Các đoạn Sticky cho PC */
.summary-box {
    position: sticky; top: 20px; background: #fff; padding: 24px;
    border-radius: 16px; box-shadow: 0 8px 24px rgba(0,0,0,.08);
}
.summary-total { font-size: 24px; font-weight: 700; margin: 14px 0; color: #ff4500; }
.summary-line { display: flex; justify-content: space-between; margin: 8px 0; font-size: 14px; }
/* ============================================================
   6. CSS CHO NÚT ĐẶT NGAY (PC & MOBILE)
   ============================================================ */

/* Nút trên PC (trong cột bên phải) */
#btn-order-now {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 12px;
    background: #ff4500; /* Màu đen sang trọng hoặc đổi thành #ff4500 nếu muốn nổi */
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

#btn-order-now:hover {
    background: #333;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Nút trên Mobile (trong thanh ghim dưới cùng) */
#btn-order-now-mobile {
    background: #ff4500 !important; /* Mobile nên để màu cam cho dễ thấy */
    color: #fff !important;
    border: none;
    padding: 12px 25px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(255, 69, 0, 0.3);
}

#btn-order-now-mobile:active {
    transform: scale(0.95);
}

/* Trạng thái nút khi chưa chọn ngày (nếu cần) */
#btn-order-now:disabled, #btn-order-now-mobile:disabled {
    background: #ccc !important;
    cursor: not-allowed;
    box-shadow: none;
}