For ThemeBuilder version 5.5.0+ / Confluence 5.9.7+ the flaglogic method has been changed. Please see the 'main' panel for the logic that controls which sidebar panel to show.
For a standard page the nested panel order is therefore
In the with-sidebar panel this looks like
Notice the two ‘panel-element’ macros for page.ia-sidebar and page.footer. This tells ThemeBuilder to use the default Confluence content for these areas. To customise the content in this area you would make a new panel, add your content, and use the ‘panel-import’ macro with your new panel name to replace the panel-element macro.