/* YooPanel, entrée « Pop kiosque » (carte #509, lot 4) : page d'inscription (www), connexion et mot de passe oublié (app),
   fenêtres de validation. Maquette inscription.html : colonne encre à gauche en bureau, parcours à droite (en-tête, points
   de progression, carte d'étape, champs, choix). Charge après yp.css et yp-app.css ; la page d'inscription charge aussi
   yp-site.css (choix .s-choix). Propriétés logiques seulement, ombres retournées par --yp-sx, aucune animation en boucle. */
.yp [hidden] { display: none !important; }
dialog.yp-boite:not([open]) { display: none; }

/* ---------- Page en deux colonnes ---------- */
.e-entree { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 100svh; background: var(--creme); color: var(--encre); }
@media (min-width: 1024px) { .e-entree { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); } }

/* Colonne encre (bureau) */
.e-cote { position: relative; isolation: isolate; overflow: hidden; display: none; flex-direction: column; gap: 40px; padding: 40px; background: var(--encre); color: var(--creme); }
@media (min-width: 1024px) { .e-cote { display: flex; } }
@media (min-width: 1280px) { .e-cote { padding: 56px; } }
.e-cote__marque { display: inline-flex; align-self: flex-start; color: var(--creme); text-decoration: none; }
.e-cote__milieu { position: relative; z-index: 1; margin-block: auto; }
.e-cote__sticker { margin-bottom: 24px; font-size: 12.8px; font-weight: 700; padding: 5px 12px; }
.e-cote__titre { font: 800 48px/1.02 var(--font-titre); letter-spacing: -.025em; text-wrap: balance; }
@media (min-width: 1280px) { .e-cote__titre { font-size: 60px; } }
.e-cote__vif { color: var(--citron); }
.e-cote__liste { display: grid; gap: 16px; margin: 40px 0 0; padding: 0; list-style: none; font-size: 18px; }
.e-cote__liste li { display: flex; align-items: center; gap: 12px; }
.e-cote__coche { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--citron); color: var(--encre); }
.e-cote__anneau { position: absolute; z-index: 0; top: 33%; inset-inline-end: -112px; width: 20rem; height: 20rem; border: 28px solid rgba(229, 72, 42, .8); border-radius: 50%; pointer-events: none; }

/* Parcours */
.e-flux { display: flex; flex-direction: column; min-width: 0; min-height: 100svh; }
.e-flux__haut { display: flex; align-items: center; gap: 12px; height: 64px; padding-inline: 16px; border-bottom: 2px solid var(--ligne); }
@media (min-width: 640px) { .e-flux__haut { padding-inline: 32px; } }
@media (min-width: 1024px) { .e-flux__haut { border-bottom: 0; } .e-flux__marque { display: none !important; } }
.e-flux__marque { display: inline-flex; flex: none; color: var(--encre); text-decoration: none; }
.e-flux__langue { margin-inline-start: auto; }
.e-flux__quitter { margin-inline-end: -8px; color: var(--encre); }
.e-flux__centre { flex: 1; display: grid; place-items: center; padding: 32px 16px; }
@media (min-width: 640px) { .e-flux__centre { padding-inline: 32px; } }
.e-flux__colonne { width: 100%; max-width: 36rem; min-width: 0; }

/* Points de progression : Sujet, Rythme, Compte */
.e-points { display: flex; align-items: center; gap: 8px; margin: 0; margin-inline-start: auto; padding: 0; list-style: none; font: 700 12px/1 var(--font-texte); }
.e-points__point { display: flex; align-items: center; gap: 6px; color: var(--texte-2); }
.e-points__point[data-etat="courant"] { color: var(--encre); }
.e-points__rond { display: block; width: 14px; height: 14px; border: 2px solid var(--encre); border-radius: 50%; background: var(--papier); transition: background-color .3s, transform .3s var(--courbe-tampon); }
.e-points__point[data-etat="courant"] .e-points__rond { background: var(--tomate); transform: scale(1.25); }
.e-points__point[data-etat="fait"] .e-points__rond { background: var(--citron); }
.e-points__trait { width: 20px; height: 2px; background: var(--ligne); }
.e-points__nom { display: none; }
@media (min-width: 640px) { .e-points__nom { display: inline; } }

