[css] redid infinite recursion fix from @francisli