Giorgos Giakoumakis was the hero for Celtic as his last-gasp goal secured victory in a dramatic game at St Johnstone.