Why is Heapsort in O(n log n) if not all n operations take time log n?
$n \log n$ means each $n$ nodes has $\log n$ operation.


No, it does not. That's like saying:


  \$100 means I sold 100 drinks for \$1 each


Obviously, you could have sold any number of things as long as they add up to \$100.

With algorithm costs it's the same. A sequence of operations taking "time" $\Theta(n \log n)$ means that the "time" costs of all the operations add up to something that behaves roughly like $n \log n$.

Once Landau terms enter the pickture, things get muddled. It's tempting to tread $\sum_{i=1}^n O(\log i)$ in the same way as $\sum_{i=1}^n \log i$, but the former sum doesn't really make sense. I recommend you read our reference questions on algorithm analysis and asymptotics to see how one can arrive at the final result here.