/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

 @import url('https://cdn.jsdelivr.net/npm/bulma@1.0.2/css/bulma.min.css');


.layout {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.layout-main {
  flex: 1;
}

/* Messages container */
.messages {
  max-height: 70vh;
  overflow-y: auto;
  scroll-behavior: smooth;
}

/* Message fragment container */
#message_fragments {
  padding: 1.5rem;
  line-height: 1.6;
  font-size: 1rem;
  word-wrap: break-word;
}

/* Message fragment inline display */
.message-fragment {
  display: inline;
  position: relative;
  white-space: normal;
}

.fragment-content {
  display: inline;
  padding: 0;
  border-radius: 3px;
  transition: background-color 0.2s ease;
  white-space: normal;
}

.message-fragment-hover:hover {
  background-color: rgba(0, 0, 0, 0.05);
  padding: 2px 4px;
  margin: -2px -4px;
}


/* Smooth appearance for new fragments */
.message-fragment {
  animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.recording {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  position: relative;
  animation: recording 1s linear infinite;
  display: inline-block;
  margin: 1rem auto;
}

.recording::before,
.recording::after {
  content: "";
  box-sizing: border-box;
  position: absolute;
  inset: 0px;
  border-radius: 50%;
  border: 5px solid #000000;
  animation: recording-prixClipFix 2s linear infinite;
}

.recording::after {
  border-color: #FF335C;
  animation: recording-prixClipFix 2s linear infinite, rotate 0.5s linear infinite reverse;
  inset: 6px;
}

@keyframes recording {
  0% {
    transform: rotate(0deg)
  }

  100% {
    transform: rotate(360deg)
  }
}

@keyframes recording-prixClipFix {
  0% {
    clip-path: polygon(50% 50%, 0 0, 0 0, 0 0, 0 0, 0 0)
  }

  25% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 0, 100% 0, 100% 0)
  }

  50% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 100% 100%, 100% 100%)
  }

  75% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 0 100%, 0 100%)
  }

  100% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 0 100%, 0 0)
  }
}

.listening {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  position: relative;
  animation: listening 1s linear infinite;
  display: inline-block;
  margin: 1rem auto;
}

.listening::before {
  content: "";
  box-sizing: border-box;
  position: absolute;
  inset: 0px;
  border-radius: 50%;
  border: 5px solid #000000;
  animation: listening-prixClipFix 2s linear infinite;
}

@keyframes listening {
  100% {
    transform: rotate(360deg)
  }
}

@keyframes listening-prixClipFix {
  0% {
    clip-path: polygon(50% 50%, 0 0, 0 0, 0 0, 0 0, 0 0)
  }

  25% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 0, 100% 0, 100% 0)
  }

  50% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 100% 100%, 100% 100%)
  }

  75% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 0 100%, 0 100%)
  }

  100% {
    clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 0 100%, 0 0)
  }
}