You've gained muscle. So as you gain more muscle and lose fat, you change your overall body composition, which can result in a higher weight, but a smaller figure and better health.