.workflow-node__edges {
  display: flex;
  gap: 15px;
  margin-top: 40px;
}

.workflow-node__edge {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 200px;
}

.workflow-edge {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.workflow-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  pointer-events: none;
}

.workflow-edge__add-button-wrapper--with-next::after {
  content: '';
  display: block;
  margin-left: 50%;
  height: 80px;
  border-left: 2px solid $palette-neutral-400;
}

.workflow-edge__label {
  position: relative;
  padding: 6px 10px;
  margin-bottom: 10px;
  border-radius: 25px;
  font-size: 11px;
  font-weight: 500;
  background-color: $palette-neutral-200;
  border: 1px solid $palette-neutral-400;
  color: $palette-neutral-900;
  display: block;

  @include elevation($elevation-low);

  &::after {
    content: '';
    position: absolute;
    display: block;
    left: 50%;
    bottom: -12px;
    height: 10px;
    border-left: 2px solid $palette-neutral-400;
  }
}

.workflow-edge__add-button-wrapper {
  pointer-events: initial;
}

.workflow-connector {
  color: $palette-neutral-400;
}

.workflow-node-content {
  position: relative;
  pointer-events: initial;
  display: inline-flex;
  height: 72px;
  padding: 16px;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
  width: 400px;
  border: 1.5px solid $palette-neutral-200;
  background: $white;
  cursor: pointer;
  background-size: 50px 57px;

  @include elevation($elevation-low);
  @include rounded($rounded-xl);

  &.workflow-node-content--selected {
    border: 1.5px solid $palette-blue-500;
  }

  &.workflow-node-content--utility {
    box-shadow: none;
    background: $palette-neutral-50;
    border: 1.5px dashed $palette-neutral-400;

    &.workflow-node-content--selected {
      border: 1.5px dashed $palette-blue-500;
    }
  }
}

.workflow-node-content__drag-handle {
  position: absolute;
  left: 0;
  top: 4px;
  width: 14px;
  height: 62px;
  cursor: grab;
  background-image: radial-gradient(
      circle,
      $palette-neutral-400 1px,
      transparent 1px
    ),
    radial-gradient(circle, $palette-neutral-400 1px, transparent 1px);
  background-repeat: repeat-y;
  background-position: 3px center, 0 center;
  background-size: auto 4px;
  display: none;

  .workflow-node-content:hover & {
    display: block;
  }
}

.workflow-node-content::before {
  content: attr(data-before-label);
  position: absolute;
  top: -25px;
  left: 0;
  color: $palette-neutral-900;
  font-weight: 500;

  .workflow-node-content__wrapper--dragging & {
    display: none;
  }
}

.workflow-node-content__more--wrapper {
  display: flex;
  margin-left: auto;
  flex-direction: column;
  gap: 4px;
}

.workflow-node-content__more-icon {
  color: $palette-neutral-800;
  font-size: 20px;
  width: 25px;
  height: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;

  @include rounded($rounded-md);

  &:hover {
    background-color: $palette-neutral-100;
  }
}

.workflow-editor {
  .vue-flow__controls {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }

  .vue-flow__controls-button {
    border: none;
    border-right: 1px solid #eee;
  }
}

.workflow-node-content__icon {
  display: flex;
  height: 40px;
  padding: 12px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  background: $white;
  border: 1px solid $palette-neutral-200;

  @include elevation($elevation-low);
  @include rounded($rounded-md);
}

.workflow-node-content__title {
  font-size: 16px;
  font-weight: 500;
  color: $palette-neutral-1200;
  min-width: 0;
  flex: 1;

  &:last-child {
    margin-bottom: 30px;
  }

  @extend %ellipsis;
}

.workflow-node-content__wrapper--dragging {
  opacity: 0.5;
}

.workflow-edge__dropzone-wrapper {
  position: relative;
  width: 400px;
  height: 100%;
}

.workflow-edge__dropzone {
  position: absolute;
  top: -18px;
  left: 0;
  width: 100%;
  z-index: 1;
  height: 70px;

  @include rounded($rounded-xl);

  &--hover {
    border: 2px dashed $palette-blue-500;
  }
}

.workflow-edge__add-button {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
}

.workflow-edge__add-button--active {
  & > .button-floating {
    transition: all 0.2s ease;
    background: $palette-blue-100;
    border: 1px dashed $palette-blue-400;
  }
}

.workflow-edge__add-button--hover {
  & > .button-floating {
    background: $palette-green-200;
    border: 1px solid $palette-green-500;
    color: $palette-green-700;
  }
}
