Restrict camera movement on X axis

Hi, I’m trying to make a marble game that restricts your camera movement on the x axis, but i just dont even know where to start. This is what i have so far.
image_2022-09-30_205242155
Could anybody help me?

There is another post on the Dev-Forum that might be helpful to you.

Link to post

I hope this helps