Why Amazon produced its first $2bn quarterly profit