/* ---------- Carte d'étape ---------- */
.e-carte { padding: 24px; background: var(--papier); border: 2.5px solid var(--encre); border-radius: var(--rayon-grand); box-shadow: var(--yp-sh); }
@media (min-width: 640px) { .e-carte { padding: 32px; } }
#s-ins { view-transition-name: carte-etape; }
.e-surtitre { margin: 0; font: 700 12.8px/1 var(--font-texte); letter-spacing: .12em; text-transform: uppercase; color: var(--tomate-profonde); }
.yp .e-titre { margin-top: 4px; font: 800 30px/1.15 var(--font-titre); letter-spacing: -.025em; text-wrap: balance; }
.yp .e-titre:focus { outline: none; }
@media (min-width: 640px) { .yp .e-titre { font-size: 36px; } }
.yp .e-titre--grand { margin-top: 24px; font-size: 36px; }
@media (min-width: 640px) { .yp .e-titre--grand { font-size: 48px; } }
.e-etape__tete { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.e-etape__tete + .e-titre { margin-top: 8px; }
.e-puce { white-space: normal; text-align: start; cursor: pointer; font: inherit; font-size: 12.8px; font-weight: 700; padding: 5px 12px; }
.e-puce:hover { background: var(--citron); }
.e-groupe { min-width: 0; margin: 24px 0 0; padding: 0; border: 0; }
.yp .e-intro { margin-top: 8px; font-size: 16px; color: var(--texte-2); }
.e-retour { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; margin-top: 16px; padding: 0; font: 700 16px/1.2 var(--font-texte); color: var(--texte-2); background: none; border: 0; cursor: pointer; text-decoration: none; }
.e-retour:hover { color: var(--encre); }
.e-centre { text-align: center; }
.e-aide { font-size: 12.5px; line-height: 1.45; color: var(--texte-2); }
.yp .e-bas { margin-top: 24px; text-align: center; font-size: 14px; color: var(--texte-2); }
.e-bas__lien, .e-lien { font-weight: 700; color: var(--encre); text-decoration: underline; text-decoration-color: var(--tomate); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.e-lien { justify-self: start; display: inline-flex; align-items: center; min-height: 32px; font-size: 15px; }

/* ---------- Champs ---------- */
.e-form { display: grid; gap: 16px; margin-top: 24px; }
.e-champ { gap: 6px; }
.e-label { font: 700 15px/1.35 var(--font-texte); color: var(--encre); }
.e-cadre { position: relative; display: flex; align-items: center; }
.e-input { width: 100%; min-height: 52px; padding: 12px 16px; font: 500 16.8px/1.4 var(--font-texte); color: var(--encre); background: var(--papier); border: 2px solid var(--encre); border-radius: 14px; appearance: none; transition: box-shadow .2s, border-color .2s; }
.e-input::placeholder { color: var(--texte-3); opacity: 1; }
.e-input:focus { outline: none; box-shadow: calc(4px * var(--yp-sx)) 4px 0 var(--tomate); }
.e-input--ok { padding-inline-end: 46px; }
.e-ok { position: absolute; inset-inline-end: 14px; color: var(--citron-profond); opacity: 0; transform: scale(.4); transition: opacity .25s, transform .25s var(--courbe-tampon); pointer-events: none; }
.e-input--ok:valid:not(:placeholder-shown) + .e-ok { opacity: 1; transform: none; }
.e-input--oeil { padding-inline-end: 54px; }
.e-oeil { position: absolute; inset-inline-end: 6px; display: grid; place-items: center; width: 42px; height: 42px; color: var(--encre); background: none; border: 0; border-radius: 10px; cursor: pointer; }
.e-oeil:hover { background: rgba(30, 25, 21, .06); }
.e-oeil[aria-pressed="true"] { background: var(--citron); }
.e-oeil:focus-visible { outline: 3px solid var(--tomate); outline-offset: 1px; }
.e-select { padding-inline-end: 44px; cursor: pointer; background: var(--papier) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%231e1915' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 14px center / 18px; }
[dir="rtl"] .e-select { background-position: left 14px center; }
.yp-champ.is-erreur .e-input { border-color: var(--tomate-profonde); }
.e-form__erreur { font-weight: 700; color: var(--tomate-profonde); }

/* Solidité du mot de passe (indicative) */
.e-force { display: flex; align-items: center; gap: 8px; }
.e-force__barres { display: flex; flex: 1; gap: 4px; }
.e-force__barres i { display: block; flex: 1; height: 6px; border-radius: 99px; background: var(--ligne); transition: background-color .3s; }
.e-force[data-niveau="1"] .e-force__barres i:nth-child(-n+1) { background: var(--tomate); }
.e-force[data-niveau="2"] .e-force__barres i:nth-child(-n+2) { background: var(--peche); }
.e-force[data-niveau="3"] .e-force__barres i { background: var(--citron-profond); }
.e-force__texte { font: 700 12px/1.2 var(--font-texte); color: var(--texte-2); }

/* Case des conditions */
.e-case { display: flex; align-items: flex-start; gap: 12px; font-size: 14px; font-weight: 500; line-height: 1.45; cursor: pointer; }
.e-case input { appearance: none; flex: none; display: grid; place-content: center; width: 20px; height: 20px; margin: 1px 0 0; background: var(--papier); border: 2px solid var(--encre); border-radius: 5px; cursor: pointer; }
.e-case input:checked { background: var(--tomate); }
.e-case input:checked::after { content: ""; width: 10px; height: 6px; border: solid var(--blanc); border-width: 0 0 2.5px 2.5px; transform: translateY(-1px) rotate(-45deg); }
.e-case input:focus-visible { outline: 3px solid var(--tomate); outline-offset: 3px; }
.e-case .yp-lien { font-weight: 500; }
.yp-champ.is-erreur .e-case { color: var(--tomate-profonde); }
.yp-champ.is-erreur .e-case input { border-color: var(--tomate-profonde); }

.e-envoyer { min-height: 56px; margin-top: 4px; font-size: 20px; }
.e-envoyer[aria-busy="true"] { opacity: .9; }
.e-rassure { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 16px; margin: 0; font: 700 12px/1.3 var(--font-texte); color: var(--texte-2); }
.e-rassure span { display: inline-flex; align-items: center; gap: 4px; }

/* ---------- Bienvenue, lien envoyé ---------- */
.e-bienvenue { text-align: center; }
.e-badge { display: grid; place-items: center; width: 80px; height: 80px; margin-inline: auto; color: var(--encre); background: var(--citron); border: 2.5px solid var(--encre); border-radius: 24px; box-shadow: var(--yp-sh); transform: rotate(calc(-6deg * var(--yp-sx))); }
.e-badge--petit { width: 56px; height: 56px; margin: 4px 0 0; border-radius: 18px; }
.e-badge--peche { background: var(--peche); }
.e-bienvenue .e-titre { margin-top: 24px; }
.yp .e-bienvenue__texte { margin-top: 12px; font-size: 18px; color: var(--texte-2); text-wrap: pretty; }
.e-bienvenue__email { color: var(--encre); overflow-wrap: anywhere; }
.e-suite { display: grid; gap: 8px; margin: 28px 0 0; padding: 0; list-style: none; text-align: start; }
.e-suite__etape { display: flex; align-items: center; gap: 12px; padding: 12px; font-weight: 700; border: 2px solid var(--encre); border-radius: 16px; }
.e-suite__etape--fait { background: var(--citron); }
.e-suite__etape--courant { background: var(--peche); }
.e-suite__etape--ensuite { color: var(--texte-2); border-style: dashed; border-color: rgba(30, 25, 21, .4); }
.e-suite__num { display: inline-grid; place-items: center; flex: none; width: 32px; height: 32px; font-weight: 800; border: 2px solid currentColor; border-radius: 50%; }
.e-suite__tag { margin-inline-start: auto; font-size: 11px; }
.e-bienvenue .e-envoyer { margin-top: 28px; }
.yp .e-bienvenue .e-aide { margin-top: 16px; font-size: 14px; }
.e-bienvenue .e-retour { margin-top: 20px; }

/* Confettis de l'inscription réussie : un seul passage, coupés sous mouvement réduit (js/yp-site.js) */
.e-confettis { position: fixed; inset: 0; z-index: 80; overflow: hidden; pointer-events: none; }
.e-confetti { position: absolute; top: -20px; width: 10px; height: 16px; border: 1.5px solid var(--encre); animation: e-confetti var(--d, 2s) cubic-bezier(.25, .6, .4, 1) 1 forwards; }
@keyframes e-confetti { to { transform: translate(var(--x, 0), 110vh) rotate(var(--rot, 360deg)); } }

/* ---------- Fenêtres (composant dialog.modal de la maquette) ---------- */
dialog.e-modale { width: min(32rem, calc(100% - 32px)); max-width: none; max-height: calc(100dvh - 32px); margin: auto; padding: 0; overflow: auto; color: var(--encre); background: transparent; border: 0; }
dialog.e-modale:not([open]) { display: none; }
dialog.e-modale::backdrop { background: rgba(30, 25, 21, .45); }
.e-modale__carte { display: grid; gap: 16px; padding: 24px; background: var(--papier); border: 2.5px solid var(--encre); border-radius: var(--rayon-grand); box-shadow: var(--yp-sh); }
.e-modale__tete { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.e-modale__tete .yp-btn-icone { margin-block: -6px; margin-inline-end: -10px; }
.yp .e-modale__titre, .e-modale__titre { margin: 0; font: 800 24px/1.2 var(--font-titre); letter-spacing: -.02em; }
.e-modale__texte { margin: 0; color: var(--texte-2); }
@media (prefers-reduced-motion: no-preference) {
  dialog.e-modale[open] .e-modale__carte { animation: e-pop .3s var(--courbe-tampon) 1 both; }
}
@keyframes e-pop { from { opacity: 0; transform: translateY(14px) scale(.96); } to { opacity: 1; transform: none; } }

/* ---------- Nouveau mot de passe (box/password.twig, chantier P2) : classes gardées ---------- */
.e-boite { inline-size: min(480px, calc(100vw - 32px)); max-block-size: calc(100dvh - 32px); overflow: auto; padding: 0; border: 0; background: transparent; }
.e-boite[open] { display: block; }
.e-boite__corps { display: grid; gap: 12px; padding: 22px; background: var(--surface); color: var(--texte); border: var(--yp-b) solid var(--bordure); border-radius: var(--rayon-grand); box-shadow: var(--yp-sh); }
.e-boite__corps .yp-tampon { justify-self: start; margin-block: 6px; }
.e-boite__titre { margin: 0; font: 400 22px/1.2 var(--font-titre); }
.e-boite__corps p { margin: 0; }
.e-boite .yp-etat { padding: 20px 16px; }
.e-champ-mdp .s-bascule { position: absolute; inset-inline-end: 4px; min-block-size: 40px; min-inline-size: 44px; padding: 0 10px; font: 700 14px/1 var(--font-texte); color: var(--texte); background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.e-champ-mdp .yp-input { padding-inline-end: 96px; }

/* ---------- Droite à gauche et écritures liées ---------- */
[dir="rtl"] .e-entree svg.yp-fleche, [dir="rtl"] .e-modale svg.yp-fleche, [dir="rtl"] .e-retour svg { scale: -1 1; }
[lang="ar"] .e-cote__titre, [lang="fa"] .e-cote__titre, [lang="ur"] .e-cote__titre { font-family: var(--font-arabe); line-height: 1.35; letter-spacing: 0; }
[lang="he"] .e-cote__titre { font-family: var(--font-hebreu); line-height: 1.2; letter-spacing: 0; }
[lang="ar"] .e-surtitre, [lang="fa"] .e-surtitre, [lang="ur"] .e-surtitre, [lang="he"] .e-surtitre { letter-spacing: 0; }

/* ---------- Mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
  .e-points__rond, .e-ok, .e-force__barres i { transition: none; }
  .e-confettis { display: none; }
}
