  /* Floating Chat Toggle Button */
#agent-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  padding: 0;
  cursor: pointer;
  z-index: 99999;
}

button#agent-toggle {
  background-color: transparent;
  border: none;
  border-radius: 50%;
}

#agent-toggle img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.25);
  display: block;
  animation: pulse 2.5s ease-in-out infinite;
  transition: transform 0.2s ease, box-shadow 0.3s ease;
}

/*  Removing animation for users with motion sensitivity.  */
@media (prefers-reduced-motion: reduce) {
    #agent-toggle img {
        animation: none;
    }
}

#agent-toggle:hover {
    background-color: rgba(255, 130, 0, 0.1);  
    border-radius: 50% !important; 
     
}

button#agent-toggle:hover {
    /*background-color: rgba(255, 130, 0, 0.1);  */
    /*border-radius: 50% !important; */
    /*outline: 4px solid white;*/
    /*outline: 3px solid #CD451F;*/
    outline: none; /* remove default outline */
    box-shadow: 0 0 0 4px #CD451F, 0 0 0 8px white;  
}

#agent-toggle:hover img {
    /* stops the pulse */
    /*animation: none; */
    /*pauses the pulse */
    animation-play-state: paused;
    transform: scale(1.05);
    box-shadow: 0 0 12px rgba(255, 130, 0, 0.6);
}


/*#agent-toggle:focus {*/
/*  outline: 3px solid #ff8200;*/
/*  outline-offset: 4px;*/
/*}*/


#agent-toggle:focus {
  outline: none; /* remove default blue square */
  /*box-shadow:*/
  /*  0 0 0 4px white,       */
  /*  0 0 0 8px #CD451F;      */
  box-shadow: 0 0 0 4px #CD451F, 0 0 0 8px white;    
  border-radius: 50% !important; 
}


/* Backdrop */
#agent-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.4); /* Semi-transparent black */
  display: none;
  z-index: 99998;
}


/* Chat Container */
#agent-container {
  position: fixed;
  bottom: 90px;
  right: 20px;
  width: 300px;
  height: 540px;
  display: flex;
  flex-direction: column;
  z-index: 99997;
  border-radius: 12px;
  overflow: hidden;
  background-color: #ffffff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  animation: fadeInUp 0.3s ease-out;
}

/* Header */
.agent-header {
  background-color: #cf4311; /* UTRGV orange */
  color: white;
  font-family: 'Segoe UI', sans-serif;
  font-size: 18px;
  font-weight: 600;
  text-align: center;
  padding: 12px;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  position: relative;
  padding-right: 35px;
}

/* Iframe */
#agent-container iframe {
  flex: 1;
  border: none;
  margin-top: -4em;
  height: 546px;
}

/* Animations */
@keyframes pulse {
  0% { transform: scale(1); box-shadow: 0 0 0 rgba(255, 130, 0, 0.4); }
  50% { transform: scale(1.05); box-shadow: 0 0 12px rgba(255, 130, 0, 0.6); }
  100% { transform: scale(1); box-shadow: 0 0 0 rgba(255, 130, 0, 0.4); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Optional override for Microsoft chat bubble (if needed) */
.___sr8l4b0.ffp7eso.f1phragk.f4ybsrx.fhuq1gn.f8xlz6g.f1sy4kr4.f1k1ca8a.f18iscwc.fqip68l.fekue4j.f15uksyk.fg1hbnc.f1pr8nl6.f199jv87.fx2xdas.f2jtosj.f18iiduk.fqy0vk0 {
  background-color: #cf4311 !important;
}

@media (max-width: 480px) {
  #agent-container {
    bottom: 90px;
    right: 0;
    left: 16px;
    width: 89%;
    height: 61%;
    border-radius: 0;
    max-height: 100vh;
}

  .agent-header {
    border-radius: 0;
    font-size: 18px;
    padding: 16px;
  }

  #agent-toggle {
    bottom: 16px;
    right: 16px;
    width: 56px;
    height: 56px;
}
  }

/* Accessibility: Focus styles for modal elements */
#agent-container button:focus,
#agent-container a:focus,
#agent-container input:focus,
#agent-container select:focus,
#agent-container textarea:focus,
#agent-container iframe:focus {
    outline: 3px solid #ff8200;
    outline-offset: 4px;
    border-radius: 4px;
}

#closeChatbot{
    position: absolute;
    top: 4px !important;
    height: 32px;
    /*border: none !important;*/
    color: #fff !important;
    font-size: 20px !important;
    font-weight: bold !important;
    cursor: pointer !important;
    transition: transform 0.2s ease, box-shadow 0.3s ease;
}
#closeChatbot:focus {
        /*outline: #ffffff  solid 3px !important;*/
        outline: none !important;
}