/* KICKOFF · quisuisje.css : jeu « Qui suis-je ? » (énigme d'identité du jour).
   Autonome : ne dépend que des tokens (tokens.css). Motion en transform/opacity.
   Préfixe qsj- : aucun conflit avec app.css / games.css. */

@keyframes qsjIn      { from { opacity: 0; transform: translateY(16px); } }
@keyframes qsjClueIn  { from { opacity: 0; transform: translateY(10px) scale(.98); } }
@keyframes qsjHalo    { 0%,100% { opacity:.55; transform:scale(1); } 50% { opacity:.9; transform:scale(1.06); } }
@keyframes qsjLoad    { 0%,100% { opacity:.85; } 50% { opacity:.5; } }
@keyframes qsjCoteDrop{ 0% { transform:translateY(-4px); color:var(--red-glow); } 100% { transform:translateY(0); } }

.qsj-wrap { display: flex; flex-direction: column; gap: 14px; padding: 4px 2px 26px; }

.qsj-back {
  align-self: flex-start; background: none; border: none; cursor: pointer;
  color: var(--muted); font-family: var(--disp); font-style: italic; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em; font-size: 12.5px; padding: 4px 2px;
  -webkit-tap-highlight-color: transparent;
}
.qsj-back:active { transform: scale(.96); }

.qsj-loading {
  text-align: center; color: var(--muted); font-family: var(--disp); font-style: italic;
  text-transform: uppercase; letter-spacing: .1em; font-size: 13px; padding: 60px 0;
  animation: qsjLoad 1.4s ease-in-out infinite;
}

/* ---------- hero d'intro ---------- */
.qsj-hero { text-align: center; padding: 10px 0 2px; animation: qsjIn .5s cubic-bezier(.16,1,.3,1) both; }
.qsj-hero-badge {
  position: relative; width: 92px; height: 92px; margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
}
.qsj-hero-halo {
  position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle, rgba(232,0,13,.42), transparent 68%);
  animation: qsjHalo 2.6s ease-in-out infinite;
}
.qsj-hero-mark {
  position: relative; font-family: var(--disp); font-style: italic; font-weight: 700;
  font-size: 54px; color: var(--txt);
  width: 84px; height: 84px; display: flex; align-items: center; justify-content: center;
  border: 1.5px solid rgba(244,244,246,.16); border-radius: 22px;
  background: linear-gradient(180deg, var(--ink-3), var(--ink-2));
  box-shadow: inset 0 0 24px rgba(232,0,13,.14);
}
.qsj-hero-title { font-size: 30px; margin-top: 2px; }
.qsj-slash { color: var(--red); text-shadow: 0 0 12px rgba(232,0,13,.8); padding: 0 .02em; }
.qsj-hero-sub { font-size: 13px; margin-top: 3px; }

/* ---------- règles ---------- */
.qsj-rules { animation: qsjIn .5s cubic-bezier(.16,1,.3,1) .06s both; }
.qsj-rules ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.qsj-rules li { display: flex; gap: 12px; align-items: flex-start; font-size: 13.5px; color: rgba(244,244,246,.9); }
.qsj-rule-b {
  flex: none; width: 24px; height: 24px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--disp); font-style: italic; font-weight: 700; font-size: 13px; color: #fff;
  background: linear-gradient(135deg, var(--red), var(--red-deep)); box-shadow: var(--glow-red);
}

/* ---------- barre haute (tier / type / cote) ---------- */
.qsj-top { display: flex; align-items: center; gap: 10px; }
.qsj-kind { font-family: var(--disp); font-style: italic; font-weight: 700; text-transform: uppercase;
  letter-spacing: .1em; font-size: 12px; color: var(--txt); }
.qsj-cote { margin-left: auto; display: inline-flex; align-items: baseline; gap: 5px; }
.qsj-cote b { font-family: var(--disp); font-style: italic; font-weight: 700; font-size: 22px; color: var(--gold); }
.qsj-cote span { font-size: 10px; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); font-weight: 700; }
.qsj-cote-drop { animation: qsjCoteDrop .45s ease-out; }

/* ---------- le dossier ---------- */
.qsj-file { animation: qsjIn .5s cubic-bezier(.16,1,.3,1) both; }
.qsj-file-head { display: flex; align-items: center; gap: 13px; padding-bottom: 12px; border-bottom: 1px dashed var(--line-2); }
.qsj-sil {
  flex: none; width: 52px; height: 52px; border-radius: 14px; color: rgba(244,244,246,.32);
  display: flex; align-items: center; justify-content: center;
  background: repeating-linear-gradient(135deg, rgba(255,255,255,.04) 0 6px, transparent 6px 12px), var(--ink);
  border: 1px solid var(--line);
}
.qsj-sil svg { width: 30px; height: 30px; }
.qsj-file-name {
  font-family: var(--disp); font-style: italic; font-weight: 700; font-size: 22px; letter-spacing: .18em;
  color: rgba(244,244,246,.5);
}

