Stochastic thermodynamics and fluctuation theorems for non-linear systems