/* Renai : mise en page. AUCUNE couleur ici : uniquement les variables de tokens.css. */

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

html, body {
  margin: 0;
  height: 100%;
  background: var(--renee-lait);
  color: var(--renee-encre);
  font-family: var(--font-text);
  font-size: var(--text-body);
  -webkit-text-size-adjust: 100%;
}

[hidden] { display: none !important; }

/* L'appli : une vue (la conversation ou un onglet) au-dessus de la barre d'onglets, qui reste en bas. */
#app {
  max-width: 480px;
  margin: 0 auto;
  height: 100dvh;
  display: flex;
  flex-direction: column;
}
#app > .erreur { padding: var(--space-4); }

.vues { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.vue {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-4) var(--space-6);
  overflow-y: auto;
  overflow-x: hidden;
}
.vue--conversation { overflow: hidden; padding-bottom: var(--space-4); }

/* --- La barre d'onglets, en bas ----------------------------------------- */
.onglets {
  display: flex;
  border-top: var(--border-soft);
  background: var(--renee-lait);
  padding-bottom: env(safe-area-inset-bottom);
}
.onglet {
  flex: 1;
  min-height: 56px;
  font: inherit;
  font-weight: 600;
  font-size: var(--text-body-l);
  color: var(--renee-ardoise);
  background: transparent;
  border: none;
  border-top: 3px solid transparent;
  cursor: pointer;
}
.onglet--actif { color: var(--renee-cobalt); border-top-color: var(--renee-cobalt); font-weight: 800; }
button:focus-visible, select:focus-visible, .zone:focus-visible { outline: none; box-shadow: var(--focus-ring); }

/* --- Titres ------------------------------------------------------------- */
.titre {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--text-h2);
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin: 0;
}

/* --- En-tête de conversation ------------------------------------------ */
.entete { display: flex; align-items: center; gap: var(--space-3); }
.entete__nom { font-weight: 700; font-size: var(--text-body); }
.entete__etat { font-size: var(--text-small); color: var(--renee-ardoise); }

/* --- Le fil ------------------------------------------------------------- */
.fil {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  overflow-y: auto;
}

.bulle {
  max-width: 86%;
  padding: 11px 14px;
  line-height: 1.3;
  white-space: pre-line;
}
.bulle--renaide {
  align-self: flex-start;
  background: var(--renee-sable);
  border-radius: var(--radius-l) var(--radius-l) var(--radius-l) 6px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
}
.bulle--aidant {
  align-self: flex-end;
  max-width: 80%;
  background: var(--renee-bonbon);
  border-radius: var(--radius-l) var(--radius-l) 6px var(--radius-l);
  font-size: var(--text-body);
}
.bulle--aidant img {
  display: block;
  max-width: 100%;
  border-radius: var(--radius-m);
}

/* L'encadré « C'est réglé. » : ce que l'application a réellement fait, une ligne cochée par geste. Pas une bulle. */
.regle {
  align-self: flex-start;
  max-width: 92%;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  background: var(--renee-beurre);
  color: var(--renee-encre);
  border-radius: var(--radius-l);
}
.regle__titre { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-body-l); }
.regle__ligne { display: flex; align-items: flex-start; gap: var(--space-2); line-height: 1.35; }
.regle__coche { flex: none; display: flex; margin-top: 1px; }
.regle__texte { min-width: 0; }

.puces { align-self: flex-start; display: flex; gap: var(--space-2); flex-wrap: wrap; }

/* --- Boutons ------------------------------------------------------------ */
.pill {
  font: inherit;
  font-weight: 600;
  font-size: var(--text-small);
  padding: 9px 14px;
  border-radius: var(--radius-pill);
  border: var(--border-strong);
  background: transparent;
  color: var(--renee-encre);
  cursor: pointer;
  min-height: 44px;
}
.pill:focus-visible, .bouton:focus-visible, .champ:focus-visible { outline: none; box-shadow: var(--focus-ring); }

.bouton {
  font: inherit;
  font-weight: 600;
  font-size: var(--text-body);
  height: var(--control-h-mobile);
  padding: 0 26px;
  border-radius: var(--radius-pill);
  border: none;
  background: var(--renee-encre);
  color: var(--renee-lait);
  cursor: pointer;
  width: 100%;
}
.bouton--cobalt { background: var(--renee-cobalt); }
.bouton--contour { background: transparent; color: var(--renee-encre); border: var(--border-strong); }

