Customise UNCODE wordpress theme with code

Job ID: 31623773

Budget: $10 – $30 USD

I am using the UNCODE theme on my WordPress website - tristanbarringtonphotography.com
I have two issues I hope can be solved through custom code
1. Create button/external link to URL from inside of lightbox image
2. Limit number of photos displaying on homepage while still maintaining filter menu.
1. I need to create a specific type of photo gallery. Clicking a photo in the gallery must open a lightbox, where the photo can be seen in bigger size. But when the lightbox is open, I need to have a button or link on the photo which leads to an external URL.
If I want to use the lightbox, clicking the image opens the lightbox and the URL link is disabled (screenshot 1). If I want to use the URL link, the lightbox must be disabled (screenshot 2).
I have already added custom links to all gallery images (screenshot 3)
Is there any way to use both at the same time? Image below to explain better what I would like to achieve (screenshot 4).
2. I am using the Portfolio Photos as my homepage. I have about 100 photos in my portfolio. I have assigned categories to each of the photos so that I have four different filter menus – wildlife, landscape, people, macro. I would love to be able to show only 30 photos on my homepage but still have the ability for the rest to be displayed when clicking on the filter menus. I need a way I can limit the number of photos displaying on the homepage to 30 yet still have the ability to show all photos when clicking on the corresponding filter menus? (Screenshot 5)
Related categories: Website Design WordPress CSS HTML Coding