Improve formatting and alignment of query list items

Fix #379.