You are witnessing the collision of two conventional constructions.
One is the juxtaposition of "nicht
B". Basically. "sondern" can only be used in combination with a preceding negation of some kind - most usually, "nicht".
The other is the transformation of "nicht" + "ein" into "kein". "Nicht" can be used to negate almost anything: it can even apply to articles, adverbs, subordinating conjunctions. But in combination with the indeterminate article it usually transforms into "kein".
Now combine both effects. The transformation construction prefers "kein", but the "sondern" construction prefers explicit "nicht" over implicit negations such as "keine" or "selten". Both preferences are strong but not absolute, so one of them has to give (if they were absolute, you couldn't combine them in this way). In this case, the transformation construction gave way.
Note that this is not the only situation where the "keine" transformation is inhibited. For instance, you can stress the indefinite article to emphasize how appalling it is that no one passed the exam:
Nicht einer von euch hat die Klausur bestanden!
This is another context in which transformation doesn't happen.