/* Maison Orsine · Assistant « Questions a l'horloger » (outil VII).
   Meme rendu sur l'accueil (nuit) et sur les pages d'outils (ivoire). */

.as-launch {
  position: fixed; right: 24px; bottom: 24px; z-index: 70;
  display: inline-flex; align-items: center; gap: 12px; padding: 15px 22px;
  background: rgba(12, 20, 36, 0.94); color: #ECE6DA; border: 1px solid rgba(198, 166, 103, 0.35);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  font-family: "Inter Tight", "Helvetica Neue", Arial, sans-serif; font-size: 11px; font-weight: 500; letter-spacing: 0.22em; text-transform: uppercase;
  cursor: pointer; box-shadow: 0 16px 40px -12px rgba(7, 11, 20, 0.55);
  transition: border-color 0.3s ease, transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.as-launch:hover { border-color: #C6A667; transform: translateY(-2px); }
.as-launch__dot { width: 7px; height: 7px; border-radius: 50%; background: #C6A667; box-shadow: 0 0 0 4px rgba(198, 166, 103, 0.22); animation: asPulse 2.6s ease-in-out infinite; }
.as-launch.is-open .as-launch__dot { animation: none; }
@keyframes asPulse { 0%, 100% { box-shadow: 0 0 0 4px rgba(198, 166, 103, 0.22); } 50% { box-shadow: 0 0 0 8px rgba(198, 166, 103, 0.06); } }

.as-panel {
  position: fixed; right: 24px; bottom: 88px; z-index: 71;
  width: min(400px, calc(100vw - 32px)); height: min(600px, calc(100vh - 120px)); height: min(600px, calc(100dvh - 120px));
  display: flex; flex-direction: column;
  background: #0C1424; color: #ECE6DA; border: 1px solid rgba(198, 166, 103, 0.3);
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.6);
  font-family: "Inter Tight", "Helvetica Neue", Arial, sans-serif; font-weight: 300;
  animation: asIn 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.as-panel[hidden] { display: none; }
@keyframes asIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.as-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 20px 22px 18px; border-bottom: 1px solid rgba(198, 166, 103, 0.22); }
.as-head__kicker { margin: 0; font-size: 10px; font-weight: 500; letter-spacing: 0.26em; text-transform: uppercase; color: #C6A667; }
.as-head__title { margin: 6px 0 0; font-family: "Cormorant", Garamond, serif; font-size: 24px; font-weight: 400; line-height: 1.1; }
.as-close { background: none; border: 1px solid rgba(198, 166, 103, 0.3); color: #ECE6DA; width: 34px; height: 34px; font-size: 20px; line-height: 1; cursor: pointer; }
.as-close:hover { border-color: #C6A667; color: #E2CC9A; }

.as-log { flex: 1; overflow-y: auto; padding: 20px 22px; display: flex; flex-direction: column; gap: 12px; overscroll-behavior: contain; }
.as-msg { max-width: 92%; font-size: 14.5px; line-height: 1.6; }
.as-msg p { margin: 0; }
.as-msg p + p, .as-msg p + .as-actions { margin-top: 10px; }
.as-msg--atelier { align-self: flex-start; color: #ECE6DA; padding-left: 14px; border-left: 1px solid #C6A667; }
.as-msg--moi { align-self: flex-end; background: rgba(198, 166, 103, 0.14); border: 1px solid rgba(198, 166, 103, 0.28); padding: 10px 14px; color: #F5F0E6; }
.as-actions { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.as-action { font-size: 11px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: #C6A667; text-decoration: none; border-bottom: 1px solid rgba(198, 166, 103, 0.35); padding-bottom: 3px; }
.as-action:hover { color: #E2CC9A; }
.as-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.as-chip { background: none; border: 1px solid rgba(198, 166, 103, 0.3); color: #C9CFDA; padding: 8px 12px; font-family: inherit; font-size: 13px; font-weight: 300; text-align: left; cursor: pointer; transition: border-color 0.3s ease, color 0.3s ease; }
.as-chip:hover { border-color: #C6A667; color: #F5F0E6; }
.as-typing { display: inline-flex; gap: 5px; padding: 6px 0; }
.as-typing i { width: 5px; height: 5px; border-radius: 50%; background: #C6A667; animation: asDot 1s ease-in-out infinite; }
.as-typing i:nth-child(2) { animation-delay: 0.15s; }
.as-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes asDot { 0%, 100% { opacity: 0.25; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-3px); } }

.as-relais { display: flex; gap: 8px; margin-top: 12px; }
.as-form { display: flex; border-top: 1px solid rgba(198, 166, 103, 0.22); }
.as-input { flex: 1; min-width: 0; background: transparent; border: 0; color: #F5F0E6; font-family: inherit; font-size: 15px; font-weight: 300; padding: 16px 22px; }
.as-input::placeholder { color: #7F8899; }
.as-input:focus { outline: none; background: rgba(198, 166, 103, 0.05); }
.as-input--email { border: 1px solid rgba(198, 166, 103, 0.3); padding: 10px 12px; font-size: 14px; }
.as-input--email.is-err { border-color: #D98C6A; }
.as-relais__btn { background: #C6A667; color: #070B14; border: 0; padding: 0 14px; font-family: inherit; font-size: 10.5px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; cursor: pointer; }
.as-relais__btn:hover { background: #E2CC9A; }
.as-send { width: 58px; background: none; border: 0; border-left: 1px solid rgba(198, 166, 103, 0.22); color: #C6A667; font-size: 20px; cursor: pointer; }
.as-send:hover { background: rgba(198, 166, 103, 0.1); }
.as-foot { margin: 0; padding: 9px 22px 11px; font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: #6F7888; border-top: 1px solid rgba(198, 166, 103, 0.12); }
.as-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.as-launch:focus-visible, .as-panel button:focus-visible, .as-panel a:focus-visible { outline: 1px solid #C6A667; outline-offset: 3px; }

@media (max-width: 560px) {
  .as-launch { right: 16px; bottom: 16px; padding: 13px 18px; }
  .as-panel { right: 8px; left: 8px; bottom: 76px; width: auto; height: calc(100dvh - 96px); }
}
@media (prefers-reduced-motion: reduce) {
  .as-launch__dot, .as-typing i, .as-panel { animation: none !important; }
}
