.chat {
    width: 100%;
    padding: 15px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    overflow-y: scroll;
    max-height: 400px;
    overflow-y: auto;
    max-width: 400px;
    padding: 10px 25px 10px 25px;
}

.msg {
    max-width: 80%;
    padding: 15px;
    border-radius: 15px;
    margin-bottom: 10px;
    line-height: 1.4;
    font-size: 14px;
    position: relative;
    overflow-wrap: anywhere;
    width: fit-content;
}

.msg.animate {
  opacity: 0;
  transform: scale(0.15);
  animation: fadeInPopX 0.5s ease-out forwards;
}

@keyframes fadeInPopX {
  from {
    opacity: 0;
    transform: scale(0.15);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.msg::after {
    content: "";
    position: absolute;
    width: 10px;
    height: 10px;
    background: inherit;
    bottom: 0;
}

.msg.me {
    background: #0084ff;
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 3px;
}

.msg.me::after {
    right: -7px;
    bottom: 0;
    clip-path: polygon(0 0, 0 100%, 100% 100%);
}

.msg.he {
    background: #e5e5ea;
    color: black;
    align-self: flex-start;
    border-bottom-left-radius: 3px;
}

.msg.he::after {
    left: -8px;
    bottom: 0;
    clip-path: polygon(0 100%, 100% 0, 100% 100%)
}

.msginput {
    width:100%;
    font-size:18px;
    padding: 5px 25px 5px 25px;
    border:1px solid #ccc;
    box-sizing: border-box;
    border-radius: 10px;
}

.chatwin {
    white-space: normal !important;
}
