You cant avoid loss of muscle during any type of calorie cut unless it is a minimal calorie cut of 200 or less. Your personal body type and hormone level will depend how quickly the body rebounds in building it up again. Basically you just have to use strength training and a higher protien diet after your post fast diet.
Since you say you are on a juice fast...Look up your daily needed calories for your weight. Drink that amount to stay at the same weight and retain muscle. You would still detox. But you wont lose. Use your lean body mass to get the most accurate calorie needs level.