body,
html {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: Arial, sans-serif;
  background-color: #212121;
  color: #fff;
}

.chat-body {
  overflow-y: scroll; /* Always show scrollbar */
}

.chat-body::-webkit-scrollbar {
  width: 8px; /* Adjust as needed */
}

.chat-body::-webkit-scrollbar-thumb {
  background-color: #363636; /* Adjust as needed */
  border-top-right-radius: 5px;
  border-top-left-radius: 5px;
  border-bottom-right-radius: 5px;
  border-bottom-left-radius: 5px;
}

.chat-body::-webkit-scrollbar-thumb:hover {
  background-color: #444444; /* Adjust on hover */
}

.chat-interface {
  width: 100%;
  max-width: 650px;
  margin: 0 auto;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: #212121;
}

.login-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
}

.login-logo {
  height: 75px;
  width: 75px;
  margin-bottom: 1rem;
}

.login-btn {
  background-color: #fff;
  padding: 10px 30px 10px 30px;
  border: 1px solid #fff;
  border-radius: 5px;
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
}

.login-label {
  text-align: center;
  padding: 0 2rem;
}

.login-btn:active, .login-btn:visited {
  color: #000;
}

.login-btn:hover {
  color: #fff;
  background-color: #212121;
  border: 1px solid #fff;
}

.cr-text {
  font-size: 0.65rem;
  text-align: center;
  color: #a9a9a9;
  margin-bottom: 0.4rem;
}

.chat-header {
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  border-bottom: 1px solid #404040;
  padding: 10px;
  font-weight: 500;
  font-size: 1.5rem;
}

.header-logo {
  height: 32px; /* Adjust as needed */
  width: auto;
  margin-right: 10px; /* Space between logo and text */
}

.chat-body {
  flex-grow: 1;
  padding: 10px 1rem;
  overflow-y: auto;
  white-space: pre-wrap;
}

.chat-message {
  margin-bottom: 10px;
  word-wrap: break-word;
  margin-bottom: 2rem;
  position: relative; /* for positioning the copy button */
}

.message-wrapper {
  margin-bottom: 15px;
}

.sender-label {
  font-size: 0.9em;
  color: #ececec;
  font-weight: bold;
  margin-bottom: 5px;
  vertical-align: middle;
  display: flex;
  align-items: center;
  margin-bottom: 0.5rem;
}

.user-message span,
.bot-message span {
  display: inline-block;
  max-width: 70%;
  margin-top: 2px;
  padding: 10px;
  border-radius: 8px;
}

.user-message span {
  color: #d9d9d9;
}

.bot-message span {
  color: #d9d9d9;
}

.chat-footer {
  display: flex;
  padding: 10px;
  padding-bottom: 0.5rem;
  background-color: #212121;
}

/* Add your existing styles here, and then update/add the following */

.input-wrapper {
  position: relative;
  flex-grow: 1;
}

#chat-input {
  width: 100%;
  padding: 15px 50px 15px 10px; /* Added right padding */
  border: 1px solid #404040;
  background-color: #212121;
  border-radius: 10px;
  font-size: 16px;
  resize: none;
  outline: none; /* Removes the outline */
  color: #fff;
  overflow: auto; /* For scrolling */
  box-sizing: border-box; /* Ensures padding is included in width */
}

#chat-input::-webkit-scrollbar {
  width: 0px; /* Adjust as needed */
}

#send-button {
  position: absolute;
  right: 15px; /* Distance from right edge */
  bottom: 20px; /* Distance from bottom edge */
  padding: 0;
  border: none;
  border-left: none;
  background-color: transparent;
  color: white;
  border-radius: 0 10px 10px 0; /* Rounded corners on the right side */
  cursor: pointer;
  font-size: 16px;
}

.copy-button {
  margin-top: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  display: block;
  padding-left: 0;
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

.blinking-circle {
  width: 10px;
  height: 10px;
  background-color: #f0f0f0;
  border-radius: 50%;
  animation: blink 1s linear infinite;
  display: inline-block;
  margin-right: 5px;
}

.bot-icon {
  height: 20px;
  width: auto;
  margin-right: 0.5rem;
  vertical-align: middle;
}

.copy-icon {
  height: 16px;
  width: auto;
  color: #d9d9d9;
  opacity: 0.5;
}

.copy-icon:hover {
  opacity: 1;
}

.code-language {
  font-family: monospace;
  font-size: 10px;
  color: #bcbcbc;
  background-color: #404040;
  padding: 8px 5px;
  font-weight: lighter;
  border-top-left-radius: 5px;
  border-top-right-radius: 5px;
  margin: 0;
}

pre {
  background-color: #000000 !important;
  padding: 10px;
  overflow: auto;
  white-space: pre; /* Changed from pre-wrap */
  word-wrap: normal; /* Changed from break-word */
  margin: 0 !important;
}

code {
  font-family: 'Courier New', Courier, monospace;
  font-size: .875rem;
}


/* Reset the white-space for other messages that are not code */
.chat-message:not(pre) {
  white-space: pre-wrap;
}