Investing in the education and health of girls pays huge dividends.