/* 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;
}
:root {
  --text-color: #FFFFFF;
  --icon-color: #ACACBE;
  --icon-hover-bg: #5b5e71;
  --placeholder-color: #dcdcdc;
  --outgoing-chat-bg: #343541;
  --incoming-chat-bg: #444654;
  --outgoing-chat-border: #343541;
  --incoming-chat-border: #444654;
}
.light-mode {
  --text-color: #343541;
  --icon-color: #a9a9bc;
  --icon-hover-bg: #f1f1f3;
  --placeholder-color: #6c6c6c;
  --outgoing-chat-bg: #FFFFFF;
  --incoming-chat-bg: #F7F7F8;
  --outgoing-chat-border: #FFFFFF;
  --incoming-chat-border: #D9D9E3;
}
body {
  background: #F7F7F8;
}

/* Chats container styling */

#page-content{
  background-image: url('../images/FONDO.jpg');
  background-repeat: repeat-x;
}



.chat-ui{
  top: 4em;
}
.chat-container {
  overflow-y: auto;
  max-height: 90vh;
  padding-bottom: 150px;
  min-height: 500px;
  padding-top: 4em;
  width: 70%;
  margin: auto;
  background: #6C687620;
  margin-bottom: 9em;
  position: relative;
  border-radius: 10px;
  margin-top: 4em;
  
}
:where(.chat-container, textarea)::-webkit-scrollbar {
  width: 6px;
}
:where(.chat-container, textarea)::-webkit-scrollbar-track {
  background: var(--incoming-chat-bg);
  border-radius: 25px;
}
:where(.chat-container, textarea)::-webkit-scrollbar-thumb {
  background: var(--icon-color);
  border-radius: 25px;
}

.chat-container::-webkit-scrollbar{
  display: none;
}
.default-text {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  height: 70vh;
  padding: 0 10px;
  text-align: center;
  color: var(--text-color);
}
.default-text h1 {
  font-size: 3.3rem;
}
.default-text p {
  margin-top: 10px;
  font-size: 1.1rem;
}
.chat-container .chat {
  padding: 25px 10px;
  display: flex;
  justify-content: center;
  color: var(--text-color);
}
.chat-container .chat.outgoing {
  background: transparent;
  /*border: 1px solid var(--outgoing-chat-border);*/
}
.chat-container .chat.incoming {
  background: transparent;
  /*border: 1px solid var(--incoming-chat-border);*/
}
.chat .chat-content {
  display: flex;
  max-width: 1200px;
  width: 100%;
  align-items: flex-start;
  justify-content: space-between;
}
button.material-symbols-rounded {
  user-select: none;
  cursor: pointer;
  display: none;
}
.chat .chat-content span {
  cursor: pointer;
  font-size: 1.3rem;
  color: var(--icon-color);
  visibility: hidden;
  display: none;
}
.chat:hover .chat-content:not(:has(.typing-animation), :has(.error)) span {
  visibility: visible;
}
.chat .chat-details {
  display: flex;
  flex-direction: column;
  /*align-items: center;*/
  border: 2px solid #C91BB7;
  /*margin-left: 1em;*/
  margin: .5em;
  border-radius: 20px;
  padding: .5em;
  margin-bottom: 1em;
}

.chat .chat-details img{
  display: none;
}

.chat .chat-res{
  display: flex;
  flex-direction: column;
  align-items: center !important;
  width: 94%;
  margin-left: 40%;
  border: 2px solid #1BC97E !important;
  margin-right: 0em;
}

.res-img{
  flex: none;
  margin-right: 10px;
}
.chat .chat-details img {
  width: 35px;
  height: 35px;
  align-self: flex-start;
  object-fit: cover;
  border-radius: 2px;
  margin-right: 1em;
}
.chat .chat-details p {
  white-space: pre-wrap;
  font-size: 1rem;
  /*padding: 10px;*/
  color: #fff;
  word-break: break-word;
  /*width: 75%;*/
  /*border: 1px solid #C91CB7;*/
  /*margin: 2em;*/
  border-radius: 10px;
  text-align: left;
}
.chat .chat-details p.error {
  color: #e55865;
}
.chat .typing-animation {
  padding-left: 25px;
  display: inline-flex;
}

