Modularising code

Modularising code, cleaning, extra css for scales