/* Animated hero chat + terminal widget */
/* Takopi pink: #F4A5B8, Flower pink: #E87A9F, Teal: #4A9B8E */

.hero-demo {
  display: flex;
  gap: 16px;
  max-width: 800px;
  margin: 24px auto;
  align-items: stretch;
  height: 320px;
}

@media (max-width: 700px) {
  .hero-demo {
    flex-direction: column;
    height: auto;
  }

  .hero-chat,
  .hero-terminal {
    min-height: 280px;
  }
}

.hero-chat {
  background: #fff;
  border-radius: 12px;
  padding: 12px;
  flex: 1;
  min-width: 0;
  font-size: 14px;
  line-height: 1.4;
  border: 1px solid #e5e5e5;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.hero-terminal {
  background: #1a1b26;
  border-radius: 12px;
  padding: 12px;
  flex: 1;
  min-width: 0;
  font-family: var(--md-code-font-family, monospace);
  font-size: 14px;
  line-height: 1.4;
  color: #a9b1d6;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.hero-terminal .terminal-content {
  white-space: pre-wrap;
  word-break: break-word;
}

.hero-terminal .prompt.shell {
  color: #4A9B8E;
}

.hero-terminal .prompt.shell .prompt-symbol {
  color: #4A9B8E;
}

.hero-terminal .prompt.shell .cursor {
  color: #4A9B8E;
}

.hero-terminal .cursor {
  color: #7aa2f7;
  animation: cursor-blink 1s step-end infinite;
}

@keyframes cursor-blink {
  50% { opacity: 0; }
}

.hero-terminal .codex-output {
  margin-top: 12px;
}

.hero-terminal .codex-msg.user {
  background: #13141c;
  margin: 0 -12px;
  padding: 8px 12px;
}

.hero-terminal .codex-msg.user::before {
  content: "› ";
  color: #a9b1d6;
}

.hero-terminal .codex-msg.assistant {
  margin-top: 8px;
}

.hero-terminal .codex-msg.assistant::before {
  content: "• ";
  color: #a9b1d6;
}

.hero-terminal .codex-prompt {
  background: #13141c;
  margin: 12px -12px -12px;
  padding: 8px 12px;
}

.hero-terminal .codex-prompt::before {
  content: "› ";
  color: #a9b1d6;
}

.hero-chat .chat-messages {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hero-chat .msg {
  max-width: 90%;
  padding: 8px 12px;
  border-radius: 14px;
  opacity: 0;
  transform: translateY(10px);
  animation: msg-appear 0.3s ease forwards;
}

@keyframes msg-appear {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-chat .msg-user {
  background: #4A9B8E;
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 6px;
}

.hero-chat .msg-bot {
  background: #fafafa;
  color: #333;
  align-self: flex-start;
  border: 1px solid #e5e5e5;
  border-bottom-left-radius: 6px;
}

.hero-chat .msg-bot .status {
  color: #999;
}

.hero-chat .msg-bot .tools {
  margin-top: 8px;
}

.hero-chat .msg-bot .tool {
  opacity: 0;
  animation: tool-appear 0.2s ease forwards;
}

@keyframes tool-appear {
  to {
    opacity: 1;
  }
}

.hero-chat .msg-bot .tool.cmd {
  font-family: var(--md-code-font-family, monospace);
}

.hero-chat .msg-bot .tool::before {
  content: "✓";
  color: #4A9B8E;
  font-family: system-ui, sans-serif;
  display: inline-block;
  width: 1.2em;
  text-align: center;
}

.hero-chat .msg-bot .tool.running::before {
  content: "•";
  font-family: system-ui, sans-serif;
}

.hero-chat .msg-bot .answer {
  margin-top: 8px;
  color: #333;
}

.hero-chat .msg-bot .resume {
  margin-top: 8px;
  color: #999;
}

.hero-chat .typing-indicator {
  display: flex;
  gap: 4px;
  padding: 4px 0;
}

.hero-chat .typing-indicator span {
  width: 6px;
  height: 6px;
  background: #999;
  border-radius: 50%;
  animation: typing-bounce 1s ease-in-out infinite;
}

.hero-chat .typing-indicator span:nth-child(2) {
  animation-delay: 0.15s;
}

.hero-chat .typing-indicator span:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes typing-bounce {
  0%, 60%, 100% {
    transform: translateY(0);
  }
  30% {
    transform: translateY(-4px);
  }
}

