/* Assistant (19.11.2026) : bouton rond en bas à droite → panneau de conversation (questions de suivi possibles).
   Fenêtre d'accueil à chaque connexion, avec « Ne plus afficher ». Sur téléphone, le panneau occupe tout l'écran. */
.assistant{font-size:.9rem;color:#33404d}
.assistant-fab{position:fixed;right:22px;bottom:22px;z-index:960;width:60px;height:60px;border-radius:50%;border:0;background:var(--brand,#293f57);color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer;box-shadow:0 0 0 3px #f3dfae,0 8px 22px rgba(16,24,40,.3);transition:transform .15s;animation:assistantGlow 2.4s ease-out .8s 2}
.assistant-fab:hover{transform:scale(1.05)}
.assistant-fab svg{width:28px;height:28px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.assistant-fab .ico-close{display:none}.assistant.open .assistant-fab .ico-chat{display:none}.assistant.open .assistant-fab .ico-close{display:block}
@keyframes assistantGlow{0%{box-shadow:0 0 0 3px #f3dfae,0 0 0 3px rgba(41,63,87,.45),0 8px 22px rgba(16,24,40,.3)}70%{box-shadow:0 0 0 3px #f3dfae,0 0 0 18px rgba(41,63,87,0),0 8px 22px rgba(16,24,40,.3)}100%{box-shadow:0 0 0 3px #f3dfae,0 8px 22px rgba(16,24,40,.3)}}
.assistant-panel{position:fixed;right:22px;bottom:96px;z-index:960;width:400px;height:min(620px,calc(100vh - 120px));display:flex;flex-direction:column;overflow:hidden;background:#fff;border-radius:16px;box-shadow:0 16px 44px rgba(16,24,40,.28);transform-origin:bottom right;animation:assistantIn .18s ease-out}
.assistant-panel[hidden]{display:none}
.assistant.wide .assistant-panel{width:min(680px,calc(100vw - 44px));height:calc(100vh - 120px)}
@keyframes assistantIn{from{opacity:0;transform:scale(.96) translateY(8px)}}
.assistant-head{flex:none;display:flex;align-items:center;gap:12px;height:68px;padding:0 10px 0 16px;background:var(--brand,#293f57);color:#fff}
.assistant-head button{flex:none;width:38px;height:38px;border:0;border-radius:10px;background:transparent;color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer}
.assistant-head button:hover{background:rgba(255,255,255,.14)}
.assistant-head button svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.assistant-head button[hidden]{display:none}
.assistant-back{margin-left:-8px}
.assistant-avatar{position:relative;flex:none;width:40px;height:40px;border-radius:50%;background:#fff;color:var(--brand,#293f57);display:flex;align-items:center;justify-content:center}
.assistant-avatar svg{width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.assistant-avatar::after{content:"";position:absolute;right:-1px;bottom:-1px;width:11px;height:11px;border-radius:50%;background:#3fb68b;border:2px solid var(--brand,#293f57)}
.assistant-titles{flex:1;min-width:0;line-height:1.25}
.assistant-titles strong{display:block;font-size:1rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.assistant-titles small{display:block;font-size:.75rem;opacity:.78;white-space:nowrap}
.assistant-body{flex:1;overflow:auto;padding:18px 16px 8px;display:flex;flex-direction:column;align-items:flex-start;gap:8px;line-height:1.5;overscroll-behavior:contain}
.assistant-body p{margin:0}
.assistant-msg{max-width:88%;padding:10px 14px;border-radius:16px 16px 16px 5px;background:#f2f4f6;color:#26323e}
.assistant-msg.user{align-self:flex-end;border-radius:16px 16px 5px 16px;background:var(--brand,#293f57);color:#fff}
.assistant-msg.muted{color:#6b7785}
.assistant-msg .assistant-go{margin-top:10px}
.assistant-dots span{display:inline-block;width:7px;height:7px;margin:0 2px;border-radius:50%;background:#9aa5b1;animation:assistantDot 1.2s infinite ease-in-out}
.assistant-dots span:nth-child(2){animation-delay:.15s}.assistant-dots span:nth-child(3){animation-delay:.3s}
@keyframes assistantDot{0%,80%,100%{opacity:.3;transform:translateY(0)}40%{opacity:1;transform:translateY(-3px)}}
.assistant-chips{display:flex;flex-wrap:wrap;gap:6px;margin:2px 0 4px}
.assistant-chips button{border:1px solid #cfd7e0;background:#fff;border-radius:16px;padding:5px 12px;font:inherit;font-size:.82rem;color:var(--brand,#293f57);font-weight:600;cursor:pointer}
.assistant-chips button:hover{border-color:var(--brand,#293f57)}
.assistant-sub{width:100%;margin:6px 0 0!important;font-size:.72rem;font-weight:700;text-transform:uppercase;letter-spacing:.04em;color:#7a8794}
.assistant-go{border:0;border-radius:8px;background:var(--brand,#293f57);color:#fff;font:inherit;font-weight:700;font-size:.82rem;padding:7px 12px;cursor:pointer;text-align:left}
.assistant-msg.user .assistant-go{display:none}
.assistant-go.ghost{background:#eef3f7;color:var(--brand,#293f57)}
.assistant-help{width:100%;box-sizing:border-box;border:1px solid #e3e8ee;border-radius:10px;background:#fff}
.assistant-help summary{cursor:pointer;padding:10px 12px;font-weight:700;color:#1f2a37;list-style:none;display:flex;justify-content:space-between;gap:8px}
.assistant-help summary::-webkit-details-marker{display:none}
.assistant-help summary::after{content:"+";color:var(--brand,#293f57);font-weight:800}
.assistant-help[open] summary::after{content:"–"}
.assistant-help>div{padding:0 12px 10px;font-size:.86rem;line-height:1.55;color:#44515e}.assistant-help>div p{margin:0 0 6px}
.assistant-help ol{margin:0 0 8px;padding-left:18px}.assistant-help li{margin:2px 0}
.assistant-shortcuts{display:flex;flex-wrap:wrap;gap:6px}
.assistant-links{width:100%;display:flex;flex-wrap:wrap;gap:6px 16px;margin:4px 0 0!important;padding-top:10px;border-top:1px solid #eef1f5;font-size:.86rem;font-weight:700}
.assistant-links a{color:var(--brand,#293f57)}
.assistant-form{flex:none;padding:10px 14px 14px;background:#fff}
.assistant-field{display:flex;align-items:center;gap:6px;height:50px;padding:0 6px 0 18px;border:1px solid #b9c3ce;border-radius:25px;background:#fff;transition:border-color .15s}
.assistant-field:focus-within{border-color:var(--brand,#293f57);box-shadow:0 0 0 3px rgba(41,63,87,.12)}
.assistant-field input{flex:1;min-width:0;height:100%;border:0!important;outline:0;box-shadow:none!important;padding:0!important;background:transparent!important;font:inherit;font-size:.95rem;color:#1f2a37;-webkit-appearance:none;appearance:none}
.assistant-field input::-webkit-search-cancel-button{display:none}
.assistant-field button{flex:none;width:38px;height:38px;border:0;border-radius:50%;background:var(--brand,#293f57);color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer}
.assistant-field button svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.assistant-foot{margin:7px 0 0;text-align:center;font-size:.7rem;color:#8a95a1}
.assistant-pulse{outline:3px solid var(--brand,#293f57)!important;outline-offset:4px;border-radius:8px;animation:assistantPulse 1s ease-in-out 3}
@keyframes assistantPulse{50%{outline-color:transparent}}
/* Fenêtre d'accueil : posée au-dessus du bouton rond, qu'elle désigne. */
.assistant-welcome{position:fixed;inset:0;z-index:955;background:rgba(16,24,40,.38);animation:assistantFade .2s ease-out}
.assistant-welcome[hidden]{display:none}
@keyframes assistantFade{from{opacity:0}}
.assistant-welcome-card{position:absolute;right:22px;bottom:100px;width:370px;max-width:calc(100vw - 32px);box-sizing:border-box;background:#fff;border-radius:16px;box-shadow:0 18px 48px rgba(16,24,40,.32);overflow:visible;animation:assistantIn .22s ease-out}
.assistant-welcome-card::after{content:"";position:absolute;right:22px;bottom:-9px;width:18px;height:18px;background:#fff;transform:rotate(45deg);border-radius:0 0 4px 0}
.assistant-welcome-head{display:flex;align-items:center;gap:12px;padding:16px 18px;background:var(--brand,#293f57);color:#fff;border-radius:16px 16px 0 0}
.assistant-welcome-head .assistant-avatar::after{border-color:var(--brand,#293f57)}
.assistant-welcome-head small{display:block;font-size:.72rem;font-weight:700;letter-spacing:.05em;text-transform:uppercase;opacity:.8}
.assistant-welcome-head h2{margin:2px 0 0;font-size:1.08rem;line-height:1.25;color:#fff}
.assistant-welcome-body{padding:16px 18px 18px;line-height:1.55;color:#33404d}
.assistant-welcome-body p{margin:0 0 10px}
.assistant-welcome-body ul{margin:0 0 14px;padding-left:18px}.assistant-welcome-body li{margin:3px 0}
.assistant-welcome-check{display:flex;align-items:center;gap:8px;margin:0 0 14px;font-size:.86rem;color:#55616e;cursor:pointer}
.assistant-welcome-check input{width:17px;height:17px;margin:0;accent-color:var(--brand,#293f57)}
.assistant-welcome-actions{display:flex;justify-content:flex-end;gap:8px}
.assistant-welcome-actions button{height:40px;padding:0 16px;border-radius:10px;font:inherit;font-weight:700;font-size:.85rem;cursor:pointer;border:1px solid #cfd7e0;background:#fff;color:#33404d}
.assistant-welcome-actions button.primary{border-color:var(--brand,#293f57);background:var(--brand,#293f57);color:#fff}
.assistant-welcome-sign{margin:14px 0 0!important;padding-top:10px;border-top:1px solid #eef1f5;font-size:.72rem;font-weight:700;letter-spacing:.04em;color:#8a95a1;text-align:right}
body.assistant-welcoming .assistant-fab{z-index:970;animation:assistantGlow 1.8s ease-out infinite}
@media (max-width:700px){
  .assistant-fab{right:16px;bottom:16px;width:56px;height:56px}
  .assistant.open .assistant-fab{display:none}
  .assistant-panel,.assistant.wide .assistant-panel{inset:0;width:auto;height:auto;border-radius:0;animation:none}
  .assistant-expand{display:none!important}
  .assistant-form{padding-bottom:max(14px,env(safe-area-inset-bottom))}
  .assistant-field input{font-size:16px}
  .assistant-welcome-card{right:16px;bottom:90px}
  .assistant-welcome-card::after{right:19px}
}
@media (prefers-reduced-motion:reduce){.assistant-fab,.assistant-panel,.assistant-welcome,.assistant-welcome-card,body.assistant-welcoming .assistant-fab{animation:none}}
@media print{.assistant,.assistant-welcome{display:none!important}}
.assistant-welcome-body .assistant-welcome-hello{font-weight:700;color:var(--brand,#293f57);font-size:1rem}
/* Administration : le site applique un espacement à toutes les « section » ; pas dans le panneau de l’assistant. */
.assistant .assistant-panel{padding:0;margin:0}
