Almost complete version
final before all details
some small cosmetic changes