.abc-help-assistant {
  --abc-help-primary: var(--bs-primary, #5a8dee);
  --abc-help-primary-rgb: var(--bs-primary-rgb, 90, 141, 238);
  --abc-help-surface: var(--bs-body-bg, #fff);
  --abc-help-muted: var(--bs-secondary-color, #6c757d);
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 1095;
  font-family: inherit;
}

.abc-help-launcher {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 50px;
  padding: 0 1.05rem;
  color: #fff;
  background: var(--abc-help-primary);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(var(--abc-help-primary-rgb), 0.3);
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.abc-help-launcher:hover,
.abc-help-launcher:focus-visible {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(var(--abc-help-primary-rgb), 0.38);
}

.abc-help-launcher i {
  font-size: 1.15rem;
}

.abc-help-panel {
  position: fixed;
  right: 24px;
  bottom: 88px;
  display: flex;
  flex-direction: column;
  width: min(400px, calc(100vw - 32px));
  height: min(660px, calc(100vh - 116px));
  overflow: hidden;
  background: var(--abc-help-surface);
  border: 1px solid rgba(var(--abc-help-primary-rgb), 0.18);
  border-radius: 1rem;
  box-shadow: 0 20px 60px rgba(34, 48, 62, 0.22);
}

.abc-help-panel[hidden] {
  display: none !important;
}

.abc-help-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 72px;
  padding: 0.85rem 1rem;
  color: #fff;
  background: var(--abc-help-primary);
}

.abc-help-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.abc-help-heading {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.abc-help-heading strong {
  font-size: 1rem;
}

.abc-help-heading small {
  color: rgba(255, 255, 255, 0.8);
}

.abc-help-icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  color: #fff;
  background: transparent;
  border: 0;
  border-radius: 50%;
}

.abc-help-icon-button:hover,
.abc-help-icon-button:focus-visible {
  background: rgba(255, 255, 255, 0.16);
}

.abc-help-status {
  min-height: 0;
  padding: 0 1rem;
  color: var(--abc-help-muted);
  background: var(--abc-help-surface);
  font-size: 0.75rem;
}

.abc-help-status:not(:empty) {
  padding-top: 0.45rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--bs-border-color, #e7e7e8);
}

.abc-help-messages {
  flex: 1 1 auto;
  min-height: 0;
  padding: 1rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: rgba(var(--abc-help-primary-rgb), 0.035);
}

.abc-help-message {
  display: flex;
  margin-bottom: 0.85rem;
}

.abc-help-message.is-user {
  justify-content: flex-end;
}

.abc-help-bubble {
  max-width: 88%;
  padding: 0.75rem 0.85rem;
  color: var(--bs-body-color, #566a7f);
  background: var(--abc-help-surface);
  border: 1px solid var(--bs-border-color, #e7e7e8);
  border-radius: 0.9rem 0.9rem 0.9rem 0.25rem;
  box-shadow: 0 4px 14px rgba(34, 48, 62, 0.06);
  line-height: 1.45;
}

.abc-help-message.is-user .abc-help-bubble {
  color: #fff;
  background: var(--abc-help-primary);
  border-color: var(--abc-help-primary);
  border-radius: 0.9rem 0.9rem 0.25rem 0.9rem;
}

.abc-help-bubble p:last-child,
.abc-help-bubble ul:last-child {
  margin-bottom: 0;
}

.abc-help-result {
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--bs-border-color, #e7e7e8);
}

.abc-help-result:first-of-type {
  margin-top: 0.4rem;
}

.abc-help-result-title {
  display: block;
  margin-bottom: 0.15rem;
  color: var(--bs-heading-color, #32475c);
  font-weight: 700;
}

.abc-help-result-section {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--abc-help-muted);
  font-size: 0.75rem;
}

.abc-help-result ol {
  margin: 0.5rem 0 0;
  padding-left: 1.15rem;
}

.abc-help-result li + li {
  margin-top: 0.2rem;
}

.abc-help-result-detail {
  margin-top: 0.65rem;
}

.abc-help-result-detail ul {
  margin: 0.3rem 0 0;
  padding-left: 1.15rem;
}

.abc-help-result-note {
  margin-top: 0.5rem;
  color: var(--abc-help-muted);
  font-size: 0.8rem;
}

.abc-help-result-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.65rem;
  color: var(--abc-help-primary);
  font-weight: 700;
}

.abc-help-result-link + .abc-help-result-link {
  margin-left: 0.75rem;
}

.abc-help-training-link {
  color: var(--abc-help-primary);
}

.abc-help-suggestions {
  display: flex;
  flex: 0 0 auto;
  gap: 0.45rem;
  padding: 0.7rem 0.85rem;
  overflow-x: auto;
  background: var(--abc-help-surface);
  border-top: 1px solid var(--bs-border-color, #e7e7e8);
  scrollbar-width: thin;
}

.abc-help-suggestions button {
  flex: 0 0 auto;
  padding: 0.38rem 0.65rem;
  color: var(--abc-help-primary);
  background: rgba(var(--abc-help-primary-rgb), 0.08);
  border: 1px solid rgba(var(--abc-help-primary-rgb), 0.2);
  border-radius: 999px;
  font-size: 0.78rem;
}

.abc-help-suggestions button:hover,
.abc-help-suggestions button:focus-visible {
  background: rgba(var(--abc-help-primary-rgb), 0.16);
}

.abc-help-file-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.65rem 0.85rem;
  overflow-x: auto;
  background: var(--abc-help-surface);
  border-top: 1px solid var(--bs-border-color, #e7e7e8);
}

.abc-help-file-actions small {
  flex: 0 0 100%;
  color: var(--abc-help-muted);
  font-size: 0.72rem;
}

.abc-help-file-actions[hidden],
.abc-help-file-button[hidden] {
  display: none !important;
}

.abc-help-file-button {
  flex: 0 0 auto;
  padding: 0.35rem 0.6rem;
  color: var(--abc-help-primary);
  background: transparent;
  border: 1px solid rgba(var(--abc-help-primary-rgb), 0.4);
  border-radius: 0.5rem;
  font-size: 0.77rem;
}

.abc-help-file-button:hover,
.abc-help-file-button:focus-visible {
  background: rgba(var(--abc-help-primary-rgb), 0.1);
}

.abc-help-report ol {
  margin: 0.5rem 0;
  padding-left: 1.2rem;
}

.abc-help-report li + li {
  margin-top: 0.55rem;
}

.abc-help-report small {
  display: block;
  color: var(--abc-help-muted);
}

.abc-help-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.55rem;
  flex: 0 0 auto;
  padding: 0.85rem;
  background: var(--abc-help-surface);
  border-top: 1px solid var(--bs-border-color, #e7e7e8);
}

.abc-help-form .btn {
  width: 42px;
  padding-right: 0;
  padding-left: 0;
}

html.dark-style .abc-help-panel,
html.dark-style .abc-help-bubble,
html.dark-style .abc-help-suggestions,
html.dark-style .abc-help-form,
html.dark-style .abc-help-file-actions,
html.dark-style .abc-help-status {
  --abc-help-surface: #2b2c40;
}

html.dark-style .abc-help-messages {
  background: rgba(255, 255, 255, 0.025);
}

@media (max-width: 575.98px) {
  .abc-help-assistant {
    right: 14px;
    bottom: 14px;
  }

  .abc-help-launcher span {
    display: none;
  }

  .abc-help-launcher {
    width: 52px;
    height: 52px;
    min-height: 52px;
    padding: 0;
  }

  .abc-help-panel {
    right: 10px;
    bottom: 76px;
    left: 10px;
    width: auto;
    height: min(680px, calc(100dvh - 92px));
    border-radius: 0.85rem;
  }
}