/* --- Barre « Racontez-moi » ------------------------------------------- */
.barre {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 6px 6px 6px var(--space-4);
  border-radius: var(--radius-pill);
  border: var(--border-strong);
}
.barre__champ {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  font: inherit;
  font-size: var(--text-body);
  color: var(--renee-encre);
  outline: none;
}
.barre__champ::placeholder { color: var(--renee-ardoise); }
.disque {
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 50%;
  border: none;
  background: var(--renee-cobalt);
  color: var(--renee-lait);
  font-weight: 700;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* --- Écran du code d'accès -------------------------------------------- */
.acces { margin: auto 0; padding: var(--space-4); display: flex; flex-direction: column; gap: var(--space-4); align-items: flex-start; }
.champ {
  width: 100%;
  height: var(--control-h-mobile);
  padding: 0 var(--space-4);
  border-radius: var(--radius-pill);
  border: var(--border-strong);
  background: transparent;
  font: inherit;
  color: var(--renee-encre);
}
.erreur { color: var(--renee-brique); font-size: var(--text-small); min-height: 1.2em; margin: 0; }

.cache { display: none; }

/* --- Cartes dans le fil : la fiche lue, les démarches ------------------ */
.carte {
  align-self: stretch;
  border: var(--border-soft);
  border-radius: var(--radius-l);
  background: var(--renee-lait);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.carte__corps { border: none; margin: 0; padding: 0; min-width: 0; display: flex; flex-direction: column; gap: var(--space-3); }
.carte__titre { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-h3); letter-spacing: -0.02em; }
.carte__quand { font-size: var(--text-small); color: var(--renee-ardoise); margin-top: calc(-1 * var(--space-2)); }
.carte--demarche { background: var(--renee-sable); }
.carte--faite { opacity: .6; }
.carte--faite .bouton { display: none; }

.grille { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2) var(--space-3); align-items: end; }
.saisie--large { grid-column: 1 / -1; }
.saisie--manque .saisie__nom { color: var(--renee-brique); }
.saisie--manque .saisie__champ { border-bottom-color: var(--renee-brique); }

/* La fiche à lire : du texte, puis deux boutons */
.fiche__texte { display: flex; flex-direction: column; gap: var(--space-2); }
.fiche__texte[hidden], .fiche__cases[hidden] { display: none; }
.fiche__ligne { margin: 0; line-height: 1.45; }
.fiche__important { font-weight: 700; }
.fiche__trait { width: 100%; margin: var(--space-1) 0; border: 0; border-top: var(--border-soft); }
.fiche__cases { display: flex; flex-direction: column; gap: var(--space-3); }
.fiche__boutons { display: flex; flex-direction: column; gap: var(--space-2); }
.fiche__boutons .bouton[hidden] { display: none; }
.grille--3 { grid-template-columns: 1fr 1fr 1fr; }
.saisie { display: flex; flex-direction: column; gap: var(--space-1); min-width: 0; }
.saisie__nom { font-size: var(--text-label); font-weight: 600; color: var(--renee-ardoise); }
.saisie__champ {
  font: inherit;
  font-size: var(--text-body);
  color: var(--renee-encre);
  background: transparent;
  border: none;
  border-bottom: 1.5px solid var(--renee-ligne);
  padding: var(--space-1) 0;
  min-width: 0;
  width: 100%;
}
.saisie__champ:focus { outline: none; border-bottom-color: var(--renee-cobalt); }
.saisie[hidden] { display: none; }
select.saisie__champ { border-radius: 0; }
.moments { display: flex; gap: var(--space-2); flex-wrap: wrap; }

.medicament { border-top: var(--border-soft); padding-top: var(--space-3); display: flex; flex-direction: column; gap: var(--space-2); }
.medicament__nom { font-weight: 700; }
.medicament__poso { font-size: var(--text-small); color: var(--renee-ardoise); }

.pill--plein { background: var(--renee-cobalt); border-color: var(--renee-cobalt); color: var(--renee-lait); }
.pill:disabled { opacity: .5; cursor: default; }

