/* pandrezz · dancefloor club — page de création de perso */
:root {
  --night: #0b0618;
  --night2: #150a2b;
  --card: rgba(24, 13, 48, .72);
  --card-solid: #1a0e34;
  --line: rgba(173, 120, 255, .22);
  --line-strong: rgba(173, 120, 255, .5);
  --text: #f6f1ff;
  --muted: #b8acd9;
  --pink: #ff2fb3;
  --cyan: #28e7ff;
  --yellow: #ffe23d;
  --violet: #9b5cff;
  --green: #3dff8b;
  --twitch: #9146ff;
  --radius: 18px;
  --pixel: 'Pixelify Sans', ui-monospace, monospace;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--night);
  color: var(--text);
  font: 16px/1.5 var(--sans);
  overflow-x: hidden;
}
img { max-width: 100%; }
button, input, textarea { font: inherit; color: inherit; }

/* ---------------------------------------------------------------- fond */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: radial-gradient(120% 80% at 50% 0%, #241046 0%, var(--night) 60%); }
.glow {
  position: absolute;
  width: 60vmax; height: 60vmax;
  border-radius: 50%;
  filter: blur(60px);
  opacity: .35;
  will-change: transform;
}
.g1 { background: var(--pink); top: -25vmax; left: -20vmax; animation: drift1 18s ease-in-out infinite alternate; }
.g2 { background: var(--cyan); bottom: -30vmax; right: -25vmax; opacity: .22; animation: drift2 22s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(14vmax, 10vmax) scale(1.1); } }
@keyframes drift2 { to { transform: translate(-12vmax, -8vmax) scale(1.15); } }
.grid {
  position: absolute;
  left: -50%; right: -50%; bottom: -10%;
  height: 55%;
  background-image:
    linear-gradient(rgba(255, 47, 179, .35) 2px, transparent 2px),
    linear-gradient(90deg, rgba(40, 231, 255, .25) 2px, transparent 2px);
  background-size: 64px 64px;
  transform: perspective(420px) rotateX(62deg);
  transform-origin: 50% 0;
  mask-image: linear-gradient(transparent, #000 35%);
  -webkit-mask-image: linear-gradient(transparent, #000 35%);
  animation: gridmove 6s linear infinite;
}
@keyframes gridmove { to { background-position: 0 64px, 0 0; } }

/* ---------------------------------------------------------------- en-tête */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  max-width: 980px;
  margin: 0 auto;
  padding: max(18px, env(safe-area-inset-top)) 20px 8px;
}
.brand { text-decoration: none; color: inherit; display: flex; flex-direction: column; line-height: 1; }
.logo {
  font-family: var(--pixel);
  font-weight: 700;
  font-size: clamp(30px, 7vw, 42px);
  letter-spacing: .02em;
  color: #fff;
  text-shadow: 0 0 6px var(--pink), 0 0 18px rgba(255, 47, 179, .7), 0 0 38px rgba(255, 47, 179, .45);
  animation: flicker 7s infinite;
}
.tagline {
  font-family: var(--pixel);
  font-size: 13px;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--cyan);
  text-shadow: 0 0 10px rgba(40, 231, 255, .6);
  margin-top: 6px;
}
@keyframes flicker {
  0%, 92%, 100% { opacity: 1; }
  93% { opacity: .55; }
  94% { opacity: 1; }
  96% { opacity: .7; }
}
.who { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); }
.who img { width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--line-strong); }
.who a { color: var(--muted); }

/* ---------------------------------------------------------------- structure */
.app { max-width: 980px; margin: 0 auto; padding: 12px 20px 40px; }
.foot { text-align: center; color: #7f73a6; font-size: 13px; padding: 10px 20px max(28px, env(safe-area-inset-bottom)); }
.foot b { color: var(--muted); }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(18px, 4vw, 28px);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .05);
}
.stack { display: flex; flex-direction: column; gap: 18px; }
.reveal { animation: rise .6s cubic-bezier(.2, .8, .2, 1) both; }
.reveal:nth-child(2) { animation-delay: .08s; }
.reveal:nth-child(3) { animation-delay: .16s; }
.reveal:nth-child(4) { animation-delay: .24s; }
.reveal:nth-child(5) { animation-delay: .32s; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }

