/* Custom styles for Chainlit dropdown menu */

/* Position SVG icon to the right side of menu items */
[role="menuitem"] svg {
  margin-left: auto;
}

/* Ensure user details button has same hover effects as other menu items */
#custom-menu-button:hover,
#custom-menu-button[data-highlighted] {
  background-color: var(--accent) !important;
  color: var(--accent-foreground) !important;
}

/* Match the styling of the Logout icon */
#custom-menu-button svg {
  width: 16px;
  height: 16px;
  pointer-events: none;
  flex-shrink: 0;
}


.custom-profile-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease-in-out;
  overflow: hidden;
  /* Prevent other elements from capturing events */
  pointer-events: all;
  isolation: isolate;
}

/* This important style prevents elements behind the modal from capturing events */
body.modal-open {
  overflow: hidden;
}

.custom-profile-close-button {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 30px;
  color: white;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 10000;
  transition: transform 0.2s;
}

.custom-profile-close-button:hover {
  transform: scale(1.2);
}

.custom-profile-iframe {
  width: 90%;
  height: 90%;
  border: none;
  border-radius: 8px;
  background-color: white;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  animation: zoomIn 0.3s ease-in-out;
  overflow: auto;
  display: block;
  transform: translateZ(0); /* Hardware acceleration */
  -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
  /* Ensure scrolling works */
  position: relative;
  /* Prevent parent elements from capturing events */
  pointer-events: auto;
  isolation: isolate;
}

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

@keyframes zoomIn {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}





#theme-toggle,#readme-button {
  display: none !important;
}

.watermark {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
  height: 0px !important;
  width: 0px !important;
  overflow: hidden !important;
}

#chat-input:empty::before {
  content: 'Ask anything here';
}

#message-composer {
  background-color: #FAF9F7 !important;
}

#welcome-screen .logo {
  width: 50%;
  height: auto;
  margin-bottom: 0.5rem;
}

#message-composer {
  border: 1px solid #B83839;
}

#starters button {
  /* border: 1px solid #3F3B38; */
  border-radius: 0.5rem;
  background-color: #A90F2B !important;
  color: white !important;
}

#starters button p {
  color: white !important;
}


[data-sidebar="header"] button {
  color: #B83839 !important;
}

[data-sidebar="header"] button:hover {
  color: #8B2929 !important;
  background-color: rgba(184, 56, 57, 0.1) !important;
}



#sidebar-trigger-button {
  color: #B83839 !important;
}

#sidebar-trigger-button:hover {
  color: #8B2929 !important;
  background-color: rgba(184, 56, 57, 0.1) !important;
}

#new-chat-button {
  color: #B83839 !important;
}

#new-chat-button:hover {
  color: #8B2929 !important;
  background-color: rgba(184, 56, 57, 0.1) !important;
}

#user-nav-button span {
  background-color: #B83839 !important;
  color: #FFFFFF !important;
}


[data-step-type="user_message"] .bg-accent {
  background-color: #f4f0ec !important;
}

.flex.flex-row.items-center.gap-1.w-full.group button {
  color: #B83839 !important;
  visibility: visible !important;
}

.flex.flex-row.items-center.gap-1.w-full.group button:hover {
  color: #8B2929 !important;
  background-color: rgba(184, 56, 57, 0.1) !important;
}

#upload-button {
  color: #B83839 !important;
}

#upload-button:hover {
  color: #8B2929 !important;
  background-color: rgba(184, 56, 57, 0.1) !important;
}

#command-Search {
  color: #B83839 !important;
}

#command-Search:hover {
  color: #8B2929 !important;
  background-color: rgba(184, 56, 57, 0.1) !important;
}

#chat-submit {
  background-color: #B83839 !important;
}

#chat-submit:hover {
  background-color: #8B2929 !important;
}
