Strontium burns bright red and Barium burns bright green - adding a fun color to your fireworks.
Each element has a unique atomic emission spectrum (visible light released) when excited electrons relax back into their ground state.
the electrons become excited when they absorb energy from their environment, jumping from their ground state configuration into one of many excited states (this is where the term "quantum leap" comes from, the electron must leap from one energy level to the next, it can't exist in between - the amount of energy required for the leap is a "quanta")
when the electrons return to their ground state, they must emit radiation - this is called the atomic emission spectrum .
Because each element has its own distinct electron configuration, the type of energy released (ie. visible light) is unique to each element.
Flame ionization is used to identify the presence of elements (color of light) and the quantity of each (intensity of light) - to describe the composition of an unknown substance (another application)