mostly functional, still ugly