/* Chatbot Container */
.chatbot-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  overflow: hidden;
  width: 350px; /* Adjust as needed */
  height: 500px; /* Adjust as needed */
  background-color: #fff;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.3s ease-in-out, visibility 0.3s ease-in-out; /* Add visibility to transition */
  visibility: hidden; /* Hidden by default */
}

.chatbot-container.open {
  transform: translateY(0);
  visibility: visible; /* Visible when open */
}

/* Chatbot Toggle Button */
.chatbot-toggle-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1001;
  background-color: #274e50;
  color: white;
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Chatbot Header */
.chatbot-header {
  background-color: #274e50;
  color: white;
  padding: 10px 15px;
  font-weight: bold;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chatbot-header-close {
  background: none;
  border: none;
  color: white;
  font-size: 25px;
  cursor: pointer;
}

/* Chatbot Messages Area */
.chatbot-messages {
  flex-grow: 1;
  padding: 15px;
  overflow-y: auto;
  /* display: flex; */
  flex-direction: column;
  gap: 10px;
  /* Removed max-height and flex-basis to simplify flex behavior */
}

.chatbot-message {
  max-width: 80%;
  padding: 8px 12px;
  border-radius: 15px;
  line-height: 1.4;
}

.chatbot-message.bot {
  background-color: #e0e0e0;
  align-self: flex-start;
  border-bottom-left-radius: 2px;
}

.chatbot-message.user {
  background-color: #376B7E;
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 2px;
}

/* Style for messages containing widgets to take full width */
.chatbot-message.chatbot-message-widget {
  max-width: 100%;
  padding: 0; /* Remove padding from the message bubble itself */
  background-color: transparent; /* No background for the bubble */
  border-radius: 0; /* No border radius for the bubble */
}

/* Chatbot Input Area */
.chatbot-input-area {
  padding: 15px;
  border-top: 1px solid #eee;
  background-color: #f9f9f9;
}

/* Initial Form Widget */
.initial-form-widget {
  padding: 5px;
  background-color: #fff;
  border-radius: 5px;
}

.initial-form-header {
  font-size: 14px;
  font-weight: bold;
  margin-bottom: 15px;
  color: #333;
}

.initial-form-inputs {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 15px;
}

.initial-form-input {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
}

.initial-form-input:focus {
  outline: none;
  border-color: #274e50;
  box-shadow: 0 0 0 2px rgba(55, 107, 126, 0.2);
}

.initial-form-submit-button {
  width: 100%;
  padding: 10px;
  background: linear-gradient(90deg,rgba(203, 152, 102, 1) 0%, rgba(139, 94, 60, 1) 100%);
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.2s;
}

.initial-form-submit-button:hover {
  background: linear-gradient(275deg,rgba(203, 152, 102, 1) 0%, rgba(139, 94, 60, 1) 100%);
}

.error-message {
  color: #d93025;
  font-size: 12px;
  margin-top: 5px;
}

/* App Features Widget */
.app-features-widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.app-features-widget li {
  background-color: #e0e0e0;
  padding: 10px;
  margin-bottom: 8px;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.app-features-widget li.disabled {
  pointer-events: none;
  opacity: 0.5;
}

.app-features-widget li:hover {
  background-color: #d0d0d0;
}

/* Message Input Widget */
.message-input-widget-container {
  width: 100%;
  box-sizing: border-box;
}

.message-input-widget {
  display: flex;
  gap: 15px; /* Increased gap for better spacing */
  align-items: center;
}

.message-input-widget input {
  flex-grow: 1; /* Allow it to grow */
  flex-basis: auto; /* Base size on content, but allow shrinking/growing */
  max-width: calc(100% - 85px); /* Ensure space for button (60px) + gap (15px) + buffer */
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
  line-height: normal;
  vertical-align: middle;
}

.message-input-widget input.input-error {
  border-color: #d93025;
}

.message-input-widget input:focus {
  outline: none;
  border-color: #274e50;
  box-shadow: 0 0 0 2px rgba(55, 107, 126, 0.2);
}

.message-input-widget button {
  padding: 10px 15px;
  background-color: #274e50 !important;
  color: white !important;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.2s;
  box-sizing: border-box;
  flex-shrink: 0; /* Prevent button from shrinking */
  min-width: 60px; /* Ensure minimum width for "Send" text */
}

.message-input-widget button:hover {
  background-color: #2c5766;
}

.message-input-error {
  color: #d93025;
  font-size: 12px;
  margin-top: 5px;
  text-align: left;
  padding-left: 5px;
}

/* Post Submit Message */
.post-submit-message {
  padding: 15px;
  text-align: center;
  color: #274e50;
  font-weight: bold;
  background-color: #f0f0f0;
  border-radius: 4px;
}