Bacterial chemotaxis: information processing, thermodynamics, and behavior