Counting pairs of intervals where one is a subset of the other
Sort all endpoints of intervals, and maintain a self-balancing order statistic tree, initially empty. Scan the endpoints from left to right. Add each left endpoint to the tree. When reaching a right endpoint, determine the order statistic of the left endpoint, and then remove the endpoint. Update the number of intersections accordingly: if the left endpoint was that $i$th smallest element (counting from $1$), then add $i-1$.

Since each operation on a self-balancing order statistic tree takes $O(\log n)$, the entire algorithm runs in $O(n\log n)$.

As an example, consider your list of intervals.


Initially, the tree is empty, and the counter is 0.
Read left endpoint of [1,7]. Tree contains 1.
Read left endpoint of [2,60]. Tree contains 1,2.
Read left endpoint of [3,5]. Tree contains 1,2,3.
Read right endpoint of [3,5]. Since 3 is the third smallest point, increase counter by 2. Tree contains 1,2.
Read right endpoint of [1,7]. Since 1 is the smallest point, increase counter by 0. Tree contains 2.
Read right endpoint of [2,60]. Since 2 is the smallest point, increase counter by 0. Tree is empty.