/* ============================================================
   Page de connexion / inscription (login.html)
   Design répliqué de zenix.best/login — palette violette Nébula,
   sans boutons sociaux. Pill flottant + carte de verre rounded-3xl.
   ============================================================ */

.auth-body {
  margin: 0;
  background: #09090b;
  min-height: 100vh;
  font-family: 'Manrope', 'Outfit', 'Segoe UI', system-ui, sans-serif;
  box-sizing: border-box;
}

/* ── Pill flottant (header) ── */
.auth-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 999;
  display: flex; justify-content: center; padding: 12px 12px;
  pointer-events: none; box-sizing: border-box;
}
@media (min-width: 640px) { .auth-header { padding: 12px 16px; } }

.auth-pill {
  pointer-events: auto;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 44px; width: auto; box-sizing: border-box;
  border-radius: 100px; padding: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}
@media (min-width: 640px) { .auth-pill { height: 48px; padding: 0 22px; } }

.auth-pill-logo { display: flex; align-items: center; text-decoration: none; }
.auth-pill-logo img { height: 28px; width: auto; }

/* ── Fond aurora animé ── */
.auth-aurora {
  position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 0;
}
.auth-aurora::before {
  content: '';
  position: absolute; top: -50%; left: -50%; width: 200%; height: 200%;
  background:
    radial-gradient(ellipse 80% 50% at 20% 40%, rgba(139, 92, 246, .18), transparent 50%),
    radial-gradient(ellipse 60% 80% at 80% 50%, rgba(236, 72, 153, .14), transparent 50%),
    radial-gradient(ellipse 50% 60% at 40% 80%, rgba(167, 139, 250, .12), transparent 50%),
    radial-gradient(ellipse 80% 40% at 60% 20%, rgba(255, 255, 255, .07), transparent 50%);
  animation: auth-aurora 20s ease-in-out infinite alternate;
}
@keyframes auth-aurora {
  0%   { transform: translate(0%, 0%) rotate(0deg) scale(1); }
  25%  { transform: translate(5%, -5%) rotate(3deg) scale(1.02); }
  50%  { transform: translate(-3%, 5%) rotate(-2deg) scale(.98); }
  75%  { transform: translate(3%, 3%) rotate(2deg) scale(1.01); }
  100% { transform: translate(-5%, -3%) rotate(-3deg) scale(1); }
}

/* ── Orbes flottantes ── */
.auth-orb {
  position: absolute; border-radius: 50%; filter: blur(80px);
  animation: auth-float 15s ease-in-out infinite; pointer-events: none;
}
.auth-orb-1 {
  width: 500px; height: 500px; top: 10%; left: 60%;
  background: linear-gradient(135deg, rgba(139, 92, 246, .22), rgba(167, 139, 250, .1));
  animation-duration: 18s;
}
.auth-orb-2 {
  width: 400px; height: 400px; top: 50%; left: 20%;
  background: linear-gradient(225deg, rgba(255, 255, 255, .1), rgba(200, 200, 255, .05));
  animation-delay: -5s; animation-duration: 22s;
}
.auth-orb-3 {
  width: 300px; height: 300px; top: 70%; left: 70%;
  background: linear-gradient(45deg, rgba(124, 58, 237, .16), rgba(236, 72, 153, .08));
  animation-delay: -10s; animation-duration: 20s;
}
@keyframes auth-float {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: .6; }
  25%      { transform: translate(30px, -40px) scale(1.05); opacity: .8; }
  50%      { transform: translate(-20px, 20px) scale(.95); opacity: .5; }
  75%      { transform: translate(40px, 30px) scale(1.02); opacity: .7; }
}

/* ── Grille subtile ── */
.auth-grid {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, .02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .02) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* ── Coque centrée ── */
.auth-shell {
  position: relative; z-index: 1;
  min-height: 100vh;
  display: flex;
  padding: 96px 16px 40px;
  box-sizing: border-box;
}
@media (min-width: 640px) { .auth-shell { padding-top: 108px; } }

.auth-wrap { width: 100%; max-width: 440px; margin: auto; }

/* ── Carte de verre (rounded-3xl façon Zenix) ── */
.auth-card {
  position: relative;
  background: rgba(0, 0, 0, .6);
  -webkit-backdrop-filter: blur(32px) saturate(180%);
  backdrop-filter: blur(32px) saturate(180%);
  border: 1px solid rgba(139, 92, 246, .5);
  border-radius: 24px;
  padding: 28px 26px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .6);
  transition: border-color .3s ease;
  overflow: hidden;
}
@media (min-width: 640px) { .auth-card { padding: 40px; } }
.auth-card:hover { border-color: rgba(139, 92, 246, .85); }

