States and transitions