.as-vchat {
  --as-vchat-primary: #133b63;
  --as-vchat-accent: #c49a5a;
  --as-vchat-text: #17212b;
  position: fixed;
  z-index: 1080;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  font-family: inherit;
  color: var(--as-vchat-text);
}
.as-vchat[hidden] { display: none !important; }
.as-vchat-launcher {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 10px 18px 10px 14px;
  color: #fff;
  background: var(--as-vchat-primary);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 12px 32px rgba(19, 59, 99, .28);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease;
}
.as-vchat-launcher:hover { transform: translateY(-2px); box-shadow: 0 15px 36px rgba(19, 59, 99, .34); }
.as-vchat-launcher:focus-visible, .as-vchat button:focus-visible, .as-vchat input:focus-visible,
.as-vchat select:focus-visible, .as-vchat textarea:focus-visible, .as-vchat a:focus-visible {
  outline: 3px solid rgba(196, 154, 90, .6);
  outline-offset: 2px;
}
.as-vchat-launcher-icon { display: grid; place-items: center; }
.as-vchat-launcher > .bi-headphones { flex: 0 0 auto; font-size: 1.15rem; line-height: 1; }
.as-vchat-toggle-chevron {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform .18s ease;
}
.as-vchat-launcher[aria-expanded="true"] .as-vchat-toggle-chevron { transform: rotate(180deg); }
.as-vchat-unread {
  position: absolute;
  top: -4px;
  right: -2px;
  min-width: 22px;
  height: 22px;
  padding: 2px 6px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #c0392b;
  color: #fff;
  font-size: 12px;
  line-height: 16px;
  text-align: center;
}
.as-vchat-panel {
  position: absolute;
  right: 0;
  bottom: 72px;
  display: flex;
  flex-direction: column;
  width: min(390px, calc(100vw - 28px));
  max-height: min(680px, calc(100vh - 120px));
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(19, 59, 99, .12);
  border-radius: 0;
  box-shadow: 0 24px 65px rgba(13, 31, 48, .22);
}
.as-vchat-panel[hidden] { display: none !important; }
.as-vchat-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 18px 16px;
  color: #fff;
  background: linear-gradient(135deg, #133b63, #1d527f);
}
.as-vchat-header strong { font-size: 17px; }
.as-vchat-header small { display: block; margin: 3px 0 0 17px; color: rgba(255,255,255,.82); }
.as-vchat-status-dot { display: inline-block; width: 10px; height: 10px; margin-right: 7px; border-radius: 50%; background: #5fdb84; box-shadow: 0 0 0 3px rgba(95,219,132,.2); }
.as-vchat-close { display: grid; place-items: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%; color: #fff; background: rgba(255,255,255,.12); cursor: pointer; }
.as-vchat-close svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.as-vchat-content { min-height: 0; overflow-y: auto; background: #f7f8fa; }
.as-vchat-welcome { margin: 16px 16px 12px; padding: 12px 14px; border-radius: 14px 14px 14px 4px; background: #fff; box-shadow: 0 2px 10px rgba(13,31,48,.06); font-size: 14px; line-height: 1.5; }
.as-vchat-lead-form { padding: 0 16px 18px; }
.as-vchat-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.as-vchat-field { margin-bottom: 10px; }
.as-vchat-field label { display: block; margin-bottom: 4px; font-size: 12px; font-weight: 700; }
.as-vchat-field input, .as-vchat-field select, .as-vchat-field textarea {
  display: block;
  width: 100%;
  padding: 10px 11px;
  color: #17212b;
  background: #fff;
  border: 1px solid #cfd6dd;
  border-radius: 9px;
  font: inherit;
  font-size: 14px;
  box-sizing: border-box;
}
.as-vchat-field textarea { resize: vertical; }
.as-vchat-hp { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.as-vchat-consent { display: flex; align-items: flex-start; gap: 8px; margin: 4px 0 12px; font-size: 11px; line-height: 1.35; color: #52606d; }
.as-vchat-consent input { flex: 0 0 auto; margin-top: 2px; }
.as-vchat-consent a { color: var(--as-vchat-primary); }
.as-vchat-primary { width: 100%; padding: 11px 16px; border: 0; border-radius: 10px; color: #fff; background: var(--as-vchat-primary); font: inherit; font-weight: 700; cursor: pointer; }
.as-vchat-primary:disabled, .as-vchat-compose button:disabled { opacity: .55; cursor: wait; }
.as-vchat-error { min-height: 0; margin: 0 0 8px; color: #a5271b; font-size: 12px; }
.as-vchat-conversation { padding-bottom: 14px; }
.as-vchat-conversation[hidden] { display: none !important; }
.as-vchat-messages { display: flex; flex-direction: column; gap: 9px; max-height: 310px; min-height: 120px; padding: 4px 16px 12px; overflow-y: auto; }
.as-vchat-closed { display: flex; min-height: 150px; padding: 24px 18px; align-items: center; justify-content: center; flex-direction: column; gap: 8px; color: #334454; background: #fff; border: 1px solid #d8e2ea; text-align: center; }
.as-vchat-closed strong { color: var(--as-vchat-primary); font-size: 16px; }
.as-vchat-closed span { max-width: 280px; font-size: 14px; line-height: 1.5; }
.as-vchat-new-question { margin-top: 8px; padding: 10px 15px; border: 0; border-radius: 9px; color: #fff; background: var(--as-vchat-primary); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.as-vchat-new-question:disabled { opacity: .55; cursor: wait; }
.as-vchat-closed-feedback { max-width: 280px; color: #a5271b; font-size: 12px; line-height: 1.4; }
.as-vchat-message { max-width: 82%; padding: 10px 12px; border-radius: 14px; font-size: 14px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.as-vchat-message.is-visitor { align-self: flex-end; color: #fff; background: var(--as-vchat-primary); border-bottom-right-radius: 4px; }
.as-vchat-message.is-admin { align-self: flex-start; background: #fff; border-bottom-left-radius: 4px; box-shadow: 0 2px 9px rgba(13,31,48,.07); }
.as-vchat-response-note { margin: 0 16px 9px; color: #64717d; font-size: 11px; text-align: center; }
.as-vchat-compose { display: flex; align-items: flex-end; gap: 8px; margin: 0 12px; padding: 8px; border: 1px solid #d7dde3; border-radius: 14px; background: #fff; }
.as-vchat-compose textarea { flex: 1; max-height: 90px; padding: 5px; border: 0; outline: 0; resize: none; font: inherit; font-size: 14px; }
.as-vchat-compose button { display: grid; place-items: center; flex: 0 0 auto; width: 38px; height: 38px; padding: 0; border: 0; border-radius: 50%; color: #fff; background: var(--as-vchat-primary); cursor: pointer; }
.as-vchat-signup { display: block; margin: 11px 16px 0; color: var(--as-vchat-primary); font-size: 12px; font-weight: 700; text-align: center; }
@media (max-width: 575.98px) {
  .as-vchat { right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); }
  .as-vchat-launcher-label { display: none; }
  .as-vchat-launcher { width: auto; min-width: 84px; padding: 0 18px; justify-content: center; }
  .as-vchat-panel { position: fixed; inset: 10px 10px 82px; width: auto; max-height: none; border-radius: 0; }
  .as-vchat-field-row { grid-template-columns: 1fr; gap: 0; }
  .as-vchat-messages { max-height: none; flex: 1; }
  .as-vchat-content { display: flex; flex-direction: column; }
  .as-vchat-conversation:not([hidden]) { display: flex; flex: 1; min-height: 0; flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) { .as-vchat-launcher { transition: none; } }
