/* ==========================================================
   ELITE AUTO — FORM THEME
   Fichier: assets/css/form.css
   Rôle: Style premium + modules (pickup, cards, etc.)
   ========================================================== */

/* === TOKENS ELITE AUTO =================================== */
:root{
  --ea-bg0:#050a14;
  --ea-bg1:#07142a;

  --ea-card:rgba(255,255,255,.06);
  --ea-line:rgba(255,255,255,.12);

  --ea-text:#eaf0ff;
  --ea-muted:rgba(234,240,255,.74);

  --ea-accent:#2aa7ff;
  --ea-accent2:#6a5cff;

  --ea-radius:22px;
  --ea-shadow: 0 18px 60px rgba(0,0,0,.45);

  --ea-warning:#ffb020;

  --ea-field-bg: rgba(0,0,0,.22);
  --ea-field-border: rgba(255,255,255,.14);
}

/* ==========================================================
   SYSTEME.IO — Masquages (si tu injectes dans System.io)
   (Si site “standalone”, ces règles ne gênent pas)
   ========================================================== */
h2:not(#reservationForm h2):not(.form-wrap h2) {
  display:none !important; visibility:hidden !important; opacity:0 !important;
  height:0 !important; margin:0 !important; padding:0 !important;
}
h1:not(.form-wrap h1, .form-wrap h2, .form-wrap h3),
.systeme-header, .systeme-title,
[class*="systeme"]:not(.form-wrap *),
[id*="systeme"]:not(.form-wrap *),
[class*="System"]:not(.form-wrap *),
[id*="System"]:not(.form-wrap *),
div[id*="rawhtml"] > h2:first-child,
.sc-gUmHl {
  display:none !important; visibility:hidden !important; opacity:0 !important;
  height:0 !important; margin:0 !important; padding:0 !important;
}

/* ==========================================================
   BASE
   ========================================================== */
*{ box-sizing:border-box; }
html, body{ height:100%; }

body{
  margin:0;
  font-family:"Poppins", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--ea-text);
  background:
    radial-gradient(1200px 700px at 50% -10%, rgba(42,167,255,.14), transparent 60%),
    linear-gradient(180deg, var(--ea-bg0) 0%, var(--ea-bg1) 40%, var(--ea-bg0) 100%);
}

.form-wrap{
  display:flex;
  justify-content:center;
  align-items:center;
  min-height:100vh;
  padding:42px 16px;
}

/* ==========================================================
   FORM CONTAINER (glass premium)
   ========================================================== */
form{
  width:100%;
  max-width:860px;
  border-radius: var(--ea-radius);
  background: var(--ea-card);
  border:1px solid var(--ea-line);
  box-shadow: var(--ea-shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding:22px;
  position:relative;
  overflow:hidden;
}
form::before{
  content:"";
  position:absolute; inset:-2px;
  background:
    radial-gradient(900px 520px at 20% 0%, rgba(106,92,255,.20), transparent 60%),
    radial-gradient(900px 520px at 90% 10%, rgba(42,167,255,.16), transparent 55%);
  pointer-events:none;
  z-index:0;
}
form > *{ position:relative; z-index:1; }

/* ==========================================================
   HEADER LOGO
   ========================================================== */
.form-header-logo{
  text-align:center;
  margin-bottom:14px;
  padding:14px;
  border-radius:18px;
  background: rgba(0,0,0,.20);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 14px 35px rgba(0,0,0,.28);
}
.form-header-logo img{
  max-width:220px;
  max-height:84px;
  height:auto;
  display:inline-block;
  object-fit:contain;
  filter: drop-shadow(0 12px 28px rgba(0,0,0,.45));
}
.form-header-logo img[src=""],
.form-header-logo img:not([src]){ display:none; }

/* ==========================================================
   TITRES
   ========================================================== */
h2{
  margin:14px 0 6px 0;
  text-align:center;
  font-weight:900;
  letter-spacing:-.4px;
  font-size: clamp(22px, 2.2vw, 30px);
  color: rgba(234,240,255,.96);
  text-shadow: 0 14px 40px rgba(0,0,0,.50);
}
p.subtitle{
  margin:0 0 18px 0;
  text-align:center;
  color: var(--ea-muted);
  font-weight:650;
  font-size:14.5px;
  line-height:1.55;
}

/* ==========================================================
   GRID / LAYOUT
   ========================================================== */
.grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
}
.full{ grid-column: 1 / -1; }

/* ==========================================================
   LABELS / NOTES
   ========================================================== */
