Write SQL query to solve given problem: What is the longest duration for a bike trip starting on a day with a fog in 2013?. Keep the solution inside sql tag ```sql [SQL-Query] ```
SELECT MAX(T1.duration) FROM trip AS T1 INNER JOIN weather AS T2 ON T2.zip_code = T1.zip_code WHERE T2.date LIKE '%2013%' AND T2.events = 'Fog' AND T2.zip_code = 94107