Daniel and Gabriel started jogging at the same time along the route shown. Both did not change their speed throughout. After 50 min, Daniel was at the halfway point and Gabriel was 540 m behind. Daniel reached the end point 4 minutes before Gabriel. What was the distance of the route? Express the answer in m.