#glossary {
  min-height: 600px;
}

.glossary-sidebar {
  max-height: 80vh;
}

#scrollContainer {
  max-height: 100%;
}

.glossary-graph-wrapper {
  min-height: 600px;
  position: relative;
}

.glossary-canvas {
  min-height: 600px;
}

.glossary-tooltip {
  position: absolute;
  padding: 0.5rem 0.75rem;
  background: #212529;
  color: #fff;
  font-size: 0.85rem;
  border-radius: 0.25rem;
  pointer-events: none;
  z-index: 1000;
  max-width: 260px;
  display: none;
  /* изначально скрыт */
  visibility: hidden;
  /* и невидим, пока не посчитаем позицию */
}

.path-glossary div#block-b5isandtheme-page-title {
  display: none;
}

@media (min-width: 992px) {
  #sidebar {
    width: 22%;
  }

  .glossary-graph-wrapper {
    width: 78%;
  }
}

/* Строка термина */
.glossary-term-item {
  cursor: pointer;
  padding: 0.35rem 0.5rem;
  border-radius: 0.25rem;
  transition: background-color 0.15s ease, color 0.15s ease;
}

/* Подсветка при наведении */
.glossary-term-item:hover {
  background-color: #f1f3f5;
  /* мягкий серый */
}

/* Активный (выбранный) термин */
.glossary-term-item--active {
  background-color: #e7f1ff;
  color: #0b5ed7;
  font-weight: 500;
}

.glossary-tooltip {
  position: absolute;
  padding: 0.5rem 0.75rem;
  background: #212529;
  color: #fff;
  font-size: 0.85rem;
  border-radius: 0.25rem;
  pointer-events: none;
  z-index: 1000;
  max-width: 260px;
  display: none;
  /* изначально скрыт */
}
