/*
 * Copyright 2018 The Chromium Authors
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */

.close-button {
  position: absolute;
  top: var(--sys-size-4);
  left: var(--sys-size-2);
}

.console-pins {
  max-height: 200px;
  overflow-y: auto;
  background: var(--sys-color-cdt-base-container);

  --override-error-text-color: var(--sys-color-on-error-container);
}

.console-pins:not(:empty) {
  border-bottom: 1px solid var(--sys-color-divider);
}

.console-pin {
  position: relative;
  user-select: text;
  flex: none;
  padding: 2px 0 6px 24px;
}

.console-pin:not(:last-child) {
  border-bottom: 1px solid var(--sys-color-divider);
}

.console-pin.error-level:not(:focus-within) {
  background-color: var(--sys-color-surface-error);
  color: var(--override-error-text-color);
}

.console-pin:not(:last-child).error-level:not(:focus-within) {
  border-top: 1px solid var(--sys-color-error-outline);
  border-bottom: 1px solid var(--sys-color-error-outline);
  margin-top: -1px;
}

.console-pin-name {
  margin-left: -5px;
  margin-bottom: 1px;
  height: auto;
}

.console-pin-name,
.console-pin-preview {
  width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-height: 13px;
}

.console-pin-preview {
  overflow: hidden;
}

.console-pin-name:focus-within {
  background: var(--sys-color-cdt-base-container);
  border-radius: 4px;
  border: 1px solid var(--sys-color-state-focus-ring);
}

.console-pin:focus-within .console-pin-preview,
.console-pin-name:not(:focus-within, :hover) {
  opacity: 60%;
}
