I see gameobjects through others Even if they are on same layer

Hi, I have been encountering this problem many times and cant seemto find a way to fix it.
I see gameobjects through others on my character.
here is the scene view and what it should look like

here is what it looks like

You can see the leg through the torso and you cant see the feets.

Please help!

nvm i fixed it