/* Recent Purchase Popup – layout fix */
#real_time_order, .rpp-card, #rpp-toast, #real_time_order .content,
.rpp-card .content,
#rpp-toast .content,
.recent-purchase-popup .content{
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding-right: 18px; /* 给右上角 X 让出空间 */
}
#real_time_order .pro_image { flex: 0 0 48px; width:48px; height:48px; margin-right:10px; }
#real_time_order .pro_image img { width:48px; height:48px; object-fit:cover; display:block; }

#real_time_order .title a,
.rpp-card .title a,
#rpp-toast .title a,
.recent-purchase-popup .title a{
  display:-webkit-box;
  -webkit-line-clamp:2;    /* 标题最多两行 */
  -webkit-box-orient:vertical;
  overflow:hidden;
  line-height:1.25;
  max-height:calc(1.25em * 2);
  word-break:break-word;
}
#real_time_order .time,
.rpp-card .time,
#rpp-toast .time,
.recent-purchase-popup .time{
  margin-top:2px;
  font-size:12px;
  opacity:.85;
  flex:0 0 auto;           /* 时间不被压缩 */
}
/* 移动端略微放宽 */
@media (max-width: 750px){
  #real_time_order, .rpp-card, #rpp-toast, }
/* RPP_FRONT_TWEAK_v1: 调度器“文本模板”外观修复（不干预显示/隐藏） */
#rpp-box .content{ position:relative!important; display:flex!important; flex-direction:column!important; gap:4px!important;
                   padding:12px 18px 10px 14px!important; }
#rpp-box .close{ position:absolute!important; right:10px!important; top:8px!important; line-height:1!important; opacity:.85!important; }

/* RPP_HIDE_NATIVE 2025-08-31 */

/* --- RPP_NATIVE_SKIN (visual-only) --- */
#rpp-box {
  position: fixed;              /* 固定在视口 */
  left: 16px;                   /* 对应你后台 Horizontal margin */
  bottom: 90px;                 /* 对应 Vertical margin */
  z-index: 2147483647;          /* 覆盖底部 bar 与社交球 */
  min-width: 260px;
  max-width: 420px;
  width: calc(100vw - 136px);   /* 16 左边距 + 120 安全右距 */
  pointer-events: auto;
}
@media (max-width: 480px){
  #rpp-box { max-width: 92vw; width: calc(100vw - 24px); left: 12px; bottom: 84px; }
}

#rpp-box .content{
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,.18);
  padding: 12px 18px 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

#rpp-box .title a{
  color: #147bff;               /* 产品/标题颜色 */
  text-decoration: underline;   /* 如需去下划线：改为 none */
}

#rpp-box .time{
  font-size: 12px;
  opacity: .85;
}

#rpp-box .close{
  position: absolute;
  right: 10px;
  top: 8px;
  line-height: 1;
  opacity: .85;
}
/* RPP_HIDE_NATIVE_WHEN_CUSTOM — 仅当自定义弹窗存在时隐藏原生弹窗，避免双弹 */
#rpp-box-custom ~ #rpp-box,
#rpp-box-custom ~ #rpp-toast,
#rpp-box-custom ~ #real_time_order{
  display:none !important;
  visibility:hidden !important;
  opacity:0 !important;
  pointer-events:none !important;
}
