.minimal-chat {
  display: grid;
  gap: 0.75rem;
}

.chat-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.42rem;
}

.chat-chip {
  border: 1px solid color-mix(in srgb, var(--accent) 30%, rgba(255, 255, 255, 0.28));
  border-radius: 999px;
  background: rgba(9, 15, 30, 0.78);
  color: rgba(232, 243, 255, 0.9);
  font: inherit;
  font-size: 0.8rem;
  padding: 0.34rem 0.62rem;
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.chat-chip:hover {
  border-color: color-mix(in srgb, var(--accent) 62%, rgba(255, 255, 255, 0.35));
  background: color-mix(in srgb, var(--accent) 20%, rgba(9, 15, 30, 0.78));
}

.chat-chip:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 72%, #d0e7ff);
  outline-offset: 2px;
}

.chat-transcript {
  border-radius: 16px;
  min-height: 320px;
  max-height: 62vh;
  overflow-y: auto;
  padding: 1rem;
  display: grid;
  gap: 0.7rem;
  border: 1px solid color-mix(in srgb, var(--accent) 24%, rgba(255, 255, 255, 0.2));
  background: linear-gradient(170deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.015)), rgba(7, 13, 25, 0.9);
}

.chat-empty {
  padding: 0.9rem 1rem;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, rgba(255, 255, 255, 0.24));
  border-radius: 14px;
  background: rgba(10, 18, 34, 0.84);
}

.chat-empty h3 {
  margin: 0 0 0.35rem;
}

.chat-empty p {
  margin: 0 0 0.55rem;
}

.chat-empty ul {
  margin: 0;
  padding-left: 1.1rem;
}

.chat-row {
  display: flex;
}

.chat-row.user {
  justify-content: flex-end;
}

.chat-row.assistant {
  justify-content: flex-start;
}

.chat-card {
  max-width: min(74ch, 88%);
  border-radius: 14px;
  padding: 0.75rem 0.85rem;
  border: 1px solid color-mix(in srgb, var(--accent) 20%, rgba(255, 255, 255, 0.24));
  background: rgba(12, 20, 38, 0.86);
}

.chat-row.user .chat-card {
  background: color-mix(in srgb, var(--accent) 18%, rgba(11, 19, 38, 0.88));
}

.chat-meta {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: color-mix(in srgb, var(--accent) 68%, #dbe9ff);
}

.chat-body > :first-child {
  margin-top: 0;
}

.chat-body > :last-child {
  margin-bottom: 0;
}

.chat-composer {
  display: grid;
  gap: 0.6rem;
  position: sticky;
  bottom: 0;
  padding: 0.9rem;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--accent) 22%, rgba(255, 255, 255, 0.22));
  background: rgba(7, 12, 24, 0.92);
  backdrop-filter: blur(8px);
}

.chat-composer label {
  font-size: 0.78rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--accent) 65%, rgba(255, 255, 255, 0.7));
}

.chat-composer textarea {
  width: 100%;
  border: 1px solid color-mix(in srgb, var(--accent) 26%, rgba(255, 255, 255, 0.26));
  border-radius: 12px;
  background: rgba(12, 20, 38, 0.9);
  color: #f6f9ff;
  padding: 0.7rem 0.75rem;
  font: inherit;
  line-height: 1.52;
  resize: none;
  overflow-y: auto;
  min-height: 76px;
  max-height: 280px;
}

.chat-composer textarea:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--accent) 70%, #bcd9ff);
  outline-offset: 1px;
}

.agent-actions {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.chat-hint {
  margin: 0;
  font-size: 0.76rem;
  color: rgba(199, 216, 242, 0.76);
}

.chat-typing {
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
  min-height: 1.1rem;
}

.chat-typing > span {
  width: 0.46rem;
  height: 0.46rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 76%, #f4f8ff);
  opacity: 0.46;
  animation: chat-typing-bounce 1s ease-in-out infinite;
}

.chat-typing > span:nth-child(2) {
  animation-delay: 120ms;
}

.chat-typing > span:nth-child(3) {
  animation-delay: 240ms;
}

.chat-typing-text {
  width: auto !important;
  height: auto !important;
  border-radius: 0 !important;
  background: transparent !important;
  opacity: 1 !important;
  animation: none !important;
  font-size: 0.82rem;
  color: color-mix(in srgb, var(--accent) 65%, #e6f3ff);
}

@keyframes chat-typing-bounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-2px); opacity: 1; }
}

.thinking-indicator {
  margin: 0;
  min-height: 1.1rem;
  font-size: 0.92rem;
}

@media (prefers-reduced-motion: reduce) {
  .chat-typing > span {
    animation: none;
  }
}

@media (max-width: 720px) {
  .chat-transcript {
    min-height: 270px;
    max-height: 56vh;
  }

  .chat-card {
    max-width: 100%;
  }
}
