Hoffenheim ended Bayern Munich's 23-game winning streak in all competitions with Andrej Kramaric scoring his fourth and fifth goals of the season.