As far as I know you can’t separate the Vector3 in that manner and add separate values. You would have to create a new Vector3 with the additional values. Try this:
trans = new Vector3(trans.x + 5f, trans.y + 5f, trans.z + 5f);
This should work for adding 5 to each of the X, Y and Z values of trans.