/* ═══════════════════════════════════════════
   STAND-UP ACADEMY — LES DEUX CHOIX ANIMÉS DE LA PAGE DES ÉCRANS TV, pour l'inscription (18/11/2026)
   ───────────────────────────────────────────
   Extrait automatiquement de questionnaire.css : uniquement les cartes de choix (.rp-choice),
   leurs étiquettes et les deux animations (Découverte = a1-*, Set Pro = a2-*).
   « data-offer » devient « data-level » (sinon inscription-modal.js ouvrirait sa fenêtre au clic).
   Si les animations changent sur la page TV, régénérer ce fichier.
   ═══════════════════════════════════════════ */

/* ============================================================
   STAND-UP ACADEMY · Page « Questionnaire » (QR code écrans)
   DA calquée sur la home : fond marron, grosses sphères orange
   coupées sur les bords (mêmes SVG que les sections de la home),
   blocs en verre brun avec filet orange, titres Bebas Neue.
   Un seul rectangle orange sur la page : « qui te correspond ».
   Page isolée : ne dépend d'aucune autre CSS du site (hors SVG).

   MISE EN PAGE : la page occupe toute la hauteur de l'écran sans
   défiler. Espacements et tailles suivent la hauteur (--vh), et
   les cartes / le formulaire s'étirent pour remplir l'espace.
   ============================================================ */

:root {
    --rp-orange:     #f07a1a;
    --rp-orange-1:   #f1951b;
    --rp-orange-2:   #f14000;
    --rp-orange-3:   #fbb56a;
    --rp-brown-deep: #1a0a00;
    --rp-cream:      #f0ece4;
    --rp-text:       #f3efe8;
    --rp-text-2:     #d4cbbb;
    --rp-text-3:     #9a8f80;

    /* Couleurs des parcours (celles de la home) */
    --rp-purple:        #d876ff;
    --rp-purple-bg:     rgba(216, 118, 255, 0.14);
    --rp-purple-border: rgba(216, 118, 255, 0.40);
    --rp-red:           #ff4d4d;
    --rp-red-bg:        rgba(255, 49, 49, 0.14);
    --rp-red-border:    rgba(255, 49, 49, 0.40);

    /* 1 % de la hauteur visible (dvh = hauteur sans les barres du navigateur mobile) */
    --vh: 1vh;
}

@supports (height: 100dvh) {
    :root { --vh: 1dvh; }
}

/* ─── Blocs en verre brun, avec un filet orange plus épais en haut ─── */
.rp-glass,
.rp-choice {
    position: relative;
    background: linear-gradient(165deg, rgba(140, 66, 0, 0.30) 0%, rgba(26, 10, 0, 0.66) 100%);
    border: 1px solid rgba(240, 122, 26, 0.28);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    -webkit-backdrop-filter: blur(14px) saturate(130%);
    backdrop-filter: blur(14px) saturate(130%);
    border-radius: 20px;
}

.rp-glass::before,
.rp-choice::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 10%;
    right: 10%;
    height: 3px;
    border-radius: 0 0 4px 4px;
    background: linear-gradient(90deg, transparent 0%, var(--rp-orange) 28%, var(--rp-orange-1) 72%, transparent 100%);
    box-shadow: 0 0 14px rgba(240, 122, 26, 0.65);
    pointer-events: none;
}

/* ─── Tags de parcours (couleur du parcours) ─── */
.rp-choice-tag {
    --tag: var(--rp-orange-3);
    --tag-bg: rgba(240, 122, 26, 0.14);
    --tag-border: rgba(240, 122, 26, 0.4);
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    height: 20px;
    padding: 0 9px;
    border-radius: 999px;
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    line-height: 1;
    white-space: nowrap;
    color: var(--tag);
    /* Fond sombre sous la teinte du parcours : reste lisible devant les sphères orange */
    background: linear-gradient(var(--tag-bg), var(--tag-bg)), rgba(18, 6, 0, 0.78);
    border: 1px solid var(--tag-border);
}

[data-level="decouverte"].rp-choice-tag { --tag: var(--rp-purple); --tag-bg: var(--rp-purple-bg); --tag-border: var(--rp-purple-border); }

[data-level="semipro"].rp-choice-tag    { --tag: var(--rp-red);    --tag-bg: var(--rp-red-bg);    --tag-border: var(--rp-red-border); }