/* --- Commandes de démo : discrètes, au-dessus de la barre -------------- */
.demo { display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-2); font-size: var(--text-label); color: var(--renee-ardoise); }
.demo__commandes { display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; }
.pill--petit { font-size: var(--text-label); padding: 5px 10px; border: var(--border-soft); color: var(--renee-ardoise); min-height: 0; }
.pill--grand { font-size: var(--text-body); min-height: 48px; padding: 0 20px; }
.puces--larges { gap: var(--space-3); }

/* --- Une ligne d'aide sous une case de la fiche ------------------------ */
.aide { margin: 0; font-size: var(--text-small); line-height: 1.3; color: var(--renee-ardoise); font-weight: 400; }

/* --- Le mail modifiable : l'objet et le texte se changent à la main ------- */
.zone {
  width: 100%;
  font: inherit;
  font-size: var(--text-body);   /* 16 px au moins : le téléphone ne zoome pas dans le champ */
  color: var(--renee-encre);
  background: var(--renee-lait);
  border: 1.5px solid var(--renee-ligne);
  border-radius: var(--radius-m);
  padding: var(--space-3);
  min-height: 48px;
}
.zone:focus { border-color: var(--renee-cobalt); }
.zone--objet { display: block; resize: none; overflow: hidden; line-height: 1.3; }
.zone--texte { display: block; resize: none; overflow: hidden; line-height: 1.4; min-height: 140px; }
.carte__avis {
  margin: 0;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-m);
  background: var(--renee-beurre);
  color: var(--renee-encre);
  font-size: var(--text-small);
  font-weight: 600;
  line-height: 1.3;
}
.carte__dest { margin: 0; font-size: var(--text-small); font-weight: 600; line-height: 1.3; color: var(--renee-encre); overflow-wrap: anywhere; }
.carte__dest--manque { color: var(--renee-brique); }
.adresses__titre { font-size: var(--text-h3); }
.adresses__retour:empty { display: none; }
.carte__garde { margin: 0; min-height: 1.2em; font-size: var(--text-small); color: var(--renee-ardoise); }
.carte--faite .zone { background: transparent; }

