I do not think you are trying very hard to grasp the biblical viewpoint presented.
If God does not credit a person's faith as righteousness, it is (by logical necessity) unrighteous.
I do not think you are denying some profess faith, but their "faith" is lacking. For example, Matthew 13 and soils two and three. Soil Two received the gospel with joy, but their faith was not a deeply rooted commitment. Soil Three trusted in the gospel, but Christ became one of several priorities, rather than their overriding priority. Then we have Matthew 7, and folks declaring "Lord, Lord" but they had not made Christ the Lord of their life as they practiced evildoing. Lastly we have Judas who professed faith, but was a non-believer from the first.(Luke 9:1-2)
Ephesians 2:8, For by (God's) grace you have been saved through (God credited) faith.
Hebrews 11:6, But without faith (as determined by God) it is impossible to please Him.
Let us consider a description of Abraham's faith: (from Romans 4)
Without becoming weak in faith he contemplated his own body, now as good as dead since he was about a hundred years old, and the deadness of Sarah’s womb; yet, with respect to the promise of God, he did not waver in unbelief but grew strong in faith, giving glory to God, and being fully assured that what God had promised, He was able also to perform.
Now is the faith of only Abraham the limit of God's discernment and crediting as righteousness? Nope.
Now not for his sake only was it written that it was credited to him, but for our sake also, to whom it will be credited, to us who believe in Him who raised Jesus our Lord from the dead,
Thus God credits the faith (based on His knowledge, for He knows our hearts) of those He determines actually "believe in Him."