/* Import Google Font - Poppins */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap');

*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

body{
    background: #E3F2FD;
    margin: 0; /* Reset margin to remove extra space around body */
    padding: 0; /* Reset padding to remove extra space around body */
    height: 100%; /* Set body height to 100% to fill the viewport */
}

html{
    height: 100%;
}
.wrapper{
    display: flex;
    height: fit-content;
}



/* NavBar Area */
nav{background: blue;
}

/* Amelia Sidebar Area*/
.sidebar-container {
    display: flex;
}

.sidebar {
    margin: 100px 50px 0px auto;
    height: 80vh;
    width: 300px;
    padding: 30px 30px;
    border-radius: 15px;
    background: #724ae8;
    color: black;
}

.profile{
    display: flex;
    flex-direction: column;
    padding: 10px;
    align-items: center;
    margin: 0 0 20px 0;
    border-radius: 20px;
    background: #fff;
}

.profile img{

    padding: 0px;
    border-radius: 50%;
    width:200px;
    height:200px;
    border: 3px solid black;
}

.profile-name {
    text-align: center;
    padding: 5px;
    letter-spacing: 5px;
    max-height: 40px;
    font-size: 0.95rem;
}

.profile-description{
    display: flex;
    flex-direction: column;
    padding: 10px;
    margin: 0 0 20px 0;
    border-radius: 20px;
    background: #fff;
    overflow: auto;
    max-height: 365px;
}

.profile-content {
    text-align: justify;
    text-indent: 10px;
    max-height: 380px;
    margin: 10px 0;
    padding: 5px;
    overflow: auto;
    word-wrap: break-word;
    font-size: 0.85rem;
    letter-spacing: 1x;
   
   
}

.profile-content::-webkit-scrollbar {
    display: none;
  }



  
/* Chatbot Area */
.chatbot{
    
    margin: 100px 15px 0 auto;
    width: 75vw;
    height: 80vh;
    overflow: hidden;
    transform: scale(0.5);
    opacity: 0;
    pointer-events: none;
    background: #fff;
    border-radius: 15px;
    transform-origin: bottom right;
    box-shadow: 0 0 128px 0 rgba(0,0,0,0.1),
                0 32px 64px -48px rgba(0,0,0,0.5);
    transition: all 0.1s ease;
}
.show-chatbot .chatbot{
    transform: scale(1);
    opacity: 1;
    pointer-events: auto;
}

.chatbot header{
    background: #724ae8;
    padding: 16px 0;
    text-align: center;
    position: relative;
}

.chatbot header h2{
    color: #fff;
    font-size: 1.4em;
}

.chatbot header span{
    position: absolute;
    right: 20px;
    top: 50%;
    color:#fff;
    cursor: pointer;
    display: none;
    transform: translateY(-50%);
}

.chatbot .chatbox{
    height:645px;
    overflow-y: auto;
    padding: 30px 20px 100px;
    
}

/* Track */
.chatbox::-webkit-scrollbar {
    width: 10px;
  }
  
  /* Handle */
  .chatbox::-webkit-scrollbar-thumb {
    background-color: #a0a0a0;
    border-radius: 10px;
  }
  
  /* Handle on hover */
  .chatbox::-webkit-scrollbar-thumb:hover {
    background-color: #c8c8c8;
  }

.chatbox .chat{
    display: flex;
}
/*
.chatbot .incoming span{
    height: 32px;
    width: 32px;
    color:#fff;
    align-self: flex-end;
    background: #724ae8;
    text-align: center;
    line-height: 32px;
    border-radius: 4px;
    margin: 0 10px 7px 0;
}
*/

.chatbot .incoming img{
    height: 70px;
    width: 70px;
    align-self:flex-end;
    text-align: center;
    border-radius: 50px;
    margin: 0 10px 0 0;
}
.chatbox .outgoing{
    margin: 20px 0;
    justify-content: flex-end;
    word-wrap: break-word; /* Add this line to enable word wrapping */
}

.chatbox .chat p{
    color:#fff;
    max-width: 75%;
    white-space: pre-wrap;
    font-size: 1.15rem;
    padding: 12px 16px;
    border-radius: 15px 15px 0 15px;
    background:#724ae8;
}

.chatbox .chat p.error {
    color: #721c24;
    background: #f8d7da;
}

.chatbox .incoming p{
    color:black;
    background: #f2f2f2;
    border-radius: 15px 15px 15px 0;
    margin: 20px 0 0 0;
    
}

.chatbot .chat-input{
    position: absolute;
    bottom: 0;
    width: 100%;
    display: flex;
    gap: 5px;
    background: #fff;
    padding: 5px 20px;
    border-top: 1px solid #ccc;
}

.chat-input textarea{
    height: 65px;
    width: 100%;
    border:none;
    outline:none;
    max-height: 180px;
    font-size: 1.15rem;
    resize: none;
    padding: 16px 15px 16px 0;
}

.chat-input span{
    align-self:flex-end;
    height: 65px;
    line-height: 65px;
    color:#724ae8;
    font-size: 1.35rem;
    cursor: pointer;
    visibility: hidden;
}

.chat-input textarea:valid ~ span {
    visibility: visible;
}


/* Dots Thinking Animation 
.typing-animation{
    display: inline-flex;
    padding-left: 25px;
}
.typing-animation .typing-dot {
    height: 7px;
    width: 7px;
    opacity: 0.7;
    margin: 0 3px;
    border-radius: 50%;
    background: #fff;
    animation: animateDots 1.5s var(--delay) ease-in-out infinite;
}
@keyframes animateDots {
    0%, 44% {
        transform: translateY(0px);
    }
    22% {
        opacity: 0.4;
        transform: translateY(-6px);
    }
    44% {
        opacity: 0.2;
    }
}
*/



@media (max-width: 850px) {
    .sidebar-container {
      display: none;
    }
    .chatbot {
        margin:auto;
        width: 100%;
        height: 100vh;
        transform: scale(1); /* Reset the scaling for smaller screens */
        opacity: 1; /* Ensure the chatbot is visible */
        pointer-events: auto; /* Allow user interaction */
      }
      .chatbot .chatbox {
        height: calc(100vh - 140px); /* Adjust height to leave room for header and input */
        overflow-y: auto; /* Show vertical scrollbar when necessary */
      }
      .chatbot header span {
        display: block;
      }
}