Relative oscillation theory for linear Hamiltonian systems with nonlinear dependence on the spectral parameter