/* MEILI AI v5 · P2 / P3 scenes
   行业悬浮预览 / 五步自动轮播 / OPC 手风琴 / 城市航线 / CTA 波浪 / 锚点滚动
   全部为渐进增强：没有 JS 时退回 v5 的静态版本。 */

/* ================================================================
   P2-1 行业卡：跟随指针的预览卡
   ================================================================ */
.v5-ind-preview {
  position: fixed; left: 0; top: 0; z-index: 40;
  width: min(320px, calc(100vw - 48px));
  padding: 20px 22px 18px;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(10, 17, 32, .97), rgba(5, 8, 16, .97));
  border: 1px solid rgba(56, 182, 242, .24);
  box-shadow: 0 28px 80px -28px rgba(0, 0, 0, .95), 0 0 0 1px rgba(255, 255, 255, .03) inset;
  pointer-events: none; opacity: 0; visibility: hidden;
  transform: translate3d(-999px, -999px, 0);
  transition: opacity .22s var(--v5-ease), visibility .22s;
  will-change: transform;
}
.v5-ind-preview::before {
  content: ''; position: absolute; left: 22px; right: 22px; top: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(56, 182, 242, .8), transparent);
}
.v5-ind-preview.is-on { opacity: 1; visibility: visible; }
.v5-ind-preview__top { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.v5-ind-preview__num {
  font: 500 40px/1 var(--font-mono); letter-spacing: -.06em;
  color: var(--t-accent); opacity: .95;
}
.v5-ind-preview__eyebrow {
  font: 500 9.5px/1.4 var(--font-mono); letter-spacing: .18em;
  color: var(--t4); text-transform: uppercase;
}
.v5-ind-preview__name {
  display: block; margin-top: 12px;
  font: 600 25px/1.25 var(--font-display); letter-spacing: -.02em; color: var(--t1);
}
.v5-ind-preview__tags {
  margin-top: 8px; font-size: 12.5px; line-height: 1.7; color: var(--t2);
}
.v5-ind-preview__hint {
  display: flex; align-items: center; gap: 8px;
  margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line-1);
  font: 500 9.5px/1.4 var(--font-mono); letter-spacing: .1em; color: var(--t4);
}
.v5-ind-preview__hint::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%;
  background: var(--t-accent); box-shadow: 0 0 0 4px rgba(56, 182, 242, .12);
}
.v5-ind-grid.is-previewing .h-ind__card { opacity: .48; }
.v5-ind-grid.is-previewing .h-ind__card.is-hovered { opacity: 1; }
.h-ind__card { transition: opacity .3s var(--v5-ease), border-color .3s var(--v5-ease), transform .5s var(--v5-ease); }
@media (hover: none), (prefers-reduced-motion: reduce) {
  .v5-ind-preview { display: none !important; }
}

/* ================================================================
   P2-2 五步：滚动/点选共用的“动态链路” + 大字 HUD
   ================================================================ */
.c-steps.v5-steps { isolation: isolate; }
.v5-steps::after {
  content: ''; position: absolute; left: 11px; top: 8px; bottom: 8px; width: 2px; z-index: 0;
  background: linear-gradient(180deg, rgba(56, 182, 242, .9), rgba(87, 111, 219, .65));
  transform: scaleY(var(--p, 0)); transform-origin: top;
  transition: transform .8s var(--v5-ease);
  border-radius: 2px;
}
.v5-steps .c-steps__step {
  position: relative; z-index: 1; isolation: isolate;
  opacity: .58; cursor: pointer;
  transition: opacity .55s var(--v5-ease), transform .55s var(--v5-ease);
}
.v5-steps .c-steps__step::before {
  content: ''; position: absolute; inset: -10px -14px; z-index: -1;
  border-radius: 14px; opacity: 0;
  border: 1px solid transparent;
  background: linear-gradient(90deg, rgba(2, 139, 215, .14), rgba(2, 139, 215, 0));
  transition: opacity .5s var(--v5-ease), border-color .5s var(--v5-ease);
}
.v5-steps .c-steps__step:hover { opacity: .82; }
.v5-steps .c-steps__step.is-active { opacity: 1; transform: translateX(4px); }
.v5-steps .c-steps__step.is-active::before {
  opacity: 1;
  border-color: rgba(56, 182, 242, .18);
}
.v5-steps .c-steps__step.is-active .c-steps__dot {
  border-color: var(--t-accent);
  box-shadow: 0 0 0 5px rgba(56, 182, 242, .10), 0 0 24px rgba(56, 182, 242, .22);
}
.v5-steps .c-steps__step.is-active .c-steps__dot::after { background: var(--t-accent); }
.v5-steps .c-steps__step.is-active .c-steps__title { color: var(--t1); }
.v5-steps .c-steps__step.is-active .c-steps__desc { color: var(--t2); }
.v5-steps .c-steps__step:focus-visible { outline: 2px solid var(--focus-color); outline-offset: 6px; border-radius: 8px; }

