/* ============================================
   家族族谱系统 - 主样式表
   主题：中国红(#C8102E) + 米金(#D4AF37/#F5E6C8)
   卡片式布局，全终端响应式
   ============================================ */
:root {
    --primary: #C8102E;
    --primary-dark: #8B0000;
    --primary-light: #E8384F;
    --gold: #D4AF37;
    --gold-light: #F5E6C8;
    --gold-dark: #B8860B;
    --bg: #FAF5F0;
    --bg-dark: #1A0A0A;
    --card: #FFFFFF;
    --text: #333333;
    --text-light: #666666;
    --text-muted: #999999;
    --border: #E8DCC8;
    --male: #2E5C8A;
    --female: #C2185B;
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #C8102E;
    --shadow: 0 4px 20px rgba(200, 16, 46, 0.1);
    --shadow-hover: 0 8px 30px rgba(200, 16, 46, 0.2);
    --radius: 12px;
    --radius-sm: 8px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 14px;
}
a { color: var(--primary); text-decoration: none; transition: color .3s; }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; height: auto; }

/* ========== 顶部导航 ========== */
.top-bar {
    background: linear-gradient(135deg, var(--bg-dark) 0%, #2D1515 100%);
    color: var(--gold-light);
    padding: 6px 0;
    font-size: 12px;
}
.top-bar .container { display: flex; justify-content: space-between; align-items: center; }
.top-bar a { color: var(--gold-light); margin-left: 16px; }
.top-bar a:hover { color: var(--gold); }

.header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,.2);
}
.header::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--gold), var(--gold-light), var(--gold));
}
.header .container { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.logo { display: flex; align-items: center; gap: 12px; }
.logo-icon {
    width: 48px; height: 48px;
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; color: var(--primary-dark);
    font-weight: bold;
    box-shadow: 0 2px 10px rgba(212,175,55,.4);
}
.logo-text h1 { font-size: 20px; letter-spacing: 2px; }
.logo-text p { font-size: 11px; opacity: .8; letter-spacing: 1px; }

.nav { display: flex; gap: 4px; }
.nav a {
    color: rgba(255,255,255,.9);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: all .3s;
    position: relative;
}
.nav a:hover, .nav a.active {
    background: rgba(255,255,255,.15);
    color: var(--gold-light);
}
.nav a.active::after {
    content: '';
    position: absolute;
    bottom: -2px; left: 50%;
    transform: translateX(-50%);
    width: 20px; height: 2px;
    background: var(--gold);
    border-radius: 2px;
}

.user-actions { display: flex; align-items: center; gap: 12px; }
.btn-login {
    background: var(--gold);
    color: var(--primary-dark) !important;
    padding: 8px 20px !important;
    border-radius: 20px !important;
    font-weight: bold;
}
.btn-login:hover { background: var(--gold-light); }

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
}

/* ========== 容器 ========== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.main { padding: 30px 0; min-height: calc(100vh - 300px); }

/* ========== 横幅/Banner ========== */
.banner {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-dark) 100%);
    color: #fff;
    padding: 60px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.banner::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(212,175,55,.1) 0%, transparent 60%);
    animation: rotate 20s linear infinite;
}
@keyframes rotate { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.banner h2 { font-size: 36px; margin-bottom: 12px; letter-spacing: 4px; position: relative; }
.banner p { font-size: 16px; opacity: .9; position: relative; }
.banner .stats-row {
    display: flex; justify-content: center; gap: 60px;
    margin-top: 30px; position: relative;
}
.banner .stat-item { text-align: center; }
.banner .stat-num { font-size: 32px; font-weight: bold; color: var(--gold); }
.banner .stat-label { font-size: 13px; opacity: .8; }

/* ========== 卡片 ========== */
.card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 20px;
    transition: box-shadow .3s, transform .3s;
    border: 1px solid var(--border);
}
.card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.card-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 16px; padding-bottom: 12px;
    border-bottom: 2px solid var(--gold-light);
}
.card-title {
    font-size: 18px; color: var(--primary-dark);
    display: flex; align-items: center; gap: 8px;
    font-weight: bold;
}
.card-title::before {
    content: '';
    width: 4px; height: 20px;
    background: linear-gradient(180deg, var(--primary), var(--gold));
    border-radius: 2px;
}

/* ========== 网格布局 ========== */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
.grid-6 { grid-template-columns: repeat(6, 1fr); }

/* ========== 快捷入口 ========== */
.quick-nav { display: grid; grid-template-columns: repeat(8, 1fr); gap: 16px; margin: 30px 0; }
.quick-item {
    background: var(--card);
    border-radius: var(--radius);
    padding: 20px 12px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: all .3s;
    border: 1px solid var(--border);
    cursor: pointer;
}
.quick-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: var(--gold);
}
.quick-icon {
    width: 50px; height: 50px;
    margin: 0 auto 10px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px;
}
.quick-item:nth-child(even) .quick-icon { background: linear-gradient(135deg, var(--gold), var(--gold-dark)); }
.quick-label { font-size: 13px; color: var(--text); font-weight: 500; }

