/* ============================================================
   ORBITLABS CHATBOT — chatbot.css
   Matches the dark-tech design system exactly.
   Injected after orbitbrands.css — zero conflicts.
============================================================ */

/* ── Floating Trigger Button ── */
#ob-chat-trigger {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 9998;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, #00e5ff 0%, #7c5cfc 100%);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 32px rgba(0, 229, 255, 0.25);
  transition: transform 0.25s cubic-bezier(.34,1.56,.64,1), box-shadow 0.25s;
  outline: none;
}
#ob-chat-trigger:hover {
  transform: scale(1.1) translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 229, 255, 0.35);
}
#ob-chat-trigger svg {
  width: 24px;
  height: 24px;
  fill: #0a0c10;
  transition: opacity 0.2s;
}
#ob-chat-trigger .ob-icon-chat { display: block; }
#ob-chat-trigger .ob-icon-close { display: none; }
#ob-chat-trigger.is-open .ob-icon-chat { display: none; }
#ob-chat-trigger.is-open .ob-icon-close { display: block; }

/* Pulse ring when closed */
#ob-chat-trigger::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 18px;
  background: linear-gradient(135deg, #00e5ff, #7c5cfc);
  z-index: -1;
  opacity: 0;
  animation: ob-pulse-ring 3s ease-in-out infinite;
}
@keyframes ob-pulse-ring {
  0%, 100% { opacity: 0; transform: scale(1); }
  50%       { opacity: 0.3; transform: scale(1.18); }
}
#ob-chat-trigger.is-open::before { animation: none; opacity: 0; }

/* Unread badge */
#ob-chat-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ff4757;
  border: 2px solid #0a0c10;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  transition: transform 0.3s cubic-bezier(.34,1.56,.64,1);
}
#ob-chat-badge.hidden { transform: scale(0); }

/* ── Chat Window ── */
#ob-chat-window {
  position: fixed;
  bottom: 96px;
  right: 28px;
  z-index: 9999;
  width: 380px;
  max-height: 580px;
  background: #111520;
  border: 1px solid #1e2535;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(0,229,255,0.08);
  transform-origin: bottom right;
  transform: scale(0.85) translateY(16px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(.34,1.56,.64,1), opacity 0.25s ease;
}
#ob-chat-window.is-visible {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: all;
}

/* ── Header ── */
#ob-chat-header {
  background: linear-gradient(135deg, rgba(0,229,255,0.08) 0%, rgba(124,92,252,0.08) 100%);
  border-bottom: 1px solid #1e2535;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.ob-avatar {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #00e5ff 0%, #7c5cfc 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
  font-weight: 800;
  color: #0a0c10;
  font-family: 'Syne', sans-serif;
}
.ob-header-info { flex: 1; }
.ob-header-name {
  font-family: 'Syne', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: #f0f4ff;
  line-height: 1.2;
}
.ob-header-status {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: #6b7a99;
  font-family: 'Space Grotesk', sans-serif;
  margin-top: 2px;
}
.ob-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #00e5ff;
  animation: ob-blink 2s ease-in-out infinite;
}
@keyframes ob-blink { 0%,100%{opacity:1} 50%{opacity:.3} }

/* ── FAQ Pills ── */
#ob-faq-section {
  padding: 14px 16px 0;
  flex-shrink: 0;
  border-bottom: 1px solid #1e2535;
  padding-bottom: 14px;
}
.ob-faq-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #6b7a99;
  font-family: 'Space Grotesk', sans-serif;
  margin-bottom: 10px;
}
.ob-faq-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.ob-faq-pill {
  display: inline-block;
  background: rgba(0,229,255,0.06);
  border: 1px solid rgba(0,229,255,0.15);
  border-radius: 100px;
  padding: 5px 12px;
  font-size: 11px;
  font-weight: 600;
  color: #c8d0e0;
  font-family: 'Space Grotesk', sans-serif;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  white-space: nowrap;
}
.ob-faq-pill:hover {
  background: rgba(0,229,255,0.12);
  border-color: rgba(0,229,255,0.4);
  color: #00e5ff;
}

