/* ============================================================
   Digital Twin Chat
   ============================================================ */

/* ── Thinking indicator ─────────────────────────────────── */
.dt-thinking-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: #f1f5f9;
  border-radius: 18px;
  border-bottom-left-radius: 4px;
}

.dt-thinking-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #94a3b8;
  animation: dtBounce 0.9s ease-in-out infinite;
}

@keyframes dtBounce {
  0%, 100% { opacity: 0.3; transform: translateY(0); }
  50%       { opacity: 1;   transform: translateY(-4px); }
}

/* ── Streaming bubble & caret ───────────────────────────── */
.dt-streaming-bubble {
  background: #E2E8F0;
  color: #1e293b;
}

.dt-streaming-caret {
  display: inline-block;
  margin-left: 1px;
  animation: dtBlink 0.8s step-start infinite;
}

@keyframes dtBlink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* ── Message bubble colours ─────────────────────────────── */

/* Twin / AI */
.dt-bubble--ai {
  background: #E2E8F0;
  color: #1e293b;
}

/* MSL (human) */
.dt-bubble--msl {
  background: linear-gradient(135deg, #1D4ED8, #3B82F6);
  color: #fff;
}

/* HCP */
.dt-bubble--hcp {
  background: linear-gradient(135deg, #059669, #34D399);
  color: #fff;
}

/* Legacy aliases kept for safety */
.dt-bubble--self  { background: linear-gradient(135deg, #1D4ED8, #3B82F6); color: #fff; }
.dt-bubble--other { background: #F1F5F9; color: #1e293b; }

/* ── Avatar colours ─────────────────────────────────────── */
.dt-avatar--ai {
  background: #94a3b8;
}

.dt-avatar--msl {
  background: linear-gradient(135deg, #1D4ED8, #3B82F6);
}

.dt-avatar--hcp {
  background: linear-gradient(135deg, #059669, #34D399);
}

/* Legacy aliases */
.dt-avatar--self  { background: linear-gradient(135deg, #1D4ED8, #3B82F6); }
.dt-avatar--other { background: #94a3b8; }

/* ── Waveform bars ──────────────────────────────────────── */
.dt-waveform-bar {
  width: 4px;
  border-radius: 2px;
  flex-shrink: 0;
  transition: height 60ms ease-out;
}

.dt-waveform-bar--active {
  background: linear-gradient(180deg, #7C3AED, #0EA5E9);
}

.dt-waveform-bar--paused {
  background: #94a3b8;
}

/* ── Voice recorder send button ─────────────────────────── */
.dt-voice-send {
  background: linear-gradient(to right, #9333ea, #06b6d4);
  color: #fff;
  border: none;
}

.dt-voice-send:hover {
  opacity: 0.9;
}

/* ── Chat input textarea ────────────────────────────────── */
.dt-chat-textarea {
  min-height: 40px;
  max-height: 120px;
}

/* ── Chat input send button ─────────────────────────────── */
.dt-chat-send {
  background: linear-gradient(to right, #2563eb, #3b82f6);
  color: #fff;
  border: none;
  flex-shrink: 0;
  border-radius: 0.75rem;
}

.dt-chat-send:hover:not(:disabled) {
  opacity: 0.9;
}

.dt-chat-send:disabled {
  opacity: 0.4;
}
