SELECT 
  a.item_id, 
  b.reason 
FROM 
  access_restriction as a 
  LEFT JOIN access_restriction_reason_descriptions as b ON a.item_id = b.item_id 
  AND a.type = b.type 
  AND lang_code = 'en' 
WHERE 
  (
    ip_from <= 'd849d821' 
    AND ip_to >= 'd849d821' 
    OR ip_from <= 'ac1f57d2' 
    AND ip_to >= 'ac1f57d2'
  ) 
  AND a.type IN ('ips', 'ipr', 'ipb') 
  AND status = 'A'

Query time 0.00067

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "4.56"
    },
    "nested_loop": [
      {
        "table": {
          "table_name": "a",
          "access_type": "ALL",
          "possible_keys": [
            "type"
          ],
          "rows_examined_per_scan": 36,
          "rows_produced_per_join": 1,
          "filtered": "2.78",
          "cost_info": {
            "read_cost": "4.11",
            "eval_cost": "0.10",
            "prefix_cost": "4.21",
            "data_read_per_join": "312"
          },
          "used_columns": [
            "item_id",
            "ip_from",
            "ip_to",
            "type",
            "status"
          ],
          "attached_condition": "((((`goimagine`.`a`.`ip_from` <= 'd849d821') and (`goimagine`.`a`.`ip_to` >= 'd849d821')) or ((`goimagine`.`a`.`ip_from` <= 'ac1f57d2') and (`goimagine`.`a`.`ip_to` >= 'ac1f57d2'))) and (`goimagine`.`a`.`type` in ('ips','ipr','ipb')) and (`goimagine`.`a`.`status` = 'A'))"
        }
      },
      {
        "table": {
          "table_name": "b",
          "access_type": "eq_ref",
          "possible_keys": [
            "PRIMARY"
          ],
          "key": "PRIMARY",
          "used_key_parts": [
            "item_id",
            "type",
            "lang_code"
          ],
          "key_length": "18",
          "ref": [
            "goimagine.a.item_id",
            "goimagine.a.type",
            "const"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 1,
          "filtered": "100.00",
          "cost_info": {
            "read_cost": "0.25",
            "eval_cost": "0.10",
            "prefix_cost": "4.56",
            "data_read_per_join": "32"
          },
          "used_columns": [
            "item_id",
            "type",
            "reason",
            "lang_code"
          ]
        }
      }
    ]
  }
}