/* ============================================================
   ZenCAR — reservationStyles.css
   CSS UNIQUEMENT pour le formulaire de réservation (tabs, map, véhicules)
   Les styles globaux (variables, navbar, hero, cartes, etc.) sont dans zencar.css
   ============================================================ */

/* ── Variables spécifiques formulaire ──────────────────────── */
:root {
  --zen-orange-dim: rgba(255, 86, 48, 0.15);
  --zen-bg:         rgba(255, 255, 255, 0.04);
  --zen-border:     rgba(255, 255, 255, 0.15);
  --zen-muted:      #cccccc;
}

/* ============================================================
   SECTION "POURQUOI CHOISIR" (home)
   ============================================================ */
.pourquoi-choisir-Zencar { padding: clamp(24px, 5vw, 50px) 8px; }
.pourquoi-choisir-Zencar .h4 { font-size: clamp(1rem, 3vw, 1.4rem); }

/* ============================================================
   TABS (onglets réservation)
   ============================================================ */
.tabs {
  display: flex;
  border-bottom: 1px solid #444;
  margin-bottom: 20px;
  width: 100%;
  max-width: 960px;
}
@media (max-width: 359px) { .tabs { display: none !important; } }

.tab-button {
  flex: 1;
  padding: 10px 4px;
  cursor: pointer;
  text-align: center;
  background: none;
  border: none;
  outline: none;
  font-size: clamp(.75rem, 2.2vw, 1rem);
  color: white;
  white-space: nowrap;
}
.tab-button.active {
  border-bottom: 3px solid var(--zen-orange);
  font-weight: 700;
}
@media (max-width: 399px) {
  .tab-button { white-space: normal; line-height: 1.2; padding: 8px 2px; }
}

/* ============================================================
   CONTENEUR GÉNÉRAL (home / réservation)
   ============================================================ */
#reservation-test-container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: Arial, sans-serif;
  color: white;
  width: 100%;
  padding: 0 8px;
}

.tab-content { width: 100%; max-width: 960px; display: none; }
.tab-content.active { display: block; }

.general-container {
  border: 1px solid var(--zen-border);
  border-radius: 8px;
  background: var(--zen-bg);
  padding: 16px;
  position: relative;
}
@media (min-width: 576px) { .general-container { padding: 24px; } }
@media (min-width: 768px) { .general-container { padding: 32px; } }

/* ============================================================
   TAB 1 — FORMULAIRE + CARTE
   ============================================================ */

/* Layout tab1 : empilé mobile → 50/50 dès 768px */
.tab1-layout {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
}
.tab1-layout > * { min-width: 0; }

@media (min-width: 768px) {
  .tab1-layout {
    flex-direction: row;
    align-items: flex-start;
    gap: 24px;
  }
  .tab1-layout > .donneesClient,
  .tab1-layout > .carte {
    flex: 1 1 0;
    width: calc(50% - 12px);
    min-width: 0;
  }
}

/* ── Champs formulaire ──────────────────────────────────────── */
.donneesClient { width: 100%; }

.form-group {
  margin-bottom: 16px;
  position: relative;
}
.form-group label {
  font-weight: 500;
  color: var(--zen-muted);
  display: block;
  margin-bottom: 6px;
  font-size: clamp(.82rem, 2vw, .95rem);
}

.form-control,
.form-select,
.input-group-text,
textarea {
  background: var(--zen-bg) !important;
  color: white !important;
  border: 1px solid var(--zen-border) !important;
  font-size: clamp(.82rem, 2vw, .95rem) !important;
}
.form-control:focus,
.form-select:focus,
textarea:focus {
  background: var(--zen-bg) !important;
  color: white !important;
  border-color: var(--zen-orange) !important;
  box-shadow: 0 0 0 .2rem rgba(255, 86, 48, .25) !important;
}
input::placeholder,
textarea::placeholder {
  color: rgba(255,255,255,.45) !important;
  font-size: clamp(.78rem, 1.8vw, .9rem) !important;
}

.input-group { display: flex; width: 100%; }
.input-group-text {
  display: flex;
  align-items: center;
  padding: 0 10px;
  font-size: .9rem;
}

.inline-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* Bouton géolocalisation */
.btn-geoloc {
  display: none;
  font-size: .78rem;
  padding: 5px 10px;
  margin-top: 6px;
  color: var(--zen-muted);
  border: 1px solid var(--zen-border);
  background: transparent;
  border-radius: 4px;
  cursor: pointer;
  align-items: center;
  gap: 5px;
}
@media (min-width: 577px) { .btn-geoloc { display: inline-flex; } }

/* ── Carte HERE Maps ────────────────────────────────────────── */
.carte { width: 100%; }

