Seeking solution : Helicoidal Spring Curve Orientation Issue

hello creators ! Having trouble orienting a helicoidal/spiral curve (representing a flat steel spring) in Grasshopper. Tried “Flip Curve” with various curve guides but the spring isn’t aligning correctly. Any suggestions on how to control the curve’s direction? any help would be appreciated !
[seeking solutions curve direction (orientation).gh|attachment]
seeking solutions curve direction (orientation).gh (96.1 KB)

note : the issue is within the red-colored group , the script is a bit heavy , increase absolute tolerance in rhino .

thank you everyone , issue fixed ! i used vector multiplication logic as shown in the script :slight_smile: