why not use the world aligned material and world aligned normal nodes? they do exactly that, on XY and Z