/* ═══════════════════════════════════════════
   HITOKI — login.css
   ═══════════════════════════════════════════ */

/* ── MAIN ── */
main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px 5% 60px;
}

/* ── CARD ── */
.auth-card {
  width: 100%;
  max-width: 440px;
  background: white;
  border: 1px solid var(--peach-dark);
  border-radius: 28px;
  padding: 40px 36px;
  animation: fadeUp 0.5s ease both;
}

/* ── SWITCH ── */
.auth-switch {
  display: flex;
  background: var(--peach-bg);
  border: 1px solid var(--peach-dark);
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 32px;
  gap: 4px;
}
.switch-btn {
  flex: 1;
  padding: 10px;
  border: none;
  border-radius: 9px;
  background: none;
  font-family: 'Inter', sans-serif;
  font-size: 14px; font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.switch-btn.active {
  background: white;
  color: var(--night);
  box-shadow: 0 1px 4px rgba(30, 26, 24, 0.08);
}

/* ── HEADER ── */
.auth-header { margin-bottom: 28px; }
.auth-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 26px; font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--night);
  margin-bottom: 8px;
}
.auth-title em { font-style: normal; }
.auth-sub { font-size: 14px; color: var(--muted); line-height: 1.6; }

/* ── CHAMPS ── */
.field-group { margin-bottom: 20px; }
.field-label {
  display: block;
  font-size: 13px; font-weight: 600;
  color: var(--night-soft);
  margin-bottom: 7px;
}
.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
}
.field-input {
  width: 100%;
  padding: 13px 16px;
  border: 1.5px solid var(--peach-dark);
  border-radius: 12px;
  background: white;
  color: var(--night);
  font-size: 15px;
  font-family: 'Inter', sans-serif;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field-input:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(244, 132, 95, 0.12);
}
.field-input::placeholder { color: var(--muted); }

.input-password-wrapper { position: relative; }
.input-password-wrapper .field-input { padding-right: 44px; }
.toggle-password {
  position: absolute; right: 12px; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  cursor: pointer; font-size: 16px;
  color: var(--muted); padding: 4px;
  line-height: 1;
}

.field-error {
  display: none;
  font-size: 12px; color: var(--red);
  margin-top: 5px;
}

/* ── FORCE MOT DE PASSE ── */
.password-strength {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}
.strength-bar {
  flex: 1; height: 4px;
  background: var(--peach-mid);
  border-radius: 2px;
  overflow: hidden;
}
.strength-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 0.3s, background 0.3s;
  width: 0%;
}
.strength-label { font-size: 11px; font-weight: 600; white-space: nowrap; }

/* ── LIEN MOT DE PASSE OUBLIÉ ── */
.forgot-link {
  background: none; border: none;
  font-size: 12px; font-weight: 600;
  color: var(--orange);
  cursor: pointer; padding: 0;
  transition: color 0.2s;
}
.forgot-link:hover { color: var(--orange-dark); }

/* ── CONSENTEMENT ── */
.consent-row {
  display: flex; align-items: flex-start; gap: 10px;
  margin-bottom: 20px; cursor: pointer;
}
.consent-row input[type="checkbox"] {
  margin-top: 2px; width: 16px; height: 16px;
  flex-shrink: 0; accent-color: var(--orange);
  cursor: pointer;
}
.consent-text {
  font-size: 12px; color: var(--muted); line-height: 1.5;
}
.consent-text a {
  color: var(--orange); text-decoration: none;
}
.consent-text a:hover { text-decoration: underline; }

/* ── ALERTES ── */
.alert {
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 13px;
  margin-bottom: 16px;
  line-height: 1.5;
}
.alert-error {
  background: var(--red-bg);
  border: 1px solid #FFCDD2;
  color: var(--red);
}

/* ── BOUTON PRINCIPAL ── */
.btn-primary {
  width: 100%;
  padding: 15px;
  border: none; border-radius: 99px;
  background: var(--orange);
  color: white;
  font-size: 15px; font-weight: 700;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  letter-spacing: -0.01em;
  display: flex; align-items: center; justify-content: center;
}
.btn-primary:hover { background: var(--orange-dark); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* ── LIEN SWITCH ── */
.auth-footer-text {
  text-align: center;
  font-size: 13px; color: var(--muted);
  margin-top: 20px;
}
.link-btn {
  background: none; border: none;
  color: var(--orange); font-size: 13px; font-weight: 600;
  cursor: pointer; padding: 0;
  transition: color 0.2s;
}
.link-btn:hover { color: var(--orange-dark); }

/* ── RETOUR ── */
.back-btn {
  background: none; border: none;
  font-size: 13px; font-weight: 600;
  color: var(--muted); cursor: pointer;
  padding: 0; margin-bottom: 16px;
  display: block;
  transition: color 0.2s;
}
.back-btn:hover { color: var(--night); }

/* ── CONFIRMATION ── */
.confirmation-box {
  display: none;
  flex-direction: column; align-items: center;
  gap: 10px; text-align: center;
  padding: 24px;
  background: var(--peach-mid);
  border-radius: 16px;
}
.confirmation-icon { font-size: 40px; }
.confirmation-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 18px; font-weight: 700;
  color: var(--night);
}
.confirmation-text { font-size: 13px; color: var(--muted); }

/* ── HIDDEN ── */
.hidden { display: none !important; }

/* ── ANIMATIONS ── */

/* ── RESPONSIVE ── */
@media (max-width: 480px) {
  .auth-card { padding: 28px 20px; border-radius: 20px; }
  main { padding: 90px 4% 40px; }

}