/* Simple chatbot widget styles */
:root {
  --cb-primary: #0051A4;
  --cb-bg: #ffffff;
  --cb-text: #1a1a1a;
}

#mscb-chatbot-bubble {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--cb-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 25px rgba(0,0,0,0.15);
  cursor: pointer;
  z-index: 9999;
}
#mscb-chatbot-bubble svg { width: 28px; height: 28px; fill: #fff; }

#mscb-chatbot-panel {
  position: fixed;
  right: 24px;
  bottom: 100px;
  width: 360px;
  max-width: calc(100vw - 32px);
  height: 520px;
  max-height: calc(100vh - 140px);
  background: var(--cb-bg);
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.20);
  overflow: hidden;
  display: none;
  flex-direction: column;
  z-index: 9999;
  border: 1px solid rgba(0,0,0,0.06);
}

#mscb-chatbot-header {
  background: var(--cb-primary);
  color: #fff;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#mscb-chatbot-header .brand { display: flex; align-items: center; gap: 10px; }
#mscb-chatbot-header .brand .logo { height: 24px; width: auto; display: block; border-radius: 4px; background: #fff; padding: 2px; }
#mscb-chatbot-header .title { font-weight: 700; font-size: 14px; }
#mscb-chatbot-header .close { cursor: pointer; opacity: 0.9; }

#mscb-chatbot-body { flex: 1; overflow-y: auto; background: #f6f8fb; padding: 14px; }

.mscb-msg { display: flex; gap: 8px; padding: 6px 8px; }
.mscb-msg .bubble {
  max-width: 85%;
  padding: 12px 14px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.4;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}
.mscb-msg.bot { justify-content: flex-start; }
.mscb-msg.bot .bubble { background: #eaf2fd; color: var(--cb-text); border-bottom-left-radius: 6px; }
.mscb-msg.user { justify-content: flex-end; }
.mscb-msg.user .bubble { background: var(--cb-primary); color: #fff; border-bottom-right-radius: 6px; }

#mscb-chatbot-footer { padding: 12px; background: #fff; border-top: 1px solid #eceff3; }
#mscb-input-row { display: flex; gap: 8px; align-items: center; }
#mscb-input { flex: 1; border: 1px solid #dee6f2; border-radius: 999px; padding: 12px 14px; font-size: 14px; background: #f7f9fc; outline: none; transition: border-color .2s, background .2s; }
#mscb-input:focus { border-color: #c8d7ee; background: #fff; }
#mscb-send { background: var(--cb-primary); color: #fff; border: 0; border-radius: 999px; padding: 10px 16px; cursor: pointer; box-shadow: 0 6px 16px rgba(0,81,164,0.25); transition: transform .05s ease; }
#mscb-send:active { transform: translateY(1px); }

.mscb-quick { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 4px; }
.mscb-chip {
  background: #fff;
  border: 1px solid #dbe3ee;
  color: var(--cb-text);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  cursor: pointer;
  box-shadow: 0 1px 6px rgba(0,0,0,0.05);
}

.mscb-form { padding: 12px; display: grid; gap: 12px; }
.mscb-form .row { display: grid; gap: 10px; }
.mscb-form input, .mscb-form select, .mscb-form textarea {
  width: 100%;
  border: 1px solid #dee6f2;
  border-radius: 12px;
  padding: 12px 12px;
  font-size: 14px;
  background: #fff;
  box-shadow: 0 1px 6px rgba(0,0,0,0.05);
}
.mscb-form textarea { min-height: 100px; resize: vertical; }
.mscb-form .actions { display: flex; gap: 8px; justify-content: flex-end; }
.mscb-btn { background: var(--cb-primary); color: #fff; border: 0; border-radius: 12px; padding: 10px 16px; cursor: pointer; box-shadow: 0 6px 16px rgba(0,81,164,0.25); }
.mscb-btn.secondary { background: #e9edf5; color: #0a2540; }

/* Small helpers */
.mscb-hidden { display: none !important; }

@media (max-width: 480px) {
  #mscb-chatbot-panel { right: 16px; left: 16px; width: auto; bottom: 90px; }
}

/* Toast */
#mscb-toast {
  position: fixed;
  right: 24px;
  bottom: 90px; /* just above the bubble */
  background: #0a2540;
  color: #fff;
  border-radius: 10px;
  padding: 10px 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  z-index: 10000;
}
#mscb-toast.show {
  opacity: 1;
  transform: translateY(0);
}
