/* =====================================================
   RC Rental — Premium Booking Form
   ===================================================== */

.rc_rent_car_form_wrapper {
    --rc-accent: #0a58ca;
    --rc-accent-2: #1d4ed8;
    --rc-accent-dark: #07306e;
    --rc-surface: #ffffff;
    --rc-surface-soft: #f7f9fc;
    --rc-border: rgba(17, 24, 39, 0.08);
    --rc-text: #0f172a;
    --rc-text-muted: #64748b;
    --rc-label: #ffffff;
    --rc-radius: 14px;
    --rc-radius-sm: 10px;
    --rc-shadow-card: 0 30px 60px -20px rgba(9, 20, 54, 0.45), 0 8px 20px -10px rgba(9, 20, 54, 0.35);
    --rc-shadow-field: 0 1px 2px rgba(15, 23, 42, 0.06), 0 2px 8px rgba(15, 23, 42, 0.04);
    --rc-shadow-field-hover: 0 6px 20px rgba(10, 88, 202, 0.18), 0 2px 6px rgba(15, 23, 42, 0.05);
    --rc-transition: 220ms cubic-bezier(.4, 0, .2, 1);

    width: 100%;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--rc-text);
}
.rc_rent_car_form_wrapper *,
.rc_rent_car_form_wrapper *::before,
.rc_rent_car_form_wrapper *::after { box-sizing: border-box; }

/* ---------- Card shell ---------- */
.rc_rent_car_form {
    position: relative;
    padding: 28px;
    background: linear-gradient(155deg, rgba(15, 23, 42, 0.78) 0%, rgba(10, 21, 53, 0.85) 100%);
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--rc-radius);
    box-shadow: var(--rc-shadow-card);
    overflow: hidden;
}
.rc_rent_car_form::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(1200px circle at 0% 0%, rgba(29, 78, 216, 0.25), transparent 40%),
                radial-gradient(800px circle at 100% 100%, rgba(10, 88, 202, 0.22), transparent 45%);
    pointer-events: none; z-index: 0;
}
.rc_rent_car_form > * { position: relative; z-index: 1; }

/* ---------- Layout rows ---------- */
.rc_rent_car_form .rc-row {
    display: flex; flex-direction: column; gap: 18px; margin-bottom: 18px;
}
.rc_rent_car_form .rc-col { width: 100%; min-width: 0; }
.rc_rent_car_form .rc_rent_form_fields { display: flex; flex-direction: column; gap: 8px; }

/* ---------- Label ---------- */
.rc_rent_car_form .rc_form_title {
    color: var(--rc-label);
    font-size: 11px; font-weight: 700;
    letter-spacing: 1.4px; text-transform: uppercase;
    margin: 0; line-height: 1.2;
    opacity: 0.92;
    display: inline-flex; align-items: center; gap: 6px;
}
.rc_rent_car_form .rc_form_title::before {
    content: ''; width: 4px; height: 4px; border-radius: 50%;
    background: var(--rc-accent); box-shadow: 0 0 0 3px rgba(10, 88, 202, 0.22);
    display: inline-block;
}

/* ---------- Field base ---------- */
.rc_rent_car_form .rc_pickup_location,
.rc_rent_car_form .rc_date_input,
.rc_rent_car_form .rc_time_input { position: relative; }

.rc_rent_car_form .rc-location-select,
.rc_rent_car_form .rc_date_input input,
.rc_rent_car_form .rc_time_input input {
    display: block !important; visibility: visible !important; opacity: 1 !important;
    width: 100% !important; height: 52px !important; line-height: 52px;
    padding: 0 44px 0 44px !important; margin: 0 !important;
    border: 1px solid var(--rc-border) !important; border-radius: var(--rc-radius-sm) !important;
    background: var(--rc-surface) !important; color: var(--rc-text) !important;
    font-size: 15px !important; font-weight: 500 !important;
    text-transform: none !important; letter-spacing: normal !important;
    box-shadow: var(--rc-shadow-field) !important;
    cursor: pointer;
    transition: box-shadow var(--rc-transition), transform var(--rc-transition), border-color var(--rc-transition);
}
.rc_rent_car_form .rc_time_input input { padding-left: 44px !important; }

.rc_rent_car_form .rc-location-select:hover,
.rc_rent_car_form .rc_date_input input:hover,
.rc_rent_car_form .rc_time_input input:hover {
    box-shadow: var(--rc-shadow-field-hover) !important;
    border-color: rgba(10, 88, 202, 0.3) !important;
}
.rc_rent_car_form .rc-location-select:focus,
.rc_rent_car_form .rc_date_input input:focus,
.rc_rent_car_form .rc_time_input input:focus {
    outline: none !important;
    border-color: var(--rc-accent) !important;
    box-shadow: 0 0 0 3px rgba(10, 88, 202, 0.18), var(--rc-shadow-field-hover) !important;
}

