/* =====================================================================
   Chauffeur.vn Premium Booking Widget — Scoped, Elementor-safe CSS
   All rules are namespaced under .chauffeur-booking-wrapper to avoid
   theme/Elementor conflicts. Mobile-first responsive (stacks < 880px).
   ===================================================================== */

.chauffeur-booking-wrapper {
    display: block;
    box-sizing: border-box;
    width: 100%;
    max-width: 1180px;
    margin: 1.5rem auto;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #e5e7eb;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    text-align: left;
}

.chauffeur-booking-wrapper *,
.chauffeur-booking-wrapper *::before,
.chauffeur-booking-wrapper *::after {
    box-sizing: border-box;
}

.chauffeur-booking-wrapper button {
    font-family: inherit;
}

/* ---------- Layout grid ---------- */
.chauffeur-booking-wrapper .cbk-grid {
    display: grid;
    grid-template-columns: 1.55fr 1fr;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 880px) {
    .chauffeur-booking-wrapper .cbk-grid {
        grid-template-columns: 1fr;
    }
}

/* ---------- Cards ---------- */
.chauffeur-booking-wrapper .cbk-card {
    background: linear-gradient(180deg, #14171d 0%, #0e1116 100%);
    border: 1px solid #232a33;
    border-radius: 14px;
    padding: 1.75rem;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.55);
}

.chauffeur-booking-wrapper .cbk-side {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    position: sticky;
    top: 1.5rem;
}

@media (max-width: 880px) {
    .chauffeur-booking-wrapper .cbk-side { position: static; }
}

/* ---------- Headings ---------- */
.chauffeur-booking-wrapper .cbk-head { margin-bottom: 1.5rem; }

.chauffeur-booking-wrapper .cbk-title {
    margin: 0 0 0.4rem 0;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.65rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #ffffff;
    text-transform: uppercase;
    line-height: 1.15;
}

.chauffeur-booking-wrapper .cbk-sub {
    margin: 0;
    font-size: 12px;
    color: #8b97a6;
    letter-spacing: 0.02em;
}

.chauffeur-booking-wrapper .cbk-side-head {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #c5a85c;
    margin-bottom: 1.1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #232a33;
}

/* ---------- Fields ---------- */
.chauffeur-booking-wrapper .cbk-field { margin-bottom: 1.1rem; }

.chauffeur-booking-wrapper label {
    display: block;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #93a1b1;
    margin-bottom: 0.45rem;
}

.chauffeur-booking-wrapper input,
.chauffeur-booking-wrapper select,
.chauffeur-booking-wrapper textarea {
    width: 100%;
    background-color: #0c0f14;
    border: 1px solid #2a323d;
    border-radius: 9px;
    color: #ffffff;
    padding: 0.8rem 0.95rem;
    font-size: 14px;
    line-height: 1.4;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
    -webkit-appearance: none;
    appearance: none;
}

.chauffeur-booking-wrapper textarea { resize: vertical; min-height: 70px; }

.chauffeur-booking-wrapper input::placeholder,
.chauffeur-booking-wrapper textarea::placeholder { color: #5b6677; }

.chauffeur-booking-wrapper input:focus,
.chauffeur-booking-wrapper select:focus,
.chauffeur-booking-wrapper textarea:focus {
    outline: none;
    border-color: #c5a85c;
    background-color: #11151b;
    box-shadow: 0 0 0 3px rgba(197, 168, 92, 0.18);
}

/* Neutralize Chrome/Edge autofill yellow/orange overlay on dark inputs */
.chauffeur-booking-wrapper input:-webkit-autofill,
.chauffeur-booking-wrapper input:-webkit-autofill:hover,
.chauffeur-booking-wrapper input:-webkit-autofill:focus,
.chauffeur-booking-wrapper input:-webkit-autofill:active,
.chauffeur-booking-wrapper textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px #0c0f14 inset !important;
    box-shadow: 0 0 0 1000px #0c0f14 inset !important;
    -webkit-text-fill-color: #ffffff !important;
    caret-color: #ffffff;
    transition: background-color 9999s ease-out 0s;
}

