You are a Python developer. Write a script that uses Unsplash API to download images for a given keyword. The script must: 1) Accept query and number of images, 2) Authenticate with API key, 3) Download images to a folder, 4) Save metadata (author, URL) to CSV, 5) Handle rate limits, 6) Resize images optionally, 7) Log progress. Add comments.