/* Grupo VektIA - Chatbot */

#vektia-chatbot {
  --vc-navy: #061f4b;
  --vc-blue: #0a3474;
  --vc-violet: #6f25e8;
  --vc-cyan: #14bac4;
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 9999;
  font-family: Arial, Helvetica, sans-serif;
}

#vektia-chatbot * {
  box-sizing: border-box;
}

#vektia-chatbot .vc-launcher {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 22px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--vc-blue), var(--vc-violet));
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(6, 31, 75, .28);
}

#vektia-chatbot .vc-launcher:hover {
  transform: translateY(-2px);
}

#vektia-chatbot .vc-panel {
  display: none;
  flex-direction: column;
  width: 370px;
  height: min(540px, calc(100dvh - 110px));
  margin-bottom: 14px;
  overflow: hidden;
  border: 1px solid #e4e8ef;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 20px 65px rgba(6, 31, 75, .22);
}

#vektia-chatbot .vc-panel.vc-open {
  display: flex;
}

#vektia-chatbot .vc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  background: linear-gradient(120deg, var(--vc-navy), var(--vc-blue));
  color: #fff;
}

#vektia-chatbot .vc-header strong {
  display: block;
  font-size: 17px;
}

#vektia-chatbot .vc-header span {
  display: block;
  margin-top: 5px;
  font-size: 12px;
  color: #c9e5f1;
}

#vektia-chatbot .vc-close {
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 26px;
  cursor: pointer;
}

#vektia-chatbot .vc-messages {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
  background: #f7f9fd;
}

#vektia-chatbot .vc-message {
  max-width: 88%;
  margin-bottom: 12px;
  padding: 12px 14px;
  border-radius: 15px;
  font-size: 14px;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

#vektia-chatbot .vc-assistant {
  margin-right: auto;
  background: #fff;
  color: #24334d;
  border: 1px solid #e6ebf3;
}

#vektia-chatbot .vc-user {
  margin-left: auto;
  background: var(--vc-blue);
  color: #fff;
}

#vektia-chatbot .vc-form {
  display: flex;
  gap: 8px;
  padding: 14px;
  border-top: 1px solid #e8ebf1;
}

#vektia-chatbot .vc-input {
  flex: 1;
  min-width: 0;
  padding: 12px;
  border: 1px solid #d9e1ec;
  border-radius: 12px;
  font-size: 14px;
}

#vektia-chatbot .vc-send {
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: var(--vc-violet);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

#vektia-chatbot .vc-send:disabled {
  opacity: .55;
  cursor: not-allowed;
}

#vektia-chatbot .vc-footer {
  padding: 11px 14px;
  text-align: center;
  border-top: 1px solid #edf0f5;
}

#vektia-chatbot .vc-footer a {
  color: var(--vc-blue);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 480px) {
  #vektia-chatbot {
    right: 12px;
    bottom: 12px;
  }

  #vektia-chatbot .vc-panel {
    width: calc(100vw - 24px);
    height: min(540px, calc(100dvh - 95px));
  }
}

/* Opciones iniciales de conversación */

#vektia-chatbot .vc-options {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 14px 0;
}

#vektia-chatbot .vc-option {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid #dce4f1;
  border-radius: 13px;
  background: #fff;
  color: #102b58;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  line-height: 1.4;
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s;
}

#vektia-chatbot .vc-option:hover {
  border-color: #6f25e8;
  background: #f7f2ff;
  transform: translateX(3px);
}

#vektia-chatbot .vc-option:focus-visible {
  outline: 2px solid #6f25e8;
  outline-offset: 2px;
}


/* Resumen editable para WhatsApp */
.vc-resumen-editor {
  display: block;
  box-sizing: border-box;
  width: 100%;
  min-height: 130px;
  padding: 12px;
  margin: 10px 0;
  border: 1px solid #d8d4e8;
  border-radius: 12px;
  background: #ffffff;
  color: #242136;
  font: inherit;
  font-size: 13px;
  line-height: 1.5;
  resize: vertical;
}

.vc-resumen-editor:focus {
  outline: 2px solid #7860c8;
  outline-offset: 2px;
}