/* Keep native date/time pickers visible on dark bg */
.chauffeur-booking-wrapper input[type="date"]::-webkit-calendar-picker-indicator,
.chauffeur-booking-wrapper input[type="time"]::-webkit-calendar-picker-indicator {
    filter: invert(0.8);
    cursor: pointer;
}

/* ---------- Row grids ---------- */
.chauffeur-booking-wrapper .cbk-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

@media (max-width: 480px) {
    .chauffeur-booking-wrapper .cbk-row-2 { grid-template-columns: 1fr; }
}

/* ---------- Service segment ---------- */
.chauffeur-booking-wrapper .cbk-seg {
    display: flex;
    gap: 0.35rem;
    background-color: #0c0f14;
    border: 1px solid #232a33;
    padding: 0.3rem;
    border-radius: 11px;
    margin-bottom: 1.25rem;
}

.chauffeur-booking-wrapper .cbk-seg-btn {
    flex: 1;
    padding: 0.8rem 0.5rem;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.02em;
    background: transparent;
    color: #93a1b1;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    line-height: 1.2;
    transition: background-color 0.18s ease, color 0.18s ease;
}

.chauffeur-booking-wrapper .cbk-seg-btn:hover { color: #e5e7eb; }

.chauffeur-booking-wrapper .cbk-seg-btn.active {
    background: linear-gradient(180deg, #2f6dff, #2457e0);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

/* Flight row hidden when service != airport (toggled via JS) */
.chauffeur-booking-wrapper .cbk-flight-row { display: block; }

/* ---------- Stepper ---------- */
.chauffeur-booking-wrapper .cbk-stepper {
    display: flex;
    align-items: stretch;
    background-color: #0c0f14;
    border: 1px solid #2a323d;
    border-radius: 9px;
    overflow: hidden;
}

.chauffeur-booking-wrapper .cbk-stepper input {
    text-align: center;
    border: none;
    border-radius: 0;
    background: transparent;
    -moz-appearance: textfield;
}

.chauffeur-booking-wrapper .cbk-stepper input::-webkit-outer-spin-button,
.chauffeur-booking-wrapper .cbk-stepper input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.chauffeur-booking-wrapper .cbk-stepper input:focus { box-shadow: none; }

.chauffeur-booking-wrapper .cbk-step {
    width: 46px;
    flex-shrink: 0;
    background-color: #1a1f27;
    color: #c5a85c;
    border: none;
    font-size: 20px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.chauffeur-booking-wrapper .cbk-step:hover { background-color: #232a33; }
.chauffeur-booking-wrapper .cbk-step:active { background-color: #c5a85c; color: #0c0f14; }

/* ---------- Divider with centered label ---------- */
.chauffeur-booking-wrapper .cbk-divider {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin: 1.5rem 0 1.1rem;
}

.chauffeur-booking-wrapper .cbk-divider::before,
.chauffeur-booking-wrapper .cbk-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: #232a33;
}

.chauffeur-booking-wrapper .cbk-divider span {
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #c5a85c;
    white-space: nowrap;
}

/* ---------- Promo ---------- */
.chauffeur-booking-wrapper .cbk-promo { display: flex; gap: 0.5rem; }
.chauffeur-booking-wrapper .cbk-promo-input { flex: 1; }

.chauffeur-booking-wrapper .cbk-promo-btn {
    flex-shrink: 0;
    padding: 0 1.1rem;
    background-color: #1a1f27;
    color: #e5e7eb;
    border: 1px solid #2a323d;
    border-radius: 9px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: border-color 0.18s ease, background-color 0.18s ease;
}

.chauffeur-booking-wrapper .cbk-promo-btn:hover { border-color: #c5a85c; color: #c5a85c; }

.chauffeur-booking-wrapper .cbk-promo-feedback {
    font-size: 11.5px;
    margin-top: 0.4rem;
    min-height: 1em;
}

/* ---------- Submit ---------- */
.chauffeur-booking-wrapper .cbk-submit {
    width: 100%;
    margin-top: 0.5rem;
    padding: 1.05rem;
    background: linear-gradient(180deg, #2f6dff, #2052d8);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 10px 26px rgba(37, 99, 235, 0.38);
    transition: transform 0.12s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.chauffeur-booking-wrapper .cbk-submit:hover { transform: translateY(-1px); box-shadow: 0 14px 32px rgba(37, 99, 235, 0.5); }
.chauffeur-booking-wrapper .cbk-submit:disabled { opacity: 0.7; cursor: progress; transform: none; }

.chauffeur-booking-wrapper .cbk-secure-note {
    text-align: center;
    font-size: 11px;
    color: #6b7585;
    margin: 0.85rem 0 0;
    letter-spacing: 0.02em;
}

/* ---------- Fleet list ---------- */
.chauffeur-booking-wrapper .cbk-fleet-list {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    max-height: 430px;
    overflow-y: auto;
    padding-right: 0.35rem;
}

.chauffeur-booking-wrapper .cbk-fleet-list::-webkit-scrollbar { width: 6px; }
.chauffeur-booking-wrapper .cbk-fleet-list::-webkit-scrollbar-thumb { background: #2a323d; border-radius: 4px; }

.chauffeur-booking-wrapper .cbk-veh {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 0.7rem;
    border: 1px solid #232a33;
    background-color: #0c0f14;
    border-radius: 11px;
    cursor: pointer;
    transition: border-color 0.18s ease, background-color 0.18s ease;
}

.chauffeur-booking-wrapper .cbk-veh:hover { border-color: #3a4452; }

.chauffeur-booking-wrapper .cbk-veh.active {
    border-color: #c5a85c;
    background-color: rgba(197, 168, 92, 0.08);
    box-shadow: 0 0 0 1px rgba(197, 168, 92, 0.4);
}

.chauffeur-booking-wrapper .cbk-veh-thumb {
    width: 72px;
    height: 50px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #1a1f27, #0c0f14);
    border: 1px solid #232a33;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chauffeur-booking-wrapper .cbk-veh-thumb img { width: 100%; height: 100%; object-fit: cover; }

.chauffeur-booking-wrapper .cbk-veh-letter {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 22px;
    font-weight: 700;
    color: #c5a85c;
}

.chauffeur-booking-wrapper .cbk-veh-info { flex: 1; min-width: 0; }

.chauffeur-booking-wrapper .cbk-veh-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
}

.chauffeur-booking-wrapper .cbk-veh-name {
    font-size: 13.5px;
    font-weight: 700;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chauffeur-booking-wrapper .cbk-veh-price {
    font-size: 13px;
    font-weight: 700;
    color: #c5a85c;
    white-space: nowrap;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.chauffeur-booking-wrapper .cbk-veh-spec {
    font-size: 11px;
    color: #8b97a6;
    margin-top: 0.3rem;
}

.chauffeur-booking-wrapper .cbk-veh-check {
    position: absolute;
    top: 0.6rem;
    right: 0.7rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #c5a85c;
    color: #0c0f14;
    font-size: 11px;
    font-weight: 800;
    line-height: 18px;
    text-align: center;
    opacity: 0;
    transform: scale(0.6);
    transition: opacity 0.18s ease, transform 0.18s ease;
}

.chauffeur-booking-wrapper .cbk-veh.active .cbk-veh-check { opacity: 1; transform: scale(1); }

/* ---------- Invoice ---------- */
.chauffeur-booking-wrapper .cbk-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #93a1b1;
    margin-bottom: 0.6rem;
}

.chauffeur-booking-wrapper .cbk-line strong { color: #ffffff; font-weight: 700; }
.chauffeur-booking-wrapper .cbk-line-disc { color: #f87171; }
.chauffeur-booking-wrapper .cbk-line-disc strong { color: #f87171; }

.chauffeur-booking-wrapper .cbk-line-total {
    border-top: 1px solid #232a33;
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    font-size: 15px;
    color: #ffffff;
}

.chauffeur-booking-wrapper .cbk-line-total strong {
    color: #c5a85c;
    font-size: 18px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.chauffeur-booking-wrapper .cbk-invoice-note {
    margin: 1rem 0 0;
    font-size: 11px;
    line-height: 1.6;
    color: #6b7585;
    background: rgba(197, 168, 92, 0.06);
    border-left: 3px solid #c5a85c;
    padding: 0.7rem 0.85rem;
    border-radius: 6px;
}

/* ---------- Modal ---------- */
.chauffeur-booking-wrapper .cbk-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 999999;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    backdrop-filter: blur(4px);
}

.chauffeur-booking-wrapper .cbk-modal.open { display: flex; }

.chauffeur-booking-wrapper .cbk-modal-box {
    background: linear-gradient(180deg, #14171d, #0c0f14);
    border: 1px solid #2f6dff;
    border-radius: 14px;
    max-width: 460px;
    width: 100%;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7);
}

.chauffeur-booking-wrapper .cbk-modal-title {
    margin: 0 0 0.4rem;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.5rem;
    color: #c5a85c;
}

.chauffeur-booking-wrapper .cbk-modal-sub { margin: 0 0 1.5rem; font-size: 12.5px; color: #93a1b1; }

.chauffeur-booking-wrapper .cbk-receipt {
    background: #0c0f14;
    border: 1px solid #232a33;
    border-radius: 9px;
    padding: 1rem;
    text-align: left;
    font-size: 12px;
    line-height: 1.9;
    margin-bottom: 1.5rem;
}

.chauffeur-booking-wrapper .cbk-receipt span { color: #6b7585; }
.chauffeur-booking-wrapper .cbk-receipt strong { color: #2f6dff; }

.chauffeur-booking-wrapper .cbk-receipt-total {
    border-top: 1px dashed #2a323d;
    margin-top: 0.5rem;
    padding-top: 0.6rem;
    font-weight: 700;
    color: #c5a85c;
    font-size: 13px;
}

.chauffeur-booking-wrapper .cbk-receipt-total span { color: #c5a85c; }

.chauffeur-booking-wrapper .cbk-modal-note {
    font-size: 12px;
    line-height: 1.6;
    color: #93a1b1;
    margin: 0 0 1.5rem;
}

.chauffeur-booking-wrapper .cbk-modal-close {
    width: 100%;
    background: #1a1f27;
    color: #ffffff;
    border: 1px solid #2a323d;
    padding: 0.85rem;
    border-radius: 9px;
    cursor: pointer;
    font-weight: 700;
    font-size: 12.5px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    transition: background-color 0.18s ease;
}

.chauffeur-booking-wrapper .cbk-modal-close:hover { background: #232a33; }

/* =====================================================================
   Input background override
   Some themes/Elementor force a loud accent (e.g. orange) on form inputs
   with high specificity / !important. Re-assert a soft neutral slate-grey
   that fits the dark layout and keeps white text readable.
   Scoped by the wrapper #id so it wins without fighting the whole theme.
   ===================================================================== */
#chauffeur-booking-wrapper input,
#chauffeur-booking-wrapper select,
#chauffeur-booking-wrapper textarea {
    background-color: #202732 !important;
    color: #ffffff !important;
    border-color: #2f3947 !important;
}

#chauffeur-booking-wrapper input:focus,
#chauffeur-booking-wrapper select:focus,
#chauffeur-booking-wrapper textarea:focus {
    background-color: #262e3a !important;
    border-color: #c5a85c !important;
}

/* Stepper wrapper + inner number field share the same neutral grey */
#chauffeur-booking-wrapper .cbk-stepper { background-color: #202732 !important; }
#chauffeur-booking-wrapper .cbk-stepper input { background-color: transparent !important; }

/* Keep autofill from re-introducing the loud color */
#chauffeur-booking-wrapper input:-webkit-autofill,
#chauffeur-booking-wrapper input:-webkit-autofill:hover,
#chauffeur-booking-wrapper input:-webkit-autofill:focus,
#chauffeur-booking-wrapper textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px #202732 inset !important;
    box-shadow: 0 0 0 1000px #202732 inset !important;
    -webkit-text-fill-color: #ffffff !important;
}