h1, h2, h3 { margin: 0; line-height: 1.15; }
h1 { font-size: clamp(30px, 7.5vw, 52px); font-weight: 800; letter-spacing: -.02em; }
h1 .hl {
  background: linear-gradient(90deg, var(--pink), var(--yellow) 50%, var(--cyan));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
h2 { font-size: 20px; font-weight: 800; display: flex; align-items: center; gap: 10px; }
h2 .num {
  font-family: var(--pixel);
  display: inline-grid; place-items: center;
  width: 30px; height: 30px; flex: none;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--pink), var(--violet));
  font-size: 17px;
  box-shadow: 0 0 16px rgba(255, 47, 179, .45);
}
.lead { color: var(--muted); font-size: clamp(16px, 3.6vw, 19px); margin: 12px 0 0; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

/* ---------------------------------------------------------------- hero */
.hero { display: grid; grid-template-columns: 1.2fr 1fr; gap: 28px; align-items: center; padding: 18px 0 8px; }
@media (max-width: 760px) { .hero { grid-template-columns: 1fr; text-align: center; gap: 8px; } .hero .stage { order: -1; } }
.stage { position: relative; display: grid; place-items: center; height: 300px; }
@media (max-width: 760px) { .stage { height: 230px; } }
.podium {
  position: absolute; bottom: 18px;
  width: 230px; height: 46px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 47, 179, .55), rgba(155, 92, 255, .25) 60%, transparent);
  animation: pulse 0.5s ease-in-out infinite alternate;
}
@keyframes pulse { to { transform: scale(1.08); opacity: .8; } }
.dancer { position: relative; width: 264px; height: 264px; image-rendering: pixelated; filter: drop-shadow(0 8px 0 rgba(0, 0, 0, .35)); }
@media (max-width: 760px) { .dancer { width: 200px; height: 200px; } }
.spot {
  position: absolute; top: -10px; width: 120px; height: 300px;
  background: linear-gradient(180deg, rgba(40, 231, 255, .35), transparent 80%);
  clip-path: polygon(45% 0, 55% 0, 100% 100%, 0 100%);
  transform-origin: 50% 0;
  animation: sweep 4s ease-in-out infinite alternate;
  mix-blend-mode: screen;
}
.spot.s2 { background: linear-gradient(180deg, rgba(255, 47, 179, .35), transparent 80%); animation-duration: 5s; animation-direction: alternate-reverse; }
@keyframes sweep { from { transform: rotate(-22deg); } to { transform: rotate(22deg); } }

.features { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 10px; }
@media (max-width: 760px) { .features { text-align: left; } }
.features li { display: flex; gap: 12px; align-items: flex-start; color: var(--muted); }
.features b { color: var(--text); }
.features .ic { font-size: 20px; line-height: 1.3; }