/* --- L'onglet Médicaments : la personne, les rubriques ----------------------- */
.proche { display: flex; flex-direction: column; gap: var(--space-3); }
.proche__rang { display: flex; align-items: center; gap: var(--space-2); }
.proche__nom {
  flex: 1;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--text-h3);
  letter-spacing: -0.02em;
  min-height: 48px;
  display: flex;
  align-items: center;
}
.proche__choix {
  flex: 1;
  min-width: 0;
  min-height: 48px;
  font: inherit;
  font-weight: 700;
  font-size: var(--text-body-l);
  color: var(--renee-encre);
  background: var(--renee-lait);
  border: var(--border-strong);
  border-radius: var(--radius-pill);
  padding: 0 var(--space-4);
}
.crayon {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: var(--border-soft);
  background: transparent;
  color: var(--renee-encre);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.panneau {
  border: var(--border-soft);
  border-radius: var(--radius-l);
  background: var(--renee-sable);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.panneau .saisie__champ { min-height: 44px; font-size: var(--text-body-l); }

/* La rangée de rubriques défile de côté (jamais la page) */
.sous-onglets {
  display: flex;
  gap: var(--space-2);
  overflow-x: auto;
  margin: 0 calc(-1 * var(--space-4));
  padding: 2px var(--space-4) var(--space-1);
  scrollbar-width: none;
  flex: none;
}
.sous-onglets::-webkit-scrollbar { display: none; }
.sous-onglet {
  flex: none;
  min-height: 44px;
  padding: 0 var(--space-4);
  font: inherit;
  font-weight: 600;
  color: var(--renee-encre);
  background: transparent;
  border: var(--border-soft);
  border-radius: var(--radius-pill);
  cursor: pointer;
}
.sous-onglet--actif { background: var(--renee-cobalt); border-color: var(--renee-cobalt); color: var(--renee-lait); }

.corps { display: flex; flex-direction: column; gap: var(--space-3); min-width: 0; }
.corps > .erreur:empty { display: none; }
.avis { background: var(--renee-sable); border-radius: var(--radius-m); padding: var(--space-3); flex: none; }
.avis__texte { margin: 0; font-weight: 600; line-height: 1.3; }
.avis__texte + .avis__texte { margin-top: var(--space-2); }
.vide { margin: 0; padding: var(--space-2) 0; color: var(--renee-ardoise); line-height: 1.4; }
.erreur--page { padding: var(--space-4); }
.section { display: flex; flex-direction: column; gap: var(--space-3); }
.section__titre { margin: var(--space-2) 0 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-h3); letter-spacing: -0.02em; }

/* --- Le pilulier ------------------------------------------------------------ */
.jour {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  border: var(--border-soft);
  border-radius: var(--radius-l);
  padding: var(--space-1);
}
.jour__fleche {
  flex: none;
  width: 52px;
  height: 52px;
  font: inherit;
  font-size: 30px;
  line-height: 1;
  color: var(--renee-encre);
  background: transparent;
  border: none;
  border-radius: var(--radius-m);
  cursor: pointer;
}
.jour__titre { flex: 1; text-align: center; font-family: var(--font-display); font-weight: 800; font-size: var(--text-body-l); }
.jour__retour { align-self: center; }

.creneau {
  --accent: var(--renee-ligne);
  --accent-texte: var(--renee-encre);
  border: 2px solid var(--accent);
  border-radius: var(--radius-l);
  background: var(--renee-lait);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.creneau--matin { --accent: var(--renee-beurre); }
.creneau--soir { --accent: var(--renee-bonbon); }
.creneau--nuit { --accent: var(--renee-cobalt); --accent-texte: var(--renee-lait); }
.creneau--en_cours { box-shadow: 0 0 0 3px var(--accent); }
.creneau__tete { display: flex; align-items: center; gap: var(--space-3); }
.creneau__nom {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--text-h3);
  background: var(--accent);
  color: var(--accent-texte);
  border-radius: var(--radius-pill);
  padding: var(--space-1) var(--space-3);
}
.creneau__heure { color: var(--renee-ardoise); }
.creneau__etat { margin-left: auto; font-size: var(--text-small); color: var(--renee-ardoise); }
.creneau__vide { margin: 0; color: var(--renee-ardoise); }
.creneau__tout { align-self: flex-start; margin-top: var(--space-1); }

.ligne {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 52px;
  padding: var(--space-2) 0;
  width: 100%;
  font: inherit;
  text-align: left;
  color: var(--renee-encre);
  background: transparent;
  border: none;
  border-top: var(--border-soft);
}
.ligne--case { cursor: pointer; }
.ligne:disabled { opacity: .6; cursor: default; }
.ligne__texte { display: flex; flex-direction: column; min-width: 0; }
.ligne__nom { font-weight: 700; }
.ligne__poso { font-size: var(--text-small); color: var(--renee-ardoise); }
.case {
  flex: none;
  width: 32px;
  height: 32px;
  border: 2px solid var(--renee-encre);
  border-radius: var(--radius-s);
  background: var(--renee-lait);
  color: var(--renee-lait);
  display: flex;
  align-items: center;
  justify-content: center;
}
.ligne--prise .case { background: var(--renee-cobalt); border-color: var(--renee-cobalt); }

/* --- Le pilulier de la semaine : la grille, le compteur, la dernière prise ---------- */
.semaine { display: flex; flex-direction: column; gap: var(--space-3); }
.semaine__entete {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  border: var(--border-soft);
  border-radius: var(--radius-l);
  padding: var(--space-1);
}
.semaine__titres { flex: 1; min-width: 0; text-align: center; }
.semaine__titre { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-body-l); line-height: 1.2; }
.semaine__sous-titre { margin: 0; font-size: var(--text-small); color: var(--renee-ardoise); }
.grille-semaine {
  display: grid;
  grid-template-columns: 58px repeat(7, minmax(0, 1fr));
  gap: var(--space-1);
  align-items: center;
}
.grille-semaine__creneau { font-size: var(--text-label); font-weight: 600; color: var(--renee-ardoise); }
.grille-semaine__jour {
  font: inherit;
  font-weight: 700;
  min-height: 36px;
  padding: 0;
  color: var(--renee-encre);
  background: transparent;
  border: 2px solid transparent;
  border-radius: var(--radius-pill);
  cursor: pointer;
}
.grille-semaine__jour--aujourdhui { background: var(--renee-encre); color: var(--renee-lait); }
.grille-semaine__jour--choisi { border-color: var(--renee-cobalt); }
.case-semaine {
  min-height: 44px;
  padding: 0;
  color: var(--renee-encre);
  border: var(--border-soft);
  border-radius: var(--radius-s);
  background: var(--renee-lait);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.case-semaine--tout { background: var(--renee-beurre); border-color: var(--renee-beurre); }
.case-semaine--partiel { background: linear-gradient(to top, var(--renee-beurre) 50%, var(--renee-lait) 50%); border-color: var(--renee-beurre); }
.case-semaine--a_venir { background: var(--renee-sable); border-color: var(--renee-sable); }
.case-semaine--avant { background: transparent; border: 1px dashed var(--renee-ligne); cursor: default; }   /* avant la validation de l'ordonnance : grisée, ne compte pas */
.case-semaine--choisie { outline: 2px solid var(--renee-cobalt); outline-offset: 1px; }
.semaine__compteur { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-body-l); }
.derniere-prise { display: flex; flex-direction: column; gap: var(--space-1); padding: var(--space-3) var(--space-4); background: var(--renee-sable); border-radius: var(--radius-l); }
.derniere-prise__titre { margin: 0; font-weight: 700; }
.derniere-prise__texte { margin: 0; color: var(--renee-ardoise); line-height: 1.35; }
.detail-jour { display: flex; flex-direction: column; gap: var(--space-3); margin-top: var(--space-4); }
.detail-jour__titre { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-body-l); text-align: center; }

