As a Chemo paitent I spend a lot of time in and out of the hospital and its impossible to tell if you're dealing with custodial staff or a brain surgeon. At least most of the doctors still choose to wear white coats which helps a bit.
Arguements can be made for wearing "scrubs" in an environment where blood and other bodily fluids often splash about but at least they could come up with a standard coding.
Badges? I go to a VA hospital and badges are a given just as paitets show VA ID before treatment. Another issue is common courtesy. Medical personel seldom identify themselves by job title. Only telling you what they want to do next. Statements such as "I'm nurse Jones and I'm going to give your meds now." are few and far between.
The use of jargon is also widespread and used by staff as a form of shorthand speech. Long ago I got used to saying "In layman's english please." Sometimes over and over till I got the desired result.
I'm sorry that you have encountered such callous jerks. Unfortunately, white uniforms are quite impractible these days, although it would serve to spotlight the so-called "nurse shortage." Whatever their costume, the staff tending to you should have had the basic courtesy to introduce themselves.