#faqcb-root {
  --c: var(--faqcb-color, #6d28d9);
  --faqcb-ink: #29282c;
  --faqcb-muted: #69666c;
  --faqcb-soft: #817d83;
  --faqcb-line: #e6e2e1;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
#faqcb-root * { box-sizing: border-box; }
.faqcb-toggle {
  position: fixed; bottom: 20px; width: 58px; height: 58px; border: 0; border-radius: 50%;
  background: var(--c); color: #fff; font-size: 26px; cursor: pointer;
  box-shadow: 0 6px 18px rgba(0,0,0,.25); z-index: 99999;
}
.faqcb-right .faqcb-toggle { right: 20px; }
.faqcb-left .faqcb-toggle { left: 20px; }
.faqcb-panel {
  position: fixed; bottom: 20px; width: 480px; max-width: calc(100vw - 24px); height: min(900px, calc(100vh - 40px));
  display: none; flex-direction: column; background: #fff; border: 1px solid var(--faqcb-line); border-radius: 24px;
  overflow: hidden; box-shadow: 0 10px 36px rgba(25,18,30,.2); z-index: 99999;
}
.faqcb-right .faqcb-panel { right: 20px; }
.faqcb-left .faqcb-panel { left: 20px; }
.faqcb-panel::before { content: ""; position: absolute; z-index: 1; inset: 0 0 auto; height: 4px; background: var(--c); }
.faqcb-panel.faqcb-open { display: flex; }
.faqcb-header { flex: 0 0 auto; background: #fff; color: var(--faqcb-ink); padding-top: 4px; }
.faqcb-topbar { height: 58px; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; }
.faqcb-brand, .faqcb-actions, .faqcb-profile { display: flex; align-items: center; }
.faqcb-brand { gap: 10px; min-width: 0; }
.faqcb-brand-mark { color: var(--c); font-size: 26px; font-weight: 700; line-height: 1; }
.faqcb-brand-name { overflow: hidden; color: var(--faqcb-ink); font-size: 14px; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }
.faqcb-actions { gap: 16px; }
.faqcb-minimize, .faqcb-close { width: 24px; height: 30px; padding: 0; border: 0; background: transparent; color: var(--faqcb-muted); font-size: 28px; line-height: 1; cursor: pointer; }
.faqcb-profile { min-height: 90px; padding: 8px 24px 20px; gap: 14px; }
.faqcb-avatar { width: 58px; height: 58px; flex: 0 0 58px; display: grid; place-items: center; border-radius: 50%; background: #fcf0f1; color: var(--c); font: italic 40px Georgia, serif; }
.faqcb-identity { min-width: 0; flex: 1; }
.faqcb-agent-name { color: var(--faqcb-ink); font-size: 26px; line-height: 1.2; }
.faqcb-agent-status { margin-top: 4px; color: #34775d; font-size: 14px; }
.faqcb-more { color: var(--faqcb-muted); font-size: 19px; letter-spacing: 2px; }
.faqcb-context { min-height: 41px; flex: 0 0 auto; display: flex; align-items: center; gap: 11px; padding: 0 24px; border-top: 1px solid var(--faqcb-line); border-bottom: 1px solid var(--faqcb-line); background: #faf9f8; color: var(--faqcb-muted); font-size: 14px; }
.faqcb-context-mark { color: var(--c); font-size: 20px; font-weight: 700; }
.faqcb-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 24px; background: #faf9f8; }
.faqcb-date { display: flex; align-items: center; gap: 14px; margin: 0 0 24px; color: var(--faqcb-soft); font-size: 12px; }
.faqcb-date::before, .faqcb-date::after { content: ""; height: 1px; flex: 1; background: var(--faqcb-line); }
.faqcb-intro { margin: 0 0 22px; }
.faqcb-intro-title { color: var(--faqcb-ink); font-size: clamp(25px, 7vw, 34px); line-height: 1.2; }
.faqcb-intro-copy { margin-top: 10px; color: var(--faqcb-muted); font-size: 17px; line-height: 1.5; }
.faqcb-message { max-width: 100%; margin: 0 0 14px; }
.faqcb-message-bot { width: min(100%, 375px); }
.faqcb-sender, .faqcb-time { color: var(--faqcb-soft); font-size: 12px; }
.faqcb-sender { margin-bottom: 6px; }
.faqcb-time { margin-top: 7px; }
.faqcb-msg { margin: 0; padding: 14px 17px; border-radius: 0 17px 17px 17px; font-size: 17px; line-height: 1.45; white-space: pre-line; overflow-wrap: anywhere; }
.faqcb-bot { background: var(--c); color: #fff; }
.faqcb-user { width: fit-content; max-width: 88%; margin-left: auto; border-radius: 17px 17px 0 17px; background: #ece8f3; color: var(--faqcb-ink); }
.faqcb-typing { font-style: italic; opacity: .8; }
.faqcb-options { flex: 0 0 auto; max-height: 38%; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 14px 18px 18px; border-top: 1px solid var(--faqcb-line); background: #fff; }
.faqcb-form { display: flex; flex-direction: column; gap: 9px; }
.faqcb-input { width: 100%; min-height: 48px; border: 1px solid var(--faqcb-line); border-radius: 10px; padding: 11px 13px; background: #fff; font: inherit; font-size: 15px; color: var(--faqcb-ink); resize: vertical; }
.faqcb-input:focus { outline: 2px solid var(--c); outline-offset: 1px; }
.faqcb-input-invalid { border-color: #b42318; }
.faqcb-input-invalid:focus { outline-color: #b42318; }
.faqcb-field-error { padding: 10px 12px; border: 1px solid #f0b8b3; border-radius: 10px; background: #fff4f2; color: #8f1d14; font-size: 13px; line-height: 1.45; }
.faqcb-field-error[hidden] { display: none; }
.faqcb-checkbox { width: 21px; height: 21px; flex: 0 0 21px; margin: 1px 0 0; accent-color: var(--c); cursor: pointer; }
.faqcb-consent-form { gap: 10px; }
.faqcb-consent-label { display: flex; align-items: flex-start; gap: 11px; padding: 13px 14px; border: 1px solid var(--faqcb-line); border-radius: 12px; background: #fff; color: var(--faqcb-ink); cursor: pointer; }
.faqcb-consent-label.faqcb-consent-checked { border-color: var(--c); background: #f6f1ff; }
.faqcb-consent-text { font-size: 14px; line-height: 1.45; }
.faqcb-consent-note { padding-left: 2px; color: var(--faqcb-muted); font-size: 12px; line-height: 1.4; }
.faqcb-consent-submit { align-self: stretch; min-height: 46px; font-size: 15px; }
.faqcb-consent-submit:disabled { background: #d7d3dc; color: #fff; opacity: 1; cursor: not-allowed; }
.faqcb-submit { align-self: flex-end; border: 0; border-radius: 10px; background: var(--c); color: #fff; padding: 11px 17px; font-size: 14px; cursor: pointer; }
.faqcb-submit:disabled { opacity: .65; cursor: wait; }
.faqcb-option { text-align: left; background: #fff; border: 1px solid var(--c); color: var(--c); padding: 10px 14px; border-radius: 14px; font-size: 14px; cursor: pointer; }
.faqcb-option:hover { background: var(--c); color: #fff; }
@media (max-width: 520px) {
  .faqcb-panel { inset: 0; width: 100%; height: 100dvh; max-width: none; border-radius: 0; }
  .faqcb-right .faqcb-panel, .faqcb-left .faqcb-panel { right: auto; left: 0; }
  .faqcb-body { padding: 20px; }
}
@media (min-width: 521px) and (max-height: 700px) {
  .faqcb-panel { height: calc(100vh - 32px); bottom: 16px; }
  .faqcb-right .faqcb-panel { right: 16px; }
  .faqcb-left .faqcb-panel { left: 16px; }
}

