Justin, Elijah and Oscar shared the cost of a present. The ratio of Justin's share to the total share of Elijah and Oscar was 1 : 4. The ratio of Elijah's share to the total share of Justin and Oscar was 1 : 5. Elijah's share was $112 less than Oscar's share. How much did the present cost?