Gold snaps a five-session slide as the dollar retreats