/* ===== 竺氏族谱 · 传统中式风格 ===== */
:root {
  --paper: #F5EFE0;       /* 宣纸米黄 */
  --paper-deep: #EAE0CB;
  --crimson: #8C2F2F;     /* 深红 */
  --crimson-light: #A63D3D;
  --ink: #3B3226;         /* 墨色 */
  --ink-soft: #6B5F4E;
  --gold: #C9A227;        /* 金色 */
  --gold-light: #E3C877;
  --line: #D8CDB8;
  --ok: #4A7A4A;
  --danger: #B04040;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: "Songti SC", "STSong", "SimSun", "Noto Serif SC", serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; font-size: 1rem; }
.hidden { display: none !important; }

/* ===== 通用容器 ===== */
.page { max-width: 640px; margin: 0 auto; padding: 0 0 84px; min-height: 100vh; }

/* ===== 顶部横幅 ===== */
.topbar {
  background: linear-gradient(160deg, var(--crimson), var(--crimson-light));
  color: var(--paper);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky; top: 0; z-index: 20;
}
.topbar .brand { font-size: 1.15rem; font-weight: 700; letter-spacing: 4px; }
.topbar .brand small { display: block; font-size: .72rem; font-weight: 400; letter-spacing: 1px; color: var(--gold-light); }
.topbar .btn-back { color: var(--paper); font-size: .95rem; padding: 6px 10px; border: 1px solid rgba(245,239,224,.5); border-radius: 6px; min-width: 44px; text-align: center; }
.topbar .spacer { width: 44px; }

/* ===== 首页封面 ===== */
.cover { text-align: center; padding: 34px 20px 20px; }
.cover .seal {
  width: 76px; height: 76px; margin: 0 auto 18px;
  border: 3px solid var(--crimson); border-radius: 10px;
  color: var(--crimson); font-size: .85rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  letter-spacing: 4px; text-indent: 4px;
  box-shadow: inset 0 0 0 3px var(--paper), inset 0 0 0 5px rgba(140,47,47,.35);
}
.cover h1 { font-size: 2.1rem; letter-spacing: 10px; text-indent: 10px; color: var(--crimson); font-weight: 900; }
.cover .subtitle { margin-top: 6px; font-size: .95rem; letter-spacing: 4px; color: var(--ink-soft); }
.cover .couplet {
  margin: 28px auto 0; max-width: 300px;
  border: 2px solid var(--crimson); border-radius: 8px;
  padding: 16px 10px; background: #FBF5E6;
  font-size: 1.05rem; line-height: 2; letter-spacing: 3px; color: var(--crimson);
}
.cover .couplet .sep { color: var(--gold); font-size: .9rem; }
.cover .preface { margin: 22px auto 0; max-width: 420px; text-align: justify; font-size: .9rem; color: var(--ink-soft); line-height: 1.9; }
.cover .entries { margin-top: 30px; display: flex; flex-direction: column; gap: 14px; max-width: 420px; margin-left: auto; margin-right: auto; }
.entry-btn {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--crimson); color: var(--paper);
  padding: 16px 20px; border-radius: 10px; font-size: 1.05rem; letter-spacing: 2px;
  box-shadow: 0 3px 10px rgba(140,47,47,.25);
}
.entry-btn .en { font-size: .75rem; color: var(--gold-light); letter-spacing: 1px; }
.entry-btn.gold { background: var(--gold); color: var(--ink); box-shadow: 0 3px 10px rgba(201,162,39,.25); }
.entry-btn.gold .en { color: var(--ink-soft); }
.entry-btn.gold:hover, .entry-btn:hover { filter: brightness(1.06); }
.cover .admin-link { margin-top: 30px; font-size: .82rem; color: var(--ink-soft); border-bottom: 1px dashed var(--line); padding-bottom: 2px; display: inline-block; }
.cover .copyright { margin-top: 20px; font-size: .72rem; color: var(--ink-soft); opacity: .7; }
.footer-copy { text-align: center; font-size: .62rem; color: #8a7f6a; padding: 2px 0 0; }

/* ===== 底部导航 ===== */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 30;
  background: var(--ink); color: var(--paper);
  display: flex; max-width: 640px; margin: 0 auto;
  border-radius: 14px 14px 0 0;
}
.bottom-nav a {
  flex: 1; text-align: center; padding: 10px 0 12px; font-size: .75rem; letter-spacing: 0;
  color: rgba(245,239,224,.75);
}
.bottom-nav a .ic { display: block; font-size: .9rem; margin-bottom: 2px; }
.bottom-nav a.active { color: var(--gold-light); font-weight: 700; }

