/* ==========================================================================
   ESYS LIVE · Bimmer Cloud Platform
   1:1 像素级神韵复刻【方案二：全屏超跑 AR-HUD 电影数字展厅】
   核心材质：烟熏柔白内漫反射磨砂玻璃 × 45° 工业圆角折线 × 瑞士高低双刻度标尺
   ========================================================================== */

:root,
[data-theme="dark"] {
  --bg-showroom: #05080f;
  --bg-deep: #070b13;

  /* 方案二灵魂材质：带柔白体积内漫反射的烟熏磨砂玻璃 */
  --smoked-nav-bg:
    radial-gradient(ellipse 290px 100px at 14% 50%, rgba(255, 255, 255, 0.16) 0%, rgba(186, 230, 253, 0.05) 52%, transparent 100%),
    linear-gradient(90deg, rgba(42, 50, 64, 0.56) 0%, rgba(20, 26, 36, 0.64) 50%, rgba(36, 44, 58, 0.56) 100%);
  --smoked-capsule-bg:
    linear-gradient(120deg, rgba(160, 174, 192, 0.28) 0%, rgba(38, 48, 64, 0.56) 46%, rgba(18, 24, 36, 0.7) 100%);
  --smoked-panel-bg:
    radial-gradient(ellipse 380px 180px at 12% 8%, rgba(255, 255, 255, 0.1) 0%, transparent 70%),
    linear-gradient(145deg, rgba(34, 42, 56, 0.52) 0%, rgba(14, 19, 29, 0.72) 100%);
  --smoked-row-bg: rgba(255, 255, 255, 0.04);

  --rim-border: rgba(255, 255, 255, 0.2);
  --rim-border-soft: rgba(255, 255, 255, 0.1);
  --rim-highlight: inset 0 1px 1px rgba(255, 255, 255, 0.28), inset 0 -1px 1px rgba(255, 255, 255, 0.04);

  --text-pure: #f8fafc;
  --text-mist: rgba(203, 213, 225, 0.78);
  --text-mute: rgba(148, 163, 184, 0.56);

  --ice: #8fd3f4;
  --ice-strong: #7cc4f8;
  --emerald: #38e58c;
  --danger: #fb7185;

  /* 方案二沉稳金属哑光三色顶带 */
  --m-left: #1d56b8;
  --m-mid: #09152e;
  --m-right: #9e1528;

  /* 方案二标志性冰川天蓝云雾发光主按钮 */
  --cta-fill: linear-gradient(180deg, #a6dafb 0%, #7ec3f6 100%);
  --cta-border: rgba(224, 242, 254, 0.88);
  --cta-ink: #071320;
  --cta-cloud: 0 0 38px 6px rgba(125, 211, 252, 0.34), 0 10px 28px rgba(56, 189, 248, 0.26);

  --callout-stroke: rgba(143, 211, 244, 0.78);
  --tick-inactive: rgba(148, 163, 184, 0.28);
  --shadow-glass: 0 24px 60px -18px rgba(0, 0, 0, 0.72);
  --edge-fade: radial-gradient(ellipse 72% 68% at 50% 50%, #000 38%, transparent 96%);
  --hero-edge-blend:
    linear-gradient(180deg, rgba(5, 8, 15, 0.55) 0%, transparent 18%, transparent 80%, #05080f 100%),
    linear-gradient(90deg, #05080f 0%, rgba(5, 8, 15, 0.72) 22%, transparent 44%);

  --font-sans: "Inter", "SF Pro Display", "Segoe UI Variable Display", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", "Cascadia Code", ui-monospace, Consolas, monospace;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}

/* 100% 全域纯白「冰川铂金展厅」同构光影 */
[data-theme="light"] {
  --bg-showroom: #f4f7fb;
  --bg-deep: #ffffff;

  --smoked-nav-bg:
    radial-gradient(ellipse 290px 100px at 14% 50%, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.4) 60%, transparent 100%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.84) 0%, rgba(248, 250, 252, 0.8) 50%, rgba(255, 255, 255, 0.86) 100%);
  --smoked-capsule-bg:
    linear-gradient(120deg, rgba(255, 255, 255, 0.94) 0%, rgba(241, 245, 249, 0.84) 100%);
  --smoked-panel-bg:
    radial-gradient(ellipse 380px 180px at 12% 8%, rgba(255, 255, 255, 0.98) 0%, transparent 70%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.9) 0%, rgba(244, 247, 252, 0.88) 100%);
  --smoked-row-bg: rgba(15, 23, 42, 0.035);

  --rim-border: rgba(15, 23, 42, 0.13);
  --rim-border-soft: rgba(15, 23, 42, 0.07);
  --rim-highlight: inset 0 1px 1px rgba(255, 255, 255, 0.95);

  --text-pure: #0b1322;
  --text-mist: #475569;
  --text-mute: #7c8da5;

  --ice: #0284c7;
  --ice-strong: #0369a1;
  --emerald: #10b981;
  --danger: #e11d48;

  --cta-fill: linear-gradient(180deg, #1e293b 0%, #0b1322 100%);
  --cta-border: rgba(15, 23, 42, 0.85);
  --cta-ink: #ffffff;
  --cta-cloud: 0 14px 34px -8px rgba(15, 23, 42, 0.28);

  --callout-stroke: rgba(2, 132, 199, 0.72);
  --tick-inactive: rgba(15, 23, 42, 0.2);
  --shadow-glass: 0 22px 54px -20px rgba(15, 23, 42, 0.12);
  --edge-fade: radial-gradient(ellipse 72% 68% at 50% 50%, #000 44%, transparent 96%);
  --hero-edge-blend:
    linear-gradient(180deg, rgba(244, 247, 251, 0.65) 0%, transparent 18%, transparent 80%, #f4f7fb 100%),
    linear-gradient(90deg, #f4f7fb 0%, rgba(244, 247, 251, 0.8) 24%, transparent 46%);
  color-scheme: light;
}

/* ==========================================================================
   基础重置
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  background: var(--bg-showroom);
  color: var(--text-pure);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-showroom);
  color: var(--text-pure);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
img, svg { display: block; max-width: 100%; }

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.img-light { display: none; }
[data-theme="light"] .img-dark { display: none; }
[data-theme="light"] .img-light { display: block; }

.container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 clamp(22px, 4vw, 52px);
  position: relative;
  z-index: 2;
}

/* 顶部沉稳哑光 M 三色带（1:1 复刻方案二原图） */
.m-top-beam {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  z-index: 140;
  background: linear-gradient(
    90deg,
    var(--m-left) 0% 33.33%,
    var(--m-mid) 33.33% 66.66%,
    var(--m-right) 66.66% 100%
  );
}

/* ==========================================================================
   顶部烟熏柔白内漫反射胶囊菜单栏（像素级对齐方案二）
   ========================================================================== */
.site-header {
  position: fixed;
  top: 26px;
  left: 0;
  right: 0;
  z-index: 130;
  padding: 0 clamp(18px, 4vw, 52px);
}

.nav-bar {
  max-width: 1280px;
  margin: 0 auto;
  height: 68px;
  padding: 0 26px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: var(--smoked-nav-bg);
  border: 1px solid var(--rim-border);
  box-shadow: var(--rim-highlight), var(--shadow-glass);
  backdrop-filter: blur(28px) saturate(145%);
  -webkit-backdrop-filter: blur(28px) saturate(145%);
  transition: background 0.35s ease, border-color 0.35s ease;
}

.brand-logo {
  height: 32px;
  width: auto;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(20px, 3vw, 42px);
}

/* 原图精髓：纯粹宽字距无底框导航字 */
.nav-link {
  position: relative;
  padding: 6px 2px;
  font-size: 0.84rem;
  font-weight: 450;
  letter-spacing: 0.14em;
  color: var(--text-mist);
  white-space: nowrap;
  transition: color 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-pure);
}

.nav-link.active::after {
  content: "";
  position: absolute;
  left: 20%;
  right: 20%;
  bottom: -2px;
  height: 1.5px;
  border-radius: 2px;
  background: var(--ice);
  box-shadow: 0 0 8px var(--ice);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* 原图右上角双圈银白边缘发光胶囊按钮 */
.connect-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 24px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--text-pure);
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.16), rgba(15, 23, 42, 0.35));
  border: 1.2px solid rgba(255, 255, 255, 0.48);
  box-shadow: 0 0 18px rgba(143, 211, 244, 0.26), inset 0 0 12px rgba(255, 255, 255, 0.14);
  white-space: nowrap;
  transition: all 0.25s var(--ease);
}

[data-theme="light"] .connect-btn {
  background: linear-gradient(180deg, #ffffff 0%, #eef4fa 100%);
  border-color: rgba(2, 132, 199, 0.42);
  box-shadow: 0 6px 20px -6px rgba(2, 132, 199, 0.25), inset 0 1px 0 #ffffff;
}

.connect-btn:hover {
  border-color: var(--ice);
  box-shadow: 0 0 26px rgba(143, 211, 244, 0.45), inset 0 0 14px rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.menu-btn {
  display: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--rim-border);
  background: var(--smoked-capsule-bg);
  align-items: center;
  justify-content: center;
}

/* ==========================================================================
   第一屏 · 1:1 像素级复刻方案二全出血超跑 AR-HUD 展厅舞台
   ========================================================================== */
.hero-showroom {
  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

/* 锁定 16:9 同坐标视觉画布，确保 45° 折线锚点 1px 不差焊死在车身精确部位 */
.hero-canvas-stage {
  position: relative;
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 118px clamp(22px, 5vw, 84px) 34px;
}

.hero-art-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  transform: translate3d(var(--px, 0px), var(--py, 0px), 0);
  transition: transform 0.3s ease-out;
}

.hero-art-layer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.hero-art-layer::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--hero-edge-blend);
}

/* 左侧纯粹克制排版（对齐原图 INTELLIGENT CORE 比例与气质） */
.hero-left-block {
  position: relative;
  z-index: 3;
  max-width: 470px;
  margin-top: auto;
  margin-bottom: auto;
  padding-top: 28px;
}

.hero-main-title {
  font-size: clamp(2.65rem, 4.4vw, 4.25rem);
  font-weight: 450;
  line-height: 1.12;
  letter-spacing: 0.03em;
  color: var(--text-pure);
  margin-bottom: 20px;
}

.hero-main-title span {
  display: block;
}

.hero-desc-lines {
  font-size: clamp(0.96rem, 1.15vw, 1.08rem);
  font-weight: 400;
  color: var(--text-mist);
  line-height: 1.66;
  max-width: 390px;
  margin-bottom: 34px;
}

.btn-launch-glow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 36px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--cta-ink);
  background: var(--cta-fill);
  border: 1.5px solid var(--cta-border);
  box-shadow: var(--cta-cloud);
  transition: transform 0.28s var(--ease), box-shadow 0.28s ease;
}