#mapContainer {
  width: 100% !important;
  height: 260px !important;
  border-radius: 8px;
  overflow: hidden !important;
  border: 2px solid var(--zen-border);
  position: relative;
}
@media (min-width: 400px) { #mapContainer { height: 300px !important; } }
@media (min-width: 576px) { #mapContainer { height: 360px !important; } }
@media (min-width: 768px) { #mapContainer { height: 420px !important; } }
@media (min-width: 992px) { #mapContainer { height: 460px !important; } }

.map-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
  font-size: clamp(.8rem, 2vw, .9rem);
}
@media (min-width: 400px) {
  .map-info { flex-direction: row; }
  .map-info .distance-box,
  .map-info .duration-box { flex: 1; }
}

/* ── Boutons temps (Immédiat / Plus tard) ───────────────────── */
.time-btn {
  padding: 8px 14px;
  min-height: 44px;
  border: 1px solid var(--zen-border);
  border-radius: 6px;
  background: var(--zen-bg);
  color: white;
  cursor: pointer;
  font-size: clamp(.8rem, 2vw, .95rem);
  transition: all .2s;
}
.time-btn.active { background: #303aff; border-color: #303aff; }

/* ============================================================
   BOUTONS NAVIGATION (Suivant / Retour)
   ============================================================ */
.button-group {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.nav-main-btn {
  background: var(--zen-orange);
  border: none;
  padding: 12px 22px;
  min-height: 44px;
  border-radius: 8px;
  color: white;
  font-size: clamp(.82rem, 2vw, 1rem);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background .2s;
  white-space: nowrap;
}
.nav-main-btn:hover { background: #e04020; }

.back-btn {
  background: #555;
  color: white;
  padding: 10px 16px;
  min-height: 44px;
  font-size: clamp(.8rem, 2vw, .9rem);
  border-radius: 8px;
  border: none;
  cursor: pointer;
}

/* ============================================================
   TAB 2 — VÉHICULES
   ============================================================ */
.vehicle-card {
  background: rgba(255,255,255,.05);
  border: 1px solid var(--zen-border);
  border-radius: 10px;
  padding: 14px 12px;
  color: white;
  cursor: pointer;
  transition: all .2s ease;
}
.vehicle-card:hover {
  background: rgba(255,255,255,.1);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,.3);
}
.vehicle-card.active {
  border-color: var(--zen-orange);
  background: var(--zen-orange-dim);
}
.vehicle-card h5           { font-size: clamp(.85rem, 2vw, 1.05rem); }
.vehicle-card .vehicle-price { font-size: clamp(.8rem, 2vw, .95rem); }

/* ============================================================
   TAB 3 — RÉCAPITULATIF
   ============================================================ */
#tab3 h2  { font-size: clamp(1.1rem, 3vw, 1.5rem); }
#tab3 ul  { padding-left: 0; list-style: none; font-size: clamp(.82rem, 2vw, 1rem); }
#tab3 ul li {
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  line-height: 1.5;
}
#tab3 ul li:last-child { border-bottom: none; }

#confirmReservationBtn {
  min-height: 44px;
  padding-top: 10px;
  padding-bottom: 10px;
}

#sendOtpBtn { width: 100%; }
@media (min-width: 576px) { #sendOtpBtn { width: auto; } }

#guest-verification-section h5 { font-size: clamp(.9rem, 2vw, 1.1rem); }

/* ============================================================
   AUTOCOMPLÉTION
   ============================================================ */
.autocomplete-list {
  position: absolute;
  z-index: 9999;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: rgba(20, 21, 30, .97);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 0 0 12px 12px;
  max-height: 220px;
  overflow-y: auto;
  list-style: none;
  padding: 0;
  margin: 0;
  box-shadow: 0 8px 20px rgba(0,0,0,.4);
  backdrop-filter: blur(6px);
}
.autocomplete-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  font-size: clamp(.78rem, 2vw, .92rem);
  color: white;
  border-top: 1px solid rgba(255,255,255,.04);
  cursor: pointer;
  transition: background .15s;
}
.autocomplete-list li:first-child { border-top: none; }
.autocomplete-list li:hover       { background: var(--zen-orange-dim); }
.autocomplete-list .icon          { color: var(--zen-orange); font-size: .95rem; }

/* ============================================================
   ERREURS FORMULAIRE
   ============================================================ */
.form-error {
  color: var(--zen-orange);
  font-size: .8rem;
  margin-top: 4px;
  display: block;
}
.symfony-error {
  color: white !important;
  background: rgba(255, 0, 0, .22);
  padding: 10px 14px;
  border-radius: 6px;
  font-size: clamp(.82rem, 2vw, .95rem);
  animation: fadeError .3s ease;
}
