/* Edventa website assistant — Edventa logo colours: violet #5A43E9, grey #808285, sky #29B2E5, ink #15123B */
.edbot { --bV: #5A43E9; --bV2: #7B68F0; --bS: #29B2E5; --bInk: #15123B; --bLine: #E6DEFF;
  position: fixed; right: 20px; bottom: 20px; z-index: 950; font-family: var(--sans, system-ui, sans-serif); }
.edbot-launch { display: flex; align-items: center; gap: 10px; padding: 7px 16px 7px 7px; border: 0; border-radius: 999px; cursor: pointer;
  background: linear-gradient(100deg, #15123B, #2A2070); color: #fff; text-align: left;
  box-shadow: 0 14px 30px -12px rgba(21,18,59,.7), inset 0 1px 0 rgba(255,255,255,.14), inset 0 0 0 1px rgba(90,67,233,.5); transition: transform .2s; }
.edbot-launch:hover { transform: translateY(-2px); }
.edbot-launch-ic { position: relative; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--bV); }
.edbot-launch-ic::after { content: ""; position: absolute; right: 1px; top: 1px; width: 9px; height: 9px; border-radius: 50%; background: #22c55e; border: 2px solid #15123B; }
.edbot-launch-tx b { display: block; font: 700 .9rem/1.1 var(--sans, system-ui, sans-serif); }
.edbot-launch-tx small { display: block; font: 400 .7rem/1.3 var(--sans, system-ui, sans-serif); color: #BCB8E6; }
.edbot.is-open .edbot-launch { display: none; }

.edbot-panel { position: absolute; right: 0; bottom: 0; width: min(380px, calc(100vw - 24px)); height: min(580px, calc(100vh - 110px));
  display: flex; flex-direction: column; background: #fff; border-radius: 22px; overflow: hidden;
  border: 1px solid var(--bLine); box-shadow: 0 30px 70px -24px rgba(21,18,59,.55); animation: edbotIn .25s ease both; }
.edbot-panel[hidden] { display: none; }
@keyframes edbotIn { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }

.edbot-head { display: flex; align-items: center; gap: 10px; padding: 12px 12px 12px 14px; background: linear-gradient(100deg, #15123B, #2A2070); color: #fff; }
.edbot-av { position: relative; flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--bV); }
.edbot-av i { position: absolute; right: 0; bottom: 0; width: 9px; height: 9px; border-radius: 50%; background: #22c55e; border: 2px solid #15123B; }
.edbot-who { flex: 1; min-width: 0; }
.edbot-who b { display: block; font: 700 .92rem/1.2 var(--sans, system-ui, sans-serif); }
.edbot-who small { display: block; font: 400 .7rem/1.3 var(--sans, system-ui, sans-serif); color: #BCB8E6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.edbot-wa { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 7px 10px; border-radius: 999px; background: #25D366; color: #fff !important;
  font: 700 .72rem/1 var(--sans, system-ui, sans-serif); text-decoration: none !important; box-shadow: 0 6px 14px -6px rgba(37,211,102,.8); }
.edbot-wa:hover { background: #1ebe5b; }
.edbot-wa svg { width: 14px; height: 14px; }
.edbot.has-lead .edbot-wa { animation: edbotPulse 1.8s ease-in-out 3; }
@keyframes edbotPulse { 50% { box-shadow: 0 0 0 6px rgba(37,211,102,.25); } }
.edbot-x { flex: none; width: 30px; height: 30px; border: 0; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; font-size: 1.3rem; line-height: 1; cursor: pointer; }
.edbot-x:hover { background: rgba(255,255,255,.2); }

.edbot-log { flex: 1; overflow-y: auto; padding: 16px 14px; display: flex; flex-direction: column; gap: 10px; background: #F7F5FF; overscroll-behavior: contain; }
.edbot-msg { max-width: 86%; padding: 10px 13px; border-radius: 16px; font: 400 .88rem/1.5 var(--sans, system-ui, sans-serif); word-wrap: break-word; }
.edbot-msg.is-bot { align-self: flex-start; background: #fff; color: #1d1640; border: 1px solid var(--bLine); border-bottom-left-radius: 6px; }
.edbot-msg.is-me { align-self: flex-end; background: var(--bV); color: #fff; border-bottom-right-radius: 6px; white-space: pre-wrap; }
.edbot-msg a { color: var(--bV); font-weight: 600; overflow-wrap: anywhere; }
.edbot-typing { display: inline-flex; gap: 4px; padding: 13px 14px; }
.edbot-typing i { width: 6px; height: 6px; border-radius: 50%; background: #B7AEEA; animation: edbotDot 1s infinite; }
.edbot-typing i:nth-child(2) { animation-delay: .15s; } .edbot-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes edbotDot { 50% { transform: translateY(-4px); background: var(--bV); } }
.edbot-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.edbot-chips button { border: 1px solid #CFC4FF; background: #fff; color: #4B2E83; border-radius: 999px; padding: 7px 11px; font: 600 .76rem/1 var(--sans, system-ui, sans-serif); cursor: pointer; }
.edbot-chips button:hover { background: var(--bV); color: #fff; border-color: var(--bV); }

.edbot-form { display: flex; align-items: flex-end; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--bLine); background: #fff; }
.edbot-form textarea { flex: 1; resize: none; border: 1px solid var(--bLine); border-radius: 14px; padding: 10px 12px; font: 400 .9rem/1.4 var(--sans, system-ui, sans-serif); color: #1d1640; max-height: 110px; outline: none; background: #FBFAFF; }
.edbot-form textarea:focus { border-color: var(--bV2); box-shadow: 0 0 0 3px rgba(90,67,233,.12); }
.edbot-form button { flex: none; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--bV); color: #fff; display: grid; place-items: center; cursor: pointer; }
.edbot-form button:disabled { opacity: .5; cursor: default; }
.edbot-note { margin: 0; padding: 0 12px 9px; background: #fff; font: 400 .66rem/1.4 var(--sans, system-ui, sans-serif); color: #8a85a3; text-align: center; }
.edbot-note a { color: #6C44D9; }
.edbot .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

@media (max-width: 560px) {
  .edbot { right: 12px; bottom: 12px; }
  .edbot-launch { padding: 6px; }
  .edbot-launch-tx { display: none; }
  .edbot.is-open { left: 0; right: 0; bottom: 0; }
  .edbot-panel { width: 100vw; height: 100dvh; max-height: 100dvh; border-radius: 0; position: fixed; inset: 0; }
  .edbot-wa span { display: none; }
  .edbot-wa { padding: 8px; }
}
@media print { .edbot { display: none; } }

html.bk-open .edbot { display: none; }
.edbot.is-open ~ .to-top, body:has(.edbot.is-open) .to-top { opacity: 0 !important; pointer-events: none !important; }