refactored category mixin and changed style