Sam sold his dining table set at a loss of 20%. If he had sold it for ₹800 more, he would have received a profit of 5%. Find the cost price.