How can I deny scroll for 360 degrees on Z axis?

I want to block the ability to scroll the camera along the Z axis by 360 degrees in Cesium js application. For example, if I lower the camera to the horizon, then by moving the mouse up, you can point the camera at the sky and see the Sun. I need the camera not to be lifted up from the horizon.

Please, help to program such behaviour with a piece of code!