in order to solve this issue. You can simply use the not selector to select every em element not a child of a p element.
not
em
p
If you have issues with this answer or if I didn’t totally answered it, let me know !
:not(p) > em { properties }