/* Style des écrans Telegram du site (Android, thème sombre de Tom), regroupé ici pour pouvoir être remplacé d'un bloc.
   Tout ce qui est dans un téléphone (en-tête, bulles, vocal, barre de saisie, couleurs, tailles) est dans ce fichier, rien dans index.html.
   Restent dans la page : la coque du téléphone (.coque), l'écran à l'échelle (.ecran, --k) et la mise en page des cartes.
   Couleurs MESURÉES (médiane de pixels) sur les captures d'écran du téléphone de Tom (verif/refonte-13-10/couleurs-tg/, mesure*.py) :
   fond #131a28 (de #0d171d en haut à #161f2e en bas), bulle reçue #232c3b, bulle envoyée en dégradé de #5e5dda (haut) à #5169de (bas),
   pilule d'en-tête, ronds et boutons du clavier #273348 / #212d3d / #2a374b, barre de saisie #212e41, bouton Menu et micro #229af1,
   texte #f9ffff, sous-titre « bot » #8291a2, « Message » #738497, icônes #a9b4c5.
   Police : Roboto si l'appareil l'a, sinon la police système (aucune police Roboto n'est hébergée sur le site). */
.tg{--tg-fond:#131a28;--tg-barre:#212e41;--tg-rond:#212d3d;--tg-pilule:#273348;--tg-entrant:#232c3b;--tg-sortant:#5e5dda;--tg-sortant-2:#5169de;--tg-texte:#f9ffff;--tg-discret:#8291a2;--tg-hint:#738497;--tg-heure:#7e8ea1;--tg-heure-sortant:#e3e8ff;--tg-icone:#a9b4c5;--tg-lien:#79c4fc;--tg-envoi:#229af1;--tg-bouton:#2a374b;--tg-service:#1b2431b3}
.tg{overflow-anchor:none;position:absolute;left:0;top:0;width:320px;height:693px;transform:scale(var(--k));transform-origin:0 0;display:flex;flex-direction:column;background:url(img/motifs.svg) 0 0/230px 312px,linear-gradient(180deg,#0d171d,var(--tg-fond) 38%,#161f2e);color:var(--tg-texte);font:15px/1.33 Roboto,"Segoe UI",system-ui,-apple-system,sans-serif;-webkit-font-smoothing:antialiased;text-align:left;letter-spacing:0}
.tg svg{display:block}
.tg .tete{flex:none;display:flex;align-items:center;gap:6px;padding:4px 8px 6px}
.tg .rond{width:42px;height:42px;border-radius:50%;background:var(--tg-rond);display:grid;place-items:center;flex:none}
.tg .rond svg{width:21px;height:21px;fill:none;stroke:var(--tg-texte);stroke-width:2.1;stroke-linecap:round;stroke-linejoin:round}
.tg .rond .points{fill:var(--tg-texte);stroke:none;width:18px}
.tg .pastille{flex:1;height:46px;border-radius:23px;background:var(--tg-pilule);display:flex;align-items:center;gap:10px;padding:0 10px 0 4px}
.tg .pastille img{width:38px;height:38px;border-radius:50%}
.tg .ident{display:flex;flex-direction:column;line-height:1.2}
.tg .ident b{font-size:17px;font-weight:600}
.tg .bot,.tg .ecrit{font-size:13px;color:var(--tg-discret)}
.tg .ecrit{display:none;color:var(--tg-lien)}
.tg .ecrit i{font-style:normal;animation:tg-point .6s infinite}
.tg .ecrit i:nth-child(2){animation-delay:.12s}
.tg .ecrit i:nth-child(3){animation-delay:.24s}
.tg.ecrit .bot{display:none}
.tg.ecrit .ecrit{display:inline}
.tg .chat{flex:1;min-height:0;overflow:hidden;display:flex;flex-direction:column;justify-content:flex-end;padding:4px 8px 8px}
.tg .fil{display:flex;flex-direction:column;gap:6px;transition:opacity .3s}
.tg .fil.fondu{opacity:0}
.tg .date{align-self:center;color:#e8eef5;background:var(--tg-service);border-radius:14px;padding:3px 10px;font-size:12px;margin-bottom:2px}
.tg .m{display:none;flex-direction:column;align-self:flex-start;max-width:268px}
.tg .m.moi{align-self:flex-end;max-width:262px}
.tg .m.large{width:284px;max-width:284px}
.tg .m.vu{display:flex;animation:tg-entree .24s cubic-bezier(.16,1,.3,1)}
.tg .bulle{background:var(--tg-entrant);border-radius:17px 17px 17px 5px;padding:7px 11px 5px;overflow:hidden}
.tg .moi .bulle{background:linear-gradient(140deg,var(--tg-sortant),var(--tg-sortant-2));border-radius:17px 17px 5px 17px}
.tg .txt{font-size:15px;line-height:1.33;overflow-wrap:anywhere}
.tg .txt+.txt{margin-top:5px}
.tg .txt b,.tg .titre-bloc{font-weight:600}
.tg .txt a{color:var(--tg-lien)}
.tg .meta{display:flex;align-items:center;justify-content:flex-end;gap:4px;color:var(--tg-heure);font-size:11px;margin-top:2px}
.tg .moi .meta{color:var(--tg-heure-sortant)}
.tg .coches{width:16px;height:11px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.tg .voix{display:flex;align-items:center;gap:9px;min-width:210px;padding-top:2px}
.tg .lire{width:40px;height:40px;flex:none;border-radius:50%;background:#fff;display:grid;place-items:center}
.tg .lire svg{width:17px;height:17px;fill:var(--tg-sortant);margin-left:3px}
.tg .audio{flex:1;min-width:0}
.tg .onde{height:22px;display:flex;align-items:center;gap:2px;overflow:hidden}
.tg .onde i{width:2px;flex:none;border-radius:2px;background:#e6f3ff}
.tg .duree{display:block;font-size:11px;color:var(--tg-heure-sortant)}
.tg .transcrit{font-size:14.5px;line-height:1.3;margin-top:6px;padding-top:6px;border-top:1px solid #ffffff2b}
.tg .titre-bloc{font-size:15px;margin:1px 0 6px}
.tg .lignes{font-size:14px;line-height:1.3;margin:2px 0 3px}
.tg .ligne{display:flex;justify-content:space-between;gap:10px;padding:5px 4px;border-bottom:1px solid #ffffff14;border-radius:4px}
.tg .ligne span:last-child{white-space:nowrap}
.tg .ligne.total{font-weight:600;border-top:1.5px solid #ffffff40;border-bottom:0;margin-top:2px;padding-top:7px}
.tg .ligne.total span:last-child{color:#8fd19e}
.tg .m.vu .ligne.nouveau{animation:tg-surligne 1.6s .3s both}
.tg .carte{background:#ffffff0d;border-radius:10px;padding:8px 10px;margin:2px 0 4px;font-size:14px}
.tg .carte-titre{display:flex;align-items:center;gap:7px;font-weight:600;color:#8fd19e}
.tg .carte-titre svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.tg .carte small{display:block;color:var(--tg-discret);font-size:12px;margin-top:3px}
.tg .compo{flex:none;display:flex;align-items:center;gap:6px;padding:4px 8px 10px}
.tg .saisie{flex:1;min-width:0;height:44px;border-radius:22px;background:var(--tg-barre);display:flex;align-items:center;gap:8px;padding:0 12px 0 4px}
.tg .menu{display:flex;align-items:center;gap:5px;border-radius:18px;background:var(--tg-envoi);padding:8px 11px 8px 9px;font-size:14.5px;font-weight:500;line-height:18px}
.tg .menu svg{width:17px;height:17px;stroke:#fff;stroke-width:2.2;fill:none;stroke-linecap:round}
.tg .gif{font-size:9px;font-weight:700;color:var(--tg-icone);border:1.8px solid var(--tg-icone);border-radius:6px;padding:2px 3px;line-height:10px}
.tg .zone{flex:1;min-width:0;overflow:hidden;white-space:nowrap;font-size:16px;display:flex;align-items:center}
.tg .vide{color:var(--tg-hint)}
.tg .curseur{display:none;width:2px;height:20px;background:var(--tg-envoi);margin-left:1px;flex:none;animation:tg-curseur .5s steps(1) infinite}
.tg .trombone{width:22px;height:22px;flex:none;fill:none;stroke:var(--tg-icone);stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.tg .rec{display:none;flex:1;align-items:center;gap:8px;font-size:15px;padding-left:10px}
.tg .rec .point{width:10px;height:10px;border-radius:50%;background:#ef5350;animation:tg-point .6s infinite}
.tg .annuler{color:var(--tg-hint);font-size:13px;margin-left:auto}
.tg .micro{width:44px;height:44px;flex:none;border-radius:50%;background:var(--tg-envoi);display:grid;place-items:center;transition:transform .2s}
.tg .micro svg{width:22px;height:22px;fill:none;stroke:#fff;stroke-width:2.1;stroke-linecap:round;stroke-linejoin:round;grid-area:1/1}
.tg .i-envoi{display:none}
.tg.saisit .menu,.tg.saisit .gif,.tg.saisit .vide,.tg.saisit .i-micro{display:none}
.tg.saisit .curseur,.tg.saisit .i-envoi{display:block}
.tg.saisit .saisie{padding-left:14px}
.tg.enregistre .menu,.tg.enregistre .gif,.tg.enregistre .zone,.tg.enregistre .trombone{display:none}
.tg.enregistre .rec{display:flex}
.tg.enregistre .micro{transform:scale(1.2)}
.tg.v360{width:360px;height:780px;transform:scale(calc(var(--k) * .88889))}
.v360 .tete,.v360 .compo{zoom:1.125}
.v360 .chat{padding:6px 9px 8px}
.v360 .fil{gap:6px}
.v360 .m{max-width:300px}
.v360 .m.moi{max-width:292px}
.v360 .m.large{width:312px;max-width:312px}
.v360 .bulle{padding:8px 12px 6px}
.v360 .txt{font-size:15.5px}
.v360 .txt+.txt{margin-top:6px}
.v360 .voix{gap:10px;min-width:236px}
.v360 .lire{width:44px;height:44px}
.v360 .lire svg{width:19px;height:19px}
.v360 .onde{height:24px}
.v360 .duree{font-size:11.5px}
.v360 .transcrit{font-size:15px;margin-top:7px;padding-top:7px}
.v360 .titre-bloc{font-size:16px;line-height:1.3;margin:1px 0 8px}
.v360 .lignes{font-size:14.5px;margin:2px 0 4px}
.v360 .ligne{gap:12px;padding:6px 0;border-radius:0}
.v360 .ligne:last-child{border-bottom:0}
.v360 .ligne span:last-child{font-variant-numeric:tabular-nums}
.v360 .ligne.total{font-size:15.5px;padding-top:8px}
.tg .ligne .moins{color:#f0a3a3}
.v360 .carte{border-radius:11px;padding:9px 11px;margin:4px 0 6px;font-size:14.5px;line-height:1.35}
.v360 .carte-titre{gap:8px;margin-bottom:4px}
.v360 .carte-titre svg{width:17px;height:17px;flex:none}
.tg .carte.rouge .carte-titre{color:#f28b80}
.tg .carte.bleu .carte-titre{color:var(--tg-lien)}
.tg .carte p{margin:0;color:#dfe6ee}
.v360 .carte small{font-size:12.5px}
.tg .agenda{margin:2px 0 4px}
.tg .creneau{display:grid;grid-template-columns:50px 1fr;gap:8px;padding:6px 0;border-bottom:1px solid #ffffff14;font-size:14.5px;line-height:1.3}
.tg .creneau:last-child{border-bottom:0}
.tg .creneau b{font-weight:600;color:var(--tg-lien);font-variant-numeric:tabular-nums}
.tg .creneau small{display:block;color:var(--tg-discret);font-size:12.5px;margin-top:1px}
.tg .groupe{padding:7px 0;border-bottom:1px solid #ffffff14;font-size:14.5px;line-height:1.3}
.tg .groupe:last-child{border-bottom:0;padding-bottom:3px}
.tg .groupe-titre{display:flex;align-items:center;gap:7px;font-weight:600;margin-bottom:3px}
.tg .groupe-titre em{font-style:normal;font-weight:500;color:var(--tg-discret);margin-left:auto;font-size:13px}
.tg .groupe p{margin:0;color:#d6dde6}
.tg .puce{width:9px;height:9px;border-radius:50%;flex:none;background:#7d8b9b}
.tg .puce.rouge{background:#ef6b5f}
.tg .puce.bleu{background:#5aa9ec}
.tg .boutons{display:grid;gap:5px;margin-top:5px}
.tg .boutons.deux{grid-template-columns:1fr 1fr}
.tg .boutons span{background:var(--tg-bouton);border-radius:11px;padding:11px 8px;font-size:14.5px;line-height:18px;font-weight:500;text-align:center}
.tg .fichier{display:flex;gap:11px;align-items:center;margin:3px 0}
.tg .fichier-icone{width:44px;height:44px;border-radius:50%;background:#4f9bd6;display:grid;place-items:center;flex:none}
.tg .fichier-icone svg{width:20px;height:20px;fill:#fff}
.tg .fichier-icone.vert{background:#3f9d63}
.tg .fichier-icone.orange{background:#d9893a}
.tg .fichier b{display:block;font-size:15px;font-weight:500;line-height:19px}
.tg .fichier small{display:block;font-size:12px;color:var(--tg-discret);margin-top:3px}
.tg .mail{border-left:2.5px solid var(--tg-lien);padding:1px 0 1px 10px;margin:8px 0 5px;font-size:14.5px;line-height:1.38}
.tg .mail .objet{color:var(--tg-lien);margin-bottom:6px;font-weight:500}
.tg .mail p{margin:0 0 7px}
.tg .mail p:last-child{margin:0}
.tg .bulle.image{padding:3px 3px 5px}
.tg .apercu{background:#fff;color:#1d2b3c;border-radius:14px 14px 4px 4px;padding:10px 10px 7px;font-size:7.6px;line-height:1.2}
.tg .apercu-tete{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.tg .apercu-tete b{font-size:10.2px;font-weight:600}
.tg .apercu-tete span{background:#e8effa;color:#3f68a4;padding:3px 4px;border-radius:3px;font-size:6.2px}
.tg .apercu table{border-collapse:collapse;width:100%;text-align:left}
.tg .apercu th{background:#eef2f7;color:#52647b;font-weight:500;font-size:6.2px}
.tg .apercu td,.tg .apercu th{padding:4.8px 3.5px;border-bottom:1px solid #e4e9f0}
.tg .apercu td:last-child{color:#537167;font-size:6.6px}
.tg .apercu-pied{font-size:6.2px;color:#78889c;margin-top:7px}
.tg .panneau-titre{font-weight:600;font-size:17px;margin:2px 0 11px}
.tg .mission{font-size:15px;line-height:1.3;margin-bottom:11px}
.tg .jauge{display:flex;align-items:center;gap:7px;font-size:15px;line-height:1.35;white-space:nowrap;font-variant-numeric:tabular-nums}
.tg .barre{display:inline-flex;gap:2px;flex:none}
.tg .barre i{width:9px;height:6px;border:1px solid #dbe5f0;border-radius:1px;transform:skewX(-16deg)}
.tg .barre i.v{background:#dbe5f0}
.tg .jauges{background:#ffffff08;border-radius:11px;margin:6px -6px 2px;padding:8px 6px 6px;font-size:15px}
.tg .jauges-nom{margin:4px 0 2px}
.tg .jauges .pas{width:30px;flex:none}
@keyframes tg-entree{from{opacity:0;transform:translateY(14px) scale(.95)}to{opacity:1;transform:none}}
@keyframes tg-surligne{from{background:#ffd54f4d}to{background:transparent}}
@keyframes tg-point{50%{opacity:.25}}
@keyframes tg-curseur{50%{opacity:0}}
@media(prefers-reduced-motion:reduce){.tg .m{display:flex}
.tg .m.vu,.tg .m.vu .ligne.nouveau{animation:none}
.tg.ecrit .ident .bot{display:inline}
.tg.ecrit .ident .ecrit{display:none}
}
.tg .visuel{position:relative;overflow:hidden;border-radius:14px 14px 4px 4px;isolation:isolate}
.tg .m:not(.large) .visuel{width:220px}
.tg .m:not(.large) .bulle.image{width:min-content}
.tg .version{position:absolute;top:8px;right:8px;z-index:9;font:600 11px/1 Roboto,system-ui,sans-serif;color:#fff;background:#131a28bf;border-radius:6px;padding:4px 6px}
.tg .bulle.image>.txt{padding:6px 9px 0;font-size:15px;line-height:1.3}
.tg .bulle.image>.meta{padding-right:9px}
.tg .bulle.image>.fichier{padding:2px 6px 0}
.tg:not(.en-vue) .visuel *{animation-play-state:paused!important}
/* Carte du rail non centrée : conversation finale figée, sans aucune animation (les visuels sont posés dans leur état d'arrivée ;
   les boucles infinies, comme la vidéo de la boulangerie, sont arrêtées sur une image fixe) */
.tg.fige .m.vu,.tg.fige .m.vu .ligne.nouveau,.tg.fige .prog-bloc{animation:none}
.tg.fige .fil,.tg.fige .mot{transition:none}
.tg.fige .visuel *{animation-duration:0s!important;animation-delay:0s!important;animation-iteration-count:1!important;animation-play-state:paused!important}
.tg.fige .rl *{animation-duration:10.4s!important;animation-delay:-1.5s!important;animation-iteration-count:infinite!important}
.tg.fige .rl-eq i,.tg.fige .rl-braise,.tg.fige .rl-vapeur{animation-duration:.9s!important;animation-delay:-.4s!important}
@media(prefers-reduced-motion:reduce){.tg .visuel *{animation:none!important}
}

/* En-tête : plus de barre d'état (ni heure ni réseau), l'espace du haut suit l'arrondi de l'écran */
.tg .tete{padding-top:14px}
.tg .ident b{font-weight:500}
/* Réponse progressive : texte mot à mot, autres blocs l'un après l'autre (classes posées par rail.js) */
.tg .prog-cache{display:none!important}
.tg .prog-bloc{animation:tg-bloc .24s cubic-bezier(.16,1,.3,1) both}
.tg .mot{opacity:0;transition:opacity .09s linear}
.tg .mot.on{opacity:1}
@keyframes tg-bloc{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
/* Sans JavaScript : tout est affiché, la saisie reste fermée */
@media(scripting:none){.tg.ecrit .ident .bot{display:inline}
.tg.ecrit .ident .ecrit{display:none}
.tg .fil .m{display:flex}
}
@media(prefers-reduced-motion:reduce){.tg .prog-bloc{animation:none}
.tg .mot{opacity:1;transition:none}
}
