.attachment-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--purple-soft);
  color: var(--purple);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 2px 6px #6d4bea10;
  transition:
    box-shadow 0.2s ease,
    transform 0.2s ease;
}
.attachment-pill svg {
  width: 14px;
  height: 14px;
}
.attachment-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px #6d4bea20;
}
.attachment-pill:disabled {
  opacity: 0.65;
}
.attachment-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 16px;
}
.attachment-preview {
  margin: 0;
  min-width: 0;
}
.attachment-preview img {
  display: block;
  width: 100%;
  max-height: 65vh;
  object-fit: contain;
  border-radius: 10px;
  background: var(--subtle);
}
.attachment-preview figcaption {
  margin-top: 8px;
  font-size: 12px;
  color: var(--muted);
  overflow-wrap: anywhere;
}
@media (prefers-reduced-motion: reduce) {
  .attachment-pill {
    transition: none;
  }
}
