Cars get "used" to how they are used, everyone thinks it's a good thing buying a "one elderly lady owner" car and then can't understand why it begins to fall apart as soon as you start thrashing it. Engines in particular don't like a sudden change of use.
EML's (engine management lights) are the bain of my life! Joe public think it's just a case of plugging in the computer and it will tell you exactly what's wrong and how to fix it, oh if only life was so simple! I've lost count of the times I've been to cars where EML's came on but have subsequently gone off, no fault codes stored, or no eml on and no code stored but there is an obvious fault. And it doesn't help when you get a error message along the lines of fuel trim bank 1 circuit too high! Why don't they write it in english?!
A few years ago when tesco's had the dodgy petrol we were getting loads of oxygen sensor fault codes, garages would replace the sensor only for it to not cure the fault, the fault turned out to be the wrong additive in the fuel coating the sensors, the computer was correct in that it was getting unexpected readings from the sensor, but the sensor wasn't faulty! The contamination was corrupting the readings.
It takes a good detective and some lateral logical thinking to work out exactly what's going on sometimes, was reading of a case the other day, car misfired when cold but when warm was OK, owner had taken it to 4 different garages and in turn had replaced injector, ignition coil, spark plug, coolant temp and ambient air temp sensors to no avail. all the eml kept telling them was there was a misfire on number 3! It turned out 3 years earlier the cam belt had broken (previous owner had to be contacted to find this out). number 3 inlet valve had been bent and was replaced at the rebuild. It turned out the con rod on number 3 had bent slightly during the impact but this had not been spotted, the 4mm difference in length was enough to reduce the compression when cold to give a misfire but when it warmed up it worked OK!
Getting onto your Rio (for the love of god why? :no: ) it sounds like it developed a misfire to me, perhaps your well intentioned thrash caused something to get hot and breakdown under load (coil, plug, lead (if it still has them)) or even a poor connection that when hot gave an excessively high resistance, once it had cooled down fault was gone.
Disconnecting the battery may have done a system reset on the electronic control unit (ecu) like when your PC crashes and you turn it off and turn it back on again, but this doesn't work on all cars, some need a eobd (electronic on board diagnostics) tool to do this. But that may be a red herring, it may have just fixed itself by cooling down. An eobd reader may be able to retrieve a code but not always.
General rule of thumb with all orange warning lights is like traffic lights, if the car is running OK then it's OK to drive with caution but needs to be checked out. Don't drive with a misfire as unburnt petrol could enter the cat which isn't good over a prolonged period although newer systems will turn off the injector if it detects a misfire to prevent this.
Another thing with misfires is the ecu may have turned the injector off deliberately, some systems do this when it detects overheating, a cylinder pumping air with no fuel in it will actually cool it down so injectors are turned off in turn to try and stop engine damage! It's getting really complicated out there :lol:
The sludge in your filler cap is almost certainly condensation reacting with oil fumes, a classic symptom with short journey driving especially on cars where the rocker box is above the height of the radiator as cold air rushes in and hits the rocker box and you get the cold outside warm inside scenario, anyone with central heating in their house would have experienced the condensation build up on the inside of their windows. Owners of vauxhall chevettes would know all about this, it was not uncommon to get a pint of the stuff out of the rocker box every service!