.trix-mention-wrapper {
  position: relative;
}

.trix-mention-dropdown {
  position: absolute;
  z-index: 1050;
  width: 280px;
  max-height: 240px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 0.25rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.mention-item {
  display: flex;
  flex-direction: column;
  padding: 0.5rem 0.75rem;
  cursor: pointer;
}

.mention-item:hover,
.mention-item.active {
  background-color: #f0edfa;
}

.mention-item-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: #172b4d;
}

.mention-item-email {
  font-size: 0.75rem;
  color: #6c757d;
}

.mention {
  display: inline;
  padding: 0.1rem 0.35rem;
  border-radius: 0.2rem;
  font-size: inherit;
  font-weight: 500;
  color: #172b4d;
  background-color: #e8e4f6;
  border: 1px solid #c8c1e8;
}

trix-editor .mention {
  cursor: default;
  user-select: all;
}

/* Trix attachment wrapper for mentions — render inline */
trix-editor figure[data-trix-attachment*="vnd.mention"],
.trix-content figure[data-trix-attachment*="vnd.mention"] {
  display: inline;
  margin: 0;
  padding: 0;
}

trix-editor figure[data-trix-attachment*="vnd.mention"] figcaption,
.trix-content figure[data-trix-attachment*="vnd.mention"] figcaption {
  display: none;
}

.trix-content .mention {
  display: inline;
  padding: 0.1rem 0.35rem;
  border-radius: 0.2rem;
  font-weight: 500;
  color: #172b4d;
  background-color: #e8e4f6;
  border: 1px solid #c8c1e8;
}
