
.imessage {
    background-color: #fff;
    border-radius: 0.25rem;
    display: flex;
    flex-direction: column;
    font-family: "SF Pro Text";
    font-size: 11pt;
    margin: 0 auto 1rem;
    padding: 0.5rem 1.5rem;
  }
  
  .imessage p {
    border-radius: 1.15rem;
    line-height: 1.25;
    max-width: 75%;
    padding: 0.5rem .875rem;
    position: relative;
    word-wrap: break-word;
  }
  
  .imessage p::before,
  .imessage p::after {
    bottom: -0.1rem;
    content: "";
    height: 1rem;
    position: absolute;
  }

  .imessage p {
    border-radius: 1.15rem;
    line-height: 1.25;
    max-width: 75%;
    padding: 0.5rem .875rem;
    position: relative;
    word-wrap: break-word;
  }
  
  .imessage p::before,
  .imessage p::after {
    bottom: -0.1rem;
    content: "";
    height: 1rem;
    position: absolute;
  }
  
  p.from-me {
    align-self: flex-end;
    background-color: #248bf5;
    color: #fff; 
  }
  
  p.from-me::before {
    border-bottom-left-radius: 0.8rem 0.7rem;
    border-right: 1rem solid #248bf5;
    right: -0.35rem;
    transform: translate(0, -0.1rem);
  }
  
  p.from-me::after {
    background-color: #fff;
    border-bottom-left-radius: 0.5rem;
    right: -40px;
    transform:translate(-30px, -2px);
    width: 10px;
  }
  
  p[class^="from-"] {
    margin: 0.5rem 0;
    width: fit-content;
  }
  
  p.from-me ~ p.from-me {
    margin: 0.25rem 0 0;
  }
  
  p.from-me ~ p.from-me:not(:last-child) {
    margin: 0.25rem 0 0;
  }
  
  p.from-me ~ p.from-me:last-child {
    margin-bottom: 0.5rem;
  }
  
  p.from-them {
    align-items: flex-start;
    background-color: #e5e5ea;
    color: #000;
  }
  
  p.from-them:before {
    border-bottom-right-radius: 0.8rem 0.7rem;
    border-left: 1rem solid #e5e5ea;
    left: -0.35rem;
    transform: translate(0, -0.1rem);
  }
  
  p.from-them::after {
    background-color: #fff;
    border-bottom-right-radius: 0.5rem;
    left: 20px;
    transform: translate(-30px, -2px);
    width: 10px;
  }
  
  p[class^="from-"].emoji {
    background: none;
    font-size: 2.5rem;
  }
  
  p[class^="from-"].emoji::before {
    content: none;
  }
  
  .no-tail::before {
    display: none;
  }
  
  .margin-b_none {
    margin-bottom: 0 !important;
  }
  
  .margin-b_one {
    margin-bottom: 1rem !important;
  }
  
  .margin-t_one {
    margin-top: 1rem !important;
  }
  .imessage .prompt-loader {
    border-radius: 1.15rem;
    line-height: 1.25;
    max-width: 75%;
    padding: 0.5rem .875rem;
    position: relative;
    word-wrap: break-word;
  }
  
  .imessage .prompt-loader::before,
  .imessage .prompt-loader::after {
    bottom: -0.1rem;
    content: "";
    height: 1rem;
    position: absolute;
  }

  .imessage .prompt-loader {
    border-radius: 1.15rem;
    line-height: 1.25;
    max-width: 75%;
    padding: 0.5rem .875rem;
    position: relative;
    word-wrap: break-word;
  }
  
  .imessage .prompt-loader::before,
  .imessage .prompt-loader::after {
    bottom: -0.1rem;
    content: "";
    height: 1rem;
    position: absolute;
  }
  
  .prompt-loader.from-me {
    align-self: flex-end;
    background-color: #248bf5;
    color: #fff; 
  }
  
  .prompt-loader.from-me::before {
    border-bottom-left-radius: 0.8rem 0.7rem;
    border-right: 1rem solid #248bf5;
    right: -0.35rem;
    transform: translate(0, -0.1rem);
  }
  
  .prompt-loader.from-me::after {
    background-color: #fff;
    border-bottom-left-radius: 0.5rem;
    right: -40px;
    transform:translate(-30px, -2px);
    width: 10px;
  }
  
  .prompt-loader[class^="from-"] {
    margin: 0.5rem 0;
    width: fit-content;
  }
  
  .prompt-loader.from-me ~ .prompt-loader.from-me {
    margin: 0.25rem 0 0;
  }
  
  .prompt-loader.from-me ~ .prompt-loader.from-me:not(:last-child) {
    margin: 0.25rem 0 0;
  }
  
  .prompt-loader.from-me ~ .prompt-loader.from-me:last-child {
    margin-bottom: 0.5rem;
  }
  
  .prompt-loader.from-them {
    align-items: flex-start;
    background-color: #e5e5ea;
    color: #000;
  }
  
  .prompt-loader.from-them:before {
    border-bottom-right-radius: 0.8rem 0.7rem;
    border-left: 1rem solid #e5e5ea;
    left: -0.35rem;
    transform: translate(0, -0.1rem);
  }
  
  .prompt-loader.from-them::after {
    background-color: #fff;
    border-bottom-right-radius: 0.5rem;
    left: 20px;
    transform: translate(-30px, -2px);
    width: 10px;
  }
  
  .prompt-loader[class^="from-"].emoji {
    background: none;
    font-size: 2.5rem;
  }
  
  .prompt-loader[class^="from-"].emoji::before {
    content: none;
  }
  
  
  
  .no-tail::before {
    display: none;
  }
  
  .margin-b_none {
    margin-bottom: 0 !important;
  }
  
  .margin-b_one {
    margin-bottom: 1rem !important;
  }
  
  .margin-t_one {
    margin-top: 1rem !important;
  }
  .card-container{
    width: 100%; 
    height: 95vh; 
    max-height: 100vh; 
    width: 700px; 
    max-width: 700px;
  }
  .ai-body{
    width: 100%; 
    height: 100vh;
  }
  
  @media screen and (max-width: 767px) {

    .ai-body{
        width: 100%; 
        height: 94vh;
      }

    .container {
      padding: 0.5rem;
    }
  
    .imessage {
      font-size: 1.05rem;
      margin: 0 auto 1rem;
      max-width: 600px;
      padding: 0.25rem 0.875rem;
    }
  
    .imessage .prompt-loader {
      margin: 0.5rem 0;
    }
    .card-container{
        width: 100%; 
        height: 85vh; 
        max-height: 100vh; 
        width: 700px; 
        max-width: 700px;
      }
  }
  /* .ai-badge {
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInUp 0.5s forwards;
  } */

  .ai-badge {
    all: unset;
    display: inline-block;
    border: 1px solid var(--bs-secondary);
    color: var(--bs-dark);
    border-radius: 0.25rem;
    background-color: transparent;
    cursor: pointer;
    transition: border-color 0.3s ease;
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInUp 0.5s forwards;
  }
  .ai-badge:hover {
    border-color: rgb(16, 32, 48) !important;
    color: #fff !important;
    background-color: rgb(16, 32, 48) !important;;
  }  
  .card{
    --bs-card-spacer-y: 8px;
    --bs-card-spacer-x: 8px;
  }
  
  
  @keyframes fadeInUp {
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  