/* Chatbot demo styles - extends theme.css */

.demo-header {
  padding: 32px 48px 0;
}
.demo-header-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.demo-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(168,255,87,0.1);
  border: 1px solid rgba(168,255,87,0.2);
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
  font-family: var(--font-display);
}
.demo-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.demo-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 800;
  letter-spacing: -1px;
  color: var(--fg);
  margin-bottom: 10px;
}
.demo-subtitle {
  font-size: 15px;
  color: var(--fg-muted);
  max-width: 560px;
}

/* TWO-COLUMN LAYOUT */
.demo-layout {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 48px 80px;
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 32px;
  align-items: start;
}

/* CHAT PANEL */
.chat-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 580px;
}
.chat-panel-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: #0d0d14;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.chat-panel-header-info {
  flex: 1;
}
.chat-panel-name {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 2px;
}
.chat-panel-meta {
  font-size: 12px;
  color: var(--fg-muted);
}
.live-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 1px;
  font-family: var(--font-display);
}
.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite;
}

/* SCENARIO BADGE */
.scenario-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  padding: 5px 12px;
  border-radius: 100px;
  font-size: 12px;
  color: var(--fg-muted);
  font-family: var(--font-body);
  margin-left: auto;
  flex-shrink: 0;
}
.scenario-badge-icon {
  width: 14px;
  height: 14px;
  opacity: 0.6;
}

/* MESSAGES AREA */
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scroll-behavior: smooth;
}
.chat-messages::-webkit-scrollbar {
  width: 4px;
}
.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}
.chat-messages::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 2px;
}

/* MESSAGE BUBBLES */
.msg {
  display: flex;
  flex-direction: column;
  gap: 4px;
  animation: msgIn 0.3s ease;
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.msg-user { align-items: flex-end; }
.msg-bot  { align-items: flex-start; }

.msg-bubble {
  max-width: 75%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
  font-family: var(--font-body);
}
.msg-user .msg-bubble {
  background: #1e1e28;
  color: var(--fg);
  border-bottom-right-radius: 4px;
}
.msg-bot .msg-bubble {
  background: #0a1a05;
  color: var(--accent);
  border-bottom-left-radius: 4px;
  border: 1px solid rgba(168,255,87,0.12);
}
.msg-time {
  font-size: 11px;
  color: var(--fg-muted);
  opacity: 0.5;
  padding: 0 4px;
}

/* TYPING INDICATOR */
.typing-indicator {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 0;
}
.typing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.4;
  animation: typingBounce 1.2s infinite;
}
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce {
  0%, 80%, 100% { transform: scale(1); opacity: 0.4; }
  40% { transform: scale(1.3); opacity: 1; }
}

/* CALENDAR CARD */
.calendar-card {
  background: var(--bg-card);
  border: 1px solid rgba(168,255,87,0.2);
  border-radius: 14px;
  padding: 16px;
  width: fit-content;
}
.cal-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}
.cal-icon {
  width: 16px;
  height: 16px;
  color: var(--accent);
}
.cal-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--fg);
}
.cal-date {
  font-size: 12px;
  color: var(--fg-muted);
  margin-left: auto;
}
.cal-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.cal-slot {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s;
  font-family: var(--font-body);
}
.cal-slot:hover {
  border-color: var(--accent);
  background: rgba(168,255,87,0.05);
}
.cal-slot-time {
  font-size: 13px;
  font-weight: 600;
  color: var(--fg);
  display: block;
}
.cal-slot-label {
  font-size: 10px;
  color: var(--fg-muted);
  display: block;
  margin-top: 1px;
}
.cal-slot.avail {
  color: var(--accent);
}
.cal-slot.avail .cal-slot-time {
  color: var(--accent);
}
.cal-slot.booked {
  opacity: 0.4;
  cursor: not-allowed;
}
.cal-slot.selected {
  border-color: var(--accent);
  background: rgba(168,255,87,0.1);
}
.cal-slot.selected .cal-slot-time {
  color: var(--accent);
}

/* BOOKING CONFIRMED CARD */
.booking-confirmed {
  background: rgba(168,255,87,0.08);
  border: 1px solid rgba(168,255,87,0.2);
  border-radius: 14px;
  padding: 16px 20px;
  width: fit-content;
}
.booking-confirmed-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.booking-confirmed-icon {
  width: 18px;
  height: 18px;
  color: var(--accent);
}
.booking-confirmed-label {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.5px;
}
.booking-detail {
  font-size: 14px;
  color: var(--fg);
  margin-bottom: 4px;
  font-family: var(--font-body);
}
.booking-detail strong {
  color: var(--fg);
}
.booking-sub {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 6px;
}

/* CHOICE BUTTONS */
.choice-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 2px 0;
}
.choice-btn {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 8px 18px;
  font-size: 13px;
  font-family: var(--font-body);
  color: var(--fg);
  cursor: pointer;
  transition: all 0.15s;
}
.choice-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(168,255,87,0.05);
}

/* CHAT INPUT */
.chat-input-area {
  padding: 16px 20px;
  background: #0d0d14;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.chat-input {
  flex: 1;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 10px 18px;
  font-size: 14px;
  font-family: var(--font-body);
  color: var(--fg);
  outline: none;
  transition: border-color 0.2s;
}
.chat-input::placeholder { color: var(--fg-muted); opacity: 0.5; }
.chat-input:focus { border-color: var(--accent); }
.send-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: opacity 0.15s;
}
.send-btn:hover { opacity: 0.85; }
.send-btn svg { width: 16px; height: 16px; color: #000; }

/* INFO PANEL (RIGHT) */
.info-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 20px;
}
.info-card-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 14px;
  font-family: var(--font-display);
}
.info-section {
  margin-bottom: 16px;
}
.info-section:last-child { margin-bottom: 0; }
.info-section-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 10px;
}
.info-step {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}
.info-step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(168,255,87,0.12);
  border: 1px solid rgba(168,255,87,0.2);
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-display);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.info-step-text {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.4;
  padding-top: 2px;
}
.info-step-text strong {
  color: var(--fg);
  font-weight: 500;
}

/* QUALIFICATION STAGE TRACKER */
.stage-tracker {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stage-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.stage-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.stage-dot.done   { background: var(--accent); }
.stage-dot.active { background: var(--accent); box-shadow: 0 0 0 3px rgba(168,255,87,0.15); }
.stage-dot.wait   { background: var(--border); }
.stage-label {
  font-size: 13px;
  font-family: var(--font-body);
}
.stage-row.done .stage-label   { color: var(--fg-muted); }
.stage-row.active .stage-label { color: var(--fg); font-weight: 600; }
.stage-row.wait .stage-label   { color: var(--fg-muted); opacity: 0.5; }
.stage-time {
  margin-left: auto;
  font-size: 12px;
  color: var(--fg-muted);
  font-family: var(--font-body);
}
.stage-row.active .stage-time { color: var(--accent); }

/* LEAD DATA */
.lead-data-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.lead-data-item {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
}
.lead-data-key {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--fg-muted);
  font-family: var(--font-display);
  margin-bottom: 4px;
}
.lead-data-val {
  font-size: 14px;
  font-weight: 600;
  color: var(--fg);
  font-family: var(--font-body);
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .demo-layout {
    grid-template-columns: 1fr;
    padding: 24px;
  }
  .demo-header { padding: 24px 24px 0; }
  .chat-panel { height: 480px; }
}