How is momentum conservation valid in the vertical direction in this scenario? 


In the given situation, a small block of mass $m$ is projected
    horizontally with a speed $u$ on a large curved wedge of mass $M$.
    According to one of my books, the block will gain both horizontal
    velocity $V_x$ and vertical velocity $V_y$ as shown in the picture. 


My questions are: 


*

*How does the block possibly attain a vertical velocity upward, though initially the momentum is $0$ in vertical direction ? How is momentum conserved in vertical direction even though the larger wedge cannot move vertically downward ?

*Does it depend upon whether wedge is free to move or not ? (In this situation the wedge is said to be free to move).


Assume all surfaces to be friction-less.
 A: *

*The block slides up. Like a ski jump arcade game (where the ball starts rolling horizontally but hits a ramp at the end and jumps up into the hoops) .



(source: bmigaming.com) 
Momentum is not conserved in the z direction since obviously the ground is providing a normal force.  You could think of the "lost" momentum being transfered into an imperceptible change in the momentum of the earth.  
Think about when you pick up a book: the book has vertical momentum even though your arm isnt moving in the opposite direction to conserve momentum.  Rather, the normal force from the floor is translated through your body so that the system of you + earth+book conserve momentum.  


*

*It does depend on whether the wedge can move or not:  if the wedge is totally free to move then instead of being projected upwards, the small block will "stick" to the wedge and the combined body will continue to move in the direction of the blocks initial velocity (with a new velocity preserving momentum of the combined system).  Of course in most real life scenarios the wedge will have some friction with the ground below it and so there will be a combination of these two effects (i.e. block energy is translated into both horizontal motion of wedge and vertical/horizontal motion of block).

