unity – Make a rigidbody walk around a planet

I have my character with a rigidbody and attracted by the planet. I am trying to move it with its velocity. I tried this script:

    Vector3 x = Input.GetAxis("Horizontal")*transform.right*speed;
    Vector3 z = Input.GetAxis("Vertical")*transform.forward*speed;
    rb.velocity = new Vector3(x.x + z.x,rb.velocity.y,x.z+z.z);
    rb.AddForce(-transform.up * GravityForce);

and I have also tried with transform.TransformDirection but the result is the same. Everything goes well until I get to the middle of the planet, then my character stop going forward. Also, it sometimes stop sticking to the planet as if my character sometimes start going straight instead of going straight relative to its rotation around the planet.