gold ends lower, logs third-straight session loss