Resonator with two layers