Are hardcore shows safe?

I’m probably gonna get flamed for asking this but I’ve never been to one and I wanna go to a Snapcase show this February, I wanna jam out and listen to the music but I don’t necessarily wanna be in the mosh pit, would there be a part of the crowd that doesn’t have that if I stand more in the back? Any helpful advice would be nice lol