/* ==========================================================================
   Poetize 前台 · 首页顶部轮播图样式
   站点：https://baby.9k.beer        生成：2026-11-02
   配置源：/pinned-promo/banner.json（改 JSON 即可换图换链接，不用改代码）
   渲染器：/js/pinned-promo-banner.js
   作用范围：全站宽度自适应；高度用 CSS 变量由 JS 按配置写入。
   ========================================================================== */

.ppb-outer {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  margin: 0 auto 18px;
  padding: 0 14px;
}

.ppb-stage {
  position: relative;
  width: 100%;
  height: var(--ppb-h, 160px);
  border-radius: var(--ppb-radius, 14px);
  overflow: hidden;
  background: #eef1f5;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 10px 22px -14px rgba(16, 24, 40, .28);
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
}

.ppb-track {
  display: flex;
  height: 100%;
  will-change: transform;
  transition: transform .45s cubic-bezier(.4, 0, .2, 1);
}
.ppb-track.is-dragging {
  transition: none;
}

.ppb-slide {
  position: relative;
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  display: block;
  overflow: hidden;
  text-decoration: none;
}

.ppb-slide img {
  display: block;
  width: 100%;
  height: 100%;
  /* 站内推广图多为竖版海报，顶部才是主视觉标题，故对齐顶部裁切 */
  object-fit: cover;
  object-position: center top;
  pointer-events: none;
}

/* 左右箭头 */
.ppb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .32);
  color: #fff;
  font-size: 17px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: .9;
  -webkit-tap-highlight-color: transparent;
}
.ppb-nav:hover { opacity: 1; background: rgba(0, 0, 0, .48); }
.ppb-prev { left: 8px; }
.ppb-next { right: 8px; }

/* 指示点 */
.ppb-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  pointer-events: none;
}
.ppb-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .55);
  box-shadow: 0 0 2px rgba(0, 0, 0, .35);
  transition: width .25s ease, background .25s ease;
}
.ppb-dot.is-active {
  width: 16px;
  border-radius: 3px;
  background: #fff;
}

/* 桌面端：限制宽度、抬高高度，避免整幅横幅被拉成一条细带 */
@media screen and (min-width: 769px) {
  .ppb-outer {
    max-width: var(--ppb-maxw, 780px);
    padding: 0;
    margin-bottom: 22px;
  }
  .ppb-stage {
    height: var(--ppb-h-d, 280px);
  }
  .ppb-nav { width: 34px; height: 34px; font-size: 19px; }
}

@media (prefers-reduced-motion: reduce) {
  .ppb-track { transition: none; }
}
