*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  background: #000;
  color: #fff;
  overflow: hidden;
}

body {
  min-height: 100dvh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial,
    sans-serif;
}

h1 {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.stage {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100dvh;
  height: 100svh;
  padding: env(safe-area-inset-top) env(safe-area-inset-right)
    env(safe-area-inset-bottom) env(safe-area-inset-left);
}

.player {
  position: relative;
  overflow: hidden;
  width: min(100%, round(nearest, calc(100dvh * 9 / 16), 1px));
  height: min(100dvh, round(nearest, calc(100vw * 16 / 9), 1px));
  max-height: 100%;
  background: #000;
}

.player iframe {
  position: absolute;
  display: block;
  top: 50%;
  left: 50%;
  width: calc(100% + 4px);
  height: calc(100% + 4px);
  transform: translate(-50%, -50%);
  border: 0;
  background: #000;
}
