/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

.networkChart {
  display: flex;
  flex: 1;
  flex-flow: column nowrap;
  cursor: default;
  user-select: none;
}

.networkChart .treeViewBody {
  border-top: 1px solid var(--grey-30);
}

.networkChart .treeViewBody .treeViewBodyInnerWrapper {
  width: 100%;
  flex-flow: column nowrap;
}

.networkChartRowItem {
  position: relative;
  display: block;
  width: 100%;
  height: 16px;
}

.networkChartRowItem.odd {
  background-color: #f5f5f5;
}

.networkChartRowItem:hover,
.networkChartRowItem.isRightClicked,
.networkChartRowItem.isSelected,
.networkChartRowItem.isHovered {
  background-color: #bbe0f6;
}

.networkChartRowItemLabel {
  display: inline-block;
  overflow: hidden;
  width: 100%;
  max-height: 16px;
  margin-left: 4px;

  /* This is necessary so that the marker element gets the mouse events, because
   * the label element is on top becaose of the :hover rule below. */
  pointer-events: none;
  white-space: nowrap;
}

.networkChartRowItemBar {
  position: absolute; /* The bar will be positioned in JS. */
  top: 0;
  display: inline-block;
  overflow: hidden; /* This clips this element's children using its border-radius */
  height: 14px;
  border-radius: 2px;
  margin: 1px 0; /* Because the line's height is 16px, this margin vertically centers the bar */

  /* styling properties */
  background-color: var(--grey-20);
  box-shadow: 0 0 0 1px inset var(--marker-color);
  opacity: 0.7;
}

.networkChartRowItemBarPhase {
  position: absolute;
  height: 100%;
  background-color: var(--marker-color);
}

.networkChartRowItemUriOptional {
  display: inline-block;
  overflow: hidden;
  max-width: 90px;
  color: var(--grey-40);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.networkChartRowItemUriRequired {
  display: inline-block;
  overflow: hidden;
  max-width: 35%;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.networkChartRowItem:hover .networkChartRowItemUriOptional {
  color: unset;
}
