/* ==================================================================
   Yandex SEO 优化详情页 —— 仅「顶部右侧 3D 场景」样式
   作用域严格限定 #yseo-scene 及其子元素：
   不修改左侧内容、五步体系、专业能力、FAQ、CTA、导航、页脚，也不影响任何其它页面。
   依赖站点既有 ../css/style.css（容器定位/尺寸/圆角由原样式提供）。
   主题：Yandex 排名数据面板（白色面板 + 品牌红侧壁 + 6 根金色柱逐级抬高，
        最高一根红色并越过金色"首页线"）+ 红色上升徽章 + 六张卖点卡片。
   ================================================================== */

/* ---------- 3D 场景容器：浅蓝白底，与集团 / 营销 / 外贸 / 功能定制页同一套设计语言 ---------- */
#yseo-scene.service-detail-hero-img {
  background:
    radial-gradient(120% 100% at 50% 6%, rgba(255,255,255,.86) 0%, rgba(255,255,255,0) 58%),
    radial-gradient(92% 82% at 84% 94%, rgba(160,199,232,.44) 0%, rgba(160,199,232,0) 66%),
    linear-gradient(168deg, #F2F9FF 0%, #E4F0FB 46%, #D5E6F7 100%);
  border: 1px solid rgba(146,175,213,.32);
  box-shadow:
    inset 0 -60px 80px -70px rgba(27,44,70,.20),
    0 26px 60px -26px rgba(30,58,102,.30),
    0 2px 10px rgba(30,58,102,.05);
  isolation: isolate;
}

/* 极淡网点：只作空气感，不抢主体 */
#yseo-scene::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(150,180,216,.062) 1px, transparent 1px),
    linear-gradient(90deg, rgba(150,180,216,.062) 1px, transparent 1px);
  background-size: 40px 40px;
  -webkit-mask-image: radial-gradient(72% 62% at 50% 58%, #000 12%, transparent 100%);
  mask-image: radial-gradient(72% 62% at 50% 58%, #000 12%, transparent 100%);
}

/* 星点氛围：3D 加载前 / 降级时同样生效，避免画面空洞 */
#yseo-scene::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1.6px 1.6px at 12% 18%, rgba(120,160,210,.50) 50%, transparent 52%),
    radial-gradient(1.4px 1.4px at 82% 14%, rgba(120,160,210,.40) 50%, transparent 52%),
    radial-gradient(1.8px 1.8px at 70% 30%, rgba(255,255,255,.55) 50%, transparent 52%),
    radial-gradient(1.3px 1.3px at 22% 42%, rgba(120,160,210,.38) 50%, transparent 52%),
    radial-gradient(1.5px 1.5px at 90% 52%, rgba(255,255,255,.45) 50%, transparent 52%),
    radial-gradient(1.4px 1.4px at 8% 66%, rgba(120,160,210,.40) 50%, transparent 52%),
    radial-gradient(1.7px 1.7px at 60% 80%, rgba(255,255,255,.40) 50%, transparent 52%),
    radial-gradient(1.3px 1.3px at 38% 88%, rgba(120,160,210,.34) 50%, transparent 52%),
    radial-gradient(1.5px 1.5px at 52% 8%, rgba(255,255,255,.42) 50%, transparent 52%);
  -webkit-mask-image: radial-gradient(78% 70% at 50% 56%, #000 8%, transparent 96%);
  mask-image: radial-gradient(78% 70% at 50% 56%, #000 8%, transparent 96%);
}

/* ---------- 3D 画布 ---------- */
#yseo-scene .yseo-canvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  z-index: 3;
  opacity: 0;
  transition: opacity .9s ease;
}
#yseo-scene.yseo-ready .yseo-canvas { opacity: 1; }

/* ---------- 静态海报：3D 未加载 / 移动端 / 减少动效时的降级内容 ---------- */
#yseo-scene img.showcase-img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity .7s ease, transform 1.2s cubic-bezier(.2,.7,.2,1);
}
#yseo-scene:hover img.showcase-img { transform: scale(1.03); }
#yseo-scene.yseo-ready img.showcase-img { opacity: 0; }

/* 容器必须始终可见：站点 .animate-on-scroll 初始 opacity:0，
   若脚本未触发会导致 3D 区域整块白屏，这里保证内容与降级图始终可读。 */
#yseo-scene.animate-on-scroll { opacity: 1; }
#yseo-scene.animate-on-scroll.animated {
  animation: yseoSceneIn .9s cubic-bezier(.16,.84,.3,1) both;
}
@keyframes yseoSceneIn {
  from { opacity: 0; transform: translateY(22px) scale(.98); }
  to   { opacity: 1; transform: none; }
}

/* 降级态：静态海报保留极克制的呼吸感 */
#yseo-scene.yseo-static img.showcase-img { animation: yseoBreath 9s ease-in-out infinite; }
@keyframes yseoBreath {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.02); }
}

