the command for export your movie from Logic is under the File Menu
File ➤ Movie ➤ Export Audio To Movie ...
Once you select that option and the file destination, Logic opens a window that lists the audio track of the original movie. When the checkbox is enabled, then that audio track is mixed together with your stereo mix of your Logic Project.
However, I would recommend to import that audio track from the video and mix it in Logic together with your other tracks. That gives you a much better Control. When you first import the movie, you get a Dialog Window that asks you to extract that audio track from the video. You cn also import it later with the command "Import Audio from Movie.
When exporting, enable the Cycle Range to determine the start and stop time of your movie export.
I explain all those little details in my book "Logic Pro X - The Details" with lots of graphics and diagrams that help you understand how that all works.
Hope that helps
Edgar Rothermich - LogicProGEM.com
(Author of the "Graphically Enhanced Manuals")
http://DingDingMusic.com/Manuals/
'I may receive some form of compensation, financial or otherwise, from my recommendation or link.'