Max rotation degrees

Hi guys
I 've write the script attachment, where I would like to stop the rotation at 30 degree and when the key is not press the rotation return to original position 0.

// Update is called once per frame
void Update () {
if (Input.GetKey(KeyCode.RightArrow))
transform.Rotate(Vector3.back * rotationspeed * Time.deltaTime);

Thank you all

if (Input.GetKey(KeyCode.RightArrow))
{ transform.Rotate(Vector3.backrotationspeedTime.deltaTime);
transform.rotation = Quaternion.Euler(transform.rotation.x,
transform.rotation.y , Mathf.Clamp(transform.rotation.z, minRotationValue, maxRotationValue));
}
else{
transform.Rotate(Vector3.forward*rotationspeed *Time.deltaTime);
transform.rotation = Quaternion.Euler(transform.rotation.x,
transform.rotation.y , Mathf.Clamp(transform.rotation.z, minRotationValue, maxRotationValue));
}
// in your case minRotationValue = -30 & maxRotationValue = 0