.user-input{
  background: transparent;
  margin-left: 0em;
  border-radius: 10px;
}

.chat-output{
  background: transparent;
  margin-left: 1em;
  border-radius: 10px;
  /*border: 1px solid #1DC97D !important;*/
}

.audio-content{
  display: flex;
  justify-content: end;
  /*align-self: flex-end;*/
  margin-right: 4%;
  height: 24px;
}

.chef-img-container{
  display: flex;
  /*display: none;*/
  position: relative;
  align-self: flex-start;
  left: 21%;
  top: 2em;
}
.typing-animation .typing-dot {
  height: 14px;
  width: 14px;
  border-radius: 50%;
  margin: 0 3px;
  opacity: 0.7;
  background: #4CAF50;
  animation: animateDots 1.5s var(--delay) ease-in-out infinite;
  color: #4CAF50;
}
.typing-animation .typing-dot:first-child {
  margin-left: 0;
}

.btn-chat{
  width: 10em;
}
@keyframes animateDots {
  0%,44% {
    transform: translateY(0px);
  }
  28% {
    opacity: 0.4;
    transform: translateY(-6px);
  }
  44% {
    opacity: 0.2;
  }
}

/* Typing container styling */
.typing-container {
  position: relative;
  bottom: 0;
  /*width: 104vw;*/
  display: flex;
  padding: 20px 10px;
  background: #6C687660;
  /*border-top: 1px solid var(--incoming-chat-border);*/
}
.typing-container .typing-content {
  display: flex;
  max-width: 100%;
  width: 100%;
  align-items: flex-end;
  margin-top: 1em;
}
.typing-container .typing-textarea {
  width: 100%;
  display: flex;
  position: relative;
}
.typing-textarea textarea {
  resize: none;
  height: 55px;
  width: 100%;
  border: none;
  padding: 15px 45px 15px 20px;
  color: var(--text-color);
  font-size: 1rem;
  border-radius: 4px;
  max-height: 250px;
  overflow-y: auto;
  background: var(--incoming-chat-bg);
  outline: 1px solid var(--incoming-chat-border);
}
.typing-textarea textarea::placeholder {
  color: var(--placeholder-color);
}
.typing-content span {
  width: 55px;
  height: 55px;
  display: flex;
  border-radius: 4px;
  font-size: 2rem;
  align-items: center;
  justify-content: center;
  color: var(--icon-color);
}
.typing-textarea span {
  position: absolute;
  right: 0;
  bottom: 0;
  visibility: hidden;
}
.typing-textarea textarea:valid ~ span {
  visibility: visible;
}
.typing-controls {
  display: flex;
  justify-content: center;
  padding-top: 15px;
  padding-left: 21% !important;
}
.typing-controls span {
  margin-left: 7px;
  font-size: 1.4rem;
  background: var(--incoming-chat-bg);
  outline: 1px solid var(--incoming-chat-border);
}
.typing-controls span:hover {
  background: var(--icon-hover-bg);
}

.button {
  background-color: #4CAF50; /* Green */
  border: none;
  color: white;
  padding: 15px 32px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 16px;
  border-radius: 4px;
  margin-right: 4px;
  margin-left: 4px;
}

.button {
  -webkit-transition-duration: 0.4s; /* Safari */
  transition-duration: 0.4s;
}

.button:hover {
  background-color: white; /* Green */
  color: gray;
}

