Control of lids for hot and cold beverages