Rendering problems when locations overlap

I faced the same problem as the picture above.
My line is made up of tubeGoemetry.
A circle is made up of many squares.

I think there is a problem with the part where the line goes up and the image appears to be in a circle.

Since the middle of the line is further ahead of the circle on the z-axis, that part should cover the circle, and I want to work on the line behind it so that the circle covers the line.

Any help would be greatly appreciated.

If you turn off .transparent does the problem still happen?