The reason your shadow can be longer than an object is that the sun is not always overhead. When it’s not overhead, it forms an angle between the object and the ground and we no longer have a simple ’right angle’ situation.
In the diagram below, you can drag the stick and enter the angle of the sun (represented here as a point source of light) to see the effect on the shadow. Click the Draw button to change the angle of the stick. Click the Run button to make the sun move across the sky so you can see how the shadow changes.