/* ============================================================
   猫知�?- 主样式文�?   品牌色：#E05A3A | 背景�?F3EFE9 | 首页�?FDFAF6
   ============================================================ */

/* ---------- CSS Custom Properties ---------- */
:root {
  /* 品牌�?*/
  --brand: #E05A3A;
  --brand-rgb: 224, 90, 58;
  --brand-light: #E87D60;
  --brand-dark: #C4452A;
  --brand-active: #D45A38;
  --brand-gradient: linear-gradient(135deg, #E05A3A 0%, #C4452A 100%);
  --title-gradient: linear-gradient(135deg, #E05A3A 0%, #B3301E 100%);
  --primary: var(--brand);
  --hover: rgba(var(--brand-rgb), 0.08);

  /* 通用�?*/
  --color-white: #FFFFFF;

  /* 语义�?*/
  --danger: #E53935;
  --danger-bg: #FFF0F0;
  --success: #2C9B84;
  --success-bg: #E8F5F0;
  --warning: #E65100;
  --warning-bg: #FFF8F0;
  --info: #3B82F6;
  --info-bg: #F0F6FF;

  /* 文字�?*/
  --text: #4E3B2C;
  --text-secondary: #7F6E5D;
  --text-muted: #8B7968;
  --text-weak: #A89888;

  /* 背景�?*/
  --bg: #F3EFE9;
  --bg-home: #FDFAF6;
  --bg-light: #F8F5F0;
  --bg-card: #FFFFFF;
  --border: #E8DCD0;
  --border-light: rgba(224, 210, 192, 0.6);

  /* 设计令牌 */
  --transition: 0.2s ease;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 4px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);

  /* 头像圆角 */
  --avatar-radius-sm: 10px;
  --avatar-radius: 12px;
  --avatar-radius-md: 14px;
  --avatar-radius-lg: 16px;
  --avatar-radius-xl: 20px;

  /* ==================== 统一头像系统 (Unified Avatar) ==================== */
  /* 使用方式: <div class="avatar avatar--lg"> �?<img class="avatar avatar--lg" src="...">
     尺寸: xs(32) sm(34) md(40) lg(44) xl(56) 2xl(80) 3xl(96)
     变体: --image(图片色底) --danger(红色�? --info(蓝色�? --warning(橙色�? --ghost(浅色�? --circle(圆形) */
  --av-xs: 32px;
  --av-sm: 34px;
  --av-md: 40px;
  --av-lg: 44px;
  --av-xl: 56px;
  --av-2xl: 80px;
  --av-3xl: 96px;

  /* 间距 */
  --space-xs: 6px;
  --space-sm: 8px;
  --space-md: 12px;
  --space-lg: 16px;
  --space-xl: 20px;
  --space-2xl: 24px;
  --space-3xl: 32px;

  /* 导航与布局 */
  --nav-bg: rgba(243, 239, 233, 0.95);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --ease: cubic-bezier(0.2, 0.9, 0.4, 1.1);
  --nav-height: 56px;
  --nav-bar-height: 56px;
  --bottom-nav-h: 56px;
  --plaza-input-h: 60px;
  --header-height: 46px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --top-offset: 46px; /* 标题栏高度，index.html JS 会根据实�?safe-top 动态覆�?*/

  /* z-index 分层 */
  --z-base: 1;
  --z-dropdown: 1000;
  --z-sticky: 2000;
  --z-overlay: 5000;
  --z-panel: 10000;
  --z-modal: 100000;
  --z-toast: 999999;

  /* 色调标签系统 */
  --tint-orange: #FFF3E0; --tint-orange-text: #E65100;
  --tint-blue: #E3F2FD; --tint-blue-text: #1565C0;
  --tint-green: #E8F5E9; --tint-green-text: #2E7D32;
  --tint-red: #FFEBEE; --tint-red-text: #C62828;
  --tint-purple: #F3E5F5; --tint-purple-text: #6A1B9A;
  --tint-yellow: #FFF8E1; --tint-yellow-text: #F59E0B;
  --tint-pink: #FFF5F0; --tint-pink-text: #AD1457;

  /* 组件微背�?*/
  --input-bg: #FAF7F4;
  --input-border: #E8DDD2;
  --card-nested: #FBF7F2;
  --card-nested-active: #F0E2D4;
  --card-nested-border: #D5C8B5;
  --list-pinned: #FFF7F0;
  --list-muted: #F5F0E8;
  --toggle-bg: #D5C4B4;

  /* 聊天气泡 */
  --bubble-sent: #FBE5D6;
  --bubble-failed: #e0e0e0;
  --bubble-failed-text: #999;

  /* 推广/礼品 */
  --promo-gradient: linear-gradient(135deg, #FFF5F0 0%, #FFEDE4 40%, #FFE8D6 100%);
  --promo-border: #FFDCC5;
  --promo-title: #4E3B2C;
  --promo-accent: #C4452A;

  /* 协议弹窗 */
  --policy-title: #4E3B2C;
  --policy-text: #6B5D4F;
  --policy-close-bg: #F5F0EB;
  --policy-close-color: #8B7355;
  --policy-close-active: #E8DDD2;
}

/* ============================================================
   深色模式
   ============================================================ */
.dark-mode {
  --brand: #E87D60;
  --brand-rgb: 232, 125, 96;
  --brand-light: #F0A090;
  --brand-dark: #D46540;
  --brand-active: #D87055;
  --brand-gradient: linear-gradient(135deg, #E87D60 0%, #D46540 100%);
  --title-gradient: linear-gradient(135deg, #E87D60 0%, #C05530 100%);
  --hover: rgba(232, 125, 96, 0.15);

  --text: #E8E0D5;
  --text-secondary: #B5A392;
  --text-muted: #9A8A7A;
  --text-weak: #7F6E5D;

  --bg: #1A1815;
  --bg-home: #1E1C19;
  --bg-light: #24211D;
  --bg-card: #2A2723;
  --border: #3A3530;
  --border-light: rgba(58, 53, 48, 0.6);

  --danger-bg: #3A1515;
  --success-bg: #152A22;
  --warning-bg: #2A1A0A;
  --info-bg: #0A1A2A;

  --shadow-sm: 0 1px 4px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);

  --nav-bg: rgba(26, 24, 21, 0.95);
  --color-white: #FFFFFF;

  /* 色调标签 - 深色 */
  --tint-orange: rgba(232,125,96,0.12); --tint-orange-text: #F0A090;
  --tint-blue: rgba(100,180,255,0.1); --tint-blue-text: #90CAF9;
  --tint-green: rgba(100,200,130,0.1); --tint-green-text: #A5D6A7;
  --tint-red: rgba(255,100,100,0.1); --tint-red-text: #EF9A9A;
  --tint-purple: rgba(180,130,210,0.1); --tint-purple-text: #CE93D8;
  --tint-yellow: rgba(255,200,60,0.1); --tint-yellow-text: #FFD54F;
  --tint-pink: rgba(232,125,96,0.1); --tint-pink-text: #F0A090;

  /* 组件微背�?- 深色 */
  --input-bg: #24211D;
  --input-border: #3A3530;
  --card-nested: #2D2824;
  --card-nested-active: #3A3028;
  --card-nested-border: #4A3F35;
  --list-pinned: #2A2218;
  --list-muted: #22201D;
  --toggle-bg: #4A3F35;

  /* 聊天气泡 - 深色 */
  --bubble-sent: #3A2820;
  --bubble-failed: #3A3030;
  --bubble-failed-text: #8A7A7A;

  /* 推广/礼品 - 深色 */
  --promo-gradient: linear-gradient(135deg, #2A1F18 0%, #251A14 40%, #201510 100%);
  --promo-border: #3A2A20;
  --promo-title: #E8E0D5;
  --promo-accent: #F0A090;

  /* 协议弹窗 - 深色 */
  --policy-title: #E8E0D5;
  --policy-text: #B5A392;
  --policy-close-bg: #2A2723;
  --policy-close-color: #9A8A7A;
  --policy-close-active: #3A3530;
}

/* 深色模式：标题栏按钮 */
.dark-mode .header-icon-btn {
  background: rgba(42, 39, 35, 0.85);
  border-color: rgba(232, 125, 96, 0.15);
  color: var(--brand);
}
.dark-mode .header-icon-btn:hover {
  background: rgba(42, 39, 35, 0.95);
  border-color: rgba(232, 125, 96, 0.25);
}
.dark-mode .cat-tag-btn {
  background: rgba(42, 39, 35, 0.85);
  border-color: rgba(232, 125, 96, 0.15);
}
.dark-mode .cat-tag-btn:hover {
  background: rgba(42, 39, 35, 0.95);
  border-color: rgba(232, 125, 96, 0.25);
}
.dark-mode .page-header {
  border-bottom-color: rgba(232, 125, 96, 0.04);
  box-shadow: 0 1px 8px rgba(0,0,0,0.15);
}
.dark-mode .profile-nickname { color: #4E3B2C; }

/* ==================== 统一头像系统 (Unified Avatar) ==================== */
/* 使用方式: <div class="avatar avatar--lg"> �?<img class="avatar avatar--lg" src="...">
   尺寸: xs(32) sm(34) md(40) lg(44) xl(56) 2xl(80) 3xl(96)
   变体: --image(图片色底) --danger(红色�? --info(蓝色�? --warning(橙色�? --ghost(浅色�? --circle(圆形) */
.avatar {
  --av-size: var(--av-lg);
  --av-radius: var(--avatar-radius);
  width: var(--av-size);
  height: var(--av-size);
  border-radius: var(--av-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--brand-gradient);
  color: rgba(255,255,255,0.85);
  font-weight: 600;
  user-select: none;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.avatar svg { width: 55%; height: 55%; stroke: currentColor; }
img.avatar { display: block; object-fit: cover; }

.avatar--xs  { --av-size: var(--av-xs); --av-radius: var(--avatar-radius-sm); font-size: 0.7rem; }
.avatar--sm  { --av-size: var(--av-sm); --av-radius: var(--avatar-radius-sm); font-size: 0.8rem; }
.avatar--md  { --av-size: var(--av-md); --av-radius: var(--avatar-radius-sm); font-size: 0.85rem; }
.avatar--lg  { --av-size: var(--av-lg); --av-radius: var(--avatar-radius); font-size: 1rem; }
.avatar--xl  { --av-size: var(--av-xl); --av-radius: var(--avatar-radius-md); font-size: 1.3rem; }
.avatar--2xl { --av-size: var(--av-2xl); --av-radius: var(--avatar-radius-xl); font-size: 1.6rem; }
.avatar--3xl { --av-size: var(--av-3xl); --av-radius: var(--avatar-radius-xl); font-size: 2rem; }

/* 变体：背景色 */
.avatar--image   { background: linear-gradient(135deg, var(--card-nested), var(--card-nested-active)); color: var(--text-weak); }  /* img 占位底色 */
.avatar--danger  { background: var(--danger); }
.avatar--info    { background: var(--info); }
.avatar--warning { background: var(--warning); }
.avatar--system  { background: var(--tint-yellow-text); font-size: 0; }
.avatar--ghost   { background: var(--bg-light); color: var(--text-weak); }
.avatar--ghost-dark { background: var(--bg-light); }
.avatar--circle  { --av-radius: var(--avatar-radius-xl); border-radius: var(--avatar-radius-xl); }

.avatar--sm.avatar--ghost { font-size: 0.85rem; font-weight: 700; }
/* ==================== 统二头像系统结束 ==================== */

/* ---------- Reset ---------- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; width: 100%; }
html, body { height: 100%; overflow: hidden; overscroll-behavior: none; touch-action: manipulation; }
body {
  width: 100%;
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: auto;
  -moz-osx-font-smoothing: auto;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
input, textarea { -webkit-user-select: text; user-select: text; }
a { color: var(--brand); text-decoration: none; }
img { max-width: 100%; display: block; }
input, textarea, button, select { font-family: inherit; font-size: inherit; outline: none; border: none; background: none; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
ul, li { list-style: none; }
*::-webkit-scrollbar { display: none; }

/* ---------- App Container ---------- */
#app {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ---------- Panels ---------- */
.panel-scroller {
  flex: 1;
  overflow: hidden;
  position: relative;
}
.panel-track {
  display: flex;
  width: 500vw;
  height: 100%;
  transition: transform 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
  will-change: transform;
}
.panel-track > .panel {
  display: block;
  flex-shrink: 0;
  width: 100vw;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: none;
  -webkit-overflow-scrolling: touch;
  position: relative;
  padding-top: var(--safe-top);
}
.panel { display: none; }
.panel.active { display: block; }

#app > .panel:not(#homePanel):not(#plazaPanel):not(#friendsPanel):not(#petsPanel):not(#profilePanel) {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 300;
  width: auto;
  height: auto;
  overflow-y: auto;
  flex-shrink: initial;
  background: var(--bg);
  background-image: radial-gradient(ellipse at 50% 0%, rgba(224,90,58,0.02) 0%, transparent 60%),
                    radial-gradient(ellipse at 80% 100%, rgba(180,140,100,0.03) 0%, transparent 50%);
}

@keyframes fadeIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }

/* ============================================================
   触摸按压反馈 (iOS highlight + Android ripple)
   ============================================================ */
/* iOS 按压变暗 �?卡片、按钮、列表项 */
.article-card:active,
.pet-item:active,
.share-teaser:active,
.plaza-bubble:active,
.chat-bubble:active {
  background: rgba(0,0,0,0.04) !important;
  transition: background 0s !important;
}

/* 按钮通用按压�?*/
.btn:active,
.btn-sm:active,
.header-icon-btn:active,
.cat-tag-btn:active {
  filter: brightness(0.92);
  transition: filter 0s;
}

/* 底部导航按压 */
.nav-item:active {
  opacity: 0.7;
  transition: opacity 0s;
}

/* Android 涟漪 �?通过 ::before 伪元�?*/
.article-card,
.pet-item,
.share-teaser,
.btn,
.btn-sm {
  position: relative;
  overflow: hidden;
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}
.article-card::before,
.pet-item::before,
.share-teaser::before,
.btn::before,
.btn-sm::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--ripple-x, 50%) var(--ripple-y, 50%), rgba(0,0,0,0.08) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0s;
  pointer-events: none;
  z-index: var(--z-base);
}
.article-card:active::before,
.pet-item:active::before,
.share-teaser:active::before,
.btn:active::before,
.btn-sm:active::before {
  opacity: 1;
  transition: opacity 0s;
}

/* ============================================================
   0. 状态栏背景保护层（所有页面对齐）
   ============================================================ */
#statusBarBg {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--safe-top);
  background: var(--bg);
  z-index: 5000;
  pointer-events: none;
}

/* ============================================================
   1. 顶部标题�?   ============================================================ */
.page-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  min-height: var(--header-height);
  padding: 0;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  z-index: 100;
  border-bottom: 1px solid rgba(224,90,58,0.06);
  box-shadow: 0 1px 8px rgba(78,59,44,0.03);
}
.header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 8px 20px 6px;
}
.header-left { flex: 1; display: flex; flex-direction: column; min-width: 0; overflow: hidden; }
.page-title {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.7px;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  line-height: 1.25;
}
.page-title .title-text {
  background: var(--title-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.header-right { display: flex; align-items: center; gap: 8px; padding-top: 2px; }

/* 藏宝图悬浮按钮 */
.treasure-fab {
  display: none;
  position: fixed;
  top: calc(var(--top-offset) + 12px);
  left: 12px;
  z-index: var(--z-dropdown);
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}
.treasure-fab.show { display: flex; }
.treasure-fab-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: linear-gradient(135deg, #E05A3A, #E88B60);
  color: #fff;
  border: none;
  border-radius: 20px;
  box-shadow: 0 3px 12px rgba(224,90,58,0.35);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: grab;
  white-space: nowrap;
  transition: transform 0.15s, box-shadow 0.15s;
  user-select: none;
  touch-action: none;
}
.treasure-fab-btn:active { transform: scale(0.95); }
.treasure-fab-icon { font-size: 1rem; flex-shrink: 0; }
.treasure-fab-cd {
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  min-width: 40px;
  text-align: center;
}
.treasure-fab-label { font-size: 0.72rem; opacity: 0.9; }
.treasure-fab-expand {
  display: none;
  background: #fff;
  border-radius: 12px;
  padding: 10px 14px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.15);
  max-width: 220px;
  text-align: left;
}
.treasure-fab.expanded .treasure-fab-expand { display: block; }
.treasure-fab-target {
  font-size: 0.72rem;
  color: #4E3B2C;
  line-height: 1.5;
  margin-bottom: 8px;
  word-break: break-all;
}
.treasure-fab-discard {
  display: block;
  width: 100%;
  padding: 5px 0;
  background: #f5f5f5;
  color: #999;
  border: none;
  border-radius: 8px;
  font-size: 0.7rem;
  cursor: pointer;
  text-align: center;
}
.treasure-fab-discard:active { background: #e8e8e8; color: #666; }

.minor-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  background: linear-gradient(135deg, var(--tint-orange), #FFE0B2);
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 500;
  border-bottom: 1px solid #FFCC80;
  text-align: center;
  position: sticky;
  top: 0;
  z-index: 101;
}
.minor-banner-icon { font-size: 1rem; flex-shrink: 0; }
.minor-banner-text { flex: 1; }

/* ---------- Unified circular icon buttons ---------- */
.icon-btn, .chat-plus-btn, #chatSendBtn,
.plaza-send-btn, .plaza-add-btn {
  display: flex; align-items: center; justify-content: center;
  border: none; cursor: pointer;
  background: var(--brand-gradient); color: #fff;
  border-radius: 50%; box-shadow: 0 3px 12px rgba(224,90,58,0.35);
  transition: transform 0.15s var(--ease), box-shadow 0.2s;
  user-select: none; -webkit-tap-highlight-color: transparent;
}
.icon-btn:active, .chat-plus-btn:active, #chatSendBtn:active,
.plaza-send-btn:active, .plaza-add-btn:active {
  transform: scale(0.92); box-shadow: 0 2px 8px rgba(224,90,58,0.2);
}
.icon-btn--sm { width: 38px; height: 38px; font-size: 16px; }
.icon-btn--md { width: 40px; height: 40px; font-size: 18px; }
.icon-btn--lg { width: 44px; height: 44px; font-size: 20px; }

.header-icon-btn {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.8);
  border: 1px solid rgba(224,90,58,0.1);
  color: var(--brand);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  position: relative;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.header-icon-btn:hover { background: rgba(255,255,255,0.95); border-color: rgba(224,90,58,0.2); }
.header-icon-btn:active { transform: scale(0.9); background: rgba(224,90,58,0.08); }
.dropdown-menu {
  visibility: hidden;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
  pointer-events: none;
}
.dropdown-menu.show {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.dropdown-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  font-size: 0.85rem; color: var(--text);
  cursor: pointer; border-radius: 10px;
  transition: background 0.12s;
  white-space: nowrap;
}
.dropdown-item:active { background: var(--bg-light); }

/* 分类标签按钮 */
.cat-tag-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(224,90,58,0.1);
  background: rgba(255,255,255,0.8);
  color: var(--brand);
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
}
.cat-tag-btn:hover { background: rgba(255,255,255,0.95); border-color: rgba(224,90,58,0.2); }
.cat-tag-btn:active { background: rgba(224,90,58,0.08); transform: scale(0.9); }

.header-online-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.64rem;
  color: var(--text-secondary);
  background: rgba(76,175,80,0.06);
  padding: 1px 10px;
  border-radius: 20px;
  white-space: nowrap;
  line-height: 1.5;
  transition: background 0.3s, color 0.3s;
}
.header-online-badge.offline {
  background: rgba(139,121,104,0.06);
  color: var(--text-weak);
}
.header-online-badge.offline .header-online-dot {
  background: var(--text-weak);
  box-shadow: none;
  animation: none;
}
.header-online-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--success);
  display: inline-block;
  flex-shrink: 0;
  box-shadow: 0 0 4px rgba(76,175,80,0.35);
  animation: headerDotPulse 2s ease-in-out infinite;
}
@keyframes headerDotPulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }

/* 分类弹窗 */
.cat-tag-popover {
  position: fixed;
  top: calc(var(--top-offset) + 4px);
  left: 50%;
  transform: translateX(-50%);
  width: min(calc(100vw - 24px), 540px);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 10px;
  background: var(--bg-card);
  border-radius: 14px;
  box-shadow: var(--shadow-md, 0 8px 32px rgba(78,59,44,0.16));
  border: 1px solid var(--border);
  z-index: var(--z-toast);
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.18s ease, visibility 0.18s ease;
}
.cat-tag-popover.active {
  visibility: visible;
  opacity: 1;
}
.cat-tag-overlay {
  position: fixed;
  top: 0; left: 0; right: 0;
  bottom: var(--bottom-nav-h);
  z-index: var(--z-panel);
  display: none; background: transparent;
}
.cat-tag-overlay.show { display: block; }
.cat-tag-opt {
  padding: 10px 8px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: var(--bg-light);
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.12s, border-color 0.12s;
}
.cat-tag-opt:active { transform: scale(0.95); }
.cat-tag-opt.active {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand-dark);
}

/* ============================================================
   2. 首页便签卡片�?   ============================================================ */
#homePanel {
  padding: 0;
  padding-top: var(--safe-top);
  padding-bottom: var(--bottom-nav-h);
  min-height: 100vh;
  background: var(--bg-home);
  position: relative;
}

.sticky-wall {
  position: relative;
  width: 100%;
  min-height: calc(100vh - 140px);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  z-index: var(--z-base);
}
.sticky-wall::-webkit-scrollbar { display: none; }

.sticky-card {
  position: absolute;
  width: 160px;
  min-height: 180px;
  border-radius: 0;
  padding: 0;
  cursor: grab;
  -webkit-user-select: none;
  user-select: none;
  touch-action: none;
  display: flex;
  flex-direction: column;
  -webkit-touch-callout: none;
  box-shadow:
    0 2px 6px rgba(78,59,44,0.08),
    0 0 0 1px rgba(78,59,44,0.03),
    inset 0 -1px 0 rgba(0,0,0,0.02);
  transition: transform 0.25s var(--ease), box-shadow 0.25s ease;
  animation: stickyDrop 0.6s cubic-bezier(0.22, 0.9, 0.36, 1) both;
}
.sticky-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 10%, rgba(224,90,58,0.15) 30%, rgba(224,90,58,0.08) 70%, transparent 90%);
  opacity: 0.6;
}
.sticky-card:hover {
  box-shadow:
    0 12px 28px rgba(78,59,44,0.12),
    0 3px 10px rgba(78,59,44,0.06),
    inset 0 -1px 0 rgba(0,0,0,0.02);
  z-index: 10;
  transform: translateY(-2px);
}
.sticky-card:active { transform: scale(0.95) !important; }
.sticky-card.dragging {
  cursor: grabbing;
  transition: none;
  box-shadow:
    0 20px 40px rgba(0,0,0,0.18),
    0 6px 16px rgba(0,0,0,0.10);
  transform: scale(1.04);
  z-index: var(--z-dropdown);
  pointer-events: none;
}

