Theresa May to warn EU leaders not to let 'ideology' jeopardise citizens' safety