/* ====================================================================
   BOOKING ENGINE - AVAILABILITY SEARCH BAR & RANGE/GUEST POP-OVERS
   ==================================================================== */

.booking-search-container {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
    padding: 16px 20px;
    position: relative;
    z-index: 100;
    margin-bottom: 24px;
}

.booking-search-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
}

/* Selector Group Fields */
.search-field-group {
    flex: 1;
    min-width: 240px;
    position: relative;
}

.search-field-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    font-weight: 800;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.search-field-label i {
    color: #0284c7;
    font-size: 0.95rem;
}

.search-field-button {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.search-field-button:hover,
.search-field-button.active {
    background: #ffffff;
    border-color: #0284c7;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.12);
}

.search-field-button .field-content {
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.search-field-button .field-icon {
    font-size: 1.1rem;
    color: #64748b;
}

.search-field-button .field-text {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.search-field-button .nights-badge {
    background: #e0f2fe;
    color: #0369a1;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 20px;
    flex-shrink: 0;
}

/* Common Popover Dropdowns */
.booking-popover {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    box-shadow: 0 20px 48px rgba(15, 23, 42, 0.16);
    padding: 20px;
    z-index: 1000;
    display: none;
    animation: popoverFadeIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.booking-popover.active {
    display: block;
}

@keyframes popoverFadeIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Date Range Picker Popover Extensions */
.date-popover {
    width: 660px;
    max-width: 95vw;
    padding: 20px;
}

.date-popover #inline_range_calendar {
    display: block;
    width: 100%;
    margin: 0 auto;
}

/* Flatpickr Native Layout Integration */
.date-popover .flatpickr-calendar.inline {
    box-shadow: none !important;
    border: none !important;
    margin: 0 auto !important;
}

.date-popover-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    margin-top: 14px;
    border-top: 1px solid #e2e8f0;
}

.date-popover-nights {
    font-size: 0.9rem;
    font-weight: 800;
    color: #0f172a;
}

.date-popover-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-link-reset {
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    text-decoration: underline;
    padding: 6px 12px;
}

.btn-link-reset:hover {
    color: #0f172a;
}

.btn-popover-done {
    background: #0284c7;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 8px 24px;
    font-size: 0.9rem;
    font-weight: 800;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-popover-done:hover {
    background: #0369a1;
}

/* Rooms & Guests Popover - Wider & Cleaner Counter Buttons */
.guests-popover {
    width: 560px;
    max-width: 94vw;
    padding: 22px;
}

.guests-header-grid {
    display: grid;
    grid-template-columns: 110px 1fr 1fr 1fr 34px;
    gap: 14px;
    text-align: center;
    font-size: 0.8rem;
    font-weight: 800;
    color: #475569;
    padding-bottom: 12px;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 14px;
}

.guests-header-col sub {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    color: #94a3b8;
    margin-top: 2px;
}

.room-row {
    display: grid;
    grid-template-columns: 110px 1fr 1fr 1fr 34px;
    gap: 14px;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px dashed #f1f5f9;
}

.room-row:last-child {
    border-bottom: none;
}

.room-name {
    font-size: 0.9rem;
    font-weight: 800;
    color: #0f172a;
}

/* Sleek Counter Widget (Square buttons, no rounded circles) */
.counter-widget {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 3px 4px;
}

.counter-btn {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: #ffffff;
    color: #334155;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
    user-select: none;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.counter-btn:hover:not(:disabled) {
    background: #0284c7;
    color: #ffffff;
}

.counter-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    background: transparent;
    box-shadow: none;
}

.counter-value {
    width: 28px;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
}

.btn-remove-room {
    background: transparent;
    border: none;
    color: #ef4444;
    font-size: 1.15rem;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.btn-remove-room:hover {
    background: #fef2f2;
}

.guests-popover-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
}

.btn-add-room {
    background: #ffffff;
    border: 1.5px solid #0284c7;
    color: #0284c7;
    border-radius: 8px;
    padding: 8px 18px;
    font-size: 0.88rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-add-room:hover {
    background: #f0f9ff;
}

/* Secondary Controls Row (Promo code & Checkin options) */
.search-options-row {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 12px;
    border-top: 1px solid #f1f5f9;
}

.promo-code-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-toggle-promo {
    background: transparent;
    border: none;
    color: #0284c7;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-toggle-promo:hover {
    text-decoration: underline;
}

.promo-input-wrapper {
    display: none;
    align-items: center;
    gap: 6px;
}

.promo-input-wrapper.active {
    display: flex;
}

.promo-input-wrapper input {
    padding: 6px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    width: 140px;
    text-transform: uppercase;
}

.special-times-group {
    display: flex;
    align-items: center;
    gap: 16px;
}

.special-time-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: #475569;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
}

.special-time-label input[type="checkbox"] {
    accent-color: #0284c7;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* Submit Search Button */
.btn-submit-search {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 13px 28px;
    font-size: 0.98rem;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(2, 132, 199, 0.3);
    transition: all 0.2s ease;
    min-width: 180px;
}

.btn-submit-search:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(2, 132, 199, 0.4);
    background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .booking-search-form {
        flex-direction: column;
        align-items: stretch;
    }
    
    .date-popover {
        width: 340px;
        min-width: calc(100vw - 40px);
        left: 0 !important;
        right: 0 !important;
        padding: 14px;
    }

    .guests-popover {
        width: calc(100vw - 40px);
    }

    .guests-header-grid,
    .room-row {
        grid-template-columns: 80px 1fr 1fr 1fr 28px;
        gap: 6px;
    }

    .search-options-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .room-card-body-grid {
        grid-template-columns: 1fr !important;
    }
}

/* ====================================================================
   MULTI-ROOM BUILDER & RESERVATION CART SIDEBAR STYLES
   ==================================================================== */

.multi-room-builder-container {
    margin-bottom: 28px;
}

.multi-room-tabs-header {
    display: flex;
    align-items: center;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e2e8f0;
}

.room-slot-tab {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 12px;
    padding: 10px 18px;
    font-size: 0.9rem;
    font-weight: 800;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.room-slot-tab:hover {
    border-color: #0284c7;
    color: #0284c7;
    background: #f0f9ff;
}

.room-slot-tab.active {
    background: #0284c7;
    border-color: #0284c7;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.3);
}

.room-slot-tab .slot-status-pill {
    font-size: 0.72rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.08);
}

.room-slot-tab.active .slot-status-pill {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff;
}

.room-slot-tab.completed {
    border-color: #16a34a;
    color: #15803d;
    background: #f0fdf4;
}

.room-slot-tab.completed .slot-status-pill {
    background: #dcfce7;
    color: #15803d;
}

/* Multi Room Layout Grid (Room Cards List + Summary Cart Sidebar) */
.multi-room-search-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 24px;
    align-items: start;
}

@media (max-width: 960px) {
    .multi-room-search-layout {
        grid-template-columns: 1fr;
    }
}

.multi-room-cart-sidebar {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    padding: 22px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    position: sticky;
    top: 80px;
    z-index: 50;
}

.cart-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-slot-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.cart-slot-item.selected {
    background: #f0f9ff;
    border-color: #bae6fd;
}

.cart-slot-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.78rem;
    font-weight: 800;
    color: #475569;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.cart-slot-room-name {
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
}

.cart-slot-price {
    font-size: 0.88rem;
    font-weight: 700;
    color: #0284c7;
}

.cart-totals-section {
    padding-top: 14px;
    margin-top: 14px;
    border-top: 2px dashed #e2e8f0;
}

.cart-total-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.cart-total-row.grand-total {
    margin-top: 8px;
    font-size: 1.25rem;
    font-weight: 900;
    color: #0284c7;
}

.btn-checkout-multi {
    width: 100%;
    margin-top: 16px;
    padding: 14px;
    font-size: 1rem;
    font-weight: 800;
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(2, 132, 199, 0.35);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-checkout-multi:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(2, 132, 199, 0.45);
}

.btn-checkout-multi:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #94a3b8;
    box-shadow: none;
}