/* ─── Réponses : les deux cartes se partagent la hauteur restante ─── */
.rp-choices {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    gap: clamp(12px, calc(var(--vh) * 2.2), 26px);
}

.rp-choice {
    --accent: var(--rp-orange);
    flex: 1 1 0;
    min-height: min-content;
    max-height: 300px;
    display: grid;
    grid-template-columns: minmax(118px, 42%) 1fr;
    gap: clamp(12px, calc(var(--vh) * 1.8), 20px);
    align-items: stretch;
    text-align: left;
    width: 100%;
    padding: clamp(10px, calc(var(--vh) * 1.5), 16px) 10px clamp(10px, calc(var(--vh) * 1.5), 16px);
    color: var(--rp-text);
    font: inherit;
    cursor: pointer;
    transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}

.rp-choice[data-level="decouverte"] { --accent: var(--rp-purple); }

.rp-choice[data-level="semipro"]    { --accent: var(--rp-red); }

.rp-choice:hover,
.rp-choice:focus-visible {
    border-color: var(--rp-orange);
    transform: translateY(-2px);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.42), 0 0 28px rgba(240, 122, 26, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    outline: none;
}

/* Cadre de l'illustration, à gauche (le Lottie viendra remplir ce cadre) */
.rp-choice-slot {
    display: grid;
    place-items: center;
    padding: 8px;
    border-radius: 16px;
    color: var(--accent);
    background: rgba(18, 6, 0, 0.5);
    border: 1px solid color-mix(in srgb, var(--accent) 38%, transparent);
    box-shadow: inset 0 0 30px color-mix(in srgb, var(--accent) 14%, transparent);
    overflow: hidden;
}

.rp-choice-slot > svg { width: min(100%, calc(var(--vh) * 15)); max-width: 150px; height: auto; transition: transform .25s ease; }

.rp-choice:hover .rp-choice-slot > svg { transform: scale(1.06) rotate(-2deg); }

.rp-choice-slot > lottie-player { width: 100%; height: 100%; }

/* Texte à droite, centré verticalement à côté de l'illustration */
.rp-choice-main {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: clamp(7px, calc(var(--vh) * 1.3), 14px);
    min-width: 0;
    padding: 4px 6px 4px 0;
}

.rp-choice-title {
    display: block;
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(23px, min(6.6vw, calc(var(--vh) * 3.2)), 31px);
    line-height: 1;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #fff;
}

.rp-choice-sub {
    font-size: clamp(13px, min(3.5vw, calc(var(--vh) * 1.65)), 15px);
    color: var(--rp-text-2);
    line-height: 1.4;
}

.rp-nowrap { white-space: nowrap; }

@media (max-width: 420px) {
    .rp-choice-slot { padding: 6px; }
}

@media (max-width: 380px) {
    .rp-choice-tag { letter-spacing: 0.04em; padding: 0 7px; }
}

@media (max-height: 700px) {
    .rp-choice-sub { font-size: 12.5px; line-height: 1.32; }
}

@media (max-height: 600px) {
    .rp-choice-sub { display: none; }
}

/* ============================================================
   ANIMATION « DÉCOUVERTE » (storyboard, boucle de 7 s)
   1. l'homme monte depuis le bas à gauche
   2. la scène arrive par la droite et glisse vers la gauche
   3. le pied de micro tombe et se pose, puis le micro
   4. l'homme penche la tête, deux « ? » apparaissent
   5. tout repart d'où il venait, dans l'ordre inverse
   Formes arrondies uniquement, couleur = couleur du parcours.
   ============================================================ */
.rp-choice-slot > .rp-anim { width: 100%; height: 100%; overflow: hidden; align-self: stretch; }

.rp-choice-slot:has(> .rp-anim) { padding: 0; }

/* fill-box seulement sur les éléments animés : les transform="…" du SVG gardent leur repère */
.rp-anim [class*="a1-"] { transform-box: fill-box; }

/* Courbe « in-out » douce sur chaque segment, sans rebond. Arrivées en léger
   décalage (un élément toutes les ~0,25 s), départs tous en même temps. */
.rp-anim-decouverte [class*="a1-"] { animation-duration: 6s; animation-iteration-count: infinite; animation-timing-function: cubic-bezier(.65, 0, .35, 1); }

.rp-anim-decouverte .a1-man   { animation-name: a1-man; }

