How to improve the hand movement based on mouse input?

This is the setup that I have to calculate the position that the cursor is in and that later the hand will have to follow using IK, in the characterBP:

This is the logic to calculate the vector at which the hand IK should be aiming at (this is EventGraph of AnimBP):

As you can see, X and Y directions are determined by the cursor position in the 2d space, while the Z value (depth) is calculated as the speed of the movement (current cursor position-previous cursor position).

Finally, the two bone IK in the AnimGraph:

The result is that the arm moves but not as intended, it follows weird positions. how would I fix that? What would you modify? Maybe make this vector relative to the character’s rotation so that if the player turns the vector turns too?

edit: one problem im seeing is that the vector seems to be stuck in a certain world space position and doesnt follow the player. Maybe if I add the character transform somehow?