/* --- Traitements, ordonnances, démarches, journal ---------------------------- */
.carte--simple { gap: var(--space-2); background: var(--renee-lait); }
.carte__nom { font-weight: 700; font-size: var(--text-body-l); }
.carte__detail { font-size: var(--text-small); color: var(--renee-ardoise); line-height: 1.3; }
.carte__note { line-height: 1.4; white-space: pre-line; }
.chips { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.chip { background: var(--renee-sable); border-radius: var(--radius-pill); padding: var(--space-1) var(--space-3); font-size: var(--text-small); }
.ordonnance__haut { display: flex; align-items: flex-start; gap: var(--space-3); }
.ordonnance__texte { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--space-1); }
.miniature {
  flex: none;
  width: 64px;
  height: 80px;
  padding: 0;
  border: var(--border-soft);
  border-radius: var(--radius-m);
  overflow: hidden;
  background: var(--renee-sable);
  cursor: zoom-in;
}
.miniature img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* La photo agrandie : au toucher elle grossit encore, et se fait défiler */
.visionneuse {
  position: fixed;
  inset: 0;
  z-index: 10;
  background: var(--renee-encre);
  overflow: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-4);
  padding: var(--space-4);
}
.visionneuse__fermer { order: -1; position: sticky; top: 0; left: 0; z-index: 1; flex: none; }
.visionneuse__image { width: 100%; height: auto; flex: none; border-radius: var(--radius-m); cursor: zoom-in; }
.visionneuse__image--grande { width: 220%; max-width: none; cursor: zoom-out; }

/* --- L'accueil : le personnage, un bonjour, une question --------------------- */
.accueil { display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-2); padding: var(--space-2) 0 var(--space-3); }
.accueil__bonjour { font-size: var(--text-h2); }
.accueil__question { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: var(--text-h3); letter-spacing: -0.01em; line-height: 1.15; }

/* --- « Parler à Renée » : le grand bouton, toujours là, et l'enregistrement -- */
.vocal { display: flex; flex-direction: column; gap: var(--space-3); flex: none; }
.bouton-parler {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  width: 100%;
  min-height: 60px;
  padding: 0 var(--space-6);
  font: inherit;
  font-weight: 700;
  font-size: var(--text-body-l);
  color: var(--renee-lait);
  background: var(--renee-encre);
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
}
.bouton-parler:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.bouton-parler:disabled { opacity: .5; cursor: default; }
.bouton-parler__icone { flex: none; }
.vocal__panneau {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border: var(--border-soft);
  border-radius: var(--radius-l);
  background: var(--renee-sable);
}
.onde { flex: 1; min-width: 0; height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 3px; }
.onde__barre { flex: 1; max-width: 6px; height: 10%; min-height: 4px; border-radius: var(--radius-pill); background: var(--renee-cobalt); }
.vocal__duree { flex: none; min-width: 3.2em; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }

/* --- L'accueil : le parcours du premier lancement ------------------------------------------------------------ */
.parcours { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: var(--space-4) var(--space-4) var(--space-4); }
.parcours__haut { flex: none; min-height: 44px; display: flex; align-items: center; justify-content: center; position: relative; }
.parcours__marque { font-family: var(--font-display); font-weight: 800; font-size: var(--text-h3); letter-spacing: -0.04em; text-transform: lowercase; }
.parcours__retour {
  position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  display: flex; align-items: center; gap: var(--space-1);
  min-height: 44px; padding: 0 var(--space-3) 0 var(--space-1);
  font: inherit; font-weight: 600; font-size: var(--text-body); color: var(--renee-ardoise);
  background: transparent; border: none; border-radius: var(--radius-pill); cursor: pointer;
}
.parcours__retour:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.parcours__corps {
  flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden;
  display: flex; flex-direction: column; gap: var(--space-4); padding: var(--space-4) 0;
  animation: parcours-entree .35s ease both;
}
.parcours__entete { display: flex; flex-direction: column; gap: var(--space-2); text-align: center; align-items: center; }
.parcours__titre { font-size: var(--text-h2); outline: none; }
.parcours__titre--grand { text-align: center; }
.parcours__ligne { display: block; }
.parcours__ligne--cobalt { color: var(--renee-cobalt); }
.parcours__aide { margin: 0; font-size: var(--text-body-l); line-height: 1.35; color: var(--renee-ardoise); text-align: center; }
.parcours__question { margin: var(--space-2) 0 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-h3); letter-spacing: -0.02em; line-height: 1.15; text-align: center; }
.parcours__champs, .parcours__lien { display: flex; flex-direction: column; gap: var(--space-3); }
.parcours__pied { flex: none; display: flex; flex-direction: column; gap: var(--space-3); padding-bottom: env(safe-area-inset-bottom); }
.parcours__erreur { text-align: center; font-size: var(--text-body); }
.parcours__erreur:empty { display: none; }
.parcours__points { display: flex; justify-content: center; gap: var(--space-2); }
.parcours__point { width: 8px; height: 8px; border-radius: var(--radius-pill); background: var(--renee-ligne); transition: width .2s ease; }
.parcours__point--actif { width: 22px; background: var(--renee-cobalt); }
.parcours .bouton { height: 56px; font-size: var(--text-body-l); }
.parcours .bouton:disabled { opacity: .6; cursor: default; }
.parcours .saisie__nom { font-size: var(--text-small); }
.saisie--parcours .saisie__champ { font-size: var(--text-h3); min-height: 52px; }
.parcours__bientot { text-align: center; font-size: var(--text-body); }