/* ── Messages Area ── */
#ob-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scroll-behavior: smooth;
}
#ob-messages::-webkit-scrollbar { width: 4px; }
#ob-messages::-webkit-scrollbar-track { background: transparent; }
#ob-messages::-webkit-scrollbar-thumb { background: #1e2535; border-radius: 4px; }

/* ── Message Bubbles ── */
.ob-msg {
  display: flex;
  gap: 8px;
  max-width: 90%;
  animation: ob-msg-in 0.25s cubic-bezier(.34,1.56,.64,1);
}
@keyframes ob-msg-in {
  from { opacity: 0; transform: translateY(8px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0)  scale(1); }
}
.ob-msg.user { align-self: flex-end; flex-direction: row-reverse; }
.ob-msg.bot  { align-self: flex-start; }

.ob-msg-avatar {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  font-family: 'Syne', sans-serif;
  margin-top: 2px;
}
.ob-msg.bot  .ob-msg-avatar { background: linear-gradient(135deg,#00e5ff,#7c5cfc); color: #0a0c10; }
.ob-msg.user .ob-msg-avatar { background: #1e2535; color: #c8d0e0; }

.ob-msg-bubble {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.6;
  font-family: 'Space Grotesk', sans-serif;
}
.ob-msg.bot  .ob-msg-bubble {
  background: #0f1420;
  border: 1px solid #1e2535;
  color: #c8d0e0;
  border-bottom-left-radius: 4px;
}
.ob-msg.user .ob-msg-bubble {
  background: linear-gradient(135deg, rgba(0,229,255,0.12), rgba(124,92,252,0.12));
  border: 1px solid rgba(0,229,255,0.2);
  color: #f0f4ff;
  border-bottom-right-radius: 4px;
}

/* ── Typing Indicator ── */
.ob-typing {
  display: flex;
  gap: 4px;
  align-items: center;
  padding: 12px 14px;
}
.ob-typing span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #00e5ff;
  animation: ob-typing-bounce 1.2s ease-in-out infinite;
}
.ob-typing span:nth-child(2) { animation-delay: 0.2s; }
.ob-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes ob-typing-bounce {
  0%,60%,100% { transform: translateY(0); opacity: 0.4; }
  30%          { transform: translateY(-6px); opacity: 1; }
}

/* ── Input Area ── */
#ob-chat-input-area {
  border-top: 1px solid #1e2535;
  padding: 12px 14px;
  display: flex;
  gap: 10px;
  align-items: flex-end;
  flex-shrink: 0;
  background: #0d111a;
}
#ob-user-input {
  flex: 1;
  background: #0a0c10;
  border: 1px solid #1e2535;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13px;
  font-family: 'Space Grotesk', sans-serif;
  color: #f0f4ff;
  outline: none;
  resize: none;
  line-height: 1.5;
  max-height: 100px;
  transition: border-color 0.2s;
  scrollbar-width: none;
}
#ob-user-input::-webkit-scrollbar { display: none; }
#ob-user-input::placeholder { color: #6b7a99; }
#ob-user-input:focus { border-color: rgba(0,229,255,0.4); }

#ob-send-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #00e5ff 0%, #7c5cfc 100%);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: opacity 0.2s, transform 0.2s;
}
#ob-send-btn:hover:not(:disabled) { opacity: 0.85; transform: scale(1.05); }
#ob-send-btn:disabled { opacity: 0.4; cursor: not-allowed; }
#ob-send-btn svg { width: 16px; height: 16px; fill: #0a0c10; }

.ob-input-hint {
  font-size: 10px;
  color: #3a4560;
  font-family: 'Space Grotesk', sans-serif;
  text-align: center;
  padding: 0 14px 10px;
  background: #0d111a;
}

/* ── Error state ── */
.ob-msg-error .ob-msg-bubble {
  background: rgba(255,71,87,0.08);
  border-color: rgba(255,71,87,0.2);
  color: #ff6b78;
}

/* ── Mobile ── */
@media (max-width: 480px) {
  #ob-chat-window {
    right: 12px;
    left: 12px;
    width: auto;
    bottom: 88px;
    max-height: 70vh;
  }
  #ob-chat-trigger {
    right: 18px;
    bottom: 20px;
  }
}