.rp-anim-decouverte .a1-stage { animation-name: a1-stage; }

.rp-anim-decouverte .a1-stand { animation-name: a1-stand; }

.rp-anim-decouverte .a1-mic   { animation-name: a1-mic; }

.rp-anim-decouverte .a1-head  { animation-name: a1-head; transform-origin: 50% 100%; /* tête + cou pivotent à la base du cou */ }

.rp-anim-decouverte .a1-q     { transform-origin: 30% 100%; }

.rp-anim-decouverte .a1-q1    { animation-name: a1-q1; }

.rp-anim-decouverte .a1-q2    { animation-name: a1-q2; }

/* Arrivées : 0 → 12 %, 4 → 16 %, 8 → 20 %, 12 → 24 %, avec un petit rebond.
   Départs : tous de 80 à 94 %. */
@keyframes a1-man {
    0%        { transform: translateY(60px); }
    14%, 80%  { transform: translateY(0); }
    94%, 100% { transform: translateY(60px); }
}

@keyframes a1-stage {
    0%, 4%    { transform: translateX(45px); opacity: 0; }
    16%       { transform: translateX(-4px); opacity: 1; }
    19%, 80%  { transform: translateX(0);    opacity: 1; }
    94%, 100% { transform: translateX(45px); opacity: 0; }
}

@keyframes a1-stand {
    0%, 8%    { transform: translateY(-110px); }
    17%       { transform: translateY(3px); }
    20%       { transform: translateY(-5px); }
    23%       { transform: translateY(1px); }
    25%, 100% { transform: translateY(0); }
}

@keyframes a1-mic {
    0%, 12%   { transform: translateY(-110px); }
    21%       { transform: translateY(3px); }
    24%       { transform: translateY(-5px); }
    27%       { transform: translateY(1px); }
    29%, 100% { transform: translateY(0); }
}

/* Oscillation amortie du pied (et du micro posé dessus) après l'atterrissage */
.rp-anim-decouverte .a1-rig { transform-box: view-box; transform-origin: 66px 91px; animation-name: a1-rig; }

/* … puis au départ : la scène l'emporte (il est dedans) et il bascule vers la gauche
   par inertie, sur exactement la même durée que la scène (80 → 94 %). */
@keyframes a1-rig {
    0%, 18%   { transform: rotate(0); }
    22%       { transform: rotate(5deg); }
    27%       { transform: rotate(-4deg); }
    32%       { transform: rotate(2.5deg); }
    37%       { transform: rotate(-1.2deg); }
    42%, 80%  { transform: rotate(0); }
    94%, 100% { transform: rotate(-14deg); }
}

@keyframes a1-head {
    0%, 26%   { transform: rotate(0); }
    36%, 74%  { transform: rotate(12deg); }
    86%, 100% { transform: rotate(0); }
}

@keyframes a1-q1 {
    0%, 32%   { transform: scale(0); opacity: 0; }
    42%, 74%  { transform: scale(1); opacity: 1; }
    84%, 100% { transform: scale(0); opacity: 0; }
}

@keyframes a1-q2 {
    0%, 36%   { transform: scale(0); opacity: 0; }
    46%, 74%  { transform: scale(1); opacity: 1; }
    84%, 100% { transform: scale(0); opacity: 0; }
}

/* ============================================================
   ANIMATION « SET PRO » (storyboard, boucle de 6 s comme Découverte)
   1. le public (4 personnes) monte du bas, en léger décalage
   2. la scène monte avec l'humoriste dessus
   3. le pied de micro tombe d'en haut (rebond + oscillation), puis le micro
   4. tout repart vers le bas en même temps
   Scène, pied et micro aux mêmes dimensions que l'animation Découverte.
   ============================================================ */
.rp-anim [class*="a2-"] { transform-box: fill-box; }

.rp-anim-setpro [class*="a2-"] { animation-duration: 6s; animation-iteration-count: infinite; animation-timing-function: cubic-bezier(.65, 0, .35, 1); }

.rp-anim-setpro .a2-p1    { animation-name: a2-p1; }

.rp-anim-setpro .a2-p2    { animation-name: a2-p2; }

.rp-anim-setpro .a2-p3    { animation-name: a2-p3; }

.rp-anim-setpro .a2-p4    { animation-name: a2-p4; }

.rp-anim-setpro .a2-stage { animation-name: a2-stage; }

.rp-anim-setpro .a2-stand { animation-name: a2-stand; }

