Static stability of loose materials under wave attack: New design formulae and probabilistic approach