A two-layer depth-averaged model of dry granular material for dam-break flows