Kinematic and stellar population properties of the counter-rotating components in the S0 galaxy NGC 1366