Need help with a basic accordion script.

Need help with a basic accordion script.

I've got my accordion working.
http://www.bassettboy.com/salt2/

The html and jq are as follows
  1. <div class="nav">
  2. <h3><div></div>
  3. <h3><div></div>
  4. <h3><div></div>etc..
  5. </div>
  1.   $(document).ready(function() {
  2.   $('div.nav> div:gt(0)').hide(); 
  3.   $('div.nav:eq(0)> h3').click(function() {
  4.     $(this).next('div:hidden').slideDown('fast')
  5.     .siblings('div:visible').slideUp('fast');
  6.   });
  7.   });
This hides all divs except the first one (check the site) on load, then whenever I click a h3, it performs as an accordion, sliding the hidden div down and other visible divs back up.

I want to add another functionality. I want it to be like, if you click on a h3, and the next div is already open, it will hide that div. else, it performs this function. This would be a basic if/else then wouldn't it? I'm new to jq but I've done mIRC scripting in the past and I don't know how the selectors work yet. Any help?