transform.eulerAngles is always setting rotation to 90 degrees from a variable

All about Euler angles and rotations, by StarManta:

https://starmanta.gitbooks.io/unitytipsredux/content/second-question.html

Notes on clamping camera rotation and NOT using .eulerAngles because of gimbal lock:

How to instantly see gimbal lock for yourself:

Also for future reference, if you post a code snippet, ALWAYS USE CODE TAGS:

How to use code tags: Using code tags properly