/* Pages de connexion (includes/auth_layout.php) — même DA que la page d'accueil. */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
:root {
  --bg:#08090c; --bg2:#0e1016; --card:#13151c; --card2:#191c25; --field:#0c0e13;
  --line:rgba(255,255,255,.08); --line2:rgba(255,255,255,.14);
  --text:#eef2f7; --muted:#98a2b3; --dim:#626b7a;
  --blue:#4f8ef7; --blue2:#7fb0ff; --gold:#f9c74f; --green:#34d399; --red:#ff6b6b;
  --r-legendaire:#d6a83c; --r-epique:#9a5cd6; --r-rare:#3f82d8;
  --display:'Archivo', sans-serif; --body:'Outfit', sans-serif;
}
html { -webkit-text-size-adjust:100%; }
body.au-body { background:var(--bg); color:var(--text); font-family:var(--body); line-height:1.5; min-height:100vh; min-height:100dvh; }
[data-lucide] { width:18px; height:18px; stroke:currentColor; fill:none; stroke-width:2; stroke-linecap:round; stroke-linejoin:round; display:inline-block; flex-shrink:0; }
a { color:inherit; text-decoration:none; }
button, input { font-family:inherit; }

.au-shell { display:grid; grid-template-columns:minmax(380px, 46%) 1fr; min-height:100vh; min-height:100dvh; }

