/* T051 — Connexion : styles de la page (sortis du gabarit login.html). */
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    circle at top,
    #f3f7ff 0,
    #e7eefb 45%,
    #d8e5f7 100%
  );
  /* T131 : police de l'ERP (DM Sans, erp-theme.css) ; sans empattement si elle manque. */
  font-family: var(--erp-police, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);
  color: #10243f;
}
/* T131 : boutons et champs à la police de la page (sinon Times sur iPhone / iPad, Arial sur PC). */
button,
input,
select,
textarea {
  font-family: inherit;
}
.card {
  width: min(460px, calc(100vw - 32px));
  background: rgba(255, 255, 255, 0.98);
  border-radius: 14px;
  border: 1px solid #d9e4f2;
  box-shadow: 0 14px 36px rgba(8, 75, 135, 0.16);
  overflow: hidden;
}
.card-header {
  background: linear-gradient(135deg, #0f6cbf 0%, #084b87 100%);
  color: #fff;
  padding: 26px 24px;
}
.card-header h1 {
  margin: 0;
  font-size: 1.5rem;
}
.card-header p {
  margin: 8px 0 0;
  opacity: 0.92;
  font-size: 0.92rem;
}
.card-body {
  padding: 24px;
}
.hint {
  margin: 0 0 18px;
  padding: 12px;
  border: 1px solid #cfe2ff;
  border-left: 4px solid #0f6cbf;
  border-radius: 8px;
  background: #eef6ff;
  font-size: 0.88rem;
}
.hint b {
  color: #0b4ea2;
}
label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 0.9rem;
}
input {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #c8d4ea;
  border-radius: 9px;
  /* T131 : 16 px au moins, sinon Safari iOS zoome la page quand on touche le champ. */
  font-size: 1rem;
  margin-bottom: 14px;
}
input:focus {
  outline: none;
  border-color: #0f6cbf;
  box-shadow: 0 0 0 3px rgba(15, 108, 191, 0.14);
}
.password-wrap {
  position: relative;
}
.password-wrap input {
  padding-right: 46px;
}
.password-toggle {
  position: absolute;
  right: 0;
  top: 0;
  width: 44px;
  height: 44px;
  padding: 0;
  color: #0f6cbf;
  background: transparent;
}
/* T131 : zone de toucher de 44 px de haut (« Mot de passe oublié ? », « Annuler »). */
.link-button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  width: auto;
  padding: 0;
  color: #0f6cbf;
  background: transparent;
  font-size: 0.88rem;
  font-weight: 600;
}
button {
  width: 100%;
  border: 0;
  border-radius: 9px;
  padding: 12px;
  font-weight: 700;
  font-size: 0.97rem;
  color: #fff;
  background: linear-gradient(135deg, #0f6cbf 0%, #084b87 100%);
  cursor: pointer;
}
/* T131 : lien qui a l'air d'un bouton (page introuvable). */
.bouton {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 9px;
  padding: 12px;
  font-weight: 700;
  font-size: 0.97rem;
  color: #fff;
  text-decoration: none;
  background: linear-gradient(135deg, #0f6cbf 0%, #084b87 100%);
}
.bouton:hover,
.bouton:focus-visible {
  color: #fff;
}
button:disabled {
  opacity: 0.72;
  cursor: not-allowed;
}
.alert {
  display: none;
  margin-bottom: 14px;
  padding: 11px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
}
/* T131 : styles sortis du gabarit (plus de style en ligne). */
.alert-visible {
  display: block;
}
.mfa-titre {
  font-size: 1.1rem;
  margin: 0 0 0.5rem;
}
.mfa-aide {
  font-size: 0.9rem;
}
.alert-danger {
  background: #ffecec;
  border: 1px solid #ffd0d0;
  color: #9a1919;
}
.alert-success {
  background: #eafbf1;
  border: 1px solid #b8ebca;
  color: #0f6b38;
}
.card-footer {
  padding: 14px 24px;
  border-top: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 0.78rem;
  background: #f8fafc;
  text-align: center;
}
[hidden] { display: none !important; }
