CSS ou sélecteur

*:is(.a, .b).c{...}
Blushing Bug