They can get away with it, but in the US, at least, it strongly indicates a violation of the Civil Rights Act. A non-racist business owner can also lose a Title VII suit, since the Civil Rights Act isn't used to convict people of racism; rather it protects people from discriminatory hiring practices, which may be subjective.
Notably, the opposite scenario to what is often assumed can also happen; if a business owner or government manager refuses to hire/promote someone because they are "white" the law may also punish that employer. This can happen regardless of whether the employer is also white, or is black, etc. It can also happen if the employer has what they consider good intentions--for example, if they want to give black job applicants a chance at a job.
This is possible simply because when they decide not to hire or promote the (majority) applicant based on race or color, they are violating the act. Minorities are not exclusively protected by the act, people are protected, and what they are protected from in this case is "discrimination based on race or color." So it is the act of discriminatory hiring based on race, sex, etc., that triggers the law.
Now BFOQ... there are of course some exceptions. A Shinto priest can not force an Apostolic monastic order to hire them as chief abbot, regardless of how qualified they may be in Shinto. Their qualifications as a religious leader are irrelevant in this case because the Apostolic set of beliefs and practices is "essential" to the operation and purpose of an Apostolic monastic order.
You might also be familiar with Hooters, a restaurant which is known for using fertility signals to attract male customers. They were indeed sued by some men who they refused to hire as servers, and they settled the suit. They didn't actually lose it though. What they did was agree to make available a number of gender neutral positions for employment. They preserved the right to select servers based on the signals of attraction considered essential to the business.
And of course there are acting roles, which are somewhat easier to defend under the bona fide occupational qualifications. I'm sure there either is or will be an exception somewhere, some day, but it's not going to be easy to sue someone for refusing to hire a light skinned person for the role of a person who was discriminated against for their dark skin. Or a dark skinned person for the role of an albino for that matter. There are some cases where inborn physical characteristics such as color are an essential job qualification. But at the same time, plaintiffs and courts, much less law and administrative code, will likely never define every situation where that is deemed legitimate, vs the situations where it is deemed unfair and illegal discrimination.
See:
- EOCC v. Hooters
- Duvant v. Novant Health
Also: