Walking alone in busy places

I don't really know how to describe this but I'm noticing it more often and wonder if it's a normal autistic trait or something else. I was in the office yesterday and noticed it again.

If I'm walking in a group with friends this doesn't seem to happen. It's more when I start to focus on it.

If I'm walking somewhere alone and especially if there's any perception that people could be watching, or maybe I become aware of someone else walking behind me for example,I find I struggle to walk properly. Can't really put my finger on what I mean but my legs get weird and I end up really anxious. Often get to my car , get in and sit for a minute calming myself down.