Arrange invoice lines flexibly

improved