/* theme_ads: icon1 marquee (from default ads-ads_icon1.css)
 * Fix: when duplicated track is narrower than viewport (few icons), left-aligned
 * max-content leaves a large right gap on play page. Detect via JS → .is-centered:
 * hide the aria-hidden clone, stop animation, flex-center the single group.
 */
@keyframes ads_icon1-marquee-x {
  0% { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.ads_icon1-marquee {
  box-sizing: border-box;
  margin: 10px auto 0;
  overflow: hidden;
  padding: 10px 0;
  width: 100%;
  max-width: var(--wrap, 1400px);
}
.bstem .ads_icon1-marquee {
  background: hsla(0, 0%, 100%, 0.06);
}
.ads_icon1-marquee-viewport {
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  overflow: hidden;
  width: 100%;
}
.ads_icon1-marquee-track {
  animation: ads_icon1-marquee-x 45s linear infinite;
  display: flex;
  width: -webkit-max-content;
  width: -moz-max-content;
  width: max-content;
  will-change: transform;
}
.ads_icon1-marquee-track:hover {
  animation-play-state: paused;
}
.ads_icon1-marquee-group {
  align-items: flex-start;
  display: flex;
  flex-shrink: 0;
  gap: 20px;
  padding: 0 12px;
}
.ads_icon1-marquee-item {
  box-sizing: border-box;
  flex: 0 0 auto;
  text-align: center;
  width: 72px;
}
.ads_icon1-marquee-item a {
  color: inherit;
  display: block;
  text-decoration: none;
}
.ads_icon1-marquee-item img {
  border-radius: var(--tpl-radius);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  display: block;
  height: 56px;
  margin: 0 auto;
  object-fit: cover;
  width: 56px;
}
.ads_icon1-marquee-item span {
  color: var(--tpl-text-muted);
  display: block;
  font-size: 11px;
  line-height: 1.25;
  margin-top: 6px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bstem .ads_icon1-marquee-item span {
  color: hsla(0, 0%, 100%, 0.7);
}
/* Few icons: track narrower than content — center, no scroll */
.ads_icon1-marquee.is-centered .ads_icon1-marquee-viewport {
  display: flex;
  justify-content: center;
  mask-image: none;
  -webkit-mask-image: none;
}
.ads_icon1-marquee.is-centered .ads_icon1-marquee-track {
  animation: none;
  will-change: auto;
}
.ads_icon1-marquee.is-centered .ads_icon1-marquee-group[aria-hidden="true"] {
  display: none;
}
@media (prefers-reduced-motion: reduce) {
  .ads_icon1-marquee-track {
    animation: none;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 100%;
    width: 100%;
  }
  .ads_icon1-marquee-group[aria-hidden="true"] {
    display: none;
  }
  .ads_icon1-marquee-group {
    flex-wrap: wrap;
    gap: 12px 16px;
    justify-content: center;
    padding: 0 8px;
    width: 100%;
  }
}

/* theme_ads: banner1（#1484 主栏宽；展示高度对齐 v10 default ads_banner1：有 ad_data.height 则写 inline height） */
.pb-theme-ads-banner1__link {
  display: block;
}
.pb-theme-ads-banner1__img {
  display: block;
}

/* theme_ads: double / bottom floating (from default public-head-early) */
.hl_ads_double img{width:100%;height:100%;}
.hl_ads_double{display:block;overflow:hidden;position:fixed;top:60%;z-index:999999998}
#LeftDiv .close_ads_lbtn,#LeftDiv.hl_ads_double{left:0}
#RightDiv.hl_ads_double{right:0}
.hl_bottom_ads{bottom:0;color:var(--tpl-text);left:0;position:fixed;width:100%;z-index:999}
.bottom_ads_box,.hl_bottom_ads{display:block;max-height:90px!important}
.bottom_ads_box{overflow:hidden}
/* 关闭 ×：桌面略加大；H5 视觉与点击热区 ≥44×44（按钮本体，避免 overflow:hidden 裁切伪元素） */
.close_ads_btn,.close_ads_lbtn,.close_ads_rbtn{
  align-items:center;
  background:rgba(0,0,0,.4);
  box-sizing:border-box;
  color:var(--tpl-text-on-inverse, #fff);
  display:flex;
  font-size:18px;
  font-weight:700;
  height:32px;
  justify-content:center;
  line-height:1;
  position:absolute;
  right:0;
  text-align:center;
  text-decoration:none;
  top:0;
  width:32px;
  z-index:2;
}
@media (max-width: 768px){
  .close_ads_btn,.close_ads_lbtn,.close_ads_rbtn{
    font-size:24px;
    height:44px;
    min-height:44px;
    min-width:44px;
    width:44px;
  }
}
.foot.foot_stem{padding-bottom:120px}
.foot_stem .extra{bottom:110px}
html.mac-app-dl-visible .foot.foot_nav.foot_stem{padding-bottom:232px}
.foot.foot_nav.foot_stem{padding-bottom:180px}
.foot_nav.foot_stem .hl_bottom_ads{bottom:1.35rem}
.foot_nav.foot_stem .extra{bottom:180px}

/* PB 移动端底栏（pb-bottom-nav / np2-tabbar）：底飘抬至底栏之上，不挡菜单点击 */
@media (max-width: 640px) {
  html.has-pb-bottom-nav .hl_bottom_ads,
  body:has(.pb-bottom-nav) .hl_bottom_ads {
    bottom: calc(56px + env(safe-area-inset-bottom, 0px));
    z-index: 898;
  }
}
@media (max-width: 960px) {
  body:has(.np2-tabbar) .hl_bottom_ads {
    bottom: calc(56px + env(safe-area-inset-bottom, 0px));
    z-index: 940;
  }
}

/* theme_ads: play（播放页选集后的图文卡片；PB 不加载 default 的 play_vlist 样式） */
.pb-theme-ads-play{margin:12px 0}
.pb-theme-ads-play a{align-items:center;color:inherit;display:flex;gap:12px;text-decoration:none}
.pb-theme-ads-play__pic{border-radius:var(--tpl-radius, 6px);flex:0 0 120px;overflow:hidden;position:relative;aspect-ratio:16/9}
.pb-theme-ads-play__pic img{display:block;height:100%;object-fit:cover;width:100%}
.pb-theme-ads-play__tip{background:rgba(0,0,0,.55);border-radius:3px;color:#fff;font-size:11px;left:4px;line-height:1;padding:3px 5px;position:absolute;top:4px}
.pb-theme-ads-play__text{display:flex;flex-direction:column;gap:4px;min-width:0}
.pb-theme-ads-play__text strong{font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pb-theme-ads-play__text em{color:var(--tpl-text-muted);font-size:12px;font-style:normal}
