/* ============================================================
   宠物交流圈 - 全局样式 v2.1
   温暖 · 自然 · 去AI感
   ============================================================ */

* { margin:0; padding:0; box-sizing:border-box; -webkit-tap-highlight-color:transparent; }

:root {
    --primary: #f06292;
    --primary-hover: #ec407a;
    --primary-light: #fde7ef;
    --primary-dark: #d81b60;
    --accent: #64b5f6;
    --accent-light: #e3f2fd;
    --success: #81c784;
    --warning: #ffb74d;
    --danger: #e57373;

    --bg: #f5f5f5;
    --bg-warm: #faf5f0;
    --card: #ffffff;
    --card-soft: #f9f9f9;
    --text: #333333;
    --text-secondary: #666666;
    --text-muted: #999999;
    --text-faint: #cccccc;

    --border: #eeeeee;
    --border-light: #f2f2f2;

    --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
    --shadow: 0 2px 8px rgba(0,0,0,0.05);
    --shadow-lg: 0 6px 20px rgba(0,0,0,0.08);
    --shadow-xl: 0 10px 30px rgba(0,0,0,0.1);

    --radius-xs: 4px;
    --radius-sm: 10px;
    --radius: 14px;
    --radius-lg: 18px;
    --radius-xl: 24px;

    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --safe-top: env(safe-area-inset-top, 0px);

    --content-max: 720px;
    --nav-height: 60px;
}

html, body { height:100%; }

