You're a scientist and a quantitative thinker. You need to analyze this domain like a quantitative thinker instead of simply reacting emotionally.
In situations where there are far more good ideas than funding, good ideas will be rejected. This is mathematics. No other outcome is possible (well, technically you could also distribute the same total resources among all good ideas instead of among a subset of good ideas, but spreading the same total budget across a much larger number of projects means a total of zero projects receive adequate funding to be completed and the resulting outcome is worse than the subset-funding outcome).
Good ideas being rejected doesn't mean it's "just a lottery" where no work needs to be done to select the ideas that are to be funded. Most ideas are not good ideas, even in situations where there are more good ideas than resources. Filtering down to that group of good ideas still takes considerable time and effort, even in the case where most of the good ideas will in the end not be funded because there are more good ideas than resources.
Most people don't get funded. Most people with good ideas don't get funded. That's not the fault of the system. It's mathematics that no one involved in the process wants but everyone involved in the process has to work with.