.lx-launcher {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--lighter);
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

.lx-panel {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 380px;
  max-width: calc(100vw - 40px);
  height: min(700px, 85dvh);
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.24);
  display: none;
  flex-direction: column;
  z-index: 9999;
  padding-bottom: env(safe-area-inset-bottom);
}

.lx-head {
  background: var(--primary);
  color: var(--lighter);
  padding: 12px 16px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.lx-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  background: #f8fafc;
  min-height: 0;
}

.lx-foot {
  padding: 8px;
  border-top: 1px solid #e2e8f0;
  display: flex;
  gap: 8px;
  background: #fff;
  flex-shrink: 0;
  padding-bottom: max(8px, env(safe-area-inset-bottom));
}

.lx-inp {
  flex: 1;
  border: 1px solid #006975;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
}

.lx-send {
  background: var(--btn-primary-background-color);
  color: var(--btn-primary-color);
  border: none;
  border-radius: 8px;
  padding: 0 14px;
  cursor: pointer;
}

.lx-stop {
  background: var(--btn-primary-background-color);
  color: var(--btn-primary-color);
  border: none;
  border-radius: 8px;
  padding: 0 14px;
  cursor: pointer;
  margin-left: -90px;
}

.lx-quick-replies {
  display: block;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 8px;
}

.lx-quick-replies-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 8px;
}

.lx-qr-btn {
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #0f172a;
  border-radius: 9999px;
  padding: 6px 10px;
  font-size: 13px;
  cursor: pointer;
}

.lx-qr-btn:hover {
  background: #f1f5f9;
}

.lx-qr-btn:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.lx-disclaimer {
  font-size: 14px;
  text-align: center;
  font-style: italic;
  flex-shrink: 0;
}

.lx-reset-container {
  text-align: center;
  margin-top: 6px;
  margin-bottom: 10px;
  flex-shrink: 0;
}

.lx-reset {
  width: 40%;
  background: var(--btn-primary-background-color);
  color: var(--btn-primary-color);
  border: none;
  border-radius: 8px;
  padding: 6px;
  cursor: pointer;
  font-size: 14px;
}

.lx-feedback {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.lx-feedback-icon {
  cursor: pointer;
  padding: 2px;
}

.lx-feedback-icon svg {
  fill: #666;
  transition: all 0.2s ease;
}

.lx-feedback-icon:hover svg {
  fill: #006975;
  transform: scale(1.2);
}

.lx-feedback-thanks {
  font-size: 14px;
}

.lx-feedback.submitted .lx-feedback-icon {
  cursor: default;
}

.lx-start-infos {
  padding: 5px 5px;
  border-radius: 14px;
  font-size: 14px;
  overflow-wrap: break-word;
  white-space: inherit;
  background: #fff;
  border: 1px solid #e5e7eb;
  margin-right: auto;
}

.msg {
  max-width: 78%;
  margin: 8px 0;
  padding: 10px 12px;
  border-radius: 14px;
  font-size: 14px;
  word-wrap: break-word;
  overflow-wrap: break-word;
  white-space: pre-wrap;
}

.user {
  background: #e2e8f0;
  margin-left: auto;
  border-top-right-radius: 4px;
}

.bot {
  background: #fff;
  border: 1px solid #e5e7eb;
  margin-right: auto;
  border-top-left-radius: 4px;
}

.error {
  color: #b91c1c;
}

@media (max-width: 600px) {
  .lx-panel {
    right: 0;
    bottom: 0;
    width: 100vw;
    max-width: 100vw;
    height: 100dvh;
    border-radius: 0;
  }
  .lx-launcher {
    right: 16px;
    bottom: 16px;
  }
  .lx-inp {
    font-size: 16px;
  }
}