/* =============================================================================
   Applipro, page fonctionnalité « Messagerie ».
   Les modules communs aux pages fonctionnalité sont dans fonctionnalite.css ;
   ce fichier ne garde que le téléphone du hero (une conversation de groupe)
   et les petits écrans des trois étapes.
   ============================================================================= */

/* --- Hero : la conversation d'un groupe, comme dans l'application --- */
.mgp-view { padding: 10px 15px 0; text-align: left; }
.mgp-view .app-head { height: 44px; }
.mgp-view .app-bell { width: 34px; height: 34px; border-radius: 11px; }
.mgp-title { margin-top: 10px; font-size: 17px; font-weight: 800; letter-spacing: -.02em; text-align: center; }
.mgp-tabs { display: flex; gap: 18px; margin-top: 12px; border-bottom: 1px solid #E6E8F0; font-size: 12.5px; font-weight: 600; color: #8A93A8; }
.mgp-tabs b, .mgp-tabs span { padding-bottom: 8px; }
.mgp-tabs b { margin-bottom: -1px; border-bottom: 2px solid var(--app, #1B3FA8); font-weight: 700; color: var(--app, #1B3FA8); }
.mgp-msgs { display: grid; gap: 8px; margin-top: 12px; }
.mgp-msgs li { justify-self: start; max-width: 86%; padding: 10px 12px 9px; border-radius: 16px; background: #fff; box-shadow: 0 0 0 1px #E3E6EE; font-size: 12.5px; line-height: 1.4; color: #1C2333; }
.mgp-msgs small { display: block; margin-bottom: 2px; font-size: 11px; font-weight: 600; color: #8A93A8; }
.mgp-msgs em { display: block; margin-top: 4px; font-size: 10px; font-style: normal; text-align: right; color: #9AA1B2; }
/* Les réactions : le seul endroit du site où un emoji a sa place, puisque c'est ce que l'application affiche */
.mgp-react { display: flex; gap: 5px; margin-top: 7px; }
.mgp-react b { padding: 4px 8px; border-radius: 99px; background: #F1F3F9; box-shadow: 0 0 0 1px #E3E6EE; font-size: 11px; font-weight: 600; line-height: 1.2; color: #3A4256; animation: mgp-in .4s var(--ease) 2.6s both; }
.mgp-react b + b { animation-delay: 2.9s; }
.mgp-msgs .is-me { justify-self: end; background: var(--app, #1B3FA8); box-shadow: none; color: #fff; animation: mgp-in .5s var(--ease) 1.2s both; }
.mgp-msgs .is-me em { color: rgba(255, 255, 255, .8); animation: mgp-fade .4s ease 2.3s both; }
.mgp-input { position: absolute; left: 12px; right: 12px; bottom: 50px; display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 8px 16px; border-radius: 99px; background: #fff; box-shadow: 0 0 0 1px #E3E6EE, 0 10px 18px -14px rgba(15, 20, 36, .4); font-size: 13px; color: #9AA1B2; }
.mgp-input i { width: 32px; height: 32px; border-radius: 50%; background: #C9D4F5; }
@keyframes mgp-in { from { opacity: 0; transform: translateY(10px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes mgp-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .mgp-msgs .is-me, .mgp-msgs .is-me em, .mgp-react b { animation-duration: .01s; animation-delay: 0s; }
}

/* --- Les petits écrans des trois étapes --- */
.mg-opt { display: grid; grid-template-columns: 16px minmax(0, 1fr); column-gap: 10px; padding: 9px 11px; border-radius: 10px; background: #fff; box-shadow: 0 0 0 1px #E6E8EF; font-size: 11.5px; line-height: 1.3; color: #5B6272; }
.mg-opt.is-on { background: #F3F6FF; box-shadow: 0 0 0 1.5px var(--blue-500); }
.mg-opt i { grid-row: span 2; align-self: center; width: 16px; height: 16px; border-radius: 50%; box-shadow: inset 0 0 0 1.6px #B9C0D0; }
.mg-opt.is-on i { box-shadow: inset 0 0 0 5px var(--blue-500); }
.mg-opt b { font-size: 12.5px; font-weight: 700; color: #1C2333; }
.mg-types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.mg-types b { padding: 9px 10px; border-radius: 9px; background: #fff; box-shadow: 0 0 0 1px #E6E8EF; font-size: 11.5px; font-weight: 700; line-height: 1.25; }
.mg-types b.is-on { background: #F3F6FF; box-shadow: 0 0 0 1.5px var(--blue-500); }
.mg-types small { display: block; margin-top: 2px; font-size: 10.5px; font-weight: 500; color: #7A8090; }
.mg-f { display: grid; gap: 4px; padding: 8px 11px 9px; border-radius: 9px; background: #fff; box-shadow: 0 0 0 1px #DCDFE8; font-size: 12.5px; font-weight: 600; }
.mg-f small { font-size: 10.5px; font-weight: 600; color: #7A8090; }
.mg-f .bo-chip { justify-self: start; padding: 5px 9px; border-radius: 99px; font-size: 11px; }
.mg-conv { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px 10px; border-radius: 12px; background: #fff; box-shadow: 0 16px 28px -22px rgba(18, 22, 36, .5); font-size: 12.5px; font-weight: 700; }
.mg-conv i { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: #EEF0FB; }
.mg-conv svg { width: 15px; height: 15px; fill: #4B50E6; }
.mg-conv small { display: block; font-size: 10.5px; font-weight: 500; color: #7A8090; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mg-conv em { align-self: start; font-size: 10px; font-style: normal; font-weight: 500; color: #9AA1B2; }
.mg-grp { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 9px 11px; border-radius: 10px; background: #fff; box-shadow: 0 0 0 1px #E6E8EF; font-size: 12.5px; font-weight: 700; line-height: 1.25; }
.mg-grp small { display: block; margin-top: 1px; font-size: 10.5px; font-weight: 500; color: #7A8090; }
.mg-grp .chip { font-size: 10.5px; }

/* Aux largeurs où le téléphone est plus court, un message de moins : rien ne passe sous la barre de saisie */
@media (max-width: 940px) {
  .mgp-msgs li:nth-child(2) { display: none; }
  .mgp-input { bottom: 90px; }
}
@media (max-width: 800px) {
  .mgp-input { bottom: 60px; }
}
