
#iris-widget-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent !important;
}
/** if not using iframe iris-container is the outter most container, it's instantiated in bot-loader */
#iris-container {   
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 2147483647;
    border: none;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25), 0 2px 8px rgba(0,0,0,0.15);
    border-radius: 10px 10px 0px 0px;
    overflow: hidden;
    background: transparent !important;
}
#iris-iframe {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 2147483647;
    border: none;/** 1px solid #ccc; */
    border-radius: 10px 10px 0px 0px;
    overflow: hidden;
}
#iris-iframe.min,
#iris-iframe.full {
  box-shadow: 0 8px 32px rgba(0,0,0,0.25), 0 2px 8px rgba(0,0,0,0.15);
}
#iris-iframe.icon { width: 64px; height: 64px;  }
#iris-iframe.min  { width: 404px; height: 304px;  }
#iris-iframe.full { width: 404px; height: 644px;  }

#iris-icon {
    cursor: pointer;
    display: block; /* Initially visible */
    width: 44px;
    height: 44px;
    background: transparent !important;
}

#iris-icon.hidden {
    display: none;
}
#iris-icon img {
    width: 100%; /* Makes sure the image fits within its container */
    height: auto; /* Maintains aspect ratio */
    display: block; /* Ensures no extra space below the image */
    background: transparent !important;
}
/* State classes for DOM-injected chat */
/** if using iris-iframe, the iframe class determins the size of the window
if not using iris-iframe, default to iris-container, then iris-chat-window determins the size */
#iris-chat-window.min  { width: 400px; height: 300px; }
#iris-chat-window.full { width: 400px; height: 640px; }



#iris-chat-window {
    display: none; /* Initially hidden, when visible it will be flex so one of the child elements can grow -main */
    flex-direction: column;
    box-sizing: border-box;
    width: 400px;
    min-width: 320px;
    margin: 0;
    padding: 0;
    height: 640px;
    position: relative;
    background-color: white;
}
#iris-chat-window.visible {
    display: flex;
}

@media (max-width: 480px) {
  /* "min" mode: covers 40% of viewport height */
  #iris-container.min,
  #iris-chat-window.min,
  #iris-iframe.min {
    width: 100vw !important;
    height: 40vh !important; /* Adjust as needed */
    border-radius: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    top: auto !important; /* Ensures it stays at the bottom */
    position: fixed !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 2147483647 !important;
    box-sizing: border-box !important;
  }
    /* "full" mode: covers 60% of viewport height */
    #iris-container.full,
    #iris-chat-window.full,
    #iris-iframe.full {
      width: 100vw !important;
      height: 60vh !important; /* Adjust as needed */
      border-radius: 0 !important;
      left: 0 !important;
      right: 0 !important;
      bottom: 0 !important;
      top: auto !important; /* Ensures it stays at the bottom */
      position: fixed !important;
      margin: 0 !important;
      padding: 0 !important;
      z-index: 2147483647 !important;
      box-sizing: border-box !important;
    }
    /**
    #iris-container.min,
    #iris-container.full,
    #iris-chat-window.min,
    #iris-chat-window.full,
    #iris-iframe.min,
    #iris-iframe.full {
      width: 100vw !important;
      height: 100vh !important;
      border-radius: 0 !important;
      left: 0 !important;
      right: 0 !important;
      top: 0 !important;
      bottom: 0 !important;
      position: fixed !important;
      margin: 0 !important;
      padding: 0 !important;
      z-index: 2147483647 !important;
      box-sizing: border-box !important;
    }  */   
  }

#iris-top-container, #iris-middle-container, #iris-bottom-container {
    box-sizing: border-box; /* Includes padding and border in element's total width and height */
    width: 100%; /* Ensures all sections have the same width */
}
#iris-top-container {
    /* position: sticky; <-- REMOVE */
    /* top: 0;           <-- REMOVE */
    padding: 0;
    /* background-color: red;  <-- REMOVE */
    flex: 0 0 60px;/** height: 60px; */
    z-index: 10; /* Ensures the header stays on top */

}
#iris-banner {
    display: flex;
    opacity: 1 !important;
   /** border-radius: 10px 10px 0px 0px; */
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
}

#iris-banner #left-side {
    display: flex;
    align-items: center;
    gap: 10px; 
}

#iris-banner #left-side #company-name {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start; /* ensures left alignment */
    margin-left: 12px; /* space between avatar and text */
    font-family: "Lato", serif !important;
}

#iris-banner #left-side .assistant-name {
    font-size: 14px;
    font-family: "Open Sans", "Lato", Arial, sans-serif;
    font-weight: 600;
    line-height: 1.2;
    color: white;
    margin-bottom: 4px;
}

#iris-banner #left-side .assistant-desc {
    font-size: 11px;
    font-family: "Open Sans", Lato, Arial, sans-serif;
    font-weight: 400;
    color: white;
    line-height: 1.2;
}


#iris-banner #left-side .assistant-avatar {
    width: 40px; 
    height: 40px; 
    object-fit: cover; 
    border-radius: 50%; 
}

#iris-banner #right-side #close-btn {
    background: transparent;
    color: #f3f4f6 !important; 
    border: none;
    cursor: pointer;
    padding: 0;
    margin-left: 0px; 
    margin-right: 10px;
    opacity: 0.7;
    font-size: medium;
    transition: color 0.3s ease;
}
#iris-banner #right-side #close-btn:hover {
    font-size: large;
    opacity: 1; /* Fading effect on hover */
}


