@import "variables";

::ng-deep .dark-theme {
  .legend-entry-name, .legend-entry-value {
    fill: $blue-250;
  }

  .donut-text {
    fill: $blue-250;

    tspan:nth-child(3) {
      stroke: $blue-800;
      stroke-width: 0.5px;
      font-weight: 500;
      pointer-events: none;
    }
  }
}

.content {
  display: grid;
  grid-auto-rows: 1fr minmax(auto, 33%);
  height: 100%;
  width: 100%;
  gap: 16px;
}

.donut-legend {
  width: 100%;
  min-height: 48px;
  text-align: center;
  overflow: auto;

  .slice {
    margin: 6px 12px;
    color: $blue-300;
    display: inline-flex;
    align-items: center;
    gap: 6px;

    &.highlight {
      color: $blue-200;

      .circle {
        box-shadow: 0 0 0 2px $blue-950, 0 0 0 3px var(--sliceColor);
      }
    }
  }

  .circle {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--sliceColor);
    box-shadow: 0 0 0 2px $blue-950, 0 0 0 3px transparent;
    cursor: url(../../../../assets/icons/pallete-cursor.svg) 6 0, pointer;
    transition: box-shadow 0.2s;
    &::after {
      content: "";
      display: block;
      transform: translate(-4px, -4px);
      padding: 10px;
    }
  }

  .quantity {
    color: $blue-200;
  }
}

.donut-container {
  position: relative;
  width: 100%;

  .percent {
    text-align: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translateY(-50%) translateX(-50%);
    font-size: 32px;
    font-weight: 500;
    opacity: 0;
  }
}
