#case01 {
    display: flex;
    justify-content: center;
    font-family: "Roboto", sans-serif;
    background-image: url('../img/background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    margin: 0;
}
.panel-group {
  display: flex;
  flex-direction: column;
  bottom: 0;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  /* border: 0.5px solid #000000; */
  background-position: center top; 
  background-repeat: no-repeat; 
  background-size: 80%;
  margin-bottom: 0;
  z-index: 1;
  background-color: rgb(238, 241, 246);
  padding-bottom: 1rem;
}
#counter {
  background-color: transparent; 
  /* padding-top: 20px;  */
  /* background-image: url('../img/counter004.png');  */
  background-position: center top; 
  background-repeat: no-repeat; 
  background-size: 80%;
}
.full-height {
  height: 100dvh; /* modern browsers */
  height: var(--app-height, 100vh); /* fallback for older Safari */
  overflow: auto;
  background: white; /* just to show area */
}
#case02 {
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  font-family: "Roboto", sans-serif;
  position: relative;
  margin: 0;
}
#case02::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  /* background-image: url('../img/background.jpg'); */
  /* background-size: cover; */
  /* background-position: center; */
  /* background-repeat: no-repeat; */
  /* filter: blur(8px); */
  /* z-index: -1; */
}
.cover-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7); /* Semi-transparent background */
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.cover-content {
  text-align: center;
  color: white;
  width: 100%;
}

.cover-content h1 {
  margin-bottom: 20px;
}

#ok-button , #continue-conversation-button, #end-button {
  background-color: #4CAF50; /* Green background */
  color: white; /* White text */
  padding: 10px 20px;
  border: none;
  cursor: pointer;
  font-size: 16px;
  border-radius: 5px;
}

#ok-button:hover {
  background-color: #45a049; /* Darker green on hover */
}

.chatbot-container {
    /* max-width: 1280px; */
    width: 100%;
    height: 100vh;
    margin: 0 auto;
    position: relative;
    /* background-color: #f8e0e0; */
    /* border: 2px solid #0a0101; */
    /* box-shadow: 0 2px 4px rgba(39, 8, 214, 0.1); */
  }

.chatbot-container, message-container {
    border-radius: 0.5rem;
  }

#chatbot {
  /* background-color: white; */
  /* box-shadow: 0 2px 6px 0 rgba(0, 0, 0, 0.1); */
  height: 100%;
  border-radius: 4px;
  position: relative;
  display: flex;
  flex-direction: column;
  /* background-color: #f9f8f9; */
  background-color: transparent;
}

#conversation-panel {
  height: 100%;
  padding-top: 5rem;
  padding-bottom: 1rem;
}

#head {
  background-image: url('../img/top_item_3.png');
  background-size: cover;
  background-position: bottom;
  background-repeat: no-repeat;
  width: 100%;
  height: 8%;
  position: absolute;
  top: 0;
}
#bottom {
  width: 100%;
  height: 24%;
  position: absolute;
  content: "";
  bottom: 0;

  background: linear-gradient(180deg, rgba(77, 74, 255, 0) 0%, rgba(74, 179, 255, 0.5) 100%);
}

#counter {
  width: 100%;
  height: 36%;
  position: absolute;
  bottom: 0px;
  background-image: url('../img/counter005.png');
  background-size: 100% 100%;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 1;
}

#header {
  background-color:white;
  color: black;
  padding: 3px;
  padding-left: 10px;
  padding-right: 10px;
  font-size: 1em;
  font-weight: bold;
}

message-container {
  /* background: rgba(255, 255, 255, 0.4); */
  background-color: white;
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
}

.chat-section {
  /* border: 1px solid #0a0101; */
  /* box-shadow: 0 2px 4px rgba(39, 8, 214, 0.2); */
  /* border-radius: 5px; */ 
  /* margin-bottom: 10px; */
}
.input-section {
  /* margin-bottom: 1rem; */
  /* border: solid 0.5px black; */
  /* box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3); */
  /* border-radius: 1rem; */
}