label{
  display:block;
  margin-bottom:8px;
  font-weight:800;
  font-size:13.5px;
  color: rgba(234,240,255,.90);
}
.km-note,
.prestige-note,
.pickup-small,
.hw-note{
  font-size:12px;
  color: var(--ea-muted);
  margin-top:6px;
  line-height:1.45;
}
.condition-sub{ font-size:12px; color:#6b7280; }

/* ==========================================================
   INPUTS / SELECT / TEXTAREA
   ========================================================== */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select,
textarea{
  width:100%;
  padding:12px 12px;
  border-radius:14px;
  border:1px solid var(--ea-field-border);
  background: var(--ea-field-bg);
  color: rgba(234,240,255,.92);
  font-size:14px;
  font-weight:650;
  outline:none;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
}
textarea{ min-height:92px; resize:vertical; }
input::placeholder, textarea::placeholder{ color: rgba(234,240,255,.45); }

select{
  appearance:none;
  -webkit-appearance:none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(234,240,255,.55) 50%),
    linear-gradient(135deg, rgba(234,240,255,.55) 50%, transparent 50%),
    linear-gradient(to right, transparent, transparent);
  background-position:
    calc(100% - 18px) calc(50% - 3px),
    calc(100% - 12px) calc(50% - 3px),
    0 0;
  background-size: 6px 6px, 6px 6px, 100% 100%;
  background-repeat:no-repeat;
  padding-right:34px;
}
select option{ color:#0b1220; }
select option:disabled{ color:#6b7280; }
select:disabled{ background: rgba(255,255,255,.06); cursor:not-allowed; opacity:.75; }

input:focus, select:focus, textarea:focus{
  border-color: rgba(42,167,255,.45);
  box-shadow: 0 0 0 6px rgba(42,167,255,.12);
  background: rgba(0,0,0,.26);
}

/* ==========================================================
   CONDITIONS D’ACCES
   ========================================================== */
.access-conditions{
  background:
    radial-gradient(520px 240px at 20% 0%, rgba(106,92,255,.18), transparent 60%),
    radial-gradient(520px 240px at 90% 10%, rgba(42,167,255,.14), transparent 55%),
    rgba(0,0,0,.18);
  border:1px solid rgba(42,167,255,.35);
  border-radius:18px;
  padding:16px;
  margin-bottom:18px;

  overflow:hidden;
  max-height:560px;
  transition:
    opacity .22s ease,
    transform .22s ease,
    max-height .34s ease,
    margin .34s ease,
    padding .34s ease,
    border-width .34s ease;
}
.access-conditions.is-collapsing{
  opacity:0 !important;
  transform: translateY(-6px) !important;
  max-height:0 !important;
  margin-bottom:0 !important;
  padding-top:0 !important;
  padding-bottom:0 !important;
  border-width:0 !important;
  pointer-events:none !important;
}
.access-conditions h3{
  margin:0 0 12px 0;
  text-align:center;
  font-weight:950;
  font-size:16px;
  letter-spacing:-.2px;
  color: rgba(234,240,255,.95);
}
.condition-option{
  display:flex;
  align-items:flex-start;
  gap:12px;
  padding:12px;
  margin-bottom:10px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.18);
  cursor:pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}
.condition-option:hover{
  transform: translateY(-1px);
  border-color: rgba(42,167,255,.32);
  box-shadow: 0 18px 55px rgba(42,167,255,.12);
}
.condition-option.selected{
  border-color: rgba(42,167,255,.42);
  background: rgba(42,167,255,.10);
}
.condition-option input[type="radio"]{
  width:18px;
  height:18px;
  margin-top:2px;
  accent-color: var(--ea-accent);
  cursor:pointer;
}
.condition-option label{
  margin:0;
  font-weight:750;
  font-size:14px;
  color: rgba(234,240,255,.92);
}

/* Formulaire désactivé tant que conditions non validées */
.form-content.disabled{
  opacity:.45;
  pointer-events:none;
  user-select:none;
}

/* ==========================================================
   OPTIONS
   ========================================================== */
.options-group{
  display:grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap:10px 12px;
  align-items:start;
  margin-top:10px;
}
.option-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding:10px 10px;
  border-radius:16px;
  background: rgba(0,0,0,.16);
  border:1px solid rgba(255,255,255,.10);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
  font-size:14px;
}
.option-item:hover{
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.16);
  background: rgba(0,0,0,.18);
}
.option-item input[type="checkbox"]{
  width:18px;
  height:18px;
  accent-color: var(--ea-accent);
}
.option-item label{
  margin:0 !important;
  font-weight:750;
  font-size:13.5px;
  color: rgba(234,240,255,.88);
}

/* ==========================================================
   ESTIMATE / CONFIRM
   ========================================================== */