.qsj-progress { display: flex; gap: 5px; margin: 12px 0 4px; }
.qsj-pip { flex: 1; height: 4px; border-radius: 999px; background: rgba(255,255,255,.08); transition: background .3s ease; }
.qsj-pip.on { background: linear-gradient(90deg, var(--red), var(--red-glow)); }

.qsj-clues { list-style: none; display: flex; flex-direction: column; gap: 9px; margin: 12px 0 4px; }
.qsj-clue { display: flex; gap: 11px; align-items: flex-start;
  background: var(--ink); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 11px 12px; }
.qsj-clue-fresh { animation: qsjClueIn .42s cubic-bezier(.16,1,.3,1) both; }
.qsj-clue-no {
  flex: none; width: 20px; height: 20px; border-radius: 6px; margin-top: 1px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--disp); font-style: italic; font-weight: 700; font-size: 12px;
  color: var(--gold); background: rgba(244,195,59,.12); border: 1px solid rgba(244,195,59,.3);
}
.qsj-clue-ico { flex: none; width: 16px; height: 16px; color: var(--muted); margin-top: 3px; }
.qsj-clue-ico svg { width: 16px; height: 16px; }
.qsj-clue-txt { font-size: 13.5px; line-height: 1.45; color: rgba(244,244,246,.92); }

.qsj-reveal {
  width: 100%; margin-top: 6px; cursor: pointer;
  background: transparent; border: 1px dashed var(--line-2); border-radius: 12px;
  color: rgba(244,244,246,.86); font-family: var(--disp); font-style: italic; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em; font-size: 12.5px; padding: 11px 12px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  transition: border-color .2s ease, transform .12s ease; -webkit-tap-highlight-color: transparent;
}
.qsj-reveal:hover { border-color: rgba(232,0,13,.5); }
.qsj-reveal:active { transform: scale(.98); }
.qsj-reveal:disabled { opacity: .5; cursor: wait; }
.qsj-reveal-cost { font-size: 10px; letter-spacing: .1em; color: var(--muted); font-style: normal; }
.qsj-allout { text-align: center; font-size: 12.5px; margin-top: 8px; font-style: italic; }

/* ---------- réponses ---------- */
.qsj-answer-lead { text-align: center; margin-top: 2px; }
.qsj-choices { display: flex; flex-direction: column; gap: 9px; }
.qsj-choice {
  display: flex; align-items: center; gap: 12px; width: 100%; cursor: pointer; text-align: left;
  background: linear-gradient(180deg, var(--ink-3), var(--ink-2));
  border: 1px solid var(--line); border-radius: 12px; padding: 13px 14px; color: var(--txt);
  transition: transform .12s ease, border-color .2s ease, background .2s ease;
  -webkit-tap-highlight-color: transparent; animation: qsjClueIn .4s cubic-bezier(.16,1,.3,1) both;
}
.qsj-choice:active { transform: scale(.985); }
.qsj-choice:disabled { cursor: default; }
.qsj-choice-k {
  flex: none; width: 26px; height: 26px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--disp); font-style: italic; font-weight: 700; font-size: 13px;
  color: var(--muted); background: rgba(255,255,255,.05); border: 1px solid var(--line);
}
.qsj-choice-t { font-size: 14.5px; font-weight: 600; }
.qsj-choice.good { border-color: rgba(34,197,94,.6); background: linear-gradient(135deg, rgba(34,197,94,.18), var(--ink-3)); }
.qsj-choice.good .qsj-choice-k { color: var(--green); border-color: rgba(34,197,94,.5); background: rgba(34,197,94,.14); }
.qsj-choice.bad { border-color: rgba(232,0,13,.6); background: linear-gradient(135deg, rgba(232,0,13,.16), var(--ink-3)); }
.qsj-choice.bad .qsj-choice-k { color: var(--red-glow); border-color: rgba(232,0,13,.5); background: rgba(232,0,13,.14); }
.qsj-choice-wait { opacity: .8; }

/* ---------- résultat ---------- */
.qsj-result { text-align: center; animation: qsjIn .45s cubic-bezier(.16,1,.3,1) both; }
.qsj-reveal-name { font-size: 26px; margin: 8px 0 4px; letter-spacing: .01em; }
.qsj-result-pts { font-size: 38px; margin: 4px 0 6px; }
.qsj-result-sub { font-size: 13px; }
.qsj-record { margin: 2px 0 6px; }
.qsj-record .pill { display: inline-flex; align-items: center; gap: 4px; }

/* ---------- upsell / verrous ---------- */
.qsj-upsell { text-align: left; }
.qsj-upsell p { font-size: 13px; color: rgba(244,244,246,.86); margin-top: 4px; }
.qsj-locked { text-align: center; padding: 26px 16px; }
.qsj-lock-ico { width: 46px; height: 46px; margin: 0 auto 12px; color: var(--muted); }
.qsj-lock-ico svg { width: 46px; height: 46px; }

@media (prefers-reduced-motion: reduce) {
  .qsj-hero, .qsj-rules, .qsj-file, .qsj-clue-fresh, .qsj-choice, .qsj-result,
  .qsj-hero-halo, .qsj-cote-drop { animation: none !important; }
}
