Rotate GameObject with children around itself on mouse drag

I’d like to rotate my GameObject with a set of spheres as children around itself. Until now I’ve written the following code:

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class ObjectRotator : MonoBehaviour{
    Vector3 mPrevPos =;
    Vector3 mPosDelta =;

    void Update(){
            mPosDelta = Input.mousePosition - mPrevPos;
            if(Vector3.Dot(transform.up, Vector3.up)>=0){
                transform.Rotate(transform.up, -Vector3.Dot(mPosDelta, Camera.main.transform.right), Space.Self);
                transform.Rotate(transform.up, Vector3.Dot(mPosDelta, Camera.main.transform.right), Space.Self);
            transform.Rotate(Camera.main.transform.right, Vector3.Dot(mPosDelta, Camera.main.transform.up), Space.Self);
        mPrevPos = Input.mousePosition;

But this code does not work as I want to. I’d like that my GameObject stays in the same position, but on mouse drag it rotates. Could you help me please?

Did you ever figure it out?