/* ===== 通用区块标题 ===== */
.section-title {
  display: flex; align-items: center; gap: 10px;
  margin: 18px 16px 12px; font-size: 1.2rem; font-weight: 700; color: var(--crimson);
  letter-spacing: 2px;
}
.section-title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.section-title .small { font-size: .78rem; font-weight: 400; color: var(--ink-soft); letter-spacing: 0; }

/* ===== 世系树 ===== */
.tree-wrap { padding: 0 12px 10px; }
.gen-group {
  background: #FBF5E6; border: 1px solid var(--line); border-radius: 10px;
  margin-bottom: 12px; overflow: hidden;
}
.gen-group .gen-head {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; background: rgba(140,47,47,.08);
  border-bottom: 1px solid var(--line);
  cursor: pointer; min-height: 44px;
}
.gen-group .gen-head .gen-badge {
  background: var(--crimson); color: var(--paper); border-radius: 6px;
  font-size: .78rem; padding: 3px 8px; font-weight: 700; letter-spacing: 1px;
}
.gen-group .gen-head .gen-name { font-size: 1rem; font-weight: 700; letter-spacing: 1px; }
.gen-group .gen-head .gen-count { margin-left: auto; font-size: .78rem; color: var(--ink-soft); }
.gen-group .gen-head .arrow { color: var(--gold); font-size: .9rem; transition: transform .2s; }
.gen-group.open .gen-head .arrow { transform: rotate(180deg); }
.gen-body { padding: 10px 14px; display: none; }
.gen-group.open .gen-body { display: block; }
.member-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px;
  padding: 10px 12px; margin-bottom: 8px; min-height: 52px;
}
.member-card .m-avatar {
  width: 38px; height: 38px; flex-shrink: 0; border-radius: 50%;
  background: var(--gold); color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem; font-weight: 700; overflow: hidden;
}
.member-card.female .m-avatar { background: var(--crimson-light); color: var(--paper); }
.member-card .m-info { flex: 1; min-width: 0; }
.member-card .m-name { font-size: 1rem; font-weight: 700; letter-spacing: 1px; }
.member-card .m-name .alias { font-size: .78rem; color: var(--ink-soft); font-weight: 400; letter-spacing: 0; }
.member-card .m-sub { font-size: .78rem; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member-card .m-go { color: var(--gold); font-size: 1rem; }

/* ===== 人物详情 ===== */
.detail-wrap { padding: 16px 16px 10px; }
.detail-hero {
  background: linear-gradient(150deg, var(--crimson), var(--crimson-light));
  border-radius: 12px; color: var(--paper); padding: 22px 18px; text-align: center;
}
.detail-hero .d-gen { font-size: .8rem; color: var(--gold-light); letter-spacing: 2px; }
.detail-hero .d-name { font-size: 1.7rem; font-weight: 900; letter-spacing: 4px; margin-top: 4px; }
.detail-hero .d-alias { font-size: .9rem; color: var(--gold-light); margin-top: 2px; }
.detail-hero .d-life { font-size: .85rem; margin-top: 8px; opacity: .95; }
.detail-card {
  background: #FBF5E6; border: 1px solid var(--line); border-radius: 10px;
  margin-top: 14px; padding: 6px 0; overflow: hidden;
}
.detail-card .row {
  display: flex; padding: 12px 16px; border-bottom: 1px dashed var(--line); gap: 12px;
}
.detail-card .row:last-child { border-bottom: none; }
.detail-card .row .k {
  flex-shrink: 0; width: 72px; font-size: .85rem; color: var(--crimson); font-weight: 700; letter-spacing: 1px;
}
.detail-card .row .v { flex: 1; font-size: .9rem; word-break: break-all; }
.detail-card .row .v .empty { color: var(--line); }
.detail-children { margin-top: 14px; }
.detail-children .child-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 20px;
  padding: 6px 14px; margin: 0 8px 8px 0; font-size: .88rem;
}
.detail-children .child-chip .sex { font-size: .7rem; color: var(--gold); }