.btn-launch-glow:hover {
  transform: translateY(-2px) scale(1.015);
}

/* 全屏同坐标系 AR-HUD 45° 工业折线 + 纯粹烟熏磨砂胶囊（零杂字！） */
.ar-overlay-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  transform: translate3d(calc(var(--px, 0px) * 0.45), calc(var(--py, 0px) * 0.45), 0);
  transition: transform 0.3s ease-out;
}

.ar-callout-svg {
  width: 100%;
  height: 100%;
}

.callout-line {
  fill: none;
  stroke: var(--callout-stroke);
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.callout-ring {
  fill: rgba(143, 211, 244, 0.14);
  stroke: var(--ice);
  stroke-width: 1.5;
}

.callout-dot {
  fill: #e0f2fe;
}

[data-theme="light"] .callout-dot {
  fill: #0284c7;
}

/* 纯粹烟熏磨砂玻璃胶囊（只放核心值 + 翠绿发光圆点，100% 复刻原图！） */
.hud-pill {
  position: absolute;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 146px;
  height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  background: var(--smoked-capsule-bg);
  border: 1px solid var(--rim-border);
  box-shadow: var(--rim-highlight), 0 16px 36px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  transform: translate(-50%, -50%);
  white-space: nowrap;
  transition: transform 0.28s var(--ease), border-color 0.25s ease;
}

[data-theme="light"] .hud-pill {
  box-shadow: var(--rim-highlight), 0 14px 32px rgba(15, 23, 42, 0.12);
}

.hud-pill:hover {
  transform: translate(-50%, calc(-50% - 3px));
  border-color: var(--ice);
}

.hud-pill-text {
  font-size: 1.02rem;
  font-weight: 450;
  letter-spacing: 0.04em;
  color: var(--text-pure);
}

.hud-green-dot {
  width: 8.5px;
  height: 8.5px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 10px 2px var(--emerald);
  flex-shrink: 0;
}

/* 精确锁定在方案二原图 16:9 比例的三个黄金坐标 */
.hud-pill-1 { left: 47.6%; top: 34.6%; }
.hud-pill-2 { left: 68.4%; top: 27.6%; }
.hud-pill-3 { left: 83.6%; top: 75.2%; }

/* ==========================================================================
   首屏底部：1:1 复刻方案二高低双节奏精密刻度尺（零多余杂字！）
   ========================================================================== */
.hero-timeline-bar {
  position: relative;
  z-index: 4;
  width: 100%;
  padding-top: 18px;
}

.precision-scale {
  position: relative;
  width: 100%;
  height: 58px;
}

.scale-svg {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  width: 100%;
  height: 26px;
  overflow: visible;
  pointer-events: none;
}

.scale-nodes-row {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.scale-node-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 11px;
  padding: 0;
  background: none;
}

.scale-node-btn:first-child { align-items: flex-start; }
.scale-node-btn:last-child { align-items: flex-end; }

.scale-num {
  font-size: 0.88rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--text-mute);
  transition: color 0.3s ease;
}

.scale-ring {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--bg-showroom);
  border: 1.5px solid var(--tick-inactive);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.35s var(--ease);
}

.scale-ring i {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--tick-inactive);
  transition: all 0.35s ease;
}

.scale-node-btn.lit .scale-num {
  color: var(--ice);
}

.scale-node-btn.lit .scale-ring {
  border-color: var(--ice);
  box-shadow: 0 0 18px rgba(143, 211, 244, 0.58);
}

.scale-node-btn.lit .scale-ring i {
  background: #e0f2fe;
  box-shadow: 0 0 8px #ffffff;
}

[data-theme="light"] .scale-node-btn.lit .scale-ring i {
  background: var(--ice);
}

/* ==========================================================================
   后续三幕：延续同款「暗棚镜面展厅 + 烟熏内发光玻璃 + 极简高奢」世界观
   ========================================================================== */
.chapter {
  position: relative;
  padding: clamp(92px, 10vw, 142px) 0;
  scroll-margin-top: 96px;
}

.chapter-divider {
  width: 100%;
  max-width: 1280px;
  height: 1px;
  margin: 0 auto;
  background: linear-gradient(90deg, transparent, var(--rim-border), transparent);
}

.chapter-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: clamp(46px, 5vw, 68px);
}

.chapter-kicker {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ice);
  margin-bottom: 12px;
}

.chapter-title {
  font-size: clamp(2rem, 3.2vw, 2.85rem);
  font-weight: 450;
  letter-spacing: 0.02em;
  line-height: 1.16;
  color: var(--text-pure);
}

.chapter-lead {
  max-width: 400px;
  font-size: 0.94rem;
  color: var(--text-mist);
  line-height: 1.7;
}

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 统一烟熏漫反射磨砂玻璃容器 */
.smoked-glass {
  background: var(--smoked-panel-bg);
  border: 1px solid var(--rim-border);
  box-shadow: var(--rim-highlight), var(--shadow-glass);
  backdrop-filter: blur(26px) saturate(140%);
  -webkit-backdrop-filter: blur(26px) saturate(140%);
  border-radius: 28px;
}

/* 第二幕：无框半透明烟熏水晶透视展厅 + 4 座烟熏微视觉展柜 */
.optical-showcase {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 28px;
  align-items: center;
  margin-bottom: 44px;
}

.crystal-car-stage {
  position: relative;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
}

.crystal-car-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  mask-image: var(--edge-fade);
  -webkit-mask-image: var(--edge-fade);
}

.node-capsule {
  position: absolute;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 38px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--smoked-capsule-bg);
  border: 1px solid var(--rim-border);
  box-shadow: var(--rim-highlight), 0 10px 24px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(18px);
  font-size: 0.78rem;
  color: var(--text-pure);
  white-space: nowrap;
  transition: all 0.25s var(--ease);
}

.node-capsule:hover,
.node-capsule.active {
  border-color: var(--ice);
  transform: translate(-50%, calc(-50% - 2px)) scale(1.05);
}

.nc-1 { left: 73%; top: 47%; }
.nc-2 { left: 25%; top: 23%; }
.nc-3 { left: 33%; top: 77%; }
.nc-4 { left: 54%; top: 23%; }

.era-detail-glass {
  padding: 32px;
}

.era-badge {
  display: inline-block;
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  color: var(--ice);
  margin-bottom: 10px;
}

.era-heading {
  font-size: 1.32rem;
  font-weight: 500;
  margin-bottom: 6px;
}

.era-models {
  font-size: 0.85rem;
  color: var(--text-mist);
  margin-bottom: 22px;
}

.era-spec-rows {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.era-spec-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 11px 15px;
  border-radius: 999px;
  background: var(--smoked-row-bg);
  border: 1px solid var(--rim-border-soft);
  font-size: 0.81rem;
}

.era-spec-row span {
  color: var(--text-mist);
  white-space: nowrap;
}

.era-spec-row strong {
  font-weight: 500;
  color: var(--text-pure);
  white-space: nowrap;
}

/* 4 座烟熏微视觉玻璃展柜 */
.vitrine-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.vitrine-card {
  padding: 26px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
  transition: transform 0.32s var(--ease), border-color 0.28s ease;
}

.vitrine-card:hover {
  transform: translateY(-4px);
  border-color: var(--ice);
}

.vitrine-stage {
  height: 118px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.fan-cards {
  position: relative;
  width: 136px;
  height: 84px;
}

.fan-piece {
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 64px;
  height: 72px;
  margin-left: -32px;
  border-radius: 12px;
  background: var(--smoked-capsule-bg);
  border: 1px solid var(--rim-border);
  box-shadow: var(--rim-highlight);
  transform-origin: bottom center;
  display: flex;
  justify-content: center;
  padding-top: 9px;
  font-size: 0.66rem;
  color: var(--text-pure);
  transition: transform 0.45s var(--ease);
}

.fan-piece:nth-child(1) { transform: rotate(-26deg) translateX(-15px); opacity: 0.5; }
.fan-piece:nth-child(2) { transform: rotate(-13deg) translateX(-7px); opacity: 0.7; }
.fan-piece:nth-child(3) { transform: rotate(0deg); opacity: 0.88; }
.fan-piece:nth-child(4) { transform: rotate(13deg) translateX(7px); opacity: 0.94; }
.fan-piece:nth-child(5) { transform: rotate(26deg) translateX(15px); border-color: var(--ice); color: var(--ice); }

.vitrine-card:hover .fan-piece:nth-child(1) { transform: rotate(-36deg) translateX(-20px); }
.vitrine-card:hover .fan-piece:nth-child(5) { transform: rotate(36deg) translateX(20px); }

.dial-spin {
  transform-origin: 50px 50px;
  animation: rotateCW 10s linear infinite;
}

@keyframes rotateCW { to { transform: rotate(360deg); } }
@keyframes rotateCCW { to { transform: rotate(-360deg); } }

.flow-beam {
  stroke-dasharray: 18 88;
  animation: beamRun 1.9s linear infinite;
}

@keyframes beamRun { to { stroke-dashoffset: -106; } }

.rotator-pill {
  display: inline-block;
  padding: 3px 11px;
  border-radius: 999px;
  font-size: 0.68rem;
  color: var(--ice);
  border: 1px solid var(--rim-border);
  margin-bottom: 8px;
}

.rotator-line {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-pure);
  text-align: center;
  transition: opacity 0.25s ease;
}

