How to calculate mixed rates for special items in shipping?

I have a shipping scenario that Shopify doesn’t seem to be able to fill. While I’m investigating app that say they can compute any rate, I’m struggling with this and would love any additional help, tips, direction, etc.

here’s the setup.

My basic shipping rate is based on the value of the cart.

However, there are 3 items that require special handling and rates.

What I want to happen is that if one of those special items is in the cart by itself, it shows the special shipping rate.

if a special item is in a cart with other regular items, then the shipping is a combination of the special shipping rate, and the value of the cart WITHOUT the value of the special item.

Item A is a regular item valued at $20. so it generates a shipping rate of $5

Item B is a special item valued at $50, which needs a $10 shipping rate.

if they are in the cart together, the $50 value of the special item is added to the $20 of item A, kicking the entire order into a higher shipping rate and adds the $10, so in effect the customer is getting charged double shipping since they are charged shipping on the item and on the value of the item.

Thoughts? Comments? Ideas?

Thanks!

According to shopify survey, more than half of consumers feel uncomfortable with in-store shopping and have shifted to ecommerce as a result of the pandemic. And this shift is creating long-term behavioral changes.