Try this (somewhat untested)

Select H4

Conditional Formatting
New Rule
Use a formula to determine...

=AND(A4 <> "",H4 <> "",H4 < INDEX(IF(A4='Store volume code'!B$2:B$16,'Store volume code'!D$2:E$7,IF(A4='Store volume code'!B$18:B$28,'Store volume code'!D$18,E$23)),MATCH(C4,IF(A4='Store volume code'!B$2:B$16,'Store volume code'!D$2:D$7,IF(A4='Store volume code'!B$18:B$28,'Store volume code'!E$18,E$23))),2))
Format as required

Use Format painter (paintbrush icon) to copy to other cells

For column Q just change the H references above to Q