/* ============================================================================
   /rides — courses à la demande (VTC), parité avec l'écran natif.
   Deux rôles dans une seule page : passager et conducteur.
   Cf. docs/audit-transport-2026-07-22.md (T1→T4).
   ========================================================================= */
.rd-shell { padding: 12px 12px 90px; max-width: 720px; margin: 0 auto; }

.rd-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.rd-tab {
  border: 0; border-radius: 12px; padding: 12px 8px; cursor: pointer;
  font: 800 13px Nunito, sans-serif; font-family: inherit;
  background: var(--surface-2, #F1F5F9); color: var(--text-muted, #64748B);
}
.rd-tab.active { background: linear-gradient(135deg, #6750A4, #7F67BE); color: #fff; }

.rd-filters { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 8px; }
.rd-pill {
  flex: 0 0 auto; border: 1.5px solid var(--border, #E2E8F0); background: transparent;
  border-radius: 999px; padding: 7px 14px; font: 700 12.5px inherit; cursor: pointer;
  color: var(--text, #0F172A);
}
.rd-pill.active { background: #6750A4; border-color: #6750A4; color: #fff; }

.rd-h2 { font-size: 15px; font-weight: 900; margin: 16px 0 8px; }
.rd-list { display: flex; flex-direction: column; gap: 10px; }

.rd-card {
  background: var(--surface, #fff); border-radius: 16px; padding: 14px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
}
.rd-card-row { display: flex; align-items: center; gap: 10px; }
.rd-veh-icon {
  width: 42px; height: 42px; border-radius: 12px; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center; color: #fff; font-size: 16px;
}
.rd-veh-name { font-weight: 800; font-size: 14.5px; }
.rd-veh-sub { font-size: 12px; color: var(--text-muted, #64748B); }

/* La contenance : l'information qui décide. Verte s'il reste de la place, rouge si complet. */
.rd-seats {
  flex: 0 0 auto; border-radius: 10px; padding: 7px 10px;
  font: 900 13px inherit; text-align: center; line-height: 1.1;
}
.rd-seats.ok { background: rgba(22, 163, 74, 0.12); color: #16A34A; }
.rd-seats.full { background: rgba(220, 38, 38, 0.12); color: #DC2626; }

/* La DESTINATION domine la carte côté conducteur : c'est sur elle qu'il décide. */
.rd-dest-label { font-size: 10.5px; font-weight: 900; letter-spacing: 1.4px; color: var(--text-muted, #64748B); }
.rd-dest { font-size: 22px; font-weight: 900; line-height: 1.15; margin: 2px 0 6px; word-break: break-word; }

.rd-btn {
  border: 0; border-radius: 12px; padding: 14px; width: 100%; cursor: pointer;
  font: 900 15px inherit; display: flex; align-items: center; justify-content: center; gap: 8px;
}
.rd-btn-primary { background: #6750A4; color: #fff; }
.rd-btn-go { background: #16A34A; color: #fff; }
.rd-btn-stop { background: #DC2626; color: #fff; }
.rd-btn-ghost { background: transparent; border: 1.5px solid var(--border, #E2E8F0); color: var(--text, #0F172A); }
.rd-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.rd-actions { display: flex; gap: 10px; margin-top: 12px; }
.rd-actions .rd-btn { flex: 1; }
.rd-actions .rd-btn.wide { flex: 1.4; }

.rd-badge {
  display: inline-block; border-radius: 8px; padding: 3px 8px;
  font: 800 11px inherit; background: var(--surface-2, #F1F5F9); color: var(--text-muted, #64748B);
}
.rd-badge.pending { background: rgba(245, 158, 11, 0.15); color: #B45309; }
.rd-badge.accepted, .rd-badge.aboard { background: rgba(22, 163, 74, 0.15); color: #16A34A; }
.rd-badge.rejected, .rd-badge.cancelled, .rd-badge.no_show { background: rgba(220, 38, 38, 0.12); color: #DC2626; }

.rd-empty { font-size: 13px; color: var(--text-muted, #64748B); padding: 14px; text-align: center; }

.rd-stars { display: flex; gap: 6px; margin-top: 10px; }
.rd-star {
  width: 40px; height: 40px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--surface-2, #F1F5F9); color: #F59E0B; font-size: 15px;
}

/* Feuille modale */
.rd-sheet { position: fixed; inset: 0; z-index: 60; display: none; }
.rd-sheet[data-open="1"] { display: block; }
.rd-sheet-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.5); }
.rd-sheet-card {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: var(--surface, #fff); border-radius: 22px 22px 0 0;
  padding: 20px 16px calc(20px + env(safe-area-inset-bottom));
  max-height: 88dvh; overflow-y: auto;
}
.rd-sheet-x {
  position: absolute; top: 12px; right: 12px; width: 34px; height: 34px;
  border: 0; border-radius: 999px; background: var(--surface-2, #F1F5F9); cursor: pointer;
}
.rd-field { margin-bottom: 12px; }
.rd-field label { display: block; font-size: 12px; font-weight: 800; margin-bottom: 5px; }
.rd-field input, .rd-field select {
  width: 100%; padding: 12px 14px; font: 500 15px inherit;
  border: 1.5px solid var(--border, #E2E8F0); border-radius: 12px; background: transparent;
  color: var(--text, #0F172A);
}
.rd-hint { font-size: 11.5px; color: var(--text-muted, #64748B); margin-top: 4px; line-height: 1.4; }
