Quantum mechanics is the branch of physics that deals with the behavior of matter and energy at the atomic, molecular, nuclear, and even smaller microscopic levels. Unlike classical mechanics that describes macroscopic phenomena, quantum mechanics governs the behavior of particles at the atomic and subatomic scale, including electrons, photons, and atoms.