The simple flattener you can use without installing any massive environments.
go install github.com/lexansoft/dirty-solidity-flattener@latest
it will install it into your $GOPATH/bin folder. Make sure you add it to your $PATH
dirty-solidity-flattener -o OUTPUT_FILE YOUR_CONTRACT_FILE
If the output file is not specified, the program will direct the output into "YOUR_CONTRACT_flat.sol"