/* Accueil : bloc « coach » (retours de Jordi du 19/11/2026). Classes propres à ce bloc (préfixe nvc2-). */

/* Cadre à points : moins de marge haut et bas (retour du 19/11) */
.nvx-frame--dots:has(.nvc2-chat){padding-block:14px}
/* Image : un petit cadre paysage bas (2:1), recadré sur le téléphone et la feuille ; la future photo (paysage bas) s'y loge sans retouche */
.nvc2-img{position:relative; margin:0; width:260px; max-width:70%; aspect-ratio:2 / 1; border-radius:var(--r-m); overflow:hidden; background:var(--mist); align-self:flex-start}
.nvc2-img img{position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:50% 4%; display:block;
              transform:scale(1.14); transform-origin:12% 75%}
@media (max-width:600px){ .nvc2-img{width:200px} }

/* Carte de chat : mord sur le bas du petit cadre, à droite */
.nvx-frame > .nvc2-img ~ .nvc2-chat{position:relative; z-index:1; margin:-46px 0 0 auto; width:min(100%,400px); box-shadow:var(--shadow-float)}
@media (max-width:600px){ .nvx-frame > .nvc2-img ~ .nvc2-chat{margin-top:-34px; width:100%} }
.nvc2-chat .nvx-chat__head{padding:7px 14px}
.nvc2-chat .nvx-chat__head small{margin-top:0}
.nvc2-chat .nvx-chat__body{justify-content:flex-start; padding:8px 14px; gap:5px}
.nvc2-chat .nvx-chat__foot{padding:7px 14px}
.nvc2-chat .nvx-bubble{padding:5px 11px; font-size:.8125rem; line-height:1.4}
.nvc2-chat .nvx-chat__input{padding:6px 14px}
.nvc2-frame-cap{margin-top:6px}
.nvc2-chat .nvx-bubble.is-hidden{display:none}
.nvc2-chat .nvx-bubble.is-in{animation:nvc2-pop 280ms cubic-bezier(.22,1,.36,1)}
@keyframes nvc2-pop{from{opacity:0; transform:translateY(8px)} to{opacity:1; transform:none}}
.nvc2-chat .nvx-bubble.is-typing::after{content:"\2022\00a0\2022\00a0\2022"; color:var(--muted); animation:nvc2-dots 900ms ease-in-out infinite}
@keyframes nvc2-dots{0%,100%{opacity:.35} 50%{opacity:1}}

/* Champ : onde sonore (voix) puis texte ; curseur quand on tape */
.nvc2-chat .nvx-chat__input{display:flex; align-items:center; gap:8px; white-space:nowrap; overflow:hidden; min-height:36px}
.nvc2-txt{min-width:0; overflow:hidden}
.nvc2-wave{display:none; align-items:center; gap:3px; height:18px; flex:none}
.nvc2-wave i{display:block; width:3px; height:100%; border-radius:2px; background:var(--coral-ink); transform:scaleY(.25); transform-origin:center}
.nvc2-chat .nvx-chat__input.is-typing{color:var(--text); border-color:var(--steel)}
.nvc2-chat .nvx-chat__input.is-typing .nvc2-txt::after{content:""; display:inline-block; width:1.5px; height:1.05em; margin-left:2px; vertical-align:-.15em; background:currentColor; animation:nvc2-caret 900ms steps(1) infinite}
@keyframes nvc2-caret{50%{opacity:0}}
.nvc2-chat .nvx-chat__input.is-listening{color:var(--text); border-color:var(--coral)}
.nvc2-chat .nvx-chat__input.is-listening .nvc2-wave{display:flex}
.nvc2-chat .nvx-chat__input.is-listening .nvc2-wave i{animation:nvc2-wave 700ms ease-in-out infinite}
.nvc2-wave i:nth-child(2){animation-delay:-120ms !important} .nvc2-wave i:nth-child(3){animation-delay:-300ms !important}
.nvc2-wave i:nth-child(4){animation-delay:-450ms !important} .nvc2-wave i:nth-child(5){animation-delay:-200ms !important}
@keyframes nvc2-wave{0%,100%{transform:scaleY(.25)} 50%{transform:scaleY(1)}}

/* Micro : rouge plein, icône blanche, halo qui pulse, pendant que l'élève parle */
.nvc2-mic{transition:background-color 160ms, border-color 160ms, color 160ms}
.nvc2-mic.is-rec{background:var(--coral); border-color:var(--coral); color:#fff; animation:nvc2-halo 1300ms ease-out infinite}
@keyframes nvc2-halo{0%{box-shadow:0 0 0 0 rgba(242,92,92,.55)} 80%,100%{box-shadow:0 0 0 10px rgba(242,92,92,0)}}

@media (prefers-reduced-motion: reduce){
  .nvc2-chat .nvx-bubble.is-in,.nvc2-chat .nvx-bubble.is-typing::after,.nvc2-chat .nvx-chat__input.is-typing .nvc2-txt::after,
  .nvc2-chat .nvx-chat__input.is-listening .nvc2-wave i,.nvc2-mic.is-rec{animation:none}
  .nvc2-mic{transition:none}
}