/* ---------- Select specifics ---------- */
.rc_rent_car_form .rc-location-select {
    appearance: none; -webkit-appearance: none; -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7'%3E%3Cpath fill='%230f172a' d='M6 7L0 1l1-1 5 5 5-5 1 1z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 18px center !important;
    background-color: var(--rc-surface) !important;
}

/* ---------- Icons (pin / calendar / clock) ---------- */
.rc_rent_car_form .rc-icon-pin,
.rc_rent_car_form .rc-icon-date,
.rc_rent_car_form .rc-icon-time {
    position: absolute; left: 14px; top: 50%;
    width: 28px; height: 28px;
    transform: translateY(-50%);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, rgba(10, 88, 202, 0.12), rgba(29, 78, 216, 0.08));
    pointer-events: none; z-index: 2;
}
.rc_rent_car_form .rc-icon-pin::before,
.rc_rent_car_form .rc-icon-date::before,
.rc_rent_car_form .rc-icon-time::before {
    content: ''; width: 16px; height: 16px;
    background-repeat: no-repeat; background-position: center; background-size: contain;
}
.rc_rent_car_form .rc-icon-pin::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 384 512'%3E%3Cpath fill='%230a58ca' d='M172 502C27 291 0 269 0 192 0 86 86 0 192 0s192 86 192 192c0 77-27 99-172 310-10 14-30 14-40 0z'/%3E%3C/svg%3E");
}
.rc_rent_car_form .rc-icon-date::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 448 512'%3E%3Cpath fill='%230a58ca' d='M152 64h144V24c0-13 11-24 24-24s24 11 24 24v40h56c27 0 48 21 48 48v48H0v-48c0-27 21-48 48-48h56V24c0-13 11-24 24-24s24 11 24 24v40zM0 192h448v272c0 27-21 48-48 48H48c-27 0-48-21-48-48V192z'/%3E%3C/svg%3E");
}
.rc_rent_car_form .rc-icon-time::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'%3E%3Cpath fill='%230a58ca' d='M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256 256-114.6 256-256S397.4 0 256 0zm0 472c-119.3 0-216-96.7-216-216S136.7 40 256 40s216 96.7 216 216-96.7 216-216 216zm12-216H152c-6.6 0-12 5.4-12 12v16c0 6.6 5.4 12 12 12h140c6.6 0 12-5.4 12-12V124c0-6.6-5.4-12-12-12h-16c-6.6 0-12 5.4-12 12v132z'/%3E%3C/svg%3E");
}

/* ---------- Date + time row ---------- */
.rc_rent_car_form .rc-date-time-row { display: flex; gap: 10px; flex-wrap: nowrap; }
.rc_rent_car_form .rc_date_time_input { min-width: 0; }
.rc_rent_car_form .rc_date_time_input.date { flex: 1 1 62%; }
.rc_rent_car_form .rc_date_time_input.time { flex: 1 1 38%; }

/* ---------- Submit button ---------- */
.rc_rent_car_form .form-btn-wrap { margin-top: 22px; }
.rc_rent_car_form .rc-search-btn {
    position: relative;
    width: 100%; height: 58px; border: 0; border-radius: var(--rc-radius-sm);
    background: linear-gradient(135deg, var(--rc-accent) 0%, var(--rc-accent-2) 50%, var(--rc-accent-dark) 100%);
    background-size: 200% 200%; background-position: 0% 50%;
    color: #fff;
    font-family: inherit; font-size: 14px; font-weight: 700;
    letter-spacing: 1.8px; text-transform: uppercase;
    cursor: pointer; overflow: hidden;
    display: inline-flex; align-items: center; justify-content: center; gap: 12px;
    box-shadow: 0 14px 30px -10px rgba(10, 88, 202, 0.6), 0 4px 12px -4px rgba(10, 88, 202, 0.4);
    transition: transform var(--rc-transition), box-shadow var(--rc-transition), background-position 400ms ease;
}
.rc_rent_car_form .rc-search-btn::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(120deg, transparent 20%, rgba(255,255,255,0.25) 50%, transparent 80%);
    transform: translateX(-100%); transition: transform 600ms ease;
}
.rc_rent_car_form .rc-search-btn:hover {
    background-position: 100% 50%;
    transform: translateY(-1px);
    box-shadow: 0 22px 40px -12px rgba(10, 88, 202, 0.7), 0 6px 18px -6px rgba(10, 88, 202, 0.5);
}
.rc_rent_car_form .rc-search-btn:hover::after { transform: translateX(100%); }
.rc_rent_car_form .rc-search-btn:active { transform: translateY(0); }
.rc_rent_car_form .rc-search-btn:focus-visible { outline: 3px solid rgba(255,255,255,0.65); outline-offset: 2px; }
.rc_rent_car_form .rc-search-btn i { transition: transform var(--rc-transition); }
.rc_rent_car_form .rc-search-btn:hover i { transform: translateX(4px); }

