Weight loss help during period?

hi I need some guidance. How do I go about losing weight/tracking it correctly if I gain about 5 pounds of water weight during my period (which starts about a week before, and then lasts until the blood stops)? This has become such a massive challenge for me, because when I think I’m losing weight, I’ll get my period then it’s almost as if I’m taking two steps back. Does anyone have advice on how to combat this? 😔 It’s upsetting because I broke my foot and gained a little weight and just want to get back to what I previously was ~which my doctor recommends for the health of my foot recovery~