.vitrine-copy h3 {
  font-size: 1.06rem;
  font-weight: 500;
  margin-bottom: 5px;
}

.vitrine-copy p {
  font-size: 0.82rem;
  color: var(--text-mist);
  line-height: 1.6;
}

/* 第三幕：全息光学护盾展台 */
.fence-showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.chip-holo-stage {
  position: relative;
  aspect-ratio: 1 / 0.86;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chip-holo-stage img {
  width: 86%;
  height: 86%;
  object-fit: cover;
  mask-image: var(--edge-fade);
  -webkit-mask-image: var(--edge-fade);
}

.holo-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.holo-cw { transform-origin: 200px 200px; animation: rotateCW 24s linear infinite; }
.holo-ccw { transform-origin: 200px 200px; animation: rotateCCW 17s linear infinite; }

.holo-stroke {
  stroke: var(--ice);
  transition: stroke 0.3s ease;
}

.chip-holo-stage.locked .holo-stroke {
  stroke: var(--danger);
}

.chip-callout-pill {
  position: absolute;
  bottom: 7%;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 11px;
  height: 44px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--smoked-capsule-bg);
  border: 1px solid var(--rim-border);
  box-shadow: var(--rim-highlight), var(--shadow-glass);
  backdrop-filter: blur(22px);
  font-size: 0.82rem;
  color: var(--text-pure);
  white-space: nowrap;
}

.chip-holo-stage.locked .chip-callout-pill {
  border-color: var(--danger);
  color: var(--danger);
}

.chip-holo-stage.locked .hud-green-dot {
  background: var(--danger);
  box-shadow: 0 0 10px 2px var(--danger);
}

.fence-glass-panel {
  padding: 32px;
  margin-top: 24px;
}

.sid-capsule-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 24px;
}

.sid-btn {
  padding: 12px 14px;
  border-radius: 18px;
  background: var(--smoked-row-bg);
  border: 1px solid var(--rim-border-soft);
  text-align: left;
  transition: all 0.22s ease;
}

.sid-btn:hover,
.sid-btn.active {
  border-color: var(--ice);
  background: var(--smoked-capsule-bg);
}

.sid-btn.danger.active {
  border-color: var(--danger);
}

.sid-btn small {
  display: block;
  font-size: 0.7rem;
  color: var(--ice);
  margin-bottom: 3px;
}

.sid-btn.danger small { color: var(--danger); }

.sid-btn strong {
  font-size: 0.83rem;
  font-weight: 500;
}

.volt-row-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.83rem;
  color: var(--text-mist);
}

.volt-readout {
  font-size: 1.32rem;
  font-weight: 500;
  color: var(--emerald);
}

.volt-readout.low { color: var(--danger); }

.volt-slider {
  width: 100%;
  height: 4px;
  accent-color: var(--ice);
  cursor: pointer;
  margin-bottom: 12px;
}

.fence-status-line {
  font-size: 0.83rem;
  color: var(--text-mist);
}

.fence-status-line.low { color: var(--danger); }

/* 第四幕：烟熏玻璃云端智控舱 & 精密刻度数字收官 */
.studio-glass-shell {
  overflow: hidden;
}

.studio-head-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding: 18px 28px;
  border-bottom: 1px solid var(--rim-border-soft);
}

.studio-left-pills {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.mini-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--smoked-capsule-bg);
  border: 1px solid var(--rim-border);
  font-size: 0.78rem;
}

.core-bars-wrap {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--text-mist);
}

.core-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 18px;
}

.core-bar {
  width: 3px;
  border-radius: 2px;
  background: var(--ice);
  transition: height 0.5s var(--ease);
}

.studio-split {
  display: grid;
  grid-template-columns: 1fr 1.08fr;
}

