:root {
    --red: #c8102e;
    --red-dark: #a00d24;
    --red-light: #fdecef;
    --gold: #d4a017;
    --bg: #f4f5f7;
    --text: #222;
    --muted: #777;
    --line: #e6e6e6;
    --ok: #1a9d5c;
    --warn: #e6a23c;
    --danger: #d43c3c;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: -apple-system, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif; background: var(--bg); color: var(--text); font-size: 14px; }
a { color: var(--red); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ============ 党员端（移动风格） ============ */
.member-shell { max-width: 480px; margin: 0 auto; min-height: 100vh; background: #fff; box-shadow: 0 0 20px rgba(0,0,0,.06); position: relative; padding-bottom: 64px; }
.member-head { background: linear-gradient(135deg, var(--red), var(--red-dark)); color: #fff; padding: 18px 16px 26px; }
.member-head .branch { font-size: 12px; opacity: .85; }
.member-head .name { font-size: 20px; font-weight: 700; margin-top: 2px; }
.member-head .sub { font-size: 12px; opacity: .9; margin-top: 4px; }
.member-body { padding: 14px; }
.member-nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 480px; background: #fff; border-top: 1px solid var(--line); display: flex; z-index: 50; }
.member-nav a { flex: 1; text-align: center; padding: 9px 0 7px; color: var(--muted); font-size: 11px; }
.member-nav a.active { color: var(--red); font-weight: 600; }
.member-nav .ico { display: block; font-size: 19px; line-height: 1; margin-bottom: 2px; }

.card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-bottom: 12px; }
.card h3 { margin: 0 0 8px; font-size: 15px; }
.list-item { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.list-item:last-child { border-bottom: 0; }
.list-item .t { font-weight: 500; }
.list-item .d { font-size: 12px; color: var(--muted); margin-top: 3px; }
.badge { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 11px; background: var(--red-light); color: var(--red); }
.badge.gray { background: #eee; color: #888; }
.badge.ok { background: #e8f7ef; color: var(--ok); }
.badge.warn { background: #fdf3e5; color: var(--warn); }
.badge.danger { background: #fdeaea; color: var(--danger); }

.btn { display: inline-block; border: 0; background: var(--red); color: #fff; padding: 10px 18px; border-radius: 8px; font-size: 14px; cursor: pointer; }
.btn:hover { background: var(--red-dark); }
.btn.block { display: block; width: 100%; text-align: center; }
.btn.ghost { background: #fff; color: var(--red); border: 1px solid var(--red); }
.btn.small { padding: 5px 12px; font-size: 12px; }

.form-row { margin-bottom: 12px; }
.form-row label { display: block; font-size: 13px; margin-bottom: 5px; color: #444; }
.form-row input, .form-row select, .form-row textarea { width: 100%; padding: 9px 10px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; }
.form-row textarea { min-height: 90px; }
.alert { padding: 10px 12px; border-radius: 8px; margin-bottom: 12px; font-size: 13px; }
.alert.ok { background: #e8f7ef; color: var(--ok); }
.alert.err { background: #fdeaea; color: var(--danger); }

.ring { position: relative; width: 76px; height: 76px; }
.ring svg { transform: rotate(-90deg); }
.ring .ring-txt { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ring .ring-txt b { font-size: 18px; }

.overdue { color: var(--danger); font-weight: 600; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.mt8 { margin-top: 8px; }
.mt12 { margin-top: 12px; }
.flex { display: flex; align-items: center; gap: 8px; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.grow { flex: 1; }

/* ============ 支委端（PC 风格） ============ */
.admin-shell { display: flex; min-height: 100vh; }
.admin-side { width: 220px; background: #2b2f3a; color: #cfd3dc; flex-shrink: 0; }
.admin-side .logo { padding: 18px 16px; color: #fff; font-weight: 700; font-size: 16px; border-bottom: 1px solid rgba(255,255,255,.08); }
.admin-side nav a { display: block; padding: 12px 18px; color: #cfd3dc; font-size: 13px; }
.admin-side nav a:hover { background: rgba(255,255,255,.05); color: #fff; }
.admin-side nav a.active { background: var(--red); color: #fff; }
.admin-main { flex: 1; padding: 20px 24px; overflow: auto; }
.admin-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 18px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 16px; }
.stat .n { font-size: 26px; font-weight: 700; color: var(--red); }
.stat .l { font-size: 12px; color: var(--muted); margin-top: 3px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 16px; margin-bottom: 16px; }
.panel h3 { margin: 0 0 12px; font-size: 15px; }
table.grid { width: 100%; border-collapse: collapse; }
table.grid th, table.grid td { border-bottom: 1px solid var(--line); padding: 9px 10px; text-align: left; font-size: 13px; }
table.grid th { background: #fafafa; color: #555; font-weight: 600; }
table.grid tr:hover td { background: #fafbfc; }
.filter-bar { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.filter-bar input, .filter-bar select { padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.tabs a { padding: 8px 14px; color: #555; font-size: 13px; border-bottom: 2px solid transparent; }
.tabs a.active { color: var(--red); border-bottom-color: var(--red); font-weight: 600; }
