Learning delays through gradients and structure: emergence of spatiotemporal patterns in spiking neural networks | Synapse