Creating two sub queries using WITH clause
There are two problems with your query:


You are missing a comma before trip_mode.travel_mode.
If you want to reference the CTEs in the main query, you have to add them to the FROM clause.