:root {
  /* 内容按 1920x1080 设计稿取宽高较小比例缩放，各区域保持边缘锚定 */
  --stage-w: 100vw;
  --stage-h: 100vh;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

img {
  display: block;
  vertical-align: middle;
  user-select: none;
  -webkit-user-drag: none;
}

html {
  /* 1920x1080 设计稿中 1rem = 100px，短屏时同步按高度缩小 */
  font-size: min(calc(100vw / 19.2), calc(100vh / 10.8));
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

body {
  position: relative;
  background: #0a0a0a url(../image/desktop/bg.png?_t=6) no-repeat center center;
  background-size: 100% 100%;
}

/* 内容铺满视口宽度并按设计稿比例缩放，背景由 body 独立拉伸铺满 */
.page-stage {
  position: absolute;
  left: 0;
  top: 0;
  width: var(--stage-w);
  height: var(--stage-h);
  overflow: hidden;
}

/* ========== header ========== */
.page-header {
  position: absolute;
  inset: 0 0 auto;
  height: 1.9rem;
  z-index: 20;
}

.page-header .logo {
  position: absolute;
  left: 0.2rem;
  top: 0.4rem;
  width: 3.1rem;
  height: auto;
}

.header-btns {
  position: absolute;
  right: 0.61rem;
  top: 0.29rem;
  display: flex;
  align-items: center;
  gap: 0.43rem;
}

.header-btns img {
  height: 0.86rem;
  width: auto;
  cursor: pointer;
}

.header-btns .tg {
  width: 2.74rem;
}

.header-btns .sw {
  width: 2.7rem;
}

/* ========== main ========== */
.page-main {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

/* 左侧：标题 + 扫码区 */
.content-left {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 9.6rem;
  height: 10.5rem;
  z-index: 10;
}

.main-title {
  position: absolute;
  left: 0.39rem;
  top: 2.45rem;
  width: 9.21rem;
  height: auto;
}

/* 扫码区：背景图 + 二维码 + 右侧按钮组 */
.scan-box {
  position: absolute;
  left: 1.42rem;
  top: 5.55rem;
  width: 5.75rem;
  height: 3.33rem;
}

.scan-box .scan-bg {
  width: 100%;
  height: 100%;
}

/* 白底二维码区 231x231 @ 575x333 */
#qrcode {
  position: absolute;
  left: 0.08rem;
  top: 0.08rem;
  width: 2.15rem;
  height: 2.15rem;
  z-index: 2;
}

#qrcode img,
#qrcode canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
}

.download-btns {
  position: absolute;
  top: 0.08rem;
  right: 0.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  z-index: 2;
}

.download-btns img {
  width: 3.15rem;
  height: 1.06rem;
  cursor: pointer;
}

/* 右侧人像主图 */
.content-right {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 12.19rem;
  aspect-ratio: 1219 / 1051;
  z-index: 5;
  pointer-events: none;
}

.content-right .main-visual {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