/* ---------------------------------------------------------------- boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px;
  padding: 12px 24px;
  border: 0;
  border-radius: 14px;
  font-weight: 800;
  font-size: 17px;
  text-decoration: none;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(135deg, var(--pink), var(--violet));
  box-shadow: 0 10px 30px rgba(255, 47, 179, .35), inset 0 1px 0 rgba(255, 255, 255, .25);
  transition: transform .15s ease, box-shadow .2s ease, filter .2s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 14px 36px rgba(255, 47, 179, .45), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn:active { transform: translateY(0) scale(.98); }
.btn:disabled { opacity: .55; cursor: default; transform: none; }
.btn.twitch { background: var(--twitch); box-shadow: 0 10px 30px rgba(145, 70, 255, .4), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn.ghost { background: transparent; border: 1px solid var(--line-strong); box-shadow: none; }
.btn.block { width: 100%; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
@media (max-width: 760px) { .cta-row { justify-content: center; } .cta-row .btn { width: 100%; } }

/* ---------------------------------------------------------------- formulaire */
.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
@media (max-width: 520px) { .choice-grid { grid-template-columns: 1fr; } }
.choice {
  position: relative;
  text-align: left;
  padding: 18px;
  border-radius: 16px;
  border: 1.5px solid var(--line);
  background: rgba(255, 255, 255, .03);
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .15s;
  -webkit-tap-highlight-color: transparent;
}
.choice:hover { border-color: var(--line-strong); }
.choice.on {
  border-color: var(--pink);
  background: linear-gradient(135deg, rgba(255, 47, 179, .14), rgba(155, 92, 255, .1));
  box-shadow: 0 0 0 4px rgba(255, 47, 179, .12);
}
.choice .ic { font-size: 28px; }
.choice b { display: block; font-size: 17px; margin-top: 6px; }
.choice span { color: var(--muted); font-size: 14px; }
.choice .badge { position: absolute; top: 12px; right: 12px; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; background: rgba(40, 231, 255, .14); color: var(--cyan); }

