/* Solution Entretien — pages connexion / inscription / mot de passe (même design system que le site). */
:root {
  --bg: #07080f; --bg-2: #0c0e1a;
  --surface: rgba(255,255,255,.035); --surface-2: rgba(255,255,255,.06);
  --line: rgba(255,255,255,.09); --line-2: rgba(255,255,255,.16);
  --text: #f3f4fb; --muted: #a3a8c3; --muted-2: #6f758f;
  --violet: #8b5cf6; --cyan: #22d3ee; --lime: #a3e635; --pink: #f472b6; --amber: #fbbf24; --red: #fb7185;
  --grad: linear-gradient(100deg, var(--cyan) 0%, var(--violet) 50%, var(--pink) 100%);
  --r-md: 14px; --r-lg: 24px;
  --font-display: 'Sora', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  min-height: 100vh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--text);
  font: 15px/1.6 var(--font-body); -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(55% 45% at 15% 0%, rgba(34,211,238,.16), transparent 70%),
    radial-gradient(50% 40% at 90% 10%, rgba(139,92,246,.22), transparent 70%),
    radial-gradient(40% 40% at 50% 100%, rgba(244,114,182,.10), transparent 70%);
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
[hidden] { display: none !important; }

/* Barre du haut */
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px clamp(16px, 4vw, 40px); }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 17px; }
.brand-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--grad); box-shadow: 0 0 18px rgba(139,92,246,.6); }
.brand strong { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.top-link { color: var(--muted); font-size: 14px; padding: 8px 10px; border-radius: 10px; }
.top-link:hover { color: var(--text); background: var(--surface-2); }

/* Sélecteur de langue */
.lang { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.lang button { border: 0; background: transparent; color: var(--muted); font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 999px; letter-spacing: .04em; }
.lang button.is-active { background: var(--surface-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line-2); }

/* Carte */
.wrap { flex: 1; display: flex; align-items: center; justify-content: center; padding: 12px 16px 48px; }
.card {
  width: 100%; max-width: 440px; padding: clamp(26px, 5vw, 40px);
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.025));
  border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: 0 30px 80px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.06);
  backdrop-filter: blur(10px);
}
.card h1 { font-family: var(--font-display); font-size: clamp(24px, 4vw, 28px); line-height: 1.2; margin-bottom: 6px; }
.card .sub { color: var(--muted); font-size: 14px; margin-bottom: 24px; }

/* Champs */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-size: 13px; font-weight: 600; color: var(--muted); }
.control { position: relative; }
.control .ico { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted-2); font-size: 14px; pointer-events: none; }
.control input {
  width: 100%; min-height: 48px; padding: 0 44px 0 42px;
  background: rgba(0,0,0,.35); color: var(--text);
  border: 1px solid var(--line); border-radius: var(--r-md);
  font: inherit; outline: none; transition: border-color .15s, box-shadow .15s;
}
.control input::placeholder { color: var(--muted-2); }
.control input:focus { border-color: rgba(139,92,246,.7); box-shadow: 0 0 0 4px rgba(139,92,246,.18); }
.control input:-webkit-autofill { -webkit-text-fill-color: var(--text); -webkit-box-shadow: 0 0 0 1000px #11131f inset; }
.eye { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); border: 0; background: transparent; color: var(--muted-2); width: 34px; height: 34px; border-radius: 8px; }
.eye:hover { color: var(--text); background: var(--surface-2); }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: -4px 0 16px; font-size: 13px; }
.link { color: var(--cyan); font-weight: 600; }
.link:hover { text-decoration: underline; }

/* Boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px; width: 100%;
  min-height: 48px; padding: 0 18px; border-radius: var(--r-md); border: 1px solid transparent;
  font-weight: 600; font-size: 15px; transition: transform .12s, filter .15s, background .15s;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--grad); color: #0b0c14; box-shadow: 0 10px 30px rgba(139,92,246,.35); }
.btn-primary:hover:not(:disabled) { filter: brightness(1.08); }
.btn-ghost { background: var(--surface-2); border-color: var(--line-2); color: var(--text); }
.btn-ghost:hover:not(:disabled) { background: rgba(255,255,255,.1); }
.btn .g { width: 18px; height: 18px; }

.divider { display: flex; align-items: center; gap: 12px; color: var(--muted-2); font-size: 12px; margin: 16px 0; text-transform: uppercase; letter-spacing: .08em; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* Messages (plus d'alert()) */
.msg { margin: 14px 0 0; padding: 11px 13px; border-radius: 12px; font-size: 14px; line-height: 1.45; display: flex; gap: 9px; align-items: flex-start; }
.msg::before { content: ''; flex: none; width: 8px; height: 8px; border-radius: 50%; margin-top: 7px; background: currentColor; }
.msg-error { background: rgba(251,113,133,.12); border: 1px solid rgba(251,113,133,.35); color: #fda4af; }
.msg-ok { background: rgba(163,230,53,.12); border: 1px solid rgba(163,230,53,.35); color: #d9f99d; }
.msg-info { background: rgba(34,211,238,.10); border: 1px solid rgba(34,211,238,.3); color: #a5f3fc; }

.spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(0,0,0,.25); border-top-color: currentColor; border-radius: 50%; animation: spin .8s linear infinite; }
.btn-ghost .spinner { border-color: var(--line-2); border-top-color: var(--text); }
@keyframes spin { to { transform: rotate(360deg); } }

.foot { margin-top: 20px; text-align: center; color: var(--muted); font-size: 13px; }
.foot .alt { margin-top: 8px; }
.help { margin-top: 28px; text-align: center; color: var(--muted-2); font-size: 12.5px; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; }
.help a { color: var(--muted); }
.help a:hover { color: var(--text); }
.terms { margin-top: 12px; font-size: 12px; color: var(--muted-2); text-align: center; }

@media (max-width: 480px) {
  .top-link { display: none; }
  .wrap { align-items: flex-start; padding-top: 8px; }
}
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }
