/* ===========================
   全局基础
=========================== */
:root {
  --page-padding-x: 15px;
  --page-padding-y: 0px;
  --left-margin: 3px;     /* 新增，控制左手机位置 */

  /* 3 个分页点的垂直位置（可以手动调整） */
  --card-dots-offset: 15px;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
}

/* ===========================
   背景与 HUD 效果（保留你的原版）
=========================== */
body {




  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 18px;







  padding: var(--page-padding-y) var(--page-padding-x);
  min-height: 100vh;
  background: radial-gradient(circle at 50% 60%, #11131a 0%, #0a0c10 60%, #050509 100%);
  color: #fff;
  font-family: 'Inter', 'Segoe UI', sans-serif;

  position: relative;
  overflow: hidden;
}

body::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 80%, rgba(255, 50, 100, 0.25) 0%, transparent 70%),
    radial-gradient(circle at 80% 20%, rgba(50, 150, 255, 0.25) 0%, transparent 70%);
  filter: blur(120px);
  z-index: -2;
}

body::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      to right,
      rgba(255, 255, 255, 0.015) 0,
      rgba(255, 255, 255, 0.015) 1px,
      transparent 1px,
      transparent 80px
    ),
    repeating-linear-gradient(
      to bottom,
      rgba(255, 255, 255, 0.015) 0,
      rgba(255, 255, 255, 0.015) 1px,
      transparent 1px,
      transparent 80px
    ),
    url("https://www.transparenttextures.com/patterns/noise-pattern-with-subtle-cross-lines.png");
  opacity: 0.2;
  mix-blend-mode: overlay;
  z-index: -1;
  pointer-events: none;
}

/* ===========================
   手机框结构（左右都用此结构）
=========================== */
.phone-frame {
  height: calc(95vh - 2 * var(--page-padding-y));
  box-sizing: border-box;
  border: 1px solid #464646;
  border-radius: 14px;
  position: relative;
  overflow: visible; /* 让圆角裁剪内容 */
  z-index: 1;
}

/* 黑色屏幕 */
.phone-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #000;
  border-radius: inherit;
  z-index: 2;
}

/* 外部光效 */
.phone-frame::after {
  content: "";
  position: absolute;
  inset: 0px;
  border-radius: inherit;
  pointer-events: none;
  mix-blend-mode: normal;
  z-index: 0;

  box-shadow:
    0 0 3px rgba(251, 198, 83, 0.55),
    0 0 4px rgba(255, 255, 255, 0.35),
    0 0 6px rgba(255, 255, 255, 0.20);
}

/* 左侧手机呼吸光（Ice White / Device Status Glow） */
.fixed-left::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  z-index: 0;

  box-shadow:
    0 0 8px  rgba(220, 235, 255, 0.50),
    0 0 14px rgba(220, 235, 255, 0.32),
    0 0 22px rgba(220, 235, 255, 0.18);

  animation: deviceBreathGlow 6s ease-in-out infinite;
}

/* 呼吸动画 —— 冰白一致 */
@keyframes deviceBreathGlow {
  0% {
    box-shadow:
      0 0 8px  rgba(220, 235, 255, 0.40),
      0 0 14px rgba(220, 235, 255, 0.26),
      0 0 22px rgba(220, 235, 255, 0.15);
  }

  50% {
    box-shadow:
      0 0 12px rgba(220, 235, 255, 0.60),
      0 0 18px rgba(220, 235, 255, 0.40),
      0 0 26px rgba(220, 235, 255, 0.28);
  }

  100% {
    box-shadow:
      0 0 8px  rgba(220, 235, 255, 0.40),
      0 0 14px rgba(220, 235, 255, 0.26),
      0 0 22px rgba(220, 235, 255, 0.15);
  }
}






/* 左侧屏幕比例锁定 */
.fixed-left {
  aspect-ratio: 9 / 18.67;
  flex: 0 0 auto;
  margin-left: var(--left-margin);   /* ← ← 你真正想要的效果在这里 */
}


/* 右侧手机框 */
.flex-right {
  flex: 1;
  width: auto;
  position: relative;
}



/* 🔑 关键：明确左右手机层级 */
.phone-frame.fixed-left {
  z-index: 5;
}

.phone-frame.flex-right {
  z-index: 1;
}













/* ======================================================
   🔥 关键升级点：右侧卡片区域 = 完全贴合黑背景本体
   让卡片与黑背景等比例缩放（解决你截图里的问题）
====================================================== */
.flex-right .right-content {
  position: absolute;
  inset: 0;           /* 完全贴合黑色背景区域 */
  z-index: 3;         /* 高于黑屏 */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;

  padding: 0;        /* 使用百分比，可以等比例缩放 */
  box-sizing: border-box;
}

/* ===========================
   卡片视口（等比例缩放）
=========================== */
.cards-viewport {
  width: 80%;         /* 相对于黑背景 */
  height: 80%;        /* 相对于黑背景 */
  min-width: 0;
  min-height: 0;

  overflow: hidden;
  position: relative;
  border-radius: 14px;
}

/* 轨道 */
.cards-track {
  height: 100%;
  width: 300%;
  display: flex;
  transition: transform 0.45s cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ===========================
   单张卡片（完全用 % 缩放）
=========================== */
.info-card {
  flex: 0 0 100%;
  height: 100%;

  padding: 4% 5%;     /* 全部用百分比，跟随黑背景缩放 */
  box-sizing: border-box;

  border-radius: 14px;

  background: linear-gradient(
    135deg,
    rgba(32, 32, 42, 0.98),
    rgba(8, 8, 14, 0.96)
  );
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06),
    0 18px 40px rgba(0, 0, 0, 0.65);

  display: flex;
  flex-direction: column;
}

.card-header h2 {
  margin: 0;
  font-size: 2.4vw;        /* 使用 vw 自动缩放，完全同步黑框缩放 */
  max-font-size: 26px;
}

.card-body {
  font-size: 1.55vw;
  line-height: 1.45;
  opacity: 0.9;
}

.card-body ul {
  margin-top: 2%;
  padding-left: 6%;
}

/* ===========================
   3 个分页点
=========================== */
.card-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;

  margin-top: var(--card-dots-offset);
}

.card-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  border: none;
  cursor: pointer;
  transition: transform 0.25s, background-color 0.25s;
}

.card-dot.active {
  background: white;
  transform: none;
}

/* 让左侧 HUD 空间具有固定高度 */
#left-hud {
  height: calc(100vh - var(--offset-top) - var(--offset-bottom));
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* 让 record-box 占满左侧手机内部 */
/* inner-screen 负责裁剪，保持满框 */
.inner-screen {
    position: absolute;
    inset: 0;
    background: #000;
    border-radius: 0px;     /* ★ 你手机屏幕圆角大小 */
    overflow: hidden;        /* ★ 负责真正裁剪截图 */
    z-index: 3;
}

/* record-box 依然是截图容器 */
#record-box {
    position: absolute;
    inset: 3px;
    border-radius: inherit;
    border-radius: 20px;   /* ★ 加大截图区域圆角 */
    overflow: hidden;
    z-index: 5;
}





/* 背后光效层 —— 位于黑屏上、截图下 */


.screen-container {
    position: absolute;
    inset: 0;
    z-index: 3;    /* 在 glow 上层，在 screenshot 下层 */
    border-radius: 24px;
    overflow: hidden;
}


/* ✅ 左侧圆形开合按钮（压在右边框上） */
/* 左侧圆形开合按钮（img 版） */
.left-toggle-btn {
  position: absolute;
  top: 45%;
  right: -35px;
  transform: translateY(-50%);

  width: clamp(60px, 5vw, 60px);
  height: clamp(60px, 5vw, 60px);
  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  background: rgba(30, 30, 38, 0.85); /* 底色，避免透明图边缘发虚 */
  border: 0.5px solid rgba(255, 255, 255, 0.25);

  padding: 0;          /* 防止 button 默认 padding */
  cursor: pointer;
  z-index: 30;

  box-shadow: 0 0 3px rgba(220, 235, 255, 0.35);
}

/* 图片本体 */
.left-toggle-btn .toggle-icon {
  width: 100%;          /* 关键：这类图片要大 */
  height: 100%;
  border-radius: 50%;  /* 防止 JPG 边角 */
  object-fit: cover;

  pointer-events: none; /* 不挡点击 */
  user-select: none;
}

/* 按下反馈 */
.left-toggle-btn:active {
  transform: translateY(-50%) scale(0.96);
}





/* 针对特斯拉圆形隐藏按钮的大小调节 */
@media (min-aspect-ratio: 16/6) {
  .left-toggle-btn {
    width: clamp(40px, 8vw, 110px);
    height: clamp(40px, 8vw, 110px);
  }
}