.auth-card-head { position: relative; text-align: center; margin-bottom: 28px; }
.auth-card-head .logo-img {
  height: 52px; width: auto; margin: 0 auto 14px;
  filter: drop-shadow(0 12px 30px rgba(139, 92, 246, .5));
}
@media (min-width: 640px) { .auth-card-head .logo-img { height: 56px; } }
.auth-sub { color: #9ca3af; font-size: .95rem; margin: 0; }

/* ── Formulaires ── */
.auth-form { position: relative; display: flex; flex-direction: column; gap: 18px; }
.auth-view.hidden { display: none; }

.auth-label-row {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px;
}
.auth-label { display: block; font-size: .95rem; font-weight: 500; color: #d1d5db; margin-bottom: 8px; }
.auth-link {
  font-size: .9rem; color: #a78bfa; font-weight: 500; padding: 0;
  background: none; border: none; cursor: pointer; transition: color .2s;
}
.auth-link:hover { color: #c4b5fd; }
.auth-optional { color: #6b7280; font-weight: 400; font-size: .85rem; }

.auth-field { position: relative; }
.auth-field > svg {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px; color: #6b7280; pointer-events: none; transition: color .3s;
}
.auth-field:focus-within > svg { color: #a78bfa; }

.auth-input {
  width: 100%; padding: 16px 46px; box-sizing: border-box;
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 14px;
  color: #fff; font-size: 1rem; font-family: inherit;
  outline: none; transition: all .3s;
}
.auth-input::placeholder { color: #6b7280; }
.auth-input:focus {
  background: rgba(255, 255, 255, .1);
  border-color: rgba(139, 92, 246, .6);
  box-shadow: 0 0 0 4px rgba(139, 92, 246, .22);
}

.auth-eye {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 42px; height: 42px; display: grid; place-items: center;
  color: #6b7280; transition: color .3s; border-radius: 10px;
}
.auth-eye:hover { color: #a78bfa; }

/* ── Bouton principal ── */
.auth-submit {
  width: 100%; margin-top: 2px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 16px 24px; border-radius: 14px; border: none; cursor: pointer;
  font-family: inherit; font-size: 1rem; font-weight: 700; color: #fff;
  background: linear-gradient(120deg, #7c3aed, #a855f7);
  box-shadow: 0 10px 30px rgba(139, 92, 246, .35);
  transition: all .25s;
}
.auth-submit:hover { opacity: .9; transform: translateY(-1px); box-shadow: 0 14px 38px rgba(139, 92, 246, .5); }
.auth-submit:active { transform: translateY(0) scale(.99); }
.auth-submit svg { transition: transform .2s; }
.auth-submit:hover svg { transform: translateX(3px); }

.auth-err {
  display: none; padding: 12px 14px; border-radius: 12px;
  background: rgba(244, 63, 94, .12); border: 1px solid rgba(244, 63, 94, .35);
  color: #fda4af; font-size: .88rem; line-height: 1.4;
}
.auth-err.show { display: block; }

/* ── Ligne de bas (switch de vue) ── */
.auth-switch-row { position: relative; margin-top: 28px; text-align: center; font-size: .95rem; color: #9ca3af; }
.auth-switch-btn {
  background: none; border: none; cursor: pointer; padding: 0; margin-left: 4px;
  font-family: inherit; font-size: inherit; font-weight: 700; color: #a78bfa; transition: color .2s;
}
.auth-switch-btn:hover { color: #c4b5fd; }

.auth-foot { position: relative; margin-top: 14px; text-align: center; font-size: .9rem; color: #6b7280; }
.auth-foot a { color: #a78bfa; font-weight: 600; text-decoration: none; }
.auth-foot a:hover { color: #c4b5fd; }

/* ── Forgot ── */
.forgot-result {
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 14px; padding: 16px;
  font-size: .92rem; color: #d1d5db; line-height: 1.5;
  display: flex; flex-direction: column; gap: 10px;
}
.forgot-result .hint-box { color: #a78bfa; font-style: italic; font-size: 1rem; }
.forgot-danger {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 16px; border-radius: 12px; width: 100%;
  background: rgba(244, 63, 94, .12); border: 1px solid rgba(244, 63, 94, .35);
  color: #fda4af; font-weight: 700; font-size: .9rem; font-family: inherit; cursor: pointer;
  transition: all .2s;
}
.forgot-danger:hover { background: rgba(244, 63, 94, .25); }

/* ── Mobile ── */
@media (max-width: 480px) {
  .auth-card { padding: 26px 20px; border-radius: 20px; }
  .auth-card-head .logo-img { height: 48px; }
}