PROTECTED COMMERCE v1.4 UPGRADE

1. Back up the database and /public_html/escrow/.
2. Keep your live config.php; this bundle intentionally excludes it.
3. Upload the app files over v1.3.1.
4. Run sql/migrate_v1_4.sql in phpMyAdmin.
5. Upgrade the bundled PrestaShop module to v1.4.0 without uninstalling first.
6. Test:
   - Test Merchant Connection
   - New protected order
   - Funding
   - Seller shipment
   - Buyer Confirm Delivery
   - Buyer Accept & Release
   - Dispute + evidence upload
   - Webhook reconciliation

V1.4 FIXES / IMPROVEMENTS
- Central transaction-state validation helper.
- Buyer can cancel before seller acceptance/funding.
- Admin can regenerate expired/lost buyer action links.
- Dispute evidence uploads: JPG/PNG/WEBP/PDF/TXT, max 10 MB.
- Evidence SHA-256 recorded for audit integrity.
- Evidence storage is under protected /storage.
- Notification preference page.
- Admin notification queue with manual retry.
- PrestaShop gets distinct FUNDED, SHIPPED and DELIVERED order states.
- Prevents duplicate PrestaShop order-history state changes.
- Customer account has "Protected Commerce Transactions" page.
- Customer can recover the Manage Transaction link from their account.

IMPORTANT
Live custody/payment is still simulation mode unless a licensed provider has been integrated.