.rp-anim-setpro .a2-mic   { animation-name: a2-mic; }

.rp-anim-setpro .a2-rig   { animation-name: a2-rig; transform-box: view-box; transform-origin: 46px 82px; }

/* Public : arrivées décalées de ~0,15 s, départ commun */
@keyframes a2-p1 {
    0% { transform: translateY(65px); }
    9% { transform: translateY(-6px); }
    12% { transform: translateY(2px); }
    15%, 80% { transform: translateY(0); }
    94%, 100% { transform: translateY(65px); }
}

@keyframes a2-p2 {
    0%, 2% { transform: translateY(65px); }
    11% { transform: translateY(-6px); }
    14% { transform: translateY(2px); }
    17%, 80% { transform: translateY(0); }
    94%, 100% { transform: translateY(65px); }
}

@keyframes a2-p3 {
    0%, 4% { transform: translateY(65px); }
    13% { transform: translateY(-6px); }
    16% { transform: translateY(2px); }
    19%, 80% { transform: translateY(0); }
    94%, 100% { transform: translateY(65px); }
}

@keyframes a2-p4 {
    0%, 6% { transform: translateY(65px); }
    15% { transform: translateY(-6px); }
    18% { transform: translateY(2px); }
    21%, 80% { transform: translateY(0); }
    94%, 100% { transform: translateY(65px); }
}

/* Scène + humoriste : montent juste après le public */
@keyframes a2-stage {
    0%, 8% { transform: translateY(135px); }
    17% { transform: translateY(-6px); }
    20% { transform: translateY(2px); }
    23%, 80% { transform: translateY(0); }
    94%, 100% { transform: translateY(135px); }
}

@keyframes a2-stand {
    0%, 16%   { transform: translateY(-250px); }
    25%       { transform: translateY(3px); }
    28%       { transform: translateY(-5px); }
    31%       { transform: translateY(1px); }
    33%, 100% { transform: translateY(0); }
}

@keyframes a2-mic {
    0%, 20%   { transform: translateY(-250px); }
    29%       { transform: translateY(3px); }
    32%       { transform: translateY(-5px); }
    35%       { transform: translateY(1px); }
    37%, 100% { transform: translateY(0); }
}

/* Oscillation amortie du pied (et du micro) après l'atterrissage */
@keyframes a2-rig {
    0%, 26%   { transform: rotate(0); }
    30%       { transform: rotate(5deg); }
    35%       { transform: rotate(-4deg); }
    40%       { transform: rotate(2.5deg); }
    45%       { transform: rotate(-1.2deg); }
    50%, 100% { transform: rotate(0); }
}

/* ============================================================
   STYLE ISOMÉTRIQUE MONOCHROME (.rp-iso)
   Une seule teinte (la couleur du parcours, currentColor) déclinée
   en nuances : claire (peau, reflets), normale, foncée, très foncée,
   + ombres portées. Lumière venant d'en haut à gauche.
   ============================================================ */
.rp-iso .t-skin    { fill: color-mix(in srgb, currentColor 28%, #fff); }

.rp-iso .t-skin-d  { fill: color-mix(in srgb, currentColor 48%, #fff); }

.rp-iso .t-hi      { fill: color-mix(in srgb, currentColor 62%, #fff); }

.rp-iso .t-mid     { fill: currentColor; }

.rp-iso .t-dark    { fill: color-mix(in srgb, currentColor 62%, #000); }

.rp-iso .t-darker  { fill: color-mix(in srgb, currentColor 38%, #000); }

.rp-iso .t-shadow  { fill: #000; opacity: .3; }

.rp-iso .s-mid     { stop-color: currentColor; }

.rp-iso .s-dark    { stop-color: color-mix(in srgb, currentColor 62%, #000); }

.rp-iso .s-darker  { stop-color: color-mix(in srgb, currentColor 40%, #000); }

.rp-iso .q-stroke  { stroke: color-mix(in srgb, currentColor 62%, #fff); }

.rp-iso .k-dark    { fill: none; stroke: color-mix(in srgb, currentColor 62%, #000); stroke-linecap: round; }

.rp-iso .k-darker  { fill: none; stroke: color-mix(in srgb, currentColor 38%, #000); stroke-linecap: round; }

@media (prefers-reduced-motion: reduce) {
    .rp-anim * { animation: none !important; }
}
