The walk between B and Z would take you about 15 min. But you would have to go twice through security (once to AC lounge which is airside and once to Z).
The panorama lounge in A may be an easier option if you want to avoid FRA's main overcrowded LH lounges.