/* Nsahni — bouton WhatsApp flottant (nsahni.com ; repris de la page maroclic.com/nsahni/).
   Une bulle grenat qui porte le ن de la marque ; son point bat comme un voyant « en ligne ».
   La bulle d'accroche arrive, « écrit », puis parle. Sans animation : tout est visible d'emblée. */
.wa {
  position: fixed; z-index: 15; display: flex; flex-direction: column; align-items: flex-end; gap: 12px;
  right: max(16px, calc(env(safe-area-inset-right) + 12px)); bottom: max(16px, calc(env(safe-area-inset-bottom) + 12px));
  pointer-events: none;
}
.wa > * { pointer-events: auto; }
html[dir="rtl"] .wa { align-items: flex-start; } /* en arabe, flex-start est le bord droit : le bouton reste sous la bulle, à droite */
.wa__btn {
  display: grid; place-items: center; width: 64px; height: 64px; border-radius: 32px 32px 10px 32px;
  background: var(--grenat); color: var(--rose);
  /* liseré blanc : le bouton reste lisible sur le hero grenat du nouveau rendu comme sur le papier */
  box-shadow: 0 0 0 3px var(--blanc), 0 14px 30px -10px rgba(36, 16, 26, .55), 0 2px 6px rgba(36, 16, 26, .18);
  transition: transform .2s cubic-bezier(.2, .8, .2, 1), background-color .2s;
}
.wa__btn:hover { background: #621832; transform: translateY(-3px); }
.wa__btn:focus-visible { outline: 3px solid var(--encre); outline-offset: 4px; }
.wa__mark { width: 36px; height: 36px; overflow: visible; }
.wa__point, .wa__pouls { fill: var(--blanc); }
.wa__pouls { opacity: 0; transform-box: fill-box; transform-origin: center; }
.wa__bulle {
  position: relative; width: min(290px, calc(100vw - 32px));
  background: var(--blanc); color: var(--encre); border: 1px solid var(--trait); border-radius: 20px 20px 6px 20px;
  box-shadow: 0 1px 2px rgba(36, 16, 26, .06), 0 12px 32px -12px rgba(36, 16, 26, .22); transform-origin: bottom right;
}
.wa__texte {
  display: grid; gap: 6px; padding-block: 14px 15px; padding-inline: 16px 46px;
  color: inherit; text-decoration: none; font: 400 15px/1.45 var(--f-texte);
}
.wa__qui { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; color: var(--texte-doux); }
.wa__qui::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--framboise); box-shadow: 0 0 0 3px rgba(194, 65, 106, .2); }
.wa__ecrit { display: flex; gap: 4px; max-height: 0; opacity: 0; overflow: hidden; }
.wa__ecrit i { width: 7px; height: 7px; border-radius: 50%; background: var(--rose); }
.wa__fermer {
  position: absolute; top: 6px; inset-inline-end: 6px; width: 36px; height: 36px; display: grid; place-items: center;
  border: 0; border-radius: 50%; background: transparent; color: var(--texte-doux); font: 400 22px/1 var(--f-texte); cursor: pointer;
}
.wa__fermer:hover { background: var(--sable); color: var(--encre); }
.wa__fermer:focus-visible { outline: 3px solid var(--grenat); outline-offset: 0; }
.wa--ferme .wa__bulle { display: none; }
@media (max-width: 559px) { .wa__btn { width: 58px; height: 58px; } .wa__texte { font-size: 14.5px; } }
@media (max-width: 759px) { .pied { padding-bottom: 112px; } }
@media print { .wa { display: none; } }
@media (prefers-reduced-motion: no-preference) {
  .wa__btn { animation: wa-entre .5s cubic-bezier(.2, .8, .2, 1) .4s backwards; }
  .wa__pouls { animation: wa-pouls 2.6s ease-out 1.2s infinite; }
  .wa__bulle { animation: wa-entre .45s cubic-bezier(.2, .8, .2, 1) 2.2s backwards; }
  .wa__ecrit { animation: wa-ecrit 1.5s linear 2.4s backwards; }
  .wa__ecrit i { animation: wa-point 1s ease-in-out infinite; }
  .wa__ecrit i:nth-child(2) { animation-delay: .15s; }
  .wa__ecrit i:nth-child(3) { animation-delay: .3s; }
  .wa__msg { animation: wa-msg .4s ease 3.9s backwards; }
  @keyframes wa-entre { from { opacity: 0; transform: translateY(12px) scale(.9); } to { opacity: 1; transform: none; } }
  @keyframes wa-pouls { 0% { opacity: .5; transform: scale(1); } 70%, 100% { opacity: 0; transform: scale(2.4); } }
  @keyframes wa-ecrit { 0%, 90% { max-height: 16px; opacity: 1; padding: 4px 0; } 100% { max-height: 0; opacity: 0; padding: 0; } }
  @keyframes wa-point { 0%, 100% { transform: translateY(0); opacity: .5; } 50% { transform: translateY(-3px); opacity: 1; } }
  @keyframes wa-msg { from { opacity: 0; max-height: 0; } to { opacity: 1; max-height: 9em; } }
}
