Gradient between two colors

Do you really need this “Max(,0)” node there?

I have the attached material with two different colours, where the position between them is set during game play.

I want to soften the line between them / apply a gradient.

I have tried several gradient nodes, and swapping the “absolute world position” for a “texture coordinate” but have not managed it.

Can anyone point me in the rights direction?