Dynamical adaptation in biology on multiple scales: from cells to collectives