#stage {
  position: absolute !important;
  left: 50%;
  bottom: 0%;
  transform: translateX(-50%);
  width: 100%;
  height: 86vh;
  margin-top: 8% !important;
  flex-direction: column;
  justify-content: flex-end;
  display: flex;
  /* background-image: url('../img/background09.png');
  background-size: 100% auto;
  background-position: top center;
  background-repeat: no-repeat; */
}
#wall {
  position: absolute;
  background-image: url('../img/background09.png');
  background-size: 100% auto;
  background-position: top center;
  background-repeat: no-repeat;
  top: 50px;
  left: 0;
  width: 100%;
  height: 400px;
}
#wall::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255, 255, 255, 0.5);
}
#toyota_logo {
  /* display: none; */
  position: absolute;
  /* background-image: url('../img/toyota_logo.gif');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat; */
  top: 0;
  left: 3%;
  /* width: 411px;
  height: 71px; */
  /* width: 287px;
  height: 50px; */
  width: 20%;
  height: auto;
}
#video {
  height: 100%;
  aspect-ratio: 540/510;
  margin: 0 auto;
  z-index: 1;
}
#personal {
  display: none;
  position: absolute;
  background-image: url('../img/personal/0004_ai_rbg.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  bottom: -80px;
  left: 36px;
  width: 1023px;
  height: 576px;
}

#support-information {
  width: 400px;
  height: 251px;
  position: absolute;
  top: 12%;
  right: 60px;
  z-index: 1;
  border: solid black 1px;
  display: none;
  flex-direction: column;
  background: white;
  background-image: url('../img/support_information/001.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

#conversation {
  /* background-color: rgba(0, 0, 0, 0.05); */
  /* height: 60vh; */
  flex: 1;
  min-height: 0;
  border-radius: 0.5rem; 
  width: 100%; 
  margin: 0 auto;
  overflow-y: auto;
  -ms-overflow-style: none;
  padding: 20px;
  display: flex;
  flex-direction: column;
  
  /* border: 1px solid #000000; */
  /* box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); */
}
/* #conversation::-webkit-scrollbar {
  display: none;
} */

@keyframes message-fade-in {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.chatbot-message {
  display: flex;
  align-items: flex-start;
  position: relative;
  font-size: 16px;
  line-height: 20px;
  border-radius: 20px;
  word-wrap: break-word;
  white-space: wrap;
  max-width: 100%;
  padding: 0 15px;
}

.message-box {
  padding: 0 2px;
  white-space: nowrap;
  line-height: 16px;
  margin-bottom: 24px;
}
.message-box p {
  word-wrap: break-word;
  white-space: wrap;
}
.role-box {
  display: flex;
  padding: 0 2px;
}
.role-box p {
  margin-bottom: 5px;
  margin-top: 2px;
}
.chatbot .chatbot-text {
  /* margin-left: 16px; */
  margin-right: 40px;
  word-wrap: break-word;
  white-space: wrap;
  /* background-color: rgb(238, 238, 238); */
  background-color: white;
}
.chatbot-text p {
  margin-top: 0;
  margin-bottom: 0;
  font-size: 0.9rem;
}
.user-message .chatbot-text {
    /* margin-right: 16px; */
    background-color: #007AFF;
    color: white;
  }
.head-img {
  height: 20px;
  width: 20px;
}
.toyota-head-img {
  height: 20px;
  width: 31px;
}
.chatbot .bot-img {
  margin-right: 3px;
}
.user-message .bot-img {
  margin-left: 3px;
}
.user-message {
  justify-content: flex-end;
}
.user-message .role-box {
  justify-content: flex-end;
}
.chatbot-text {
  background: rgba(256, 256, 256, 0.7);
  color: #000000;
  font-size: 0.9rem;
  letter-spacing: 0.02rem;
  line-height: 1.4rem;
  padding: 10px 28px;
  border-radius: 1.5rem;
  /* border: 1px solid #000000; */
  margin-top: 2px;
}
.user-message .message-box .chatbot-text {
  border-top-right-radius: 0.2rem;
}
.chatbot .message-box .chatbot-text {
  border-top-left-radius: 0.2rem;
}

#input-form {
  display: flex;
  align-items: center;
  /* border-top: 1px solid #000000; */
}

