Sequential Nonparametrics: Invariance Principles and Statistical Inference