Correct me if I'm wrong, but I don't think the Court did - or could - decide that the tax itself is constitutional. That battle will likely be fought later.
Roberts himself changed the mandate into a tax in the majority opinion. If he planned to kill it as unconstitutional then, why kick it down the road? Why not just leave it as a mandate, which was already unconstitutional?