Inventory is tracked per variant per location, and every change is a stock movement row. Movements are append-only and arithmetically checked, so the quantity on the shelf and the quantity in the database can be reconciled at any point in time.
Every stock change is recorded as a movement with the quantity before, the change, and the quantity after, giving you a full audit trail.
Track stock separately per warehouse or shop, so orders are fulfilled from the location that holds the item.
If stock levels and recorded movements disagree, an alert is raised instead of the difference being silently corrected.
Set a low-stock level for each variant, and restocking appears in your task list before you run out.