This is a problem many women (like me) wish they had.
I thought I was going to read that you were finding 40 mi per day not sustainable from a time standpoint, not from an issue of weight loss. <jealous>
It actually is about caloric intake
. With the increased activity you are burning more calories than you are taking in. Here's an interesting stat: Olympic swimmer, Michael Phelps, when he was in daily training, was eating 12,000 calories a day. Consider it takes an abundance or deficit of 3,500 calories to gain or lose 1 lb.
If you don't want to lose weight or don't want to lose weight at that level then eat more calories, choose healthy fats and increase those as well, and maybe do a little weight training to build up more muscle too. Carbs put weight on me faster than I can practically eat them. (A bowl of brown rice & beans (supposedly healthy) will bulk me up almost immediately. If I eat that 3x a week I could easily put on 10 lbs in less than a month. And that's not muscle weight we're talking about.
Anyway, add an extra 500 to 600 calories to your food intake per day to reduce your weekly weight loss by 1 lb. Or, if you like where your weight is currently, add an extra 900 to 1,000 calories to your diet each day you are doing that 40 mi commute. If the weight loss continues and you want it to stop, keeping adding in calories per day until you stabilize.
It comes down to a math equation and you need to figure out how to get your input of daily calories to be equal to or just slightly less than your output of calories.