label.field { display: block; margin-top: 16px; }
label.field > span { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
label.field > small { display: block; color: var(--muted); font-size: 13px; margin-top: 6px; }
textarea, input[type=text] {
  width: 100%;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: rgba(8, 4, 20, .6);
  font-size: 16px; /* évite le zoom auto sur iPhone */
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  resize: vertical;
}
textarea:focus, input[type=text]:focus { border-color: var(--cyan); box-shadow: 0 0 0 4px rgba(40, 231, 255, .12); }
.counter { float: right; font-weight: 500; color: var(--muted); font-size: 13px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.chip {
  padding: 9px 14px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: rgba(255, 255, 255, .03);
  font-size: 14px; font-weight: 600;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.chip.on { border-color: var(--cyan); background: rgba(40, 231, 255, .12); color: #dffaff; }
.chip.ex { font-weight: 500; color: var(--muted); }

.colors { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
.swatch {
  width: 46px; height: 46px; border-radius: 12px;
  border: 2px solid var(--line-strong);
  cursor: pointer; position: relative; overflow: hidden;
}
.swatch input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.swatch.empty { background: repeating-linear-gradient(45deg, rgba(255,255,255,.06) 0 6px, transparent 6px 12px); display: grid; place-items: center; color: var(--muted); font-size: 22px; }
.linkbtn { background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; font-size: 14px; padding: 4px; }

.drop {
  display: grid; place-items: center; gap: 6px;
  min-height: 170px;
  margin-top: 8px;
  border: 2px dashed var(--line-strong);
  border-radius: 16px;
  background: rgba(255, 255, 255, .02);
  text-align: center;
  padding: 18px;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}
.drop:hover, .drop.over { border-color: var(--cyan); background: rgba(40, 231, 255, .05); }
.drop .ic { font-size: 34px; }
.drop img { max-height: 260px; border-radius: 12px; }
.privacy {
  display: flex; gap: 10px; align-items: flex-start;
  margin-top: 12px; padding: 12px 14px;
  border-radius: 12px;
  background: rgba(40, 231, 255, .06);
  border: 1px solid rgba(40, 231, 255, .25);
  color: #cfeff7; font-size: 13.5px;
}

.moves { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 14px; }
@media (max-width: 640px) { .moves { grid-template-columns: repeat(2, 1fr); } }
.move {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 14px 8px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: rgba(255, 255, 255, .03);
  cursor: pointer; font-weight: 700; font-size: 15px;
  transition: border-color .2s, background .2s, transform .15s;
  -webkit-tap-highlight-color: transparent;
}
.move .ic { font-size: 28px; transition: transform .3s cubic-bezier(.3, 1.6, .5, 1); }
.move:hover .ic { transform: scale(1.15) rotate(-6deg); }
.move.on { border-color: var(--yellow); background: rgba(255, 226, 61, .1); box-shadow: 0 0 0 4px rgba(255, 226, 61, .1); }
.move.custom { grid-column: span 4; flex-direction: row; justify-content: center; gap: 10px; }
@media (max-width: 640px) { .move.custom { grid-column: span 2; } }
.warn {
  margin-top: 10px; padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 226, 61, .07);
  border: 1px solid rgba(255, 226, 61, .3);
  color: #ffeeb0; font-size: 13.5px;
}

.submit-bar { position: sticky; bottom: 0; padding: 14px 0 max(14px, env(safe-area-inset-bottom)); background: linear-gradient(transparent, var(--night) 35%); z-index: 2; }
.error { color: #ff9db2; font-weight: 600; margin: 0 0 10px; text-align: center; }

/* ---------------------------------------------------------------- suivi */
.status-hero { display: grid; grid-template-columns: 220px 1fr; gap: 24px; align-items: center; }
@media (max-width: 640px) { .status-hero { grid-template-columns: 1fr; text-align: center; } }
.preview {
  width: 220px; height: 220px; margin: 0 auto;
  border-radius: 20px;
  display: grid; place-items: center;
  background: radial-gradient(circle at 50% 70%, rgba(255, 47, 179, .3), transparent 65%), rgba(8, 4, 20, .6);
  border: 1px solid var(--line);
  position: relative; overflow: hidden;
}
.preview img { width: 200px; height: 200px; image-rendering: pixelated; }
.preview .gift { font-size: 76px; animation: wobble 1.4s ease-in-out infinite; }
@keyframes wobble { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-8deg) translateY(-6px); } 50% { transform: rotate(6deg); } 75% { transform: rotate(-3deg) translateY(-3px); } }

.timeline { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 4px; }
.timeline li { display: flex; gap: 12px; align-items: center; color: #7f73a6; padding: 6px 0; }
.timeline .dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; flex: none; }
.timeline li.done { color: var(--muted); }
.timeline li.done .dot { background: var(--green); border-color: var(--green); }
.timeline li.now { color: var(--text); font-weight: 700; }
.timeline li.now .dot { border-color: var(--pink); background: var(--pink); box-shadow: 0 0 0 0 rgba(255, 47, 179, .6); animation: ping 1.4s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 10px rgba(255, 47, 179, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 47, 179, 0); } }

.recap { display: grid; gap: 6px; margin-top: 16px; font-size: 15px; }
.recap div { color: var(--muted); }
.recap b { color: var(--text); }
.cmds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; }
@media (max-width: 520px) { .cmds { grid-template-columns: 1fr; } }
.cmd { padding: 14px; border-radius: 14px; background: rgba(255, 255, 255, .04); border: 1px solid var(--line); text-align: center; }
.cmd code { font-family: var(--pixel); font-size: 20px; color: var(--yellow); }
.cmd div { color: var(--muted); font-size: 13px; margin-top: 4px; }
.notice { padding: 14px 16px; border-radius: 14px; background: rgba(255, 84, 112, .08); border: 1px solid rgba(255, 84, 112, .35); color: #ffd0da; }

.loading { display: flex; justify-content: center; gap: 8px; padding: 80px 0; }
.loading .dot { width: 12px; height: 12px; border-radius: 3px; background: var(--pink); animation: bounce .9s ease-in-out infinite; }
.loading .dot:nth-child(2) { background: var(--cyan); animation-delay: .15s; }
.loading .dot:nth-child(3) { background: var(--yellow); animation-delay: .3s; }
@keyframes bounce { 50% { transform: translateY(-12px); } }

.confetti { position: fixed; top: -12px; width: 9px; height: 9px; z-index: 50; pointer-events: none; animation: fall linear forwards; }
@keyframes fall { to { transform: translateY(110vh) rotate(720deg); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition: none !important; }
}
