/* Vega Tooltip Styles - Adapted for Nebula theming */

#vg-tooltip-element {
  position: fixed;
  padding: 10px;
  font-family: var(--font-family, sans-serif);
  font-size: 13px;
  border-radius: 6px;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-emphasis);
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  pointer-events: none;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
}

#vg-tooltip-element.visible {
  opacity: 1;
}

#vg-tooltip-element table {
  border-collapse: collapse;
  border-spacing: 0;
  width: 100%;
}

#vg-tooltip-element table tr {
  border-bottom: 1px solid var(--color-border-muted, var(--color-border));
}

#vg-tooltip-element table tr:last-child {
  border-bottom: none;
}

#vg-tooltip-element table td {
  padding: 4px 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#vg-tooltip-element table td.key {
  color: var(--color-subtle);
  font-weight: 500;
  max-width: 150px;
}

#vg-tooltip-element table td.value {
  color: var(--color-emphasis);
  font-weight: 600;
  text-align: right;
  max-width: 200px;
}

#vg-tooltip-element h2 {
  margin: 0 0 8px 0;
  padding: 0 0 8px 0;
  font-size: 14px;
  font-weight: 600;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-emphasis);
}

#vg-tooltip-element img {
  max-width: 200px;
  max-height: 200px;
  border-radius: 4px;
  margin-top: 8px;
}

/* Dark mode adjustments */
html.dark #vg-tooltip-element {
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.3), 0 2px 4px -2px rgb(0 0 0 / 0.2);
}
