Planar superconducting resonators with internal quality factors above one million