Pulse phase spectroscopy of the cyclotron line in Centaurus X-3