/* ========== 族人卡片 ========== */
.member-card {
    background: var(--card);
    border-radius: var(--radius);
    padding: 16px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: all .3s;
    border: 1px solid var(--border);
    cursor: pointer;
}
.member-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.member-avatar {
    width: 70px; height: 70px;
    border-radius: 50%;
    margin: 0 auto 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; font-weight: bold; color: #fff;
    border: 3px solid var(--gold-light);
}
.member-avatar.male { background: linear-gradient(135deg, var(--male), #1A3A5C); }
.member-avatar.female { background: linear-gradient(135deg, var(--female), #880E4F); }
.member-avatar-photo { padding: 0; overflow: hidden; background: #fff; }
.member-avatar-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.member-name { font-size: 16px; font-weight: bold; color: var(--text); margin-bottom: 4px; }
.member-info { font-size: 12px; color: var(--text-muted); }
.member-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    margin-top: 6px;
}
.badge-alive { background: #E8F5E9; color: var(--success); }
.badge-dead { background: #FBE9E7; color: var(--danger); }
.badge-male { background: #E3F2FD; color: var(--male); }
.badge-female { background: #FCE4EC; color: var(--female); }

/* ========== 家族树 ========== */
.tree-container {
    background: var(--card);
    border-radius: var(--radius);
    padding: 20px;
    overflow: auto;
    min-height: 500px;
    position: relative;
}
.tree-node {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 8px;
    margin: 4px;
    font-size: 13px;
    cursor: pointer;
    transition: all .3s;
    border: 2px solid transparent;
    text-align: center;
    min-width: 80px;
}
.tree-node.male { background: #E3F2FD; border-color: var(--male); color: var(--male); }
.tree-node.female { background: #FCE4EC; border-color: var(--female); color: var(--female); }
.tree-node:hover { transform: scale(1.05); box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.tree-node.root { background: linear-gradient(135deg, var(--gold), var(--gold-dark)); color: #fff; border-color: var(--gold-dark); font-weight: bold; }
.tree-children { margin-left: 40px; border-left: 2px dashed var(--border); padding-left: 20px; }
.tree-spouse { color: var(--text-muted); font-size: 12px; }

/* 吊线图 */
.hanging-tree { display: flex; flex-wrap: wrap; gap: 20px; }
.hanging-generation { flex: 1; min-width: 200px; }
.hanging-gen-title {
    text-align: center; padding: 8px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff; border-radius: 8px 8px 0 0;
    font-weight: bold;
}
.hanging-gen-body {
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 8px 8px;
    padding: 10px;
    min-height: 100px;
}

/* ========== 按钮 ========== */
.btn {
    display: inline-block;
    padding: 10px 24px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff !important;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 14px;
    cursor: pointer;
    transition: all .3s;
    text-align: center;
    font-weight: 500;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(200,16,46,.3); }
.btn-gold { background: linear-gradient(135deg, var(--gold), var(--gold-dark)); }
.btn-gold:hover { box-shadow: 0 4px 12px rgba(212,175,55,.4); }
.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary) !important;
}
.btn-outline:hover { background: var(--primary); color: #fff !important; }
.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-lg { padding: 14px 36px; font-size: 16px; }
.btn-block { display: block; width: 100%; }
.btn-danger { background: linear-gradient(135deg, var(--danger), #A71D2A); }
.btn-success { background: linear-gradient(135deg, var(--success), #1E7E34); }

/* ========== 详情页紧凑水平按钮（v183：缩小按钮，水平布局，重点展示内容） ========== */
.detail-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 16px 0;
}
.detail-actions .btn {
    padding: 7px 18px;
    font-size: 13px;
    border-radius: 20px;
    min-height: auto;
    line-height: 1.4;
}
.bio-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
}
.bio-actions .btn {
    padding: 7px 18px;
    font-size: 13px;
    border-radius: 20px;
    min-height: auto;
}

/* ========== 表单 ========== */
.form-group { margin-bottom: 20px; }
.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--text);
    font-size: 14px;
}
.form-group label .required { color: var(--danger); }
.form-control {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: border-color .3s, box-shadow .3s;
    background: #fff;
}
.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(200,16,46,.1);
}
textarea.form-control { resize: vertical; min-height: 100px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-row-3 { grid-template-columns: repeat(3, 1fr); }

/* ========== 表格 ========== */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
table th, table td {
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}
table th {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    font-weight: 500;
    font-size: 13px;
}
table tr:hover { background: var(--gold-light); }
table tr:nth-child(even) { background: #FAF7F2; }

/* ========== 分页 ========== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 24px;
    flex-wrap: wrap;
}
.pagination a, .pagination span {
    padding: 8px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 13px;
    transition: all .3s;
}
.pagination a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination .current { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ========== 公告滚动 ========== */
.notice-scroll {
    background: var(--card);
    border-radius: var(--radius);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    border-left: 4px solid var(--primary);
}
.notice-scroll .label {
    background: var(--primary);
    color: #fff;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    flex-shrink: 0;
}
.notice-scroll .content { flex: 1; overflow: hidden; }
.notice-scroll .content a { color: var(--text); }

/* ========== 统计卡片 ========== */
.stat-card {
    background: var(--card);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow);
    border-top: 4px solid var(--primary);
    transition: all .3s;
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.stat-card.gold { border-top-color: var(--gold); }
.stat-card.blue { border-top-color: var(--male); }
.stat-card.pink { border-top-color: var(--female); }
.stat-card.green { border-top-color: var(--success); }
.stat-num { font-size: 32px; font-weight: bold; color: var(--primary-dark); margin-bottom: 4px; }
.stat-card.gold .stat-num { color: var(--gold-dark); }
.stat-label { font-size: 13px; color: var(--text-muted); }

/* ========== 进度条 ========== */
.progress { height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; }
.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    border-radius: 4px;
    transition: width .5s;
}

/* ========== 时间线 ========== */
.timeline { position: relative; padding-left: 30px; }
.timeline::before {
    content: '';
    position: absolute;
    left: 8px; top: 0; bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--primary), var(--gold));
}
.timeline-item { position: relative; margin-bottom: 24px; }
.timeline-item::before {
    content: '';
    position: absolute;
    left: -28px; top: 6px;
    width: 14px; height: 14px;
    background: var(--primary);
    border-radius: 50%;
    border: 3px solid var(--gold-light);
}
.timeline-date { font-size: 13px; color: var(--gold-dark); font-weight: bold; margin-bottom: 4px; }
.timeline-title { font-size: 16px; color: var(--text); font-weight: 500; margin-bottom: 4px; }
.timeline-desc { font-size: 13px; color: var(--text-light); }

/* ========== 瀑布流相册 ========== */
.masonry {
    column-count: 4;
    column-gap: 16px;
}
.masonry-item {
    break-inside: avoid;
    margin-bottom: 16px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all .3s;
}
.masonry-item:hover { transform: scale(1.02); box-shadow: var(--shadow-hover); }
.masonry-item img { width: 100%; display: block; }
.masonry-caption { padding: 8px 12px; background: var(--card); font-size: 12px; color: var(--text-light); }

/* ========== 名人堂 ========== */
.hall-card {
    background: var(--card);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all .3s;
    border: 1px solid var(--border);
}
.hall-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.hall-photo { height: 200px; background: linear-gradient(135deg, var(--gold-light), var(--gold)); display: flex; align-items: center; justify-content: center; font-size: 48px; color: var(--primary-dark); }
.hall-photo img { width: 100%; height: 100%; object-fit: cover; }
.hall-body { padding: 16px; }
.hall-name { font-size: 18px; font-weight: bold; color: var(--primary-dark); margin-bottom: 4px; }
.hall-title { font-size: 13px; color: var(--gold-dark); margin-bottom: 8px; }
.hall-desc { font-size: 13px; color: var(--text-light); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* ========== 祭奠堂 ========== */
.memorial-card {
    background: linear-gradient(135deg, #2C1810, #1A0F0A);
    color: var(--gold-light);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    border: 1px solid var(--gold);
}
.memorial-photo {
    width: 100px; height: 100px;
    border-radius: 50%;
    margin: 0 auto 16px;
    border: 3px solid var(--gold);
    overflow: hidden;
    background: var(--gold-light);
}
.memorial-name { font-size: 20px; color: var(--gold); margin-bottom: 4px; }
.memorial-dates { font-size: 13px; opacity: .8; }
.memorial-actions { margin-top: 16px; display: flex; justify-content: center; gap: 12px; }
.worship-btn {
    background: rgba(212,175,55,.2);
    border: 1px solid var(--gold);
    color: var(--gold);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all .3s;
}
.worship-btn:hover { background: var(--gold); color: var(--bg-dark); }

/* ========== 五服图 ========== */
.wufu-diagram { text-align: center; padding: 30px; }
.wufu-level {
    display: inline-block;
    padding: 12px 24px;
    margin: 8px;
    border-radius: var(--radius-sm);
    font-weight: bold;
    color: #fff;
}
.wufu-zhancui { background: #8B0000; }
.wufu-qicui { background: #C8102E; }
.wufu-dagong { background: #E85D75; }
.wufu-xiaogong { background: #F0A0AE; }
.wufu-sima { background: #F5D0D8; color: #333; }

/* ========== 宗亲圈 ========== */
.feed-card {
    background: var(--card);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}
.feed-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.feed-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: bold; }
.feed-user-info { flex: 1; }
.feed-username { font-weight: bold; color: var(--text); }
.feed-time { font-size: 12px; color: var(--text-muted); }
.feed-content { font-size: 14px; line-height: 1.8; margin-bottom: 12px; }
.feed-images { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.feed-images img { border-radius: 6px; width: 100%; height: 120px; object-fit: cover; }
.feed-actions { display: flex; gap: 24px; padding-top: 12px; border-top: 1px solid var(--border); }
.feed-action { color: var(--text-muted); cursor: pointer; font-size: 13px; display: flex; align-items: center; gap: 4px; }
.feed-action:hover, .feed-action.liked { color: var(--primary); }

/* ========== 话题讨论 ========== */
.topic-item {
    background: var(--card);
    border-radius: var(--radius-sm);
    padding: 16px 20px;
    margin-bottom: 12px;
    display: flex;
    gap: 16px;
    border: 1px solid var(--border);
    transition: all .3s;
}
.topic-item:hover { border-color: var(--gold); box-shadow: var(--shadow); }
.topic-stats { text-align: center; min-width: 60px; }
.topic-replies { font-size: 20px; font-weight: bold; color: var(--primary); }
.topic-views { font-size: 11px; color: var(--text-muted); }
.topic-main { flex: 1; }
.topic-title { font-size: 16px; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.topic-meta { font-size: 12px; color: var(--text-muted); }
/* ========== 底部 ========== */
.footer {
    background: linear-gradient(135deg, var(--bg-dark), #2D1515);
    color: var(--gold-light);
    padding: 40px 0 20px;
    margin-top: 40px;
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px; margin-bottom: 30px; }
.footer h4 { color: var(--gold); margin-bottom: 16px; font-size: 16px; }
.footer p, .footer a { color: rgba(245,230,200,.7); font-size: 13px; line-height: 2; }
.footer a:hover { color: var(--gold); }
.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(212,175,55,.2);
    font-size: 12px;
    color: rgba(245,230,200,.5);
}

/* ========== 标签/筛选 ========== */
.filter-bar {
    background: var(--card);
    border-radius: var(--radius);
    padding: 16px 20px;
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    border: 1px solid var(--border);
}
.filter-bar select, .filter-bar input {
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 13px;
}
.tag {
    display: inline-block;
    padding: 4px 12px;
    background: var(--gold-light);
    color: var(--gold-dark);
    border-radius: 12px;
    font-size: 12px;
    margin: 2px;
}
.tag.active { background: var(--primary); color: #fff; }

/* ========== 详情页 ========== */
.detail-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    color: #fff;
    padding: 30px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    display: flex;
    gap: 30px;
    align-items: center;
}
.detail-avatar {
    width: 120px; height: 120px;
    border-radius: 50%;
    border: 4px solid var(--gold);
    display: flex; align-items: center; justify-content: center;
    font-size: 48px; font-weight: bold; color: #fff;
    flex-shrink: 0;
}
.detail-avatar.male { background: linear-gradient(135deg, var(--male), #1A3A5C); }
.detail-avatar.female { background: linear-gradient(135deg, var(--female), #880E4F); }
.detail-avatar-photo { padding: 0; overflow: hidden; background: #fff; }
.detail-avatar-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.detail-info h2 { font-size: 28px; margin-bottom: 8px; }
.detail-meta { display: flex; gap: 20px; flex-wrap: wrap; font-size: 14px; opacity: .9; }

.info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.info-item { display: flex; padding: 8px 0; border-bottom: 1px dashed var(--border); }
.info-label { width: 100px; color: var(--text-muted); flex-shrink: 0; }
.info-value { color: var(--text); flex: 1; }

/* ========== 谱文 ========== */
.genealogy-text {
    background: linear-gradient(135deg, #FFFEF5, #FAF5E8);
    border: 2px solid var(--gold);
    border-radius: var(--radius);
    padding: 30px;
    font-family: "KaiTi", "STKaiti", serif;
    font-size: 16px;
    line-height: 2;
    color: #3E2723;
    white-space: pre-wrap;
}

/* ============================================
   响应式设计 - 平板端 (768px - 1024px)
   ============================================ */
@media (max-width: 1024px) {
    /* 容器 */
    .container { max-width: 100%; padding: 0 16px; }
    /* 顶部栏 */
    .top-bar .container { flex-wrap: wrap; gap: 4px; justify-content: center; }
    .top-bar-slogan { width: 100%; text-align: center; font-size: 11px; }
    /* Header */
    .header .container { height: 64px; }
    .logo-text h1 { font-size: 18px; letter-spacing: 1px; }
    .logo-text p { font-size: 10px; }
    .logo-icon { width: 44px; height: 44px; }
    /* 网格布局 */
    .grid-4, .grid-5, .grid-6 { grid-template-columns: repeat(3, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .grid-2 { grid-template-columns: repeat(2, 1fr); }
    /* 快捷导航 */
    .quick-nav { grid-template-columns: repeat(4, 1fr); gap: 12px; }
    /* 瀑布流 */
    .masonry { column-count: 2; }
    /* Banner */
    .banner { padding: 40px 20px; }
    .banner h2 { font-size: 28px; letter-spacing: 2px; }
    .banner .stats-row { gap: 30px; flex-wrap: wrap; }
    .banner .stat-num { font-size: 28px; }
    /* 卡片 */
    .card { padding: 18px; }
    .card-header { padding: 14px 18px; }
    .card-body { padding: 16px; }
    /* 表单 */
    .form-row { grid-template-columns: 1fr 1fr; }
    .form-row-3 { grid-template-columns: repeat(2, 1fr); }
    /* 详情页 */
    .detail-header { padding: 24px; gap: 20px; }
    .detail-avatar { width: 100px; height: 100px; font-size: 40px; }
    .detail-info h2 { font-size: 24px; }
    /* 表格 */
    table th, table td { padding: 10px 12px; font-size: 13px; }
    /* 底部 */
    .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
    .footer { padding: 30px 0 16px; }
    /* 统计卡片 */
    .stat-card { padding: 18px; }
    .stat-num { font-size: 28px; }
    /* 筛选栏 */
    .filter-bar { padding: 12px 16px; gap: 10px; }
    /* 公告滚动 */
    .notice-scroll { padding: 10px 16px; gap: 10px; }
    /* 主内容 */
    .main { padding: 20px 0; }
    /* 按钮 */
    .btn { padding: 9px 18px; font-size: 13px; }
    .btn-lg { padding: 12px 28px; font-size: 15px; }
}

/* ============================================
   响应式设计 - 手机端 (<768px)
   ============================================ */
@media (max-width: 768px) {
    /* 全局 */
    body { font-size: 13px; }
    .container { padding: 0 12px; }
    /* 顶部栏 */
    .top-bar { padding: 6px 0; }
    .top-bar-slogan { font-size: 10px; letter-spacing: 0; }
    .top-bar-links { font-size: 11px; }
    .top-bar-links a { margin-left: 10px; }
    /* Header */
    .header .container { height: 60px; }
    .logo { gap: 8px; }
    .logo-icon { width: 40px; height: 40px; border-radius: 10px; }
    .logo-text h1 { font-size: 16px; letter-spacing: 1px; }
    .logo-text p { font-size: 9px; letter-spacing: 0; }
    /* Banner */
    .banner { padding: 30px 16px; border-radius: 12px; }
    .banner h2 { font-size: 22px; letter-spacing: 1px; margin-bottom: 8px; }
    .banner p { font-size: 13px; }
    .banner .stats-row { gap: 16px; margin-top: 20px; }
    .banner .stat-item { min-width: 70px; }
    .banner .stat-num { font-size: 24px; }
    .banner .stat-label { font-size: 11px; }
    /* 网格布局 - 手机端全部1列 */
    .grid-2, .grid-3, .grid-4, .grid-5, .grid-6 { grid-template-columns: 1fr; gap: 14px; }
    /* 快捷导航 */
    .quick-nav { grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
    .quick-item { padding: 12px 8px; border-radius: 10px; }
    .quick-icon { width: 38px; height: 38px; font-size: 18px; margin-bottom: 6px; }
    .quick-label { font-size: 12px; }
    /* 瀑布流 */
    .masonry { column-count: 2; column-gap: 10px; }
    .masonry-item { margin-bottom: 10px; }
    /* 卡片 */
    .card { padding: 14px; border-radius: 10px; margin-bottom: 14px; }
    .card-header { padding: 12px 14px; margin-bottom: 12px; }
    .card-title { font-size: 16px; }
    .card-body { padding: 14px; }
    /* 族人卡片 */
    .member-card { padding: 12px; }
    .member-avatar { width: 54px; height: 54px; font-size: 22px; }
    .member-name { font-size: 15px; }
    .member-info { font-size: 11px; }
    /* 按钮 */
    .btn { padding: 10px 18px; font-size: 13px; border-radius: 8px; min-height: 40px; }
    .btn-sm { padding: 7px 12px; font-size: 12px; min-height: 32px; }
    .btn-lg { padding: 12px 24px; font-size: 15px; }
    .btn-block { width: 100%; }
    /* 表单 */
    .form-group { margin-bottom: 16px; }
    .form-group label { font-size: 13px; margin-bottom: 5px; }
    .form-control { padding: 10px 12px; font-size: 14px; min-height: 42px; }
    .form-row, .form-row-3 { grid-template-columns: 1fr; gap: 12px; }
    textarea.form-control { min-height: 80px; }
    /* 表格 - 横向滚动 */
    .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    table { min-width: 500px; font-size: 12px; }
    table th, table td { padding: 8px 10px; }
    /* 分页 */
    .pagination { gap: 4px; margin-top: 16px; }
    .pagination a, .pagination span { padding: 7px 11px; font-size: 12px; }
    /* 详情页 */
    .detail-header { flex-direction: column; text-align: center; padding: 20px 16px; gap: 16px; }
    .detail-avatar { width: 90px; height: 90px; font-size: 36px; }
    .detail-info h2 { font-size: 22px; }
    .detail-meta { justify-content: center; gap: 12px; font-size: 13px; }
    .info-grid { grid-template-columns: 1fr; gap: 8px; }
    .info-item { padding: 6px 0; }
    .info-label { width: 85px; font-size: 12px; }
    .info-value { font-size: 13px; }
    /* 统计卡片 */
    .stat-card { padding: 16px 12px; }
    .stat-num { font-size: 26px; }
    .stat-label { font-size: 12px; }
    /* 筛选栏 */
    .filter-bar { padding: 12px; gap: 8px; flex-direction: column; align-items: stretch; }
    .filter-bar select, .filter-bar input { width: 100%; padding: 10px; font-size: 14px; min-height: 40px; }
    /* 公告滚动 */
    .notice-scroll { padding: 10px 12px; gap: 8px; flex-wrap: wrap; }
    .notice-scroll .label { font-size: 11px; padding: 3px 10px; }
    .notice-scroll .content { font-size: 13px; }
    /* 时间线 */
    .timeline { padding-left: 24px; }
    .timeline-item { margin-bottom: 18px; }
    .timeline-date { font-size: 12px; }
    .timeline-title { font-size: 14px; }
    .timeline-desc, .timeline-content { font-size: 12px; }
    /* 名人堂 */
    .hall-photo { height: 160px; font-size: 36px; }
    .hall-body { padding: 12px; }
    .hall-name { font-size: 16px; }
    /* 祭奠堂 */
    .memorial-card { padding: 18px; }
    .memorial-photo { width: 80px; height: 80px; }
    .memorial-name { font-size: 18px; }
    .memorial-actions { flex-wrap: wrap; gap: 8px; }
    .worship-btn { padding: 6px 12px; font-size: 11px; }
    /* 底部 */
    .footer { padding: 24px 0 14px; margin-top: 24px; }
    .footer-grid { grid-template-columns: 1fr; gap: 20px; text-align: center; }
    .footer-col { text-align: center; }
    .footer-logo { justify-content: center; }
    .footer h4 { font-size: 15px; margin-bottom: 10px; }
    .footer p, .footer a { font-size: 12px; line-height: 1.8; }
    .footer-bottom { font-size: 11px; padding-top: 14px; }
    /* 主内容区 */
    .main { padding: 14px 0; min-height: auto; }
    /* 标签 */
    .tag { padding: 3px 10px; font-size: 11px; }
    /* 进度条 */
    .progress { height: 6px; }
    /* 五服图 */
    .wufu-diagram { padding: 16px; }
    .wufu-level { padding: 8px 16px; font-size: 13px; margin: 4px; }
    /* 谱文 */
    .genealogy-text { padding: 16px; font-size: 14px; line-height: 1.8; }
    /* 话题/动态 */
    .topic-item { flex-direction: column; gap: 10px; padding: 12px; }
    .topic-stats { display: flex; gap: 16px; min-width: auto; }
    .feed-card { padding: 14px; }
    .feed-images { grid-template-columns: repeat(2, 1fr); }
    .feed-images img { height: 100px; }
    .feed-actions { gap: 16px; }
    /* 搜索框 */
    .card form[style*="display:flex"] {
        flex-direction: column;
    }
    .card form[style*="display:flex"] input[type="text"] {
        width: 100%;
    }
}

/* ============================================
   响应式设计 - 小屏手机 (<480px)
   ============================================ */
@media (max-width: 480px) {
    /* 快捷导航2列 */
    .quick-nav { grid-template-columns: repeat(2, 1fr); }
    /* 瀑布流1列 */
    .masonry { column-count: 1; }
    /* Banner统计 */
    .banner .stats-row { gap: 12px; }
    .banner .stat-item { min-width: 60px; }
    .banner .stat-num { font-size: 20px; }
    .banner .stat-label { font-size: 10px; }
    .banner h2 { font-size: 20px; }
    /* Logo */
    .logo-text h1 { font-size: 14px; }
    .logo-text p { display: none; }
    /* 统计卡片 */
    .stat-num { font-size: 22px; }
    /* 族人卡片网格在480以下保持1列 */
    .grid-2 { grid-template-columns: 1fr; }
    /* 按钮 */
    .btn { font-size: 12px; padding: 9px 14px; }
    /* 卡片 */
    .card { padding: 12px; }
    .card-body { padding: 12px; }
    /* 详情 */
    .detail-avatar { width: 75px; height: 75px; font-size: 30px; }
    .detail-info h2 { font-size: 20px; }
    /* 表格最小宽度 */
    table { min-width: 420px; }
    /* 名人堂 */
    .hall-photo { height: 140px; }
    /* 动态图片 */
    .feed-images { grid-template-columns: 1fr; }
    .feed-images img { height: 140px; }
}

/* ============================================
   响应式设计 - 横屏手机优化
   ============================================ */
@media (max-width: 768px) and (orientation: landscape) {
    .header .container { height: 54px; }
    .nav { max-height: calc(100vh - 54px); }
    .banner { padding: 20px 16px; }
    .banner h2 { font-size: 20px; }
    .banner .stats-row { gap: 20px; margin-top: 14px; }
}

/* ============================================
   触摸设备优化
   ============================================ */
@media (hover: none) and (pointer: coarse) {
    .btn, .nav-item, .quick-item, .member-card, .hall-card,
    .pagination a, .dropdown-menu a, .filter-bar select, .filter-bar input {
        min-height: 40px;
    }
    .card:hover, .member-card:hover, .hall-card:hover, .quick-item:hover {
        transform: none;
    }
    .nav-dropdown:hover .dropdown-menu {
        opacity: 0;
        visibility: hidden;
    }
}

/* ========== 工具类 ========== */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-primary { color: var(--primary); }
.text-gold { color: var(--gold-dark); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.mt-10 { margin-top: 10px; } .mt-20 { margin-top: 20px; } .mt-30 { margin-top: 30px; }
.mb-10 { margin-bottom: 10px; } .mb-20 { margin-bottom: 20px; } .mb-30 { margin-bottom: 30px; }
.flex { display: flex; } .flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-10 { gap: 10px; } .gap-20 { gap: 20px; }
.hidden { display: none !important; }

/* ============================================
   移动端APP式底部导航栏 (v54)
   仅在 < 768px 显示，PC/平板不显示
   ============================================ */
.mobile-bottom-nav {
    display: none;
}

.mbn-drawer-overlay {
    display: none;
}

.mbn-drawer {
    display: none;
}

@media (max-width: 767px) {
    /* 底部导航栏 */
    .mobile-bottom-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: 56px;
        padding-bottom: env(safe-area-inset-bottom, 0px);
        background: linear-gradient(180deg, #fff 0%, #faf8f5 100%);
        border-top: 2px solid #C8102E;
        box-shadow: 0 -4px 16px rgba(139,0,0,.12);
        z-index: 9998;
    }

    .mbn-item {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        text-decoration: none;
        color: #888;
        font-size: 11px;
        transition: color .2s, background .2s;
        position: relative;
        -webkit-tap-highlight-color: transparent;
    }

    .mbn-item:active,
    .mbn-item.tapped {
        background: rgba(200,16,46,.08);
    }

    .mbn-item.active {
        color: #C8102E;
        font-weight: 600;
    }

    .mbn-item.active::before {
        content: '';
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 28px;
        height: 3px;
        background: linear-gradient(90deg, #C8102E, #D4AF37);
        border-radius: 0 0 3px 3px;
    }

    /* 简单几何图形代替图标 */
    .mbn-shape {
        width: 20px;
        height: 20px;
        border: 2px solid currentColor;
        border-radius: 4px;
        opacity: .7;
        position: relative;
    }

    .mbn-item.active .mbn-shape {
        opacity: 1;
        background: rgba(200,16,46,.1);
    }

    .mbn-shape-menu {
        border-radius: 50%;
        border-style: dashed;
    }

    .mbn-shape-menu::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 6px;
        height: 6px;
        background: currentColor;
        border-radius: 50%;
    }

    .mbn-label {
        line-height: 1;
    }

    /* 移动端内容区底部留白，避免被导航栏遮挡 */
    body {
        padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px));
    }

    .main {
        padding-bottom: 0;
    }

    /* 抽屉遮罩 */
    .mbn-drawer-overlay {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,.5);
        z-index: 9999;
        opacity: 0;
        visibility: hidden;
        transition: opacity .3s ease, visibility .3s ease;
    }

    .mbn-drawer-overlay.open {
        opacity: 1;
        visibility: visible;
    }

    /* 抽屉菜单 */
    .mbn-drawer {
        display: block;
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: 82%;
        max-width: 340px;
        background: #FAF5F0;
        z-index: 10000;
        transform: translateX(100%);
        transition: transform .3s cubic-bezier(.4,0,.2,1);
        box-shadow: -8px 0 24px rgba(0,0,0,.2);
        display: flex;
        flex-direction: column;
    }

    .mbn-drawer.open {
        transform: translateX(0);
    }

    .mbn-drawer-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px 20px;
        background: linear-gradient(135deg, #8B0000, #C8102E);
        color: #D4AF37;
    }

    .mbn-drawer-title {
        font-size: 17px;
        font-weight: bold;
        letter-spacing: 2px;
    }

    .mbn-drawer-close {
        width: 32px;
        height: 32px;
        border: none;
        background: rgba(255,255,255,.15);
        color: #fff;
        font-size: 22px;
        line-height: 1;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: background .2s;
    }

    .mbn-drawer-close:active {
        background: rgba(255,255,255,.3);
    }

    .mbn-drawer-body {
        flex: 1;
        overflow-y: auto;
        padding: 16px;
        -webkit-overflow-scrolling: touch;
    }

    .mbn-drawer-group {
        margin-bottom: 20px;
    }

    .mbn-drawer-group-title {
        font-size: 13px;
        color: #8B0000;
        font-weight: bold;
        margin-bottom: 10px;
        padding-left: 10px;
        border-left: 3px solid #D4AF37;
    }

    .mbn-drawer-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .mbn-drawer-link {
        display: block;
        text-align: center;
        padding: 12px 6px;
        background: #fff;
        border-radius: 10px;
        text-decoration: none;
        color: #444;
        font-size: 13px;
        border: 1px solid #E8DCC8;
        transition: all .2s;
        -webkit-tap-highlight-color: transparent;
    }

    .mbn-drawer-link:active {
        background: #C8102E;
        color: #fff;
        border-color: #C8102E;
        transform: scale(.96);
    }
}

/* PC端和平板端严格隐藏移动端菜单 */
@media (min-width: 768px) {
    .mobile-bottom-nav,
    .mbn-drawer-overlay,
    .mbn-drawer {
        display: none !important;
    }
}

/* 移动端隐藏顶部汉堡菜单（使用底部导航+抽屉代替） */
@media (max-width: 767px) {
    .mobile-menu-btn {
        display: none !important;
    }
    .nav {
        display: none !important;
    }
    .header .container {
        justify-content: center;
    }
    .logo {
        margin: 0 auto;
    }
}

/* ========== v86 统一按钮样式 ========== */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:0 20px;height:40px;border-radius:6px;font-size:14px;font-weight:500;cursor:pointer;border:none;text-decoration:none;transition:all .15s ease;box-sizing:border-box;line-height:1;white-space:nowrap}
.btn:active{transform:scale(.97)}
.btn:disabled{opacity:.5;cursor:not-allowed;transform:none}
.btn-primary{background:linear-gradient(135deg,#C8102E,#8B0000);color:#fff;box-shadow:0 2px 8px rgba(200,16,46,.3)}
.btn-primary:hover{background:linear-gradient(135deg,#a00d24,#6b0000);box-shadow:0 4px 12px rgba(200,16,46,.4)}
.btn-secondary{background:#fff;color:#333;border:1px solid #ddd}
.btn-secondary:hover{background:#f5f5f5;border-color:#bbb}
.btn-danger{background:linear-gradient(135deg,#C8102E,#8B0000);color:#fff;box-shadow:0 2px 8px rgba(200,16,46,.3)}
.btn-danger:hover{background:linear-gradient(135deg,#a00d24,#6b0000);box-shadow:0 4px 12px rgba(200,16,46,.4)}
.btn-success{background:linear-gradient(135deg,#10B981,#059669);color:#fff}
.btn-success:hover{background:linear-gradient(135deg,#059669,#047857)}
.btn-text{background:none;color:#C8102E;padding:0 8px;height:auto}
.btn-text:hover{text-decoration:underline}
.btn-icon{width:36px;height:36px;padding:0;border-radius:50%;background:rgba(0,0,0,.05);color:#555;font-size:16px}
.btn-icon:hover{background:rgba(0,0,0,.1)}
.btn-sm{height:32px;padding:0 14px;font-size:13px;border-radius:5px}
.btn-lg{height:46px;padding:0 28px;font-size:16px;border-radius:8px}
.btn-block{width:100%}
.btn-group{display:flex;gap:8px;flex-wrap:wrap}
.btn-group .btn{flex:1}
/* 表单底部按钮区 */
.form-actions{display:flex;gap:10px;justify-content:center;margin-top:20px;padding-top:16px;border-top:1px solid #eee}
.form-actions.right{justify-content:flex-end}
/* 卡片操作按钮 */
.card-actions{display:flex;gap:8px;justify-content:flex-end;margin-top:12px}
/* 移动端按钮 */
@media(max-width:480px){
  .btn{height:38px;font-size:13px;padding:0 16px}
  .btn-lg{height:44px;font-size:15px}
  .form-actions{flex-direction:column}
  .form-actions .btn{width:100%}
}

/* ========== v100 按钮响应式增强 ========== */
@media(max-width:767px){
  .btn{min-height:44px;font-size:15px;padding:0 20px}
  .btn-sm{min-height:36px;font-size:13px;padding:0 12px}
  .btn-lg{min-height:48px;font-size:16px}
  .btn-block{width:100%}
  /* 按钮组：两个按钮并排各50% */
  .btn-group.two-col .btn{flex:1;min-width:0}
  .btn-group.two-col{gap:10px}
  /* 表单底部按钮：移动端全宽堆叠 */
  .form-actions{flex-direction:column;gap:10px}
  .form-actions .btn{width:100%}
  .form-actions.right{justify-content:center}
  /* 卡片操作按钮：移动端右对齐小按钮 */
  .card-actions .btn{min-height:36px;font-size:13px;padding:0 12px}
  /* 弹窗底部按钮 */
  .modal-footer{flex-direction:row;justify-content:flex-end;gap:10px}
  .modal-footer .btn{min-width:80px}
  /* 列表操作按钮 */
  .list-actions{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}
  .list-actions .btn{min-height:32px;font-size:12px;padding:0 10px}
}
/* 平板端 */
@media(min-width:768px) and (max-width:1024px){
  .btn{min-height:40px;font-size:14px}
  .form-actions .btn{min-width:120px}
}
/* PC端 */
@media(min-width:1025px){
  .btn{min-height:40px}
  .form-actions{justify-content:flex-end}
  .form-actions.center{justify-content:center}
}

/* ============================================
   v100: 详情页布局优化增强
   ============================================ */
.detail-header {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 24px;
    background: linear-gradient(135deg, #fff 0%, #fdf8f0 100%);
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.detail-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
}
.detail-avatar.male { background: linear-gradient(135deg, #4A90D9, #2E5C8A); }
.detail-avatar.female { background: linear-gradient(135deg, #E8A0BF, #C97B9B); }
.detail-avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.detail-info { flex: 1; min-width: 0; }
.detail-info h2 { margin: 0 0 8px; font-size: 24px; color: #1a1a1a; }
.detail-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; color: #666; font-size: 14px; }
.detail-meta span { display: inline-flex; align-items: center; }
.detail-actions { display: flex; flex-direction: row; flex-wrap: wrap; gap: 6px; justify-content: center; flex-shrink: 0; }
.detail-actions .btn-group { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.detail-btn { font-size: 12px; padding: 4px 12px; border-radius: 14px; line-height: 1.4; white-space: nowrap; }
.detail-btn-primary { background: linear-gradient(135deg,#C8102E,#8B0000); color: #fff; border: none; }
.detail-btn-outline { background: #fff; color: #C8102E; border: 1px solid #C8102E; }
.detail-btn-gold { background: linear-gradient(135deg,#D4AF37,#B8860B); color: #fff; border: none; }
.detail-btn-gray { background: #f5f5f5; color: #666; border: 1px solid #ddd; }

.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    margin-bottom: 20px;
    overflow: hidden;
}
.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #f0ebe0;
    background: #faf7f2;
}
.card-title {
    font-size: 17px;
    font-weight: 700;
    color: #1a1a1a;
    border-left: 3px solid #C8102E;
    padding-left: 10px;
}
.card-body { padding: 20px; }

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
}
.info-item {
    display: flex;
    padding: 10px 0;
    border-bottom: 1px dashed #f0ebe0;
    font-size: 14px;
}
.info-label {
    width: 90px;
    flex-shrink: 0;
    color: #888;
    font-weight: 500;
}
.info-value {
    flex: 1;
    color: #333;
    word-break: break-all;
}

/* 详情页移动端响应式 */
@media (max-width: 767px) {
    .detail-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 20px 16px;
    }
    .detail-avatar { width: 72px; height: 72px; font-size: 28px; }
    .detail-info h2 { font-size: 20px; }
    .detail-meta { justify-content: center; }
    .detail-actions { width: 100%; }
    .detail-actions .btn-group { justify-content: center; }
    .detail-actions .btn { flex: 1; min-width: 0; }
    .grid.grid-2 { grid-template-columns: 1fr; }
    .info-grid { grid-template-columns: 1fr; }
    .info-label { width: 80px; }
    .card-header { padding: 14px 16px; }
    .card-body { padding: 16px; }
    .card-title { font-size: 16px; }
}

/* 平板端 */
@media (min-width: 768px) and (max-width: 1024px) {
    .info-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ========== v132 全局UI优化 ========== */

/* 卡片通用优化 */
.card, .member-card, .stat-card, .info-card {
    transition: box-shadow 0.3s ease, transform 0.2s ease;
}
.card:hover, .member-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

/* 按钮通用优化 */
.btn, button, input[type="submit"] {
    transition: all 0.2s ease;
    cursor: pointer;
}
.btn:hover, button:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.btn:active, button:active {
    transform: translateY(0);
}

/* 表单focus效果 */
input[type="text"], input[type="email"], input[type="password"],
input[type="number"], input[type="tel"], input[type="date"],
select, textarea {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #C8102E !important;
    box-shadow: 0 0 0 3px rgba(200,16,46,0.1);
}

/* 统计卡片优化 */
.stat-card {
    position: relative;
    overflow: hidden;
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #C8102E, #D4AF37);
}
.stat-card .stat-num {
    font-size: 28px;
    font-weight: bold;
    background: linear-gradient(135deg, #C8102E, #D4AF37);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* 空状态优化 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}
.empty-state .empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}
.empty-state .empty-text {
    font-size: 14px;
    margin-bottom: 16px;
}

/* 加载动画 */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #C8102E;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 标签/徽章优化 */
.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 500;
}
.badge-pending { background: #fff3cd; color: #856404; }
.badge-approved { background: #d4edda; color: #155724; }
.badge-rejected { background: #f8d7da; color: #721c24; }

/* 分页优化 */
.pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-top: 20px;
    flex-wrap: wrap;
}
.pagination a, .pagination span {
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: all 0.2s;
}
.pagination a:hover {
    border-color: #C8102E;
    color: #C8102E;
}
.pagination .current {
    background: #C8102E;
    color: #fff;
    border-color: #C8102E;
}

/* 表格hover优化 */
table.data-table tbody tr {
    transition: background-color 0.15s;
}
table.data-table tbody tr:hover {
    background-color: #faf7f2;
}

/* 快捷入口网格优化 */
.quick-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
}
.quick-grid a {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 12px;
    background: #fff;
    border-radius: 10px;
    text-decoration: none;
    color: #333;
    transition: all 0.2s;
    border: 1px solid #f0f0f0;
}
.quick-grid a:hover {
    border-color: #C8102E;
    box-shadow: 0 4px 12px rgba(200,16,46,0.1);
    transform: translateY(-2px);
}
.quick-grid a .quick-icon {
    font-size: 28px;
    margin-bottom: 8px;
}
.quick-grid a .quick-text {
    font-size: 13px;
}

/* 图片懒加载 */
img[loading="lazy"] {
    background: #f5f5f5;
}

/* 移动端触摸优化 */
@media (max-width: 767px) {
    .btn, button, a {
        -webkit-tap-highlight-color: transparent;
    }
    .quick-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ========== v142: 页面过渡动画 ========== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.page-content, .admin-card, .card {
    animation: fadeIn 0.3s ease-out;
}
.btn, button {
    transition: all 0.2s ease;
}
.btn:active, button:active {
    transform: scale(0.97);
}
.card:hover, .admin-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

/* ========== v142: 空状态优化 ========== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}
.empty-state .empty-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.5;
}
.empty-state .empty-title {
    font-size: 18px;
    color: #666;
    margin-bottom: 8px;
}
.empty-state .empty-desc {
    font-size: 14px;
    color: #999;
    margin-bottom: 20px;
}
.empty-state .empty-action {
    display: inline-block;
    padding: 10px 24px;
    background: #C8102E;
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
}
.empty-state .empty-action:hover {
    background: #A00D24;
}

/* ========== v142: 骨架屏 ========== */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}
.skeleton-text {
    height: 14px;
    margin-bottom: 10px;
}
.skeleton-title {
    height: 20px;
    margin-bottom: 12px;
    width: 60%;
}
.skeleton-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

/* ========== v157 性能优化与响应式增强 ========== */
/* 空状态统一样式 */
.empty-state { text-align: center; padding: 48px 20px; color: #999; font-size: 15px; }
.empty-state-icon { font-size: 48px; opacity: 0.3; margin-bottom: 12px; display: block; }
/* 响应式表格容器 */
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -4px; padding: 0 4px; }
.table-responsive table { min-width: 600px; }
/* 全局Toast容器 */
.global-toast-container { position: fixed; top: 70px; left: 50%; transform: translateX(-50%); z-index: 99999; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
/* 图片懒加载占位 */
img[loading="lazy"] { background: #f5f0e8; }
/* 移动端内容区优化 */
@media (max-width: 768px) {
    .container { padding: 0 12px; }
    .card { padding: 16px; }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .btn-group { flex-wrap: wrap; }
}
@media (max-width: 480px) {
    .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
}


/* v191 全局响应式布局优化 - 确保任何设备美观 */
@media (max-width: 1200px) {
    .container { max-width: 960px; }
    .grid-4 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 992px) {
    .container { max-width: 720px; }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .sidebar { display: none; }
    .main-content { width: 100%; }
}
@media (max-width: 768px) {
    .container { max-width: 100%; padding: 0 12px; }
    .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
    .card { margin-bottom: 12px; border-radius: 10px; }
    .card-body { padding: 14px; }
    .card-title { font-size: 16px; }
    .btn { padding: 8px 16px; font-size: 13px; }
    .btn-sm { padding: 5px 12px; font-size: 12px; }
    table { font-size: 12px; }
    th, td { padding: 8px 6px; }
    h1 { font-size: 22px; }
    h2 { font-size: 18px; }
    h3 { font-size: 16px; }
    .hero-banner { padding: 30px 16px; }
    .hero-title { font-size: 24px; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .stat-card { padding: 12px; }
    .stat-number { font-size: 20px; }
    .quick-nav { grid-template-columns: repeat(4, 1fr); gap: 8px; }
    .quick-item { padding: 10px 4px; }
    .quick-label { font-size: 11px; }
}
@media (max-width: 480px) {
    .quick-nav { grid-template-columns: repeat(3, 1fr); }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .detail-actions { gap: 4px; }
    .detail-btn { font-size: 11px; padding: 4px 8px; }
}
/* 平板横屏优化 */
@media (min-width: 768px) and (max-width: 1024px) and (orientation: landscape) {
    .container { max-width: 900px; }
    .grid-4 { grid-template-columns: repeat(3, 1fr); }
}
/* 大屏优化 */
@media (min-width: 1400px) {
    .container { max-width: 1320px; }
}
/* 打印优化 */
@media print {
    .no-print, .sidebar, .footer, .admin-header { display: none !important; }
    .main-content { width: 100%; }
    .card { box-shadow: none; border: 1px solid #ddd; page-break-inside: avoid; }
}
