:host {
  flex-grow: 1;
  overflow: hidden;
  display: flex;
  --popup-label-color: var(--text-primary-color);
  --popup-options-color: var(--bg-primary-light);
}

@font-face {
  font-family: 'Simpli Norm';
  src: url('../../../assets/fonts/SimpliNorm-Regular.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
}

#outgoing-message > * {
  display: flex;
  width: fit-content;
  justify-content: end;
  max-width: 80%;
}

::-webkit-scrollbar {
  width: 0;
}

::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background-color: var(--bg-secondary-color) !important;
  border-radius: 10px;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background: red;
  z-index: 999;
}
.popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  display: flex !important;
  flex-direction: column !important;
  align-items: flex-start !important;
  width: 320px !important;
  gap: 12px !important;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2), 0 2px 4px rgba(0, 0, 0, 0.1);
  font-family: 'Roboto';
  padding: 30px;
  font-weight: 500;
  border-radius: 8px;
  background: var(--bg-primary-color);
}

.popup span {
  cursor: pointer;
}

#incoming-message {
  position: relative;
  display: flex;
  width: fit-content;
  max-width: 80%;
}


.chat-body {
  scroll-behavior: auto;
  transition: scrollTop 0.3s ease-in-out;
  display: flex;
  flex-grow: 1;
  flex-direction: column;
  gap: 20px;
  padding: 10px 15px 35px 10px;
  overflow-y: scroll;
  position: relative;
  background-color: var(--bg-primary-color);
}

.chat-body.unscrollable {
  overflow-y: hidden;
}

.deleteText {
  font-size: 16px;
  font-weight: 400;
  border-radius: 24px;
  padding: 12px 20px;
  margin-left: auto;
  width: auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
  background: var(--popup-options-color);
  border: 1px solid var(--popup-options-color);
}

.deleteText:nth-child(2) {
  border: 1px solid var(--popup-options-color) !important;
  background: var(--popup-options-color);
}

.popup-label {
  font-size: 20px;
  font-weight: 400;
  margin-bottom: 8px;
  text-align: left;
  width: 100%;
  justify-content: flex-start;
  color: var(--popup-label-color);
}

.messageActionPopup {
  position: absolute;
  width: 9rem;
  max-width: 10rem;
  display: flex;
  flex-direction: column;
  z-index: 9999;
  border-radius: 5px;
  background: var(--bg-primary-color);
  color: var(--popup-label-color);
  box-shadow: var(--menu-shadow);
  font-size: 14px;
  align-items: center;
  padding: 2px;
  transition: top 0.2s, bottom 0.2s;
}

.messageActionPopup.position-top {
  bottom: 100%;
}

.messageActionPopup.position-bottom {
  top: 0;
}

.messageActionPopup button {
  background: transparent;
  color: var(--text-primary-color);
  padding: 10px;
  width: 93%;
  border: none;
  outline: none;
  display: flex;
  align-items: center;
  cursor: pointer;
  gap: 14px
}

.kebab-menu {
  cursor: pointer;
  position: absolute;
  top: 5px;
  -webkit-tap-highlight-color: transparent;
}

.kebab-menu-left {
  left: -12px;
}

.kebab-menu-right {
  right: -12px;
}

.custom-reply-block {
  background: var(--bg-secondary-color);
  position: fixed;
  z-index: 2;
  bottom: 65px;
  width: 72vw !important;
  border-left: 5px solid var(--bg-primary-light);
}

reply-block {
  width: 100%;
}

.highlighted {
  animation: highlight 2s ease-out;
}

.message-info-container {
  position: fixed;
  top: 0;
  right: 0;
  width: 25%;
  min-width: var(--sidebar-width);
  height: 100%;
  box-shadow: -2px 0 5px rgba(0, 0, 0, 0.2);
  z-index: 999;
  background-color: var(--bg-primary-color);
}


.popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 999;
}

.searchable-list {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1000;
  width: 25%;
  min-width: var(--sidebar-width);
}
.spinner-wrapper {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  justify-content: center;
  align-items: center;
}
.messagePillContainer {
  max-width: 50%;
  word-break: break-word;
  font-size: 12px;
  color: var(--text-tertiary-color);
  background-color: var(--bg-grey-color);
  padding:5px 20px;
  border-radius: 9px;
  text-align: center;
}
@media (max-width: 768px) {
  .deleteText {
    padding: 1rem 2rem;
    font-size: 16px;
    width: 80%;
  }
  .message-info-container {
    width: 100%;
  }
  .messagePillContainer{
    max-width: 80%; 
  }

  .searchable-list {
    width: 100%;
    height: 100%;
  }

  .popup {
    width: 50% !important;
  }
  .popup-label {
    font-size: 24px;
    margin-bottom: 10px;
  }
  .custom-reply-block {
    width: 100vw !important;
  }
}

@keyframes highlight {
  0% {
    background-color: var(--bg-primary-light);
  }
  100% {
    background-color: transparent;
  }
}
