/* 踊るページ：真っ黒な背景に、YouTube と キャラクターだけ */
* { box-sizing: border-box; }
[hidden] { display: none !important; }

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

.page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100dvh;
}

/* 動画：高さの約半分まで。画面が狭ければ横幅いっぱい */
.video {
  position: relative;
  flex: none;
  width: min(100vw, calc(52dvh * 16 / 9));
  aspect-ratio: 16 / 9;
  background: #000;
}
.video > * {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.video.over { outline: 2px dashed #777; outline-offset: -2px; }

/* キャラ：動画の下。跳ねても動画にかからないよう、上に自分の高さの半分ぶん空ける */
.stage {
  --size: min(30dvh, 70vw);
  position: relative;
  flex: none;
  width: var(--size);
  height: calc(var(--size) * 1.5);
}
.dancer {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  transform-origin: 50% 100%;
  will-change: transform;
}
.dancer img {
  display: block;
  width: 100%;
  height: auto;
  user-select: none;
  -webkit-user-drag: none;
}

/* エラーのときだけ左下に小さく出る */
.status {
  position: fixed;
  left: 12px;
  bottom: 8px;
  max-width: calc(100vw - 24px);
  margin: 0;
  color: #ff8a98;
  font: 13px/1.5 system-ui, -apple-system, "Hiragino Sans", "Noto Sans JP", sans-serif;
}
.status:empty { display: none; }
