Camera movement independent of rotation

Hi, I have a camera which moves left right up and down using mouse getAxis.

I get the the mouse axis values and add them to a variable called movementOffset. The camera moves fine when it has no rotation, but when i rotate it, the camera moves in weird directions rather than left right up and down. How can I translate the movementOffset in such a way that the camera always moves left right up and down no matter what the rotation is.

How I move:

movementOffset += new Vector3(Input.GetAxis("Mouse X"), 0, Input.GetAxis("Mouse Y"));
transform.position += movementOffset;

try (not tested) :

movementOffset = (Vector3.right* Input.GetAxis(“Mouse X”)) + ( Vector3.up* Input.GetAxis(“Mouse Y”));