/* ==========================================================================
   AUTOCARE — Écran de connexion
   Panneau identité (pétrole, arcs du monogramme) + formulaire sobre.
   Police Inter auto-hébergée ; focus clavier toujours visible.
   ========================================================================== */

:root {
  --ac-bleu: #3489B8;
  --ac-bleu-fonce: #2A729B;
  --ac-petrole: #16394F;
  --ac-petrole-2: #0E2A3C;
  --ac-magenta: #C13D7C;
  --encre: #1D2B36;
  --texte-2: #6B675C;
  --bord: #E8DFD2;
  --bord-fort: #D2C5B2;
  --danger: #B3372B;
  --danger-pale: #FBEDEB;
  --anneau: 0 0 0 3px rgba(52, 137, 184, .25);
  --police: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

body {
  margin: 0;
  font-family: var(--police);
  color: var(--encre);
  background: #FBF7F0; /* crème chaud, cohérent avec l'application */
}

:focus-visible { outline: 2px solid var(--ac-bleu); outline-offset: 2px; }

.login-split { display: flex; min-height: 100vh; }

/* --------------------------------------------------------------------------
   Panneau identité — la signature : les arcs concentriques du monogramme
   -------------------------------------------------------------------------- */
.login-visual {
  flex: 1.2;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Pétrole profond réchauffé par des halos bleu et magenta */
  background:
    radial-gradient(720px 540px at 82% 88%, rgba(193, 61, 124, .2), transparent 62%),
    radial-gradient(640px 460px at 8% 6%, rgba(52, 137, 184, .28), transparent 60%),
    linear-gradient(160deg, var(--ac-petrole) 0%, var(--ac-petrole-2) 70%);
}

/* Arcs décoratifs, traits fins — rappel du « A » circulaire du logo */
.login-visual::before,
.login-visual::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, .08);
  pointer-events: none;
}
.login-visual::before {
  width: 640px; height: 640px;
  right: -180px; bottom: -220px;
  border-top-color: rgba(193, 61, 124, .35);   /* pointe magenta */
}
.login-visual::after {
  width: 420px; height: 420px;
  right: -60px; bottom: -120px;
}

.visual-content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 40px;
  animation: apparition .7s ease-out both;
}

.logo-circle {
  width: 96px; height: 96px;
  margin: 0 auto 22px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 34px rgba(0, 0, 0, .28);
}
.logo-circle .logo-img { width: 58px; height: auto; }

.visual-title {
  margin: 0;
  color: #fff;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: .12em;
}
.visual-sep {
  width: 46px; height: 3px;
  margin: 14px auto;
  border: none;
  border-radius: 3px;
  background: var(--ac-magenta);
  opacity: 1;
}
.visual-baseline {
  margin: 0;
  color: rgba(255, 255, 255, .62);
  font-size: 14px;
  max-width: 320px;
}

/* --------------------------------------------------------------------------
   Panneau formulaire
   -------------------------------------------------------------------------- */
.login-form-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 24px;
  /* Crème chaleureux + souffle doré discret en bas (signature) */
  background:
    radial-gradient(680px 420px at 50% 112%, rgba(212, 160, 23, .09), transparent 62%),
    linear-gradient(180deg, #FDFAF4 0%, #F8F2E9 100%);
}

.login-form-box { width: 100%; max-width: 380px; }

.form-header h1 {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 700;
  color: var(--encre);
}
.form-header p { margin: 0 0 26px; font-size: 13.5px; color: var(--texte-2); }

.champ { margin-bottom: 16px; }
.champ label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--texte-2);
  margin-bottom: 5px;
}

.champ-enveloppe { position: relative; }
.champ-enveloppe > i {
  position: absolute;
  left: 12px; top: 50%;
  transform: translateY(-50%);
  color: #B0A890;
  font-size: 15px;
  pointer-events: none;
}

.champ input.form-control {
  width: 100%;
  height: 44px;
  font-family: var(--police);
  font-size: 14.5px;
  color: var(--encre);
  background: #FFFEFB;
  border: 1px solid var(--bord);
  border-radius: 9px;
  padding: 0 42px 0 38px;
  transition: border-color .12s ease, box-shadow .12s ease;
  box-shadow: none;
}
.champ input.form-control:hover { border-color: var(--bord-fort); }
.champ input.form-control:focus {
  border-color: var(--ac-bleu);
  box-shadow: var(--anneau);
  outline: none;
}

.pwd-toggle {
  position: absolute;
  right: 6px; top: 50%;
  transform: translateY(-50%);
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  border: none;
  background: transparent;
  color: var(--texte-2);
  border-radius: 7px;
  font-size: 15px;
}
.pwd-toggle:hover { background: #F6EFE4; color: var(--encre); }

.error-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--danger-pale);
  border: 1px solid #EFC9C4;
  color: #7C2A21;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 13px;
  margin-bottom: 16px;
  animation: secousse .35s ease;
}

.login-btn {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, #41A0D2 0%, var(--ac-bleu) 45%, var(--ac-bleu-fonce) 100%);
  color: #fff;
  font-family: var(--police);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .01em;
  box-shadow: 0 8px 22px rgba(52, 137, 184, .32);
  transition: background .15s ease, box-shadow .15s ease;
  cursor: pointer;
}
.login-btn:hover {
  background: linear-gradient(135deg, var(--ac-bleu) 0%, var(--ac-bleu-fonce) 100%);
  box-shadow: 0 10px 26px rgba(52, 137, 184, .42);
}
.login-btn:focus-visible { outline: 2px solid var(--ac-petrole); outline-offset: 2px; }

.footer-text {
  margin-top: 28px;
  margin-bottom: 6px;
  text-align: center;
  font-size: 12px;
  color: #9AAAB5;
}

.footer-liens {
  text-align: center;
  display: flex;
  justify-content: center;
  gap: 14px;
}
.footer-liens a {
  font-size: 11.5px;
  color: #9AAAB5;
  text-decoration: none;
}
.footer-liens a:hover { color: var(--texte-2); text-decoration: underline; }

/* Signature AC Technologie : monogramme + nom en or animé */
.signature {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 14px;
  text-decoration: none;
}
.signature img { height: 18px; width: auto; display: block; }
.signature-texte {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  background: linear-gradient(100deg, #8A5A06 0%, #D4A017 28%, #F6D97C 50%, #D4A017 72%, #8A5A06 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: reflet-or 8s linear infinite;
}
.signature:hover .signature-texte { animation-duration: 2.2s; }
@keyframes reflet-or {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* --------------------------------------------------------------------------
   Animations discrètes
   -------------------------------------------------------------------------- */
@keyframes apparition {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes secousse {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}
.login-form-box { animation: apparition .5s ease-out both; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* --------------------------------------------------------------------------
   Écrans étroits : le panneau identité s'efface
   -------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .login-visual { display: none; }
}
