The 17-year-old Brandt became Leverkusen's youngest ever goal-scorer in the Bundesliga.
Hamburg's late surge saw it climb above Nuremberg and Stuttgart in the table, pending their home games Saturday with Borussia Moenchengladbach and Freiburg, respectively.
"It's a great feeling for the lads," Hamburg coach Mirko Slomka said. "This win isn't just good for the team; it's good for the city, for the fans. I think everyone deserves it."
The result increases the pressure on Leverkusen coach Sami Hyypia with fourth place no longer secure. Both Moenchengladbach and Wolfsburg can overtake his side with wins on Saturday.
"We're not paying attention to this discussion (about Hyypia)," Leverkusen captain Simon Rolfes said. "Luck isn't on our side."
Leverkusen has just one win from its last 12 competitive games.