* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "Dongle", sans-serif;
  font-size: 24px;
  background: no-repeat url(./background.png);
  background-size: cover;
  height: 100vh;
}


.container {
  display: flex;
  height: 100vh;
  width: 80vw;
  max-width :1200px;
  margin: auto;
  padding: 20px;
  align-items: center;

}

.sidebar {
  background-image: linear-gradient(to bottom, rgb(61, 15, 15, 0.7), rgb(206, 127, 124, 0.3), rgb(236, 202, 202, 0.2));
  padding: 10px;
  width: 16%;
  min-width: 150px;
  height: 93%;
  display: flex;
  z-index: 1;
  user-select: none;
  border-radius: 16px 0 0 16px;
  flex-direction: column;
  justify-content: top;
  font-size: 28px;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.sidebar h2 {
  font-size: 1.8rem;
  font-weight: 500;
  color: #f5f5f5;
  margin-bottom: 20px;
}

.chatbot-list {
  list-style: none;
  padding: 0;
}

.chatbot-item {
  display: flex;
  width: 95%;
  min-width: 130px;
  padding: 10px;
  border-radius: 12px;
  margin:8px 0 8px 0;
  cursor: pointer;
  background-color: #f5f5f5;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}
.chatbot-item:hover {
  transform: scale(1.08);
}

.chatbot-item img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 10px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}
.chatbot-item img:hover {
  transform: scale(1.08);
}

.chatbot-item.selected {
  background-color: #0056b3;
  color: #f5f5f5;
  font-size: 32px;
  width: 100%;
  min-width: 150px;
  border-radius: 12px;
  margin:2px 0 2px 0;
}


.chat {
  background-color: #f5f5f588;
  border-radius: 16px;
  padding: 20px;
  width: 86%;
  height: 98%;
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.chatbox {
  background-color: #f5f5f533;
  border-radius: 12px;
  border: 1px solid #f5f5f588;
  height: 93vh;
  overflow-y: auto;
  padding: 16px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
  position: relative;
}
.spinner {
  text-align: center;
}
.chat-form {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.chat-form input {
  flex-grow: 1;
  padding: 12px;
  background-color: #f5f5f5;
  border: 1px solid #ddd;
  border-radius: 24px;
  outline: none;
  font-size: 16px;
  margin-right:5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.chat-form input:focus {
  border-color: #007bff;
}

.chat-form input:focus ~ button {
  background-color: #0056b3;
}
.chat-form button {
  background-color: #007bff;
  border: none;
  color: #ffffff;
  padding: 10px 20px;
  border-radius: 24px;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}
.paper-airplane {
  display: inline-block;
  filter: invert(1);
  width: 13px;
  height: 13px;
  background-image: url("paper-airplane.svg");
  background-size: contain;
  background-repeat: no-repeat;
  transition: transform 0.3s ease;
}

.chat-form button:hover {
  background-color: #273c52;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.message {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  margin-bottom: 16px;
}

.assistant-message {
  align-items: flex-start;
}

.bubble {
  background-color: #007bffcc;
  color: #f5f5f5;
  padding: 12px;
  border-radius: 16px 16px 0 16px;
  border: 1px solid #0056b3;
  overflow: auto;
  max-width: 65%;
  margin-bottom: 4px;
  font-size: 24px;
  position: relative;
  animation: fadeIn 0.3s;
}

.assistant-bubble {
  background-color: #f5f5f5;
  border-radius: 16px 16px 16px 0;
  border: 1px solid #a8a8a8;
  max-width:95%;
  padding : 16px 16px 16px 32px;
  color: #333333;
  z-index:1;
  align-items: center;
}

.chatbot-img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #a8a8a8;
  object-fit: cover;
  margin-bottom:-20px;
  z-index:3;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .container {
    padding: 0px;
  }

  .sidebar {
    width: 10%;
    min-width: 50px;
    height: 95%;
    border-radius: 16px 0 16 0;
    padding: 10px 0px 0px 0px;
    align-items: center;
    font-size:0;
  }
  .sidebar h2 {
    text-align: center;
    font-size:28px;
    flex-wrap: wrap;
  }

  .chatbot-list {
    flex-direction: row;
    justify-content: center;
    align-items:center;
    padding: 0px;
  }

  .chatbot-item {
    background: none;
    flex-direction: column;
    min-width: 18px;
    align-items: center;
    margin-right: 0px;
    padding: 0px;
    border-radius: 50%;
  }
  .chatbot-item.selected {
    background-color: #0056b3;
    color: #f5f5f5;
    font-size:0;
    width: 45px;
    height: 45px;
    text-align: center;
    align-content: center;
    justify-content: center;
    min-width: 45px;
    padding: 0;
    border-radius: 50%;
    margin-bottom: 0;
    margin-top: 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  }

  .chatbot-item img {
    width: 35px;
    height: 35px;
    border: 2px solid #a8a8a8;
    padding: 0px;
    margin-right: 0;
    margin-bottom: 0px;
  }

  .chat {
    width: 100%;
    border-radius: 12px;
    padding:16px;
    min-width: 300px;
  }

  .bubble {
    font-size: 26px;
  }

  @media (max-width: 560px) {
    .body {
      flex-direction: column;
      justify-content: center;
      align-items: center;
    }
    .container {
      height: 100vh;
      width:100vw;
      flex-direction: column;
      justify-content: center;
      align-items: center;
    }

    .sidebar {
      flex-direction: row;
      width: 100vw;
      height: 50px;
      vertical-align:auto;
      border-radius: 0;
      padding-left: 20px;
      align-items: center;
      justify-content: center;
      margin: 0;
      padding-bottom: 0;
      z-index:3;
    }
    .sidebar h2 {
      font-size: 20px;
      min-width: 50px;
      max-width: 100%;
      margin: 0;
    }
    .chatbot-list {
      direction: row;
      width: 90%;
      margin:auto;
      justify-content: center;
      align-items: center;
      padding-left: 20px;
      z-index:3;
    }
    .chatbot-item {
      float: left;
      margin:auto;
      box-shadow: none;
      width: 40px;
      margin: 0 5px 0px 5px;
      z-index:3;
    }
    .chatbot-item img{
      z-index:3;
    }
    .chat{
      border-radius:0;
      padding:6px;
      z-index:1;
      padding-bottom:0;
    }
    .chatbox {
      margin-bottom:10px;
      z-index:1;
    }
    .chat-form {
      margin-bottom:30px;
    }
  }

}



/* Table formatting */
table {
  border-collapse: collapse;
  border-radius:12px;
  width: 100%;
  margin-bottom: 1rem;
  font-size: 20px;
}

th, td {
  text-align: left;
  padding: 0.5rem;
  vertical-align: middle;
  border-top: 1px solid #dee2e6;
}

th {
  background-color: #d85b5b8c;
  color: #fff;
  font-weight: 600;
  text-transform: uppercase;
}

tr:nth-child(even) {
  background-color: #f8f9fa;
}

tr:hover {
  background-color: #e9ecef;
}

td:first-child, th:first-child {
  padding-left: 1rem;
}

td:last-child, th:last-child {
  padding-right: 1rem;
}

/* css for code. in case of not using prism.js */
pre {
  overflow-x: auto; /* Enable horizontal scrolling if code is too wide */
  padding: 0px 8px 0px 16px;
  width:80%;
  height:80%;
  background-color: #282c34; /* Dark background */
  color: #a9b7c6; /* Light text */
  border-radius: 4px; /* Rounded corners */
}

code {
  white-space: pre-wrap; /* Preserve line breaks and spaces */
  word-break: break-all; /* Allow long lines to break */
  font-size:20px;
  font-family: "Dongle", sans-serif;

}



@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* 
@keyframes gradient {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }*/

