/* ── TRỢ LÝ ARDIGUN (chatbot) ── màu theo hệ màu site: xanh #1565c0 / #29b6f6, nền tối #0a1628 */
/* Vị trí và cỡ nút theo cụm nút nổi (biến --fab… trong site.css) */
.ac-launcher { right: var(--fab-right); bottom: calc(var(--fab-bottom) + 2 * (var(--fab) + var(--fab-gap))); width: var(--fab); height: var(--fab); }
.ac-launcher { position: fixed; z-index: 10000; border-radius: 50%; border: 0; cursor: pointer;
  background: linear-gradient(135deg, #1565c0, #29b6f6); color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(21,101,192,.5); transition: transform .2s; }
.ac-launcher:hover { transform: scale(1.08); }
.ac-launcher-dot { position: absolute; top: 4px; right: 4px; width: 12px; height: 12px; border-radius: 50%; background: #22c55e; border: 2px solid #fff; }
.ac-panel[hidden] { display: none; }
.ac-panel { position: fixed; right: 24px; bottom: 24px; z-index: 10001; width: 380px; max-width: calc(100vw - 24px); height: min(620px, calc(100vh - 48px));
  display: flex; flex-direction: column; background: #0a1628; color: #e8eef8; border: 1px solid rgba(41,182,246,.25); border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0,0,0,.5); overflow: hidden; font-family: "Source Sans 3", "Be Vietnam Pro", system-ui, sans-serif; }
.ac-head { display: flex; align-items: center; gap: 10px; padding: 14px 12px 14px 16px; background: #060e1c; border-bottom: 1px solid rgba(255,255,255,.07); }
.ac-avatar { width: 40px; height: 40px; border-radius: 50%; background: #fff; padding: 3px; object-fit: contain; flex-shrink: 0; }
.ac-head-text { flex: 1; min-width: 0; }
.ac-name { font-family: "Barlow", sans-serif; font-weight: 800; font-size: 17px; color: #fff; }
.ac-status { font-size: 12.5px; color: rgba(232,238,248,.7); display: flex; align-items: center; gap: 6px; }
.ac-online { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; flex-shrink: 0; }
.ac-icon-btn { background: none; border: 0; color: #cfd9ea; width: 36px; height: 36px; border-radius: 8px; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.ac-icon-btn:hover { background: rgba(255,255,255,.08); color: #fff; }
.ac-body { flex: 1; overflow-y: auto; padding: 16px 14px 8px; display: flex; flex-direction: column; gap: 10px; scroll-behavior: smooth; }
.ac-msg { max-width: 88%; padding: 10px 14px; border-radius: 14px; font-size: 15px; line-height: 1.5; white-space: pre-line; word-wrap: break-word; }
.ac-msg.bot { align-self: flex-start; background: #112a52; border: 1px solid rgba(41,182,246,.2); border-top-left-radius: 4px; }
.ac-msg.user { align-self: flex-end; background: linear-gradient(135deg, #1565c0, #1e88e5); color: #fff; border-top-right-radius: 4px; }
.ac-msg a { color: #7fd3fb; text-decoration: underline; font-weight: 600; }
.ac-msg b { color: #fff; }
.ac-msg .ac-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 8px 0 4px; white-space: normal; }
.ac-msg .ac-kpi { background: rgba(255,255,255,.06); border-radius: 8px; padding: 6px 8px; font-size: 12.5px; color: rgba(232,238,248,.75); }
.ac-msg .ac-kpi b { display: block; font-size: 16px; color: #29b6f6; }
.ac-typing { align-self: flex-start; display: flex; gap: 4px; padding: 12px 14px; background: #112a52; border-radius: 14px; }
.ac-typing span { width: 7px; height: 7px; border-radius: 50%; background: #7fd3fb; animation: acDot 1s infinite; }
.ac-typing span:nth-child(2) { animation-delay: .15s; } .ac-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes acDot { 0%, 80%, 100% { opacity: .3; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
.ac-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 6px 14px 10px; }
.ac-chip { border: 1px solid rgba(41,182,246,.5); background: rgba(21,101,192,.12); color: #e8eef8; border-radius: 999px; padding: 7px 13px; font-size: 13.5px; cursor: pointer; font-family: inherit; text-align: left; }
.ac-chip:hover { background: rgba(41,182,246,.22); border-color: #29b6f6; }
.ac-contact { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 0 14px 10px; }
.ac-contact-btn { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px; border-radius: 10px; background: #112240; border: 1px solid rgba(255,255,255,.1); color: #fff; font-weight: 700; font-size: 14px; text-decoration: none; }
.ac-contact-btn:hover { border-color: #29b6f6; }
.ac-zalo { background: #0068ff; color: #fff; font-size: 11px; font-weight: 800; padding: 2px 6px; border-radius: 5px; }
.ac-form { display: flex; gap: 8px; padding: 10px 14px; border-top: 1px solid rgba(255,255,255,.07); }
.ac-form input { flex: 1; min-width: 0; background: #0f1f3a; border: 1px solid rgba(255,255,255,.15); color: #fff; border-radius: 12px; padding: 12px 14px; font-size: 15px; font-family: inherit; outline: none; }
.ac-form input:focus { border-color: #29b6f6; }
.ac-send { width: 48px; border: 0; border-radius: 12px; background: linear-gradient(135deg, #1565c0, #29b6f6); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.ac-send:disabled { opacity: .5; cursor: default; }
.ac-note { font-size: 11.5px; color: rgba(232,238,248,.55); padding: 0 14px 12px; line-height: 1.4; }
.ac-note a { color: #7fd3fb; }
@media (max-width: 600px) {
  .ac-panel { right: 0; bottom: 0; width: 100vw; max-width: 100vw; height: 100%; height: 100dvh; border-radius: 0; border: 0; }
}