.button-green {background-color: #4CAF50;} /* Green */
.button-blue {background-color: #008CBA;} /* Blue */
.button-red {background-color: #f44336;} /* Red */

.btn-disabled {
  cursor: not-allowed;
  opacity: .65;
  filter: alpha(opacity=65);
  -webkit-box-shadow: none;
  box-shadow: none;
}

/* Works on Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: rgb(178, 178, 186) rgb(65, 64, 62);
}

/* Works on Chrome, Edge, and Safari */
*::-webkit-scrollbar {
  width: 12px;
}

*::-webkit-scrollbar-track {
  background: rgb(65, 64, 62);;
}

*::-webkit-scrollbar-thumb {
  background-color: rgb(178, 178, 186);
  border-radius: 20px;
  border: 3px solid rgb(65, 64, 62);;
}

#chat-input{
  max-height: 60px !important;
  height: 60px !important;
  width: 60%;
  margin: auto;
}

/** Audio controls*/
.audio-controls{
  padding-top: 1em;
}

.btn-play{
  width: 4em;
  margin-right: 2em;
}

.btn-stop{
  width: 4em;
  margin-right: 2em;
}


/**Animation*/

.button-container {
  display: flex;
  align-items: center;
  position: relative;
  left: -10em;
}

button {
  padding: 10px 20px;
  background-color: #3498db;
  color: white;
  border: none;
  cursor: pointer;
  font-size: 16px;
}

.recording-animation {
  width: 20px;
  height: 20px;
  margin-left: 10px;
  background-color: red;
  border-radius: 50%;
  animation: pulse 1s infinite;
  visibility: hidden;
}

@keyframes pulse {
  0% {
      transform: scale(1);
  }
  50% {
      transform: scale(1.5);
  }
  100% {
      transform: scale(1);
  }
}

.incoming{
  display: flex;
  justify-content: end;
  margin: .5em;
}

.usage-limit{
  display: flex;
  justify-content: flex-end;
}

.usage-limit-text{
  font-size: 20px;
  color:red;
  margin-right: 16%;
}
/* Reponsive Media Query */
@media screen and (max-width: 600px) {
  .default-text h1 {
    font-size: 2.3rem;
  }
  :where(.default-text p, textarea, .chat p) {
    font-size: 0.95rem!important;
  }

  .chat-container {
    overflow-y: auto;
    max-height: 90vh;
    padding-bottom: 150px;
    min-height: 500px;
    padding-top: 4em;
    width: 100%;
    margin: auto;
    margin-bottom: 5em;
  }
  .chat-container .chat {
    padding: 20px 10px;
  }
  .chat-container .chat img {
    height: 32px;
    width: 32px;
    margin-right: .5em;
  }
  .chat-container .chat p {
    padding: 0 20px;
  }
  .chat .chat-content:not(:has(.typing-animation), :has(.error)) span {
    visibility: visible;
    display: none;
  }
  .typing-container {
    padding: 15px 10px;
  }
  .typing-textarea textarea {
    height: 45px;
    padding: 10px 40px 10px 10px;
  }
  .typing-content button {
    height: 45px;
    margin-left: 5px;
  }
  button.material-symbols-rounded {
    font-size: 2.25rem!important;
    display: none;
  }
  
  #chat-input{
    max-height: 60px !important;
    height: 60px !important;
    width: 100%;
    margin-left: 1em;
  }
  .typing-controls {
    padding-left: 15px !important;
    padding-top: 15px;
  }

  .audio-content{
    margin-left: -2em !important;
  }

  .chat .chat-details p {
    white-space: pre-wrap;
    font-size: 1.05rem;
    padding: 0 50px 0 25px;
    color: var(--text-color);
    word-break: break-word;
    width: 100%;
  }

  .chef-img-container{
    display: flex;
    position: relative;
    align-self: flex-start;
    left: -12%;
    top: 2em;
  }
}

@media screen and (max-width: 768px) {
  .typing-controls {
    margin-left: 1.5em;
    padding-top: 15px;
  }

  .typing-container .typing-textarea {
    padding-right: 0px;
  }

  .audio-content{
    margin-left: -2em !important;
  }

  .button-container {
    display: flex;
    align-items: center;
    position: relative;
    left: 12em;
    top: -4em;
  }

  .chat .chat-details p {
    white-space: pre-wrap;
    font-size: .8rem !important;
    padding: 0 50px 0 25px;
    color: #fff;
    word-break: break-word;
    width: 100%;
    /*margin-right: 24px;
    border: 1px solid #897127;*/

  }

  .chef-img-container{
    display: flex;
    position: relative;
    align-self: flex-start;
    left: -4em;
    top: 2em;
  }

  .chat .chat-res{
    display: flex;
    flex-direction: column;
    align-items: flex-end !important;
    /*width: 94%;*/
    margin-left: 0;
    border: 2px solid #1BC97E !important;
    margin-right: 0em;
  }

  .coach-chat-container {
    overflow-y: auto;
    max-height: 90vh;
    padding-bottom: 150px;
    min-height: 500px;
    padding-top: 4em;
    width: 100% !important;
    margin: auto;
    background: #0000009C;
    margin-bottom: 9em;
    position: relative;
    border-radius: 10px;
    margin-top: 4em;
    
  }

  #outgoing-title{
    font-size: 1em;
  }

  .typing-textarea{
    flex-direction: column !important;
  }
  .coach-button-container{
    justify-content: flex-end;
    margin-top: 1em;
  }

  #chat-input{
    /*margin-left: .5em !important;*/
    margin: auto;
  }

  #coach-page-content{
    /*background-image: url('../images/JUEGOS.png');
    background-repeat:repeat-x !important; */
  }
  .audio-content{
    display: flex;
    justify-content: end;
    align-self: flex-end;
    /*margin-right: 0%;*/
    height: 24px;
  }
}

