I think this question may involve more than Spanish, and may include Romance languages or even Latin.
I wonder why, when, and how did vowels E and I get special treatment from consonants like C, G, ...