A practical playbook to protect gross margin in e-commerce using rule-based pricing, automated invoice checks, and anomaly detection with clear audit trails.