.tooltip {
  z-index: 150;
  cursor: pointer;
  pointer-events: auto;
  border-radius: 0.275rem;
  background-color: var(--surface-primary);
  padding-top: 0.25rem;
  padding-bottom: 0.25rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  font-size: 1rem;
  line-height: 1.5rem;
  color: black;
  box-shadow: 0 2px 4px 0 rgb(0 0 0 / 0.25);
  /* Enhanced layout for longer descriptions */
  max-width: 320px;
  word-wrap: break-word;
  text-align: left;
}

@media (max-width: 640px) {
  .tooltip {
    max-width: 200px;
  }
}

.tooltip:where(.dark, .dark *) {
  background-color: var(--surface-primary);
  color: white;
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.35);
}
