Modelling the transition between fixed and mobile bed conditions in two-phase free-surface flows: The Composite Riemann Problem and its numerical solution