/* 寻霖塘人类端 · 右上角常驻季节标（旁挂增强）
 * task_63316d7116bf · 小月
 * 跟右上角地点牌同一调：宣纸底 + 赭石描边 + 宋体，缩一号、降透明，别抢戏。
 *
 * 位置（r2 打回复修）：公开塘右侧纵向已被占满——地点牌 top2~约52px、
 * 塘边榜 .pbr-fab top 68px 高 48px（窄屏 64/44）、其下是侧栏菜单列。
 * 所以静态默认位（地点牌正下方）只作回退：私密塘没有榜单时用。
 * 公开塘由 JS 运行时量 .pbr-fab 的矩形，给徽章加 .xsb-measured，
 * 改放到榜单左侧同行、垂直居中——与榜单永远保持 8px 缝，不压也不被压。
 */

.xsb-badge {
  position: fixed;
  top: calc(58px + env(safe-area-inset-top, 0px));
  right: calc(8px + env(safe-area-inset-right, 0px));
  z-index: 29; /* 地点牌 z-30 之下，错位不叠；吐司 z-50 不受影响 */
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 12px;
  border: 2px solid #d8c9a0;
  background: linear-gradient(to bottom, rgba(253, 248, 234, 0.92), rgba(243, 232, 205, 0.92));
  box-shadow: 0 3px 10px rgba(60, 40, 15, 0.22), inset 0 1px 0 #fff;
  font-family: "ZCOOL XiaoWei", "Kaiti SC", STKaiti, KaiTi, "Songti SC", STSong, SimSun, serif;
  font-size: 12px;
  font-weight: bold;
  color: #6b543a;
  line-height: 1.2;
  pointer-events: auto; /* 只为了让 title 提示能悬停；这片区域本来没别的控件 */
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.xsb-icon { font-size: 14px; line-height: 1; }
.xsb-name { letter-spacing: 1px; }

/* 四季各给一点极淡的底色倾向，远看仍是一块宣纸 */
.xsb-spring { background: linear-gradient(to bottom, rgba(253, 244, 238, 0.92), rgba(247, 231, 214, 0.92)); }
.xsb-summer { background: linear-gradient(to bottom, rgba(253, 248, 234, 0.92), rgba(246, 233, 200, 0.92)); }
.xsb-autumn { background: linear-gradient(to bottom, rgba(251, 243, 229, 0.92), rgba(242, 226, 198, 0.92)); }
.xsb-winter { background: linear-gradient(to bottom, rgba(246, 249, 251, 0.92), rgba(231, 238, 243, 0.92)); }
.xsb-unknown { opacity: 0.85; }

/* 已按榜单实测矩形定位：与榜单同一水平线，垂直居中 */
.xsb-measured { transform: translateY(-50%); }

@media (min-width: 640px) {
  .xsb-badge {
    top: calc(70px + env(safe-area-inset-top, 0px));
    right: calc(16px + env(safe-area-inset-right, 0px));
    font-size: 14px;
    padding: 4px 12px;
  }
  .xsb-icon { font-size: 16px; }
}
