ill just throw it out there because its comon and would cause the idle problem that you have.
the intake piping from the air filter to the throttle body(rubber hose) tends to crack and since it cracks after the mas air flow sensor it allows un metered air into your engine and your air/fuel...