The point being: yes, they could absolutely use the replicator to create "perfected" tools and machines. No user serviceable parts, when broken, please recycle at nearest replicator. They don't though. They still design and implement parts like the end user is intended to open them up, rearrange the guts, and duct tape it back together. But that's what you get when you don't exist in a society that worries more about the value of the intellectual property over how it's used... and when you can trust the population not to abuse the intellectual property. When no one is rushing to generate wealth to ensure they remain above poverty: the population doesn't worry about how to make the quickest buck possible and the corporations (and they do still exist in trek.) honestly don't care about safeguarding the bottom line and only the bottom line. In that state: the population functionally becomes part of the dev team. You give credit where due, and changes made by enterprising nobodies get implemented because the company isn't paying out royalties on circuit designs and software, and the people are literally just after bragging rights; "I made a change that influenced the entire world and beyond".
I think the user-serviceable technology is a very good way to visually represent the ethos you're describing, which is nearly identical to FOSS or the maker movement, which I think further is both very based and very Star Trek.
I do not agree, just as a matter of sci-spec, that it would actually
look like that. I think anyone with any engineering interest at all and want to improve or repurpose a small device or component would have a replicator at home that could do tech stuff, and would make their modifications to a hologram and print the results.
We could have a Star Trek economy today if we abolished the police, ate the rich, declared IP null and void, instituted UBI, and implemented worker democracy in all workplaces, but that's a completely whole other everything not to be explored here.
Like Wonko said, most of the time when they're stealing an Enterprise, all they need is to get from point A to point B for a relatively short amount of time, typically in an emergency, and don't need much more than that and/or short term combat capability. You only need a limited number of systems working at full efficiency for that, and you'd expect the combat ones to have enough redundancies for if something breaks to immediately spin up redundancies. That's why it seems they can always get away with a small number of crew(outside of plot convenience) - there's no need for all the regular maintenance these ships probably need before it slowly cascades into failure as minor problems become major. Murphy is always watching, and even if you try to rely on drones, those drones will need their own maintenance, and we all know how technology never has bugs or problems of it's own.
As for non-engineering staff, you need manpower for landing and exploring things an making decisions on the spot. You could probably replace some of that with drones, but I don't think it would help First Contact at all. Honestly, A lot of them and the Science crew is probably partly there for their creativity, as the computer on most ships is not designed to have initiative of its own, to come up with off-the-wall solutions. Of course giving them initiative doesn't always work out, like the Texas Class, so it could also simply be to make sure the gazorninplatz radiation doesn't make the ship suddenly start a intergalactic incident or that the ship doesn't decide the best way to solve the problem of a colony infected with Space COVID is to wipe out all life there before the colonists can spread it elsewhere.
I feel like things like the Texas Class are the handwave by which the rest is supported
but there is an undeniable truth to the idea that if a job needs a human intelligence, then any AI that does the job will either be bad at it, or will be intelligent enough to qualify as a sapient being anyway.
It's also a valid point as Cybersnark says that operational staff have three shifts and you need people to cover all of them, even though we only ever see the one bridge crew on their 9-5. Maintenance has crews and engineering has a whole team of its own standing around pushing buttons under normal conditions. If a third of the crew on shift at any given time is fixing things and emptying biofilters, I guess engineering and bridge crew could get most of the way to 100, and maybe the rest are doing science stuff we never hear about or something.
I also think the fact that fancy flying, security, ship repair, and medical care are the things that we see the crew actually doing much of the time are not so much because those things are particularly well suited to humans over machines, but because they are very well suited to television. The now obligatory pilot role carved out by Tom Paris especially, since by all rights the computer should be so much better at it than a human that the computer might as well be asking for help on its math homework, but security should also be a complete nonissue when the ship has internal sensors and force fields that by all rights ought to be able to detain anyone on board instantly and indefinitely on command.
And no one wants to watch researchers researching.
I don't know, I still think that Deep Space Nine had a magic formula that's just not available to any of these other shows, since every member of the cast had a specific job and those jobs could be very diverse thanks to the setting being more like a little town and not something that we have to conceptualize as being sort of like a navy ship. (And once in a while we even hear about the other shifts.) To think of it, Voyager had something too - you don't have to ask why anyone on the ship is there, they're there to get home.
Anyway, if a sizeable fraction of the crew complement of a Starfleet ship under normal operation is actually a whole science department faculty, or random art students self-bettering themselves or whatnot, I kinda want to know about it and see what that actually looks like.