I think it'll either need to be a very early or a very late POD. What I could see is the Welf dynasty succeeding at building up a power base that later serves to coalesce 'Germany' around it the way the Capetian Ile de France did. Hamburg was a town in Welf lands, and its position will make it important as soon as the Baltic and upper elbe open up for trade and settlement. It is also clpose enough to the 'South' (in these terms, the Westfalia and Rhineland) that it won't put the ruler too far away from the action if he uses it. And it has lost out as episcopal residence, so having a duke may look attractive. Of course all that is before Hamburg becomes in any way important or powerful, so it's more a matter of 'a capital in the place we have Hamburg today'.
A Hanseatic land empire is all but impossible. the structure of the Hanse makes any such ambitions near impossible. And Hamburg *was* a serious territrorial power with extensive holdings along the Stecknitz, the Lübeck corridor (jointly with Lübeck), East Frisia, the upper Elbe and up the Alster and Ossenweg. That was about as well as any such city could realistically hope to do.
I'm thinking later on it could serve as a compromise capoirtal simply because it has no history of royal residence or political power projection. A democratic North German League might pick it. Or - for a really far out idea - post-1945 the Labour government goes *really* left and is met halfway by a more accommodating USSR due to a series of convenient heart attacks in the politburo. THis makes a three-way confrontatzion - capitalist USA versus nationalist-traditionalist France (threatened by its own strong Communist movement) versus Labour Britain and Communist Russia. Enter the 'Bi-Zone', complete with its 'Western' enclave in US-occupied Bremen and its quest for a new capital. Berlin is tainted by Prussian militarism. Hannover's a village. The Ruhr isn't a city. Cologne is too close to the enemy. Dresden won't be acceptable to the northerners. And Hamburg, conveniently, has lots of empty space to build the infrastructure of government.
I don't think so, either. But the image is cool.