
.inprox-ai-root {
  --inprox-ai-primary: #64005f;
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 999999;
  font-family: Arial, Helvetica, sans-serif;
}

.inprox-ai-launcher-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.inprox-ai-bubble {
  position: relative;
  max-width: 210px;
  background: #ffffff;
  color: #222;
  border-radius: 18px;
  padding: 10px 12px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.16);
  font-size: 13px;
  line-height: 1.35;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.inprox-ai-bubble::after {
  content: '';
  position: absolute;
  right: 20px;
  bottom: -8px;
  width: 16px;
  height: 16px;
  background: #fff;
  transform: rotate(45deg);
  box-shadow: 6px 6px 18px rgba(0, 0, 0, 0.06);
}

.inprox-ai-bubble.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.inprox-ai-bubble-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
}

.inprox-ai-bubble-hand {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 50%;
  background: rgba(100, 0, 95, 0.10);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.inprox-ai-launcher {
  border: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--inprox-ai-primary);
  color: #fff;
  border-radius: 999px;
  padding: 12px 15px;
  box-shadow: 0 12px 34px rgba(100, 0, 95, 0.32);
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
}

.inprox-ai-launcher:hover {
  transform: translateY(-1px);
}

.inprox-ai-launcher.inprox-ai-small {
  display: none;
}

.inprox-ai-launcher-icon {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.inprox-ai-panel {
  width: 380px;
  max-width: calc(100vw - 24px);
  height: 590px;
  max-height: calc(100vh - 30px);
  background: #fff;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 18px 55px rgba(0, 0, 0, 0.28);
  display: flex;
  flex-direction: column;
}

.inprox-ai-hidden {
  display: none !important;
}

.inprox-ai-header {
  background: var(--inprox-ai-primary);
  color: #fff;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.inprox-ai-header strong {
  display: block;
  font-size: 16px;
}

.inprox-ai-header span {
  display: block;
  font-size: 12px;
  opacity: 0.9;
  margin-top: 2px;
}

.inprox-ai-close {
  background: rgba(255, 255, 255, 0.18);
  border: 0;
  width: 32px;
  height: 32px;
  color: #fff;
  border-radius: 50%;
  font-size: 22px;
  line-height: 28px;
  cursor: pointer;
}

.inprox-ai-body {
  flex: 1;
  overflow-y: auto;
  background: #f7f3f7;
  padding: 16px;
}

.inprox-ai-lead-box h3 {
  margin: 0 0 12px;
  font-size: 17px;
  color: #202020;
}

.inprox-ai-lead-form label {
  display: block;
  color: #333;
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 10px;
}

.inprox-ai-lead-form input,
.inprox-ai-lead-form select,
.inprox-ai-lead-form textarea,
.inprox-ai-chat-input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #ddd;
  border-radius: 12px;
  padding: 11px 12px;
  margin-top: 5px;
  font-size: 14px;
  outline: none;
  background: #fff;
}

.inprox-ai-lead-form textarea {
  min-height: 70px;
  resize: vertical;
}

.inprox-ai-lead-form input:focus,
.inprox-ai-lead-form select:focus,
.inprox-ai-lead-form textarea:focus,
.inprox-ai-chat-input:focus {
  border-color: var(--inprox-ai-primary);
  box-shadow: 0 0 0 3px rgba(100, 0, 95, 0.10);
}

.inprox-ai-lead-form button,
.inprox-ai-chat-form button {
  border: 0;
  background: var(--inprox-ai-primary);
  color: #fff;
  border-radius: 14px;
  padding: 12px 16px;
  font-weight: 700;
  cursor: pointer;
}

.inprox-ai-lead-form button {
  width: 100%;
  font-size: 15px;
}

.inprox-ai-note {
  font-size: 11px;
  color: #666;
  text-align: center;
  margin: 10px 0 0;
}

.inprox-ai-msg {
  width: fit-content;
  max-width: 86%;
  margin: 8px 0;
  padding: 10px 12px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.45;
  clear: both;
}

.inprox-ai-msg.assistant {
  background: #fff;
  color: #222;
  border-bottom-left-radius: 5px;
}

.inprox-ai-msg.user {
  background: var(--inprox-ai-primary);
  color: #fff;
  margin-left: auto;
  border-bottom-right-radius: 5px;
}

.inprox-ai-msg.loading {
  opacity: 0.75;
}

.inprox-ai-chat-form {
  display: flex;
  gap: 8px;
  padding: 12px;
  background: #fff;
  border-top: 1px solid #eee;
}

.inprox-ai-chat-input {
  margin-top: 0;
  border-radius: 14px;
}

.inprox-ai-chat-form button {
  flex: 0 0 auto;
}

@media (max-width: 520px) {
  .inprox-ai-root {
    right: 10px;
    bottom: 10px;
  }

  .inprox-ai-bubble {
    max-width: 185px;
    font-size: 12px;
  }

  .inprox-ai-launcher {
    padding: 11px 13px;
    font-size: 13px;
  }

  .inprox-ai-panel {
    width: calc(100vw - 20px);
    height: calc(100vh - 20px);
    max-height: calc(100vh - 20px);
    border-radius: 18px;
  }
}
