Connect all of your pieces together for a test fit. This will help you double-check your work so you don't mistakenly remove too much material and ruin the gate. There are three places where you are likely to find the most excess:
the upper linear ratcheting mechanism support
the lower linear ratcheting mechanism support
all four corners of the gate, i.e. two corners per panel
When marking the excess that can be cut off from the upper and lower supports, leave about 1/2" of reveal to ensure that there is enough material to support the connection. On the other hand, the corners can be cut flush with the edge of the panels.