Leia, how are you measuring body fat? We've talked about it a lot in various forums here on 3FC and most of us agree that there isn't a really good way to measure fat percentage. The most accurate is that dunking in water thing, and even that varies wildly enough to not really be accurate. The electric machines are the least accurate, when compared to skilled use of calipers. Unskilled use of calipers, however, is totally inaccurate.
Guess what I'm trying to say is to not stress about it. It's unlikely that you actually gained fat. VERY unlikely. What's more likely is that your method for measuring was somehow skewed by the changes in your body. It's inaccurate, not you! I get my fat percentage checked at my nutrition clinic. They place two diodes on my hand and two on my foot and run current through my body. It's fast and seems to be fairly accurate. If you're truly concerned, you might see if you have a nutrition clinic locally that can help you with this. Otherwise, try measuring yourself with a tape measure and look for lost inches--fat takes up more room than muscle.