Jonny Lomax touched down impressively as St Helens got on the scoreboard to keep their hopes alive against rivals Wigan.