/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(156, 163, 175, 0.3);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(156, 163, 175, 0.5);
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes scaleUp {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
@keyframes bounceSlow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.animate-fade-in {
  animation: fadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.animate-scale-up {
  animation: scaleUp 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.animate-bounce-slow {
  animation: bounceSlow 3s infinite ease-in-out;
}

/* Typing Indicator Dots Animasi */
.typing-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
}
.typing-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #6366f1;
  animation: typingBounce 1.4s infinite ease-in-out both;
}
.typing-dot:nth-child(1) { animation-delay: -0.32s; }
.typing-dot:nth-child(2) { animation-delay: -0.16s; }
.typing-dot:nth-child(3) { animation-delay: 0s; }

@keyframes typingBounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
  40% { transform: scale(1); opacity: 1; }
}

/* Markdown prose styling */
.prose-demina {
  font-size: 0.95rem;
  line-height: 1.65;
}
.prose-demina p {
  margin-bottom: 0.75rem;
}
.prose-demina p:last-child {
  margin-bottom: 0;
}
.prose-demina h1, .prose-demina h2, .prose-demina h3 {
  font-weight: 700;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}
.prose-demina ul {
  list-style-type: disc;
  padding-left: 1.25rem;
  margin-bottom: 0.75rem;
}
.prose-demina ol {
  list-style-type: decimal;
  padding-left: 1.25rem;
  margin-bottom: 0.75rem;
}
.prose-demina pre {
  background: #0f172a !important;
  border-radius: 0.75rem;
  padding: 0.85rem 1rem;
  overflow-x: auto;
  margin: 0.75rem 0;
}
.prose-demina code:not(pre code) {
  background-color: rgba(99, 102, 241, 0.12);
  color: #4f46e5;
  padding: 0.15rem 0.4rem;
  border-radius: 0.375rem;
  font-size: 0.88em;
}
.dark .prose-demina code:not(pre code) {
  background-color: rgba(255, 255, 255, 0.1);
  color: #a5b4fc;
}