/* 点阵链路 */
.v5-chain-line {
  opacity: .36;
  transition: stroke-dashoffset .9s var(--v5-ease);
}
.v5-chain-ring { opacity: .35; pointer-events: none; }
.v5-chain-comet { pointer-events: none; }
.h-steps__svg circle[data-g="-1"] { opacity: .36; }
.h-steps__svg circle[data-g] { transition: opacity .45s var(--v5-ease); }
.h-steps__svg circle.is-future { opacity: .5; }
.h-steps__svg circle.is-done { opacity: .88; }
.h-steps__svg circle.is-on { opacity: 1; }

/* 大字 HUD */
.v5-steps__hud {
  position: static;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line-1);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: end;
  gap: 4px 18px;
}
.v5-steps__hud b {
  grid-row: 1 / span 2;
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 4.4vw, 4.1rem);
  font-weight: 300;
  line-height: .8;
  letter-spacing: -.05em;
  color: var(--t1);
}
.v5-steps__hud b i { font-style: normal; color: var(--t-accent); }
.v5-steps__hud b em {
  margin-left: 6px;
  font: 500 10px/1 var(--font-mono);
  font-style: normal;
  letter-spacing: .04em;
  color: var(--t4);
}
.v5-steps__hud span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font: 500 var(--fs-small)/1.4 var(--font-text);
  color: var(--t2);
}
.v5-steps__meter {
  grid-column: 2;
  height: 2px;
  overflow: hidden;
  background: var(--line-1);
}
.v5-steps__meter i {
  display: block; height: 100%; width: 20%;
  background: linear-gradient(90deg, var(--t-accent), var(--indigo-lift));
  transition: width .7s var(--v5-ease);
}

@media (max-width: 1023px) {
  .v5-steps__hud b { font-size: 2.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  .v5-steps .c-steps__step { opacity: 1; }
  .v5-steps::after { transition: none; }
  .v5-chain-ring, .v5-chain-comet { display: none; }
  .h-steps__svg, .h-steps__svg circle, .v5-chain-line,
  .v5-steps__hud, .v5-steps__meter i { transition: none !important; animation: none !important; }
}

/* ================================================================
   P2-3 OPC：横向手风琴（仅精细指针桌面）
   ================================================================ */
@media (min-width: 1024px) and (hover: hover) and (pointer: fine) {
  .v4-opc__grid.v5-opc {
    display: flex; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-1);
  }
  .v5-opc .v4-opc__mod {
    flex: 1 1 0; min-width: 0; overflow: hidden;
    border-bottom: 0; border-left: 1px solid var(--line-1);
    padding: clamp(24px, 2.6vw, 34px) clamp(16px, 1.8vw, 26px) clamp(26px, 2.8vw, 36px);
    transition: flex-grow .9s var(--v5-ease), transform .5s var(--v5-ease),
                background .6s var(--v5-ease), padding .9s var(--v5-ease);
  }
  .v5-opc .v4-opc__mod:first-child { border-left: 0; }
  .v5-opc .v4-opc__modlead {
    max-height: 0; opacity: 0; margin-top: 0; overflow: hidden; color: var(--t2);
    transition: max-height .7s var(--v5-ease), opacity .45s var(--v5-ease),
                margin-top .7s var(--v5-ease);
  }
  .v5-opc .v4-opc__mod:hover,
  .v5-opc .v4-opc__mod:focus-within {
    flex-grow: 3.4;
    background: linear-gradient(165deg, rgba(19, 29, 52, .62), rgba(7, 11, 22, .1));
  }
  .v5-opc .v4-opc__mod:hover .v4-opc__modlead,
  .v5-opc .v4-opc__mod:focus-within .v4-opc__modlead {
    max-height: 90px; opacity: 1; margin-top: 6px;
  }
  .v5-opc .v4-opc__mod:focus-visible { outline: 1px solid var(--t-accent); outline-offset: -1px; }
}
@media (prefers-reduced-motion: reduce) {
  .v5-opc .v4-opc__mod,
  .v5-opc .v4-opc__modlead { transition: none; }
}

/* ================================================================
   OPC 认证体系 L0–L6
   ================================================================ */
.h-cert {
  margin-top: clamp(48px, 6vw, 84px);
  padding-top: clamp(26px, 3.4vw, 42px);
  border-top: 1px solid var(--line-2);
}
.h-cert__head { display: grid; gap: var(--sp-4); }
.h-cert__title {
  margin-top: 14px;
  font: 600 var(--fs-h3) / 1.18 var(--font-display);
  letter-spacing: -.02em; color: var(--t1);
}
.h-cert__aside { display: grid; gap: 12px; align-content: start; }
.h-cert__lead {
  max-width: 46ch;
  font-size: var(--fs-small); line-height: 1.8; color: var(--t2);
}
.h-cert__meta {
  display: flex; flex-wrap: wrap; gap: 8px 16px;
  font: 500 10px/1.5 var(--font-mono); letter-spacing: .08em; color: var(--t4);
}
.h-cert__meta span { display: inline-flex; align-items: center; gap: 7px; }
.h-cert__meta span::before {
  content: ''; width: 4px; height: 4px; border-radius: 50%;
  background: var(--t-accent); box-shadow: 0 0 0 3px rgba(56, 182, 242, .10);
}
.h-cert__tracks {
  max-width: 52ch;
  font: 500 10px/1.9 var(--font-mono); letter-spacing: .02em; color: var(--t4);
}
.h-cert__rail {
  list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px; margin: clamp(22px, 3vw, 34px) 0 0; padding: 0;
  border: 1px solid var(--line-1); background: var(--line-1);
}
.h-cert__step {
  appearance: none; -webkit-appearance: none;
  position: relative; display: flex; flex-direction: column; align-items: flex-start;
  gap: 6px; width: 100%; min-width: 0; min-height: 154px; box-sizing: border-box;
  padding: 16px 14px 18px; border: 0; border-radius: 0;
  background: var(--s1); color: inherit; font: inherit; text-align: left;
  cursor: pointer;
  transition: background .35s var(--v5-ease), opacity .35s var(--v5-ease),
              transform .35s var(--v5-ease);
}
.h-cert__step:hover { transform: translateY(-2px); }
.h-cert__step:focus-visible { outline: 1px solid var(--t-accent); outline-offset: -2px; }
.h-cert__rail.is-interactive .h-cert__step { opacity: .52; }
.h-cert__rail.is-interactive .h-cert__step:hover,
.h-cert__rail.is-interactive .h-cert__step.is-active { opacity: 1; }
.h-cert__step.is-active {
  background: linear-gradient(165deg, rgba(56, 182, 242, .18), rgba(87, 111, 219, .06) 68%, var(--s1));
}
.h-cert__step.is-active .h-cert__icon {
  border-color: var(--t-accent); color: var(--t-accent);
  box-shadow: 0 0 0 4px rgba(56, 182, 242, .14);
  transform: scale(1.06);
}
.h-cert__step.is-active .h-cert__lv { color: var(--t-accent); }
.h-cert__step.is-active .h-cert__req { color: var(--t2); }
.h-cert__step.is-active .h-cert__icon::after {
  content: ''; position: absolute; inset: -5px; border-radius: 50%;
  border: 1px solid rgba(56, 182, 242, .42);
  animation: h-cert-pulse 2.6s var(--v5-ease) infinite;
}
@keyframes h-cert-pulse {
  0% { transform: scale(.9); opacity: .85; }
  70%, 100% { transform: scale(1.4); opacity: 0; }
}
.h-cert__icon {
  display: grid; place-items: center;
  width: 34px; height: 34px; margin-bottom: 4px;
  border: 1px solid var(--line-2); border-radius: 50%;
  background: var(--s1); color: var(--t2);
  position: relative; z-index: 1;
}
.h-cert__icon svg { width: 16px; height: 16px; }
.h-cert__lv {
  font: 500 9.5px/1 var(--font-mono); letter-spacing: .16em; color: var(--t4);
}
.h-cert__name {
  font: 600 15px/1.35 var(--font-display); letter-spacing: -.01em; color: var(--t1);
}
.h-cert__req {
  font-size: 11.5px; line-height: 1.65; color: var(--t3);
}
.h-cert__step--l3 {
  background: linear-gradient(165deg, rgba(56, 182, 242, .13), rgba(87, 111, 219, .04) 70%, var(--s1));
}
.h-cert__step--l3 .h-cert__icon {
  border-color: rgba(56, 182, 242, .44); color: var(--t2);
}
.h-cert__step--l3 .h-cert__lv { color: var(--t2); }
.h-cert__step--l3 .h-cert__req { color: var(--t2); }
.h-cert__detail {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center; gap: clamp(18px, 3vw, 44px);
  margin-top: 14px; padding: 16px 0 14px;
  border-top: 1px solid var(--line-1);
}
.h-cert__detail-main { display: flex; align-items: center; gap: 16px; min-width: 0; }
.h-cert__detail-lv {
  min-width: 62px;
  font: 500 34px/1 var(--font-mono); letter-spacing: -.06em; color: var(--t-accent);
  font-variant-numeric: tabular-nums;
}
.h-cert__detail-copy { display: grid; gap: 3px; min-width: 0; }
.h-cert__detail-kicker {
  font: 500 9px/1.4 var(--font-mono); letter-spacing: .14em; color: var(--t4);
}
.h-cert__detail-name {
  font: 600 16px/1.3 var(--font-display); letter-spacing: -.01em; color: var(--t1);
}
.h-cert__detail-req { font-size: 11.5px; line-height: 1.55; color: var(--t3); }
.h-cert__detail-next { display: grid; gap: 4px; min-width: 0; }
.h-cert__detail-next > span {
  font: 500 9px/1.4 var(--font-mono); letter-spacing: .12em; color: var(--t4);
}
.h-cert__detail-next p {
  margin: 0; font-size: 12.5px; line-height: 1.6; color: var(--t2);
}
.h-cert__detail-side { display: grid; justify-items: end; gap: 3px; }
.h-cert__detail-count {
  font: 500 10px/1.4 var(--font-mono); letter-spacing: .1em; color: var(--t3);
}
.h-cert__detail-hint {
  font: 500 9px/1.4 var(--font-mono); letter-spacing: .04em; color: var(--t4);
  white-space: nowrap;
}
.h-cert__detail.is-swap .h-cert__detail-main,
.h-cert__detail.is-swap .h-cert__detail-next,
.h-cert__detail.is-swap .h-cert__detail-side {
  animation: h-cert-swap .34s var(--v5-ease) both;
}
@keyframes h-cert-swap {
  from { opacity: .15; transform: translateY(5px); }
}
.h-cert__meter {
  height: 2px; margin: 0 0 12px; overflow: hidden;
  background: var(--line-1);
}
.h-cert__meter span {
  display: block; width: var(--cert-p, 57.14%); height: 100%;
  background: linear-gradient(90deg, var(--t-accent), var(--indigo-lift));
  transition: width .55s var(--v5-ease);
}
.h-cert__foot {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 18px;
  margin-top: 13px;
  font: 500 10px/1.65 var(--font-mono); letter-spacing: .02em; color: var(--t4);
}
.h-cert__foot span:last-child { color: var(--t3); }
@media (min-width: 768px) {
  .h-cert__rail { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
  .h-cert__step:last-child { grid-column: span 2; min-height: 0; }
  .h-cert__step.is-active::after {
    content: '下一步 · ' attr(data-next);
    display: block; margin-top: 7px; padding-top: 8px;
    border-top: 1px solid var(--line-1);
    font: 500 9px/1.65 var(--font-mono); letter-spacing: .02em; color: var(--t2);
  }
}
@media (min-width: 768px) and (max-width: 1199px) {
  .h-cert__step:last-child { grid-column: span 2; }
}
@media (max-width: 1023px) {
  .h-cert__detail { grid-template-columns: 1fr; gap: 12px; }
  .h-cert__detail-side {
    display: flex; justify-content: flex-start; gap: 16px;
  }
}
@media (min-width: 1024px) {
  .h-cert__head {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    align-items: end; gap: var(--sp-7);
  }
  .h-cert__aside { justify-items: end; text-align: right; }
  .h-cert__meta { justify-content: flex-end; }
}
@media (min-width: 1200px) {
  .h-cert__rail {
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0; border-left: 0; border-right: 0; background: transparent;
    border-bottom: 1px solid var(--line-1);
    position: relative;
  }
  .h-cert__rail::before {
    content: ''; position: absolute; left: 0; right: 0; top: 16px; height: 1px;
    background: var(--line-1); z-index: 0;
  }
  .h-cert__rail::after {
    content: ''; position: absolute; left: 32px; top: 16px; height: 1px;
    width: calc(var(--cert-i, 3) * 100% / 7);
    background: linear-gradient(90deg, var(--t-accent), rgba(87, 111, 219, .75));
    transition: width .55s var(--v5-ease);
    z-index: 0;
  }
  .h-cert__step {
    min-height: 0; padding: 0 15px 22px;
    background: transparent; border-left: 1px solid var(--line-1);
  }
  .h-cert__step:first-child { border-left: 0; }
  .h-cert__step--l3 { background: linear-gradient(165deg, rgba(56, 182, 242, .13), rgba(87, 111, 219, .03) 70%, transparent); }
  .h-cert__step:last-child { grid-column: auto; }
  .h-cert__icon { margin-top: -1px; background: var(--s1); }
}
@media (prefers-reduced-motion: reduce) {
  .h-cert__icon, .h-cert__step, .h-cert__meter span { transition: none; }
  .h-cert__step.is-active .h-cert__icon::after { animation: none; }
  .h-cert__detail.is-swap .h-cert__detail-main,
  .h-cert__detail.is-swap .h-cert__detail-next,
  .h-cert__detail.is-swap .h-cert__detail-side { animation: none; }
}

/* ================================================================
   P2-4 城市：航线绘制 / 节点脉冲 / 时钟 / 图片过渡
   ================================================================ */
.v4-map.is-drawn .v4-map__arcs path { stroke-dashoffset: 0 !important; }
.v5-cityclock {
  display: flex; align-items: center; gap: 9px;
  margin-top: 2px;
  font: 500 10.5px/1.4 var(--font-mono); letter-spacing: .1em; color: var(--t3);
}
.v5-cityclock b { color: var(--t1); font-weight: 500; letter-spacing: .08em; }
.v5-cityclock__dot {
  width: 5px; height: 5px; border-radius: 50%; background: var(--t-accent);
  box-shadow: 0 0 0 4px rgba(56, 182, 242, .12);
}
.h-cities__panel:not([hidden]) .c-slot img { animation: v5-photo-in .85s var(--v5-ease) both; }
@keyframes v5-photo-in {
  from { opacity: 0; transform: scale(1.035); }
}
@media (prefers-reduced-motion: no-preference) {
  .v4-map__halo {
    transform-box: fill-box; transform-origin: center;
    animation: v5-halo 4.2s ease-in-out infinite;
  }
  .v4-map__node:nth-child(2) .v4-map__halo { animation-delay: .55s; }
  .v4-map__node:nth-child(3) .v4-map__halo { animation-delay: 1.1s; }
  .v4-map__node:nth-child(4) .v4-map__halo { animation-delay: 1.65s; }
}
@keyframes v5-halo {
  0%, 100% { opacity: .5; transform: scale(1); }
  50% { opacity: .12; transform: scale(1.35); }
}
@media (prefers-reduced-motion: reduce) {
  .h-cities__panel .c-slot img { animation: none; }
  .v4-map__halo { animation: none; }
}

/* ================================================================
   P2-5 AIGC 卡片：入场 stagger / hover 抬升 / 媒体缩放
   ================================================================ */
@media (hover: hover) {
  .c-tile {
    transition:
      opacity 1s var(--v5-ease) calc(var(--i, 0) * 70ms),
      filter 1s var(--v5-ease) calc(var(--i, 0) * 70ms),
      transform 1.1s var(--v5-ease) calc(var(--i, 0) * 70ms),
      translate .5s var(--v5-ease),
      border-color .4s var(--v5-ease),
      background .4s var(--v5-ease);
  }
  .c-tile:hover {
    translate: 0 -4px;
    border-color: rgba(56, 182, 242, .32);
    background: linear-gradient(180deg, rgba(22, 30, 49, .7), var(--s2) 60%);
  }
  .c-tile__stage img { transition: transform .9s var(--v5-ease); }
  .c-tile:hover .c-tile__stage img { transform: scale(1.03); }
}
@media (prefers-reduced-motion: reduce) {
  .c-tile, .c-tile__stage img { transition: none; }
  .c-tile:hover { translate: none; }
  .c-tile:hover .c-tile__stage img { transform: none; }
}
.v5-anchor-target:focus { outline: none; }

/* ================================================================
   P3-1 首屏点阵：滚动缩放 / 淡出
   ================================================================ */
.v4-hero__canvas { will-change: transform, opacity; transform-origin: 50% 45%; }

/* ================================================================
   P3-2 CTA 波浪
   ================================================================ */
.v5-wave {
  position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%;
  pointer-events: none; opacity: .55;
}
.h-cta > .l-container { position: relative; z-index: 1; }
@media (prefers-reduced-motion: reduce) { .v5-wave { display: none !important; } }

/* ================================================================
   P2-6 / 其它
   ================================================================ */
.c-marquee__viewport {
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}
