I would leave WDW no later than 3-3:15pm, which should leave you enough time to stop for gas, return the rental car and walk to terminal.
Sometimes going through security can be long, longest I've ever experienced was 40 minutes (average is probably 20) you should get to your gate at least 30 minutes prior to scheduled departure.
You should have a couple of minutes to spare to use the restroom or pick up a snack before boarding.
I always use Rt 417 returning to the airport, never experienced heavy traffic.
If you are using a participating airline, by all means use RAC at your resort, it will save you time at the airport not having to check bags. If you can't use RAC give yourself a little extra time.