Java implementation of a custom Height Balanced Binary Search Tree (HBTree), where each node is balanced if the height difference of its subtrees is ≤ max(1, ⌊log₂(N)⌋). Each node stores its height and weight.