Weyl type N solutions with null electromagnetic fields in the Einstein–Maxwell p-form theory