// ugly hacks to get as close to the design as possible
$('document').ready(function(){
    // "more" links
    $('div.text').has('a.more').each(function(){
        me = $(this);
        more = me.children('a.more');
        p = me.children('p:last');
        p.append('<span class="space"> </span>');
        p.append(more);
    });

    // navigation item spacing
    navig = $('#navigation ul');
    items = navig.children('li');
    separators = items.filter(':not(:has(a))');
    total = 0;
    items.each(function(){
        total += $(this).width();
    });
    spacing = parseInt((navig.width() - total) / (items.length - 1));
    separators.each(function(){
        $(this).css('margin-left', spacing).css('margin-right', spacing);
    });

    // search form submit ;)
    $('#search label').click(function(){
        $(this).parent().submit();
    });
});