@keyframes parcours-entree { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Le premier écran : Renée au milieu, des post-it qui apparaissent l'un après l'autre autour d'elle */
.scene { position: relative; flex: none; height: 270px; margin-top: var(--space-2); }
.scene__renee { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.post-it {
  position: absolute; max-width: 46%; padding: var(--space-2) var(--space-3); text-wrap: balance;
  font-weight: 600; font-size: var(--text-small); line-height: 1.2; color: var(--renee-encre);
  border-radius: var(--radius-s); transform: rotate(var(--inclinaison, 0deg));
  animation: post-it-entree .5s ease both; animation-delay: calc(var(--rang, 0) * 450ms + 250ms);
}
.post-it--1 { --inclinaison: -8deg; left: 0; top: 14%; background: var(--renee-beurre); }
.post-it--2 { --inclinaison: 6deg; right: 0; top: 4%; background: var(--renee-bonbon); }
.post-it--3 { --inclinaison: -4deg; left: 2%; bottom: 6%; background: var(--renee-ciel); }
.post-it--4 { --inclinaison: 7deg; right: 2%; bottom: 12%; background: var(--renee-beurre); }
@keyframes post-it-entree { from { opacity: 0; transform: translateY(10px) scale(.9) rotate(var(--inclinaison, 0deg)); } to { opacity: 1; transform: rotate(var(--inclinaison, 0deg)); } }

/* Les choix : une ligne à toucher, en cobalt quand elle est choisie */
.choix-liste { display: flex; flex-direction: column; gap: var(--space-3); }
.choix {
  display: flex; align-items: center; gap: var(--space-3); width: 100%; min-height: 64px; padding: 0 var(--space-4);
  font: inherit; font-weight: 600; font-size: var(--text-body-l); text-align: left;
  color: var(--renee-encre); background: var(--renee-sable); border: none; border-radius: var(--radius-m); cursor: pointer;
}
.choix:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.choix--choisi { background: var(--renee-cobalt); color: var(--renee-lait); }
.choix__texte { flex: 1; min-width: 0; }
.choix__pastille, .choix__icone {
  flex: none; width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: var(--text-body); font-weight: 700; color: var(--renee-encre); background: var(--renee-ligne);
}
.choix-liste--pastilles .choix:nth-child(1) .choix__pastille { background: var(--renee-bonbon); }
.choix-liste--pastilles .choix:nth-child(2) .choix__pastille { background: var(--renee-beurre); }
.choix__icone { background: var(--renee-lait); color: var(--renee-cobalt); }

/* « Voici Renée » : des cartes qui défilent au doigt, une humeur et une couleur chacune */
.cartes {
  position: relative; display: flex; gap: var(--space-3); padding: var(--space-2) 19%;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.cartes::-webkit-scrollbar { display: none; }
.cartes:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: var(--radius-l); }
.carte-renee {
  flex: none; width: 100%; min-height: 280px; scroll-snap-align: center;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-3);
  padding: var(--space-6) var(--space-4); border-radius: var(--radius-l); text-align: center;
}
.carte-renee--ecoute { background: var(--renee-bonbon); }
.carte-renee--prepare { background: var(--renee-ciel); }
.carte-renee--regle { background: var(--renee-beurre); }
.carte-renee__etiquette {
  padding: 3px 10px; border-radius: var(--radius-pill); background: var(--renee-lait);
  font-size: var(--text-label); font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
}
.carte-renee__texte { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: var(--text-h3); line-height: 1.2; letter-spacing: -0.01em; }
.cartes__points { display: flex; justify-content: center; gap: var(--space-2); }
.cartes__point { width: 8px; height: 8px; border-radius: var(--radius-pill); background: var(--renee-ligne); }
.cartes__point--actif { background: var(--renee-cobalt); }

/* La famille */
.famille { display: flex; flex-direction: column; gap: var(--space-3); }
.famille__ligne { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-3) var(--space-4); background: var(--renee-sable); border-radius: var(--radius-m); }
.famille__pastille {
  flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--renee-bonbon);
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: var(--text-body-l);
}
.famille__texte { flex: 1; min-width: 0; }
.famille__nom { font-weight: 700; font-size: var(--text-body-l); }
.famille__lien { font-size: var(--text-small); color: var(--renee-ardoise); }
.famille__champs { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--space-2); }
.saisie__champ--famille {
  width: 100%; min-height: 44px; font: inherit; font-size: var(--text-body-l); color: var(--renee-encre);
  background: transparent; border: none; border-bottom: var(--border-soft); border-radius: 0; padding: 0;
}
.saisie__champ--famille:focus { outline: none; border-bottom-color: var(--renee-cobalt); }
.famille__retirer {
  flex: none; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  color: var(--renee-ardoise); background: transparent; border: none; border-radius: 50%; cursor: pointer;
}
.famille__retirer:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.famille__ajouter {
  min-height: 56px; font: inherit; font-weight: 600; font-size: var(--text-body-l); color: var(--renee-cobalt);
  background: transparent; border: 1.5px dashed var(--renee-ligne); border-radius: var(--radius-m); cursor: pointer;
}
.famille__ajouter:focus-visible { outline: none; box-shadow: var(--focus-ring); }