#iris-bottom-container {
     /* position: sticky;  <-- REMOVE */
    /* bottom: 10px;      <-- REMOVE */
    padding-top: 10px;
    padding-bottom: 10px;
    padding-left: 10px;
    padding-right: 10px;
    width: 100%;
   /*  background-color: green; */
    flex: 0 0 100px;           /* height: 120px; input-field is 60px + upper and lower padding of 20 each */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
} 

#iris-middle-container {
    flex: 1 1 auto;
    overflow-y: auto;
    position: relative;
    /** background-color: yellow; */
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    padding-left: 10px;
    padding-right: 10px;
    padding-bottom: 20px;
    padding-top: 0px;
    width: 100%;
    box-sizing: border-box;
}

#iris-middle-container .chatbot-avatar .assistant-avatar {
    width: 70px; 
    height: auto;
}

#iris-middle-container .chatbot-avatar {
    margin-top: 24px;
    display: flex;
    flex-direction: column; 
    justify-content: center; 
    align-items: center; 
    width: 100%;
    gap: 16px;
}
#iris-middle-container .chatbot-avatar #assistant-name {
    margin: 0; 
    padding: 0; 
    color: #404040;
}
#iris-middle-container .chatbot-avatar #assistant-description {
    color: #78716c;
}


#iris-chat-history {
  /**  background-color: blueviolet; */
    padding-top: 24px;
    display: grid;
    grid-template-columns: 10% 80% 10%;
    gap: 12px 0px;
    width: 100% ; 
    align-content: start;
}


#iris-chat-history .bot-message {
    background-color: white;
    grid-column: 1 / span 2; 
    display: flex; 
    align-items: center; 
}

#iris-chat-history .bot-message img {
    width: 26px; 
    height: auto;
    margin-right: 5px; 
}
#iris-chat-history .bot-message div{
    background-color: #e4e4e7;
    color: black;
    text-align: left;
    border-radius: 8px;
    padding: 12px;
    height: auto;
    width: -moz-fit-content; 
    width: fit-content; 
    box-sizing: border-box;
    line-height: 1.4;
}
#waiting-dots-message #lottie-container {
    background-color: transparent; /*should be transparent */
    width: 72px;
    height: 72px;
    gap: 5px;

    display: flex;
    justify-content: center;
    align-items: center;

}


  
  /* Dots */
 #lottie-container .dot {
    width: 8px;
    height: 8px;
    background-color: #999ea4; /* Blue color */
    border-radius: 50%;

   
    animation: typing-dots 1.5s infinite; 
  }
  
  /**Delay animations for each dot */
  #lottie-container .dot:nth-child(2) {
     animation-delay: 0.2s; 
  }
  #lottie-container .dot:nth-child(3) {
     animation-delay: 0.4s; 
  }

  @keyframes typing-dots {
    0%, 80%, 100% {
      opacity: 0;
      transform: scale(0.8);
    }
    40% {
      opacity: 1;
      transform: scale(1);
    }
  }
  

#iris-chat-history .user-message {
    display: flex; 
    background-color:white;
    grid-column: 2 / span 2; 
    max-width: 100%; 
    align-self: center; 
    justify-content: flex-end; 
    
}
#iris-chat-history .user-message div{
    background-color: black;
    color: white;
    text-align: left;
    border-radius: 8px;
    padding: 12px;
    height: auto;
    width: -moz-fit-content; 
    width: fit-content; 
    box-sizing: border-box;
    line-height: 1.4;
}


/* Adjust the wrapper to ensure it doesn't affect layout negatively */
#iris-input-field {
    display: flex;
    align-items: center;
    height: 56px; /* Adjusted to auto to accommodate content */
    width: 100%;
   
    padding: 10px 10px;
    margin: 0;
    box-sizing: border-box;
    border: 2px solid #9ca3af;
    border-radius: 6px;
    position: relative;
    background-color: white;
}

#iris-input-field #iris-user-input {
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    height: 100%;
    color: black;
    width: calc(100% - 34px); /* Adjusts the width to leave room for the icon */
    border: none;
    outline: none; /* Invisible border around the textarea */
    resize: none;
    line-height: 1.4;
}



#iris-input-field .fa-arrow-circle-up {
    color: black;
    position: absolute;
    font-size: 24px;
    right: 10px; /* Positions the icon 10px from the right edge */
    top: 50%; /* Positions the icon 10px from the bottom edge */
    transform: translateY(-50%);
    cursor: pointer; /* Changes cursor to pointer to indicate clickable */
    opacity: 0.5; 
    transition: opacity 0.3s ease; 
}

#iris-input-field .fa-arrow-circle-up:hover {
    opacity: 0.8; 
    font-size: 28px;
}

#iris-middle-container .preserve-whitespace {
    white-space: pre-wrap;
}

.iris-powered-by {
    font-family: 'DM Sans', 'Roboto', 'Lato', 'Verdana', 'Helvetica', Arial, sans-serif;
    margin-top: 2px;
    text-align: center;
    font-size: 10px;
    color: #888;
    width: 100%;
}



.iris-powered-by a {
    color: #888;
    text-decoration: none;
    font-weight: normal;
    transition: color 0.2s;
}

.iris-powered-by a:hover,
.iris-powered-by .askiris-link:hover {
    color: #888;                  /* Keep gray on hover */
    text-decoration: underline;   /* Underline on hover */
}

.askiris-link {
    font-weight: bold;
    color: #888;                  /* Make AskIris gray, not blue */
}