/* ── Panneau visuel ─────────────────────────────────────────────── */
.au-side { position:sticky; top:0; height:100vh; height:100dvh; overflow:hidden; display:flex; flex-direction:column; padding:36px 44px; border-right:1px solid var(--line); isolation:isolate; }
.au-side-bg { position:absolute; inset:0; z-index:-1;
  background:
    radial-gradient(700px 480px at 70% 62%, rgba(79,142,247,.24), transparent 62%),
    radial-gradient(520px 380px at 0% 0%, rgba(52,211,153,.12), transparent 60%),
    linear-gradient(180deg, #0b0e16, #08090c); }
.au-side-bg::after { content:''; position:absolute; inset:0; opacity:.07;
  background:
    linear-gradient(90deg, transparent calc(50% - 1px), #fff calc(50% - 1px), #fff calc(50% + 1px), transparent calc(50% + 1px)),
    radial-gradient(circle at 50% 66%, transparent 88px, #fff 89px, #fff 91px, transparent 92px);
  -webkit-mask-image:linear-gradient(180deg, transparent 20%, #000 60%); mask-image:linear-gradient(180deg, transparent 20%, #000 60%); }
.au-brand { display:inline-flex; align-items:center; gap:.55rem; font-family:var(--display); font-weight:900; font-size:1.15rem; letter-spacing:-.02em; }
.au-brand img { width:34px; height:34px; object-fit:contain; }
.au-side-copy { margin-top:clamp(28px, 7vh, 72px); max-width:460px; }
.au-side-copy h2 { font-family:var(--display); font-weight:900; font-size:clamp(2rem, 3.2vw, 2.9rem); line-height:1.02; letter-spacing:-.035em; }
.au-side-copy h2 em { font-style:normal; background:linear-gradient(90deg, var(--gold), #ffe29a 45%, var(--gold) 90%); background-size:200% 100%; -webkit-background-clip:text; background-clip:text; color:transparent; animation:auGrad 6s linear infinite; }
@keyframes auGrad { to { background-position:-200% 0; } }
.au-side-copy p { color:var(--muted); margin-top:.9rem; font-size:1.02rem; max-width:400px; }

.au-fan { position:relative; flex:1; min-height:250px; display:flex; align-items:center; justify-content:center; }
.au-card { position:absolute; width:150px; height:212px; border-radius:14px; padding:10px 10px 12px; display:flex; flex-direction:column; align-items:center; overflow:hidden;
  --rc:var(--r-rare);
  background:radial-gradient(120% 70% at 50% 0%, color-mix(in srgb, var(--rc) 55%, transparent), transparent 70%), linear-gradient(160deg, color-mix(in srgb, var(--rc) 30%, #11131a), #0d0f15 75%);
  border:2px solid color-mix(in srgb, var(--rc) 75%, #fff 10%);
  box-shadow:0 24px 50px -18px rgba(0,0,0,.85), 0 0 34px -10px var(--rc);
  animation:auFloat 6s ease-in-out infinite; }
.au-card.r-legendaire { --rc:var(--r-legendaire); } .au-card.r-epique { --rc:var(--r-epique); }
.au-card:nth-child(1) { transform:translate(-106px, 16px) rotate(-12deg); animation-delay:-2s; --t:translate(-106px, 16px) rotate(-12deg); }
.au-card:nth-child(2) { z-index:2; --t:translate(0, -12px) scale(1.07); transform:var(--t); }
.au-card:nth-child(3) { --t:translate(106px, 16px) rotate(12deg); transform:var(--t); animation-delay:-4s; }
@keyframes auFloat { 50% { transform:var(--t) translateY(-8px); } }
.au-card::after { content:''; position:absolute; inset:0; background:linear-gradient(115deg, transparent 35%, rgba(255,255,255,.2) 48%, transparent 60%); transform:translateX(-100%); animation:auFoil 5.5s ease-in-out infinite; }
.au-card:nth-child(1)::after { animation-delay:1.4s; } .au-card:nth-child(3)::after { animation-delay:2.8s; }
@keyframes auFoil { 0%,60% { transform:translateX(-100%); } 100% { transform:translateX(100%); } }
.au-card-top { align-self:stretch; display:flex; justify-content:space-between; align-items:flex-start; }
.au-card-top b { font-family:var(--display); font-weight:900; font-size:1.55rem; line-height:1; }
.au-card-top span { font-size:.64rem; font-weight:800; padding:.18rem .4rem; border-radius:5px; background:var(--rc); color:#0b0b0d; }
.au-card img { width:108px; height:108px; object-fit:contain; filter:drop-shadow(0 10px 14px rgba(0,0,0,.6)); }
.au-card-name { font-family:var(--display); font-weight:800; font-size:.9rem; margin-top:auto; max-width:100%; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.au-card-club { font-size:.64rem; color:rgba(255,255,255,.6); max-width:100%; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

.au-side-stats { display:grid; grid-template-columns:repeat(3, 1fr); gap:1px; background:var(--line); border:1px solid var(--line); border-radius:16px; overflow:hidden; }
.au-side-stats div { background:rgba(19,21,28,.85); padding:.9rem 1rem; }
.au-side-stats b { display:block; font-family:var(--display); font-weight:900; font-size:1.35rem; letter-spacing:-.02em; }
.au-side-stats div:nth-child(1) b { color:var(--blue2); } .au-side-stats div:nth-child(2) b { color:var(--green); } .au-side-stats div:nth-child(3) b { color:var(--gold); }
.au-side-stats span { font-size:.76rem; color:var(--muted); }

/* ── Colonne formulaire ─────────────────────────────────────────── */
.au-main { display:flex; flex-direction:column; min-width:0; background:radial-gradient(600px 400px at 100% 0%, rgba(79,142,247,.07), transparent 60%); }
.au-top { display:flex; align-items:center; justify-content:flex-end; padding:22px 28px; }
.au-brand-m { display:none; }
.au-back { display:inline-flex; align-items:center; gap:.4rem; font-size:.86rem; font-weight:600; color:var(--muted); padding:.45rem .8rem; border-radius:10px; border:1px solid var(--line); }
.au-back:hover { color:var(--text); border-color:var(--line2); }
.au-back [data-lucide] { width:16px; height:16px; }
.au-center { flex:1; display:flex; justify-content:center; align-items:flex-start; padding:2vh 24px 32px; }
.au-card-wrap { width:100%; max-width:440px; animation:auIn .5s cubic-bezier(.2,.8,.2,1); }
@keyframes auIn { from { opacity:0; transform:translateY(14px); } }
.au-foot { display:flex; flex-wrap:wrap; justify-content:center; gap:.4rem 1.3rem; padding:18px 20px calc(22px + env(safe-area-inset-bottom)); font-size:.82rem; font-weight:600; color:var(--muted); border-top:1px solid var(--line); }
.au-foot a:hover { color:var(--text); text-decoration:underline; text-underline-offset:3px; }

.au-title { font-family:var(--display); font-weight:900; font-size:clamp(1.7rem, 3vw, 2.1rem); letter-spacing:-.03em; line-height:1.08; }
.au-lead { color:var(--muted); margin:.45rem 0 1.5rem; font-size:.96rem; }
.au-lead strong { color:var(--text); font-weight:600; }

/* Onglets connexion / inscription */
.au-tabs { position:relative; display:grid; grid-template-columns:1fr 1fr; padding:4px; background:var(--card); border:1px solid var(--line); border-radius:14px; margin-bottom:1.6rem; }
.au-tabs button { position:relative; z-index:1; background:none; border:none; color:var(--muted); font-weight:700; font-size:.92rem; padding:.62rem; border-radius:10px; cursor:pointer; transition:color .2s; }
.au-tabs button.active { color:var(--text); }
.au-tabs .au-pill { position:absolute; top:4px; bottom:4px; left:4px; width:calc(50% - 4px); border-radius:10px; background:var(--card2); border:1px solid var(--line2); box-shadow:0 6px 16px -8px rgba(0,0,0,.8); transition:transform .32s cubic-bezier(.3,.9,.3,1); }
.au-tabs.reg .au-pill { transform:translateX(100%); }
.au-pane { display:none; }
.au-pane.active { display:block; animation:auIn .35s ease; }

/* Champs */
.au-field { margin-bottom:1rem; }
.au-label-row { display:flex; justify-content:space-between; align-items:baseline; gap:.5rem; margin-bottom:.4rem; }
.au-label-row label { font-size:.84rem; font-weight:600; color:#cdd5df; }
.au-label-row a, .au-label-row .opt { font-size:.78rem; color:var(--muted); }
.au-label-row a { color:var(--blue2); font-weight:600; }
.au-label-row a:hover { text-decoration:underline; }
.au-input { position:relative; display:flex; align-items:center; }
.au-input > [data-lucide] { position:absolute; left:14px; width:18px; height:18px; color:var(--dim); pointer-events:none; transition:color .2s; }
.au-input input { width:100%; background:var(--field); border:1px solid var(--line2); border-radius:12px; color:var(--text); font-size:1rem; padding:.8rem .9rem .8rem 2.65rem; transition:border-color .2s, box-shadow .2s, background .2s; }
.au-input.has-eye input { padding-right:2.9rem; }
.au-input input::placeholder { color:#4b5260; }
.au-input input:hover { border-color:rgba(255,255,255,.2); }
.au-input input:focus { outline:none; border-color:var(--blue); box-shadow:0 0 0 4px rgba(79,142,247,.16); background:#0e1119; }
.au-input:focus-within > [data-lucide] { color:var(--blue2); }
.au-input input:-webkit-autofill { -webkit-text-fill-color:var(--text); -webkit-box-shadow:0 0 0 40px var(--field) inset; caret-color:var(--text); }
.au-eye { position:absolute; right:6px; width:38px; height:38px; display:flex; align-items:center; justify-content:center; background:none; border:none; color:var(--dim); cursor:pointer; border-radius:9px; }
.au-eye:hover { color:var(--text); background:rgba(255,255,255,.05); }
.au-eye.on { color:var(--blue2); }
.au-hint { font-size:.76rem; color:var(--dim); margin-top:.35rem; }

/* Force du mot de passe */
.au-meter { display:grid; grid-template-columns:repeat(4, 1fr); gap:4px; margin-top:.5rem; }
.au-meter i { height:4px; border-radius:4px; background:rgba(255,255,255,.08); transition:background .25s; }
.au-meter[data-s="1"] i:nth-child(-n+1) { background:var(--red); }
.au-meter[data-s="2"] i:nth-child(-n+2) { background:#f59e0b; }
.au-meter[data-s="3"] i:nth-child(-n+3) { background:var(--blue); }
.au-meter[data-s="4"] i { background:var(--green); }

/* Blocs de l'inscription */
.au-group { margin:1.4rem 0 .9rem; display:flex; align-items:center; gap:.6rem; font-size:.72rem; font-weight:800; letter-spacing:.12em; text-transform:uppercase; color:var(--dim); }
.au-group::after { content:''; flex:1; height:1px; background:var(--line); }
.au-group:first-of-type { margin-top:0; }

/* Aperçu du club */
.au-club { display:flex; align-items:center; gap:.9rem; padding:.9rem; border-radius:16px; background:linear-gradient(135deg, color-mix(in srgb, var(--cc, #4f8ef7) 20%, var(--card)), var(--card) 70%); border:1px solid var(--line2); margin-bottom:1rem; transition:background .3s; }
.au-crest { width:58px; height:58px; border-radius:16px; flex-shrink:0; display:flex; align-items:center; justify-content:center; background:var(--cc, #4f8ef7); font-family:var(--display); font-weight:900; font-size:1.5rem; color:#fff; overflow:hidden; position:relative; transition:background .3s; }
.au-crest img { position:absolute; inset:0; width:100%; height:100%; object-fit:contain; background:var(--field); }
.au-club-name { font-family:var(--display); font-weight:800; font-size:1.08rem; line-height:1.15; word-break:break-word; }
.au-club-coach { font-size:.8rem; color:var(--muted); display:flex; align-items:center; gap:.4rem; margin-top:.2rem; }
.au-club-coach .au-av { width:20px; height:20px; border-radius:50%; background:var(--card2); border:1px solid var(--line2); overflow:hidden; display:inline-block; }
.au-club-coach .au-av img { width:100%; height:100%; object-fit:cover; display:block; }
.au-club-tag { margin-left:auto; align-self:flex-start; font-size:.62rem; font-weight:800; letter-spacing:.08em; text-transform:uppercase; color:var(--green); background:rgba(52,211,153,.1); border:1px solid rgba(52,211,153,.3); padding:.15rem .45rem; border-radius:999px; white-space:nowrap; }

/* Boutons d'import d'image */
.au-files { display:grid; grid-template-columns:1fr 1fr; gap:.6rem; margin-bottom:1rem; }
.au-file { position:relative; display:flex; align-items:center; gap:.55rem; padding:.7rem .75rem; border-radius:12px; border:1px dashed var(--line2); background:var(--field); cursor:pointer; transition:border-color .2s, background .2s; min-width:0; }
.au-file:hover { border-color:var(--blue); background:#0e1119; }
.au-file input { position:absolute; inset:0; opacity:0; cursor:pointer; width:100%; }
.au-file [data-lucide] { color:var(--blue2); width:18px; height:18px; }
.au-file b { display:block; font-size:.82rem; font-weight:700; }
.au-file span { display:block; font-size:.7rem; color:var(--dim); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.au-file > div { min-width:0; }
.au-file.done { border-style:solid; border-color:rgba(52,211,153,.45); }
.au-file.done [data-lucide] { color:var(--green); }
.au-file.bad { border-color:var(--red); }

/* Parrainage replié */
.au-more { margin:.2rem 0 1rem; }
.au-more summary { list-style:none; cursor:pointer; font-size:.84rem; font-weight:600; color:var(--blue2); display:inline-flex; align-items:center; gap:.35rem; }
.au-more summary::-webkit-details-marker { display:none; }
.au-more summary [data-lucide] { width:16px; height:16px; transition:transform .2s; }
.au-more[open] summary [data-lucide] { transform:rotate(45deg); }
.au-more .au-field { margin-top:.7rem; }

.au-legal { font-size:.76rem; color:var(--dim); margin:.2rem 0 1rem; }
.au-legal a { color:var(--muted); text-decoration:underline; text-underline-offset:2px; }
.au-note { display:flex; gap:.55rem; align-items:flex-start; font-size:.8rem; color:var(--muted); background:rgba(79,142,247,.07); border:1px solid rgba(79,142,247,.2); border-radius:12px; padding:.65rem .8rem; margin-bottom:1rem; }
.au-note [data-lucide] { color:var(--blue2); width:17px; height:17px; margin-top:1px; }

/* Boutons */
.au-btn { position:relative; width:100%; display:inline-flex; align-items:center; justify-content:center; gap:.5rem; border:none; cursor:pointer; border-radius:13px; padding:.9rem 1.2rem; font-weight:800; font-size:1rem; transition:transform .15s, box-shadow .15s, background .15s, opacity .15s; }
.au-btn-primary { color:#fff; background:linear-gradient(135deg, #5b97ff, #3a74e6); box-shadow:0 10px 28px -10px rgba(79,142,247,.7), inset 0 1px 0 rgba(255,255,255,.22); }
.au-btn-primary:hover { transform:translateY(-1px); box-shadow:0 14px 34px -10px rgba(79,142,247,.85), inset 0 1px 0 rgba(255,255,255,.22); }
.au-btn-ghost { color:var(--text); background:rgba(255,255,255,.05); border:1px solid var(--line2); }
.au-btn-ghost:hover { background:rgba(255,255,255,.09); }
.au-btn[disabled] { opacity:.55; cursor:not-allowed; transform:none; }
.au-btn.busy { color:transparent !important; pointer-events:none; }
.au-btn.busy::after { content:''; position:absolute; width:20px; height:20px; border-radius:50%; border:2.5px solid rgba(255,255,255,.35); border-top-color:#fff; animation:auSpin .7s linear infinite; }
@keyframes auSpin { to { transform:rotate(360deg); } }
.au-alt { text-align:center; margin-top:1.1rem; font-size:.88rem; color:var(--muted); }
.au-alt a, .au-alt button { color:var(--blue2); font-weight:700; background:none; border:none; cursor:pointer; font-size:inherit; }
.au-alt a:hover, .au-alt button:hover { text-decoration:underline; }

/* Alertes */
.au-alert { display:flex; gap:.6rem; align-items:flex-start; border-radius:12px; padding:.75rem .9rem; font-size:.88rem; margin-bottom:1.1rem; animation:auShake .4s ease; }
.au-alert [data-lucide] { width:18px; height:18px; margin-top:1px; }
.au-alert.err { background:rgba(255,107,107,.1); border:1px solid rgba(255,107,107,.35); color:#ffc9c9; }
.au-alert.err [data-lucide] { color:var(--red); }
.au-alert.ok { background:rgba(52,211,153,.1); border:1px solid rgba(52,211,153,.35); color:#c6f6e2; animation:none; }
.au-alert.ok [data-lucide] { color:var(--green); }
@keyframes auShake { 20%,60% { transform:translateX(-4px); } 40%,80% { transform:translateX(4px); } }

/* Écrans d'état (boîte mail, lien expiré, succès) */
.au-state { text-align:center; }
.au-state .au-lead { margin-bottom:1.3rem; }
.au-state-ic { width:92px; height:92px; margin:0 auto 1.3rem; border-radius:28px; display:flex; align-items:center; justify-content:center; position:relative;
  background:linear-gradient(145deg, rgba(79,142,247,.22), rgba(79,142,247,.05)); border:1px solid rgba(79,142,247,.35); color:var(--blue2); }
.au-state-ic [data-lucide] { width:42px; height:42px; stroke-width:1.7; }
.au-state-ic.mail [data-lucide] { animation:auBob 2.6s ease-in-out infinite; }
.au-state-ic.mail::after { content:''; position:absolute; top:-5px; right:-5px; width:22px; height:22px; border-radius:50%; background:var(--green); border:3px solid var(--bg); animation:auPing 2.6s ease-in-out infinite; }
.au-state-ic.warn { background:linear-gradient(145deg, rgba(249,199,79,.2), rgba(249,199,79,.04)); border-color:rgba(249,199,79,.35); color:var(--gold); }
.au-state-ic.ok { background:linear-gradient(145deg, rgba(52,211,153,.22), rgba(52,211,153,.04)); border-color:rgba(52,211,153,.4); color:var(--green); }
@keyframes auBob { 50% { transform:translateY(-4px) rotate(-4deg); } }
@keyframes auPing { 0%,100% { transform:scale(1); } 50% { transform:scale(1.18); } }
.au-email-chip { display:inline-flex; align-items:center; gap:.45rem; max-width:100%; padding:.45rem .85rem; border-radius:999px; background:var(--card); border:1px solid var(--line2); font-weight:700; font-size:.92rem; margin:-.4rem 0 1.3rem; overflow:hidden; }
.au-email-chip span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.au-email-chip [data-lucide] { width:16px; height:16px; color:var(--blue2); }
.au-steps-mini { text-align:left; list-style:none; display:grid; gap:.5rem; margin:0 0 1.3rem; }
.au-steps-mini li { display:flex; gap:.7rem; align-items:flex-start; font-size:.88rem; color:var(--muted); background:var(--card); border:1px solid var(--line); border-radius:12px; padding:.65rem .8rem; }
.au-steps-mini li b { color:var(--text); font-weight:600; }
.au-steps-mini .n { width:22px; height:22px; border-radius:7px; background:rgba(79,142,247,.15); color:var(--blue2); font-weight:800; font-size:.75rem; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.au-stack { display:grid; gap:.6rem; }

/* ── Mobile ─────────────────────────────────────────────────────── */
@media (max-width: 960px) {
  .au-shell { grid-template-columns:1fr; }
  .au-side { display:none; }
  .au-top { justify-content:space-between; padding:16px 18px; }
  .au-brand-m { display:inline-flex; }
  .au-center { padding:10px 18px 24px; }
}
@media (max-width: 420px) {
  .au-files { grid-template-columns:1fr; }
  .au-input input { font-size:16px; } /* pas de zoom iOS au focus */
}
@media (max-height: 760px) and (min-width: 961px) {
  .au-card { width:124px; height:176px; }
  .au-card img { width:84px; height:84px; }
  .au-card:nth-child(1) { --t:translate(-88px, 14px) rotate(-12deg); transform:var(--t); }
  .au-card:nth-child(3) { --t:translate(88px, 14px) rotate(12deg); transform:var(--t); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation:none !important; transition-duration:.001ms !important; }
}
