improved rem mixin