/* Questionnaire en swipe. Reprend les jetons et les classes de style.css. */

.q-ecran { display: flex; flex-direction: column; gap: .75rem; min-height: 70vh; }
.q-ecran h1 { font-family: "Fraunces", serif; font-size: 2.2rem; line-height: 1.1; }
.q-ecran h2 { font-family: "Fraunces", serif; font-size: 1.6rem; line-height: 1.15; }
.q-note { color: var(--gris); font-size: .9rem; }
.carte .q-note { margin-top: .5rem; }
.q-apercu-mail { margin: .75rem 0; }
.q-apercu-mail pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: .85rem; background: var(--fond); border: 1px solid var(--gris); border-radius: 8px; padding: .75rem; margin: .25rem 0 0; }

.q-tete { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.bouton.q-mini { min-height: 2.75rem; padding: .4rem .8rem; font-size: .9rem; box-shadow: 2px 2px 0 var(--ombre); }
.q-progres { height: 10px; border: 2px solid var(--trait); border-radius: 99px; background: var(--surface); overflow: hidden; }
.q-progres i { display: block; height: 100%; background: var(--lime); transition: width 250ms var(--sortie); }
.q-bloc { color: var(--gris); }

.q-carte {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 16rem;
  padding: 1.5rem 1.25rem;
  background: var(--surface);
  border: 2.5px solid var(--trait);
  border-radius: 18px;
  box-shadow: 5px 5px 0 var(--ombre);
  transition: transform 250ms var(--sortie), opacity 250ms var(--sortie), background 250ms var(--sortie);
}
.q-swipe { touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.q-ecran .q-texte { font-family: "Fraunces", serif; font-size: 1.6rem; line-height: 1.25; }
.q-retour { position: absolute; top: .8rem; right: 1rem; font-weight: 700; }

.q-choisi { opacity: 0; }
.q-choisi.q-v1 { transform: translateX(60%) rotate(8deg); background: var(--lime); }
.q-choisi.q-v0 { transform: translateX(-60%) rotate(-8deg); background: var(--peche); }
.q-choisi.q-vnsp { transform: translateY(-40%); background: var(--rose); }
.q-tremble { animation: q-tremble 300ms var(--sortie); }
@keyframes q-tremble {
  25% { transform: translateX(-6px); }
  50% { transform: translateX(6px); }
  75% { transform: translateX(-3px); }
}

.q-trois { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: .5rem; }
.q-pile { display: grid; gap: .5rem; }
.q-choix { min-height: 56px; }
.q-trois .q-choix { padding: .5rem; font-size: .95rem; }
.q-pile .q-choix { justify-content: flex-start; text-align: left; }
.q-nsp { color: var(--gris); }
.q-avant { background: var(--lime); }

.q-demo { display: flex; justify-content: center; padding: 1rem 0; }
.q-demo-carte { min-height: 10rem; max-width: 18rem; animation: q-demo 3s var(--sortie) infinite; }
@keyframes q-demo {
  0%, 100% { transform: none; }
  25% { transform: translateX(30px) rotate(4deg); }
  55% { transform: translateX(-30px) rotate(-4deg); }
  80% { transform: translateY(-20px); }
}

.q-fete { text-align: center; justify-content: center; }
.q-fete .sticker { position: static; align-self: center; }

.q-libre textarea {
  width: 100%;
  padding: .75rem;
  font: inherit;
  border: 2.5px solid var(--trait);
  border-radius: 12px;
  background: var(--surface);
  color: var(--encre);
  resize: vertical;
}

@media (prefers-reduced-motion: reduce) {
  .q-carte, .q-progres i { transition: opacity 150ms linear; }
  .q-choisi, .q-choisi.q-v0, .q-choisi.q-v1, .q-choisi.q-vnsp { transform: none; }
  .q-tremble, .q-demo-carte { animation: none; }
}
.q-ecran [tabindex="-1"]:focus { outline: none; }
