Can't you lose bone when your period stops due to low body fat?

When I was running half- and full marathons, I had very low body fat. I was too thin. My gyne told me that staying on the pill "saved" my bone mass.