Autopoiesis, structural coupling and cognition