Bt works by producing Cry proteins during sporulation. When insects ingest these proteins, the alkaline environment in their gut activates the toxins, which then bind to specific receptors in the gut lining. This causes the gut cells to rupture, leading to the insect's death.