Add media detect to style.