body {
    background: var(--bg);
    color: var(--text);
    font-size: 15px;
    line-height: 1.6;
    padding-bottom: calc(var(--nav-height) + var(--safe-bottom));
    max-width: var(--content-max);
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC",
                 "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, textarea, select { font-family: inherit; font-size: 15px; }

/* ============ 通用组件 ============ */
.card {
    background: var(--card);
    margin: 10px 12px;
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: var(--shadow-sm);
}

.btn {
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--primary); color: #fff;
    padding: 10px 20px; border-radius: var(--radius-sm);
    font-size: 14px; font-weight: 500;
    transition: all 0.15s;
}
.btn:active { transform: scale(0.97); }
.btn:hover { background: var(--primary-hover); }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-lg { padding: 14px 28px; font-size: 16px; }
.btn-out { background: #fff; color: var(--primary); border: 1px solid var(--primary); }
.btn-out:hover { background: var(--primary-light); }
.btn-ghost { background: transparent; color: var(--text-secondary); }

.empty {
    padding: 60px 20px; text-align: center; color: var(--text-muted);
}
.empty .icon { font-size: 48px; margin-bottom: 12px; opacity: 0.4; }
.empty .txt { font-size: 14px; line-height: 1.6; }

/* ============ 顶部滚动公告 ============ */
.scroll-notice {
    background: #fff8e1;
    padding: 8px 16px;
    font-size: 13px;
    color: #8a6300;
    overflow: hidden;
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid #ffe8b8;
}
.scroll-notice .text {
    display: inline-block;
    animation: scrollNotice 30s linear infinite;
}
@keyframes scrollNotice {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* ============ 轮播图 ============ */
.banner {
    position: relative;
    width: calc(100% - 24px);
    margin: 10px 12px;
    height: 200px;
    overflow: hidden;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.banner-track { display: flex; height: 100%; }
.banner-item {
    min-width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
}
.banner-dots {
    position: absolute; bottom: 8px; left: 0; right: 0;
    display: flex; justify-content: center; gap: 5px;
}
.banner-dots .dot {
    width: 5px; height: 5px; border-radius: 50%;
    background: rgba(255,255,255,0.5);
    transition: all 0.3s;
    cursor: pointer;
}
.banner-dots .dot.active {
    background: #fff; width: 14px; border-radius: 3px;
}

/* ============ 合并胶囊栏（板块+地区） ============ */
.merge-bar {
    display:flex;
    align-items:center;
    gap:6px;
    padding:10px 12px;
    background:#fff;
    border-bottom:1px solid #f3f4f6;
    flex-wrap:wrap;
}
.merge-bar .group {
    display:flex;
    gap:6px;
    flex-wrap:wrap;
    align-items:center;
}
.merge-bar .pill {
    padding:6px 14px;
    border-radius:16px;
    font-size:13px;
    color:#666;
    cursor:pointer;
    background:#f5f5f5;
    border:1px solid transparent;
    transition:all 0.15s;
    font-weight:500;
    white-space:nowrap;
}
.merge-bar .pill:hover { border-color:var(--primary); color:var(--primary); }
.merge-bar .pill.active {
    background:var(--primary);
    color:#fff;
    box-shadow:0 2px 6px rgba(240,98,146,0.3);
}
.merge-bar .divider {
    width:1px; height:18px; background:#e5e5e5; margin:0 4px; flex-shrink:0;
}

/* ============ 板块标签（独立页面用） ============ */
.board-tabs {
    display: flex;
    padding: 10px 12px;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    background: #fff;
    border-bottom: 1px solid var(--border-light);
}
.board-tabs::-webkit-scrollbar { display: none; }
.board-tab {
    flex-shrink: 0;
    padding: 7px 16px;
    background: #f5f5f5;
    border-radius: 18px;
    font-size: 13px;
    color: var(--text-secondary);
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.15s;
    font-weight: 500;
}
.board-tab:hover { border-color: var(--primary); color: var(--primary); }
.board-tab.active {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 2px 6px rgba(240,98,146,0.3);
}

/* ============ 动态卡片（朋友圈风格） ============ */
.moment-card {
    background:#fff;
    border-radius:var(--radius);
    margin:10px 12px;
    padding:14px;
    box-shadow:var(--shadow-sm);
}
.moment-head {
    display:flex; gap:10px; align-items:center; margin-bottom:8px;
}
.moment-head .ava {
    width:44px; height:44px; border-radius:50%; object-fit:cover;
    background:#eee; flex-shrink:0; cursor:pointer;
    border:2px solid #fff; box-shadow:0 2px 6px rgba(0,0,0,0.06);
}
.moment-head .ava-def {
    width:44px; height:44px; border-radius:50%;
    background:linear-gradient(135deg,#ffb7c5,#f06292);
    color:#fff; display:flex; align-items:center; justify-content:center;
    font-size:18px; flex-shrink:0; cursor:pointer;
    border:2px solid #fff; box-shadow:0 2px 6px rgba(0,0,0,0.06);
}
.moment-head .m-info { flex:1; min-width:0; }
.moment-head .nick {
    font-weight:600; font-size:14px; color:#333; cursor:pointer;
}
.moment-head .nick .t {
    color:#999; font-weight:400; font-size:12px; margin-left:4px;
}
.moment-head .nick .t .tag {
    background:#f3f4f6; color:#666; padding:0 6px;
    border-radius:8px; font-size:10px; font-weight:500; margin-right:3px;
}
.moment-head .time { font-size:12px; color:#999; margin-top:2px; }
.moment-head .more-dot {
    color:#bbb; font-size:20px; cursor:pointer;
    padding:4px 8px; border-radius:50%; transition:all 0.15s; line-height:1;
}
.moment-head .more-dot:hover { background:#f5f5f5; color:#666; }

.moment-body {
    font-size:14px; color:#333; line-height:1.5;
    margin-bottom:8px; word-break:break-word; white-space:pre-wrap;
}
.moment-loc {
    font-size:12px; color:#888; margin-bottom:6px;
    display:flex; align-items:center; gap:4px;
}
.moment-foot {
    display:flex; gap:16px; padding-top:8px;
    border-top:1px solid #f5f5f5; font-size:13px; color:#888;
}
.moment-foot .action {
    cursor:pointer; display:flex; align-items:center; gap:4px;
    padding:4px 8px; border-radius:12px; transition:all 0.15s; user-select:none;
}
.moment-foot .action:hover { background:#fde7ef; color:var(--primary); }
.moment-foot .action.liked { color:#ff4757; }
.moment-foot .action.liked svg { animation:popHeart 0.4s; }
@keyframes popHeart { 0%{transform:scale(1)} 50%{transform:scale(1.3)} 100%{transform:scale(1)} }

.moment .imgs {
    display:grid; grid-template-columns:repeat(3,1fr);
    gap:3px; margin:8px 0; border-radius:8px; overflow:hidden;
}
.moment .imgs img {
    width:100%; aspect-ratio:1; object-fit:cover;
    cursor:pointer; transition:transform 0.15s; border-radius:4px;
}
.moment .imgs img:hover { transform:scale(1.02); }
.moment .imgs.single { grid-template-columns:1fr; max-width:280px; }
.moment .imgs.single img { aspect-ratio:auto; max-height:280px; }
.moment .imgs.grid-2 { grid-template-columns:repeat(2,1fr); max-width:380px; }
.moment .imgs.grid-4 { grid-template-columns:repeat(2,1fr); }

.moment .video-box {
    margin:8px 0; background:#000; border-radius:8px;
    overflow:hidden; position:relative;
}
.moment .video-box video { width:100%; max-height:320px; display:block; }
.moment .video-box .play-icon {
    position:absolute; inset:0; display:flex;
    align-items:center; justify-content:center;
    color:#fff; font-size:36px; opacity:0.8; pointer-events:none;
}

/* ============ 旧版 .moment 样式兼容 ============ */
.moment {
    background: var(--card);
    margin: 10px 12px;
    border-radius: var(--radius);
    padding: 14px 16px;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.15s;
}
.moment:active { box-shadow: var(--shadow); }
.moment .head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.moment .avatar {
    width: 42px; height: 42px; border-radius: 50%;
    object-fit: cover; background: #eee; flex-shrink: 0; cursor: pointer;
    border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}
.moment .avatar-default {
    width: 42px; height: 42px; border-radius: 50%;
    background: linear-gradient(135deg, #ffe0e8, #ffc5d3);
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; flex-shrink: 0; cursor: pointer;
    border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}
.moment .name-box { flex: 1; min-width: 0; }
.moment .name { font-size: 15px; font-weight: 600; color: var(--text); cursor: pointer; }
.moment .meta {
    font-size: 12px; color: var(--text-muted); margin-top: 2px;
    display: flex; gap: 8px; align-items: center; flex-wrap: wrap;
}
.moment .tag {
    background: var(--primary-light);
    color: var(--primary);
    padding: 1px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
}
.moment .more {
    color: var(--text-muted); font-size: 20px; cursor: pointer;
    padding: 4px 8px; border-radius: 50%;
    transition: all 0.15s;
}
.moment .more:hover { background: var(--border-light); color: var(--text); }

.moment .actions {
    display: flex; gap: 8px; margin-top: 10px;
    padding-top: 10px; border-top: 1px solid var(--border-light);
}
.moment .act-btn {
    display: flex; align-items: center; gap: 5px;
    font-size: 13px; color: var(--text-secondary);
    cursor: pointer; transition: all 0.15s;
    padding: 5px 10px; border-radius: 16px;
    user-select: none;
}
.moment .act-btn:hover { background: var(--border-light); }
.moment .act-btn:active { color: var(--primary); }
.moment .act-btn.liked { color: #ff4757; }

/* ============ 标签 ============ */
.tag-help { background:#fff1f0; color:#ff4757; padding:1px 6px; border-radius:8px; font-size:10px; font-weight:500; }
.tag-share { background:#e8f0ff; color:#5b8def; padding:1px 6px; border-radius:8px; font-size:10px; font-weight:500; }
.tag-plate { background:#fef3c7; color:#b45309; padding:1px 6px; border-radius:8px; font-size:10px; font-weight:500; }

/* ============ 悬浮按钮 ============ */
.fab {
    position: fixed;
    right: 18px;
    bottom: calc(75px + var(--safe-bottom));
    width: 54px; height: 54px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; font-weight: 300;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(240,98,146,0.35);
    z-index: 100;
    transition: all 0.15s;
}
.fab:hover { transform: scale(1.06); box-shadow: 0 6px 18px rgba(240,98,146,0.45); }
.fab:active { transform: scale(0.94); }

/* ============ 发布弹窗 ============ */
.publish-modal {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: flex-end;
    z-index: 9999;
    animation: fadeIn 0.2s;
}
.publish-modal.show { display: flex; }
@keyframes fadeIn { from{opacity:0} to{opacity:1} }

.publish-sheet {
    width: 100%; max-width: var(--content-max);
    margin: 0 auto;
    background: #fff;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 20px;
    padding-bottom: calc(24px + var(--safe-bottom));
    max-height: 88vh;
    overflow-y: auto;
}
.publish-tabs { display: flex; gap: 10px; margin-bottom: 18px; }
.publish-tab {
    flex: 1; padding: 12px;
    text-align: center;
    background: var(--card-soft);
    border-radius: var(--radius-sm);
    font-size: 14px; color: var(--text-secondary);
    cursor: pointer; transition: all 0.15s;
    font-weight: 500;
}
.publish-tab.active {
    background: var(--primary-light); color: var(--primary);
}
.publish-form label {
    display: block; font-size: 13px; color: var(--text-secondary);
    margin: 12px 0 6px; font-weight: 500;
}
.publish-form input, .publish-form textarea, .publish-form select {
    width: 100%; padding: 11px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px; outline: none;
    transition: border-color 0.15s;
    background: var(--card-soft);
}
.publish-form input:focus, .publish-form textarea:focus, .publish-form select:focus {
    border-color: var(--primary); background: #fff;
}
.publish-form textarea { min-height: 110px; resize: vertical; line-height: 1.6; }

.publish-form .media-row { display: flex; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.publish-form .media-btn {
    padding: 10px 18px;
    background: var(--card-soft);
    border-radius: 20px;
    font-size: 13px; cursor: pointer; color: var(--text-secondary);
    transition: all 0.15s;
    display: flex; align-items: center; gap: 6px;
}
.publish-form .media-btn:hover { background: var(--primary-light); color: var(--primary); }

.publish-form .submit-btn {
    width: 100%; padding: 14px;
    background: var(--primary);
    color: #fff; border: none;
    border-radius: var(--radius-sm);
    font-size: 15px; font-weight: 500;
    cursor: pointer; margin-top: 18px;
    box-shadow: 0 4px 14px rgba(240,98,146,0.3);
    transition: all 0.15s;
}
.publish-form .submit-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(240,98,146,0.4); }
.publish-form .close-btn {
    text-align: center; color: var(--text-muted);
    margin-top: 12px; padding: 12px;
    cursor: pointer; font-size: 14px;
    transition: color 0.15s;
}
.publish-form .close-btn:hover { color: var(--text); }

/* ============ 弹出层 ============ */
.popup-mask {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center; justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.2s;
    padding: 16px;
}
.popup-mask.show { display: flex; }
.popup {
    width: 100%; max-width: 420px;
    max-height: 85vh; overflow-y: auto;
    background: #fff;
    border-radius: 18px;
    padding: 20px;
}
.popup .label {
    display: block; font-size: 13px; color: var(--text-secondary);
    margin: 14px 0 6px; font-weight: 500;
}
.popup .input {
    width: 100%; padding: 11px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px; outline: none;
    transition: border-color 0.15s;
    background: var(--card-soft);
    box-sizing: border-box;
}
.popup .input:focus {
    border-color: var(--primary); background: #fff;
}
.popup textarea.input { min-height: 100px; resize: vertical; line-height: 1.6; }
.popup .btn {
    width: 100%; padding: 12px;
    background: var(--primary);
    color: #fff; border: none; border-radius: 14px;
    font-size: 15px; cursor: pointer; font-weight: 500;
    transition: transform 0.1s;
}
.popup .btn:hover { transform: scale(1.01); }
.popup .btn:active { transform: scale(0.98); }
.popup .close {
    text-align: center; margin-top: 12px;
    padding: 10px; color: var(--text-muted);
    cursor: pointer; font-size: 14px;
}
.popup .close:hover { color: var(--text); }

/* ============ top-bar ============ */
.top-bar {
    display: flex; align-items: center;
    padding: 12px 16px;
    background: #fff;
    border-bottom: 1px solid var(--border-light);
    position: sticky; top: 0; z-index: 10;
    max-width: var(--content-max);
    margin: 0 auto;
}
.top-bar .back {
    font-size: 15px; cursor: pointer; color: var(--text-secondary);
    padding: 6px 10px; border-radius: 10px;
    transition: background 0.15s;
}
.top-bar .back:hover { background: var(--card-soft); }
.top-bar .title {
    flex: 1; text-align: center;
    font-weight: 600; font-size: 16px;
}

/* ============ 底部导航 ============ */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; right: 0;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-light);
    display: flex; z-index: 99;
    max-width: var(--content-max);
    margin: 0 auto;
    padding-bottom: var(--safe-bottom);
    padding-top: 4px;
}
.bottom-nav .nav-item {
    flex: 1; text-align: center;
    padding: 6px 0 8px;
    color: var(--text-muted);
    font-size: 11px; cursor: pointer;
    transition: color 0.15s;
    text-decoration: none;
}
.bottom-nav .nav-item.active { color: var(--primary); }
.bottom-nav .nav-icon {
    font-size: 22px; line-height: 1;
    margin-bottom: 3px;
    transition: transform 0.15s;
}
.bottom-nav .nav-item:active .nav-icon { transform: scale(0.85); }

/* ============ 图片全屏预览 ============ */
.img-viewer {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.96);
    z-index: 99999;
    display: none;
    align-items: center; justify-content: center;
}
.img-viewer.show { display: flex; }
.img-viewer img { max-width: 100%; max-height: 100%; object-fit: contain; }
.img-viewer .close-btn {
    position: absolute; top: 18px; right: 18px;
    color: #fff; font-size: 36px; cursor: pointer; z-index: 100000;
    width: 44px; height: 44px;
    background: rgba(0,0,0,0.4);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
}

/* ============ 下拉刷新 ============ */
.pull-tip {
    text-align: center; padding: 10px;
    color: var(--text-muted); font-size: 13px; display: none;
}
.pull-tip.show { display: block; }

/* ============ 用户卡片 ============ */
.user-row { display: flex; align-items: center; gap: 12px; }
.user-row .avatar {
    width: 52px; height: 52px; border-radius: 50%;
    object-fit: cover; background: #eee;
    border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}
.user-row .nickname { font-weight: 600; font-size: 15px; }
.user-row .meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.user-row .badge {
    background: var(--primary-light); color: var(--primary);
    font-size: 11px; padding: 2px 8px;
    border-radius: 10px; margin-left: 6px; font-weight: 500;
}

/* ============ 我的页面 ============ */
.profile-card {
    background: linear-gradient(135deg, #fff5f8, #fff);
    padding: 24px 16px 20px;
    display: flex; gap: 16px; align-items: center;
}
.profile-card .avatar-box { position: relative; }
.profile-card .avatar {
    width: 80px; height: 80px; border-radius: 50%;
    object-fit: cover; background: #eee;
    cursor: pointer;
    border: 3px solid #fff; box-shadow: 0 4px 14px rgba(0,0,0,0.1);
}
.profile-card .edit-avatar {
    position: absolute; bottom: 0; right: 0;
    width: 24px; height: 24px;
    background: var(--primary); color: #fff;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 12px; cursor: pointer;
    box-shadow: 0 2px 6px rgba(240,98,146,0.35);
}
.profile-card .nickname { font-size: 19px; font-weight: 700; color: var(--text); }
.profile-card .signature { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }
.profile-card .meta-line { font-size: 12px; color: var(--text-muted); margin-top: 8px; display: flex; gap: 8px; flex-wrap: wrap; }
.profile-card .meta-line .tag {
    background: var(--primary-light); color: var(--primary);
    padding: 2px 8px; border-radius: 10px; font-size: 11px; font-weight: 500;
}

/* 统计卡片 */
.stat-card {
    background: var(--card);
    margin: 10px 12px;
    border-radius: var(--radius);
    padding: 18px 16px;
    display: flex; justify-content: space-around; text-align: center;
    box-shadow: var(--shadow-sm);
}
.stat-card .stat-num { font-size: 22px; font-weight: 700; color: var(--primary); }
.stat-card .stat-label { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

/* 设置列表 */
.setting-list {
    background: var(--card);
    margin: 10px 12px; border-radius: var(--radius);
    overflow: hidden; box-shadow: var(--shadow-sm);
}
.setting-row {
    display: flex; align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-light);
    cursor: pointer; transition: background 0.1s;
}
.setting-row:last-child { border: none; }
.setting-row:hover { background: var(--card-soft); }
.setting-row .lbl { font-size: 14px; flex: 1; font-weight: 500; }
.setting-row .desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; font-weight: 400; }
.setting-row .arrow { color: var(--text-muted); font-size: 18px; }

/* 开关 */
.toggle {
    width: 46px; height: 26px;
    background: #d1d5db;
    border-radius: 13px;
    position: relative; cursor: pointer;
    transition: background 0.2s;
    flex-shrink: 0;
}
.toggle.on { background: var(--primary); }
.toggle::after {
    content: ''; position: absolute;
    top: 3px; left: 3px;
    width: 20px; height: 20px;
    background: #fff; border-radius: 50%;
    transition: transform 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.toggle.on::after { transform: translateX(20px); }

/* ============ Tab 切换 ============ */
.tabs {
    display: flex;
    background: var(--card);
    margin: 10px 12px 0;
    border-radius: var(--radius);
    padding: 4px;
    box-shadow: var(--shadow-sm);
    gap: 4px;
}
.tabs .tab {
    flex: 1; text-align: center;
    padding: 10px; border-radius: var(--radius-sm);
    font-size: 14px; color: var(--text-secondary);
    cursor: pointer; transition: all 0.15s;
    font-weight: 500;
}
.tabs .tab.active {
    background: var(--primary); color: #fff;
    box-shadow: 0 2px 6px rgba(240,98,146,0.3);
}

/* ============ SOS 横幅 ============ */
.sos-banner {
    position: fixed; top: 0; left: 0; right: 0;
    background: linear-gradient(135deg, #ff6b6b, #ee5a5a);
    color: #fff; padding: 12px 18px;
    z-index: 9999;
    display: none; align-items: center; gap: 12px;
    box-shadow: 0 4px 14px rgba(255,107,107,0.35);
}
.sos-banner.show { display: flex; }
.sos-banner .sos-icon {
    font-size: 22px;
    animation: sosPulse 1.5s infinite;
}
@keyframes sosPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}
.sos-banner .sos-info { flex: 1; }
.sos-banner .sos-info .sos-title { font-weight: 600; font-size: 14px; }
.sos-banner .sos-info .sos-content { font-size: 12px; opacity: 0.9; margin-top: 2px; }

/* ============ 地图 ============ */
.map-full {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    z-index: 98;
}
.map-full #map { width: 100%; height: 100%; }

/* ============ 滚动条 ============ */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #ddd; border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: #bbb; }

::selection { background: var(--primary-light); color: var(--primary-dark); }

/* ============ 响应式 ============ */
@media (max-width: 480px) {
    body { font-size: 14px; }
    .fab { width: 48px; height: 48px; font-size: 26px; right: 14px; }
    .moment-card { margin: 8px 10px; padding: 12px; }
    .banner { margin: 8px 10px; height: 180px; }
}

@media (min-width: 1024px) {
    body { max-width: 800px; }
    .bottom-nav { max-width: 800px; }
}

/* ============ 全局过渡效果 ============ */
* { -webkit-font-smoothing: antialiased; }

/* 平滑滚动 */
html { scroll-behavior: smooth; }

/* 卡片悬停效果 */
.moment-card, .help-card, .reward-card {
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.moment-card:hover, .help-card:hover, .reward-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* 按钮过渡 */
button, .btn, .device-chip, .pill {
    transition: all 0.15s ease;
}

/* 图片加载过渡 */
img {
    transition: opacity 0.2s ease;
}
img[loading="lazy"] {
    opacity: 0;
}
img:not([loading="lazy"]) {
    opacity: 1;
}

/* 底部导航活跃指示器 */
.bottom-nav .nav-item.active .nav-icon {
    transform: scale(1.1);
}

/* 发布按钮脉冲效果 */
.fab {
    animation: fabPulse 2s ease-in-out infinite;
}
@keyframes fabPulse {
    0%, 100% { box-shadow: 0 6px 20px rgba(240,98,146,0.4); }
    50% { box-shadow: 0 6px 28px rgba(240,98,146,0.55); }
}

/* 板块标签激活态 */
.pill.active {
    animation: pillPop 0.3s ease;
}
@keyframes pillPop {
    0% { transform: scale(0.95); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}