/* ---------- 环绕卖点卡片：文字由 DOM 原生渲染，任何尺寸都锐利 ---------- */
#yseo-scene .yseo-labels {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}
#yseo-scene .yseo-card-label {
  position: absolute;
  left: 50%;
  top: 50%;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px 7px 8px;
  min-width: 96px;
  max-width: 148px;
  border-radius: 9px;
  background: rgba(255,255,255,.97);
  border: 1px solid rgba(146,175,213,.50);
  border-left: 3px solid var(--yseo-accent, #2E6FD6);
  box-shadow: 0 8px 20px rgba(30,58,102,.16), 0 1px 3px rgba(30,58,102,.08);
  transform: translate(-50%,-50%) scale(.92);
  opacity: 0;
  transition: opacity .45s ease, transform .45s cubic-bezier(.16,.84,.3,1);
  white-space: nowrap;
}
#yseo-scene .yseo-card-label.is-on {
  opacity: 1;
  transform: translate(-50%,-50%) scale(1);
}
#yseo-scene .yseo-card-label i {
  flex: 0 0 auto;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--yseo-accent, #2E6FD6);
}
#yseo-scene .yseo-card-label span { display: block; min-width: 0; }
#yseo-scene .yseo-card-label b {
  display: block;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: .01em;
  color: #16335B;
}
#yseo-scene .yseo-card-label em {
  display: block;
  margin-top: 2px;
  font-size: 10px;
  font-style: normal;
  line-height: 1.3;
  color: #6B829E;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- 中心标注：说明"这块面板就是 AI 答案里的品牌位" ---------- */
#yseo-scene .yseo-core-cap {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  pointer-events: none;
  text-align: center;
  white-space: nowrap;
  transform: translate(-50%,-50%) scale(.94);
  opacity: 0;
  transition: opacity .5s ease, transform .5s cubic-bezier(.16,.84,.3,1);
}
#yseo-scene .yseo-core-cap.is-on {
  opacity: 1;
  transform: translate(-50%,-50%) scale(1);
}
#yseo-scene .yseo-core-cap b {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: .02em;
  color: #16335B;
}
#yseo-scene .yseo-core-cap em {
  display: block;
  margin-top: 2px;
  font-size: 10px;
  font-style: normal;
  line-height: 1.3;
  letter-spacing: .01em;
  color: #5C7793;
}

/* 窄容器 / 平板：文字牌等比收紧，避免 6 张互相挤压 */
@media (max-width: 1100px) {
  #yseo-scene .yseo-card-label { padding: 5px 8px 5px 6px; min-width: 84px; max-width: 126px; gap: 5px; }
  #yseo-scene .yseo-card-label b { font-size: 11.5px; }
  #yseo-scene .yseo-card-label em { font-size: 9px; }
  #yseo-scene .yseo-card-label i { width: 7px; height: 7px; }
  #yseo-scene .yseo-core-cap b { font-size: 11.5px; }
  #yseo-scene .yseo-core-cap em { font-size: 9px; }
}

/* ---------- 模块悬停提示（功能名称 + 简短说明） ---------- */
#yseo-scene .yseo-tooltip {
  position: absolute;
  z-index: 6;
  min-width: 168px;
  max-width: 250px;
  padding: 10px 13px 11px;
  border-radius: 10px;
  background: rgba(20,36,62,.94);
  border: 1px solid rgba(226,120,96,.50);
  box-shadow: 0 12px 32px rgba(16,30,54,.30);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: #fff;
  pointer-events: none;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .22s ease, transform .22s ease;
}
#yseo-scene .yseo-tooltip.is-visible { opacity: 1; transform: none; }
#yseo-scene .yseo-tooltip strong {
  display: block;
  margin-bottom: 4px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
  color: #FFCFC2;
}
#yseo-scene .yseo-tooltip span {
  display: block;
  font-size: 11.5px;
  line-height: 1.65;
  color: rgba(255,255,255,.82);
}

/* ---------- 响应式（只调 3D 区域本身，不改页面布局） ---------- */
@media (max-width: 767px) {
  #yseo-scene .yseo-tooltip { display: none; }
}

/* ---------- 减少动效：内容始终可见，停止一切装饰动画 ---------- */
@media (prefers-reduced-motion: reduce) {
  #yseo-scene.animate-on-scroll,
  #yseo-scene.animate-on-scroll.animated {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
  #yseo-scene.yseo-static img.showcase-img { animation: none !important; }
  #yseo-scene .yseo-canvas,
  #yseo-scene img.showcase-img { transition-duration: .01ms !important; }
}

/* ---------- 窄容器（真实服务页右侧栏 ~430px）：卡片收紧，把版面让给中心搜索屏 ---------- */
#yseo-scene.yseo-narrow .yseo-card-label {
  padding: 5px 8px 5px 6px;
  min-width: 78px;
  max-width: 112px;
  gap: 5px;
  border-radius: 8px;
}
#yseo-scene.yseo-narrow .yseo-card-label i { width: 7px; height: 7px; }
#yseo-scene.yseo-narrow .yseo-card-label b { font-size: 11.5px; }
#yseo-scene.yseo-narrow .yseo-card-label em { font-size: 9px; }
#yseo-scene.yseo-narrow .yseo-core-cap b { font-size: 12px; }
