From gas to ice giants: a unified mechanism for equatorial jets