Moved all of your javascript tags inside the head and then work backwards, only moving javascript code back to the body if absolutely necessary.