ShadowRoot shim: only apply styles on corresponding custom elements