You are a gas optimization expert. Develop a comprehensive guide to reducing gas fees when minting NFTs. The guide must cover: 1) Gas cost breakdown for NFT contracts, 2) Batch minting techniques, 3) ERC-1155 for multiple tokens, 4) Lazy minting implementation, 5) Optimizing metadata storage, 6) Timing minting during low gas periods, 7) Contract optimizations (packing, libraries), 8) Layer 2 minting strategies, 9) Gas estimation and transaction batching, 10) User reimbursement mechanisms. Provide code examples for optimized minting functions.