@media screen and (max-width: 358px) {
  .chat .chat-res{
    display: flex;
    flex-direction: column;
    align-items: flex-end !important;
    width: 88%;
    margin-left: 4em;
  }

  #outgoing-title{
    font-size: 1em;
  }

  .coach-chat-container {
    overflow-y: auto;
    max-height: 90vh;
    padding-bottom: 150px;
    min-height: 500px;
    padding-top: 4em;
    width: 95%;
    margin: auto;
    background: #0000009C;
    margin-bottom: 9em;
    position: relative;
    border-radius: 10px;
    margin-top: 4em;
    
  }

  .typing-textarea{
    flex-direction: column !important;
  }
  .coach-button-container{
    justify-content: flex-end;
  }

  #chat-input{
    margin-left: .5em !important;
  }

  #coach-page-content{
    /*background-image: url('../images/JUEGOS.png');
    background-repeat:repeat-x !important; */
  }

  .audio-content{
    display: flex;
    justify-content: end;
    align-self: flex-end;
    margin-right: 0%;
    height: 24px;
  }
}

/***
* Sección de Gamer Coach
*
*
*/
#coach-page-content{
  /*background-image: url('../images/JUEGOS.png');
  background-repeat:round; */
}

.coach-chat-container {
  overflow-y: auto;
  max-height: 90vh;
  padding-bottom: 150px;
  min-height: 500px;
  padding-top: 4em;
  width: 80%;
  margin: auto;
  background: #0000009C;
  margin-bottom: 9em;
  position: relative;
  border-radius: 10px;
  /*margin-top: 4em;*/
  
}
:where(.coach-chat-container, textarea)::-webkit-scrollbar {
  width: 6px;
}
:where(.coach-chat-container, textarea)::-webkit-scrollbar-track {
  background: var(--incoming-chat-bg);
  border-radius: 25px;
}
:where(.coach-chat-container, textarea)::-webkit-scrollbar-thumb {
  background: var(--icon-color);
  border-radius: 25px;
}

.coach-chat-container::-webkit-scrollbar{
  display: none;
}

.coach-button-container {
  display: flex;
  align-items: center;
  position: relative;
  right: 13vw;
}