/* Styles globaux : erreurs, validation, accessibilité, responsive */

/* Messages d'erreur */
.msg-error,
.input-error {
  color: var(--danger, #ef4444);
}

.msg-error {
  font-size: 0.9rem;
  margin-top: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(239, 68, 68, 0.1);
  border-radius: 8px;
  border-left: 3px solid var(--danger, #ef4444);
}

.msg-success {
  font-size: 0.9rem;
  margin-top: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(34, 197, 94, 0.1);
  border-radius: 8px;
  border-left: 3px solid #4ade80;
  color: #4ade80;
}

/* Validation input */
input:invalid:not(:placeholder-shown):not(:focus),
input.input-invalid,
select.input-invalid,
textarea.input-invalid {
  border-color: var(--danger, #ef4444);
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.2);
}

input:focus:invalid:not(:placeholder-shown),
input.input-invalid:focus {
  border-color: var(--danger, #ef4444);
}

/* Accessibilité : focus visible */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent, #38bdf8);
  outline-offset: 2px;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  padding: 8px 16px;
  background: var(--accent, #38bdf8);
  color: #020617;
  font-weight: 600;
  z-index: 100;
  transition: top 0.2s;
}

.skip-link:focus {
  top: 0;
}

/* Aria live */
[aria-live="polite"],
[aria-live="assertive"] {
  min-height: 1em;
}

/* Responsive : auth pages */
@media (max-width: 480px) {
  .auth__box {
    padding: 0 0.5rem;
  }
  .auth h1 {
    font-size: 1.5rem;
  }
}

/* ========== NAVBAR CHAUFFEUR SaaS PREMIUM (unique sur toutes les pages) ========== */
.chauffeur-header {
  position: sticky;
  top: 0;
  background: linear-gradient(90deg, #071a2d, #0b223a);
  backdrop-filter: blur(8px);
  padding: 0 28px;
  z-index: 1000;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.chauffeur-header .nav-container {
  position: relative;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-left a {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

.nav-logo {
  height: 28px;
  display: block;
}

.nav-title {
  font-weight: 600;
  color: white;
  font-size: 16px;
}

.nav-center {
  display: flex;
  gap: 24px;
  flex: 1;
  justify-content: center;
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-center a {
  color: #94a3b8;
  text-decoration: none;
  font-size: 14px;
  transition: 0.2s ease;
}

.nav-center a:hover {
  color: #00d4ff;
}

.nav-center a.active {
  color: #00d4ff;
  font-weight: 600;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.btn-profile {
  background: #00d4ff;
  color: #071a2d;
  padding: 8px 18px;
  border-radius: 20px;
  font-weight: 600;
  text-decoration: none;
  transition: 0.2s ease;
}

.btn-profile:hover {
  background: #00bde6;
}

.btn-client {
  color: #94a3b8;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 6px 12px;
  border: 1px solid #334155;
  border-radius: 20px;
  transition: 0.2s ease;
}

.btn-client:hover {
  color: #00d4ff;
  border-color: #00d4ff;
}

.btn-logout {
  color: #94a3b8;
  text-decoration: none;
  font-size: 14px;
  transition: 0.2s ease;
}

.btn-logout:hover {
  color: #00d4ff;
}

.burger {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.burger span {
  width: 22px;
  height: 2px;
  background: white;
  transition: 0.3s ease;
}

@media (max-width: 1000px) {
  .nav-center {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: #071a2d;
    flex-direction: column;
    padding: 20px;
    gap: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .nav-center.open {
    display: flex;
  }

  .burger {
    display: flex;
  }
}

/* ========== PHOTO CHAUFFEUR OBLIGATOIRE ========== */
.badge-required { background: rgba(255, 59, 48, 0.15); color: #ff3b30; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge-pending { background: rgba(255, 149, 0, 0.15); color: #ff9500; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge-approved { background: rgba(52, 199, 89, 0.15); color: #34c759; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }

.doc-row.doc-photo {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1.5rem;
  padding: 1.25rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.doc-row .doc-left { flex: 1; min-width: 200px; }
.doc-row .doc-title { font-weight: 600; font-size: 1rem; margin: 0 0 0.35rem; color: var(--text, #e5e7eb); }
.doc-row .doc-sub { font-size: 0.9rem; color: var(--text-muted, #94a3b8); margin: 0; line-height: 1.4; }
.doc-row .doc-right { flex-shrink: 0; }

.photo-box { display: flex; flex-direction: column; gap: 10px; min-width: 260px; }
.photo-live { position: relative; width: 260px; height: 260px; border-radius: 16px; overflow: hidden; background: #1e293b; border: 1px solid rgba(255, 255, 255, 0.08); }
#driverCam { width: 100%; height: 100%; object-fit: cover; }
.photo-preview { display: none; width: 260px; height: 260px; border-radius: 16px; object-fit: cover; border: 1px solid rgba(255, 255, 255, 0.08); }
.photo-preview.is-visible { display: block; }
.photo-live.is-hidden { display: none; }

.face-overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.face-circle { width: 170px; height: 170px; border-radius: 999px; border: 2px solid rgba(0, 212, 255, 0.9); box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.12); }
.face-hint { position: absolute; bottom: 10px; left: 10px; right: 10px; font-size: 12px; color: #071a2d; background: rgba(255, 255, 255, 0.92); padding: 8px 10px; border-radius: 12px; text-align: center; font-weight: 700; }

.photo-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.photo-req { font-size: 12px; color: #94a3b8; }

*** End Patch```}>>>>> {"id":"functions.ApplyPatch"} ੱਞassistantานุการ to=functions.ApplyPatchционер ***!

.account-status { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem 1rem; padding: 0.75rem 1rem; border-radius: 12px; margin-bottom: 1.25rem; font-size: 0.9rem; }
.account-status--ok { background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.3); color: #86efac; }
.account-status--pending { background: rgba(245, 158, 11, 0.12); border: 1px solid rgba(245, 158, 11, 0.35); color: #fcd34d; }
.account-status--error { background: rgba(239, 68, 68, 0.12); border: 1px solid rgba(239, 68, 68, 0.3); color: #fca5a5; }
.account-status__badge { font-weight: 700; }
.account-status__text { color: inherit; opacity: 0.95; }
.documents-intro { color: var(--text-muted, #94a3b8); font-size: 0.95rem; margin: -0.5rem 0 1.25rem; line-height: 1.45; }
.photo-test-desc { margin: 0.5rem 0; font-size: 0.8rem; color: var(--text-muted, #94a3b8); }

.kyc-quality { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.q-item { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #94a3b8; background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(255, 255, 255, 0.06); padding: 8px 10px; border-radius: 999px; font-weight: 700; }
.q-item .dot { width: 10px; height: 10px; border-radius: 999px; background: #64748b; }
.q-item.ok { color: #a7f3d0; border-color: rgba(52, 199, 89, 0.22); }
.q-item.ok .dot { background: #34c759; }
.q-item.bad { color: #ffb4ad; border-color: rgba(255, 59, 48, 0.22); }
.q-item.bad .dot { background: #ff3b30; }

.kyc-tip { margin-top: 8px; font-size: 12px; color: #cbd5e1; }
.kyc-countdown { margin-top: 6px; font-size: 12px; font-weight: 800; color: #00d4ff; }

.block-banner { background: rgba(255, 59, 48, 0.12); color: #ffb4ad; border: 1px solid rgba(255, 59, 48, 0.25); padding: 12px 14px; border-radius: 14px; margin: 14px 0; font-weight: 700; }

.nav-center a.disabled { opacity: 0.5; pointer-events: none; cursor: not-allowed; }

@media (max-width: 640px) {
  .doc-row.doc-photo { flex-direction: column; }
  .photo-box { min-width: 100%; }
  .photo-live, .photo-preview { width: 100%; max-width: 260px; height: 260px; }
}

/* ========== HERO BRANDING (documents, programme partenaire, dashboard) ========== */
.documents-hero,
.partner-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
}

.documents-image img,
.hero-image img,
.dashboard-branding img {
  max-width: 100%;
  border-radius: 18px;
  object-fit: cover;
}

.dashboard-branding {
  margin-top: 40px;
  text-align: center;
}

.dashboard-branding img {
  max-width: min(100%, 420px);
  width: auto;
  height: auto;
}

@media (max-width: 767px) {
  .documents-hero,
  .partner-hero {
    flex-direction: column;
    gap: 24px;
  }
  .documents-image,
  .hero-image {
    order: -1;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }
  .dashboard-branding img {
    max-width: min(100%, 400px);
  }
}
