make it more general, factor out css