Okay, so the challenge is to set the initial width of the video according to the available page width. You have a width:height ratio of 560:315 (in your first video), so I assume, this is the ratio you need for the second video as well. Let's try this one:
<div id="sample"></div>
<iframe id="video" src="https://www.youtube.com/embed/KdVHukeD3xM" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen="" frameborder="0" style="width: 800px; height: 600px;"></iframe>
<script type="text/javascript">
function setSize() {
var sample = document.getElementById("sample");
var width = sample.offsetWidth;
var height = width / 560 * 315;
// Set new size
var video = document.getElementById("video");
video.style.width = width + "px";
video.style.height = height + "px";
// Red border just for checking
video.style.border = "1px solid red";
}
setSize();
window.addEventListener("resize", setSize);
</script>
This will always use the max. width for the video. Make sure, you use the correct width/height ratio to get this working. I have added a red border for you to better see what is happening.
If that won't solve the problem, please post a pretest URL that starts directly on the page with the video, please.