move preview css to own file
simplify templates; add some comments