Variational calculations of the lowest 2S and 2P states of the Li atom