/* ==========================================================================
   Quiz chronotype  ·  La Tribu Digitale
   Toutes les classes sont préfixées .qc- pour éviter toute collision.
   S'appuie sur ltd.css : --blue-color, --orange-color, --white-color, .lisere
   ========================================================================== */

.qc-wrap {
  --qc-blue: var(--blue-color, #2B315B);
  --qc-orange: var(--orange-color, #F8B520);
  --qc-white: var(--white-color, #FFFFFF);
  --qc-ink: #2C3040;
  --qc-grey: #5A5F72;
  --qc-line: #E1E4EE;
  --qc-pale: #F5F6FA;
  --qc-cream: #FEF6E4;

  --qc-lion: #EF7D18;
  --qc-ours: #8B5E34;
  --qc-loup: #4A5A78;
  --qc-dauphin: #2FA3C7;

  max-width: 780px;
  margin: 0 auto;
  padding: 0 16px 64px;
  font-family: 'Raleway', system-ui, sans-serif;
  color: var(--qc-ink);
}

.qc-wrap *, .qc-wrap *::before, .qc-wrap *::after { box-sizing: border-box; }

/* ---------- Écrans ---------- */
.qc-screen { display: none; }
.qc-screen.qc-active { display: block; animation: qc-fade .35s ease; }
@keyframes qc-fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Intro ---------- */
.qc-intro { text-align: center; padding: 32px 0 8px; }
.qc-intro__emoji { font-size: 44px; line-height: 1; letter-spacing: 6px; margin-bottom: 18px; }
.qc-title {
  font-family: 'Lora', Georgia, serif;
  font-style: italic;
  font-size: clamp(28px, 5vw, 40px);
  line-height: 1.2;
  color: var(--qc-blue);
  margin: 0 0 16px;
}
.qc-intro__lead { font-size: 17px; line-height: 1.6; color: var(--qc-grey); max-width: 560px; margin: 0 auto 12px; }
.qc-intro__meta { font-size: 14px; color: var(--qc-grey); margin-bottom: 28px; }
.qc-intro__meta strong { color: var(--qc-blue); }

/* ---------- Boutons ---------- */
.qc-btn {
  display: inline-block;
  border: 0;
  border-radius: 999px;
  padding: 15px 34px;
  font-family: 'Raleway', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease;
}
.qc-btn--primary { background: var(--qc-orange); color: var(--qc-blue); box-shadow: 0 6px 18px rgba(248, 181, 32, .35); }
.qc-btn--primary:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(248, 181, 32, .45); }
.qc-btn--ghost { background: transparent; color: var(--qc-blue); border: 2px solid var(--qc-line); padding: 12px 26px; font-size: 15px; }
.qc-btn--ghost:hover { border-color: var(--qc-blue); }
.qc-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---------- Progression ---------- */
.qc-progress { margin: 24px 0 28px; }
.qc-progress__bar { height: 6px; background: var(--qc-line); border-radius: 99px; overflow: hidden; }
.qc-progress__fill { height: 100%; width: 0; background: var(--qc-orange); border-radius: 99px; transition: width .3s ease; }
.qc-progress__label { display: flex; justify-content: space-between; font-size: 13px; color: var(--qc-grey); margin-top: 8px; }

/* ---------- Question ---------- */
.qc-question { font-family: 'Lora', Georgia, serif; font-style: italic; font-size: clamp(21px, 3.6vw, 27px); line-height: 1.35; color: var(--qc-blue); margin: 0 0 6px; }
.qc-question__hint { font-size: 14px; color: var(--qc-grey); margin: 0 0 22px; }
.qc-options { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.qc-option {
  width: 100%;
  text-align: left;
  background: var(--qc-white);
  border: 2px solid var(--qc-line);
  border-radius: 14px;
  padding: 16px 18px;
  font-family: 'Raleway', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.45;
  color: var(--qc-ink);
  cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease, transform .1s ease;
}
.qc-option:hover { border-color: var(--qc-orange); background: var(--qc-cream); }
.qc-option:active { transform: scale(.99); }
.qc-option.qc-picked { border-color: var(--qc-orange); background: var(--qc-cream); }
.qc-nav { margin-top: 22px; display: flex; justify-content: space-between; align-items: center; }
.qc-back { background: none; border: 0; color: var(--qc-grey); font-size: 15px; cursor: pointer; padding: 8px 0; font-family: inherit; }
.qc-back:hover { color: var(--qc-blue); text-decoration: underline; }
.qc-back[hidden] { visibility: hidden; }

/* ---------- Résultat ---------- */
.qc-result__head { text-align: center; padding: 24px 0 8px; }
.qc-result__eyebrow { font-family: 'Montserrat', system-ui, sans-serif; font-size: 12px; letter-spacing: 2.5px; text-transform: uppercase; color: var(--qc-grey); }
.qc-result__emoji { font-size: 68px; line-height: 1; margin: 10px 0 6px; }
.qc-result__name { font-family: 'Lora', Georgia, serif; font-style: italic; font-size: clamp(30px, 5.5vw, 42px); margin: 0 0 6px; color: var(--qc-animal, var(--qc-blue)); }
.qc-result__tag { font-size: 16px; color: var(--qc-grey); margin: 0 0 4px; }
.qc-result__share { font-size: 14px; color: var(--qc-grey); }

.qc-card { border: 2px solid var(--qc-line); border-top: 6px solid var(--qc-animal, var(--qc-orange)); border-radius: 16px; padding: 24px 24px 8px; margin: 26px 0; }
.qc-card p { line-height: 1.65; }
.qc-card h3 { font-family: 'Montserrat', system-ui, sans-serif; font-size: 15px; font-weight: 700; color: var(--qc-blue); margin: 22px 0 8px; }
.qc-card h3:first-child { margin-top: 0; }

.qc-rythme { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 4px 0 8px; }
.qc-rythme div { background: var(--qc-pale); border-radius: 12px; padding: 14px; text-align: center; }
.qc-rythme span { display: block; font-family: 'Montserrat', system-ui, sans-serif; font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--qc-grey); margin-bottom: 4px; }
.qc-rythme strong { font-size: 16px; color: var(--qc-blue); }

.qc-day { list-style: none; margin: 0; padding: 0; }
.qc-day li { display: flex; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--qc-line); font-size: 15px; line-height: 1.5; }
.qc-day li:last-child { border-bottom: 0; }
.qc-day b { flex: 0 0 108px; color: var(--qc-animal, var(--qc-blue)); font-weight: 700; }

.qc-piege { background: var(--qc-cream); border-radius: 12px; padding: 16px 18px; font-size: 15px; line-height: 1.6; margin-bottom: 20px; }
.qc-mix { background: var(--qc-pale); border-radius: 12px; padding: 14px 18px; font-size: 14.5px; line-height: 1.6; color: var(--qc-grey); margin-bottom: 20px; }
.qc-mix[hidden] { display: none; }

/* ---------- Écran formulaire ---------- */
.qc-gate { background: var(--qc-blue); color: var(--qc-white); border-radius: 18px; padding: 34px 30px; margin: 8px 0 0; }
.qc-gate__emoji { font-size: 40px; line-height: 1; text-align: center; margin-bottom: 6px; }
.qc-gate__title { color: var(--qc-white); text-align: center; font-size: clamp(26px, 4.5vw, 34px); margin-bottom: 14px; }
.qc-gate__lead { font-size: 16px; line-height: 1.6; color: #D9DCEA; margin: 0 0 10px; }
.qc-gate__list { margin: 0 0 22px; padding-left: 20px; color: #D9DCEA; font-size: 15px; line-height: 1.75; }

.qc-field { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; margin-bottom: 12px; }
.qc-field--one { grid-template-columns: 1fr; }
.qc-field label { display: block; }
.qc-field label > span {
  display: block; font-family: 'Montserrat', system-ui, sans-serif;
  font-size: 11.5px; letter-spacing: 1.2px; text-transform: uppercase;
  color: #B9BFD6; margin-bottom: 6px;
}
.qc-field input {
  width: 100%; border: 2px solid transparent; border-radius: 10px; padding: 14px 16px;
  font-family: inherit; font-size: 16px; color: var(--qc-ink); background: var(--qc-white);
}
.qc-field input:focus { outline: none; border-color: var(--qc-orange); }
.qc-field input.qc-err { border-color: #FF8A75; }

.qc-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; line-height: 1.55; color: #C9CEE2; margin: 14px 0 0; cursor: pointer; }
.qc-consent input { margin-top: 3px; width: 17px; height: 17px; flex: 0 0 auto; accent-color: var(--qc-orange); }
.qc-consent em { font-style: normal; color: #9AA1BC; }
.qc-consent a { color: var(--qc-orange); }
.qc-submit { margin-top: 22px; width: 100%; }

/* Bloc de consentement pixels, rendu par l'include PHP.
   On se contente d'harmoniser sa couleur avec le fond bleu du formulaire. */
.qc-consent-pixels { margin-top: 16px; font-size: 13.5px; line-height: 1.55; color: #C9CEE2; }
.qc-consent-pixels a { color: var(--qc-orange); }
.qc-consent-pixels label { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.qc-consent-pixels input[type="checkbox"] { margin-top: 3px; width: 17px; height: 17px; flex: 0 0 auto; accent-color: var(--qc-orange); }

/* Case « en formation », mise en avant en tête de formulaire */
.qc-consent--formation {
  margin: 0 0 18px;
  padding: 12px 14px;
  border: 1px dashed rgba(255, 255, 255, .3);
  border-radius: 10px;
  font-size: 14px;
  color: #E4E7F2;
}
.qc-consent--formation:hover { border-color: var(--qc-orange); }
[hidden] { display: none !important; }
.qc-legal { font-size: 12.5px; line-height: 1.55; color: #A8AEC6; margin: 18px 0 0; }
.qc-legal a { color: #C9CEE2; }
.qc-sent { background: var(--qc-cream); border-radius: 12px; padding: 14px 18px; font-size: 15px; line-height: 1.6; margin-bottom: 22px; }
.qc-sent[hidden] { display: none; }
.qc-msg { margin-top: 14px; font-size: 15px; line-height: 1.6; }
.qc-msg--ok { color: var(--qc-orange); font-weight: 700; }
.qc-msg--ko { color: #FFB4A8; }

.qc-foot { text-align: center; }
.qc-note { font-size: 13.5px; line-height: 1.6; color: var(--qc-grey); font-style: italic; margin-top: 26px; }

@media (max-width: 640px) {
  .qc-rythme { grid-template-columns: 1fr; }
  .qc-field { grid-template-columns: 1fr; }
  .qc-day li { flex-direction: column; gap: 2px; }
  .qc-day b { flex: none; }
  .qc-gate { padding: 26px 20px; }
  .qc-card { padding: 20px 18px 6px; }
}
