/* 演示 iframe 全屏组件样式 */
.demo-embed {
  position: relative;
}

.demo-embed iframe {
  display: block;
  max-width: 100%;
}

/* 右上角全屏按钮 */
.demo-fs-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 9;
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-size: 13px;
  line-height: 1;
  padding: 7px 13px;
  border-radius: 999px;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background 0.2s;
}

.demo-fs-btn:hover {
  background: rgba(0, 0, 0, 0.6);
}

/* 原生全屏状态：iframe 撑满视口 */
.demo-embed:fullscreen {
  width: 100vw;
  height: 100vh;
  background: #000;
}

.demo-embed:fullscreen iframe {
  width: 100%;
  height: 100%;
}

.demo-embed:-webkit-full-screen {
  width: 100vw;
  height: 100vh;
  background: #000;
}

.demo-embed:-webkit-full-screen iframe {
  width: 100%;
  height: 100%;
}

/* 伪全屏降级（iOS Safari 等） */
.demo-embed.demo-fs-pseudo {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: #000;
}

.demo-embed.demo-fs-pseudo iframe {
  width: 100%;
  height: 100%;
}

body.demo-fs-lock {
  overflow: hidden;
}
