In professional sports, why do some players get recognized more/ more playing time versus players sitting on the bench, possibly getting no time to play?
why do some players get [...] more playing time
Because they're better. The aim of a professional sports team is to win, and you win by playing your best players. There are some second order effects around trying to maintain a strong squad and players not necessarily being happy if they aren't playing, but they are very much secondary to very simple idea of letting the best players play.
I'll extend this some to answer the logical expansion:
Why are there players on the bench that do not play?
Most sports teams have a set of "starters", which are typically the players who are, today, the best at playing each position. Sometimes that's a bit fuzzy, because of human nature; oftentimes veterans play instead of rookies (players in their first season), for example, even if the rookie is physically "better", because some coaches believe rookies don't have the experience to deal with in-game situations. But ultimately, most of the time it is simply the best players on the team that "start" - meaning, play on the first second of the game.
Some sports simply play those players the entire game most of the time. Less physically demanding sports, like baseball, do that more often - in baseball, you could use only the starting 9 and no others, though usually at least the pitcher is replaced. Other sports, like soccer, do mostly use the starting lineup, but because of the rules of the game - only three substitutions are allowed in many common rulesets, for the whole game (including for injuries/etc.), and so in soccer most of the starting 11 play the whole game.
In Baseball, the bench for hitters is usually there for specific purposes. There is usually one or more "bench bats", meaning players specifically there to come in during a game when a big hit is needed, and hit instead of one of the more defensively oriented players, or a pitcher. There is usually one or more "utility defenders", players who can play several positions well and can come in either in case of an injury or to give someone a day off. There is always one backup catcher, a specialist position that generally requires someone trained in its specifics, and usually plays in 20-40 games a season to give the starting catcher a rest. And then there might be pairs of "platoon" players, meaning players that hit well against pitchers with one "handedness" - right handed or left handed - and the other player hits well against the other handedness of pitcher. The starter for that day will usually be the player with the advantage.
Pitchers in baseball are an entirely different case. Baseball has "Starting" pitchers, usually the better pitchers, who can pitch for 5-7 innings at least, and start the game. They only pitch every 5 games or so, due to fatigue concerns. Then it has "relief" pitchers, who come in after the starter, and pitch an inning or so. They pitch maybe every other day (sometimes multiple days in a row), but only the one inning usually, or maybe two. Because of numbers, teams have about 11-13 pitchers- 5 starters, 6-8 relievers.
Soccer has some similarities to baseball, in that it usually has 11 starters, one specific backup goaltender (who is a specialist), and then a number of bench players who are there for particular reasons. A few of them might be specialist strikers or scoring midfielders, to bring in when the team is behind and needs goals. A few might be specialist defenders, or defensive midfielders, who come in when the team is ahead or tied and needs to hold the line. And a few might be young up-and-comers who aren't ready to start yet but need to get experience playing at the highest level, who come in occasionally. Because only three (or so) players can be substituted, they have to make sure and have a good bench of players to fill in depending on the need.
American Football is fairly unique, in that it has two entire "teams" - an Offense and a Defense - and they each are considered "starters". Most sports expect players to play both offense and defense, but for whatever reason American Football diverged from that - perhaps due to the physical nature of the sport. Their bench consists of backups for the many specific positions - I could name about 20 off the top of my head - plus specialists at non-"starting" positions, such as special teams. Certain positions usually are substituted for for fatigue reasons, such as defensive lineman, and most players end up taking at least a snap or two off. There are different defensive formations, such as a more "run heavy" 4-3-4 (front-middle-back) or even 4-6-1, versus a more "pass" oriented 4-2-5 ("nickel") or 4-1-6 ("dime"). Every player, or almost every player, plays at some point, except the backup quarterback, in every game, for most teams (assuming they do all of the usual things once a game, like kick a field goal and punt). Many of the younger/less skilled players play on special teams (covering kickoffs and punts).
Other sports, like Hockey and Basketball, allow infinite substitutions. Hockey usually has every player except the backup goaltender play, similar to American Football, but has its players organized as "shifts" - this is to let them take breaks and keep up their stamina. Hockey (in the NHL, at least) has four lines of three offensive players each (for twelve) plus three lines of two defensive players each (for six), plus the goaltender and backup goaltender, for twenty active players. The "first line", or starters, plays a lot more than the "fourth line" of offensive players, but all play some. How often each play is related to their skill, and to strategy - often one line is a "bruiser" line for example that might be subbed in to slow the game down and make it more physical.
Basketball does not have "lines", but some teams do have "second" teams that come in as a group and play together when the starters need a break. Most teams don't quite do that, but instead give breaks as often as needed. They also will often substitute to try and get advantages, for example switching in some extra players who are tall against a team that is playing taller players, or some faster players who can shoot from a distance against a team that is stronger inside. This varies much based on the team though; basketball, more than any other major sport, is a sport of superstars, and superstars tend to play most of the game, or even the entire game (rarely), due to their ability and the importance of their play to the team's performance. Most teams do have players who never see the floor for weeks at a time; they have 12 players on an (NBA) active game roster, but many of those are not as skilled and there for emergencies (due to injury or foul trouble only), kept either solely for that purpose (as minimum-wage players) or kept out of the hope they will be better players in the future.