1. Attractive male opens door for female. Female blushes, there is no problem.
2. Unattractive male opens door for female. Female reports unwanted behavior.
("attractive" does not have to mean "physically attractive", it could be another quality)
And I'm not being smug here with the above. No matter what, life is a popularity contest.
Outside of that example, with grey zones, it's all on a case-by-case bases, as far as what appropriate behavior is.
But if you need an actionable answer, then realizes that right now we are living in a time where victimhood is the predominant social "virtue"... People are seeking it, promoting it, and pretending to be outraged over it (e.g., social justice) - and will do anything to get attention.
So if you are a male, it's best not to have any type of non-work contact and non-work dialog with opposite sex co-workers, unless you want to be the subject of another world-trending tweet and/or 1000 point + 500 reply HN post.
As anything from a simple compliment, to a obvious joke, will be interpreted in the worst of ways.