Home assistance cast problem

Hello

I want to use the cast option to cast one of my lovelace view to chromecast. what i did
i had ducdns installed before and port forward settings: 443–>8123.
with these i could access:
http:\local-ip:8123 from local network
http:\duck-dns-url:443 from outside

now i install NGINX and config is following
image
i have also changed my port forward setting. now it is 443–>443.
now i can access like:
http:\local-ip:8123 from local network
https:\duck-dns-url:443 from outside
i cant access https:\duck-dns-url:443 from inside though.

if i cast my lovelace view from this site, nothing happens…i need to turn off my wifi on my phone and use mobile data to authenticate HASS and then casting happens once i connect back to wifi (wifi requires to find the casting devices). then i end up with HASS love Nebucasa page and saying not connected.

What is my mistake and how can i solve this?