/* ---------- Select2 integration (premium look) ---------- */
.rc_rent_car_form .rc_pickup_location .select2-container { width: 100% !important; }
.rc_rent_car_form .rc_pickup_location .select2-container--default .select2-selection--single {
    height: 52px !important; padding: 0 36px 0 44px !important;
    border: 1px solid var(--rc-border) !important; border-radius: var(--rc-radius-sm) !important;
    background: var(--rc-surface) !important;
    box-shadow: var(--rc-shadow-field) !important;
    display: flex; align-items: center;
    transition: box-shadow var(--rc-transition), border-color var(--rc-transition);
}
.rc_rent_car_form .rc_pickup_location .select2-container--default .select2-selection--single:hover {
    box-shadow: var(--rc-shadow-field-hover) !important;
    border-color: rgba(10, 88, 202, 0.3) !important;
}
.rc_rent_car_form .rc_pickup_location .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 52px !important; padding: 0 !important;
    color: var(--rc-text) !important; font-size: 15px; font-weight: 500;
}
.rc_rent_car_form .rc_pickup_location .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 52px !important; right: 14px;
}
.rc_rent_car_form .rc_pickup_location .select2-container--default.select2-container--focus .select2-selection--single,
.rc_rent_car_form .rc_pickup_location .select2-container--default.select2-container--open .select2-selection--single {
    border-color: var(--rc-accent) !important;
    box-shadow: 0 0 0 3px rgba(10, 88, 202, 0.18), var(--rc-shadow-field-hover) !important;
}
.rc_rent_car_form .rc_pickup_location .select2-hidden-accessible + .rc-location-select,
.rc_rent_car_form .rc_pickup_location select.select2-hidden-accessible { display: none !important; }
.select2-dropdown {
    z-index: 9999 !important;
    border: 1px solid var(--rc-border) !important;
    border-radius: var(--rc-radius-sm) !important;
    box-shadow: 0 20px 40px -12px rgba(9, 20, 54, 0.3) !important;
    overflow: hidden;
}
.select2-results__option--highlighted[aria-selected] { background-color: var(--rc-accent) !important; }

/* ---------- Flatpickr polish ---------- */
.flatpickr-calendar {
    border-radius: var(--rc-radius-sm) !important;
    box-shadow: 0 20px 50px -12px rgba(9, 20, 54, 0.35), 0 6px 16px -8px rgba(9, 20, 54, 0.2) !important;
    border: 1px solid var(--rc-border) !important;
    font-family: inherit;
}
.flatpickr-calendar.open { z-index: 9999; }
.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
    background: var(--rc-accent) !important; border-color: var(--rc-accent) !important;
}
.flatpickr-day.today { border-color: var(--rc-accent) !important; }
.flatpickr-day.selected, .flatpickr-day.selected:hover{
    color: #2f2f2f !important;
}
/* ---------- Responsive ---------- */
@media (max-width: 420px) {
    .rc_rent_car_form { padding: 20px; border-radius: 12px; }
    .rc_rent_car_form .rc-location-select,
    .rc_rent_car_form .rc_date_input input,
    .rc_rent_car_form .rc_time_input input { height: 48px !important; font-size: 14px !important; }
    .rc_rent_car_form .rc_pickup_location .select2-container--default .select2-selection--single { height: 48px !important; }
    .rc_rent_car_form .rc_pickup_location .select2-container--default .select2-selection--single .select2-selection__rendered { line-height: 48px !important; }
    .rc_rent_car_form .rc-search-btn { height: 52px; font-size: 13px; letter-spacing: 1.4px; }
    .rc_rent_car_form .rc-date-time-row { gap: 8px; }
}

@media (min-width: 768px) {
    .rc_rent_car_form { padding: 32px; }
    .rc_rent_car_form_wrapper:not(.compact) .rc-row { flex-direction: row; gap: 20px; }
    .rc_rent_car_form_wrapper:not(.compact) .rc-col { flex: 1 1 0; }
}

@media (min-width: 1200px) {
    .rc_rent_car_form { padding: 36px; }
    .rc_rent_car_form_wrapper:not(.compact) .rc-row { gap: 24px; }
}
