/* ============================================================
   INSCRIPTION.CSS — Page inscription / connexion Atryvia
   ============================================================ */

body.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== WRAPPER ===== */
.auth-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  background:
    radial-gradient(circle at 12% 12%, rgba(125, 149, 133, 0.08), transparent 24%),
    radial-gradient(circle at 88% 88%, rgba(196, 162, 78, 0.08), transparent 24%),
    var(--cream-light);
}

/* ===== CARTE AUTH ===== */
.auth-card {
  background: var(--white);
  width: 100%;
  max-width: 480px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 40px;
  border: 1px solid rgba(255, 255, 255, 0.8);
}

/* ===== ONGLETS ===== */
.auth-tabs {
  display: flex;
  margin-bottom: 32px;
  border-bottom: 2px solid var(--cream);
  gap: 0;
}

.auth-tab {
  flex: 1;
  padding-bottom: 14px;
  text-align: center;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  background: none;
  font-family: inherit;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.auth-tab.active {
  color: var(--green);
  border-bottom-color: var(--green);
}

.auth-tab:hover:not(.active) {
  color: var(--navy);
}

/* ===== FORMULAIRES ===== */
.auth-form {
  display: none;
}

.auth-form.active {
  display: block;
  animation: fadeInUp 0.3s ease;
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy);
}

.form-input {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-size: 1rem;
  background: var(--cream-light);
  color: var(--text);
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--green);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(45, 90, 61, 0.1);
}

/* Options (se souvenir + lien) */
.form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  font-size: 0.85rem;
  flex-wrap: wrap;
  gap: 8px;
}

.form-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text-light);
}

.form-checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--green);
}

.form-link {
  color: var(--green-dark);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
  padding: 0;
}

.form-link:hover {
  color: var(--navy);
}

/* Checkbox CGU */
.form-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-light);
  margin-bottom: 24px;
  line-height: 1.5;
}

.form-consent input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--green);
  flex-shrink: 0;
}

/* Bouton soumettre */
.btn-submit {
  width: 100%;
  padding: 14px;
  border-radius: var(--radius);
  border: none;
  background: var(--green);
  color: white;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease, transform 0.2s ease;
  margin-bottom: 16px;
}

.btn-submit:hover {
  background: var(--green-dark);
  transform: translateY(-1px);
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Flash messages */
.auth-flash {
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 20px;
}

.auth-flash.error {
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(220, 38, 38, 0.25);
  color: #b91c1c;
}

.auth-flash.success {
  background: rgba(45, 90, 61, 0.08);
  border: 1px solid rgba(45, 90, 61, 0.25);
  color: var(--green-dark);
}

/* Pied de formulaire */
.auth-footer {
  text-align: center;
  margin-top: 16px;
  font-size: 0.9rem;
  color: var(--text-light);
}

/* ===== FOOTER SIMPLIFIÉ ===== */
.footer-simple {
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.5);
  padding: 24px 0;
  text-align: center;
  font-size: 0.85rem;
  margin-top: auto;
}

.footer-simple a {
  color: rgba(255, 255, 255, 0.6);
  margin: 0 8px;
}

.footer-simple a:hover {
  color: white;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .auth-card {
    padding: 28px 20px;
  }

  .auth-wrapper {
    padding: 40px 16px;
  }
}
