UK's largest teaching union accepts government's pay offer