.studio-toggles {
  padding: 26px 28px;
  border-right: 1px solid var(--rim-border-soft);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toggle-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 18px;
  background: var(--smoked-row-bg);
  border: 1px solid var(--rim-border-soft);
  text-align: left;
  transition: border-color 0.22s ease;
}

.toggle-item.on {
  border-color: rgba(143, 211, 244, 0.42);
}

.toggle-item strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 500;
  margin-bottom: 2px;
}

.toggle-item span {
  font-size: 0.75rem;
  color: var(--text-mist);
}

.switch-track {
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.28);
  padding: 3px;
  flex-shrink: 0;
  transition: background-color 0.25s ease;
}

.toggle-item.on .switch-track {
  background: var(--ice-strong);
}

.switch-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  transition: transform 0.25s var(--ease);
}

.toggle-item.on .switch-thumb {
  transform: translateX(18px);
}

.studio-langs-pane {
  padding: 26px 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
}

.lang-pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.lang-pill-btn {
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.76rem;
  color: var(--text-mist);
  border: 1px solid var(--rim-border-soft);
  background: var(--smoked-row-bg);
}

.lang-pill-btn.active {
  color: var(--cta-ink);
  background: var(--cta-fill);
  border-color: transparent;
}

.decoded-rows {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.decoded-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 16px;
  border-radius: 16px;
  background: var(--smoked-row-bg);
  border: 1px solid var(--rim-border-soft);
}

.decoded-row code {
  display: block;
  font-size: 0.74rem;
  color: var(--ice);
  margin-bottom: 3px;
}

.decoded-row span {
  font-size: 0.85rem;
  color: var(--text-pure);
}

.decoded-badge {
  font-size: 0.72rem;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--smoked-capsule-bg);
  border: 1px solid var(--rim-border-soft);
  color: var(--emerald);
  white-space: nowrap;
}

/* 底部高低刻度数字雕塑收官 */
.closing-metrics {
  margin-top: clamp(64px, 7vw, 96px);
  padding-top: 38px;
  border-top: 1px solid var(--rim-border-soft);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.closing-metric strong {
  display: block;
  font-size: clamp(2rem, 3.1vw, 2.75rem);
  font-weight: 350;
  letter-spacing: 0.01em;
  color: var(--text-pure);
  margin-bottom: 6px;
}

.closing-metric strong em {
  font-style: normal;
  font-size: 0.96rem;
  color: var(--ice);
  margin-left: 5px;
}

.closing-metric span {
  font-size: 0.82rem;
  color: var(--text-mist);
}

.site-footer {
  padding: 36px 0 42px;
  border-top: 1px solid var(--rim-border-soft);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.8rem;
  color: var(--text-mute);
}

/* ==========================================================================
   响应式适配（平板 & 390px 手机端零溢出）
   ========================================================================== */
@media (max-width: 1060px) {
  .ar-callout-svg { display: none; }
  .ar-overlay-layer {
    position: relative;
    inset: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 24px 0 18px;
    transform: none !important;
  }
  .hud-pill {
    position: static;
    transform: none !important;
  }
  .optical-showcase { grid-template-columns: 1fr; }
  .vitrine-grid { grid-template-columns: repeat(2, 1fr); }
  .fence-showcase { grid-template-columns: 1fr; }
  .studio-split { grid-template-columns: 1fr; }
  .studio-toggles { border-right: none; border-bottom: 1px solid var(--rim-border-soft); }
  .closing-metrics { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  .nav-links {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    left: 18px;
    right: 18px;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    border-radius: 24px;
    background: var(--smoked-panel-bg);
    border: 1px solid var(--rim-border);
    backdrop-filter: blur(28px);
    box-shadow: var(--shadow-glass);
  }
  .nav-links.open { display: flex; }
  .menu-btn { display: inline-flex; }
  .brand-logo { height: 28px; }
  .vitrine-grid { grid-template-columns: 1fr; }
  .sid-capsule-row { grid-template-columns: 1fr; }
  .node-capsule { height: 32px; padding: 0 11px; font-size: 0.7rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