/* 分类颜色 */
.sticky-card.cat-idle { border-top: 4px solid #2E7D32; }       /* 闲置-绿 */
.sticky-card.cat-job { border-top: 4px solid #1565C0; }         /* 求职-蓝 */
.sticky-card.cat-help { border-top: 4px solid #C62828; }        /* 求助-红 */
.sticky-card.cat-vote { border-top: 4px solid #6A1B9A; }        /* 投票-紫 */
.sticky-card.cat-deal { border-top: 4px solid #E65100; }        /* 活动-橙 */
.sticky-card.cat-rent { border-top: 4px solid #6D4C41; }        /* 房屋-棕 */
.sticky-card.cat-carpool { border-top: 4px solid #546E7A; }     /* 车辆-灰 */
.sticky-card.cat-dating { border-top: 4px solid #AD1457; }      /* 缘分-粉 */
.sticky-card.cat-repair { border-top: 4px solid #F59E0B; }      /* 其他-黄 */
.sticky-card.cat-pet { border-top: 4px solid #E91E63; }         /* 宠物-暖粉 */

/* 图钉 */
.pushpin-hit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  position: absolute;
  top: -8px; right: -8px;
  z-index: 10;
  cursor: pointer;
}
.sticky-card .pushpin {
  width: 12px; height: 12px;
  border-radius: 50%;
  background: radial-gradient(circle at 38% 32%, #FF6B6B 0%, var(--danger) 45%, #B71C1C 100%);
  box-shadow:
    0 2px 4px rgba(0,0,0,0.2),
    inset 0 1px 2px rgba(255,255,255,0.5),
    inset 0 -1px 2px rgba(0,0,0,0.15);
  position: relative;
  cursor: pointer;
  z-index: 5;
  transition: transform 0.12s;
}
.sticky-card .pushpin::before {
  content: '';
  position: absolute;
  top: 2px; left: 3px;
  width: 5px; height: 3px;
  background: radial-gradient(ellipse, rgba(255,255,255,0.7), transparent);
  border-radius: 50%;
}
.sticky-card .pushpin::after {
  content: '';
  position: absolute;
  bottom: -6px; left: 50%;
  transform: translateX(-50%);
  width: 1.5px; height: 6px;
  background: linear-gradient(to bottom, #9E9E9E, #BDBDBD 40%, #E0E0E0 100%);
  border-radius: 1px;
  box-shadow: 0 0 1px rgba(0,0,0,0.1);
}
.pushpin-hit:active .pushpin { transform: translateY(2px) scale(0.85); }

.sticky-card-body { padding: 14px 12px 12px; flex: 1; display: flex; flex-direction: column; }
.sticky-cat-badge {
  display: inline-block; align-self: flex-start;
  font-size: 0.65rem; font-weight: 600; color: #fff;
  padding: 2px 8px; border-radius: 6px; margin-bottom: 4px;
  background: var(--brand);
}
.sticky-card-body .sticky-title {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
  color: #000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-rendering: optimizeLegibility;
}
.sticky-card-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--border);
  position: relative;
}
.sticky-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; -webkit-user-drag: none; }
.sticky-card-img + .sticky-card-body { padding-top: 10px; }
.sticky-excerpt {
  font-size: 0.75rem;
  line-height: 1.5;
  color: #222;
  margin-top: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
  text-rendering: optimizeLegibility;
  letter-spacing: 0.01em;
}
.sticky-card-img ~ .sticky-card-body .sticky-excerpt { -webkit-line-clamp: 1; }

.sticky-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 6px;
  gap: 4px;
}
.sticky-footer .meta {
  font-size: 0.7rem;
  color: #555;
  flex-shrink: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sticky-footer .btn-edit,
.sticky-footer .btn-delete {
  padding: 2px 7px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255,255,255,0.45);
  color: var(--text-secondary);
  font-size: 0.6rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
  white-space: nowrap;
  flex-shrink: 0;
  margin-left: 3px;
}
.sticky-footer .btn-edit:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
.sticky-footer .btn-delete:hover { background: var(--danger); color: #fff; border-color: var(--danger); }
.sticky-footer .btn-edit:active,
.sticky-footer .btn-delete:active { transform: scale(0.93); }

/* 便签纸纹�?*/

/* 马卡龙风格便�?*/

/* 掉落动画 */
.sticky-card.falling {
  animation: stickyFall 0.8s cubic-bezier(0.22, 0.9, 0.6, 1) forwards;
  pointer-events: none;
}
.sticky-card.fallen {
  opacity: 0.45;
  filter: grayscale(0.3);
  pointer-events: none;
  cursor: default;
}

@keyframes stickyDrop {
  0%   { opacity: 0; transform: translateY(-60px) scale(0.85); }
  60%  { opacity: 1; transform: translateY(6px) scale(1.02); }
  100% { opacity: 1; transform: translateY(0); }
}
@keyframes stickyFall {
  0%   { opacity: 1; transform: translateY(0) scale(1); }
  30%  { opacity: 1; transform: translateY(10px) scale(1.02); }
  100% { opacity: 0; transform: translateY(400px) scale(0.8); }
}

/* ============================================================
   3. 底部导航�?   ============================================================ */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--nav-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  display: flex;
  justify-content: space-around;
  align-items: flex-end;
  padding: 6px 12px calc(var(--safe-bottom) + 8px);
  border-top: 1px solid var(--border-light);
  box-shadow: 0 -2px 16px rgba(78,59,44,0.04);
  z-index: var(--z-sticky);
}
.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--text-secondary);
  font-size: 0.65rem;
  padding: 6px 8px;
  min-width: 50px;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}
.nav-item svg { width: 28px; height: 28px; transition: all 0.2s ease; }
.nav-item.active { color: var(--brand-active); font-weight: 600; }
.nav-item.active svg { transform: scale(1.1); }
.nav-label { font-size: 0.6rem; font-weight: 500; }

/* ============================================================
   4. 广场消息
   ============================================================ */
#plazaPanel { background: var(--bg); }
#plazaPanel.active { display: flex; flex-direction: column; overflow: hidden; }
.plaza-container {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}
.plaza-messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 8px 12px;
  padding-bottom: var(--plaza-input-h);
  -webkit-overflow-scrolling: touch;
  background: var(--bg);
  position: relative;
}
.plaza-msg { display: flex; flex-direction: column; padding: 2px 0; }
.plaza-msg-row { display: flex; }
.plaza-msg.own .plaza-msg-row { flex-direction: row-reverse; }

.plaza-time-divider {
  display: flex; align-items: center; justify-content: center;
  padding: 8px 0 10px;
}
.plaza-time-divider span {
  font-size: 0.68rem; color: var(--text-muted);
  opacity: 0.7; white-space: nowrap;
}

.plaza-avatar {
  flex-shrink: 0;
}
.plaza-body { flex: 1; min-width: 0; }
.plaza-msg:not(.own) .plaza-avatar { margin-right: 8px; }
.plaza-msg.own .plaza-avatar { margin-left: 8px; }
.plaza-msg.own .plaza-body { display: flex; flex-direction: column; align-items: flex-end; }

.plaza-author {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 1px;
  padding-left: 2px;
}
.plaza-author-loc {
  font-size: 0.6rem;
  font-weight: 400;
  color: var(--text-weak);
  margin-left: 2px;
}
.plaza-msg.own .plaza-author { color: var(--brand); padding-left: 0; padding-right: 2px; }
.plaza-msg.own .plaza-author-loc { color: rgba(224,90,58,0.45); }

.plaza-bubble {
  display: inline-block;
  max-width: 80%;
  padding: 8px 14px;
  border-radius: 12px;
  font-size: 0.92rem;
  line-height: 1.55;
  word-wrap: break-word;
  white-space: pre-wrap;
  animation: bubbleIn 0.25s cubic-bezier(0.2, 0.9, 0.4, 1.1) both;
}
.plaza-msg:not(.own) .plaza-bubble {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
  border-bottom-left-radius: 4px;
}
.plaza-msg.own .plaza-bubble {
  background: var(--bubble-sent);
  color: var(--text);
  border-bottom-right-radius: 4px;
}

.plaza-content { display: block; }

.plaza-img {
  display: block;
  max-width: min(260px, 65vw);
  max-height: 300px;
  width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 4px 0;
  cursor: pointer;
  object-fit: cover;
  transition: transform 0.15s ease;
}
.plaza-img:active { transform: scale(0.97); }

/* 图片全屏查看 */
.plaza-img-viewer {
  position: fixed; inset: 0; z-index: var(--z-toast);
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.92);
  cursor: pointer;
}
.plaza-img-viewer img {
  max-width: 95vw;
  max-height: 95vh;
  object-fit: contain;
  border-radius: 4px;
  animation: imgZoomIn 0.2s ease;
}
@keyframes imgZoomIn { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: scale(1); } }

/* 广场消息撤回 */
.plaza-recalled { color: #999; font-style: italic; font-size: 0.85rem; }
.plaza-msg.recalled .plaza-bubble { background: var(--bg-light); color: var(--text-muted); }
.plaza-msg.recalled .plaza-content { opacity: 0.5; }

/* 广场消息发送失�?*/
.plaza-msg.failed .plaza-bubble {
  background: var(--bubble-failed); color: var(--bubble-failed-text);
  border-color: #ccc;
}
.plaza-msg.failed .plaza-bubble::after {
  content: "发送失败，点击重试";
  display: block;
  font-size: 0.7rem;
  color: #c0392b;
  margin-top: 4px;
  white-space: nowrap;
}
.plaza-msg.own.failed .plaza-bubble { background: var(--bubble-failed); }

.plaza-input-area {
  position: fixed;
  bottom: var(--bottom-nav-h);
  left: 0;
  right: 0;
  z-index: var(--z-sticky);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--nav-bg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-top: 1px solid var(--border);
}
.plaza-input {
  flex: 1;
  min-height: 40px;
  max-height: 120px;
  padding: 10px 16px;
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: 16px;
  color: var(--text);
  font-size: 0.9rem;
  font-family: inherit;
  line-height: 1.4;
  resize: none;
  overflow-y: hidden;
}
.plaza-input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.plaza-input::placeholder { color: var(--text-weak); }

.plaza-send-btn, .plaza-add-btn { flex-shrink: 0; }
.plaza-send-btn { width: 44px; height: 44px; font-size: 20px; }
.plaza-add-btn { width: 40px; height: 40px; font-size: 18px; }
.plaza-empty { text-align: center; color: var(--text-muted); padding: 48px 20px; font-size: 0.88rem; }

.plaza-to-bottom {
  position: sticky;
  bottom: 12px;
  width: 40px;
  height: 40px;
  margin-left: auto;
  margin-right: 12px;
  border-radius: 50%;
  background: var(--brand-gradient);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(224,90,58,0.45);
  z-index: 5;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.plaza-to-bottom.show { display: flex; }
.plaza-to-bottom:active { transform: scale(0.9); box-shadow: 0 1px 6px rgba(224,90,58,0.3); }

/* +功能菜单 */
.add-menu-overlay { position: fixed; inset: 0; z-index: var(--z-panel); visibility: hidden; pointer-events: none; background: rgba(0,0,0,0.25); animation: menuFadeIn 0.2s var(--ease); }
@keyframes menuFadeIn { from { opacity: 0; } to { opacity: 1; } }
.add-menu-overlay.show { visibility: visible; pointer-events: auto; }
.add-menu-panel {
  position: fixed;
  bottom: calc(var(--bottom-nav-h) + 80px);
  left: 12px;
  right: 12px;
  z-index: var(--z-panel);
  display: flex; justify-content: center;
  visibility: hidden; pointer-events: none;
  will-change: transform, opacity;
}
.add-menu-panel.show { visibility: visible; pointer-events: auto; animation:menuSlideUp 0.25s var(--ease); }
@keyframes menuSlideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.add-menu-inner {
  display: flex; gap: 0;
  background: var(--bg-card);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(78,59,44,0.14);
  border: 1px solid rgba(224,90,58,0.12);
  padding: 6px 0;
  width: 100%;
  justify-content: space-around;
}
.add-menu-item {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 8px 0; cursor: pointer;
  transition: background 0.15s;
  border-radius: 12px;
  flex: 1;
  max-width: 80px;
}
.add-menu-item:active { background: var(--card-nested-active); }
.add-menu-icon { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.add-menu-icon svg { width: 20px; height: 20px; stroke-width: 2; }
.add-menu-icon.share-icon { background: var(--tint-blue); color: var(--info); }
.add-menu-icon.image-icon { background: var(--tint-green); color: var(--tint-green-text); }
.add-menu-icon.emoji-icon { background: var(--tint-purple); color: var(--tint-purple-text); }
.add-menu-icon.block-icon { background: var(--tint-red); color: var(--danger); }
.add-menu-label { font-size: 0.68rem; color: var(--text-muted); font-weight: 500; white-space: nowrap; }

/* ============================================================
   4.5 广场搜索�?   ============================================================ */
.header-search-bar { max-height: 0; overflow: hidden; transition: max-height 0.3s ease, padding 0.3s ease; padding: 0 12px; background: var(--bg); }
.header-search-bar.active { max-height: 180px; padding: 10px 12px; }
.search-mode-row { display: flex; gap: 10px; }
.search-mode-pill { flex: 1; text-align: center; padding: 8px 0; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; font-size: 0.85rem; font-weight: 500; color: var(--text-secondary); cursor: pointer; transition: all 0.2s; }
.search-mode-pill:active { transform: scale(0.97); }
.search-mode-pill.active { background: var(--brand); color: #fff; border-color: var(--brand); }
.search-input-wrapper { display: flex; align-items: center; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 8px 12px; margin-top: 8px; }
.search-input-wrapper input { flex: 1; border: none; background: transparent; font-size: 0.9rem; outline: none; color: var(--text); margin-left: 8px; }
.search-input-wrapper input::placeholder { color: var(--text-weak); }
.input-clear-btn { width: 22px; height: 22px; border: none; background: var(--border); border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--text-muted); transition: all 0.15s; margin-left: 6px; }
.input-clear-btn:hover { background: var(--text-weak); color: #fff; }
.input-clear-btn:active { transform: scale(0.9); }
.preset-search-row { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.monitor-input-wrapper { display: flex; align-items: center; background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 4px 4px 4px 12px; }
.monitor-input-wrapper input { flex: 1; border: none; background: transparent; font-size: 0.9rem; outline: none; color: var(--text); }
.monitor-input-wrapper input::placeholder { color: var(--text-weak); }
.monitor-start-btn { padding: 8px 16px; background: var(--brand); color: #fff; border: none; border-radius: 12px; font-size: 0.85rem; cursor: pointer; white-space: nowrap; font-weight: 500; transition: all 0.2s; }
.monitor-start-btn:active { transform: scale(0.95); background: var(--brand-dark); }
.monitor-status { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--tint-yellow); border: 1px solid var(--promo-border); border-radius: 12px; font-size: 0.85rem; color: var(--tint-yellow-text); }
.monitor-stop-btn { padding: 4px 12px; background: transparent; border: 1px solid var(--danger); color: var(--danger); border-radius: 8px; font-size: 0.8rem; cursor: pointer; margin-left: auto; transition: all 0.2s; }
.monitor-stop-btn:active { background: var(--tint-red); }
.search-highlight { background: #FFE082; color: var(--text); padding: 0 2px; border-radius: 3px; }
.search-alert { animation: search-glow 0.8s ease-in-out infinite; }
.search-alert svg { animation: search-pulse 0.6s ease-in-out infinite; }
@keyframes search-glow { 0%,100% { box-shadow: 0 0 4px rgba(229,57,53,0.2); } 50% { box-shadow: 0 0 16px rgba(229,57,53,0.5); } }
@keyframes search-pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.15); } }

/* ============================================================
   5. 个人中心
   ============================================================ */
#profilePanel { overflow-y: auto; padding-bottom: var(--bottom-nav-h); background: var(--bg); position: relative; z-index: var(--z-base); }
.profile-hero {
  background: linear-gradient(160deg, #E05A3A 0%, #E88B60 60%, #F5EBE0 100%);
  padding: calc(var(--top-offset) + 8px) 16px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.profile-hero::before {
  content: '';
  position: absolute;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.14) 0%, transparent 65%);
  top: -100px; right: -60px;
}
.profile-hero::after {
  content: '';
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.08) 0%, transparent 60%);
  bottom: -80px; left: 5%;
}
.profile-avatar-wrap { position: relative; z-index: var(--z-base); }
.profile-avatar {
  margin: 0 auto 12px;
  box-shadow: 0 4px 20px rgba(196,69,42,0.22), 0 0 0 1px rgba(224,90,58,0.06);
  position: relative;
  z-index: 2;
  border-radius: 20px;
  background: var(--bg-light);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.avatar.profile-avatar { background: var(--bg-light); }
.profile-avatar svg {
  color: var(--text-weak);
  width: 65%; height: 65%;
}
.profile-nickname { font-size: 1.15rem; font-weight: 800; color: var(--text); position: relative; z-index: var(--z-base); }
.profile-meta {
  display: flex; align-items: center; justify-content: center; gap: 0; margin-top: 4px;
  position: relative; z-index: var(--z-base);
}
.profile-id { font-size: 0.72rem; color: var(--text-weak); }
.profile-id::after { content: '·'; margin: 0 6px; color: var(--text-muted); }
.profile-id:empty::after { display: none; }
.profile-location {
  font-size: 0.72rem; color: rgba(45,27,16,0.5);
  display: flex; align-items: center; justify-content: center; gap: 4px; cursor: pointer;
  transition: color 0.2s ease;
}
.profile-location:hover { color: var(--brand); }
.profile-location svg { flex-shrink: 0; }
.profile-verified { display: inline-flex; align-items: center; gap: 3px; font-size: 0.68rem; color: #2E7D32; background: #E8F5E9; padding: 2px 8px; border-radius: 10px; margin-left: 8px; font-weight: 600; white-space: nowrap; }
.profile-location span { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-bio {
  font-size: 0.8rem; color: var(--text-muted); line-height: 1.5; text-align: center;
  margin-top: 8px; padding: 6px 16px; position: relative; z-index: var(--z-base);
  word-break: break-word; max-width: 260px; margin-left: auto; margin-right: auto;
}
.profile-bio.is-empty { color: var(--text-weak); font-style: italic; }
.profile-menu {
  margin: 14px 16px 0;
  background: var(--bg-card);
  border-radius: 20px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 8px rgba(78,59,44,0.06);
}
.menu-item {
  display: flex; align-items: center;
  padding: 16px;
  transition: background 0.2s ease;
  cursor: pointer;
}
.menu-item:active { background: var(--bg-light); }
.menu-item + .menu-item { border-top: 1px solid var(--border); }
.menu-item-icon {
  width: 42px; height: 42px;
  border-radius: 12px;
  background: var(--bg-light);
  display: flex; align-items: center; justify-content: center;
  margin-right: 14px;
  flex-shrink: 0;
  color: var(--text-secondary);
}
.menu-item-text { flex: 1; font-size: 0.94rem; color: var(--text); font-weight: 500; }
.menu-item-arrow { color: var(--text-weak); font-size: 16px; font-weight: 300; }
.menu-item-badge {
  font-size: 0.68rem; padding: 2px 10px; border-radius: 10px;
  background: var(--brand); color: #fff; margin-right: 8px;
}
.logout-btn {
  display: block; width: 100%; margin: 20px 0;
  padding: 14px;
  background: var(--bg-card);
  color: var(--danger);
  font-size: 0.94rem;
  font-weight: 600;
  border-radius: 20px;
  border: 1px solid var(--danger);
  transition: all 0.2s ease;
}
.logout-btn:active { background: var(--tint-red); transform: scale(0.98); }

/* ============================================================
   6. 好友面板
   ============================================================ */
#friendsPanel { padding-bottom: var(--bottom-nav-h); background: var(--bg); }
.friends-tabs {
  display: flex;
  background: var(--bg);
  margin: 4px 0 0;
  border-radius: 0;
  padding: 6px 12px;
  border-bottom: 1px solid var(--border);
  gap: 4px;
}
.friends-tab {
  flex: 1;
  text-align: center;
  padding: 10px 12px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.friends-tab.active { background: var(--brand); color: #F8F5F0; font-weight: 600; }
.friends-content { padding: 0; }
.friends-list, .friend-requests, .friend-groups { padding: 0; }
.friend-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 12px; margin: 4px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--avatar-radius);
  box-shadow: 0 1px 3px rgba(78,59,44,0.04);
  cursor: pointer;
  transition: background 0.15s;
}
.friend-item:active { background: var(--bg-light); }

.friend-info { flex: 1; min-width: 0; }
.friend-name { font-size: 0.92rem; font-weight: 600; color: var(--text); }
.friend-remark-original { font-size: 0.7rem; color: var(--text-muted); margin-top: 1px; }
.friend-city { font-size: 0.7rem; color: var(--text-muted); margin-top: 2px; }
.friend-group-header {
  padding: 8px 16px 4px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 2;
}
.friend-menu-btn {
  width: 32px; height: 32px; border-radius: 8px;
  border: none; background: transparent; color: var(--text-muted);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: background 0.15s;
}
.friend-menu-btn:active { background: var(--bg-light); }
.friend-menu-pop {
  position: fixed; z-index: var(--z-panel);
  background: var(--bg-card); border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  padding: 4px; min-width: 120px;
}
.friend-menu-pop button {
  display: block; width: 100%; padding: 10px 16px;
  border: none; background: none; font-size: 0.85rem;
  color: var(--text); text-align: left; cursor: pointer;
  border-radius: 8px; font-family: inherit;
}
.friend-menu-pop button:active { background: var(--bg-light); }
.friend-menu-pop button.danger { color: var(--danger); }

.friend-requests-section { margin: 4px 0 12px; }
.friend-requests-title {
  font-size: 0.82rem; font-weight: 700; color: var(--text);
  padding: 4px 16px 8px; display: flex; align-items: center; gap: 8px;
}
.friend-requests-count {
  background: var(--danger); color: #fff; font-size: 0.7rem;
  border-radius: 10px; padding: 1px 8px; font-weight: 600;
}
.friend-request-item { cursor: default !important; background: var(--tint-pink); border-color: rgba(224,90,58,0.15); }
.friend-req-actions { display: flex; gap: 8px; flex-shrink: 0; }
.friend-req-accept, .friend-req-reject {
  padding: 7px 16px; border: none; border-radius: 8px;
  font-size: 0.8rem; font-weight: 600; cursor: pointer; transition: transform 0.12s;
}
.friend-req-accept { background: var(--brand); color: #fff; }
.friend-req-accept:active { transform: scale(0.95); }
.friend-req-reject { background: var(--bg-light); color: var(--text-muted); }
.friend-req-reject:active { transform: scale(0.95); }

.blacklist-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; margin: 2px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--avatar-radius-sm);
  transition: background 0.15s;
}
.blacklist-item:active { background: var(--bg-light); }

.blacklist-item-info { flex: 1; min-width: 0; }
.blacklist-item-name { font-size: 0.82rem; font-weight: 500; color: var(--text); }
.blacklist-item-status { font-size: 0.68rem; color: var(--danger); margin-top: 1px; }
.blacklist-unblock-btn {
  padding: 5px 12px; border-radius: 6px;
  border: 1px solid var(--border); background: var(--bg-card);
  color: var(--text-muted); font-size: 0.7rem; cursor: pointer;
  flex-shrink: 0; font-family: inherit; transition: all 0.15s;
}
.blacklist-unblock-btn:active { background: var(--danger); color: #fff; border-color: var(--danger); }

/* ---- 好友搜索浮层 ---- */
.friends-search-bar-inline {
  margin: 0 16px 12px;
  background: var(--bg-card);
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(78,59,44,0.06);
  border: 1px solid var(--border);
  overflow: hidden;
}
.friends-search-bar-row {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}
.friends-search-icon {
  color: var(--text-muted); flex-shrink: 0;
}
.friends-search-input {
  flex: 1; border: none; outline: none; font-size: 0.95rem;
  color: var(--text); background: transparent; font-family: inherit;
}
.friends-search-input::placeholder { color: var(--text-muted); }
.friends-search-clear {
  width: 28px; height: 28px; border: none; background: var(--bg-light);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: var(--text-muted); cursor: pointer; flex-shrink: 0;
}
.friends-search-cancel {
  border: none; background: var(--bg-light); color: var(--text-secondary);
  font-size: 0.85rem; font-weight: 500; cursor: pointer;
  padding: 6px 16px; border-radius: 8px; flex-shrink: 0;
  font-family: inherit; white-space: nowrap;
}
.friends-search-results {
  max-height: 360px; overflow-y: auto; padding: 4px 0;
}
.friends-search-results .empty-state {
  padding: 20px 0; font-size: 0.85rem; color: var(--text-muted);
}
.friends-search-section {
  padding: 8px 16px 4px;
  font-size: 0.72rem; font-weight: 700; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
}
.fs-result-section-title {
  padding: 12px 16px 4px;
  font-size: 0.75rem; font-weight: 700; color: var(--text-muted);
  display: flex; align-items: center; gap: 6px;
}
.fs-result-count {
  font-size: 0.65rem; font-weight: 600; color: #fff;
  background: var(--text-muted); padding: 1px 6px; border-radius: 8px;
  text-transform: none; letter-spacing: 0;
}

.fs-result-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; cursor: pointer;
  border-bottom: 1px solid rgba(0,0,0,0.03);
  transition: background 0.15s;
}
.fs-result-item:active { background: var(--bg-light); }

.fs-result-name {
  flex: 1; font-size: 0.95rem; font-weight: 500; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.fs-result-badge {
  font-size: 0.68rem; padding: 2px 8px; border-radius: 8px;
  font-weight: 500; flex-shrink: 0;
}
.fs-result-badge--friend { background: var(--tint-green); color: var(--success); }
.fs-result-badge--group { background: var(--tint-blue); color: var(--info); }
.fs-result-badge--recent { background: var(--tint-orange); color: var(--tint-orange-text); }
.fs-result-badge--blacklist { background: var(--tint-red); color: var(--danger); }
.fs-result-highlight { color: var(--brand); font-weight: 700; }

/* ============================================================
   7. 宠物面板（方案A：橱窗黄页）
   ============================================================ */
#petsPanel { background: var(--bg); position: relative; z-index: var(--z-base); }
#petsPanel.active { display: flex; flex-direction: column; overflow: hidden; }
.pets-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; padding-bottom: var(--bottom-nav-h); }

/* 轮播 */
.pets-banner { position: relative; z-index: 1; height: 300px; overflow: hidden; background: var(--card-nested); border-radius: 14px; margin: 8px 0 4px; display: block; }
.pets-banner-track { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scroll-behavior: smooth; }
.pets-banner-track::-webkit-scrollbar { display: none; }
.pets-banner-slide { flex: 0 0 100%; scroll-snap-align: start; position: relative; cursor: pointer; }
.pets-banner-slide img { width: 100%; height: 100%; object-fit: cover; }
.pets-banner-slide-label { position: absolute; bottom: 0; left: 0; right: 0; padding: 30px 14px 12px; background: linear-gradient(transparent, rgba(0,0,0,0.65)); color: #fff; font-size: 0.88rem; font-weight: 600; display: flex; justify-content: space-between; align-items: flex-end; gap: 8px; }
.pets-banner-slide-label .pbsl-shop { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pets-banner-slide-label .pbsl-city { flex-shrink: 0; font-size: 0.7rem; font-weight: 400; opacity: 0.85; }
/* 占位轮播 */
.pets-banner-placeholder { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.pets-banner-placeholder:nth-child(2) { background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%); }
.pets-banner-placeholder:nth-child(3) { background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%); }
.pets-banner-placeholder:nth-child(4) { background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%); }
.pets-banner-placeholder:nth-child(5) { background: linear-gradient(135deg, #fa709a 0%, #fee140 100%); }
.pbs-placeholder-text { font-size: 1.2rem; font-weight: 700; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,0.2); }
/* 广告位占位 */
.pets-banner-ad { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #E8E0D5 0%, #D5CCC0 100%); }
.pbs-ad-text { font-size: 1.1rem; font-weight: 600; color: var(--text-muted); }
/* 无图商家轮播 */
.pets-banner-noimg { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #5B4FD9 0%, #3D30B0 100%); }
.pbs-noimg-icon { color: rgba(255,255,255,0.35); margin-bottom: 40px; }
.pets-banner-dots { position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; z-index: 2; }
.pets-banner-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,0.4); transition: background 0.3s, width 0.3s; }
.pets-banner-dot.active { background: #fff; width: 18px; border-radius: 3px; }

/* 服务分类网格 */
.pets-cat-row { display: flex; gap: 8px; overflow-x: auto; padding: 10px 14px; -webkit-overflow-scrolling: touch; scroll-snap-type: x proximity; touch-action: pan-x; overscroll-behavior-x: contain; }
.pets-cat-row::-webkit-scrollbar { display: none; }
.pets-cat-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 12px 18px; border-radius: 12px; background: var(--bg-card); border: 1px solid var(--border); cursor: pointer; transition: transform 0.15s; flex-shrink: 0; white-space: nowrap; }
.pets-cat-item:active { transform: scale(0.95); }
.pets-cat-item.active { border-color: var(--brand); background: rgba(224,90,58,0.06); }
.pets-cat-icon { font-size: 1.5rem; line-height: 1; min-width: 1.5em; text-align: center; }
.pets-cat-label { font-size: 0.72rem; color: var(--text-secondary); font-weight: 500; }

/* 返回顶部 */
.pets-back-top { position: fixed; right: 16px; bottom: calc(var(--bottom-nav-h) + 16px); width: 44px; height: 44px; border-radius: 50%; background: var(--brand); border: none; box-shadow: 0 2px 12px rgba(0,0,0,0.18); display: none; align-items: center; justify-content: center; cursor: pointer; z-index: 9999; color: #fff; }
.pets-back-top:active { transform: scale(0.92); }
.pets-back-top.show { display: flex; }

/* 分区标题 */
.pets-section { padding: 0 14px; }
.pets-section-title { font-size: 0.88rem; font-weight: 700; color: var(--text); padding: 10px 0 8px; display: flex; align-items: center; justify-content: space-between; }
.pets-section-title > span { display: flex; align-items: center; gap: 6px; }
.pets-section-title > span::before { content: ''; width: 3px; height: 16px; border-radius: 2px; background: var(--brand); flex-shrink: 0; }
.pets-section-pub-btn { padding: 5px 14px; border-radius: 14px; border: none; background: var(--brand); color: #fff; font-size: 0.72rem; font-weight: 600; cursor: pointer; font-family: inherit; }
.pets-section-pub-btn:active { opacity: 0.8; }

/* 卡片列表 */
.pets-feed { display: flex; flex-direction: column; gap: 10px; }

/* 宠物卡片 */
.pet-card { background: var(--bg-card); border-radius: 14px; padding: 14px; box-shadow: 0 1px 6px rgba(78,59,44,0.04); cursor: pointer; transition: transform 0.15s; }
.pet-card:active { transform: scale(0.98); }
.pet-card-main { display: flex; gap: 12px; margin-bottom: 10px; }
.pet-card-info { flex: 1; min-width: 0; }
.pet-card-title { font-size: 0.92rem; font-weight: 700; color: var(--text); margin-bottom: 5px; line-height: 1.4; }
.pet-card-body { font-size: 0.8rem; line-height: 1.55; color: var(--text-secondary); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-all; }
.pet-card-image { width: 72px; height: 72px; border-radius: 10px; object-fit: cover; flex-shrink: 0; }
.pet-card-img-wrap { position: relative; flex-shrink: 0; }
.pet-card-img-extra {
  position: absolute; top: 6px; right: 6px;
  background: rgba(0,0,0,0.55); color: #fff;
  font-size: 0.7rem; font-weight: 600;
  padding: 2px 7px; border-radius: 10px;
  pointer-events: none;
}
.pet-card-footer { display: flex; align-items: center; justify-content: flex-start; padding-top: 8px; border-top: 1px solid var(--border); }
.pet-card-city { font-size: 0.75rem; color: var(--text-muted); display: flex; align-items: center; gap: 4px; }
.pet-card-avatar img { width: 42px; height: 42px; border-radius: var(--avatar-radius); object-fit: cover; display: block; }
.pet-card-avatar svg { width: 42px; height: 42px; display: block; }
.pet-card-avatar-fallback svg { width: 42px; height: 42px; display: block; }
.pet-card-actions { display: flex; gap: 6px; }
.pet-card-time { font-size: 0.65rem; color: var(--text-muted); flex: 1; text-align: center; }
.pet-card-action-btn { padding: 5px 12px; font-size: 0.7rem; font-weight: 500; color: var(--brand); background: rgba(91,79,217,0.07); border-radius: 12px; cursor: pointer; border: none; font-family: inherit; white-space: nowrap; transition: all 0.15s; }
.pet-card-action-btn:active { opacity: 0.7; }
.pet-card-action-del { color: #E53E3E; background: rgba(229,62,62,0.07); }
.pet-card-action-fav { color: #F59E0B; background: rgba(245,158,11,0.08); }
.pet-card-action-contact { color: #059669; background: rgba(5,150,105,0.07); }

/* 内容类型选择器 */
.pet-type-row { display: flex; gap: 8px; }
.pet-type-opt { flex: 1; padding: 9px 0; border-radius: 10px; border: 1.5px solid var(--border); background: var(--bg-card); color: var(--text-secondary); font-size: 0.8rem; font-weight: 500; text-align: center; cursor: pointer; font-family: inherit; transition: all 0.15s; }
.pet-type-opt.active { background: var(--brand); color: #fff; border-color: var(--brand); font-weight: 600; }

/* 经营范围标签 */
.pet-scope-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.pet-scope-tag { padding: 7px 14px; border-radius: 18px; border: 1.5px solid var(--border); background: var(--bg-card); color: var(--text-secondary); font-size: 0.78rem; cursor: pointer; transition: all 0.15s; user-select: none; }
.pet-scope-tag.active { background: rgba(91,79,217,0.1); color: #5B4FD9; border-color: #5B4FD9; font-weight: 600; }

/* 必填标记 */
.form-label-req { color: var(--brand); font-weight: 400; }

.task-poll-card {
  padding: 10px 12px;
  background: var(--card-nested);
  border: 1px solid var(--border);
  border-radius: 14px;
  margin-bottom: 10px;
}
.mc-poll-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
}
.mc-poll-radio {
  width: 16px; height: 16px;
  border-radius: 50%;
  border: 2px solid var(--card-nested-border);
  flex-shrink: 0;
  background: var(--bg-card);
}
.mc-poll-bar-wrap { flex: 1; min-width: 0; }
.mc-poll-bar-track {
  height: 6px;
  border-radius: 3px;
  background: var(--card-nested-active);
  overflow: hidden;
}
.mc-poll-bar-fill {
  height: 100%;
  background: var(--brand-gradient);
  border-radius: 3px;
  transition: width 0.4s var(--ease);
}
.mc-poll-label {
  font-size: 0.78rem;
  color: var(--text-secondary);
  flex-shrink: 0;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mc-poll-pct {
  font-size: 0.72rem;
  color: var(--text-muted);
  flex-shrink: 0;
  min-width: 32px;
  text-align: right;
}

/* 宠物卡片图片内容 */
.pet-content-row { display:flex; gap:10px; align-items:flex-start; }
.pet-content-row.has-image .pet-content { flex:1; min-width:0; margin-bottom:0; }
.pet-card-thumb { flex-shrink:0; width:72px; height:72px; border-radius:8px; overflow:hidden; background:var(--list-muted); }
.pet-card-thumb img { width:100%; height:100%; object-fit:cover; cursor:pointer; }
.pet-card-thumb.expanded { width:100%; height:auto; max-height:200px; }
.pet-card-thumb.expanded img { max-height:200px; object-fit:contain; }
.pet-card-img-badge { position:absolute; right:3px; bottom:3px; background:rgba(0,0,0,0.55); color:#fff; font-size:0.65rem; padding:1px 6px; border-radius:8px; }
.pet-card-gallery { display:none; margin-top:8px; overflow-x:auto; white-space:nowrap; -webkit-overflow-scrolling:touch; scroll-snap-type:x mandatory; }
.pet-item.expanded .pet-card-gallery, .pet-card-full.expanded .pet-card-gallery { display:block; }
.pet-card-gallery img { display:inline-block; width:100px; height:100px; object-fit:cover; border-radius:8px; margin-right:6px; cursor:pointer; scroll-snap-align:start; }
.pet-item.expanded .pet-content-row { display:block; }
.pet-item.expanded .pet-content-row .pet-card-thumb { display:none; }
.pet-item.expanded .pet-card-gallery { display:block; }
.pet-item.expanded .pet-content-row.has-image .pet-card-gallery { display:block; }

/* 图片投票标签 */
.poll-img-tags { display:grid; grid-template-columns:repeat(auto-fit, minmax(52px, 1fr)); gap:6px; margin-bottom:8px; }
.poll-img-tag { display:block; text-align:center; padding:4px 6px; background:var(--tint-purple); color:#7B1FA2; border-radius:6px; font-size:0.72rem; font-weight:600; cursor:pointer; transition:background 0.15s; white-space:nowrap; }
.poll-img-tag:active { background:#E1BEE7; }

/* 全屏图片查看器（投票图片�?*/
.poll-img-viewer { position:fixed; inset:0; z-index:100010; display:flex; align-items:center; justify-content:center; background:rgba(0,0,0,0.9); cursor:pointer; }
.poll-img-viewer img { max-width:92vw; max-height:92vh; border-radius:12px; object-fit:contain; }

/* 喇叭奖励规则提示 */
.pet-horn-hint { padding:6px 10px; background:rgba(230,168,23,0.08); border-radius:6px; font-size:0.65rem; color:#c99515; line-height:1.5; word-break:break-all; }

/* 全屏图片查看�?*/
.pet-img-viewer { position:fixed; inset:0; z-index:var(--z-panel); display:flex; align-items:center; justify-content:center; }
.pet-img-viewer-bg { position:absolute; inset:0; background:rgba(0,0,0,0.85); }
.pet-img-viewer img { position:relative; z-index:1; max-width:92vw; max-height:92vh; border-radius:10px; cursor:pointer; }
.tiv-counter { position:absolute; top:16px; left:50%; transform:translateX(-50%); z-index:2; color:#fff; font-size:0.85rem; font-weight:500; background:rgba(0,0,0,0.4); padding:4px 12px; border-radius:12px; }
.tiv-prev, .tiv-next { position:absolute; top:50%; transform:translateY(-50%); z-index:2; width:40px; height:40px; border-radius:50%; background:rgba(255,255,255,0.15); border:none; color:#fff; display:flex; align-items:center; justify-content:center; cursor:pointer; }
.tiv-prev { left:12px; }
.tiv-next { right:12px; }
.tiv-prev svg, .tiv-next svg { width:22px; height:22px; }
.tiv-hidden { display:none !important; }

/* 投票模式切换按钮 */
.poll-mode-toggle { display:flex; align-items:center; gap:6px; margin-bottom:12px; }
.poll-mode-btn { padding:5px 14px; border-radius:14px; border:1px solid var(--card-nested-border); background: var(--bg-card); color:var(--text-muted); font-size:0.75rem; cursor:pointer; transition:all 0.15s; font-family:inherit; }
.poll-mode-btn.active { background:var(--brand); color:#fff; border-color:var(--brand); }

/* 图片投票选项上传 */
#pollOptsWrapper { display:block; }
#pollOptsWrapper.poll-opts-grid { display:flex; flex-wrap:wrap; gap:8px; align-items:flex-start; }
#pollOptsWrapper.poll-opts-grid #pollOptionsContainer { display:contents; }
#pollOptsWrapper.poll-opts-grid .poll-add-btn { width:72px; height:72px; padding:0; border:1.5px dashed var(--card-nested-border); border-radius:10px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:2px; font-size:0.6rem; margin:0; }
#pollOptionsContainer.poll-opts-grid { display:flex; flex-wrap:wrap; gap:8px; }
.poll-opt-row { display:flex; align-items:center; gap:8px; margin-bottom:8px; }
.poll-opt-row:has(.poll-img-upload) { flex-direction:column; align-items:center; gap:4px; margin-bottom:0; }
#pubVoteOptionsList { display:flex; flex-wrap:wrap; gap:8px; }
#pubVoteOptionsList .poll-opt-row { margin-bottom:0; flex:1 1 100%; min-width:100%; }
#pubVoteOptionsList .poll-opt-row:has(.poll-img-upload) { flex:none; min-width:auto; flex-direction:row; align-items:center; gap:4px; }
.poll-img-upload { width:72px; height:72px; border-radius:10px; border:1.5px dashed var(--card-nested-border); display:flex; flex-direction:column; align-items:center; justify-content:center; gap:2px; cursor:pointer; color:var(--text-muted); font-size:0.6rem; flex-shrink:0; }
.poll-img-preview { width:72px; height:72px; border-radius:10px; object-fit:cover; }
.poll-img-wrap { position:relative; display:inline-block; }
.poll-img-wrap .pig-del { position:absolute; top:-6px; right:-6px; }
.poll-opt-del--img { font-size:0.65rem; color:var(--text-muted); cursor:pointer; background:none; border:none; padding:2px; }
.poll-img-upload svg { opacity:0.6; }

/* 任务图片删除按钮 */
.pig-del { position:absolute; top:-6px; right:-6px; width:18px; height:18px; border-radius:50%; background:var(--danger); color:#fff; border:none; font-size:10px; cursor:pointer; display:flex; align-items:center; justify-content:center; line-height:1; }

.vote-dialog-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
  text-align: center;
}
.vote-dialog-options { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.vote-dialog-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.15s;
}
.vote-dialog-opt:active { border-color: var(--brand); }
.vote-dialog-opt.selected { border-color: var(--brand); background: var(--tint-pink); }
.vote-dialog-opt-text { font-size: 0.9rem; color: var(--text); }
.vote-dialog-opt-check {
  width: 20px; height: 20px;
  border-radius: 50%;
  border: 2px solid var(--card-nested-border);
  flex-shrink: 0;
  background: var(--bg-card);
  transition: all 0.15s;
}
.vote-dialog-opt.selected .vote-dialog-opt-check {
  border-color: var(--brand);
  background: var(--brand);
  box-shadow: inset 0 0 0 3px #fff;
}
.vote-dialog-img-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; margin-bottom:16px; }
.vote-dialog-img-opt { position:relative; aspect-ratio:1; border-radius:12px; overflow:hidden; cursor:pointer; border:2px solid transparent; transition:border-color 0.15s; }
.vote-dialog-img-opt img { width:100%; height:100%; object-fit:cover; display:block; }
.vote-dialog-img-opt .vote-dialog-opt-check { position:absolute; top:6px; right:6px; opacity:0; }
.vote-dialog-img-opt.selected { border-color:var(--brand); }
.vote-dialog-img-opt.selected .vote-dialog-opt-check { opacity:1; }

#payOverlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: var(--z-toast);
  display: none;
  align-items: center;
  justify-content: center;
}

@keyframes modalIn { from { opacity: 0; transform: scale(0.92) translateY(16px); } to { opacity: 1; transform: scale(1) translateY(0); } }
@keyframes scaleIn { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: scale(1); } }

.auth-card {
  background: var(--bg-card);
  border-radius: 12px;
  width: 90%;
  max-width: 360px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 32px 24px 40px;
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
  border: 1px solid var(--border);
  animation: modalIn 0.35s var(--ease);
  position: relative;
}
.auth-close {
  position: absolute; top: 14px; right: 14px;
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  border-radius: 50%;
  transition: background 0.2s ease;
}
.auth-close:hover { background: var(--bg-light); }

/* ============================================================
   9. Modal弹窗系统
   ============================================================ */
/* ---------- Unified overlay base ---------- */
.modal-overlay, .edit-profile-overlay, .confirm-overlay, .report-overlay,
.user-profile-overlay, .gi-overlay, .blocked-list-overlay, .cg-picker-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  z-index: var(--z-dropdown);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.modal-overlay {
  display: none;
  z-index: 300;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.modal-dialog {
  background: var(--bg-card);
  border-radius: 16px;
  max-width: 400px;
  width: calc(100% - 32px);
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.06);
  animation: modalIn 0.25s var(--ease);
}
.modal-header { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 0; flex-shrink: 0; }
.modal-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.modal-close {
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.2s ease;
}
.modal-close:active { background: var(--border); }
.modal-body { padding: 16px 20px; overflow-y: auto; flex: 1; }
.modal-footer { display: flex; gap: 12px; padding: 0 20px 20px; }
.modal-footer .btn { flex: 1; }
.btn-primary {
  width: 100%; padding: 13px;
  border: none;
  border-radius: 12px;
  background: var(--brand-gradient);
  color: #fff;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-primary:active { transform: scale(0.99); }
.modal-sm { max-width: 300px; }
.modal-sm .modal-body { text-align: center; }

/* ============================================================
   10. 表单
   ============================================================ */
input[type="text"], input[type="password"], input[type="email"], input[type="search"],
input[type="number"], textarea, select {
  font-family: inherit;
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.2s;
}
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.form-section-label {
  font-size: 0.85rem; font-weight: 700; color: var(--brand);
  padding: 12px 0 4px 0; margin-bottom: 8px;
  border-bottom: 2px solid var(--brand-light, #f0e0ff);
}
.form-input, .form-textarea, .form-select {
  width: 100%; padding: 12px 14px;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px; color: var(--text);
}
.form-input:focus, .form-textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.form-input::placeholder, .form-textarea::placeholder { color: var(--text-weak); }
.form-textarea { min-height: 100px; resize: vertical; line-height: 1.6; }
#editBio { min-height: 60px; }
.form-hint { font-size: 0.72rem; color: var(--text-muted); margin-top: 6px; }
.form-select { appearance: auto; }
.gender-options { display: flex; gap: 16px; }
.gender-option { display: flex; align-items: center; gap: 6px; font-size: 0.88rem; color: var(--text); cursor: pointer; }
.btn-outline {
  padding: 10px 24px;
  background: transparent;
  color: var(--brand);
  border: 1.5px solid var(--brand);
  border-radius: 10px;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
.pay-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn-outline:active { background: var(--tint-pink); }
.btn-sm { padding: 6px 16px; font-size: 0.82rem; border-radius: 10px; font-weight: 500; }

/* 编辑资料弹窗 */
.edit-profile-overlay {
  z-index: var(--z-panel); background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.edit-profile-overlay.show { opacity: 1; pointer-events: auto; }
.edit-profile-card {
  background: var(--bg-card); border-radius: 20px;
  width: calc(100vw - 40px); max-width: 400px; max-height: 85vh;
  overflow-y: auto; box-shadow: 0 12px 40px rgba(0,0,0,0.2);
}
.ep-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px 8px; border-bottom: 1px solid var(--border);
}
.ep-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.ep-close-btn {
  width: 32px; height: 32px; border-radius: 50%;
  border: none; background: var(--bg-light);
  font-size: 1rem; color: var(--text-muted); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.ep-close-btn:active { background: var(--border); }
.ep-body { padding: 16px 20px 24px; }

/* 头像裁剪区域 */
.avatar-crop-area { text-align: center; margin-bottom: 16px; }
.ep-crop-container {
  width: 240px;
  height: 240px;
  margin: 0 auto 14px;
  background: var(--bg-light);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  border-radius: 20px;
  touch-action: none;
}
/* 榜单展示图裁切（匹配轮播满宽 × 200px） */
.banner-crop-container {
  width: 100%;
  max-width: 360px;
  height: 200px;
  border-radius: 12px;
}
.banner-crop-container .ep-crop-frame { border-radius: 0; }
.banner-crop-container .ep-crop-frame-edge { box-shadow: none; border-radius: 0; }
/* 暂无图片占位 */
.ep-crop-container::before {
  content: '暂无图片';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  z-index: 0;
  pointer-events: none;
}
.ep-crop-container:active { cursor: grabbing; }
.ep-crop-container img {
  position: absolute;
  max-width: none;
  display: block;
  pointer-events: none;
}
.ep-crop-mask {
  display: none;
}
.ep-crop-frame {
  position: absolute;
  pointer-events: none;
  z-index: 3;
  border-radius: 12px;
}
.ep-crop-frame-edge {
  width: 100%;
  height: 100%;
  border-radius: 12px;
  box-shadow: 0 0 0 2px var(--brand),
              0 0 0 1px rgba(224,90,58,0.15),
              inset 0 0 0 1px rgba(0,0,0,0.08);
}
.ep-crop-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 0 4px;
  box-sizing: border-box;
}
.ep-zoom-slider {
  flex: 1;
  accent-color: var(--brand);
}
.ep-zoom-btn {
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  border: 1.5px solid #E8DDD0;
  background: var(--bg-card);
  font-size: 1rem;
  font-weight: 600;
  color: var(--brand);
  cursor: pointer;
  font-family: inherit;
  flex-shrink: 0;
  transition: all 0.15s;
  line-height: 1;
}
.ep-zoom-btn:active { background: var(--card-nested-active); }

/* 签到 */
.signin-body { text-align: center; }
.signin-calendar { margin: 12px 0; }
.signin-reward { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 10px; }

/* 道具 */
.props-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; padding: 4px 0; }
.props-list .empty-state { grid-column: 1 / -1; }
.prop-card {
  display: flex; flex-direction: column; align-items: center;
  padding: 24px 16px 16px;
  background: var(--bg-card);
  border-radius: 16px;
  box-shadow: 0 2px 10px rgba(78,59,44,0.05);
  border: 1px solid var(--border);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  text-align: center;
  position: relative;
}
.prop-card:active { transform: scale(0.97); }
.prop-card .icon-wrap {
  position: relative;
  display: inline-block;
  margin-bottom: 14px;
}
.prop-card .icon { font-size: 48px; width: 80px; height: 80px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--bg-light), var(--card-nested-active)); border-radius: 20px; flex-shrink: 0; box-shadow: 0 2px 12px rgba(78,59,44,0.06); }
.prop-card .count {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  background: var(--brand);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(224,90,58,0.35);
  line-height: 1;
}
.prop-card .info { flex: 1; min-width: 0; width: 100%; }
.prop-card .name { font-size: 0.95rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.prop-card .desc { font-size: 0.7rem; color: var(--text-muted); line-height: 1.4; }
.prop-card .card-bottom { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; }
.prop-card .gift-btn {
  flex-shrink: 0;
  padding: 7px 18px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s ease;
}
.prop-card .gift-btn:active { opacity: 0.8; }
.prop-card .gift-btn:disabled { background: #ccc; cursor: not-allowed; }
.prop-card .prop-use-btn {
  margin-top: 10px;
  padding: 7px 16px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s ease;
}
.prop-card .prop-use-btn:active { opacity: 0.8; }
.prop-card .prop-use-btn:disabled { background: #ccc; cursor: not-allowed; }
.prop-card.gift-card { cursor: pointer; }
.prop-card.gift-card:active { transform: scale(0.97); }
.prop-card .gift-icon-img { width: 60px; height: 60px; border-radius: 14px; object-fit: cover; }
#giftDetailOverlay { position: fixed; inset: 0; background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center; z-index: 9999; }
#giftDetailCard { background: #fff; border-radius: 18px; max-width: 360px; width: 90%; overflow: hidden; box-shadow: 0 8px 32px rgba(0,0,0,0.2); }
.prop-card .prop-discard-btn {
  padding: 7px 14px;
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}
.prop-card .prop-discard-btn:active { transform: scale(0.93); }

/* 道具标签栏 */
.props-tabs {
  display: flex;
  gap: 0;
  margin: -4px 0 16px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  border-radius: 10px 10px 0 0;
  overflow: hidden;
}
.props-tab {
  flex: 1;
  padding: 12px 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.props-tab.active {
  color: var(--brand);
  border-bottom-color: var(--brand);
}
.props-tab-content { display: none; }
.props-tab-content.active { display: block; }

/* 发放弹窗 */
#distributeSheet .ipt-row { margin-top: 12px; }
#distributeSheet .ipt-row label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 6px; }
#distributeSheet .ipt-row input {
  width: 100%; box-sizing: border-box; padding: 12px 14px;
  border: 1px solid var(--border); border-radius: 12px;
  font-size: 1.1rem; text-align: center; letter-spacing: 8px;
  outline: none;
}
#distributeSheet .ipt-row input:focus { border-color: var(--brand); }

/* 发放/领取码弹窗通用 */
.mask {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 9998;
}
.modal-sheet {
  position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%);
  background: #fff;
  border-radius: 14px;
  z-index: 9999;
  width: 88%;
  max-width: 360px;
  max-height: 70vh;
  overflow-y: auto;
  animation: fadeScale .2s ease;
}
@keyframes fadeScale { from { opacity: 0; transform: translate(-50%, -50%) scale(0.92); } to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }
.sheet-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}
.sheet-title { font-size: 1rem; font-weight: 700; }
.sheet-close-btn {
  font-size: 0.9rem; color: var(--text-muted);
  background: none; border: none; cursor: pointer; padding: 4px 8px;
}
.sheet-confirm-btn {
  font-size: 0.9rem; font-weight: 600; color: var(--brand);
  background: none; border: none; cursor: pointer; padding: 4px 8px;
}
.sheet-body { padding: 16px; }

/* 聊天礼品卡片 */
.chat-gift-card {
  max-width: 260px;
  margin: 8px auto;
  padding: 16px 20px;
  background: linear-gradient(135deg, var(--tint-yellow), var(--tint-orange));
  border: 1.5px solid var(--promo-border);
  border-radius: 16px;
  text-align: center;
  box-shadow: 0 2px 12px rgba(255,160,0,0.1);
}
.chat-gift-card .gift-icon-wrap {
  width: 44px; height: 44px;
  margin: 0 auto 10px;
  background: var(--tint-orange);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--tint-orange-text);
}
.chat-gift-card .gift-icon-wrap svg { width: 22px; height: 22px; }
.chat-gift-card .gift-title {
  font-size: 0.85rem; font-weight: 700; color: var(--tint-orange-text); margin-bottom: 4px;
}
.chat-gift-card .gift-desc {
  font-size: 0.78rem; color: #8D6E63; margin-bottom: 8px; line-height: 1.4;
}
.chat-gift-card .gift-status {
  font-size: 0.72rem; color: #A1887F; margin-bottom: 6px;
}
.chat-gift-card .gift-actions {
  display: flex; gap: 8px; justify-content: center; margin-top: 8px;
}
.chat-gift-card .gift-actions .gift-btn {
  flex: 1; max-width: 100px;
  padding: 7px 14px; border-radius: 20px;
  font-size: 0.78rem; font-weight: 600; cursor: pointer;
  border: none; transition: opacity 0.15s;
}
.chat-gift-card .gift-actions .gift-btn:active { opacity: 0.8; }
.chat-gift-card .gift-actions .gift-btn.accept {
  background: var(--brand); color: #fff;
}
.chat-gift-card .gift-actions .gift-btn.reject {
  background: var(--bg-card); color: var(--danger); border: 1px solid var(--danger);
}
.chat-gift-card .gift-actions .gift-btn.confirm {
  background: var(--tint-orange-text); color: #fff;
}
.chat-gift-card .gift-time {
  font-size: 0.65rem; color: #BCAAA4; margin-top: 6px;
}

/* 个人页喇叭计�?*/
.profile-horn-count {
  margin-top: 6px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--brand);
  text-align: center;
}

/* 收藏 */
.favorites-list { max-height: 300px; overflow-y: auto; }
.favorite-item {
  padding: 14px 16px; cursor: pointer;
  border-bottom: 1px solid var(--border);
  font-size: 0.88rem; color: var(--text);
  transition: background 0.2s ease;
}
.favorite-item:active { background: var(--bg-light); }

/* 我的发布 */
.publish-list { max-height: 300px; overflow-y: auto; }
.publish-item {
  padding: 14px 16px; cursor: pointer;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s ease;
}
.publish-item:active { background: var(--bg-light); }
.publish-item .title { font-size: 0.94rem; font-weight: 500; color: var(--text); }
.publish-item .meta { font-size: 0.72rem; color: var(--text-muted); margin-top: 4px; }

/* Promotion */
.promo-banner {
  position: relative;
  background: var(--promo-gradient);
  border-radius: 16px;
  padding: 24px 20px;
  margin-bottom: 14px;
  overflow: hidden;
  border: 1px solid var(--promo-border);
}
.promo-banner-bg {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 56px;
  height: 56px;
  background: rgba(224,90,58,0.08);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.promo-banner-cat { animation: promoFloat 3s ease-in-out infinite; }
.promo-banner-cat svg { display: block; }
@keyframes promoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
.promo-banner-text { position: relative; z-index: var(--z-base); padding-right: 60px; }
.promo-banner-title { font-size: 1.05rem; font-weight: 800; color: var(--promo-title); margin-bottom: 6px; }
.promo-banner-reward { font-size: 0.82rem; color: var(--promo-accent); }
.promo-banner-reward strong { color: var(--brand); font-weight: 700; }
.promo-banner-sub { font-size: 0.78rem; color: var(--text-secondary); margin-top: 4px; }

.promo-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}
.promo-stat-card {
  background: var(--bg-card);
  border-radius: 14px;
  padding: 14px 10px;
  text-align: center;
  border: 1px solid var(--border);
  box-shadow: 0 1px 4px rgba(78,59,44,0.03);
}
.promo-stat-num { font-size: 1.6rem; font-weight: 800; color: var(--brand); line-height: 1.2; }
.promo-stat-label { font-size: 0.68rem; color: var(--text-weak); margin-top: 4px; }

.promo-link-card {
  background: var(--bg-card);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 14px;
  border: 1px solid var(--border);
  box-shadow: 0 1px 6px rgba(78,59,44,0.04);
}
.promo-link-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}
.promo-link-value {
  display: block;
  width: 100%;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text);
  background: var(--bg-light);
  border-radius: 10px;
  padding: 12px 14px;
  word-break: break-all;
  line-height: 1.5;
  margin-bottom: 12px;
  cursor: pointer;
  transition: background 0.15s;
  border: 1px solid transparent;
}
.promo-link-value:hover { background: var(--card-nested-active); }
.promo-link-value:active { background: var(--card-nested-active); }
.promo-copy-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 11px;
  background: var(--brand-gradient);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
}
.promo-copy-btn:active { transform: scale(0.98); opacity: 0.9; }
.promo-copy-btn.copied { background: var(--success); }

.promo-steps {
  background: var(--bg-card);
  border-radius: 14px;
  padding: 18px 16px;
  margin-bottom: 14px;
  border: 1px solid var(--border);
  box-shadow: 0 1px 6px rgba(78,59,44,0.04);
}
.promo-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.promo-step-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.promo-step-icon svg { display: block; }
.promo-step-body { min-width: 0; }
.promo-step-title { font-size: 0.8rem; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.promo-step-desc { font-size: 0.7rem; color: var(--text-secondary); line-height: 1.5; }
.promo-step-arrow {
  text-align: left;
  padding: 2px 0 2px 48px;
  line-height: 1;
}
.promo-step-arrow svg { display: block; }

/* 设置 */
.setting-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.94rem; color: var(--text);
  cursor: pointer;
  transition: background 0.2s;
}
.setting-item:active { opacity: 0.7; }
.setting-item-arrow { color: var(--text-weak); font-size: 16px; }
.setting-toggle { position: relative; display: inline-block; width: 44px; height: 26px; }
.setting-toggle input { display: none; }
.toggle-slider {
  position: absolute; inset: 0;
  background: var(--toggle-bg); border-radius: 26px;
  transition: 0.2s; cursor: pointer;
}
.toggle-slider::before {
  content: ''; position: absolute;
  width: 22px; height: 22px; left: 2px; top: 2px;
  background: var(--bg-card); border-radius: 50%;
  transition: 0.2s;
}
.setting-toggle input:checked + .toggle-slider { background: var(--brand); }
.setting-toggle input:checked + .toggle-slider::before { transform: translateX(18px); }

.setting-version { text-align:center; padding:20px 0 16px; }
.setting-version-name { font-size:1.1rem; font-weight:700; color:var(--text); }
.setting-version-num { font-size:0.8rem; color:var(--text-muted); margin-top:4px; }
.setting-item-left { display:flex; align-items:center; gap:12px; }
.setting-item-text { display:flex; flex-direction:column; }
.setting-item-title { font-size:0.94rem; color:var(--text); font-weight:500; }
.setting-item-sub { font-size:0.72rem; color:var(--text-muted); margin-top:2px; }
#settingsPanel { background: var(--bg); }
#settingsPanel .setting-item {
  background: var(--bg-card);
  padding: 16px;
  border-bottom: none;
  border-radius: 12px;
  margin-bottom: 8px;
}
#settingsPanel .setting-item:last-child { margin-bottom: 0; }
#settingsPanel .setting-version { padding: 8px 0 16px; }
#settingsPanel .setting-logout { margin-top: 16px; }

/* ====== 关于应用卡片 ====== */
.about-app-card {
  background: var(--bg-card);
  border-radius: 12px;
  margin-bottom: 8px;
  overflow: hidden;
}
.about-app-header {
  text-align: center;
  padding: 20px 16px 14px;
}
.about-app-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}
.about-app-version {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}
.about-app-divider {
  height: 1px;
  background: var(--border);
  margin: 0 12px;
}
.about-app-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  cursor: pointer;
  transition: background 0.15s;
}
.about-app-row:active { background: var(--bg-hover); }
.about-app-row-left {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 0.92rem;
}

.collect-tabs {
  display:flex; gap:0;
  background:var(--bg-card);
  border-radius:12px;
  padding:4px;
  margin-bottom:16px;
  border:1px solid var(--border);
}
.collect-tab {
  flex:1; text-align:center;
  padding:8px 0;
  font-size:0.85rem; font-weight:500;
  color:var(--text-secondary);
  border-radius:10px;
  cursor:pointer;
}
.collect-tab.active { background:var(--brand); color:#fff; }

.search-box {
  display:flex; align-items:center; gap:8px;
  background: var(--bg-card); border:1px solid var(--border);
  border-radius:12px; padding:8px 14px; margin-bottom:12px;
}
.search-box svg { flex-shrink:0; color:var(--text-muted); }
.search-input { flex:1; border:none; outline:none; background:transparent; font-size:0.9rem; color:var(--text); }
.search-input::placeholder { color:var(--text-weak); }
.search-clear { cursor:pointer; color:var(--text-muted); font-size:0.9rem; flex-shrink:0; }
.search-tips { padding:40px 0; text-align:center; color:var(--text-muted); font-size:0.85rem; }
.search-tips-icon { font-size:2.2rem; margin-bottom:8px; }

.cg-avatar-area { text-align:center; margin-bottom:16px; }
.cg-selected-row {
  display:flex; flex-wrap:wrap; gap:10px; align-items:center;
}
.cg-add-btn {
  width:48px; height:48px; border-radius:14px;
  border:1.5px dashed var(--card-nested-border);
  display:flex; align-items:center; justify-content:center;
  font-size:1.4rem; color:var(--text-muted);
  cursor:pointer; flex-shrink:0; background:var(--input-bg);
  transition:all 0.15s;
}
.cg-add-btn:active { background:var(--card-nested-active); }
.cg-friend-card {
  display:flex; flex-direction:column; align-items:center;
  width:56px; flex-shrink:0; position:relative;
  cursor:default;
}

.cg-friend-card-name {
  font-size:0.65rem; color:var(--text-secondary);
  margin-top:3px; text-align:center; max-width:56px;
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
}
.cg-friend-card-remove {
  position:absolute; top:-4px; right:-4px;
  width:18px; height:18px; border-radius:50%;
  background:#E55; color:#fff; font-size:0.7rem;
  display:flex; align-items:center; justify-content:center;
  cursor:pointer; line-height:1;
}

.cg-picker-overlay {
  z-index: var(--z-modal);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  animation: fadeInSimple 0.2s ease;
}
@keyframes fadeInSimple { from { opacity:0; } to { opacity:1; } }
@keyframes pickerSlideUp { from { opacity:0; transform:translateY(20px) scale(0.96); } to { opacity:1; transform:translateY(0) scale(1); } }
.cg-friend-picker {
  width: 90%; max-width: 380px; max-height: 75vh;
  border-radius: 20px; background: var(--bg-card); overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.18), 0 0 0 1px rgba(0,0,0,0.05);
  display: flex; flex-direction: column;
  animation: pickerSlideUp 0.3s cubic-bezier(0.16,1,0.3,1);
}
.cg-picker-head {
  display:flex; align-items:center; gap:10px;
  padding:12px 16px 12px;
}
.cg-picker-title,
.cg-picker-title-row {
  padding: 18px 16px 14px;
  font-size: 1.05rem; font-weight: 700;
  color: var(--text); text-align: left;
  border-bottom: 1px solid var(--border);
}
.cg-picker-search {
  flex:1; padding:10px 14px; border:1.5px solid var(--input-border);
  border-radius:12px; font-size:0.85rem; background:var(--input-bg);
  outline:none; color:var(--text); transition:border-color 0.2s;
}
.cg-picker-search:focus { border-color:var(--brand); background: var(--bg-card); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.cg-picker-search::placeholder { color:var(--text-muted); }
.cg-picker-all {
  font-size:0.82rem; color:var(--brand); font-weight:600;
  cursor:pointer; white-space:nowrap; flex-shrink:0;
  padding:6px 10px; border-radius:8px;
  transition:background 0.15s;
}
.cg-picker-all:active { background:var(--tint-orange); }
.cg-picker-body {
  margin:0 12px;
  background:var(--bg-light);
  border-radius:14px;
  overflow:hidden;
}
.cg-picker-list { max-height:260px; overflow-y:auto; padding:2px 0; }
.cg-picker-item {
  display:flex; align-items:center; gap:12px; padding:12px 14px;
  cursor:pointer; transition:background 0.15s;
}
.cg-picker-item.selected { background:rgba(41,128,185,0.08); }
.cg-picker-item:active { background:rgba(0,0,0,0.03); }

.cg-picker-name { font-size:0.9rem; color:var(--text); flex:1; font-weight:500; }
.cg-picker-check {
  width:22px; height:22px; flex-shrink:0; position:relative; cursor:pointer;
}
.cg-picker-check input { display:none; }
.cg-picker-checkmark {
  display:block; width:22px; height:22px; border:2px solid var(--card-nested-border);
  border-radius:7px; position:relative; transition:all 0.2s;
}
.cg-picker-item.selected .cg-picker-checkmark {
  background:var(--brand); border-color:var(--brand);
}
.cg-picker-item.selected .cg-picker-checkmark::after {
  content:''; position:absolute; left:7px; top:3px; width:5px; height:10px;
  border:solid #fff; border-width:0 2px 2px 0; transform:rotate(45deg);
}
.cg-picker-foot {
  padding:10px 16px 16px;
}
.cg-picker-done {
  width:100%; padding:12px; background:var(--brand-gradient); color:#fff;
  border:none; border-radius:14px; font-size:0.95rem; font-weight:600; cursor:pointer;
  box-shadow:0 2px 8px rgba(224,90,58,0.25);
  transition:all 0.15s;
}
.cg-picker-done:active { transform:scale(0.98); opacity:0.9; }

.share-modal {
  background:var(--bg-card); border-radius:20px; width:400px; max-width:94vw;
  max-height:80vh; display:flex; flex-direction:column; overflow:hidden;
  box-shadow:0 12px 40px rgba(0,0,0,0.15); animation:upFadeIn 0.25s ease;
}
.share-modal-head {
  display:flex; align-items:center; justify-content:space-between;
  padding:18px 20px 0;
}
.share-modal-title { font-size:1.1rem; font-weight:700; color:var(--text); }
.share-modal-close {
  width:32px; height:32px; border-radius:50%; border:none; background:var(--bg-light);
  font-size:1.2rem; color:var(--text-secondary); cursor:pointer; display:flex;
  align-items:center; justify-content:center; line-height:1; transition:all 0.15s;
}
.share-modal-close:hover { background:var(--border); color:var(--text); }
.share-tabs {
  display:flex; gap:6px; padding:14px 14px 0; flex-shrink:0; flex-wrap:wrap;
}
.share-tab {
  padding:7px 14px; border:none; border-radius:18px;
  background:var(--bg-light); color:var(--text-secondary); font-size:0.78rem;
  font-weight:600; cursor:pointer; transition:all 0.2s; white-space:nowrap;
}
.share-tab:hover { background:var(--border); }
.share-tab.active { background:var(--brand); color:#fff; box-shadow:0 2px 8px rgba(224,90,58,0.25); }
.share-cards {
  background:var(--bg-card); flex:1; overflow-y:auto; max-height:60vh;
  min-height:120px; padding:10px;
}
.share-empty {
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  padding:48px 20px; gap:10px;
}
.share-empty-icon { font-size:2.2rem; opacity:0.5; }
.share-empty-text { font-size:0.9rem; color:var(--text-muted); }
.share-item {
  display:flex; align-items:center; gap:8px; padding:12px 14px;
  border-radius:12px; cursor:pointer; transition:all 0.2s;
  margin-bottom:4px; background:var(--bg);
  border:1px solid transparent;
}
.share-item:hover { background:var(--bg-white); border-color:var(--border); box-shadow:0 2px 8px rgba(78,59,44,0.04); }
.share-item:active { transform:scale(0.98); }
.share-card-left { display:flex; align-items:center; gap:10px; flex:1; min-width:0; }
.share-card-icon {
  width:36px; height:36px; border-radius:10px; background:var(--bg-card);
  display:flex; align-items:center; justify-content:center;
  font-size:1.1rem; flex-shrink:0; box-shadow:0 1px 3px rgba(78,59,44,0.06);
}
.share-card-info { flex:1; min-width:0; }
.share-item-title { font-size:0.9rem; font-weight:600; color:var(--text); display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.share-item-meta { font-size:0.75rem; color:var(--text-muted); display:block; margin-top:1px; }
.share-card-tag {
  font-size:0.65rem; font-weight:600; color:#fff; padding:2px 8px;
  border-radius:10px; flex-shrink:0; white-space:nowrap;
}
.share-card-tag.signin { background:var(--success); }
.share-card-tag.need { background:var(--warning); }
.share-card-tag.service { background:var(--info); }
.share-card-tag.vote { background:#9C27B0; }
.share-card-tag.other { background:#78909C; }
.share-card-arrow { flex-shrink:0; color:var(--text-muted); opacity:0.4; transition:opacity 0.15s; }
.share-item:hover .share-card-arrow { opacity:0.8; }

.share-link-card {
  display:flex; align-items:center; gap:10px; padding:12px 14px;
  background:var(--bg); border-radius:12px; cursor:pointer;
  transition:all 0.15s; border:1px solid var(--border-light);
  max-width:260px; position:relative;
}
.share-link-card:hover { border-color:var(--brand); box-shadow:0 2px 8px rgba(224,90,58,0.1); }
.share-link-icon { font-size:1.4rem; flex-shrink:0; }
.share-link-info { flex:1; min-width:0; }
.share-link-title { font-size:0.88rem; font-weight:600; color:var(--text); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.share-link-hint { font-size:0.72rem; color:var(--text-muted); margin-top:2px; }
.share-link-badge {
  position:absolute; top:-1px; right:-1px;
  font-size:0.6rem; font-weight:600; color:#fff;
  padding:2px 8px; border-radius:0 12px 0 10px;
}
.share-link-badge.signin { background:var(--success); }
.share-link-badge.need { background:var(--warning); }
.share-link-badge.service { background:var(--info); }
.share-link-badge.vote { background:#9C27B0; }
.share-link-badge.other { background:#78909C; }
.chat-bubble--share { background:transparent !important; padding:0 !important; border:none !important; border-radius:0 !important; display:block !important; width:80% !important; }
.plaza-bubble--share { background:transparent !important; padding:0 !important; box-shadow:none !important; border:none !important; border-radius:0 !important; display:block !important; width:80% !important; }
.plaza-bubble--share .article-card,
.plaza-bubble--share .pet-item { max-width:none !important; }
.chat-bubble--share .article-card { max-width:none !important; }
/* 分享卡片禁用按压涟漪和 WebKit 相关属性（overflow:hidden+box-shadow 变化会在最后一条消息时导致滚动跳变） */
.plaza-bubble--share .article-card,
.chat-bubble--share .article-card { -webkit-mask-image:none !important; mask-image:none !important; overflow:visible !important; }
.plaza-bubble--share .article-card:active,
.chat-bubble--share .article-card:active { background:var(--bg-card) !important; box-shadow:0 1px 4px rgba(78,59,44,0.06) !important; }
.plaza-bubble--share .article-card:active::before,
.chat-bubble--share .article-card:active::before { opacity:0 !important; }

/* 极简分享卡片 */
.share-teaser { padding:10px 14px; cursor:pointer; border-radius:12px; background:var(--bg-card); }
.chat-bubble--sent .share-teaser { background:var(--bg-card); }
.plaza-bubble:not(.plaza-bubble--share) .share-teaser { border-radius:8px; }
.share-teaser-line1 { display:flex; align-items:center; gap:6px; font-size:0.88rem; font-weight:500; color:var(--text); overflow:hidden; }
.share-teaser-title { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; flex:1; min-width:0; }
.share-teaser-icon { width:16px; height:16px; flex-shrink:0; color:var(--text-muted); }
.share-teaser-line2 { margin-top:4px; padding-left:22px; font-size:0.75rem; color:var(--text-muted); display:flex; align-items:center; gap:6px; }
.share-teaser-line2 .sep { opacity:0.5; }
.share-teaser .cat-type-tag { font-size:0.7rem; padding:1px 5px; border-radius:3px; flex-shrink:0; }

.chat-plus-btn { width:40px; height:40px; font-size:18px; flex-shrink:0; }
.chat-plus-btn:hover { box-shadow:0 4px 16px -2px rgba(224,90,58,0.4); }
.chat-plus-menu {
  position:absolute; bottom:64px; left:8px; right:8px;
  display:flex; justify-content:center; z-index:10;
  visibility: hidden; pointer-events: none;
  will-change: transform, opacity;
}
.chat-plus-menu.show { visibility: visible; pointer-events: auto; animation:menuSlideUp 0.25s var(--ease); }
.chat-plus-menu .add-menu-inner {
  width:100%;
}
.add-menu-icon.image-icon { background:var(--tint-orange); color:var(--tint-orange-text); }
.add-menu-icon.gift-icon { background:var(--tint-pink); color:var(--tint-pink-text); }
.chat-bubble--image { padding:4px !important; background:transparent !important; max-width:min(240px, 60vw); min-width:0; overflow:hidden; }
.chat-image { max-width:100%; max-height:300px; height:auto; border-radius:12px; display:block; cursor:pointer; }
.chat-image-expired { width:200px; height:120px; border-radius:12px; background:#eee; color:#999; display:flex; align-items:center; justify-content:center; font-size:13px; }
.chat-image-viewer { position:fixed; inset:0; z-index:var(--z-modal); background:rgba(0,0,0,0.9); display:flex; align-items:center; justify-content:center; }
.chat-image-viewer img { max-width:92vw; max-height:92vh; border-radius:8px; }
.chat-image-close { position:absolute; top:16px; right:16px; background:none; border:none; cursor:pointer; z-index:1; }

.cg-avatar-preview {
  width: 88px; height: 88px;
  margin: 0 auto;
  border: 2px dashed var(--card-nested-border);
  border-radius: var(--avatar-radius-xl);
  background: var(--input-bg);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 4px;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  overflow: hidden;
}
.cg-avatar-preview:active { background: var(--card-nested-active); border-color: var(--brand); }
.cg-avatar-preview img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 18px;
}
.cg-avatar-preview-label {
  font-size: 0.7rem; color: var(--text-muted);
  pointer-events: none;
}

.cg-crop-overlay {
  position: fixed; inset: 0; z-index: var(--z-panel);
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.cg-crop-overlay.show { opacity: 1; pointer-events: auto; }
.cg-crop-card {
  background: var(--bg-card); border-radius: 20px;
  width: calc(100vw - 40px); max-width: 400px; max-height: 85vh;
  overflow-y: auto; box-shadow: 0 12px 40px rgba(0,0,0,0.2);
}
.cg-crop-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px 8px; border-bottom: 1px solid var(--border);
}
.cg-crop-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.cg-crop-close {
  width: 32px; height: 32px; border-radius: 50%;
  border: none; background: var(--bg-light);
  font-size: 1rem; color: var(--text-muted); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.cg-crop-close:active { background: var(--border); }
.cg-crop-body {
  padding: 20px;
  display: flex; flex-direction: column; align-items: center;
}
.cg-crop-body .ep-crop-container {
  width: 220px; height: 220px;
  margin: 0 auto 14px;
  border-radius: 16px;
}
.cg-crop-body .ep-crop-frame {
  width: 220px; height: 220px;
  left: 0; top: 0;
}
.cg-crop-done {
  margin-top: 16px;
  width: 100%;
}

.pub-dropdown {
  display:flex; align-items:center; justify-content:space-between;
  padding:12px 14px;
  background: var(--bg-card); border:1px solid var(--border);
  border-radius:12px; cursor:pointer;
  position:relative;
}
.pub-dropdown-text { font-size:0.88rem; color:var(--text); }
.pub-dropdown-arrow { flex-shrink:0; color:var(--text-secondary); }
.pub-cat-menu {
  display:none;
  position:absolute; top:100%; left:0; right:0;
  background: var(--bg-card); border:1px solid var(--border);
  border-radius:12px; box-shadow:var(--shadow-md, 0 4px 16px rgba(0,0,0,0.08));
  z-index:102; padding:4px; margin-top:4px;
}
.pub-cat-menu.up {
  top:auto; bottom:100%; margin-top:0; margin-bottom:4px;
}
.pub-cat-menu.show { display:block; }
.pub-cat-opt {
  padding:10px 14px; font-size:0.85rem; color:var(--text);
  border-radius:10px; cursor:pointer; transition:background 0.12s;
}
.pub-cat-opt:active { background:var(--bg-light); }
.pub-cat-opt.selected { background:var(--brand-light, #FFF0EC); color:var(--brand); font-weight:600; }
.pub-cat-field { margin-bottom:8px; padding:12px; background:var(--bg-light); border-radius:12px; }
.pub-cat-field .form-group:last-child { margin-bottom:0; }
.pub-imgs-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 4px; }
.pub-imgs-grid .pig-item { aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--bg-light); position: relative; cursor: pointer; }
.pub-imgs-grid .pig-item .pig-del { top: 2px; right: 2px; }
.pub-imgs-grid .pig-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pub-imgs-grid .pig-item .pig-del-top { position: absolute; top: 2px; right: 2px; width: 18px; height: 18px; border-radius: 50%; background: rgba(0,0,0,0.45); border: none; color: #fff; font-size: 0.6rem; display: flex; align-items: center; justify-content: center; cursor: pointer; line-height: 1; }
.pub-imgs-grid .pig-item .pig-actions { position: absolute; bottom: 0; left: 0; right: 0; display: flex; }
.pub-imgs-grid .pig-item .pig-act { flex: 1; border: none; background: rgba(0,0,0,0.5); color: #fff; font-size: 0.6rem; padding: 5px 0; cursor: pointer; line-height: 1.4; }
.pub-imgs-grid .pig-item .pig-cover { border-right: 1px solid rgba(255,255,255,0.15); }
.pub-imgs-grid .pig-item .pig-act:active { background: rgba(0,0,0,0.7); }
.pub-imgs-grid .pig-add { aspect-ratio: 1; border-radius: 8px; background: var(--bg-light); border: 1px dashed var(--border); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; cursor: pointer; color: var(--text-weak); font-size: 0.62rem; }
.pub-imgs-grid .pig-add svg { width: 20px; height: 20px; }

/* 宠物发布图片网格（复用 pub-imgs-grid 样式） */
.pet-imgs-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 4px; }
.pet-imgs-grid .pig-item { aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--bg-light); position: relative; cursor: pointer; }
.pet-imgs-grid .pig-item .pig-del { top: 2px; right: 2px; }
.pet-imgs-grid .pig-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pet-imgs-grid .pig-add { aspect-ratio: 1; border-radius: 8px; background: var(--bg-light); border: 1px dashed var(--border); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; cursor: pointer; color: var(--text-weak); font-size: 0.62rem; }
.pet-imgs-grid .pig-add svg { width: 20px; height: 20px; }
.form-row { display:flex; gap:12px; }
.form-label-hint { font-weight:400; color:var(--text-secondary); font-size:0.72rem; }

.form-checkbox {
  display:flex; align-items:center; gap:8px; cursor:pointer;
  font-size:0.95rem; color:var(--text-primary); user-select:none;
}
.form-checkbox input[type="checkbox"] {
  width:20px; height:20px; accent-color:var(--brand); flex-shrink:0; cursor:pointer;
}
/* label 内嵌勾选项与表单风格统一 */
.form-label input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: var(--brand);
  vertical-align: middle; margin-right: 6px;
  cursor: pointer;
}

/* ---------- Pet Publish ---------- */
.pet-type-dropdown {
  width:100%; padding:12px 14px; margin-bottom:10px;
  border:1.5px solid var(--brand); border-radius:14px;
  font-size:0.92rem; color:var(--text); background:var(--tint-pink);
  display:flex; align-items:center; justify-content:space-between;
  cursor:pointer; transition:all 0.2s; box-sizing:border-box;
  position:relative; z-index:20;
}
.pet-type-dropdown:hover { box-shadow:0 0 0 3px rgba(224,90,58,0.08); }
.pet-type-dropdown:active { border-color:var(--brand); box-shadow:0 0 0 3px rgba(224,90,58,0.1); }
.pet-type-current { display:flex; align-items:center; gap:8px; color:var(--text); }
.pet-type-current svg { flex-shrink:0; }
.pet-type-arrow { flex-shrink:0; color:var(--text-secondary); transition:transform 0.2s; }
.pet-type-dropdown.open .pet-type-arrow { transform:rotate(180deg); }
.pet-type-menu {
  display:none; position:absolute; top:calc(100% + 2px); left:0; right:0;
  background: var(--bg-card); border:1px solid var(--border); border-radius:14px;
  padding:6px; box-shadow:0 8px 30px rgba(78,59,44,0.12); z-index:100;
}
.pet-type-menu.show { display:block; }
.pet-type-opt {
  display:flex; align-items:center; gap:8px; padding:10px 12px;
  border-radius:10px; font-size:0.88rem; color:var(--text);
  cursor:pointer; transition:background 0.12s;
}
.pet-type-opt:active { background:var(--bg-light); }
.pet-type-opt.selected { background:var(--bg-light); color:var(--brand); font-weight:600; }
.pet-type-opt svg { flex-shrink:0; }

.poll-opt-row { display:flex; align-items:center; gap:8px; margin-bottom:8px; }
.poll-opt-row input { flex:1; padding:10px 12px; border:1.5px solid var(--border); border-radius:10px; font-size:0.85rem; background: var(--bg-card); color:var(--text); outline:none; transition:border-color 0.15s; box-sizing:border-box; }
.poll-opt-row input:focus { border-color:var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.poll-opt-del { width:28px; height:28px; border-radius:50%; border:none; background:transparent; color:var(--text-muted); cursor:pointer; font-size:0.9rem; display:flex; align-items:center; justify-content:center; }
.poll-opt-del:active { background:var(--bg-light); color:var(--danger); }
.poll-add-btn { display:flex; align-items:center; gap:6px; padding:8px 14px; border:1.5px dashed var(--card-nested-border); border-radius:10px; background:transparent; font-size:0.82rem; color:var(--text-muted); cursor:pointer; transition:all 0.15s; margin-bottom:8px; }
.poll-add-btn:active { border-color:var(--brand); color:var(--brand); }

.signin-sub { text-align:center; font-size:0.85rem; color:var(--text-muted); margin-bottom:12px; }
.signin-upload {
  background:var(--bg-light); border:2px dashed var(--border);
  border-radius:16px; padding:24px;
  text-align:center; cursor:pointer; margin-bottom:16px;
  transition:border-color 0.2s;
}
.signin-upload:active { border-color:var(--brand); }
.signin-upload-icon { color:var(--text-muted); margin-bottom:8px; }
.signin-upload-tip { font-size:0.82rem; color:var(--text-muted); }
.signin-upload-preview { max-width:100%; max-height:160px; border-radius:10px; margin:0 auto 8px; object-fit:cover; }

.sub-header-btn { flex-shrink:0; white-space:nowrap; }

/* 确认弹窗 */
.confirm-message { font-size: 0.92rem; color: var(--text); line-height: 1.5; margin-bottom: 4px; text-align: center; }

/* ============================================================
   11. 子页面通用样式
   ============================================================ */
.sub-header {
  position: fixed;
  top: var(--safe-top);
  left: 0;
  right: 0;
  height: 54px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  background: var(--nav-bg);
	backdrop-filter: blur(16px);
	-webkit-backdrop-filter: blur(16px);
	z-index: 101;
	border-bottom: 1px solid var(--border);
}
.sub-back-btn {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
  transition: all 0.2s;
}
.sub-back-btn:active { transform: scale(0.92); background: var(--border); }
.sub-title {
  flex: 1;
  text-align: center;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  pointer-events: none;
}
.sub-spacer { width: 38px; flex-shrink: 0; }
.sub-right-btn {
  flex-shrink: 0; font-size: 0.8rem; color: var(--brand);
  background: none; border: none; cursor: pointer; padding: 4px 8px;
}
.sub-body {
  padding: calc(var(--top-offset) + 24px) 16px calc(var(--bottom-nav-h) + 40px);
}
.sub-btn-row {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}
.sub-btn-row .btn {
  flex: 1;
  border-radius: 12px;
}

/* ============================================================
   12. 城市选择�?   ============================================================ */
.header-dropdown-overlay {
  position: fixed;
  top: 0; left: 0; right: 0;
  bottom: var(--bottom-nav-h);
  z-index: var(--z-dropdown);
  display: block;
  opacity: 0;
  pointer-events: none;
  background: transparent;
  transition: opacity 0.15s;
}
.header-dropdown-overlay.show {
  opacity: 1;
  pointer-events: auto;
}
.header-dropdown {
  position: fixed;
  top: var(--top-offset);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border-radius: 16px;
  box-shadow: 0 8px 28px rgba(78,59,44,0.18);
  z-index: var(--z-dropdown);
  width: min(460px, calc(100vw - 32px));
  max-height: 35vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  opacity: 0;
  pointer-events: none;
  padding: 12px 0;
  transition: opacity 0.2s ease;
}
.header-dropdown.show {
  opacity: 1;
  pointer-events: auto;
}
.location-search { padding: 0 14px 10px; flex-shrink: 0; }
.location-search-input {
  width: 100%; padding: 10px 16px;
  border: 1px solid var(--input-border); border-radius: 24px;
  font-size: 0.85rem; outline: none;
  background: var(--bg-light); color: var(--text);
  transition: border-color 0.15s, background 0.15s;
}
.location-search-input:focus { border-color: var(--brand); background: var(--bg-card); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.location-search-input::placeholder { color: var(--text-weak); }
.location-letter-index { flex: 1; overflow-y: auto; padding: 0 14px 8px; }
.city-letter-group { margin-bottom: 4px; }
.city-recents-section { margin-bottom: 8px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.city-recents-header { padding: 4px 2px 6px; font-size: 0.78rem; font-weight: 700; color: var(--brand); }
.city-letter-header {
  padding: 8px 2px 6px; font-size: 0.78rem; font-weight: 700; color: var(--brand);
  position: sticky; top: 0; background: var(--bg-card); z-index: var(--z-base);
}
.city-letter-cities { display: flex; flex-wrap: wrap; gap: 8px; }
.city-tag {
  padding: 6px 14px; cursor: pointer; font-size: 0.85rem; color: var(--text);
  background: var(--bg-light); border-radius: 20px; border: 1px solid transparent;
  transition: all 0.15s; white-space: nowrap;
}
.city-tag:active { background: var(--card-nested-active); }
.city-tag.active { background: var(--card-nested); border-color: var(--brand); color: var(--brand); font-weight: 600; }

/* ============================================================
   13. Toast
   ============================================================ */
.toast-container {
  position: fixed;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 100px);
  left: 0;
  right: 0;
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}
.toast {
  width: fit-content;
  width: -moz-fit-content;
  max-width: 85%;
  padding: 8px 20px;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #fff;
  font-size: 0.75rem;
  border-radius: 40px;
  text-align: center;
  opacity: 0;
  pointer-events: auto;
  transition: opacity 0.2s ease;
  overflow-wrap: break-word;
}
.toast.show { opacity: 1; }
.toast.error { background: rgba(229,57,53,0.85); }
.toast.success { background: rgba(44,155,132,0.85); }

/* ============================================================
   14. 通用组件
   ============================================================ */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 30px;
  color: var(--text-muted);
  text-align: center;
  font-size: 0.88rem;
  min-height: 200px;
}
.empty-state-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.35;
  margin-bottom: 4px;
}
.empty-state-text {
  font-size: 0.92rem;
  color: var(--text-secondary);
  font-weight: 500;
}
.empty-state-sub {
  font-size: 0.78rem;
  color: var(--text-weak);
  max-width: 220px;
  line-height: 1.5;
}
.empty-state-spin .empty-state-icon {
  animation: emptySpin 2s linear infinite;
}
.loading-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.25);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: var(--z-overlay);
  display: flex; align-items: center; justify-content: center;
}
.spinner {
  width: 42px; height: 42px;
  border: 3.5px solid rgba(224,90,58,0.15);
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* 公用按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 10px 24px;
  border-radius: 10px;
  font-size: 0.88rem; font-weight: 600;
  transition: all 0.25s var(--ease);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.btn-block { display: flex; width: 100%; }
.btn:active { transform: scale(0.97); }

/* 标签 */
.tag {
  display: inline-flex; align-items: center;
  padding: 2px 8px; font-size: 0.68rem;
  border-radius: 10px; font-weight: 500;
}
.tag-orange { background: var(--tint-pink); color: var(--brand); }
.tag-green { background: var(--tint-green); color: var(--success); }
.tag-red { background: var(--tint-red); color: var(--danger); }
.tag-blue { background: var(--tint-blue); color: var(--info); }

/* 工具�?*/
.text-center { text-align: center; }
.text-brand { color: var(--brand); }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.flex { display: flex; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }

/* ============================================================
   15. 响应式适配（≤480px�?   ============================================================ */
@media (max-width: 480px) {
  .page-title { font-size: 1.35rem; }
  .page-header { padding: 0; }
  .header-row { padding: 6px 16px 6px; }
  .header-icon-btn { width: 34px; height: 34px; }
  .header-right { gap: 6px; }
  .header-online-badge { font-size: 0.6rem; padding: 1px 8px; }
  .section { padding: 16px; }
  .section-title { font-size: 1.05rem; margin-bottom: 14px; }
  .nav-item-text { font-size: 0.6rem; }
  .profile-avatar { width: 84px; height: 84px; }
  .profile-nickname { font-size: 1.05rem; }
  .plaza-input-area { padding: 8px 12px; }
  .plaza-input { padding: 10px 14px; font-size: 0.92rem; }
  .plaza-send-btn { width: 44px; height: 44px; min-width: 44px; }
  .plaza-add-btn { width: 40px; height: 40px; min-width: 40px; }
  .plaza-messages { padding: 8px 6px; }
  .sub-header { padding: 0 8px; }
  .sub-title { font-size: 0.95rem; }
  .sub-body { padding: calc(var(--top-offset) + 16px) 12px calc(var(--bottom-nav-h) + 32px); }
}

/* ============================================================
   16. 平板适配（≥768px）—�?仅修复广场输入框被导航栏遮挡
   ============================================================ */
@media (min-width: 768px) {
  :root { --nav-height: 68px; --nav-bar-height: 68px; --bottom-nav-h: 68px; }

  .profile-avatar { width: 100px; height: 100px; margin-bottom: 16px; }
  .profile-avatar svg { width: 65%; height: 65%; }
  .profile-nickname { font-size: 1.35rem; }
  .profile-hero { padding: calc(var(--top-offset) + 16px) 32px 28px; }
  .profile-hero::before { width: 400px; height: 400px; top: -140px; right: -80px; }
  .profile-hero::after { width: 260px; height: 260px; top: 50%; left: 50%; transform: translate(-50%, -50%); border-radius: 50%; }
}

/* ============================================================
   18. 详情弹出面板 (detail-sheet)
   ============================================================ */
body.detail-open .page-header,
body.detail-open .bottom-nav,
body.sub-panel-open .page-header,
body.sub-panel-open .bottom-nav { display: none !important; }
.detail-sheet { position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: var(--z-modal); background: rgba(0,0,0,0.45); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); display: none; align-items: flex-end; justify-content: center; padding-top: var(--safe-top); }
.detail-sheet.show { display: flex; }
.detail-sheet-inner { background: var(--bg-card); border-radius: 16px 16px 0 0; width: 100%; max-height: 92vh; overflow-y: auto; animation: dsSlideUp 0.3s ease; box-shadow: 0 -4px 30px rgba(0,0,0,0.08); position: relative; padding-bottom: var(--safe-bottom, 0px); }
@keyframes dsSlideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.detail-sheet-inner .detail-cover { width: 100%; aspect-ratio: 16/9; background: var(--bg-light); position: relative; overflow: hidden; flex-shrink: 0; border-radius: 16px 16px 0 0; }
.detail-sheet-inner .detail-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.detail-cover-close { position: absolute; top: 12px; left: 12px; width: 36px; height: 36px; border-radius: 50%; background: rgba(0,0,0,0.35); border: none; color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 5; }
.view-timer { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; display: none; align-items: center; justify-content: center; z-index: 5; }
.view-timer-text { position: absolute; font-size: 0.85rem; font-weight: 700; color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,0.4); }
.detail-sheet-inner .detail-body { padding: 16px 18px; }
.detail-sheet-inner .detail-title { font-size: 1.1rem; font-weight: 700; color: var(--text); line-height: 1.5; margin-bottom: 12px; }
.detail-sheet-inner .detail-text { font-size: 0.88rem; line-height: 1.8; color: var(--text); }
.detail-sheet-inner .detail-author { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-top: 1px solid var(--border); }

.detail-sheet-inner .detail-author .da-info { flex: 1; min-width: 0; }
.detail-sheet-inner .detail-author .da-info .da-name-row { display: flex; align-items: center; gap: 6px; }
.detail-sheet-inner .detail-author .da-info .name { font-size: 0.85rem; font-weight: 600; color: var(--text); }
.detail-sheet-inner .detail-author .da-info .meta { font-size: 0.68rem; color: var(--text-weak); margin-top: 3px; }
.detail-sheet-inner .detail-title .da-cat {
  display: inline-block; vertical-align: middle;
  font-size: 0.6rem; color: var(--brand); background: rgba(224,90,58,0.08);
  padding: 1px 6px; border-radius: 4px; margin-left: 4px;
}
.detail-sheet-inner .detail-author .da-info .da-cat {
  font-size: 0.6rem; color: var(--brand); background: rgba(224,90,58,0.08);
  padding: 1px 6px; border-radius: 4px; flex-shrink: 0;
}
.detail-sheet-inner .detail-author .da-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.detail-sheet-inner .detail-author .da-contact { padding: 6px 14px; border: none; border-radius: 8px; background: var(--brand); color: #fff; font-size: 0.72rem; font-weight: 600; cursor: pointer; font-family: inherit; white-space: nowrap; flex-shrink: 0; }
.detail-sheet-inner .detail-author .da-contact:active { background: var(--brand-dark); }
.detail-sheet-inner .detail-author .da-heart { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border: none; border-radius: 50%; background: var(--tint-pink); color: var(--danger); cursor: pointer; flex-shrink: 0; font-size: 1rem; transition: transform 0.15s; }
.detail-sheet-inner .detail-author .da-heart:active { transform: scale(0.85); }
.detail-sheet-inner .detail-author .da-heart.liked svg { fill: var(--danger); stroke: var(--danger); }
.detail-sheet-inner .detail-author .da-heart.edit,
.detail-sheet-inner .detail-author .da-heart.delete { display: inline-flex; align-items: center; justify-content: center; padding: 0 14px; height: 32px; border: none; border-radius: 8px; cursor: pointer; flex-shrink: 0; font-size: 0.82rem; font-weight: 600; transition: all 0.15s; font-family: inherit; color: #fff; width: auto; }
.detail-sheet-inner .detail-author .da-heart.edit { background: var(--brand); }
.detail-sheet-inner .detail-author .da-heart.delete { background: var(--danger); }
.detail-sheet-inner .detail-author .da-heart.edit:active,
.detail-sheet-inner .detail-author .da-heart.delete:active { opacity: 0.85; transform: scale(0.96); }
.detail-sheet-inner .detail-author .da-report { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border: none; border-radius: 50%; background: var(--bg-light); color: var(--text-muted); cursor: pointer; flex-shrink: 0; font-size: 0.8rem; }
.detail-sheet-inner .detail-author .da-report:active { background: var(--border); }
.detail-sheet-inner .detail-author .da-pet-btn {
  padding: 6px 14px; border: none; border-radius: 8px; background: var(--brand); color: #fff;
  font-size: 0.72rem; font-weight: 600; cursor: pointer; font-family: inherit;
  white-space: nowrap; flex-shrink: 0; margin-right: 4px;
}
.detail-sheet-inner .detail-author .da-pet-btn:active { background: var(--brand-dark); }
.detail-sheet-inner .detail-pet-body { padding: 0; }
.detail-sheet-inner .detail-pet-body .dp-desc {
  font-size: 0.88rem; line-height: 1.8; color: var(--text); margin-bottom: 12px;
  white-space: pre-wrap; word-break: break-word;
}
.detail-sheet-inner .detail-pet-body .dp-horn {
  font-size: 0.82rem; color: var(--warning); margin-bottom: 8px;
  display: flex; align-items: center; gap: 4px;
}
.detail-sheet-inner .detail-pet-body .dp-countdown {
  font-size: 0.82rem; color: var(--text-muted); margin-top: 12px;
  display: flex; align-items: center; gap: 4px;
}
.detail-sheet-inner .detail-pet-body .dp-countdown-expired {
  color: var(--danger); font-weight: 600;
}
.detail-sheet-inner .detail-pet-body .dp-countdown .dp-countdown-timer {
  font-weight: 600; color: var(--brand);
}

/* 分类专属信息行 */
.detail-cat-info { padding:6px 0; font-size:0.9rem; color:var(--text-muted); display:flex; align-items:center; gap:4px; }

/* 投票区 */
.detail-poll { padding:12px 0; }
.poll-btn { display:block; width:100%; padding:10px; margin-bottom:6px; border:1.5px solid var(--border); border-radius:10px; background:var(--bg-card); color:var(--text); font-size:0.85rem; text-align:left; cursor:pointer; box-sizing:border-box; }
.poll-btn:hover { border-color:var(--brand); background:var(--brand-ghost); }
.poll-btn .poll-bar { height:4px; background:var(--brand); border-radius:2px; margin-top:4px; transition:width 0.3s; }

/* 投票/签到按钮 */
.da-vote, .da-signin { background:var(--brand-ghost); color:var(--brand); border:1px solid var(--brand); border-radius:16px; padding:4px 12px; font-size:0.8rem; cursor:pointer; font-family:inherit; white-space:nowrap; flex-shrink:0; }
.da-vote:hover, .da-signin:hover, .da-vote:active, .da-signin:active { background:var(--brand); color:#fff; }

/* 签到弹窗 */
.signin-modal { position:fixed; inset:0; z-index:100010; display:flex; align-items:center; justify-content:center; }
.signin-modal-bg { position:absolute; inset:0; background:rgba(0,0,0,0.45); }
.signin-modal-box { position:relative; background:var(--bg-card); border-radius:16px; width:90vw; max-width:340px; padding:24px; box-shadow:0 8px 40px rgba(0,0,0,0.2); animation:dsSlideUp 0.25s ease; }
.signin-modal-title { font-size:1rem; font-weight:700; color:var(--text); margin-bottom:8px; }
.signin-modal-desc { font-size:0.82rem; color:var(--text-muted); margin-bottom:16px; }
.signin-input { width:100%; border:1.5px solid var(--border); border-radius:10px; padding:12px; font-size:1.2rem; text-align:center; letter-spacing:8px; outline:none; box-sizing:border-box; font-family:inherit; }
.signin-input:focus { border-color:var(--brand); box-shadow:0 0 0 3px rgba(224,90,58,0.08); }
.signin-error { color:var(--danger); font-size:0.8rem; margin-top:8px; text-align:center; }
.signin-modal-btns { display:flex; gap:10px; margin-top:16px; }
.signin-btn-cancel { flex:1; padding:10px; background:var(--bg-light); border:none; border-radius:10px; color:var(--text-secondary); cursor:pointer; font-size:0.85rem; font-family:inherit; }
.signin-btn-ok { flex:1; padding:10px; background:var(--brand-gradient); border:none; border-radius:10px; color:#fff; cursor:pointer; font-size:0.85rem; font-weight:600; font-family:inherit; }

/* ---------- 宠物卡片全屏弹窗 ---------- */
.pet-card-overlay {
  position: fixed; inset: 0; z-index: var(--z-modal);
  background: rgba(0,0,0,0.45); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  animation: fadeInSimple 0.2s ease;
}
.pet-card-full-wrapper {
  position: relative; width: calc(100% - 32px); max-width: 440px; max-height: 88vh;
  overflow-y: auto; border-radius: 20px; box-shadow: 0 8px 40px rgba(0,0,0,0.18);
  animation: modalIn 0.25s ease;
}
.pet-card-full-wrapper::-webkit-scrollbar { display: none; }
.pet-card-full {
  background: var(--bg-card); border-radius: 20px; padding: 18px; margin: 0; cursor: default;
}
.pet-card-full .pet-title { padding: 0; border-bottom: 1px solid var(--border); padding-bottom: 12px; margin-bottom: 12px; }
.pet-card-full .pet-title-text { font-size: 1.05rem; }
.pet-card-full .pet-content { padding: 0; font-size: 0.88rem; line-height: 1.7; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; word-break: break-all; overflow-wrap: break-word; }
.pet-card-full .pet-footer { margin-top: 14px; }
.pet-card-full .pet-signin-row { padding: 0 0 0 0; }
.pet-card-timer {
  text-align:center; padding:4px 0 10px 0; font-size:0.72rem; color:var(--text-muted);
  border-bottom:1px solid var(--border); margin-bottom:2px;
}
.pet-card-timer-text { font-weight:500; }

/* ============================================================
   19. 举报弹窗 (report)
   ============================================================ */
.report-overlay {
  display: none; z-index: var(--z-modal);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.report-overlay.show { display: flex; }
.report-card { background: var(--bg-card); border-radius: 24px; max-width: 420px; width: calc(100% - 32px); max-height: 80vh; overflow-y: auto; padding: 24px 20px 20px; box-shadow: 0 12px 40px rgba(0,0,0,0.2); animation: modalIn 0.2s ease; }
.report-card::-webkit-scrollbar { display: none; }
.report-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.report-title { font-size: 1.1rem; font-weight: 700; color: var(--text); }
.report-close { width: 30px; height: 30px; border-radius: 50%; border: none; background: transparent; font-size: 1.1rem; color: var(--text-secondary); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.report-close:active { background: var(--border); }
.report-body { }
.report-sub { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 10px; }
.report-options { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.report-opt { padding: 8px 14px; border-radius: 18px; border: 1px solid var(--border); font-size: 0.82rem; color: var(--text); cursor: pointer; transition: all 0.15s; background: var(--bg-card); user-select: none; }
.report-opt:active { transform: scale(0.96); }
.report-opt.selected { border-color: var(--brand); background: var(--tint-pink); color: var(--brand); font-weight: 600; }
.report-field { margin-bottom: 14px; }
.report-label { font-size: 0.8rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; display: block; }
.report-textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 14px; font-size: 0.85rem; color: var(--text); background: var(--bg-card); outline: none; font-family: inherit; resize: none; min-height: 72px; box-sizing: border-box; transition: border-color 0.2s; }
.report-textarea:focus { border-color: var(--brand); }
.report-textarea::placeholder { color: var(--text-weak); }
.report-counter { text-align: right; font-size: 0.7rem; color: var(--text-weak); margin-top: 4px; }
.report-upload { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px; border: 2px dashed var(--border); border-radius: 16px; background: var(--bg-light); cursor: pointer; transition: all 0.15s; }
.report-upload-placeholder { display: flex; align-items: center; gap: 8px; }
.report-upload:active { transform: scale(0.98); }
.report-upload.has-img { border-style: solid; border-color: var(--brand); background: var(--tint-pink); padding: 6px; }
.report-upload-icon { font-size: 1.5rem; display: flex; align-items: center; }
.report-upload-tip { font-size: 0.78rem; color: var(--text-muted); }
.report-preview { width: 100%; max-height: 180px; object-fit: contain; border-radius: 10px; display: block; }
.report-remove-img { padding: 6px 12px; border: 1px solid #EF9A9A; border-radius: 12px; background: transparent; color: var(--danger); font-size: 0.75rem; cursor: pointer; margin-top: 6px; font-family: inherit; }
.report-remove-img:active { background: var(--tint-red); }
.report-submit { padding: 12px 28px; border: none; border-radius: 14px; background: var(--brand-gradient); color: white; font-size: 0.95rem; font-weight: 600; cursor: pointer; transition: all 0.2s; box-shadow: 0 4px 12px rgba(224,90,58,0.25); margin-top: 4px; margin-left: auto; display: block; font-family: inherit; }
.report-submit:active { transform: scale(0.97); }
.report-submit:disabled { opacity: 0.5; cursor: default; }

.report-got-it {
  width: 100%; padding: 12px; border: 1px solid var(--border);
  border-radius: 14px; background: var(--bg-card); color: var(--text-primary);
  font-size: 0.9rem; font-weight: 600; cursor: pointer;
  transition: all 0.2s; font-family: inherit;
}
.report-got-it:active { background: var(--bg-light); transform: scale(0.97); }

.report-divider { border: none; border-top: 1px dashed var(--card-nested-border); margin: 14px 0; }
.report-row { display: flex; justify-content: space-between; align-items: center; padding: 3px 0; font-size: 0.85rem; color: var(--text); }
.report-row .label { color: var(--text-muted); }
.report-poll-table { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: 0.85rem; }
.report-poll-table th { text-align: left; padding: 4px 6px; border-bottom: 1px solid var(--card-nested-border); color: var(--text-secondary); font-weight: 500; }
.report-poll-table td { padding: 4px 6px; border-bottom: 1px solid var(--list-muted); }
.report-poll-table .rank-1 { font-weight: 700; color: #E6A23C; }
.report-poll-table .rank-2 { font-weight: 600; color: var(--text-secondary); }
.report-poll-table .rank-3 { color: #B87333; }
.report-summary { font-size: 0.85rem; color: var(--text); line-height: 1.7; }

/* ---------- 首页便签横板卡片 ---------- */
.article-card { background: var(--bg-card); border-radius: 12px; border-left: 3px solid var(--brand); padding: 14px 16px; margin-bottom: 10px; box-shadow: 0 1px 4px rgba(78,59,44,0.06); display: flex; flex-direction: column; gap: 6px; cursor: pointer; transition: box-shadow 0.15s; }
.article-card:active { box-shadow: 0 2px 8px rgba(78,59,44,0.1); }
.article-card-header { display: flex; align-items: center; justify-content: space-between; }
.article-card-title { font-size: 0.95rem; font-weight: 600; color: var(--text); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.article-card-status { font-size: 0.7rem; padding: 2px 8px; border-radius: 10px; white-space: nowrap; margin-left: 10px; }
.article-card-status.closed { background: var(--list-muted); color: var(--text-muted); }
.article-card-status.completed { background: var(--tint-blue); color: var(--tint-blue-text, #2563eb); }
.article-card-status.active { background: var(--tint-green); color: var(--tint-green-text); }
.article-card-status.pending { background: var(--tint-orange); color: var(--tint-orange-text); }
.article-card-status.rejected { background: var(--tint-red); color: var(--tint-red-text); }
.article-card-meta { display: flex; align-items: center; gap: 10px; font-size: 0.75rem; color: var(--text-muted); }
.article-card-meta .sep { color: var(--card-nested-border); }
.article-card-footer { display: flex; justify-content: flex-end; align-items: center; gap: 6px; padding-top: 2px; }
.article-card-footer .btn-sm { font-size: 0.72rem; padding: 4px 12px; border-radius: 6px; border: 1px solid var(--card-nested-border); background: var(--bg-card); color: var(--text-secondary); cursor: pointer; }
.article-card-footer .btn-sm:hover { background: var(--bg-light); }
.article-card-city { font-size: 0.7rem; color: var(--text-muted); display: flex; align-items: center; gap: 4px; }
.article-card-city svg { flex-shrink: 0; }
.article-card-favcnt { font-size: 0.7rem; color: var(--danger); display: inline-flex; align-items: center; gap: 3px; }
.article-card-summary { font-size: 0.78rem; color: var(--text-muted); margin-top: 4px; margin-bottom: 2px; line-height: 1.4; }

/* ---------- 签到弹窗 ---------- */
.signin-modal-overlay {
  position: fixed; inset: 0; z-index: var(--z-modal);
  background: rgba(0,0,0,0.45); display: flex;
  align-items: center; justify-content: center;
  animation: fadeInSimple 0.2s ease;
}
.signin-modal-card {
  background: var(--bg-card); border-radius: 24px; width: calc(100% - 40px); max-width: 380px;
  padding: 28px 24px 24px; box-shadow: 0 12px 40px rgba(0,0,0,0.2);
  animation: modalIn 0.25s ease;
}
.signin-modal-title { font-size: 1.1rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.signin-modal-sub { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 16px; }
.signin-modal-card .form-input { width: 100%; box-sizing: border-box; margin-bottom: 10px; }
.signin-modal-card .signin-upload { margin-bottom: 14px; }
.signin-modal-btns { display: flex; gap: 10px; margin-top: 6px; }
.signin-modal-cancel {
  flex: 1; padding: 12px; border-radius: 14px; border: 1px solid var(--border);
  background: var(--bg-light); font-size: 0.88rem; cursor: pointer; font-family: inherit;
}
.signin-modal-cancel:active { background: var(--border); }
.signin-modal-submit {
  flex: 1; padding: 12px; border-radius: 14px; border: none;
  background: var(--brand-gradient); color: #fff; font-size: 0.88rem; font-weight: 600;
  cursor: pointer; font-family: inherit;
}
.signin-modal-submit:active { opacity: 0.85; }

/* ---------- 好友聊天赠送喇叭弹�?---------- */
.horn-gift-overlay {
  position: fixed; inset: 0; z-index: var(--z-modal);
  background: rgba(0,0,0,0.45); display: flex;
  align-items: center; justify-content: center;
}
.horn-gift-card {
  background: var(--bg-card); border-radius: 24px; width: calc(100% - 40px); max-width: 360px;
  padding: 28px 24px 24px; box-shadow: 0 12px 40px rgba(0,0,0,0.2);
}
.horn-gift-title { font-size: 1.05rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.horn-gift-hold { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 16px; }
.horn-gift-hold strong { color: var(--brand); }
.horn-gift-card .form-input { width: 100%; box-sizing: border-box; margin-bottom: 16px; font-size: 1.1rem; }
.horn-gift-btns { display: flex; gap: 10px; }
.horn-gift-cancel {
  flex: 1; padding: 12px; border-radius: 14px; border: 1px solid var(--border);
  background: var(--bg-light); font-size: 0.88rem; cursor: pointer; font-family: inherit;
}
.horn-gift-confirm {
  flex: 1; padding: 12px; border-radius: 14px; border: none;
  background: var(--brand-gradient); color: #fff; font-size: 0.88rem; font-weight: 600;
  cursor: pointer; font-family: inherit;
}
.horn-gift-confirm:active { opacity: 0.85; }

.confirm-overlay {
  display: none; z-index: 100010; /* 硬编码避免 calc(var()) 在 WebView 兼容问题 */
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.confirm-overlay.show { display: flex; }
.confirm-card {
  background: var(--bg-card);
  border-radius: 24px;
  padding: 32px 24px 24px;
  width: min(320px, 90vw);
  box-shadow: 0 12px 40px rgba(0,0,0,0.2);
  border: 1px solid var(--border);
  animation: modalIn 0.3s var(--ease);
  text-align: center;
}
.confirm-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px; height: 48px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--tint-pink);
  color: var(--brand);
}
.confirm-msg {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.6;
  padding: 0 4px;
}
.confirm-actions { display: flex; gap: 12px; }
.confirm-btn {
  flex: 1;
  padding: 12px;
  border-radius: 14px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
}
.confirm-btn.cancel {
  background: var(--bg-light);
  border: 1px solid var(--border);
  color: var(--text-secondary);
}
.confirm-btn.cancel:active { background: var(--border); }
.confirm-btn.danger {
  background: var(--brand-gradient);
  color: #fff;
  border: none;
  box-shadow: 0 4px 12px rgba(224,90,58,0.25);
}
.confirm-btn.danger:active { transform: scale(0.97); }
.confirm-btn.ok {
  background: var(--brand-gradient);
  color: #fff;
  font-weight: 600;
  border: none;
}
.confirm-btn.ok:active { transform: scale(0.97); }

/* 自定义时间选择�?*/
.time-trigger {
  padding: 10px 16px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  font-family: inherit;
  min-width: 100px;
  text-align: center;
  transition: border-color 0.2s, box-shadow 0.2s;
  user-select: none;
  -webkit-user-select: none;
}
.time-trigger:hover, .time-trigger:active { border-color: var(--brand); }

.time-picker-overlay {
  display: none; position: fixed; z-index: 100020;
  inset: 0; background: rgba(0,0,0,0.4);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  align-items: center; justify-content: center;
}
.time-picker-overlay.show { display: flex; }

.time-picker-popup {
  background: var(--bg-card);
  border-radius: 20px;
  width: calc(100% - 48px); max-width: 340px;
  padding: 24px 20px 24px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.18);
  animation: scaleIn 0.2s var(--ease);
  border: 1px solid var(--border);
}

.time-picker-title {
  text-align: center;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 20px;
}

.time-picker-body {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-bottom: 24px;
}

.time-picker-col-wrap {
  flex: 1;
  max-width: 130px;
  position: relative;
  background: var(--bg-light);
  border-radius: 14px;
  overflow: hidden;
}

.time-picker-highlight {
  position: absolute;
  left: 0; right: 0;
  top: 100px; transform: translateY(-50%);
  height: 42px;
  background: rgba(224,90,58,0.06);
  border-top: 1px solid rgba(224,90,58,0.12);
  border-bottom: 1px solid rgba(224,90,58,0.12);
  pointer-events: none;
  z-index: 2;
}

.time-picker-scroll {
  height: 200px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  padding: 80px 0;
  scroll-snap-type: y mandatory;
  position: relative;
  z-index: 3;
  background: transparent;
}
.time-picker-scroll::-webkit-scrollbar { display: none; }

.time-picker-item {
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--text-weak);
  font-family: -apple-system, 'SF Mono', 'SF Pro Display', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  letter-spacing: 1px;
  scroll-snap-align: center;
  transition: color 0.15s;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  font-variant-numeric: tabular-nums;
}
.time-picker-item.selected {
  color: var(--brand);
  font-weight: 700;
}

.time-picker-colon {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
  padding: 0 4px;
}

.time-picker-label {
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 6px;
}

.time-picker-buttons {
  display: flex;
  gap: 12px;
}
.time-picker-btn-cancel {
  flex: 1;
  padding: 12px;
  border-radius: 14px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  background: var(--bg-light);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-family: inherit;
  transition: background 0.15s;
}
.time-picker-btn-cancel:active { background: var(--border); }
.time-picker-btn-ok {
  flex: 1;
  padding: 12px;
  border-radius: 14px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  background: var(--brand-gradient);
  color: #fff;
  border: none;
  font-family: inherit;
  box-shadow: 0 4px 12px rgba(224,90,58,0.2);
  transition: transform 0.15s, box-shadow 0.15s;
}
.time-picker-btn-ok:active { transform: scale(0.97); box-shadow: 0 2px 6px rgba(224,90,58,0.15); }
.prompt-input {
  width: 100%; height: 44px; margin: 0 0 16px;
  border: 1px solid var(--border); border-radius: 10px;
  padding: 0 14px; font-size: 0.92rem; outline: none;
  background: var(--bg); color: var(--text);
  box-sizing: border-box;
}
.prompt-input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }

.lightbox-overlay {
  position: fixed; inset: 0; z-index: var(--z-modal);
  background: rgba(0,0,0,0.92);
  display: none; align-items: center; justify-content: center;
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.lightbox-overlay.show { display: flex; }
.lightbox-bg { position: absolute; inset: 0; }
.lightbox-img {
  max-width: 90vw; max-height: 85vh;
  object-fit: contain; border-radius: 8px;
  z-index: var(--z-base); position: relative;
  box-shadow: 0 8px 40px rgba(0,0,0,0.35);
  transition: opacity 0.25s ease;
}
.lightbox-close {
  position: fixed; top: 16px; right: 16px; z-index: 10;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.12); border: none;
  color: #fff; font-size: 1.2rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s;
}
.lightbox-close:hover { background: rgba(255,255,255,0.2); }
.lightbox-arrow {
  position: fixed; top: 50%; z-index: 10;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,0.1); border: none;
  color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s; transform: translateY(-50%);
}
.lightbox-arrow:hover { background: rgba(255,255,255,0.22); }
.lightbox-prev { left: 12px; }
.lightbox-next { right: 12px; }
.lightbox-counter {
  position: fixed; bottom: 28px; left: 50%; z-index: 10;
  transform: translateX(-50%);
  padding: 6px 16px; border-radius: 20px;
  background: rgba(0,0,0,0.5); color: #fff;
  font-size: 0.82rem; font-weight: 600;
  letter-spacing: 1px;
}

.user-search-card {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: 12px;
  background: var(--bg-card); cursor: pointer;
  border: 1px solid var(--border);
  transition: background 0.15s, box-shadow 0.15s;
}
.user-search-card:hover { background: var(--bg-light); box-shadow: 0 2px 10px rgba(0,0,0,0.06); }
.user-search-card + .user-search-card { margin-top: 8px; }

.user-search-card .usc-name { font-weight: 600; font-size: 0.95rem; }
.user-search-card .usc-city { font-size: 0.75rem; color: var(--text-muted); }

.user-profile-overlay {
  display: none; z-index: var(--z-modal); background: rgba(0,0,0,0.4);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.user-profile-overlay.show { display: flex; }
.user-profile-card {
  background: var(--bg-card); border-radius: 16px; width: 90%; max-width: 360px;
  padding: 24px; animation: upFadeIn 0.25s ease;
  box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}
.user-profile-card .up-header {
  display: flex; align-items: center; gap: 14px; margin-bottom: 16px;
}

.user-profile-card .up-info { flex: 1; min-width: 0; text-align: left; }
.user-profile-card .up-name { font-size: 1.1rem; font-weight: 700; margin-bottom: 2px; }
.user-profile-card .up-meta { font-size: 0.78rem; color: var(--text-muted); line-height: 1.4; }
.user-profile-card .up-meta .up-meta-line { display: flex; justify-content: space-between; gap: 8px; }
.user-profile-card .up-meta .up-meta-line span { flex-shrink: 0; }
.user-profile-card .up-meta b { color: var(--danger); }
.user-profile-card .up-bio {
  font-size: 0.85rem; color: var(--text-muted); line-height: 1.5;
  padding: 10px 14px; margin-bottom: 4px;
  background: var(--bg-light); border-radius: 10px;
  text-align: left; word-break: break-word;
  min-height: 0;
}
.user-profile-card .up-bio.is-empty { color: var(--text-weak); font-style: italic; }
.user-profile-card .up-actions { display: flex; gap: 10px; margin-top: 16px; }
.user-profile-card .up-actions button {
  flex: 1; padding: 10px 0; border-radius: 22px; border: none;
  font-size: 0.92rem; font-weight: 600; cursor: pointer;
  transition: transform 0.12s, opacity 0.12s;
}
.user-profile-card .up-actions button:active { transform: scale(0.96); }
.user-profile-card .up-btn-add {
  background: var(--brand); color: #fff;
}
.user-profile-card .up-btn-close {
  background: var(--bg-light); color: var(--text);
}

/* Blocked list overlay */
.blocked-list-overlay {
  display: none; z-index: 100010; background: rgba(0,0,0,0.4);
}
.blocked-list-overlay.show { display: flex; }
.blocked-list-card {
  background: var(--bg-card); border-radius: 16px; width: 90%; max-width: 380px;
  max-height: 70vh; display: flex; flex-direction: column;
  animation: upFadeIn 0.25s ease;
  box-shadow: 0 12px 40px rgba(0,0,0,0.15);
  overflow: hidden;
}
.bl-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px 12px; flex-shrink: 0;
}
.bl-title {
  font-size: 1.05rem; font-weight: 700; color: var(--text);
}
.bl-close {
  background: none; border: none; cursor: pointer;
  padding: 4px; color: var(--text-muted);
  display: flex; align-items: center;
  transition: color 0.15s;
}
.bl-close:hover { color: var(--text); }
.bl-body {
  padding: 0 20px 20px; overflow-y: auto; flex: 1;
}
.bl-body .empty-state {
  text-align: center; color: var(--text-muted); font-size: 0.88rem;
  padding: 30px 0;
}
.bl-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 0; border-bottom: 1px solid var(--border);
}
.bl-item:last-child { border-bottom: none; }
.bl-item-avatar {
  width: 40px; height: 40px; border-radius: var(--avatar-radius);
  background: var(--bg-light); display: flex; align-items: center;
  justify-content: center; font-size: 1.1rem; flex-shrink: 0;
  overflow: hidden;
}
.bl-item-avatar.bl-avatar-img {
  object-fit: cover;
}
.bl-item-avatar.bl-avatar-fallback {
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-light);
}
.bl-item-name {
  flex: 1; font-size: 0.92rem; font-weight: 500; color: var(--text);
  display: flex; align-items: center; gap: 8px;
}
.bl-item-days {
  font-size: 0.75rem; color: var(--text-muted); font-weight: 400;
}
.bl-item-btn {
  background: var(--brand); color: #fff; border: none;
  border-radius: 16px; padding: 6px 14px; font-size: 0.8rem;
  cursor: pointer; transition: transform 0.12s;
}
.bl-item-btn:active { transform: scale(0.95); }

/* 扎堆 - 热门城市 */
.add-menu-icon.hot-icon { background: var(--tint-orange); color: var(--tint-orange-text); }

.hot-city-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 0; border-bottom: 1px solid var(--border);
  cursor: pointer; transition: background 0.15s;
}
.hot-city-item:last-child { border-bottom: none; }
.hot-city-item:active { background: var(--card-nested-active); }
.hot-city-item.active { background: var(--tint-orange); border-radius: 8px; padding-left: 8px; padding-right: 8px; margin: 0 -8px; }
.hot-city-rank {
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--bg-light); display: flex; align-items: center;
  justify-content: center; font-size: 0.75rem; font-weight: 700;
  color: var(--text-muted); flex-shrink: 0;
}
.hot-city-item:nth-child(1) .hot-city-rank { background: var(--tint-orange-text); color: #fff; }
.hot-city-item:nth-child(2) .hot-city-rank { background: #E0E0E0; color: #616161; }
.hot-city-item:nth-child(3) .hot-city-rank { background: #FFCC80; color: #BF360C; }
.hot-city-info {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; gap: 6px;
}
.hot-city-name {
  font-size: 0.92rem; font-weight: 600; color: var(--text);
}
.hot-city-bar-wrap {
  height: 4px; background: var(--bg-light); border-radius: 2px; overflow: hidden;
}
.hot-city-bar {
  height: 100%; background: linear-gradient(90deg, var(--brand), var(--tint-orange-text));
  border-radius: 2px; transition: width 0.4s ease;
}
.hot-city-count {
  font-size: 0.75rem; color: var(--brand); font-weight: 600;
  white-space: nowrap; flex-shrink: 0;
}

.gi-overlay {
  display: none; z-index: var(--z-modal); background: rgba(0,0,0,0.4);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.gi-overlay.show { display: flex; }
.gi-card {
  background: var(--bg-card); border-radius: 20px;
  width: 90%; max-width: 380px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.15);
  animation: giFadeIn 0.25s ease;
  overflow: hidden;
}
@keyframes giFadeIn { from { opacity:0; transform:translateY(12px); } to { opacity:1; transform:translateY(0); } }
.gi-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px 12px;
}
.gi-title { font-size: 1.1rem; font-weight: 700; color: var(--text); }
.gi-close-btn {
  width: 34px; height: 34px; border-radius: 50%;
  border: none; background: var(--bg-light);
  font-size: 1.1rem; color: var(--text-muted); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s;
}
.gi-close-btn:active { background: var(--border); }
.gi-body { padding: 0 20px 20px; }
.gi-avatar-row {
  display: flex; flex-direction: row; align-items: flex-start;
  gap: 14px;
  margin-bottom: 12px;
}
.gi-avatar {
  width: 64px; height: 64px; border-radius: var(--avatar-radius);
  overflow: hidden; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-light);
}
.gi-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--avatar-radius); }

.gi-name { font-size: 1rem; font-weight: 700; color: var(--text); }
.gi-name-col { flex: 1; min-width: 0; }
.gi-desc {
  font-size: 0.85rem; color: var(--text-secondary);
  background: var(--bg-light); border-radius: 12px;
  padding: 12px 14px; margin-bottom: 12px;
  line-height: 1.5; white-space: pre-wrap; word-break: break-word;
}
.gi-meta {
  display: flex; justify-content: flex-start; gap: 18px;
  padding: 3px 0 0;
  font-size: 0.8rem; color: var(--text-muted);
}
.gi-meta span { display: flex; align-items: center; gap: 4px; }
.gi-meta b { color: var(--brand); font-weight: 600; }
.gi-creator {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding-top: 12px; border-top: 1px solid var(--border);
  font-size: 0.82rem; color: var(--text-secondary);
}
.gi-creator b { color: var(--text); font-weight: 600; }
.gi-actions {
  display: flex; gap: 12px;
  padding: 0 20px 20px;
}
.gi-actions button {
  flex: 1; padding: 12px 0; border-radius: 14px; border: none;
  font-size: 0.95rem; font-weight: 600; cursor: pointer;
  transition: transform 0.12s, opacity 0.12s;
}
.gi-actions button:active { transform: scale(0.96); }
.gi-btn-accept { background: var(--brand-gradient); color: #fff; }
.gi-btn-reject { background: var(--bg-light); color: var(--text); }

.notif-list { padding: 8px 0; }
.notif-item {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 14px 16px 14px 13px; margin: 4px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid transparent;
  border-radius: var(--avatar-radius); cursor: pointer;
  box-shadow: 0 1px 3px rgba(78,59,44,0.04);
  transition: border-left-color 0.2s, background 0.15s;
}
.notif-item:active { background: var(--bg-light); }
.notif-item.unread {
  border-left-color: var(--brand);
  background: rgba(224,90,58,0.06);
}
.notif-item.read {
  border-left-color: transparent;
  background: var(--bg-card);
}
.notif-icon {
  width: 36px; height: 36px; border-radius: var(--avatar-radius-sm);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; margin-top: 2px;
}
.notif-icon svg { width: 18px; height: 18px; }
.notif-icon--friend { background: var(--tint-orange); color: var(--warning); }
.notif-icon--group { background: var(--tint-blue); color: var(--info); }
.notif-icon--horn { background: var(--tint-yellow); color: var(--tint-yellow-text); }
.notif-icon--success { background: var(--tint-green); color: var(--success); }
.notif-body { flex: 1; min-width: 0; }
.notif-body .notif-title-text { font-size: 0.875rem; color: var(--text); line-height: 1.4; }
.notif-body .notif-content { font-size: 0.75rem; color: var(--text-muted); margin-top: 2px; }
.notif-body .notif-time { font-size: 0.7rem; color: var(--text-muted); margin-top: 4px; }
.notif-arrow {
  flex-shrink: 0; font-size: 1.2rem; color: var(--text-muted);
  align-self: center; margin-left: 4px;
}

/* ============================================================
   最近聊�?   ============================================================ */
.rc-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 12px; margin: 4px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--avatar-radius);
  box-shadow: 0 1px 3px rgba(78,59,44,0.04);
  cursor: pointer; transition: background 0.15s;
}
.rc-item:active { background: var(--bg-light); }
.rc-pinned {
  background: var(--list-pinned); border-left: none;
}
.rc-muted {
  background: var(--list-muted); opacity: 0.78;
  border-left: 3px solid var(--border);
  border-style: none none none solid;
}
.rc-muted .rc-name { color: var(--text-muted); }
.rc-muted .rc-msg { color: var(--text-weak); }
.rc-muted .rc-time { color: var(--text-weak); opacity: 0.6; }
.rc-muted .rc-avatar,
.rc-muted .rc-avatar-text { opacity: 0.65; }

.rc-avatar--system {
  background: var(--tint-yellow-text); font-size: 0;
}
.rc-system-notif {
  border-left: 3px solid var(--tint-yellow-text);
}
.rc-avatar-text--stranger {
  background: var(--warning);
}
.rc-avatar-wrap, .friend-avatar-wrap { position: relative; flex-shrink: 0; }
.rc-avatar-badge {
  position: absolute; top: -5px; right: -5px;
  min-width: 18px; height: 18px;
  background: var(--danger); color: #fff;
  font-size: 0.62rem; font-weight: 600;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 5px; box-sizing: border-box;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.rc-info { flex: 1; min-width: 0; }
.rc-name {
  font-size: 0.92rem; font-weight: 600; color: var(--text);
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
}
.rc-msg {
  font-size: 0.75rem; color: var(--text-muted);
  margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  max-width: 200px;
}

.rc-at-mention {
  color: #EF5350; font-weight: 600;
}

.rc-tag {
  font-size: 0.62rem; font-weight: 500; padding: 2px 6px;
  border-radius: 4px; line-height: 1.3; flex-shrink: 0;
}
.rc-tag--stranger {
  background: var(--tint-orange); color: var(--warning);
}
.rc-tag--group {
  background: var(--tint-blue); color: var(--info);
}
.rc-tag--pinned {
  background: rgba(224,90,58,0.1); color: var(--brand);
}

.rc-time {
  font-size: 0.68rem; color: var(--text-weak); flex-shrink: 0;
  align-self: center; white-space: nowrap;
}
.rc-muted-icon {
  flex-shrink: 0; align-self: center;
  color: var(--text-weak); opacity: 0.5;
  margin-left: 2px;
}

.rc-divider {
  padding: 8px 16px 4px; margin: 4px 12px 0;
  font-size: 0.7rem; color: var(--text-muted);
  font-weight: 500; border-top: 1px solid var(--border);
  margin-top: 10px; padding-top: 10px;
}
.rc-divider span { background: var(--bg); padding: 0 8px; }

/* ============================================================
   聊天面板
   ============================================================ */
.chat-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  z-index: 100000; background: var(--bg); display: none; flex-direction: column;
  padding-top: var(--safe-top);
  padding-bottom: var(--safe-bottom);
}
.chat-overlay.show { display: flex; }
/* 键盘弹出时输入框/聊天的 bottom 定位由 JS updateLayoutHeights() 动态处理
   （需区分 adjustResize / 非 adjustResize 设备，CSS 无法做条件判断） */

.chat-header {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 12px 12px 6px;
  background: var(--bg-card); border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.chat-back-btn {
  width: 36px; height: 36px; border-radius: 50%;
  border: none; background: none; font-size: 1.3rem;
  color: var(--text); cursor: pointer; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0;
}
.chat-back-btn:active { background: var(--bg-light); }

.chat-header-info { flex: 1; min-width: 0; }
.chat-header-name { font-size: 0.95rem; font-weight: 600; color: var(--text); }
.chat-header-tag { font-size: 0.65rem; color: var(--text-muted); margin-top: 1px; }
.chat-search-btn {
  width: 36px; height: 36px; border-radius: 10px;
  border: none; background: none; font-size: 1.1rem;
  color: var(--text-weak); cursor: pointer; display: flex;
  align-items: center; justify-content: center; flex-shrink: 0;
}
.chat-search-btn:active { background: var(--bg-light); }
.chat-search-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; background: var(--bg-card); border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.chat-search-bar input {
  flex: 1; height: 32px; border: 1px solid var(--border);
  border-radius: 8px; padding: 0 10px; font-size: 0.85rem;
  background: var(--bg); outline: none;
}
.chat-search-bar input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.chat-search-bar button {
  height: 32px; padding: 0 14px; border: none; border-radius: 8px;
  background: var(--bg-light); color: var(--text); font-size: 0.8rem; cursor: pointer;
}
.chat-search-mark { background: #FFD54F; color: #333; border-radius: 2px; padding: 0 1px; }

.chat-messages {
  flex: 1; overflow-y: auto; padding: 16px 14px;
  padding-bottom: 16px;
  display: flex; flex-direction: column; gap: 8px;
  -webkit-overflow-scrolling: touch;
}

.chat-time-divider {
  text-align: center; font-size: 0.68rem; color: var(--text-weak);
  padding: 8px 0; user-select: none;
}

.chat-bubble-row {
  display: flex; max-width: 88%; align-items: flex-end; gap: 6px;
}
.chat-bubble-row--sent { align-self: flex-end; flex-direction: row-reverse; }
.chat-bubble-row--received { align-self: flex-start; flex-direction: row; }

.chat-bubble {
  padding: 10px 14px; border-radius: 12px;
  font-size: 0.9rem; line-height: 1.45; word-break: break-word;
  position: relative;
}
.chat-bubble--sent {
  background: var(--bubble-sent); color: var(--text);
  border-bottom-right-radius: 4px;
  margin-left: auto;
}
.chat-bubble--received {
  background: var(--bg-card); color: var(--text);
  border: 1px solid var(--border);
  border-bottom-left-radius: 4px;
}
.chat-bubble-time {
  font-size: 0.6rem; margin-top: 4px; opacity: 0.7;
  text-align: right;
}
.chat-bubble--received .chat-bubble-time { opacity: 0.55; }

/* --- 系统消息（居中通知样式�?--- */
.chat-system-msg-row {
  display: flex; justify-content: center; padding: 8px 16px;
}
.chat-system-msg {
  display: inline-flex; align-items: flex-start; gap: 6px;
  max-width: 85%; background: #F3F4F6; border-radius: 10px;
  padding: 8px 14px; line-height: 1.5;
}
.chat-system-msg--icon {
  font-size: 0.9rem; flex-shrink: 0; margin-top: 1px;
}
.chat-system-msg--text {
  font-size: 0.82rem; color: #6B7280; word-break: break-word;
}

.chat-empty {
  flex: 1; display: flex; align-items: center; justify-content: center;
  color: var(--text-muted); font-size: 0.9rem;
}

/* --- 消息长按/右键菜单 --- */
.msg-context-menu {
  display: none; position: fixed; z-index: var(--z-panel);
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  padding: 6px 0; min-width: 140px;
  animation: msgCmIn 0.15s ease-out;
}
@keyframes msgCmIn { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: scale(1); } }
.msg-context-menu.show { display: block; }
.msg-cm-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; font-size: 0.85rem; color: var(--text-primary);
  cursor: pointer; white-space: nowrap;
}
.msg-cm-item:hover { background: var(--hover); }
.msg-cm-item.danger { color: var(--danger); }
.msg-cm-item svg { flex-shrink: 0; }

/* --- 转发选择�?--- */
.forward-overlay {
  position: fixed; inset: 0; z-index: var(--z-modal);
  background: rgba(0,0,0,0.4); display: flex; align-items: center; justify-content: center;
}
.forward-picker {
  width: 90%; max-width: 380px; max-height: 60vh;
  background: var(--bg-card); border-radius: 16px;
  display: flex; flex-direction: column; overflow: hidden;
  animation: fwdPickerIn 0.2s ease-out;
}
@keyframes fwdPickerIn { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.forward-picker-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--border);
  font-size: 0.95rem; font-weight: 600;
}
.forward-picker-close {
  background: none; border: none; font-size: 1.1rem; color: var(--text-secondary);
  cursor: pointer; padding: 4px;
}
.forward-picker-search {
  margin: 10px 12px; padding: 10px 14px;
  border: 1px solid var(--border); border-radius: 10px;
  background: var(--bg); font-size: 0.85rem; outline: none;
}
.forward-picker-search:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.forward-picker-list {
  flex: 1; overflow-y: auto; padding: 4px 0;
}
.forward-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; cursor: pointer; transition: background 0.15s;
}
.forward-item:hover { background: var(--hover); }
.forward-avatar-wrap { position: relative; flex-shrink: 0; }
.forward-avatar-wrap .avatar {
  --av-size: 40px; font-size: 0.9rem;
}
.forward-item-name {
  font-size: 0.9rem; font-weight: 500; color: var(--text-primary);
}
.forward-tag {
  display: inline-block; vertical-align: middle;
  font-size: 0.65rem; font-weight: 500; padding: 1px 5px;
  border-radius: 3px; margin-left: 6px; line-height: 1.4;
}
.forward-tag--group { background: var(--brand-light); color: var(--brand); }
.forward-tag--stranger { background: var(--tint-orange); color: var(--tint-orange-text); }
.forward-item-sub {
  font-size: 0.75rem; color: var(--text-secondary);
}
/* --- 引用回复�?--- */
.chat-quote-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; background: var(--bg);
  border-top: 1px solid var(--border); font-size: 0.8rem;
}
.chat-quote-content {
  flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--text-secondary); padding-left: 8px;
  border-left: 3px solid var(--brand);
}
.chat-quote-close {
  background: none; border: none; color: var(--text-muted);
  font-size: 1rem; cursor: pointer; padding: 2px 6px;
}

/* --- 引用消息气泡 --- */
.chat-bubble--quote {
  border: 1px solid var(--border) !important;
  padding: 8px 10px !important;
}
.chat-quote-preview {
  font-size: 0.75rem; color: var(--text-muted);
  margin-bottom: 4px; padding-bottom: 4px;
  border-bottom: 1px solid var(--border); overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap;
}
.chat-bubble--sent .chat-quote-preview {
  color: var(--text-muted);
  border-bottom-color: var(--border);
}

/* --- 已撤回消�?--- */
.chat-bubble--failed {
  background: var(--bubble-failed) !important; color: var(--bubble-failed-text) !important;
}
.chat-bubble--failed::after {
  content: "发送失败，点击重试";
  display: block;
  font-size: 0.65rem;
  color: #c0392b;
  margin-top: 4px;
  white-space: nowrap;
}

.chat-bubble--recalled {
  background: transparent !important; border: 1px dashed var(--border) !important;
  color: var(--text-muted); font-style: italic; font-size: 0.8rem;
  padding: 6px 14px !important;
}

/* --- 转发消息 --- */
.chat-bubble--forward {
  background: var(--bg) !important; border: 1px solid var(--border) !important;
  padding: 8px 10px !important;
}
.forward-origin {
  font-size: 0.72rem; color: var(--brand); margin-bottom: 4px;
  display: flex; align-items: center; gap: 4px;
}
.forward-origin svg { flex-shrink: 0; }
.forward-text {
  font-size: 0.85rem; color: var(--text-primary); word-break: break-word;
}
.forward-text.forward-text--image {
  display: flex; align-items: center; gap: 6px; font-size: 0.8rem;
  color: var(--text-secondary);
}

/* --- @提及选择�?--- */
.chat-at-picker {
  display: none; position: absolute; bottom: 100%; left: 0; right: 0;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px 12px 0 0; box-shadow: 0 -4px 16px rgba(0,0,0,0.1);
  max-height: 200px; overflow-y: auto; z-index: 500;
}
.chat-at-picker.show { display: block; }
.chat-at-item {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; cursor: pointer; font-size: 0.85rem;
}
.chat-at-item:hover { background: var(--hover); }
.chat-at-item--all { border-bottom: 1px solid var(--border); }
.chat-at-icon-all {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 700; flex-shrink: 0;
}
.chat-at-item .avatar {
  --av-size: 28px; border-radius: 10px;
}

/* --- 表情面板 --- */
.chat-emoji-panel {
  display: none; position: absolute; bottom: 100%; left: 0; right: 0;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px 12px 0 0; box-shadow: 0 -4px 16px rgba(0,0,0,0.1);
  padding: 8px; z-index: 500;
}
.chat-emoji-panel.show { display: block; }
.chat-emoji-list {
  display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px;
  max-height: 180px; overflow-y: auto;
}
.chat-emoji-item {
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; padding: 6px; cursor: pointer; border-radius: 6px;
  transition: background 0.1s;
}
.chat-emoji-item:hover { background: var(--hover); }

/* 统一表情面板（广�?/ 私聊通用�?*/
.emoji-picker-panel {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: 0 -4px 16px rgba(0,0,0,0.12);
  padding: 8px; display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px;
  max-height: 200px; overflow-y: auto;
}
.emoji-picker-item {
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; padding: 6px; cursor: pointer; border-radius: 6px;
  transition: background 0.1s;
}
.emoji-picker-item:hover { background: var(--hover); }

.chat-input-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; background: var(--bg-card);
  border-top: 1px solid var(--border);
  flex-shrink: 0; position:relative;
}
.chat-input-bar textarea {
  flex: 1; padding: 10px 14px; border-radius: 20px;
  border: 1px solid var(--border); background: var(--bg-light);
  font-size: 0.9rem;
  font-family: inherit;
  line-height: 1.4;
  min-height: 40px;
  max-height: 120px;
  resize: none;
  overflow-y: hidden;
}
.chat-input-bar textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
#chatSendBtn { width:44px; height:44px; font-size:20px; flex-shrink:0; }
#chatSendBtn:disabled { opacity:0.5; }

.nav-chat-badge {
  position: absolute; top: 0; right: 4px;
  min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 8px; background: var(--danger); color: #fff;
  font-size: 0.6rem; font-weight: 700; line-height: 16px;
  text-align: center; pointer-events: none;
}
.friends-tab-badge {
  display: inline-block; min-width: 16px; height: 16px;
  margin-left: 4px; padding: 0 4px; border-radius: 8px;
  background: var(--danger); color: #fff;
  font-size: 0.6rem; font-weight: 700; line-height: 16px;
  text-align: center; vertical-align: middle;
}

.group-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 12px; margin: 4px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--avatar-radius);
  box-shadow: 0 1px 3px rgba(78,59,44,0.04);
  cursor: pointer;
  transition: background 0.15s;
}
.group-item:active { background: var(--bg-light); }
.group-pinned { background: var(--list-pinned); }
.group-avatar-wrap { position: relative; flex-shrink: 0; }
.group-avatar-badge {
  position: absolute; top: -5px; right: -5px;
  min-width: 18px; height: 18px;
  background: var(--danger); color: #fff;
  font-size: 0.62rem; font-weight: 600;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 5px; box-sizing: border-box; z-index: var(--z-base);
}
.group-item-info {
  flex: 1; min-width: 0;
}
.group-item-name {
  font-size: 0.92rem; font-weight: 600; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.group-item-remark {
  font-size: 0.72rem; color: var(--text-muted); font-weight: 400; margin-right: 4px;
}
.group-item-msg {
  font-size: 0.75rem; color: var(--text-muted);
  margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  max-width: 220px;
}
.group-item-meta {
  font-size: 0.68rem; color: var(--text-weak);
  flex-shrink: 0; text-align: right; line-height: 1.4;
}
.group-divider {
  padding: 6px 16px 2px; margin: 2px 12px 0;
  font-size: 0.7rem; color: var(--text-muted);
  font-weight: 500; border-top: 1px solid var(--border);
  margin-top: 8px; padding-top: 8px;
}
.group-divider span { background: var(--bg); padding: 0 8px; }
.gcm-overlay {
  position: fixed; z-index: 100010;
  background: var(--bg-card); border-radius: 14px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
  padding: 6px; min-width: 170px;
}
.gcm-overlay button {
  display: flex; align-items: center; gap: 10px;
  width: 100%; padding: 11px 14px; border: none; background: none;
  font-size: 0.85rem; color: var(--text); cursor: pointer;
  border-radius: 10px; transition: background 0.12s;
  font-family: inherit; text-align: left;
}
.gcm-overlay button:active { background: var(--bg-light); }
.gcm-overlay button.danger { color: var(--danger); }

.gp-avatar-area {
  display: flex; justify-content: center; padding: 32px 0 0;
}
.gp-avatar {
  width: 88px; height: 88px; border-radius: var(--avatar-radius-xl);
  overflow: hidden; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-light);
}
.gp-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--avatar-radius-xl); }

.gp-name {
  text-align: center; font-size: 1.15rem; font-weight: 700; color: var(--text);
  padding: 16px 20px 6px;
}
.gp-meta-row {
  display: flex; justify-content: center; gap: 20px;
  padding: 4px 20px 16px;
  font-size: 0.8rem; color: var(--text-muted);
}
.gp-meta-row span { display: flex; align-items: center; gap: 4px; }
.gp-meta-row b { color: var(--brand); font-weight: 600; }
.gp-desc-card {
  margin: 0 12px 16px; padding: 14px 16px;
  background: var(--bg-light); border-radius: 12px;
}
.gp-desc-label { font-size: 0.72rem; color: var(--text-muted); margin-bottom: 6px; }
.gp-desc-text { font-size: 0.88rem; color: var(--text); line-height: 1.5; white-space: pre-wrap; word-break: break-word; }
.gp-owner-controls {
  margin: 0 12px 16px; padding: 0;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px;
}
.gp-toggle-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
}
.gp-toggle-info { flex: 1; min-width: 0; }
.gp-toggle-label { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.gp-toggle-hint { font-size: 0.7rem; color: var(--text-muted); margin-top: 2px; }
.gp-switch {
  position: relative; width: 48px; height: 28px; flex-shrink: 0; margin-left: 12px;
}
.gp-switch input { opacity: 0; width: 0; height: 0; }

/* ---------- 工具�?---------- */
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-center-col { display: flex; align-items: center; justify-content: center; flex-direction: column; }
.gp-switch-slider {
  position: absolute; inset: 0; background: #ccc; border-radius: 14px;
  cursor: pointer; transition: background 0.2s;
}
.gp-switch-slider::before {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--bg-card); transition: transform 0.2s;
}
.gp-switch input:checked + .gp-switch-slider { background: var(--brand); }
.gp-switch input:checked + .gp-switch-slider::before { transform: translateX(20px); }
.gp-section-title {
  padding: 0 16px 8px; font-size: 0.82rem; font-weight: 600;
  color: var(--text-muted);
}
.gp-section-title span { font-weight: 400; }
.gp-member-list {
  padding: 0 12px 40px;
  display: flex; flex-wrap: wrap; gap: 10px;
}
.gp-member-item {
  display: flex; flex-direction: column; align-items: center;
  width: 64px;
  padding: 10px 4px; border-radius: 10px;
  transition: background 0.12s;
  text-align: center;
}
.gp-member-clickable { cursor: pointer; }
.gp-member-clickable:active { background: var(--bg-light); }

.gp-member-info {
  display: flex; align-items: center; justify-content: center; gap: 4px;
  max-width: 100%;
}
.gp-member-name {
  font-size: 0.75rem; color: var(--text); font-weight: 500;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.gp-role-tag {
  font-size: 0.6rem; font-weight: 600; padding: 1px 5px;
  border-radius: 4px; background: var(--tint-blue); color: var(--info); flex-shrink: 0;
}
.gp-member-add { cursor: pointer; }
.gp-add-avatar {
  background: var(--brand) !important;
  color: #fff !important;
  font-size: 1.2rem;
}
.gp-member-kick { cursor: pointer; }
.gp-kick-avatar {
  background: var(--tint-red) !important;
  color: var(--danger) !important;
  font-size: 1.1rem;
}
.gp-kick-active .gp-kick-avatar {
  background: var(--danger) !important;
  color: #fff !important;
}
.gp-member-kick-target {
  cursor: pointer;
  position: relative;
}
.gp-member-kick-target::after {
  content: '×';
  position: absolute;
  top: -2px; right: -2px;
  width: 18px; height: 18px;
  background: var(--danger);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  line-height: 1;
}

/* ============================================================
   20. 动画 & 骨架�?   ============================================================ */
@keyframes bubbleIn {
  0% { opacity: 0; transform: scale(0.85) translateY(6px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes emptySpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeletonPulse 1.5s ease-in-out infinite;
  border-radius: 8px;
}
@keyframes skeletonPulse {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.skeleton-text { height: 14px; margin-bottom: 8px; width: 80%; }
.skeleton-text.short { width: 50%; }
.skeleton-avatar { width: 40px; height: 40px; border-radius: var(--avatar-radius); }
.skeleton-card-chat { height: 80px; border-radius: 12px; margin-bottom: 12px; }

/* ============================================================
   21. 协议弹窗
   ============================================================ */
.policy-overlay { display:none; position:fixed; top:0; left:0; width:100%; height:100%; background:rgba(0,0,0,0.5); z-index:var(--z-toast); flex-direction:column; justify-content:flex-end; }
.policy-overlay.show { display:flex; animation:policyFadeIn 0.25s ease; }
@keyframes policyFadeIn { from{opacity:0} to{opacity:1} }
.policy-panel { background: var(--bg-card); border-radius:20px 20px 0 0; max-height:85vh; display:flex; flex-direction:column; animation:policySlideUp 0.35s cubic-bezier(0.16,1,0.3,1); }
@keyframes policySlideUp { from{transform:translateY(100%)} to{transform:translateY(0)} }
.policy-header { display:flex; align-items:center; justify-content:center; padding:18px 20px; border-bottom:1px solid var(--border); position:relative; flex-shrink:0; }
.policy-header-title { font-size:1.05rem; font-weight:700; color:var(--policy-title); }
.policy-close-btn { position:absolute; right:16px; top:50%; transform:translateY(-50%); width:32px; height:32px; border:none; background:var(--policy-close-bg); border-radius:50%; font-size:18px; color:var(--policy-close-color); cursor:pointer; display:flex; align-items:center; justify-content:center; transition:all 0.2s; }
.policy-close-btn:active { background:var(--policy-close-active); }
.policy-body { overflow-y:auto; -webkit-overflow-scrolling:touch; padding:20px 24px 40px; }
.policy-body h1 { font-size:1.2rem; color:var(--policy-title); margin-bottom:16px; line-height:1.5; }
.policy-body h2 { font-size:1rem; color:var(--policy-title); margin:20px 0 10px; line-height:1.5; }
.policy-body p { font-size:0.88rem; color:var(--policy-text); line-height:1.8; margin-bottom:12px; }
.policy-body ul, .policy-body ol { padding-left:20px; margin-bottom:12px; }
.policy-body li { font-size:0.88rem; color:var(--policy-text); line-height:1.8; margin-bottom:6px; }
.policy-body strong { color:var(--policy-title); }

/* Plaza context menu */
.plaza-ctx-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  z-index: var(--z-dropdown); display: none;
}
.plaza-ctx-overlay.show { display: block; }
.plaza-ctx-menu {
  position: fixed; z-index: var(--z-dropdown);
  background: var(--bg-card); border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  padding: 6px; min-width: 150px;
  animation: ctxFadeIn 0.15s ease;
}
@keyframes ctxFadeIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}
.plaza-ctx-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 8px;
  font-size: 0.9rem; color: var(--text); cursor: pointer;
  transition: background 0.15s; white-space: nowrap;
}
.plaza-ctx-item:hover { background: var(--list-muted); }
.plaza-ctx-item svg { flex-shrink: 0; opacity: 0.6; }
.plaza-ctx-item.danger { color: var(--danger); }
.plaza-ctx-item.danger svg { opacity: 1; }

/* ---- 下拉刷新 ---- */
/* 下拉刷新 - 已移�?*/

/* ---- 排序�?---- */
.sticky-sort-bar { display:flex; gap:8px; padding:6px 12px; }
/* ---- 空白引导 ---- */
.sticky-empty { text-align:center; padding:60px 20px; }
.sticky-empty .empty-icon { margin-bottom:12px; opacity:0.45; }
.sticky-empty .empty-text { font-size:0.95rem; color:var(--text-secondary); margin-bottom:8px; }
.sticky-empty .empty-sub { font-size:0.8rem; color:var(--text-weak); margin-bottom:20px; }
.sticky-empty .empty-action { display:inline-block; padding:8px 24px; background:var(--brand-gradient); color:#fff; border-radius:20px; font-weight:700; cursor:pointer; font-size:0.9rem; }

/* ---- 反馈弹窗 ---- */
.feedback-overlay { position:fixed; inset:0; background:rgba(0,0,0,0.45); display:flex; justify-content:center; align-items:center; z-index:var(--z-panel); }
.feedback-box { background: var(--bg-card); border-radius:12px; width:90vw; max-width:380px; padding:20px; box-shadow:0 8px 30px rgba(0,0,0,0.18); }
.feedback-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:12px; }
.feedback-textarea { width:100%; border:1.5px solid var(--card-nested-border); border-radius:8px; padding:12px; font-size:0.9rem; font-family:inherit; resize:vertical; outline:none; box-sizing:border-box; }
.feedback-textarea:focus { border-color:var(--brand); box-shadow: 0 0 0 3px rgba(224,90,58,0.08); outline: none; }
.feedback-actions { display:flex; justify-content:flex-end; gap:10px; margin-top:12px; }
.feedback-actions .btn-cancel { padding:8px 20px; background:var(--list-muted); border:none; border-radius:8px; color:var(--text-secondary); cursor:pointer; font-size:0.85rem; }
.feedback-actions .btn-submit { padding:8px 20px; background:var(--brand-gradient); color:#fff; border:none; border-radius:8px; cursor:pointer; font-size:0.85rem; font-weight:600; }
/* ---- 娲昏穬鐢ㄦ埛杞挱 ---- */
/* ---- 活跃用户轮播 ---- */
.aus-slide-bg {
  background-size: cover; background-position: center;
  position: relative;
}
.aus-slide-bg::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.1) 50%, transparent 100%);
}
.aus-slide-overlay {
  position: absolute; bottom: 0; left: 0; right: 0;
  display: flex; align-items: center; gap: 10px;
  padding: 16px 14px; z-index: 1; color: #fff;
}
.aus-slide-overlay .aus-slide-avatar {
  width: 36px; height: 36px; border-radius: var(--avatar-radius); overflow: hidden;
  border: 2px solid rgba(255,255,255,0.5); flex-shrink: 0;
  background: rgba(255,255,255,0.2); display: flex; align-items: center; justify-content: center;
  position: relative;
}
.aus-slide-overlay .aus-slide-avatar img { width: 100%; height: 100%; object-fit: cover; position: relative; z-index: 1; }
.aus-slide-overlay .aus-slide-avatar .aus-avatar-fallback { position: absolute; inset: 0; z-index: 0; color: rgba(255,255,255,0.7); display: flex; align-items: center; justify-content: center; }
.aus-slide-info { min-width: 0; }
.aus-slide-info .aus-slide-name { font-size: 0.95rem; font-weight: 700; text-shadow: 0 1px 3px rgba(0,0,0,0.3); }
.aus-slide-info .aus-slide-bio { font-size: 0.72rem; opacity: 0.8; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.aus-slide-noimg {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #a855f7 100%);
  cursor: pointer; gap: 6px;
}
.aus-slide-noimg:nth-child(2) { background: linear-gradient(135deg, #ec4899 0%, #f43f5e 50%, #f97316 100%); }
.aus-slide-noimg:nth-child(3) { background: linear-gradient(135deg, #06b6d4 0%, #3b82f6 50%, #6366f1 100%); }
.aus-slide-noimg:nth-child(4) { background: linear-gradient(135deg, #10b981 0%, #14b8a6 50%, #06b6d4 100%); }
.aus-slide-noimg:nth-child(5) { background: linear-gradient(135deg, #f59e0b 0%, #ef4444 50%, #ec4899 100%); }
.aus-slide-noimg .aus-slide-avatar { width: 48px; height: 48px; border-radius: var(--avatar-radius); overflow: hidden; border: 2px solid rgba(255,255,255,0.4); background: rgba(255,255,255,0.2); display: flex; align-items: center; justify-content: center; }
.aus-slide-noimg .aus-slide-avatar img { width: 100%; height: 100%; object-fit: cover; }
.aus-slide-noimg .aus-slide-avatar .aus-avatar-fallback { color: rgba(255,255,255,0.6); display: flex; align-items: center; justify-content: center; }
.aus-slide-noimg .aus-slide-name { font-size: 0.9rem; font-weight: 700; color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,0.2); }
.aus-slide-noimg .aus-slide-bio { font-size: 0.72rem; color: rgba(255,255,255,0.7); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 榜单分隔线 */
.aul-divider { height: 1px; background: var(--border); margin: 8px 18px; }

/* ---- 娲昏穬鐢ㄦ埛姒滃崟寮圭獥 ---- */
.active-users-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.45); display: none; flex-direction: column; align-items: center; justify-content: center; z-index: var(--z-modal); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.active-users-overlay.show { display: flex; }
.au-panel { background: var(--bg-card); border-radius: 16px; width: 92%; max-width: 420px; max-height: 80vh; display: flex; flex-direction: column; box-shadow: 0 12px 40px rgba(0,0,0,0.18); animation: upFadeIn 0.25s ease; }
.au-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 12px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.au-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.au-title span { color: var(--brand); margin-right: 4px; cursor: pointer; border-bottom: 1px dashed var(--brand); }
.au-close { width: 32px; height: 32px; border: none; background: var(--bg-light); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text-muted); transition: background 0.15s; }
.au-close:hover { background: var(--card-nested); }
.au-list { flex: 1; overflow-y: auto; padding: 8px 0; }
.au-list::-webkit-scrollbar { width: 4px; }
.au-list::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.au-loading { text-align: center; padding: 40px 20px; font-size: 0.9rem; color: var(--text-muted); }

/* 姒滃崟鐢ㄦ埛鍗＄墖 */
.aul-card { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); transition: background 0.12s; cursor: default; }
.aul-card:last-child { border-bottom: none; }
.aul-card:active { background: var(--bg-light); }
.aul-card-rank { width: 28px; flex-shrink: 0; text-align: center; }
.aul-rank { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; font-size: 0.7rem; font-weight: 700; color: var(--text-muted); background: var(--bg-light); }
.aul-rank-gold { background: #fbbf24; color: #92400e; }
.aul-rank-silver { background: #cbd5e1; color: #475569; }
.aul-rank-bronze { background: #fed7aa; color: #9a3412; }
.aul-card-avatar { width: 40px; height: 40px; border-radius: var(--avatar-radius); overflow: hidden; flex-shrink: 0; background: var(--bg-light); display: flex; align-items: center; justify-content: center; }
.aul-card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.aul-card-avatar .aul-avatar-fallback { color: var(--text-muted); display: flex; align-items: center; justify-content: center; }
.aul-card-info { flex: 1; min-width: 0; }
.aul-card-name { font-size: 0.9rem; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aul-card-bio { font-size: 0.75rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.aul-card-btn { flex-shrink: 0; padding: 6px 16px; border: none; background: var(--brand); color: #fff; border-radius: 16px; font-size: 0.8rem; font-weight: 600; cursor: pointer; transition: transform 0.12s, opacity 0.12s; }
.aul-card-btn:active { transform: scale(0.95); opacity: 0.85; }
/* ---- 活跃用户轮播 ---- */
/* ---- 活跃用户轮播 ---- */
.aus-slide-bg {
  background-size: cover; background-position: center;
  position: relative;
}

/* ---- 活跃用户榜单弹窗 ---- */
.active-users-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.45); display: none; flex-direction: column; align-items: center; justify-content: center; z-index: var(--z-modal); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.active-users-overlay.show { display: flex; }
.au-panel { background: var(--bg-card); border-radius: 16px; width: 92%; max-width: 420px; max-height: 80vh; display: flex; flex-direction: column; box-shadow: 0 12px 40px rgba(0,0,0,0.18); animation: upFadeIn 0.25s ease; }
.au-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 12px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.au-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.au-title span { color: var(--brand); margin-right: 4px; cursor: pointer; border-bottom: 1px dashed var(--brand); }
.au-close { width: 32px; height: 32px; border: none; background: var(--bg-light); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text-muted); transition: background 0.15s; }
.au-close:hover { background: var(--card-nested); }
.au-list { flex: 1; overflow-y: auto; padding: 8px 0; }
.au-list::-webkit-scrollbar { width: 4px; }
.au-list::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.au-loading { text-align: center; padding: 40px 20px; font-size: 0.9rem; color: var(--text-muted); }

/* 榜单用户卡片 */
.aul-card { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); transition: background 0.12s; cursor: default; }
.aul-card:last-child { border-bottom: none; }
.aul-card:active { background: var(--bg-light); }
.aul-card-rank { width: 28px; flex-shrink: 0; text-align: center; }
.aul-rank { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; font-size: 0.7rem; font-weight: 700; color: var(--text-muted); background: var(--bg-light); }
.aul-rank-gold { background: #fbbf24; color: #92400e; }
.aul-rank-silver { background: #cbd5e1; color: #475569; }
.aul-rank-bronze { background: #fed7aa; color: #9a3412; }
.aul-card-avatar { width: 40px; height: 40px; border-radius: var(--avatar-radius); overflow: hidden; flex-shrink: 0; background: var(--bg-light); display: flex; align-items: center; justify-content: center; }
.aul-card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.aul-card-avatar .aul-avatar-fallback { color: var(--text-muted); display: flex; align-items: center; justify-content: center; }
.aul-card-info { flex: 1; min-width: 0; }
.aul-card-name { font-size: 0.9rem; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aul-card-bio { font-size: 0.75rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.aul-card-btn { flex-shrink: 0; padding: 6px 16px; border: none; background: var(--brand); color: #fff; border-radius: 16px; font-size: 0.8rem; font-weight: 600; cursor: pointer; transition: transform 0.12s, opacity 0.12s; }
.aul-card-btn:active { transform: scale(0.95); opacity: 0.85; }

/* ---- 活跃用户轮播 ---- */
.aus-slide-bg {
  background-size: cover; background-position: center;
  position: relative;
}

/* ---- 娲昏穬鐢ㄦ埛姒滃崟寮圭獥 ---- */
.active-users-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.45); display: none; flex-direction: column; align-items: center; justify-content: center; z-index: var(--z-modal); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.active-users-overlay.show { display: flex; }
.au-panel { background: var(--bg-card); border-radius: 16px; width: 92%; max-width: 420px; max-height: 80vh; display: flex; flex-direction: column; box-shadow: 0 12px 40px rgba(0,0,0,0.18); animation: upFadeIn 0.25s ease; }
.au-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px 12px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.au-title { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.au-title span { color: var(--brand); margin-right: 4px; cursor: pointer; border-bottom: 1px dashed var(--brand); }
.au-close { width: 32px; height: 32px; border: none; background: var(--bg-light); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text-muted); transition: background 0.15s; }
.au-close:hover { background: var(--card-nested); }
.au-list { flex: 1; overflow-y: auto; padding: 8px 0; }
.au-list::-webkit-scrollbar { width: 4px; }
.au-list::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.au-loading { text-align: center; padding: 40px 20px; font-size: 0.9rem; color: var(--text-muted); }

/* 姒滃崟鐢ㄦ埛鍗＄墖 */
.aul-card { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); transition: background 0.12s; cursor: default; }
.aul-card:last-child { border-bottom: none; }
.aul-card:active { background: var(--bg-light); }
.aul-card-rank { width: 28px; flex-shrink: 0; text-align: center; }
.aul-rank { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; font-size: 0.7rem; font-weight: 700; color: var(--text-muted); background: var(--bg-light); }
.aul-rank-gold { background: #fbbf24; color: #92400e; }
.aul-rank-silver { background: #cbd5e1; color: #475569; }
.aul-rank-bronze { background: #fed7aa; color: #9a3412; }
.aul-card-avatar { width: 40px; height: 40px; border-radius: var(--avatar-radius); overflow: hidden; flex-shrink: 0; background: var(--bg-light); display: flex; align-items: center; justify-content: center; }
.aul-card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.aul-card-avatar .aul-avatar-fallback { color: var(--text-muted); display: flex; align-items: center; justify-content: center; }
.aul-card-info { flex: 1; min-width: 0; }
.aul-card-name { font-size: 0.9rem; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aul-card-bio { font-size: 0.75rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.aul-card-btn { flex-shrink: 0; padding: 6px 16px; border: none; background: var(--brand); color: #fff; border-radius: 16px; font-size: 0.8rem; font-weight: 600; cursor: pointer; transition: transform 0.12s, opacity 0.12s; }
.aul-card-btn:active { transform: scale(0.95); opacity: 0.85; }

.aul-card-score {
  flex-shrink: 0; text-align: center; min-width: 36px;
  font-size: 0.85rem; font-weight: 700; color: var(--brand);
  line-height: 1.1;
}
.aul-card-score span {
  display: block; font-size: 0.62rem; font-weight: 400;
  color: var(--text-muted);
}

/* 活跃度规则按钮 */
.au-rules-btn {
  margin-left: auto; margin-right: 8px;
  padding: 4px 10px; border: 1px solid var(--brand);
  background: transparent; color: var(--brand);
  font-size: 0.75rem; font-weight: 600;
  border-radius: 20px; cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.au-rules-btn:hover { background: var(--brand); color: #fff; }

/* 自己的卡片 */
.aul-card-self { background: rgba(59,130,246,0.05); }
.aul-self-tag {
  display: inline-block; font-size: 0.65rem; font-weight: 600;
  color: #fff; background: var(--brand); padding: 1px 6px;
  border-radius: 8px; margin-left: 6px; vertical-align: middle;
}

/* 活跃度规则内联 */
.au-rules {
  padding: 10px 18px; border-bottom: 1px solid var(--border);
  background: var(--bg-light);
}
.ar-text {
  font-size: 0.8rem; color: var(--text-muted); line-height: 1.6;
}



/* 底部固定：我的排名（不参与滚动） */
.au-self-footer {
  flex-shrink: 0;
  border-top: 2px solid var(--brand);
  background: rgba(59,130,246,0.04);
  padding: 6px 0 4px;
}
.au-self-footer-label {
  font-size: 0.7rem; font-weight: 600; color: var(--brand);
  padding: 0 16px 4px;
  letter-spacing: 0.05em;
}
.au-self-footer .aul-card {
  border-bottom: none;
  background: transparent;
}