.estimate{
  margin-top:14px;
  padding:12px 12px;
  border-radius:18px;
  text-align:center;
  font-weight:950;
  color: rgba(234,240,255,.92);
  background:
    radial-gradient(520px 240px at 20% 0%, rgba(106,92,255,.18), transparent 60%),
    radial-gradient(520px 240px at 90% 10%, rgba(42,167,255,.14), transparent 55%),
    rgba(0,0,0,.18);
  border:1px solid rgba(255,255,255,.12);
  transition: transform .18s ease, filter .18s ease, background .18s ease;
  line-height:1.35;
}
.estimate.updated{ transform: scale(1.01); filter: brightness(1.03); }

.confirm-box{
  margin-top:12px;
  padding:12px;
  border-radius:18px;
  background: rgba(0,0,0,.18);
  border:1px solid rgba(255,255,255,.12);
  color: rgba(234,240,255,.90);
  font-weight:800;
  text-align:center;
}

/* ==========================================================
   ACTIONS / BUTTON
   ========================================================== */
.actions{
  margin-top:16px;
  display:flex;
  gap:12px;
  align-items:center;
}
button{
  width:100%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding:14px 18px;
  border-radius:999px;
  border:none;
  cursor:pointer;
  user-select:none;
  -webkit-tap-highlight-color: transparent;

  font-weight:950;
  font-size:15px;
  line-height:1;

  color:#06101f;
  background: linear-gradient(135deg, var(--ea-accent), var(--ea-accent2));
  box-shadow: 0 18px 55px rgba(42,167,255,.22);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
button:hover{
  transform: translateY(-1px);
  box-shadow: 0 22px 70px rgba(42,167,255,.28);
  filter: brightness(1.03);
}
button[disabled]{
  opacity:.6;
  cursor:not-allowed;
  transform:none;
  box-shadow:none;
  filter:none;
}

/* ==========================================================
   VEHICLE CARD
   ========================================================== */
.vehicle-card{
  margin-top:16px;
  padding:14px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,.12);
  background:
    radial-gradient(520px 240px at 20% 0%, rgba(106,92,255,.18), transparent 60%),
    radial-gradient(520px 240px at 90% 10%, rgba(42,167,255,.14), transparent 55%),
    rgba(0,0,0,.18);
  box-shadow: 0 18px 55px rgba(0,0,0,.35);
  animation: slideIn .28s ease;
  display:grid;
  grid-template-columns: 240px 1fr;
  gap:14px;
  align-items: stretch;
}
@keyframes slideIn{
  from{ opacity:0; transform: translateY(-8px); }
  to{ opacity:1; transform: translateY(0); }
}
.vehicle-card > img{
  width:100%;
  height:170px;
  min-height:170px;
  object-fit: cover;
  object-position:center;
  background: rgba(255,255,255,.04);
  border-radius:16px;
  display:block;
  border:1px solid rgba(255,255,255,.12);
}
.vehicle-card > img[data-fit="contain"]{
  object-fit: contain;
  background: rgba(255,255,255,.06);
}
.vehicle-card-header{
  display:flex;
  align-items: baseline;
  justify-content: space-between;
  gap:10px;
  margin-bottom:10px;
}
.vehicle-card-title{
  font-weight:950;
  font-size:16px;
  margin:0;
  letter-spacing:-.2px;
  color: rgba(234,240,255,.95);
}
.vehicle-card-price{
  font-weight:950;
  font-size:13px;
  color: rgba(234,240,255,.95);
  background: rgba(42,167,255,.12);
  border: 1px solid rgba(42,167,255,.30);
  padding:7px 10px;
  border-radius:999px;
  white-space: nowrap;
}
.vehicle-specs{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:10px;
}
.spec-item{
  display:flex;
  align-items:center;
  gap:8px;
  padding:10px 10px;
  background: rgba(255,255,255,.06);
  border-radius:14px;
  font-size:12px;
  font-weight:800;
  border:1px solid rgba(255,255,255,.10);
  color: rgba(234,240,255,.88);
}
.spec-icon{ font-size:16px; flex-shrink:0; }

/* ==========================================================
   PICKUP (Retrait/Retour) — skin
   ========================================================== */
