Astonishing? They own the means of production, you are the means of production.
But let me give you an example of how these sort of laws have severe unintended consequences:
In some states it is illegal to ask a potential hire if they have a felony. The reasoning was that this would force employers to be less discriminatory. The result? More discrimination of black people and lower wages. Why, you might ask? Because the less information you have as an employer, the more you are going to rely on the information you do have: what the applicant looks like, how they act, etc. Also the wages are lower becauase you have to price in the risk of them being a felon.
Employers should be able to choose whoever they think is best through whatever metrics they want. After all, it’s their business, and hiring and firing who you want is absolutely integral to freedom and free markets. And laws imposed by the government just make things worse, and more discriminatory.
Let’s say a teenage boy who looks like a stoner wants a job at WalMart. He’s not a stoner though, he just has long hair or whatever. If WalMart could have made him pee in a cup, they would have hired a dependable and honest employee. But because they can’t, they judge him on his hair and don’t give him the job.