The mechanical energy of a bicycle at the top of a hill is 6,000 J. The bicycle stops at the bottom of the hill by applying the brakes. If the potential energy of the bicycle is 2,000 J at the bottom of the hill, how much thermal energy was produced?