/* Le résumé du soir : la grande horloge et ses deux interrupteurs */
.horloge {
  align-self: center; position: relative; width: 240px; height: 240px; padding: 0;
  font: inherit; color: var(--renee-encre); background: transparent; border: none; border-radius: 50%; cursor: pointer;
}
.horloge:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.horloge__dessin { width: 100%; height: 100%; display: block; }
.horloge__piste { stroke: var(--renee-ciel); }
.horloge__arc { stroke: var(--renee-cobalt); transition: stroke-dasharray .25s ease; }
.horloge__repere { stroke: var(--renee-ardoise); stroke-width: 2; stroke-linecap: round; }
.horloge__centre { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-1); }
.horloge__heure { font-family: var(--font-display); font-weight: 800; font-size: 52px; letter-spacing: -0.04em; line-height: 1; }
.horloge__legende { font-size: var(--text-small); color: var(--renee-ardoise); }
.parcours__toucher { text-align: center; }
.selecteur { display: flex; flex-direction: column; align-items: center; gap: var(--space-4); padding: var(--space-4); background: var(--renee-sable); border-radius: var(--radius-l); }
.selecteur__colonnes { display: flex; gap: var(--space-8); }
.selecteur__colonne { display: flex; flex-direction: column; align-items: center; gap: var(--space-2); }
.selecteur__nom { font-size: var(--text-small); font-weight: 600; color: var(--renee-ardoise); }
.selecteur__valeur { font-family: var(--font-display); font-weight: 800; font-size: var(--text-h2); line-height: 1; }
.selecteur__bouton {
  width: 56px; height: 56px; display: flex; align-items: center; justify-content: center;
  color: var(--renee-lait); background: var(--renee-cobalt); border: none; border-radius: 50%; cursor: pointer;
}
.selecteur__bouton:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.interrupteurs { display: flex; flex-direction: column; gap: var(--space-3); }
.interrupteur { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding: var(--space-3) var(--space-4); background: var(--renee-sable); border-radius: var(--radius-m); }
.interrupteur__texte { font-weight: 600; font-size: var(--text-body-l); line-height: 1.25; }
.interrupteur__bouton {
  flex: none; position: relative; width: 56px; height: 32px; padding: 0;
  background: var(--renee-ligne); border: none; border-radius: var(--radius-pill); cursor: pointer; transition: background .2s ease;
}
.interrupteur__bouton:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.interrupteur__bouton--actif { background: var(--renee-cobalt); }
.interrupteur__poignee { position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: var(--renee-lait); transition: transform .2s ease; }
.interrupteur__bouton--actif .interrupteur__poignee { transform: translateX(24px); }

/* « Tout est prêt » : l'encadré jaune avec Renée */
.carte-prete {
  align-self: center; width: 100%; display: flex; flex-direction: column; align-items: center; gap: var(--space-3);
  padding: var(--space-8) var(--space-4); background: var(--renee-beurre); border-radius: var(--radius-l); text-align: center;
}
.carte-prete__titre { margin: 0; font-family: var(--font-display); font-weight: 800; font-size: var(--text-h2); letter-spacing: -0.03em; }
.carte-prete__texte { margin: 0; font-size: var(--text-body-l); line-height: 1.35; }

@media (prefers-reduced-motion: reduce) {
  .parcours__corps, .post-it { animation: none; }
  .parcours__point, .horloge__arc, .interrupteur__bouton, .interrupteur__poignee { transition: none; }
}

/* --- Installer l'application et recevoir les rappels (static/rappels.js) ----- */
.installer { display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-2); }
.installer__titre { margin: 0; font-weight: 600; font-size: var(--text-body); }
.installer__bouton { align-self: flex-start; }
.demo__commandes .installer { flex-basis: 100%; }
.installer--avant { align-self: stretch; }
.installer--avant .installer__bouton { align-self: stretch; }
.parcours__sous { display: flex; justify-content: center; }
.parcours__sous .installer { align-items: center; text-align: center; }
.rappels-bloc { display: flex; flex-direction: column; gap: var(--space-3); }
.rappels-bloc__actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.rappels-bloc__actions:empty { display: none; }
.rappels__titre { font-size: var(--text-h3); }
.rappels__sous-titre { margin: var(--space-3) 0 0; font-family: var(--font-display); font-size: var(--text-body-l); font-weight: 700; }
.rappels__confirmation:empty { display: none; }
.parcours__corps .rappels-bloc { margin-top: var(--space-4); }
