Your notion of “decent” is certainly not the same as 99.99% of the population. Or you live in a very expensive place and have a very specific use of mountain bikes.
Yes my notion of “decent” is skewed because I’m doing 3000 foot climbs/descents on highly technical and fast trails with drops, jumps, rock rolls, wet roots, etc. You can ride those on a $500 Walmart bike but you might not survive it lol. There’s deals to be had, direct to consumer bike brands are considerably cheaper (like $1000 cheaper in general I’d say) and there’s obviously more budget oriented options, but their performance, longevity, and weight are typically not as good.
I was going off of a ballpark average of what I’ve been seeing in media and bike shops over the last couple of years. Seems like every mountain bike even with lower end components is $5k+ these days, but media tends not to cover cheaper stuff because it’s not as interesting.