diff --git a/css/filedepot.css b/css/filedepot.css
index 1066fa0..3c71e26 100644
--- a/css/filedepot.css
+++ b/css/filedepot.css
@@ -33,9 +33,10 @@ body.layout-left-main .outer { margin-left:0px !important; }
   padding:0px;
 }
 
-#filedepotmodule table { margin: 0px !important; border: 0px !important}
-#filedepotmodule tbody { border-top: 0px; }
-#filedepotmodule form  { margin:0px !important }
+#filedepotmodule table, #filedepot_panels table  { margin: 0px !important; border: 0px !important}
+#filedepotmodule tbody, #filedepot_panels tbody { border-top: 0px; }
+#filedepotmodule form, #filedepot_panels form  { margin:0px !important }
+#filedepot_panels { z-index: 2010; }
 
 /* general alignment classes **************************************************/
 .alignleft {
diff --git a/filedepot.module b/filedepot.module
index 454977b..da81cbe 100644
--- a/filedepot.module
+++ b/filedepot.module
@@ -441,6 +441,7 @@ function filedepot_access($op, $node) {
  */
 function filedepot_main($id=0) {
   $modulepath = drupal_get_path('module', 'filedepot');
+  drupal_add_js('Drupal.behaviors.filedepot = function() {$("body").append($("#filedepot_panels"));}', 'inline');
   drupal_add_css($modulepath . '/css/filedepot.css');
   drupal_add_js($modulepath . '/js/filedepotlanguage.js');
   drupal_set_breadcrumb('');
diff --git a/theme/filedepot-mainpage.tpl.php b/theme/filedepot-mainpage.tpl.php
index 02dd3eb..64ffb24 100644
--- a/theme/filedepot-mainpage.tpl.php
+++ b/theme/filedepot-mainpage.tpl.php
@@ -200,7 +200,7 @@ All the needed style sheets should be loaded automatically by the loader.
   <div class="clearboth"></div>
 
   <!-- Supporting Panels - initially hidden -->
-
+  <div id="filedepot_panels">
     <div id="filedetails" style="display:none;">
       <div id="filedetails_titlebar" class="hd"><?php print $LANG_filedetails ?></div>
       <div id="filedetailsmenubar" class="yuimenubar" style="border:0px;">
@@ -415,6 +415,7 @@ All the needed style sheets should be loaded automatically by the loader.
       </div>
     </div>
 
+  </div> <!-- end supporting panels div -->
 
 </div>   <!-- end of filedepotmodule wrapper div -->
 
