A group of 12 friends wants to buy a farewell gift for their teacher. Initially, they planned to split the cost equally among all 12 members. However, due to unforeseen circumstances, 5 friends were unable to contribute, and the remaining friends had to share the cost equally. As a result, each person's share increased by $10. What is the total cost of the gift? Let's think step by step and output the final answer within \boxed{}.
user