Category is determined by purpose
Riding position, fuel capacity, weight distribution, suspension travel and fairing all follow from what the bike is meant to do. A machine designed for long distance carries luggage, weather protection and an upright riding position. One designed for rough terrain has long suspension travel, knobbly tyres and almost no bodywork.
Several questions describe a set of characteristics and ask for the category name. Working from purpose rather than appearance gets you there.