Igneous rocks form when magma or lava cools and hardens. They are classified based on where they form, their texture, and composition. Igneous rocks that form inside Earth's interior through slow cooling are intrusive with coarse textures, while those forming outside through rapid cooling are extrusive with fine or glassy textures. The rate of cooling influences crystal size, with slow cooling leading to large crystals and fast cooling resulting in small or no crystals.