/* ===== 家族渊源 ===== */
.origin-wrap { padding: 16px 16px 10px; }
.origin-card {
  background: #FBF5E6; border: 1px solid var(--line); border-radius: 10px;
  padding: 18px 16px; margin-bottom: 14px;
}
.origin-card h3 { color: var(--crimson); font-size: 1.05rem; letter-spacing: 2px; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.origin-card h3::before { content: ""; width: 4px; height: 16px; background: var(--gold); border-radius: 2px; }
.origin-card p { font-size: .92rem; line-height: 2; text-align: justify; color: var(--ink); }
.origin-card .line-list { font-size: .92rem; line-height: 2; list-style: none; }
.origin-card .line-list li { padding-left: 18px; position: relative; }
.origin-card .line-list li::before { content: "◆"; position: absolute; left: 0; font-size: .7rem; color: var(--gold); }

/* ===== 原谱影集 ===== */
.gallery-wrap { padding: 16px; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.gallery-grid .g-item { position: relative; border-radius: 8px; overflow: hidden; background: #E4DCC8; aspect-ratio: 3 / 4; }
.gallery-grid .g-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-grid .g-item .g-num {
  position: absolute; left: 6px; bottom: 6px; background: rgba(59,50,38,.75); color: var(--paper);
  font-size: .7rem; padding: 2px 7px; border-radius: 4px; letter-spacing: 1px;
}
.gallery-hint { font-size: .8rem; color: var(--ink-soft); text-align: center; margin-top: 14px; }

/* ===== 图片查看器 ===== */
.viewer {
  position: fixed; inset: 0; z-index: 100; background: rgba(20,16,10,.96);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.viewer img { max-width: 100%; max-height: 78vh; object-fit: contain; }
.viewer .v-top { position: absolute; top: 0; left: 0; right: 0; display: flex; justify-content: space-between; padding: 14px 16px; color: var(--paper); font-size: .9rem; }
.viewer .v-close { font-size: 1.2rem; padding: 8px 14px; min-width: 44px; text-align: center; }
.viewer .v-count { background: rgba(245,239,224,.15); border-radius: 20px; padding: 4px 14px; }
.viewer .v-nav { position: absolute; bottom: 26px; left: 0; right: 0; display: flex; justify-content: center; gap: 18px; }
.viewer .v-nav button {
  background: var(--crimson); color: var(--paper); border: none; border-radius: 50%;
  width: 52px; height: 52px; font-size: 1.3rem; cursor: pointer;
}
.viewer .v-nav button:disabled { opacity: .4; }
.viewer .v-cap { position: absolute; bottom: 92px; color: var(--gold-light); font-size: .8rem; letter-spacing: 1px; }

/* ===== 提示条 ===== */
.notice {
  margin: 14px 16px 0; padding: 10px 14px; border-radius: 8px;
  background: rgba(201,162,39,.12); border: 1px solid var(--gold-light);
  font-size: .82rem; color: var(--ink-soft); text-align: center;
}

/* ===== 后台登录 ===== */
.login-page { max-width: 640px; margin: 0 auto; min-height: 100vh; display: flex; flex-direction: column; }
.login-box {
  margin: auto 20px; background: #FBF5E6; border: 1px solid var(--line); border-radius: 14px;
  padding: 34px 24px; box-shadow: 0 6px 20px rgba(59,50,38,.12);
}
.login-box .seal { width: 60px; height: 60px; margin: 0 auto 14px; border: 3px solid var(--crimson); border-radius: 8px; color: var(--crimson); display: flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 700; letter-spacing: 3px; }
.login-box h2 { text-align: center; color: var(--crimson); letter-spacing: 3px; font-size: 1.3rem; }
.login-box .hint { text-align: center; font-size: .8rem; color: var(--ink-soft); margin-top: 6px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: .85rem; color: var(--ink-soft); margin-bottom: 6px; letter-spacing: 1px; }
.field input, .field select, .field textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 8px;
  padding: 12px 14px; background: var(--paper); color: var(--ink); outline: none;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--gold); }
.field textarea { min-height: 84px; resize: vertical; line-height: 1.7; }
.btn {
  display: block; width: 100%; border: none; border-radius: 8px;
  background: var(--crimson); color: var(--paper);
  padding: 14px; font-size: 1rem; letter-spacing: 2px; cursor: pointer; min-height: 44px;
}
.btn.gold { background: var(--gold); color: var(--ink); }
.btn.ghost { background: transparent; border: 1px solid var(--crimson); color: var(--crimson); }
.btn.danger { background: var(--danger); }
.btn:disabled { opacity: .55; }
.msg { text-align: center; font-size: .85rem; margin-top: 10px; min-height: 20px; }
.msg.err { color: var(--danger); }
.msg.ok { color: var(--ok); }

/* ===== 后台管理 ===== */
.admin-nav {
  position: sticky; top: 0; z-index: 20; background: var(--ink); color: var(--paper);
  display: flex; overflow-x: auto; max-width: 640px; margin: 0 auto;
}
.admin-nav a { flex-shrink: 0; padding: 13px 16px; font-size: .88rem; letter-spacing: 1px; color: rgba(245,239,224,.8); border-bottom: 3px solid transparent; }
.admin-nav a.active { color: var(--gold-light); border-bottom-color: var(--gold); }
.admin-body { max-width: 640px; margin: 0 auto; padding: 16px; padding-bottom: 60px; }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 16px; }
.stat-card { background: #FBF5E6; border: 1px solid var(--line); border-radius: 10px; text-align: center; padding: 14px 8px; }
.stat-card .num { font-size: 1.6rem; font-weight: 900; color: var(--crimson); }
.stat-card .lab { font-size: .78rem; color: var(--ink-soft); margin-top: 2px; }
.toolbar { display: flex; gap: 10px; margin-bottom: 14px; }
.toolbar input { flex: 1; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; background: var(--paper); }
.toolbar select { border: 1px solid var(--line); border-radius: 8px; padding: 10px 8px; background: var(--paper); }
.list-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 14px; margin-bottom: 8px; display: flex; align-items: center; gap: 10px; min-height: 52px;
}
.list-card .lc-info { flex: 1; min-width: 0; }
.list-card .lc-name { font-weight: 700; font-size: .98rem; }
.list-card .lc-sub { font-size: .78rem; color: var(--ink-soft); }
.list-card .lc-actions { display: flex; gap: 6px; flex-shrink: 0; }
.mini-btn { border: 1px solid var(--line); background: var(--paper); border-radius: 6px; padding: 6px 10px; font-size: .8rem; color: var(--ink); min-width: 40px; text-align: center; }
.mini-btn.edit { border-color: var(--gold); color: var(--crimson); }
.mini-btn.del { border-color: var(--danger); color: var(--danger); }
.form-title { font-size: 1.1rem; color: var(--crimson); letter-spacing: 2px; margin-bottom: 14px; font-weight: 700; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.form-grid .field.full { grid-column: 1 / -1; }
.form-actions { display: flex; gap: 10px; margin-top: 8px; }
.back-link { display: inline-block; margin-bottom: 14px; color: var(--crimson); font-size: .9rem; }

/* ===== 弹窗 ===== */
.modal-mask { position: fixed; inset: 0; background: rgba(20,16,10,.55); z-index: 90; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal { background: var(--paper); border-radius: 12px; max-width: 440px; width: 100%; padding: 22px 20px; box-shadow: 0 10px 30px rgba(0,0,0,.3); }
.modal h3 { color: var(--crimson); margin-bottom: 12px; letter-spacing: 1px; }
.modal .modal-actions { display: flex; gap: 10px; margin-top: 16px; }

/* ===== 空状态与杂项 ===== */
.empty { text-align: center; color: var(--line); padding: 40px 0; font-size: .9rem; }
.spouse-card {
  background: #FBF5E6; border: 1px solid var(--line); border-radius: 10px;
  padding: 14px 16px; margin: 12px 0; display: flex; align-items: flex-start; gap: 12px;
}
.spouse-icon { font-size: 1.2rem; color: var(--gold); flex-shrink: 0; margin-top: 2px; }
.spouse-label { font-size: .75rem; color: var(--ink-soft); margin-bottom: 2px; }
.spouse-name { font-size: 1rem; font-weight: 700; color: var(--crimson); }
.spouse-note { font-size: .82rem; color: var(--ink-soft); margin-top: 4px; line-height: 1.6; }
.hl { color: var(--crimson); font-weight: 700; background: #f0e0d0; padding: 0 2px; border-radius: 2px; }

.spin { text-align: center; padding: 60px 0; color: var(--ink-soft); font-size: .9rem; }
.spin::before {
  content: '竺'; display: block; width: 60px; height: 60px; margin: 0 auto 12px;
  border: 3px solid var(--crimson); border-radius: 8px;
  color: var(--crimson); font-size: 1.5rem; font-weight: 900;
  display: flex; align-items: center; justify-content: center;
  animation: spin 1.5s ease-in-out infinite;
}
@keyframes spin {
  0%, 100% { transform: rotate(0deg); opacity: 1; }
  50% { transform: rotate(180deg); opacity: .6; }
}
.toast {
  position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 120;
  background: var(--ink); color: var(--paper); padding: 10px 22px; border-radius: 24px;
  font-size: .88rem; box-shadow: 0 4px 14px rgba(0,0,0,.3); max-width: 86vw; text-align: center;
}
.toast.ok { background: var(--ok); }
.toast.err { background: var(--danger); }

/* ===== 响应式 ===== */
@media (min-width: 640px) {
  body { background: #E4DCC8; }
  .page, .login-page, .admin-body, .bottom-nav, .admin-nav { border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
}

/* ===== 自动备份历史列表 ===== */
.ab-row {
  background: var(--paper); border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 14px; margin-bottom: 8px; display: flex; align-items: center; gap: 10px;
}
.ab-row .ab-info { flex: 1; min-width: 0; }
.ab-row .ab-label { font-weight: 600; font-size: .92rem; word-break: break-all; }
.ab-row .ab-meta { font-size: .78rem; color: var(--ink-soft); margin-top: 2px; }
.ab-row .mini-btn { flex-shrink: 0; }

/* ===== 首页搜索框 ===== */
.btn-toggle-tree {
  float: right; font-size: .78rem; padding: 4px 12px;
  border: 1px solid var(--line); border-radius: 14px; background: var(--paper);
  color: var(--crimson); cursor: pointer;
}
.home-stats {
  max-width: 420px; margin: 12px auto 0; text-align: center;
  font-size: .85rem; color: var(--ink-soft); letter-spacing: 1px;
}
.home-stats b { color: var(--crimson); font-size: 1rem; margin: 0 2px; }
.search-box { position: relative; max-width: 420px; margin: 14px auto 0; }
.search-box input {
  width: 100%; padding: 11px 14px; border: 1px solid var(--line);
  border-radius: 24px; background: var(--paper); font-size: .95rem; outline: none;
}
.search-box input:focus { border-color: var(--crimson); }
.search-results {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 30;
  background: var(--paper); border: 1px solid var(--line); border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0,0,0,.12); overflow: hidden; display: none;
}
.search-box input:focus ~ .search-results,
.search-box .search-results:not(:empty) { display: block; }
.sr-empty { padding: 12px 14px; font-size: .85rem; color: var(--ink-soft); }
.sr-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 14px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink);
}
.sr-item:last-child { border-bottom: none; }
.sr-item:active { background: rgba(140,47,47,.06); }
.sr-name { font-weight: 600; font-size: .95rem; }
.sr-gen { font-size: .78rem; color: var(--ink-soft); }

/* ===== 资料征集：模板展示框 ===== */
.tpl-box {
  background: #faf6ec; border: 1px dashed var(--line); border-radius: 8px;
  padding: 12px; font-family: monospace; font-size: .8rem; line-height: 1.7;
  white-space: pre-wrap; word-break: break-all; max-height: 280px; overflow-y: auto;
  margin: 8px 0 10px;
}
.tpl-copy { width: 100%; }

/* ===== 人物详情：上下翻页 ===== */
.pager { display: flex; justify-content: space-between; gap: 10px; margin: 18px 16px 24px; }
.pager-btn {
  flex: 1; text-align: center; padding: 10px; border-radius: 8px;
  background: var(--paper); border: 1px solid var(--line);
  color: var(--crimson); text-decoration: none; font-size: .9rem;
}
.pager-btn.disabled { color: var(--ink-soft); opacity: .5; }

/* ===== 树形图 ===== */
.tree-v { padding: 10px 12px 30px; }
.t-node { position: relative; margin-bottom: 2px; }
.t-node .member-card { margin-bottom: 4px; }
.t-children {
  border-left: 2px solid var(--line);
  margin-left: 14px;
  padding-left: 12px;
  position: relative;
}
.t-children.collapsed { display: none; }
.t-toggle {
  flex-shrink: 0; width: 24px; height: 24px; line-height: 22px; text-align: center;
  border-radius: 50%; border: 1px solid var(--line); font-size: .8rem; color: var(--crimson);
  background: var(--paper);
}

/* ===== 焦点人物模式 ===== */
.focus-tree { padding: 16px 14px 30px; }
.tree-back { margin-bottom: 12px; }
.tree-back a { color: var(--crimson); text-decoration: none; font-size: .9rem; }
.ancestor-chain {
  text-align: center; font-size: .85rem; color: var(--ink-soft); margin-bottom: 16px;
}
.ancestor-chain .ancestor-label { letter-spacing: 4px; color: var(--crimson); font-weight: 700; }
.ancestor-chain a { color: var(--crimson); text-decoration: none; }
.ancestor-sep { margin: 0 6px; color: var(--line); }
.focus-card {
  background: var(--paper); border: 2px solid var(--crimson); border-radius: 14px;
  padding: 20px 16px; text-align: center; margin-bottom: 20px;
}
.focus-card.female { border-color: var(--gold); }
.fc-avatar {
  width: 64px; height: 64px; border-radius: 50%; background: var(--crimson);
  color: var(--paper); font-size: 1.6rem; font-weight: 700; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 10px;
}
.focus-card.female .fc-avatar { background: var(--gold); }
.fc-name { font-size: 1.4rem; font-weight: 900; color: var(--crimson); letter-spacing: 2px; }
.fc-gen { font-size: .85rem; color: var(--ink-soft); margin-top: 4px; }
.fc-life { font-size: .85rem; color: var(--ink-soft); margin-top: 6px; }
.fc-spouse { font-size: .85rem; color: var(--ink-soft); margin-top: 4px; }
.fc-detail { display: inline-block; margin-top: 12px; font-size: .85rem; color: var(--crimson); border-bottom: 1px dashed var(--line); text-decoration: none; }
.kids-title { font-size: .95rem; font-weight: 700; color: var(--crimson); margin-bottom: 10px; }
.kids-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kid-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 10px;
  padding: 12px 8px; text-align: center; text-decoration: none; color: var(--ink);
}
.kid-card.female { border-color: var(--gold); }
.kc-avatar {
  width: 40px; height: 40px; border-radius: 50%; background: var(--crimson);
  color: var(--paper); font-size: 1rem; font-weight: 700; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 6px;
}
.kid-card.female .kc-avatar { background: var(--gold); }
.kc-name { font-weight: 700; font-size: .95rem; }
.kc-gen { font-size: .75rem; color: var(--ink-soft); margin-top: 2px; }
