Do the Bernstein polynomials form an orthonormal basis in some inner product space?

I'm trying to better understand the constructive proof of the Stone-Weierstrass theorem. I know that the sequence $\sum f(\frac{k}{n})\binom{n}{k}x^k(1-x)^{n-k}$ will uniformly converge to $f$ on the compact interval $[0, 1]$.

What I am having trouble with, though, is finding a "story" that explains how such a fact would have been discovered. As I understand it, there's some explanation in terms of moments of probability generating functions or something to that tune.

However, I don't have as strong a background in probability, and I feel I should be able to find an (historically fictitious) explanation that doesn't depend on it.

I'm led to the following problem. Treating $B_{n,k}(x) = \binom{n}{k}x^k(1-x)^{n-k}$ as a basis for the polynomials of degree bounded by $n$, can we define an inner product $\langle-,-\rangle$ which makes this into an orthonormal basis.

This way, when $f$ is polynomial of degree less than $n$, the coefficients $f(\frac{k}{n})$ would appear naturally as $\langle f, B_{n,k} \rangle$. And similarly, for arbitrary continuous functions $f$ defined on $[0, 1]$, we might be able to extend the inner product to one for all of $C[0, 1]$ and treat the Bernstein approximations as a sequence of orthonormal projections of $f$ onto an increasing chain of nested subspaces.

So I am wondering if anyone can point out any glaring problems with this approach before I attempt it. On the other hand, if this is a standard way of thinking about the problem, I'd love to know that too.