Salary caps are usually described as spending limits, which is the wrong mental model for basketball. The system is not a wall that stops teams at a number. It is a dense set of permissions, exceptions and penalties, and what it regulates is less how much a team spends than what a team is allowed to do once it has spent. Reading a roster decision correctly means reading which permissions the team still holds.
The aprons are where that becomes clearest. They are the mechanism by which a system built on charging teams money for excess payroll shifted toward denying them transactions instead, and that change altered how expensive teams are assembled, how long they stay together and why star players get traded while they are still obviously good.