#input-field {
  flex: 1;
  height: 60px;
  border: 1px solid #7f9bbe;
  border-radius: 4px;
  padding: 0 10px;
  font-size: 14px;
  transition: border-color 0.3s;
  color: #000000;
  border: none;
  background-color: transparent;
}

.send-icon {
  width: 28px;
  margin-right: 10px;
  cursor: pointer;
}

#input-field:focus {
  border-color: #000000;
  outline: none;
}

#submit-button {
  background-color: transparent;
  border: none;
}

#record-button {
  display: none;
}

p[sentTime]:hover::after {    
  content: attr(sentTime);
  position: absolute;
  top: -3px;
  font-size: 14px;
  color: gray;
}

.chatbot p[sentTime]:hover::after {  
  left: 15px;
}

.user-message p[sentTime]:hover::after {  
  right: 15px;
}


/* width */
::-webkit-scrollbar {
  width: 10px;
}

/* Track */
::-webkit-scrollbar-track {
  background: #f1f1f1; 
}
  
/* Handle */
::-webkit-scrollbar-thumb {
  background: #888; 
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: #555; 
}
.card-img {
  width: 48%;
  margin-top: 20px;
}
.speaker-button {
  background-color: transparent;
  border: none;
}
.speaker-icon {
  width: 20px;
  margin-left: 24px;
  margin-top: 4px;
}
.microphone-icon {
  width: 28px;
  margin-right: 10px;
  cursor: pointer;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

.speaker-button.blinking {
  animation: blink 1s infinite;
}
.blinking {
  animation: blink 1s infinite;
}

@keyframes blinkRed {
  0% { opacity: 1; }
  50% { opacity: 0.3; }
  100% { opacity: 1; }
}

.blink-red {
  animation: blinkRed 1s infinite;
  background-color: red;
  /* filter: hue-rotate(360deg) saturate(200%) brightness(80%); */
}
#sample-question {
  margin-top: 1rem;
  margin-bottom: 1.5rem;
}
.sample-question-button {
  border: none;
  border-radius: 1rem;
  padding: 7px 24px;
  margin-right: 10px;
  background: #007AFF;
  color: #F9F8F9;
  font-size: 0.9rem;
}
.chatbot-row {
  height: 100%;
}


@media (max-width: 768px) {
  body {
    overflow: hidden;
    position: fixed;
    width: 100%;
  }
  .chatbot-row {
    display: flex !important;
    flex-direction: column !important;
    height: calc(100vh - env(safe-area-inset-top) - env(safe-area-inset-bottom)) !important;
  }
  .chatbot-container {
    overflow: hidden;
    position: fixed;
    width: 100%;
  }
  #head {
    display: none;
  }
  #stage {
    height: 100%;
  }
  #wall {
    background-size: cover;
    top: 5%;
    height: 300px;
  }
  #toyota_logo {
    top: 5%;
    width: 30%;
    z-index: 1;
  }
  #chatbot{
    flex: 1;
    height: 50%;
    max-height: 50%;
    overflow: hidden;
  }
  #video {
    /* width: 96%; */
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
  }
  #counter{
    height: 18%;
    background-image: url('../img/counter005_mobile.png');
  }
  #conversation-panel {
    flex: 1;
    height: 50%;
    max-height: 50%;
    overflow: auto;
    padding-top: 0rem;
    padding-bottom: 0rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }
  .sample-question-button {
    border: none;
    border-radius: 1rem;
    padding: 4px 12px;
    margin-right: 5px;
    font-size: 0.7rem;
  }
  .input-section {
    margin-bottom: 2rem;
  }
  .panel-group {
    padding-bottom: 1rem;
    padding-top: 1rem;
  }
  #sample-question {
    margin-top: 0.4rem;
    margin-bottom: 0.6rem;
  }
  .chatbot-message {
    padding: 0 0;
  }
  .message-box {
    margin-bottom: 12px;
  }
  .chatbot-text {
    letter-spacing: 0.02rem;
    margin-right: 16px !important;
    line-height: 1.4rem;
    padding: 10px 16px;
    border-radius: 1.5rem;
    margin-top: 2px;
  }
}