:root { --encre:#102526; --niagara:#4A6B6B; --ocean:#3F4E4D; --menthe:#5C6C64; --brume:#D0CDCD; --terre:#8A4B3C;
  --titre:"Zen Maru Gothic","Trebuchet MS",Verdana,sans-serif; --texte:"Raleway",Calibri,Arial,sans-serif; }
* { box-sizing: border-box; }
html, body { margin:0; background:#fff; color:var(--ocean); font-family:var(--texte); font-size:15px; line-height:1.55; }
h1,h2,h3 { font-family:var(--titre); font-weight:500; color:var(--encre); margin:0; line-height:1.3; }
h1{font-size:26px} h2{font-size:18px} h3{font-size:16px}
p{margin:0} a{color:var(--niagara);text-decoration:none;font-weight:600}
button{font:inherit}
#app { max-width:480px; margin:0 auto; min-height:100vh; display:flex; flex-direction:column; }
.ecran { display:flex; flex-direction:column; min-height:100vh; }
.ecran.sombre { background:var(--encre); color:#fff; } .ecran.sombre h2 { color:#fff; }
.barre { display:flex; align-items:center; justify-content:space-between; padding:22px 20px 12px; }
.barre .retour { background:none; border:0; padding:0; width:26px; height:26px; cursor:pointer; }
.barre .etape { font-size:12px; letter-spacing:.04em; color:var(--ocean); } .sombre .barre .etape{ color:var(--brume) }
.contenu { padding:0 20px; display:flex; flex-direction:column; gap:14px; flex-grow:1; }
.bas { margin-top:auto; padding:14px 20px 26px; display:flex; flex-direction:column; gap:10px; border-top:1px solid var(--brume); background:#fff; position:sticky; bottom:0; }
.btn { display:flex; align-items:center; justify-content:center; gap:10px; height:52px; border-radius:10px; border:0; background:var(--niagara); color:#fff; font-weight:600; font-size:15px; letter-spacing:.02em; cursor:pointer; width:100%; }
.btn.second { background:#fff; color:var(--niagara); border:1px solid var(--niagara); }
.btn:disabled { opacity:.45; cursor:not-allowed; }
.carte { border:1px solid var(--brume); border-radius:12px; padding:14px 16px; }
.carte.choisie { border:1.5px solid var(--niagara); }
.ligne { display:flex; align-items:center; gap:14px; padding:12px 0; border-bottom:1px solid var(--brume); }
.avatar { width:40px; height:40px; border-radius:50%; background:var(--menthe); color:#fff; display:flex; align-items:center; justify-content:center; font-weight:600; flex-shrink:0; }
.champ { display:flex; align-items:center; gap:10px; height:46px; border:1px solid var(--brume); border-radius:10px; padding:0 14px; width:100%; font:inherit; color:var(--encre); }
.hero { background:var(--encre); border-radius:14px; padding:22px 20px; color:#fff; display:flex; align-items:center; justify-content:space-between; gap:16px; cursor:pointer; }
.hero p { color:var(--brume); font-size:13px; }
.tuiles { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.tuile { border:1px solid var(--brume); border-radius:12px; padding:14px 16px; }
.tuile .n { font-family:var(--titre); font-size:24px; color:var(--encre); display:block; }
.tuile span:last-child { font-size:12px; }
.petit { font-size:12px; } .muet { color:var(--ocean); }
.encart { background:var(--menthe); color:#fff; border-radius:12px; padding:14px 16px; } .encart * { color:#fff; }
.puces { display:flex; gap:8px; flex-wrap:wrap; }
.puce { padding:6px 12px; border-radius:16px; border:1px solid var(--niagara); color:var(--niagara); font-size:12px; font-weight:600; background:none; cursor:pointer; }
.puce.active { background:var(--encre); color:#fff; border-color:var(--encre); }
.indic { display:flex; flex-direction:column; gap:2px; padding:7px 0; }
.indic .haut { display:flex; align-items:center; gap:14px; }
.indic .nom { width:96px; color:var(--encre); font-size:14px; flex-shrink:0; }
.indic .sc { width:30px; text-align:right; font-weight:600; color:var(--encre); }
.jauge { position:relative; height:6px; border-radius:3px; background:var(--brume); flex-grow:1; }
.jauge i { display:block; height:6px; border-radius:3px; background:var(--niagara); }
.jauge b { position:absolute; top:-4px; width:2px; height:14px; background:var(--encre); }
.indic .phrase { font-size:12px; padding-left:110px; }
/* La définition du problème de peau, repliée par défaut : l'esthéticienne la déplie
   quand une cliente demande « ça veut dire quoi ? ». Toujours là, jamais imposée. */
.indic .def { padding-left:110px; margin-top:3px; }
/* Le même dépliant sert ailleurs : les marques de la carte de soins, le déroulé d'un
   protocole. D'où des règles sur `details.def` et non plus seulement dans `.indic`. */
details.def > summary { font-size:12px; color:var(--niagara); cursor:pointer; list-style:none; }
details.def > summary::-webkit-details-marker { display:none; }
details.def > summary::before { content:'＋ '; }
details.def[open] > summary::before { content:'－ '; }
details.def p { font-size:12.5px; color:var(--menthe); margin:5px 0 0; line-height:1.55; max-width:62ch; }
/* Le prix d'un soin. Vide, le champ se borde en rouge : c'est ce qui fait voir d'un
   coup d'œil, dans une liste de quarante soins, lesquels ne sont pas encore offerts. */
.prix { width:66px; height:34px; border:1px solid var(--brume); border-radius:8px; padding:0 8px;
  font:inherit; font-size:14px; text-align:right; color:var(--encre); background:#fff; }
.prix:placeholder-shown { border-color:var(--terre, #8A4B3C); }
.score { font-family:var(--titre); font-size:54px; color:var(--encre); line-height:1; }
.photo { border-radius:12px; background:var(--ocean); object-fit:cover; }
.viseur { position:relative; width:100%; aspect-ratio:3/4; background:#000; border-radius:16px; overflow:hidden; }
.viseur video, .viseur img.guide { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }
.viseur img.guide { opacity:.35; pointer-events:none; }
.viseur .ovale { position:absolute; left:12%; right:12%; top:6%; bottom:10%; border:2px dashed var(--brume); border-radius:50%; }
.voyants { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; }
.voyant { display:flex; align-items:center; justify-content:center; gap:6px; height:36px; border-radius:18px; border:1px solid var(--brume); color:#fff; font-size:12px; font-weight:600; }
.voyant.ok { background:#fff; color:var(--encre); border-color:#fff; }
.capture { width:78px; height:78px; border-radius:50%; border:3px solid #fff; background:none; margin:0 auto; display:flex; align-items:center; justify-content:center; cursor:pointer; }
.capture i { width:62px; height:62px; border-radius:50%; background:#fff; display:block; }
.capture:disabled { opacity:.45; border-color:var(--brume); } .capture:disabled i { background:var(--brume); }
.prio { display:flex; gap:14px; align-items:flex-start; }
.prio .num { font-family:var(--titre); font-size:22px; color:var(--niagara); line-height:1; }
.produit { display:flex; align-items:center; gap:12px; padding:10px 0; border-bottom:1px solid var(--brume); }
.produit .vignette { width:54px; height:54px; border-radius:8px; background:var(--brume); flex-shrink:0; }
.chip { display:inline-flex; align-items:center; font-size:11px; font-weight:600; border-radius:10px; padding:2px 8px; }
.chip.ok { background:var(--menthe); color:#fff; } .chip.cmd { background:var(--encre); color:#fff; } .chip.last { border:1px solid var(--niagara); color:var(--niagara); }
.interrupteur { width:44px; height:26px; border-radius:13px; background:var(--brume); border:0; position:relative; cursor:pointer; }
.interrupteur.on { background:var(--niagara); } .interrupteur::after { content:""; position:absolute; top:3px; left:3px; width:20px; height:20px; border-radius:50%; background:#fff; transition:left .15s; } .interrupteur.on::after { left:21px; }
.signature { height:110px; border:1px dashed var(--menthe); border-radius:10px; width:100%; touch-action:none; background:#fff; }
.erreur { background:#fff; color:var(--encre); border-radius:14px; padding:18px; }
.toast { position:fixed; left:50%; bottom:100px; transform:translateX(-50%); background:var(--encre); color:#fff; padding:10px 16px; border-radius:10px; font-size:14px; z-index:9; }
.chargement { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:14px; flex-grow:1; color:var(--ocean); }
.spin { width:36px; height:36px; border:3px solid var(--brume); border-top-color:var(--niagara); border-radius:50%; animation:tourne 1s linear infinite; }
@keyframes tourne { to { transform:rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation:none; } }

/* ---- Agenda ---- */
.semaine { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:4px; }
.jour { display:flex; flex-direction:column; align-items:center; gap:2px; padding:8px 0; border-radius:10px; border:1px solid transparent; cursor:pointer; }
.jour .n { font-family:var(--titre); font-size:18px; color:var(--encre); } .jour .l { font-size:11px; color:var(--ocean); text-transform:uppercase; letter-spacing:.06em; }
.jour.actif { background:var(--encre); } .jour.actif .n, .jour.actif .l { color:#fff; }
.jour.ferme .n { color:var(--brume); }
.jour .pts { display:flex; gap:2px; height:4px; } .jour .pts i { width:4px; height:4px; border-radius:50%; background:var(--niagara); } .jour.actif .pts i { background:#fff; }
.rdv { display:flex; gap:12px; padding:12px 0; border-bottom:1px solid var(--brume); align-items:flex-start; }
.rdv .h { width:52px; flex-shrink:0; font-weight:600; color:var(--encre); font-variant-numeric:tabular-nums; }
.rdv .h small { display:block; font-weight:400; color:var(--ocean); font-size:12px; }
.rdv .corps { flex-grow:1; display:flex; flex-direction:column; gap:4px; }
.rdv.annule .corps { opacity:.5; text-decoration:line-through; }
.rdv .actions { display:flex; gap:8px; flex-wrap:wrap; }
.mini { font-size:12px; font-weight:600; padding:6px 10px; border-radius:8px; border:1px solid var(--brume); background:#fff; color:var(--ocean); cursor:pointer; }
.mini.p { background:var(--niagara); color:#fff; border-color:var(--niagara); }
/* Le bouton qui détruit. Il doit se voir, sans crier plus fort que le bouton principal
   de l'écran : bordé et en terre au repos, plein et rouge une fois armé. Le changement
   de couleur EST la confirmation, avec le changement de texte. */
.danger { display:flex; align-items:center; justify-content:center; gap:8px; width:100%;
  height:44px; border-radius:10px; background:#fff; color:var(--terre, #8A4B3C);
  border:1px solid var(--terre, #8A4B3C); font:inherit; font-weight:600; font-size:14px; cursor:pointer; }
.danger[data-arme="1"] { background:#B3261E; border-color:#B3261E; color:#fff; height:auto;
  min-height:44px; padding:10px 14px; line-height:1.35; text-align:center; }
.danger:disabled { opacity:.5; cursor:not-allowed; }
.creneaux { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; }
.creneau { height:40px; border-radius:8px; border:1px solid var(--brume); background:#fff; color:var(--encre); font-weight:600; font-size:14px; cursor:pointer; font-variant-numeric:tabular-nums; }
.creneau.choisi { background:var(--encre); color:#fff; border-color:var(--encre); }
.libre { text-align:center; padding:24px 0; color:var(--ocean); font-size:14px; }
.nav-bas { position:sticky; bottom:0; background:#fff; border-top:1px solid var(--brume); display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); padding:10px 8px 22px; margin-top:auto; }
.nav-bas a { display:flex; flex-direction:column; align-items:center; gap:4px; font-size:11px; color:var(--ocean); font-weight:400; }
.nav-bas a.actif { color:var(--encre); font-weight:600; }
select.champ { appearance:none; background:#fff; }
