/* ==========================================================================
   1. FLOATING LAUNCHER BUTTON
   ========================================================================== */
#omed-launcher-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99998;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #0f172a;
  color: #f8fafc;
  border: 1px solid #334155;
  padding: 12px 18px;
  border-radius: 50px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
}

#omed-launcher-btn:hover {
  background: #1e293b;
  transform: translateY(-2px);
}

.omed-launcher-icon {
  font-size: 18px;
}

/* ==========================================================================
   2. OVERLAY CONTAINER & BACKDROP
   ========================================================================== */
.omed-overlay-hidden {
  display: none !important;
}

#omed-full-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.omed-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(4px);
}

.omed-overlay-container {
  position: relative;
  z-index: 2;
  width: 95vw;
 /* max-width: 1200px; */
  height: 90vh;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ==========================================================================
   3. HEADER
   ========================================================================== */
.omed-overlay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: #0f172a;
  color: #ffffff;
  border-bottom: 1px solid #1e293b;
}

.omed-header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.omed-header-brand h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #f8fafc;
}

.omed-close-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
  padding: 0;
}

.omed-close-btn:hover {
  color: #ffffff;
}

/* ==========================================================================
   4. SPLIT PANE BODY
   ========================================================================== */
.omed-overlay-body {
  display: flex;
  flex: 1;
  overflow: hidden;
  background: #f8fafc;
}

/* Sidebar (LHS) */
.omed-sidebar {
  width: 320px;
  background: #ffffff;
  border-right: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  padding: 16px;
}

.omed-search-box input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 14px;
  box-sizing: border-box;
}

.omed-search-box input:focus {
  outline: none;
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.omed-search-results {
  margin-top: 16px;
  flex: 1;
  overflow-y: auto;
}

.omed-search-item {
  display: block;
  padding: 10px 12px;
  margin-bottom: 8px;
  background: #f1f5f9;
  border-radius: 6px;
  text-decoration: none;
  color: #1e293b;
  transition: background 0.15s ease;
}

.omed-search-item:hover {
  background: #e2e8f0;
}

.omed-search-item-title {
  font-weight: 600;
  font-size: 13px;
  display: block;
  margin-bottom: 2px;
}

.omed-search-item-type {
  font-size: 11px;
  color: #0284c7;
  text-transform: uppercase;
  font-weight: 700;
}

/* Main Chat Area (RHS) */
.omed-chat-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #f8fafc;
}

.omed-chat-stream {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.omed-chat-msg {
  display: flex;
  gap: 12px;
  max-width: 80%;
}

.omed-msg-bot {
  align-self: flex-start;
}

.omed-msg-user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.omed-msg-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.omed-msg-content {
  background: #ffffff;
  padding: 14px 18px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  font-size: 14px;
  line-height: 1.6;
  color: #334155;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.omed-msg-user .omed-msg-content {
  background: #0284c7;
  color: #ffffff;
  border: none;
}

.omed-msg-content p {
  margin: 0 0 10px 0;
}

.omed-msg-content p:last-child {
  margin-bottom: 0;
}

.omed-msg-content a {
  color: #0284c7;
  text-decoration: underline;
}

.omed-msg-user .omed-msg-content a {
  color: #ffffff;
}

/* Chat Input Bar */
.omed-chat-form {
  display: flex;
  gap: 12px;
  padding: 16px 24px;
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
}

.omed-chat-form textarea {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  resize: none;
  font-family: inherit;
  font-size: 14px;
  max-height: 120px;
}

.omed-chat-form textarea:focus {
  outline: none;
  border-color: #0284c7;
}

.omed-chat-form button {
  background: #0284c7;
  color: #ffffff;
  border: none;
  padding: 0 24px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.omed-chat-form button:hover {
  background: #0369a1;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .omed-sidebar {
    display: none; /* Hide LHS search on smaller mobile screens */
  }
}