.pickup-wrap{ grid-column: 1 / -1; margin-top: 6px; }
.pickup-title{
  display:block;
  margin-bottom:8px;
  font-weight:900;
  font-size:13.5px;
  color: rgba(234,240,255,.90);
}
.pickup-row{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
  align-items:start;
}
.pickup-col{ display:flex; flex-direction:column; gap:8px; }
.pickup-label{
  margin:0;
  font-weight:800;
  font-size:13.5px;
  color: rgba(234,240,255,.90);
}
.pickup-btn{
  width:100%;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
  padding:12px 12px;
  border-radius:14px;
  border:1px solid var(--ea-field-border);
  background: var(--ea-field-bg);
  color: rgba(234,240,255,.92);
  cursor:pointer;
  font-weight:850;
  text-align:left;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease, transform .18s ease;
}
.pickup-btn:hover{
  transform: translateY(-1px);
  border-color compiler: rgba(255,255,255,.18);
  background: rgba(0,0,0,.26);
}
.pickup-btn[disabled]{ opacity:.6; cursor:not-allowed; transform:none; }
.pickup-btn .chev{ opacity:.7; font-weight: 950; }
.pickup-btn #pickupAllerValue,
.pickup-btn #pickupRetourValue{
  font-weight:750;
  color: rgba(234,240,255,.70);
}
.pickup-panel{
  display:none;
  border:1px solid rgba(255,255,255,.12);
  border-radius:16px;
  padding:10px;
  background: rgba(0,0,0,.18);
}
.pickup-opt{
  display:flex;
  gap:10px;
  align-items:flex-start;
  padding:10px;
  border-radius:14px;
  cursor:pointer;
  transition: background .18s ease, border-color .18s ease;
  border:1px solid transparent;
}
.pickup-opt:hover{
  background: rgba(42,167,255,.08);
  border-color: rgba(42,167,255,.14);
}
.pickup-opt input{
  margin-top:2px;
  width:18px;
  height:18px;
  accent-color: var(--ea-accent);
}
.pickup-opt span{
  color: rgba(234,240,255,.88);
  font-weight:750;
  font-size:13.5px;
}
.pickup-head{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap:10px;
  margin-bottom:2px;
}
.same-inline{
  display:flex;
  align-items:center;
  gap:8px;
  font-size:13px;
  color: rgba(234,240,255,.70);
  font-weight:850;
  cursor:pointer;
  user-select:none;
  margin:0;
}
.same-inline input{
  width:16px;
  height:16px;
  accent-color: var(--ea-accent);
  margin:0;
}
.hw-box{
  display:none;
  margin-top:8px;
  padding:12px;
  border-radius:16px;
  border:1px dashed rgba(42,167,255,.35);
  background: rgba(42,167,255,.08);
}
.hw-box .hw-title{
  font-weight:950;
  margin-bottom:8px;
  font-size:13px;
  color: rgba(234,240,255,.92);
}

/* ==========================================================
   ALERTS / NOTICES
   ========================================================== */
.prestige-alert{
  background: rgba(255,176,32,.10);
  border: 1px solid rgba(255,176,32,.26);
  border-radius:16px;
  padding:12px;
  margin-top:10px;
  font-size:13px;
  color: rgba(255,236,210,.92);
  display:flex;
  align-items:flex-start;
  gap:10px;
}
.prestige-alert strong{ color: rgba(255,255,255,.96); }
.prestige-alert-icon{ font-size:18px; flex-shrink:0; }

.km-locked-notice{
  background: rgba(255,176,32,.10);
  border: 1px solid rgba(255,176,32,.24);
  border-radius:14px;
  padding:10px;
  margin-top:8px;
  font-size:12px;
  color: rgba(255,236,210,.92);
  font-weight:800;
}

/* ==========================================================
   REDIRECT LINKS
   ========================================================== */
.redirect-links{
  margin-top:12px;
  display:flex;
  gap:10px;
  flex-wrap: wrap;
  justify-content:center;
}
.redirect-links a{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:12px 14px;
  border-radius:999px;
  text-decoration:none;
  font-weight:950;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  color: rgba(234,240,255,.92);
  transition: transform .18s ease, background .18s ease, border-color .18s ease;
}
.redirect-links a:hover{
  transform: translateY(-1px);
  border-color: rgba(42,167,255,.30);
  background: rgba(42,167,255,.10);
}

/* ==========================================================
   RESPONSIVE
   ========================================================== */
@media (max-width: 980px){
  form{ padding:18px; }
}
@media (max-width: 860px){
  .grid{ grid-template-columns: 1fr; }
  .options-group{ grid-template-columns: 1fr; }
  .pickup-row{ grid-template-columns: 1fr; }
}
@media (max-width: 768px){
  .vehicle-card{ grid-template-columns: 1fr; }
  .vehicle-card > img{ height: 190px; min-height: 190px; }
  .vehicle-specs{ grid-template-columns: 1fr; }
}

/* NOTE: petit correctif typo si besoin */
#unlimitedNotice{ color: var(--ea-warning); font-weight: 600; }
