:root {
  --red: #d9302a;
  --red-dark: #b01f1a;
  --red-soft: #fff1ef;
  --orange-1: #ffe7ce;
  --orange-2: #ffd3a8;
  --brown: #8a4b12;
  --ink: #1f2329;
  --ink-2: #5c636e;
  --ink-3: #8a9099;
  --line: #eff1f4;
  --bg: #f6f7f9;
  --card: #ffffff;
  --ok: #17a673;
  --warn: #e8a33d;
  --info: #2b6cd4;
  --gold: #c9a227;
  --r: 12px;
  --shadow: 0 4px 16px rgba(20, 24, 31, 0.06);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
/* 关键：类选择器里�?display 会压过浏览器默认�?[hidden]{display:none}，必须显式兜�?*/
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--ink); }
body {
  font-family: "PingFang SC", "Microsoft YaHei", "Source Han Sans SC", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }

#app { max-width: 520px; margin: 0 auto; min-height: 100vh; background: var(--bg); position: relative; }
.view { padding-bottom: 96px; }

/* ---------- 头部 ---------- */
.hero {
  background: linear-gradient(180deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff;
  padding: 18px 16px 56px;
  border-radius: 0 0 22px 22px;
  position: relative;
}
.hero.compact { padding-bottom: 20px; }
.hero-top { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  display: grid; place-items: center; font-weight: 700; font-size: 16px;
  border: 1px solid rgba(255, 255, 255, 0.35);
}
.hero-name { font-size: 18px; font-weight: 700; line-height: 1.2; }
/* 页面标题统一带品牌：鸽源ERP · 种鸽库（首页/我的 是个人信息页，不套这条）
   字号、字重、颜色都跟标题一致，整行读起来是「鸽源ERP · 页面名」 */
.hero.compact .hero-name::before {
  content: "鸽源ERP · ";
}
/* 「我的赛事」那张大卡片用的是自己的标题类 */
.rc-hero-title::before {
  content: "鸽源ERP · ";
}
/* 首页 / 我的：昵称右边跟一行品牌小字 */
.hero-brand {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.5px;
  opacity: 0.78;
  margin-left: 7px;
  vertical-align: 2px;
  white-space: nowrap;
}
.hero-sub { font-size: 12px; opacity: 0.86; margin-top: 2px; }
.hero-actions { margin-left: auto; display: flex; gap: 8px; }
.icon-btn {
  width: 40px; height: 40px; border-radius: 12px; border: 0;
  background: rgba(255, 255, 255, 0.16); color: #fff;
  display: grid; place-items: center; font-size: 18px;
}
.loft-switch { display: flex; align-items: center; gap: 6px; margin-top: 14px; font-size: 15px; }
.loft-switch .chev { opacity: 0.8; font-size: 12px; }

/* ---------- 统计卡：一整条白卡 + 列间细线，当前项浅红底（照「我的赛事」统计带） ---------- */
.stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
  margin: -40px 16px 0; padding: 12px 6px;
  background: #fff; border-radius: 16px;
  box-shadow: 0 6px 18px rgba(16, 18, 22, 0.08);
  position: relative; z-index: 2;
}
.stat {
  position: relative;
  padding: 6px 4px;
  background: none; border: 0; border-radius: 12px;
  text-align: center; color: #241b18;
}
.stat + .stat::before {
  content: '';
  position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 1px; height: 26px; background: #eef0f3;
}
.stat .num { font-size: 26px; font-weight: 800; letter-spacing: 0.5px; color: #1f2329; }
.stat .label { margin-top: 2px; font-size: 13px; opacity: 0.85; color: #4b5563; }

/* ---------- 通用区块 ---------- */
.section { padding: 16px; }
.section-title { font-size: 15px; font-weight: 700; margin: 4px 0 10px; display: flex; align-items: center; gap: 6px; }
.section-title .more { margin-left: auto; font-size: 13px; color: var(--ink-3); font-weight: 400; }
.card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.card + .card { margin-top: 12px; }
.divider { height: 1px; background: var(--line); margin: 0 16px; }

/* ---------- 快捷入口 ---------- */
.quick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.quick-item {
  background: var(--card); border-radius: var(--r); padding: 14px;
  display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow);
  border: 0; text-align: left; width: 100%;
}
.quick-item .qi { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; }
.quick-item .qt { font-weight: 600; font-size: 15px; }
.quick-item .qs { font-size: 12px; color: var(--ink-3); }

/* ---------- 列表 ---------- */
.list { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.row {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px;
  border-bottom: 1px solid var(--line); background: none; border-left: 0; border-right: 0; border-top: 0;
  width: 100%; text-align: left;
}
.row:last-child { border-bottom: 0; }
.row:active { background: #fafbfc; }
.row .thumb {
  width: 52px; height: 52px; border-radius: 10px; flex: 0 0 auto;
  background: linear-gradient(135deg, #ffe9e7, #ffd7d2); display: grid; place-items: center;
  color: var(--red); font-weight: 700; font-size: 13px; overflow: hidden;
}
.row .thumb img { width: 100%; height: 100%; object-fit: cover; }
.row .main { flex: 1; min-width: 0; }
.pigeon-row { cursor: pointer; }
.pigeon-row .title { font-size: 17px; font-weight: 750; letter-spacing: 0.2px; }
.pigeon-row .sub { font-size: 14px; color: var(--ink-2); }
.row-tags { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.lineage { font-size: 12px; color: var(--ink-3); margin-top: 4px; line-height: 1.4; }
.row-side { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.sex-badge { font-size: 13px; font-weight: 700; line-height: 1.2; white-space: nowrap; }
.sex-badge.cock { color: #2B6CD4; }
.sex-badge.hen { color: #D9302A; }
.sex-badge.unknown { color: #8A9099; }
.row-actions { display: flex; gap: 6px; }
.act-btn.transfer { color: var(--red); border-color: rgba(217, 48, 42, 0.22); background: #fff7f5; font-weight: 650; }
.act-btn {
  min-width: 66px; padding: 7px 12px; border-radius: 10px; border: 1px solid var(--line);
  background: #fff; font-size: 13px; font-weight: 650; color: var(--ink-2);
}
.act-btn:active { background: #f2f4f7; }
.sheet-actions { display: flex; flex-direction: column; gap: 10px; }
.action-item {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line); background: #fff;
  font-size: 15px; font-weight: 600; color: var(--ink);
}
.action-item span { font-size: 17px; }
.ai-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ai-title { font-size: 15px; font-weight: 600; }
.ai-desc { font-size: 11.5px; font-weight: 400; color: var(--ink-3); line-height: 1.35; }
.action-item.danger .ai-desc { color: #c0574f; }
.action-item.danger { color: var(--red); border-color: #f6d6d3; background: #fffafa; }
.row .title { font-size: 16px; font-weight: 650; letter-spacing: 0.3px; }
.row .sub { font-size: 13px; color: var(--ink-3); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* 子代赛绩可能有 4~6 条：允许换行显示全，不再截成一行省略号 */
.row .sub.sub-races { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.45; word-break: break-word; }
.row .tail { color: var(--ink-3); font-size: 13px; text-align: right; }
/* 鸽子详情：配对中 / 子代列表更扁 */
.compact-list .row { padding: 10px 14px; gap: 8px; }
.compact-list .row .title { font-size: 15px; }
.compact-list .row .sub { margin-top: 1px; font-size: 12px; }

/* ---------- 徽标 ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; padding: 2px 8px; border-radius: 999px;
  background: var(--red-soft); color: var(--red); font-weight: 600;
}
.badge.green { background: #e8f7f0; color: var(--ok); }
.badge.orange { background: #fdf1de; color: #b97614; }
.badge.blue { background: #e9f0fd; color: var(--info); }
.badge.gray { background: #f1f3f5; color: var(--ink-3); }
.badge.gold { background: #faf3d8; color: #8a6d0b; }
.badge.dark { background: #eef0f3; color: var(--ink-2); }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 48px; padding: 0 20px; border-radius: 999px; border: 0;
  font-size: 17px; font-weight: 650; width: 100%;
}
.btn-primary { background: linear-gradient(180deg, var(--red), var(--red-dark)); color: #fff; box-shadow: 0 8px 20px rgba(217, 48, 42, 0.28); }
.btn-ghost { background: #fff; color: var(--red); border: 1.5px solid var(--red); }
.btn-plain { background: #f1f3f5; color: var(--ink-2); }
.btn-danger { background: #fff; color: var(--red); border: 1.5px solid #f3c9c6; }
.btn[disabled] { opacity: 0.5; }
.btn-sm { height: 36px; font-size: 14px; padding: 0 14px; width: auto; }
.btn-row { display: flex; gap: 10px; }

.fab {
  position: fixed; right: max(18px, calc(50% - 260px + 18px)); bottom: calc(84px + var(--safe-bottom));
  width: 56px; height: 56px; border-radius: 50%; border: 0; color: #fff; font-size: 26px;
  background: linear-gradient(180deg, var(--red), var(--red-dark));
  box-shadow: 0 10px 24px rgba(217, 48, 42, 0.35); z-index: 20;
}

/* ---------- 表单 ---------- */
.form { padding: 16px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 14px; color: var(--ink-2); margin-bottom: 6px; font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; height: 48px; border-radius: 10px; border: 1px solid #e3e7ec;
  padding: 0 14px; background: #fff; outline: none; font-size: 16px;
}
.field textarea { height: 96px; padding: 12px 14px; resize: none; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--red); }
.field .hint { font-size: 12px; color: var(--ink-3); margin-top: 4px; }
.field .err { font-size: 12px; color: var(--red); margin-top: 4px; }
/* 两个短字段并排一行（如 羽色 + 眼砂） */
.field-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
.field-pair > .field { margin-bottom: 0; min-width: 0; }
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg button {
  flex: 1; min-width: 76px; height: 48px; border-radius: 10px; border: 1px solid #e3e7ec;
  background: #fff; font-weight: 600; color: var(--ink-2);
}
.seg button.on { border-color: var(--red); color: var(--red); background: var(--red-soft); }

/* ---------- 环号分段输入 ---------- */
.combo { position: relative; }
.combo input { padding-right: 30px; }
.combo-chev {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  color: var(--ink-3); font-size: 12px; pointer-events: none;
}
.combo-panel {
  position: absolute; z-index: 40; left: 0; right: 0; top: calc(100% + 4px);
  max-height: 240px; overflow: auto; background: #fff; border-radius: 12px;
  border: 1px solid var(--line); box-shadow: 0 12px 30px rgba(20, 24, 31, 0.12);
  padding: 6px;
}
.combo-item {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 10px 12px; border: 0; border-radius: 9px; background: none; font-size: 14px;
}
.combo-item:active { background: #f6f8fb; }
.combo-item.on { background: var(--red-soft); color: var(--red); font-weight: 650; }
.combo-item .ci-code { font-weight: 700; font-variant-numeric: tabular-nums; }
.combo-item .ci-name { color: var(--ink-2); }
.ring-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ring-grid input { height: 48px; border-radius: 10px; border: 1px solid #e3e7ec; padding: 0 12px; background: #fff; font-size: 16px; }
.ring-grid input:focus { border-color: var(--red); outline: none; }

/* ---------- 图片上传 ---------- */
.photo-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.photo-slot { display: flex; flex-direction: column; gap: 6px; }
.photo-slot-label { font-size: 12.5px; color: var(--ink-2); font-weight: 650; display: flex; align-items: center; gap: 6px; }
.photo-slot-tip { font-size: 11px; color: var(--ink-3); font-weight: 400; }
.photo-slot-body { aspect-ratio: 1 / 1; border-radius: 12px; overflow: hidden; position: relative; }
.photo-slot-body .photo-cell { width: 100%; height: 100%; }
.photo-slot-body .photo-add { width: 100%; height: 100%; border-radius: 12px; }
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.photo-cell, .photo-add {
  position: relative; aspect-ratio: 1 / 1; border-radius: 10px; overflow: hidden;
}
.photo-cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-cell .photo-del {
  position: absolute; right: 4px; top: 4px; width: 24px; height: 24px; border-radius: 50%;
  border: 0; background: rgba(0, 0, 0, 0.55); color: #fff; font-size: 15px; line-height: 1;
}
.photo-cell .photo-tag {
  position: absolute; left: 4px; bottom: 4px; background: rgba(217, 48, 42, 0.9); color: #fff;
  font-size: 10px; padding: 1px 6px; border-radius: 6px;
}
.photo-add {
  border: 1px dashed #d5dae1; background: #fafbfc; color: #9aa0a8;
  display: grid; place-items: center; align-content: center; gap: 2px;
}

/* ---------- 血统书模板 ---------- */
.tpl-row { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; }
.tpl-card {
  flex: 0 0 132px; background: #fff; border: 1.5px solid var(--line); border-radius: 12px;
  padding: 10px; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; box-shadow: var(--shadow);
}
.tpl-card.on { border-color: var(--red); box-shadow: 0 6px 18px rgba(217, 48, 42, 0.18); }
.tpl-swatch { width: 46px; height: 22px; border-radius: 5px; border: 1px solid; display: block; }
.tpl-name { width: 100%; font-size: 13px; font-weight: 650; color: var(--ink-2); margin-top: 4px; }
.tpl-card.on .tpl-name { color: var(--red); }

.cert-toolbar { display: flex; gap: 8px; padding: 10px 16px 0; overflow-x: auto; }
.cert-wrap { padding: 12px 16px; }
.cert-img { width: 100%; display: block; border-radius: 8px; box-shadow: 0 10px 30px rgba(20, 24, 31, 0.12); background: #fff; }
.cert-stage { position: relative; }
.cert-stage > svg { width: 100%; height: auto; display: block; border-radius: 8px; background: #fff; }
.cert-hot { position: absolute; padding: 0; border: 1px solid transparent; background: transparent; border-radius: 4px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.cert-hot:active { background: rgba(217, 48, 42, 0.12); border-color: rgba(217, 48, 42, 0.45); }

/* ---------- 血统书大图预览（保存图片用） ---------- */
.cert-viewer { position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column; background: rgba(17, 20, 25, 0.95); }
.cert-viewer-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; color: #fff; font-size: 15px; }
.cert-viewer-bar span { opacity: 0.8; }
.cert-viewer-close { flex: none; border: 1px solid rgba(255, 255, 255, 0.5); background: rgba(255, 255, 255, 0.12); color: #fff; border-radius: 20px; padding: 9px 22px; font-size: 15px; font-weight: 600; }
.cert-viewer-stage { flex: 1; overflow: auto; padding: 0 12px 16px; -webkit-overflow-scrolling: touch; }
.cert-viewer-stage img { display: block; width: 100%; height: auto; border-radius: 6px; background: #fff; }

/* ---------- 血统书 A4 预览（打印 / 存图） ---------- */
.cert-print-view { position: fixed; inset: 0; z-index: 70; display: flex; flex-direction: column; background: #E9EBEF; }
.cert-print-bar { display: flex; gap: 8px; padding: 10px 12px; background: #1F2329; }
.cp-btn { flex: 1; height: 62px; border: 0; border-radius: 12px; background: rgba(255, 255, 255, 0.16); color: #fff; font-size: 12.5px; font-weight: 600; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; -webkit-tap-highlight-color: transparent; }
.cp-btn svg { width: 24px; height: 24px; }
.cp-btn:active { transform: scale(0.97); }
.cp-btn.primary { background: #C0272D; }
.cp-btn.ghost { flex: 0 0 86px; background: rgba(255, 255, 255, 0.24); }
.cert-print-stage { flex: 1; overflow: auto; padding: 12px; -webkit-overflow-scrolling: touch; }
.cert-print-stage svg { width: 100%; height: auto; display: block; background: #fff; border-radius: 8px; box-shadow: 0 8px 24px rgba(20, 24, 31, 0.12); }

/* 打印时只出 A4 那一张（仅当证书层打开时） */
@media print {
  @page { size: A4 portrait; margin: 0; }
  html, body { margin: 0 !important; padding: 0 !important; background: #fff !important; }
  body.cert-printing > *:not(#certPrint) { display: none !important; }
  #certPrint { position: static !important; display: block !important; background: #fff !important; }
  #certPrint .cert-print-bar { display: none !important; }
  #certPrint .cert-print-stage { padding: 0 !important; overflow: visible !important; }
  #certPrint svg { width: 210mm !important; height: 297mm !important; border-radius: 0 !important; box-shadow: none !important; }
}

.swatches { display: flex; gap: 10px; }
.swatch { width: 34px; height: 34px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.swatch.on { box-shadow: 0 0 0 2px var(--red); }

/* ---------- Tab �?---------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  max-width: 520px; margin: 0 auto;
  background: #fff; border-top: 1px solid var(--line);
  display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  padding: 6px 0 calc(6px + var(--safe-bottom));
}
.tabbar button {
  background: none; border: 0; display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: 12px; color: #9aa0a8; padding: 4px 0;
}
.tabbar button.on { color: var(--red); font-weight: 700; }
.tabbar svg { width: 24px; height: 24px; }
.tabbar .dot { width: 4px; height: 4px; border-radius: 50%; background: transparent; }
.tabbar button.on .dot { background: var(--red); }

/* ---------- 弹层 ---------- */
.toast {
  position: fixed; left: 50%; bottom: 110px; transform: translateX(-50%);
  background: rgba(31, 35, 41, 0.92); color: #fff; padding: 10px 18px;
  border-radius: 999px; font-size: 14px; z-index: 10050; max-width: 80%;
}
.overlay { position: fixed; inset: 0; background: rgba(16, 18, 22, 0.45); z-index: 50; overscroll-behavior: contain; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 55;
  max-width: 520px; margin: 0 auto; background: #fff; border-radius: 18px 18px 0 0;
  padding: 18px 16px calc(18px + var(--safe-bottom)); max-height: 82vh; overflow: auto;
  overscroll-behavior: contain;
}
.sheet h3 { margin: 0 0 12px; font-size: 17px; }
.sheet .close { position: absolute; right: 14px; top: 12px; background: none; border: 0; font-size: 20px; color: var(--ink-3); }

/* ---------- 空状�?---------- */
.empty { text-align: center; padding: 44px 20px; color: var(--ink-3); }
.empty .big { font-size: 40px; margin-bottom: 8px; }
.empty p { margin: 6px 0 16px; font-size: 14px; }

/* ---------- 搜索 ---------- */
.searchbar { display: flex; gap: 8px; align-items: center; padding: 10px 16px; background: #fff; }
.picker {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; font-size: 15px; color: var(--ink-3); text-align: left;
}
.picker::after { content: '›'; color: var(--ink-3); font-size: 13px; line-height: 1; }
.picker.on { color: var(--ink); font-weight: 650; }
.picker:disabled { background: #f6f7f9; color: var(--ink-3); }
/* ---------- 鸽子名行 + 血统书预览 ---------- */
.name-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.name-row-main { display: flex; align-items: center; gap: 10px; min-width: 0; }
.pigeon-name {
  font-size: 22px; font-weight: 800; letter-spacing: 0.5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 52vw;
}
.cert-preview-btn {
  margin-left: auto; display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px; border: 1px solid rgba(217, 48, 42, 0.22);
  background: linear-gradient(135deg, #fff3f1 0%, #ffe4df 100%);
  color: var(--red); font-size: 13px; font-weight: 700; white-space: nowrap;
  box-shadow: 0 2px 8px rgba(217, 48, 42, 0.10);
}
.cert-preview-btn:active { transform: translateY(1px); }
.cert-preview-btn .cpb-ico { font-size: 14px; }

.cert-modal { position: fixed; inset: 0; z-index: 90; display: flex; flex-direction: column; background: rgba(16, 18, 22, 0.72); }
.cert-modal-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px calc(10px); color: #fff; font-size: 15px; font-weight: 650;
}
.cert-modal-x { border: 0; background: rgba(255, 255, 255, 0.16); color: #fff; width: 30px; height: 30px; border-radius: 50%; font-size: 17px; line-height: 1; }
.cert-modal-save {
  border: 0; border-radius: 999px; padding: 0 14px; height: 32px;
  background: #fff; color: #b01f1a; font-size: 13.5px; font-weight: 700;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
}
.cert-modal-save:disabled { opacity: 0.55; }
.cert-modal-body { flex: 1; overflow: auto; padding: 0 16px 12px; -webkit-overflow-scrolling: touch; }
.cert-modal-img { width: 100%; display: block; border-radius: 8px; background: #fff; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35); }
.cert-modal-img > svg { width: 100%; height: auto; display: block; border-radius: 8px; background: #fff; }
.cert-modal-loading { display: grid; place-items: center; color: #fff; padding: 60px 0; }
.cert-modal-err { color: #fff; text-align: center; padding: 40px 0; font-size: 14px; }
.cert-modal-foot { display: flex; gap: 10px; padding: 12px 16px calc(14px + var(--safe-bottom)); background: #fff; border-radius: 16px 16px 0 0; }
.cert-modal-foot .btn { flex: 1; }

.scope-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 6px 16px 12px; }
.scope-tab {
  height: 46px; border-radius: 13px; border: 1px solid var(--line); background: #fff;
  font-size: 15.5px; font-weight: 700; color: var(--ink-2);
  box-shadow: 0 2px 8px rgba(20, 24, 31, 0.04);
  transition: background .18s, color .18s, box-shadow .18s;
}
.scope-tab.on {
  color: #fff; border-color: transparent;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  box-shadow: 0 8px 20px rgba(217, 48, 42, 0.22);
}
.pair-toolbar { padding: 14px 16px 0; }
.pair-list { display: flex; flex-direction: column; gap: 12px; }
.pair-card {
  display: block; width: 100%; text-align: left; background: #fff;
  border: 1px solid #f1f3f6; border-radius: 16px; padding: 14px 16px 12px;
  box-shadow: 0 6px 20px rgba(20, 24, 31, 0.05);
  transition: box-shadow .18s, transform .12s;
}
.pair-card:active { background: #fafbfc; }
.pair-birds { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 2px 0 8px; }
.bird-cell { display: flex; align-items: center; gap: 6px; min-width: 0; }
.bird-thumb-sm {
  position: relative; width: 30px; height: 30px; border-radius: 10px; flex: 0 0 auto;
  background: #f4f6f8; display: grid; place-items: center;
  color: var(--ink-3); font-size: 12px; font-weight: 700;
  box-shadow: 0 0 0 1px #e9edf2;
}
.bird-thumb-sm img { border-radius: inherit; }
.sex-dot {
  position: absolute; right: -3px; bottom: -3px;
  width: 15px; height: 15px; border-radius: 50%; background: #fff;
  display: grid; place-items: center; font-size: 9px; line-height: 1; font-weight: 800;
  box-shadow: 0 0 0 1px var(--line);
}
.sex-dot.cock { color: #2B6CD4; }
.sex-dot.hen { color: #D9302A; }
.sex-dot.unknown { color: var(--ink-3); }
.bird-thumb-sm img { width: 100%; height: 100%; object-fit: cover; }
.bird-main { min-width: 0; flex: 1; }
.bird-ring {
  font-size: 10.5px; font-weight: 750; letter-spacing: -0.1px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.bird-name { font-size: 11px; color: var(--ink-3); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bird-ring.hot { color: var(--red); }
.bird-sex { font-size: 12px; font-weight: 700; }
.bird-sex.cock { color: #2B6CD4; }
.bird-sex.hen { color: #D9302A; }
.bird-sex.unknown { color: var(--ink-3); }
.pair-foot { display: flex; align-items: center; gap: 8px; padding-top: 10px; margin-top: 4px; border-top: 1px solid var(--line); }
.pair-date { font-size: 12px; color: var(--ink-3); }
.pair-arrow { margin-left: auto; color: #c3c9d2; font-size: 16px; }
.pair-stats { display: flex; gap: 6px; padding-top: 8px; flex-wrap: wrap; }
.egg-actions { display: flex; gap: 6px; flex: 0 0 auto; }
.act-btn.danger { color: var(--red); border-color: #f6d6d3; background: #fffafa; }
.egg-op-row { display: flex; align-items: flex-start; gap: 10px; padding: 12px 0; border-bottom: 1px dashed #f0f2f5; }
.egg-op-label { width: 60px; flex: 0 0 auto; font-size: 14px; font-weight: 700; padding-top: 8px; }
.egg-op-form { flex: 1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.egg-op-form input {
  flex: 1; min-width: 120px; height: 38px; border-radius: 10px;
  border: 1px solid var(--line); padding: 0 12px; font-size: 14px; background: #fff;
}
.egg-op-state { font-size: 13px; color: var(--ink-3); }
.clutch-card { padding: 12px 14px; margin-bottom: 10px; }
.clutch-head { display: flex; align-items: baseline; gap: 8px; padding-bottom: 8px; }
.clutch-no { font-size: 14px; font-weight: 750; }
.clutch-meta { font-size: 12px; color: var(--ink-3); }
.egg-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px dashed #f0f2f5; }
.egg-main { flex: 1; min-width: 0; }
.egg-title { font-size: 13px; font-weight: 650; }
.egg-chips { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 5px; }
.stat-chip {
  font-size: 11.5px; font-weight: 650; padding: 3px 8px; border-radius: 7px;
  background: #f3f6fb; color: #5a6b85;
}
.stat-chip.clutch { background: #eaf1fd; color: #2b6cd4; }
.stat-chip.egg { background: #fdf3e0; color: #a4701a; }
.stat-chip.hatch { background: #f0eafc; color: #6b46c1; }
.stat-chip.band { background: #e9f7f0; color: #1a7f5a; }
.stat-chip.ok { background: #e9f7f0; color: #1a7f5a; }
.stat-chip.muted { background: #f4f5f7; color: #98a1ad; }
.stat-chip.warn { background: #fdeee2; color: #b4691a; }
.home-search {
  display: flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 5px 5px 5px 14px; box-shadow: var(--shadow);
  transition: border-color .15s, box-shadow .15s;
}
.home-search:focus-within { border-color: var(--red); box-shadow: 0 6px 18px rgba(217, 48, 42, 0.14); }
.home-search .hs-icon { font-size: 21px; color: var(--ink-3); line-height: 1; margin-top: -1px; }
.home-search input {
  flex: 1; min-width: 0; height: 40px; border: 0; outline: none; background: none;
  font-size: 16px; color: var(--ink);
  pointer-events: auto; user-select: text; -webkit-user-select: text;
}
.home-search input::placeholder { color: #b9bfc8; }
.home-search .hs-btn {
  flex: 0 0 auto; height: 38px; padding: 0 18px; border: 0; border-radius: 10px;
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff; font-size: 14px; font-weight: 700; letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(217, 48, 42, 0.25);
}
.home-search .hs-btn:active { transform: translateY(1px); box-shadow: 0 2px 8px rgba(217, 48, 42, 0.2); }
.searchbar input { flex: 1; height: 42px; border-radius: 999px; border: 0; background: #f1f3f5; padding: 0 16px; outline: none; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 9px 16px 3px; }
.chips-sep { flex: 0 0 auto; align-self: center; width: 1px; height: 16px; background: var(--line); margin: 0 1px; }
.chip { flex: 0 0 auto; padding: 5px 11px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-size: 13px; line-height: 1.5; color: var(--ink-2); }
.chip.on { background: var(--red-soft); border-color: var(--red); color: var(--red); font-weight: 600; }

/* ---------- 详情 ---------- */
/* 封面：完整显示不裁切，最�?70vh；多张时横向滑动 */
.cover { width: 100%; height: auto; min-height: 180px; max-height: 70vh; background: #eef0f3; object-fit: contain; display: block; }
/* 封面横向滑动看多张：原生滚动 + scroll-snap */
.cover-track { display: flex; width: 100%; overflow-x: auto; scroll-snap-type: x mandatory; background: #eef0f3; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.cover-track::-webkit-scrollbar { display: none; }
.cover-track .cover { flex: 0 0 100%; scroll-snap-align: center; }
.cover-dots { position: absolute; right: 14px; bottom: 14px; display: flex; gap: 5px; }
.cover-dots span { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, 0.55); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25); }
.cover-dots span.on { background: #fff; width: 16px; border-radius: 3px; }
.cover-wrap { position: relative; }
.cover-wrap .ring {
  position: absolute; left: 14px; bottom: 12px; color: #fff; font-size: 26px; font-weight: 800;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45); letter-spacing: 0.5px;
}
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 12px; padding: 14px 16px; }
.kv .k { font-size: 12px; color: var(--ink-3); }
.kv .v { font-size: 15px; font-weight: 600; margin-bottom: 10px; }
/* 鸽子详情资料：标签和值同一行，压扁高度 */
.kv-flat { padding: 5px 14px 7px; }
.kv-row { display: flex; align-items: stretch; }
.kv-row + .kv-row { border-top: 1px solid #f6f7f9; }
.kv-cell { flex: 1 1 0; min-width: 0; display: flex; align-items: baseline; gap: 4px; padding: 9px 0; }
.kv-cell + .kv-cell { margin-left: 14px; }
.kv-row-parents .kv-cell + .kv-cell { margin-left: 20px; }
.kv-flat .k { flex: 0 0 26px; font-size: 11px; line-height: 1.5; white-space: nowrap; color: var(--ink-3); }
.kv-flat .v { flex: 1 1 auto; min-width: 0; font-size: 12.5px; line-height: 1.5; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kv-flat .v a.rel-link { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.actionbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; max-width: 520px; margin: 0 auto;
  background: #fff; border-top: 1px solid var(--line); display: flex; gap: 10px;
  padding: 10px 16px calc(10px + var(--safe-bottom));
}
.actionbar .btn { height: 46px; font-size: 16px; }

/* ---------- 族谱 ---------- */
.pedigree { padding: 12px 16px 24px; overflow-x: auto; }
.gen-row { display: flex; gap: 8px; align-items: stretch; margin-bottom: 8px; }
.gen-label { flex: 0 0 34px; font-size: 11px; color: var(--ink-3); display: grid; place-items: center; }
.pnode {
  flex: 1 1 0; min-width: 0; background: #fff; border-radius: 10px; padding: 8px 10px;
  border: 1px solid var(--line); box-shadow: var(--shadow);
}
.pnode .pr { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pnode .ps { font-size: 11px; color: var(--ink-3); }
.pnode.unknown { background: #fafbfc; border-style: dashed; color: var(--ink-3); }
button.pnode { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; font: inherit; text-align: left; cursor: pointer; }\nbutton.pnode:active { background: #f2f4f7; }\n.pnode.me { border-color: var(--red); background: var(--red-soft); }

/* ---------- 时间�?---------- */
.timeline { padding: 8px 16px 20px; }
.tl-item { display: flex; gap: 12px; padding: 10px 0; }
.tl-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--red); margin-top: 6px; flex: 0 0 auto; }
.tl-dot.gray { background: #c9ced6; }
.tl-body .t { font-size: 15px; font-weight: 600; }
.tl-body .d { font-size: 12px; color: var(--ink-3); }

/* ---------- 登录 ---------- */
.auth { min-height: 100vh; background: linear-gradient(180deg, var(--red), var(--red-dark)); color: #fff; display: flex; flex-direction: column; justify-content: center; padding: 32px 24px calc(32px + var(--safe-bottom)); }
.auth h1 { font-size: 30px; margin: 0 0 6px; letter-spacing: 1px; }
.auth p { opacity: 0.9; margin: 0 0 28px; font-size: 15px; }
.auth .panel { background: #fff; border-radius: 18px; padding: 20px; color: var(--ink); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2); }
.auth .code-row { display: flex; gap: 10px; }
.auth .code-row input { flex: 1; }
.auth .code-row button { flex: 0 0 116px; height: 48px; border-radius: 10px; border: 1px solid var(--red); background: #fff; color: var(--red); font-weight: 600; }
.auth .agree-line { display: flex; gap: 8px; align-items: flex-start; margin: 14px 2px 0; font-size: 12.5px; line-height: 1.6; color: var(--ink-3); }
.auth .agree-line input { flex: none; width: 16px; height: 16px; margin: 2px 0 0; accent-color: var(--red); }
.auth .agree-line a { color: var(--red); text-decoration: none; }
.auth-foot { margin-top: 18px; text-align: center; font-size: 12px; line-height: 1.9; color: rgba(255, 255, 255, 0.72); }
.auth-foot a { text-decoration: none; }

/* ---------- 用户协议 / 隐私政策 ---------- */
.legal-page { min-height: 100vh; background: #fff; padding-bottom: calc(24px + var(--safe-bottom)); }
.legal-top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: #fff; border-bottom: 1px solid var(--line); font-size: 15px; font-weight: 600; color: var(--ink); }
.legal-top .icon-btn { width: 34px; height: 34px; border-radius: 50%; }
.legal-body { padding: 18px 18px 8px; color: var(--ink-2); font-size: 14px; line-height: 1.85; }
.legal-body h1 { font-size: 20px; color: var(--ink); margin: 0 0 4px; }
.legal-body .legal-meta { font-size: 12px; color: var(--ink-3); margin: 0 0 16px; }
.legal-body h2 { font-size: 15px; color: var(--ink); margin: 20px 0 6px; }
.legal-body p { margin: 6px 0; }
.legal-body ul { margin: 6px 0; padding-left: 20px; }
.legal-body li { margin: 4px 0; }
.legal-body b { color: var(--ink); }
.legal-foot { margin: 18px; padding: 12px 14px; border-radius: 12px; background: #f7f8fa; color: var(--ink-3); font-size: 12px; line-height: 1.6; }

/* ---------- 海报 ---------- */
.poster-wrap { padding: 16px; }
.poster-wrap img { width: 100%; border-radius: 12px; box-shadow: var(--shadow); background: #fff; }

/* ---------- 权限提示 ---------- */
.notice {
  margin: 16px; padding: 14px 16px; border-radius: 12px; font-size: 14px;
  background: #fff8e8; color: #8a5a10; border: 1px solid #f6e3bd;
}
.notice.error { background: var(--red-soft); color: #a3201b; border-color: #f6cdc9; }
.notice.info { background: #eef4ff; color: #24509c; border-color: #d8e4fa; }

/* ---------- 表格 ---------- */
.table { width: 100%; border-collapse: collapse; font-size: 13px; background: #fff; }
.table th, .table td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; }
.table th { color: var(--ink-3); font-weight: 600; background: #fafbfc; }
.scroll-x { overflow-x: auto; }

.skeleton { height: 14px; border-radius: 7px; background: linear-gradient(90deg, #eef0f3, #f7f8fa, #eef0f3); background-size: 200% 100%; animation: sk 1.2s infinite; }
@keyframes sk { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.hint-line { font-size: 12px; color: var(--ink-3); padding: 10px 16px; }

/* ---------- 我的成绩�?---------- */
.mx-page { padding-bottom: 8px; }
/* 成绩单分享按钮（红色导航栏右侧） */
.hero-share {
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border-radius: 999px;
  padding: 5px 13px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
}
.hero-share:active { opacity: 0.75; }
.mx-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(130px 130px at 100% -10%, rgba(210, 58, 46, 0.12), rgba(210, 58, 46, 0) 70%),
    linear-gradient(135deg, #ffffff 0%, #fffaf7 55%, #fff1e9 100%);
  border: 1px solid #f6e2d8;
  border-radius: 18px;
  padding: 18px;
  min-height: 152px;
  color: #231f1e;
  box-shadow: 0 6px 18px rgba(168, 28, 21, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.mx-hero::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, #d23a2e 0%, #e8835c 45%, rgba(232, 131, 92, 0) 100%);
}
.mx-hero-main { flex: 1; min-width: 0; padding-right: 136px; }
.mx-hall { font-size: 12px; color: #8c7b74; letter-spacing: 0.2px; display: flex; align-items: center; flex-wrap: nowrap; gap: 6px; min-width: 0; }
.mx-hall-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mx-hall .rc-chip, .mx-hall .mx-year { flex: 0 0 auto; }
.mx-hall::before {
  content: '';
  width: 6px; height: 6px; border-radius: 50%;
  background: #d23a2e;
  margin-right: 5px;
  flex: 0 0 auto;
}
.mx-year {
  display: inline-block; margin-left: 6px; padding: 1px 7px;
  border-radius: 999px; background: #fdeee7; color: #b0482f;
  font-size: 11px; font-weight: 700; vertical-align: 1px;
}
.mx-entry { font-size: 21px; font-weight: 800; margin-top: 6px; letter-spacing: 0.3px; line-height: 1.25; overflow-wrap: anywhere; color: #231f1e; }
.mx-hero-stats { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 12.5px; color: #6d625d; }
.mx-hero-stats .mx-year { margin-left: 0; }
.mx-hero-stats b { font-size: 16px; margin-right: 2px; color: #231f1e; }
/* 累计奖金：深红小圆 + 金边 + 白字，下面一行说明 */
.mx-prize-orb {
  position: relative;
  width: 96px; height: 96px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  padding: 8px; text-align: center;
  background:
    radial-gradient(circle at 30% 22%, rgba(255, 255, 255, 0.26) 0%, rgba(255, 255, 255, 0.05) 34%, rgba(0, 0, 0, 0.16) 100%),
    linear-gradient(160deg, #a51f14 0%, #8a120b 52%, #6d0b06 100%);
  border: 2px solid #e8cf9a;
  box-shadow:
    0 6px 14px rgba(120, 15, 8, 0.28),
    inset 0 0 0 4px rgba(232, 207, 154, 0.18),
    inset 0 1px 1px rgba(255, 255, 255, 0.25);
}
.mx-prize-orb::after {
  content: '';
  position: absolute;
  inset: 9px;
  border-radius: 50%;
  border: 1px solid rgba(232, 207, 154, 0.45);
  pointer-events: none;
}
.mx-prize-label {
  font-size: 11px; line-height: 1.2; letter-spacing: 0.6px;
  color: #f0d6a0; font-weight: 600;
  transform: translateY(1px);
}
.mx-prize-orb b {
  font-size: 17px; font-weight: 800; line-height: 1.15;
  color: #fff; font-variant-numeric: tabular-nums;
  white-space: nowrap; text-shadow: 0 1px 2px rgba(90, 12, 6, 0.35);
}
.mx-prize-orb b.sm { font-size: 12px; }
.mx-prize-orb.empty {
  background: #f2f3f6;
  border-color: #e7e9ee;
  box-shadow: none;
}
.mx-prize-orb.empty::after { border-color: #e4e7ec; }
.mx-prize-orb.empty .mx-prize-label { color: #b6bbc4; }
.mx-prize-orb.empty b { font-size: 18px; font-weight: 700; color: #b6bbc4; text-shadow: none; }
.mx-prize-caption { font-size: 11px; line-height: 1.3; color: #9a8b84; letter-spacing: 0.5px; white-space: nowrap; }
/* 累计奖金：金色桂冠（左枝 + 金额 + 右枝），靠右下角放 */
.mx-hero-prize { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); display: flex; align-items: center; justify-content: flex-end; }
/* 有奖金 / 没奖金用同一套尺寸，卡片高度保持一致 */
.mx-laurel { display: flex; align-items: center; justify-content: space-between; gap: 2px; height: 64px; width: 132px; flex: none; }
.mx-laurel svg { width: 27px; height: 64px; flex: 0 0 auto; }
.mx-laurel svg.laurel-flip { transform: scaleX(-1); }
.mx-laurel-text { display: flex; flex-direction: column; align-items: center; gap: 1px; min-width: 66px; }
.mx-laurel-text .mx-prize-label { color: #a5866a; font-size: 10.5px; letter-spacing: 1.2px; transform: none; }
.mx-laurel-text b {
  font-size: 24px; font-weight: 800; line-height: 1.1; color: #b3261b;
  white-space: nowrap; font-variant-numeric: tabular-nums; letter-spacing: 0.2px;
}
.mx-laurel-text b.sm { font-size: 15px; }
.mx-laurel.empty .mx-laurel-text::after { background: #e6e2da; }
/* 没奖金时整套仍走同一尺寸/位置，只把颜色改成浅灰 */
.mx-laurel.empty svg path { stroke: #ded8cf; }
.mx-laurel.empty svg g { fill: #ded8cf; }
.mx-laurel.empty .mx-prize-label { color: #b6bbc4; }
.mx-laurel.empty b { color: #b6bbc4; }
.mx-laurel-text::after {
  content: ''; display: block; width: 28px; height: 2px; margin: 3px auto 0; border-radius: 1px;
  background: linear-gradient(90deg, rgba(217, 173, 69, 0), #d9ad45, rgba(217, 173, 69, 0));
}
.mx-dot { width: 3px; height: 3px; border-radius: 50%; background: #cfb9b0; }

.mx-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #fff;
  border-radius: 16px;
  margin-top: 12px;
  padding: 14px 6px;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
}
.mx-stat { text-align: center; position: relative; }
.mx-stat + .mx-stat::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 28px;
  background: #f0f2f5;
}
.mx-k { font-size: 11px; color: #9aa0a8; }
.mx-v { font-size: 19px; font-weight: 800; color: #1f2329; margin-top: 4px; font-variant-numeric: tabular-nums; }
.mx-v small { font-size: 11px; font-weight: 500; color: #9aa0a8; margin-left: 2px; }

.mx-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 18px 2px 10px; }
.mx-title { font-size: 16px; font-weight: 800; color: #1f2329; margin-right: auto; }
.mx-modes { display: inline-flex; border: 1px solid #e6d3cb; border-radius: 999px; overflow: hidden; background: #fff; }
.mx-mode {
  border: 0;
  background: transparent;
  color: #8a6d63;
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
}
.mx-mode.on { background: #b32a21; color: #fff; }
.mx-money { color: #c0392b; font-weight: 700; }
.mx-money.zero { color: #b9b2aa; font-weight: 500; }
.mx-prize-sum { color: #ffe6a8; }
.mx-fs {
  border: 0;
  background: #f3f5f8;
  color: #4b5563;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
}
.mx-fs:active { background: #e8ecf1; }

.mx-tablewrap {
  background: #fff;
  border-radius: 16px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
}
.mx-table { border-collapse: separate; border-spacing: 0; width: 100%; table-layout: fixed; }
.mx-table th,
.mx-table td { padding: 11px 4px; font-size: 13px; }
.mx-table thead th {
  background: #f8efeb;
  color: #6f554a;
  font-weight: 600;
  font-size: 11.5px;
  border-bottom: 1px solid #efdfd8;
}
.mx-table tbody td { border-bottom: 1px solid #f5f7fa; color: #2b3036; }
.mx-table tbody tr:last-child td { border-bottom: 0; }
.mx-table tbody tr:nth-child(even) td { background: #fbfcfd; }

.mx-table .mx-ring {
  position: sticky;
  left: 0;
  z-index: 2;
  text-align: left;
  padding-left: 14px;
  background: #fff;
  box-shadow: 1px 0 0 #f0f2f5;
  font-weight: 700;
  font-size: 13px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.mx-table thead .mx-ring { z-index: 3; background: #f8efeb; }
.mx-table tbody tr:nth-child(even) .mx-ring { background: #fbfcfd; }

.mx-table .mx-color { text-align: center; color: #6b7280; font-size: 12.5px; }
.mx-table .mx-stage { text-align: center; }
.mx-km { font-size: 12px; color: #4b5563; font-weight: 700; }
.mx-return { font-size: 10.5px; color: #9aa0a8; font-weight: 400; margin-top: 2px; }
.mx-table .mx-cell { text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.mx-table .mx-cell.gold { color: #c58a12; }
.mx-table .mx-cell.silver { color: #7a8797; }
.mx-table .mx-cell.bronze { color: #b0724a; }
.mx-none { color: #c9cfd6; font-weight: 400; }
.mx-table .mx-spacer { width: auto; padding: 0; background: transparent; }

.mx-empty { padding: 28px 16px; text-align: center; color: #9aa0a8; font-size: 13px; }
.mx-hint {
  margin: 0 0 10px; padding: 10px 12px; border-radius: 10px;
  background: #fff8ee; color: #8a5a10; font-size: 12px; line-height: 1.5;
}
.mx-foot { margin-top: 10px; text-align: center; font-size: 11.5px; color: #9aa0a8; }

.mx-fs-overlay { position: fixed; inset: 0; background: #fff; z-index: 9999; display: flex; flex-direction: column; }
.mx-fs-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid #f0f2f5;
}
.mx-fs-title { font-weight: 800; font-size: 14px; }
.mx-fs-body { flex: 1; overflow: auto; padding: 8px; }

/* 全屏成绩单：横屏展示（内容旋�?90°，设备已是横屏则不转�?*/
.mx-fs-overlay { overflow: hidden; }
.mx-fs-rot { position: absolute; inset: 0; display: flex; flex-direction: column; background: #fff; }
.mx-fs-overlay.is-rotated .mx-fs-rot {
  inset: auto;
  top: 50%;
  left: 50%;
  width: 100vh;
  height: 100vw;
  transform: translate(-50%, -50%) rotate(90deg);
  transform-origin: center;
}
.mx-fs-overlay .mx-fs-body { padding: 6px 10px 10px; }
.mx-fs-overlay .mx-table th,
.mx-fs-overlay .mx-table td { padding: 9px 3px; }
.mx-fs-overlay .mx-tablewrap { box-shadow: none; }
/* 头像作为「我的」入口按�?*/
.avatar { padding: 0; cursor: pointer; color: #fff; font-family: inherit; line-height: 1; }
.avatar:active { transform: scale(0.96); }

/* ---------- 我的赛事 ---------- */
.hero.rc-hero { padding: 20px 18px 58px; }
.rc-hero-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.rc-hero-title { font-size: 20px; font-weight: 800; color: #fff; letter-spacing: 0.5px; }
.rc-hero-sub { margin-top: 7px; font-size: 12.5px; line-height: 1.4; color: rgba(255, 255, 255, 0.9); }
.rc-hero-btn {
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  flex: 0 0 auto;
}
.rc-body { padding-top: 0; }
.rc-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: #fff;
  border-radius: 18px;
  padding: 16px 6px;
  box-shadow: 0 6px 18px rgba(16, 18, 22, 0.08);
  margin: -38px 12px 0;
  position: relative;
  z-index: 2;
}
.rc-stat {
  text-align: center;
  position: relative;
  background: none;
  border: 0;
  border-radius: 12px;
  padding: 4px 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  transition: background 0.15s ease;
}
.rc-stat:active { background: #fafbfc; }
.rc-stat.on { background: #fff3f1; }
.rc-stat.on b { color: var(--red); }
.rc-stat.on span { color: var(--red); opacity: 0.75; }
.rc-filter-tip {
  margin-top: 10px;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 12px; color: #9aa0a8;
}
.rc-filter-tip button {
  border: 0; background: none; padding: 0;
  font-size: 12px; color: #2b6cd4; cursor: pointer;
}
.rc-stat + .rc-stat::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 26px;
  background: #f0f2f5;
}
.rc-stat b { display: block; font-size: 20px; font-weight: 800; color: #1f2329; font-variant-numeric: tabular-nums; }
.rc-stat span { font-size: 11.5px; color: #9aa0a8; }

.rc-tabs { display: flex; gap: 4px; margin-top: 16px; background: #f3f5f8; border-radius: 12px; padding: 4px; }
.rc-tabs button {
  flex: 1;
  border: 0;
  background: transparent;
  color: #6b7280;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 0;
  border-radius: 9px;
}
.rc-tabs button.on { background: #fff; color: #1f2329; box-shadow: 0 1px 4px rgba(16, 18, 22, 0.08); }

.rc-search { margin-top: 12px; }
.rc-list { margin-top: 2px; }
.rc-group-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 18px 2px 2px;
  font-size: 13px;
  font-weight: 700;
  color: #4b5563;
}
.rc-group-title span {
  font-size: 11px;
  font-weight: 600;
  color: #9aa0a8;
  background: #f1f3f6;
  border-radius: 999px;
  padding: 1px 8px;
}

.rc-card {
  display: grid;
  grid-template-columns: 46px 1fr auto;
  grid-template-areas: 'av main side' 'foot foot foot';
  gap: 10px 12px;
  background: #fff;
  border-radius: 16px;
  padding: 13px 14px;
  margin-top: 10px;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
  cursor: pointer;
}
.rc-card:active { transform: scale(0.995); }
.rc-avatar {
  grid-area: av;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 17px;
  color: #b01f1a;
  background: linear-gradient(135deg, #ffede9, #ffd9d2);
}
.rc-main { grid-area: main; min-width: 0; }
.rc-name {
  font-size: 15px;
  font-weight: 800;
  color: #1f2329;
  display: flex;
  align-items: center;
  gap: 6px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.rc-chip { font-size: 10.5px; font-weight: 700; padding: 2px 6px; border-radius: 6px; flex: 0 0 auto; }
.rc-chip.spring { color: #2b6cd4; background: #eaf2ff; }
.rc-chip.autumn { color: #c58a12; background: #fff6e3; }
.rc-chip.year { color: #5c6673; background: #f1f3f6; }
.rc-chip.ok { color: #1e8c5c; background: #e7f7ef; }
.rc-meta { margin-top: 5px; font-size: 12px; color: #6b7280; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.rc-cap { font-size: 10.5px; color: #9aa0a8; background: #f4f6f8; padding: 1px 5px; border-radius: 5px; }
.rc-muted { color: #b6bcc4; font-style: normal; }
.rc-dot { width: 3px; height: 3px; border-radius: 50%; background: #d4d9df; }
.rc-side { grid-area: side; display: flex; align-items: center; gap: 8px; }
.rc-count { font-size: 16px; font-weight: 800; color: #1f2329; }
.rc-count small { font-size: 10.5px; font-weight: 600; color: #9aa0a8; margin-left: 1px; }
.rc-arrow { color: #c3c9d1; font-size: 18px; }
.rc-foot {
  grid-area: foot;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  padding-top: 9px;
  border-top: 1px dashed #f0f2f5;
  font-size: 11.5px;
  color: #9aa0a8;
}
.rc-foot b { color: #4b5563; }
.rc-detail { margin-left: auto; color: #d9302a; font-weight: 600; }

/* 配对详情：父母环号单�?+ 繁育汇总紧�?*/
.pp-row { display: flex; align-items: flex-start; gap: 10px; }
.pp { flex: 1; min-width: 0; }
.pp-r { text-align: right; }
.pp-sex { font-size: 12px; color: #8a9099; }
.pp-ring {
  display: block;
  margin-top: 3px;
  text-decoration: none;
  color: #1f2329;
  font-size: 13px;
  font-weight: 700;
  color: #1f2329;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.2px;
  font-variant-numeric: tabular-nums;
}
.pp-x { color: #d9302a; font-size: 17px; padding-top: 16px; flex: 0 0 auto; }

.bs-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 6px; }
.bs { text-align: center; min-width: 0; }
.bs b { display: block; font-size: 19px; font-weight: 800; color: #1f2329; line-height: 1.15; font-variant-numeric: tabular-nums; }
.bs span { display: block; margin-top: 3px; font-size: 11px; color: #9aa0a8; white-space: nowrap; }
a.pp-ring { cursor: pointer; }
a.pp-ring::after { content: ' ›'; color: #c3c9d1; font-weight: 400; }
a.pp-ring:active { opacity: 0.6; }
/* 鸽子档案：父母环号链�?*/
.rel-link {
  color: #2b6cd4;
  text-decoration: none;
  font-size: 13px;
  white-space: nowrap;
  letter-spacing: -0.2px;
  font-variant-numeric: tabular-nums;
}
.rel-link:active { opacity: 0.6; }
/* 鸽子库列表：环号单行 + 操作/转库上下排列 */
.pigeon-row .main { min-width: 0; }
.pigeon-row .title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 14.5px;
  letter-spacing: -0.05px;
}
.act-btn.transfer { padding: 7px 10px; }
.row-actions { flex-direction: column; align-items: stretch; gap: 6px; }
.row-actions .act-btn { min-width: 76px; }

/* 种鸽库 / 预备库列表：比默认略大一点（老年人看得清），环号留足宽度不被截断 */
.pigeon-row { padding: 15px 10px; gap: 10px; }
.pigeon-row .thumb { width: 52px; height: 52px; border-radius: 11px; }
.pigeon-row .title { font-size: 15px; letter-spacing: 0; white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; line-height: 1.22; }
.pigeon-row .title.long { font-size: 14px; }
.pigeon-row .sub { font-size: 14.5px; margin-top: 2px; }
.pigeon-row .row-tags { margin-top: 7px; gap: 7px; }
.pigeon-row .row-tags .badge { font-size: 12.5px; padding: 2px 9px; }
.pigeon-row .sex-badge { font-size: 13.5px; }
.pigeon-row .row-actions .act-btn { font-size: 13px; padding: 7px 9px; min-width: 54px; }
@media (max-width: 370px) {
  .pigeon-row .title { font-size: 14px; }
  .pigeon-row .title.long { font-size: 13px; }
}
/* ---------- 配对详情：父母对�?+ 汇�?+ 产蛋 ---------- */
.pd-pair-card {
  background: #fff;
  border-radius: 18px;
  padding: 14px 14px 12px;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
}
.pd-row { display: flex; align-items: center; gap: 8px; }
.pd-bird {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  color: inherit;
}
.pd-bird.pd-r { justify-content: flex-end; text-align: right; }
.pd-sex {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 16px;
  font-weight: 800;
  flex: 0 0 auto;
}
.pd-sex.cock { color: #2b6cd4; background: #eaf2ff; }
.pd-sex.hen { color: #d9302a; background: #ffedea; }
.pd-info { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.pd-role { font-size: 10.5px; color: #9aa0a8; }
.pd-ring {
  font-size: 13px;
  font-weight: 800;
  color: #1f2329;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.2px;
  font-variant-numeric: tabular-nums;
}
.pd-name { font-size: 11px; color: #8a9099; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pd-x { align-self: center; color: #d9302a; font-size: 15px; font-weight: 800; flex: 0 0 auto; }
.pd-chips { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 12px; padding-top: 11px; border-top: 1px dashed #f0f2f5; }

.bs b.red { color: #d9302a; }
.bs b.blue { color: #2b6cd4; }
.bs b.green { color: #1e8c5c; }
.bs b.orange { color: #c58a12; }

.pd-rate { margin-top: 14px; }
.pd-rate-bar { height: 6px; border-radius: 999px; background: #f1f3f6; overflow: hidden; }
.pd-rate-bar span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #f0554f, #b01f1a); }
.pd-rate-txt { margin-top: 6px; font-size: 11px; color: #9aa0a8; text-align: right; }

/* 产蛋记录小优�?*/
.clutch-no {
  background: #fff1ef;
  color: #b01f1a;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12.5px;
}
.egg-title { font-weight: 700; font-size: 13px; color: #4b5563; }

/* 父母改为上下两行，环号完整显�?*/
.pd-row + .pd-row { margin-top: 6px; }
.pd-ring { flex: 0 0 auto; overflow: visible; text-overflow: clip; }
.pd-name { margin-left: auto; max-width: 42%; overflow: hidden; text-overflow: ellipsis; }
.pd-bird { padding: 2px 0; }

/* 产蛋行按钮：操作在上、删除在�?*/
.egg-actions { flex-direction: column; align-items: stretch; gap: 6px; }
.egg-actions .act-btn { min-width: 62px; text-align: center; }
/* 产蛋行：环号跟在「第 X 枚」后�?*/
.egg-code {
  margin-left: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #2b6cd4;
  background: #eaf2ff;
  padding: 2px 8px;
  border-radius: 7px;
  letter-spacing: -0.2px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   我的成绩单 · 参赛鸽浮层 / 飞行曲线（电竞数据风）
   ============================================================ */
.mono-num {
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-variant-numeric: tabular-nums;
}

/* 足环号可�?*/
.mx-ring-btn {
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 12.5px;
  font-weight: 800;
  color: #1d2a3f;
  background: none;
  border: 0;
  padding: 2px 0;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
}
.mx-ring-btn::after { content: "›"; margin-left: 3px; color: var(--info); font-family: sans-serif; }

/* ---------- 浮层 ---------- */
.pg-modal {
  position: fixed; inset: 0; z-index: 80;
  display: grid; place-items: center;
  padding: 18px;
  background: rgba(10, 14, 24, 0.5);
}
.pg-card {
  position: relative;
  width: 100%; max-width: 344px;
  background: #fff;
  border-radius: 24px;
  padding: 20px 20px 18px;
  box-shadow: 0 30px 70px -30px rgba(6, 10, 20, 0.7);
}
.pg-close {
  position: absolute; right: 14px; top: 14px;
  width: 30px; height: 30px; border-radius: 50%;
  border: 0; background: #f2f3f6; color: #7b8394;
  font-size: 15px; line-height: 1; cursor: pointer;
}
.pg-eyebrow { font-size: 10.5px; letter-spacing: 2px; color: var(--ink-3); font-weight: 600; }
.pg-ring {
  margin-top: 4px;
  display: flex; align-items: center; gap: 8px;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 22px; font-weight: 700; letter-spacing: 0.2px; color: #10141c;
}
.pg-flag {
  font-size: 10px; font-weight: 600; letter-spacing: 0;
  color: #b0271f; background: #ffefec; border-radius: 6px; padding: 3px 6px;
}
.pg-parents { margin-top: 12px; display: flex; gap: 8px; }
.pg-parents > div {
  flex: 1; min-width: 0;
  background: #f7f8fb; border-radius: 11px; padding: 8px 10px;
  font-size: 10.5px; color: var(--ink-3); line-height: 1.5;
}
.pg-parents b {
  display: block;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 12.5px; font-weight: 600; color: #2a3341;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pg-parents b.pg-none { color: #bcc2cc; font-weight: 500; font-family: inherit; font-size: 11.5px; }
.pg-sec {
  margin-top: 18px;
  display: flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 700; color: #1b2029;
}
.pg-cnt {
  margin-left: auto;
  font-size: 10.5px; font-weight: 500; color: var(--ink-3);
  background: #f4f5f8; border-radius: 999px; padding: 2px 8px;
}
.pg-list { margin-top: 6px; max-height: 232px; overflow: auto; }
.pg-item {
  display: flex; align-items: center; height: 38px;
  border-bottom: 1px solid #f3f4f7; font-size: 13px;
}
.pg-item:last-child { border-bottom: 0; }
.pg-item .km {
  color: #333b48;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 13px;
}
.pg-item .km i {
  display: inline-block; width: 4px; height: 4px; border-radius: 50%;
  background: #d8dce4; margin-right: 8px; vertical-align: 2px;
}
.pg-item .rk {
  margin-left: auto;
  display: flex; align-items: center; gap: 7px;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 13.5px; font-weight: 600; color: #4a5260;
}
.pg-item .tag {
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 9.5px; font-weight: 700; letter-spacing: 0.5px;
  color: #fff; background: linear-gradient(135deg, #ff5b3d, #d92a22);
  border-radius: 5px; padding: 2px 5px;
}
.pg-item.best { background: linear-gradient(90deg, rgba(224, 54, 45, 0.07), rgba(224, 54, 45, 0)); border-radius: 8px; }
.pg-item.best .rk { color: var(--red); font-weight: 800; }
.pg-actions { margin-top: 16px; display: grid; grid-template-columns: 1.15fr 1fr; gap: 10px; }
.pg-btn-primary {
  height: 44px; border: 0; border-radius: 14px;
  color: #fff; font-size: 13.5px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  background: linear-gradient(135deg, #ff5c3c 0%, #d92a22 55%, #b71c17 100%);
  box-shadow: 0 10px 20px -10px rgba(217, 42, 34, 0.85);
  cursor: pointer;
}
.pg-btn-ghost {
  height: 44px; border: 0; border-radius: 14px;
  font-size: 13.5px; font-weight: 700; color: #333b48;
  background: #f4f5f8;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer;
}

/* ---------- 飞行曲线详情�?---------- */
.pgc-page {
  position: fixed; inset: 0; z-index: 40;
  overflow-y: auto;
  color: #fff;
  background:
    radial-gradient(120% 60% at 8% 0%, rgba(255, 208, 150, 0.35) 0%, rgba(255, 208, 150, 0) 55%),
    radial-gradient(90% 60% at 100% 100%, rgba(255, 120, 70, 0.5) 0%, rgba(255, 120, 70, 0) 60%),
    linear-gradient(158deg, #6d0a0e 0%, #a3130f 34%, #d32a1d 66%, #f05a37 100%);
}
.pgc-page::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 100% 34px, 34px 100%;
  -webkit-mask-image: radial-gradient(120% 80% at 50% 0%, #000 20%, transparent 78%);
  pointer-events: none;
}
.pgc-inner {
  position: relative; z-index: 1;
  max-width: 520px; margin: 0 auto;
  min-height: 100vh;
  display: flex; flex-direction: column;
  padding: 10px 16px calc(16px + var(--safe-bottom));
}
.pgc-top { display: flex; align-items: center; gap: 10px; padding: 6px 0 10px; }
.pgc-rotate {
  margin-left: auto;
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff; font-size: 15px; line-height: 1;
  display: grid; place-items: center;
  cursor: pointer;
}
.pgc-body { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.pgc-back {
  width: 34px; height: 34px; border-radius: 12px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff; font-size: 19px; line-height: 1;
  display: grid; place-items: center; padding-bottom: 2px;
  cursor: pointer;
}
.pgc-title { font-size: 14.5px; font-weight: 700; letter-spacing: 0.2px; line-height: 1.25; text-shadow: 0 1px 10px rgba(80, 0, 0, 0.35); }
.pgc-title small { display: block; font-size: 10px; font-weight: 500; letter-spacing: 1.2px; opacity: 0.72; margin-top: 2px; }
.pgc-info {
  display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center;
  padding: 14px 14px 14px 16px;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06));
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
}
.pgc-k { font-size: 9.5px; letter-spacing: 1.6px; color: rgba(255, 255, 255, 0.62); font-weight: 600; }
.pgc-v {
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 16.5px; font-weight: 700; letter-spacing: 0.3px; margin: 1px 0 8px;
}
.pgc-v.owner { font-family: "PingFang SC", "Microsoft YaHei", sans-serif; font-size: 12.5px; font-weight: 600; margin: 0; color: rgba(255, 255, 255, 0.92); }
.pgc-stats { display: flex; gap: 14px; padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, 0.18); }
.pgc-stats div { text-align: right; }
.pgc-stats b {
  display: block;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 17px; font-weight: 700; letter-spacing: 0.2px;
}
.pgc-stats span { display: block; font-size: 8.5px; color: rgba(255, 255, 255, 0.62); margin-top: 2px; white-space: nowrap; }
.pgc-chart-card {
  margin-top: 14px;
  flex: 1; min-height: 360px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfe 100%);
  border-radius: 20px;
  padding: 14px 12px 10px;
  display: grid; grid-template-columns: 70px 1fr; gap: 8px;
  box-shadow: 0 22px 40px -26px rgba(40, 0, 0, 0.9);
  color: var(--ink);
}
.pgc-rail { display: flex; flex-direction: column; gap: 8px; padding-top: 4px; }
.pgc-rail-btn {
  border-radius: 11px; padding: 7px 6px;
  font-size: 9.5px; font-weight: 700; white-space: nowrap;
  display: flex; align-items: center; gap: 5px;
  color: #4c5461; background: #f3f5f8; border: 1px solid transparent;
  cursor: pointer;
}
.pgc-rail-btn i { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; }
.pgc-rail-btn.red i { background: var(--red); box-shadow: 0 0 0 3px rgba(224, 54, 45, 0.14); }
.pgc-rail-btn.blue i { background: var(--info); box-shadow: 0 0 0 3px rgba(47, 123, 246, 0.14); }
.pgc-rail-btn.on { background: #fff; border-color: #e6e9ef; box-shadow: 0 4px 10px -6px rgba(20, 28, 44, 0.35); }
.pgc-rail-btn.off { opacity: 0.45; }
.pgc-rail-btn.switch { flex-direction: column; align-items: flex-start; gap: 3px; font-size: 9.5px; color: #7b8394; background: #f7f8fb; }
.pgc-rail-btn.switch b { color: #1d2a3f; font-size: 11px; }
.pgc-rail-btn.switch b::after { content: " ▾"; color: #98a0ae; }
.pgc-chart-wrap { position: relative; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.pgc-legend { display: flex; gap: 10px; justify-content: flex-end; align-items: center; font-size: 9px; color: var(--ink-3); padding-right: 4px; margin-bottom: 2px; }
.pgc-legend span { display: inline-flex; align-items: center; gap: 4px; }
.pgc-legend i { width: 10px; height: 3px; border-radius: 2px; }
.pgc-chart-box { position: relative; flex: 1; min-height: 240px; }
.pgc-chart { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pgc-page--single .pgc-chart-card { flex: 0 0 auto; min-height: 0; }
.pgc-page--single .pgc-chart-box { flex: none; height: 300px; min-height: 0; }

/* 横屏：旋转后的页面布局 */
.pgc-page.is-rotated {
  top: 0; left: 0; right: auto; bottom: auto;
  width: 100vh; height: 100vw;
  transform: rotate(90deg) translateY(-100%);
  transform-origin: 0 0;
  overflow: hidden;
}
.pgc-page.is-landscape .pgc-inner {
  max-width: none; height: 100%; min-height: 0;
  padding: 6px 14px calc(8px + var(--safe-bottom));
}
.pgc-page.is-landscape .pgc-top { padding: 2px 0 8px; }
.pgc-page.is-landscape .pgc-body { flex-direction: row; gap: 12px; min-height: 0; }
.pgc-page.is-landscape .pgc-info {
  flex: 0 0 246px;
  align-self: flex-start;
  display: flex; flex-direction: column; justify-content: flex-start; gap: 10px;
}
.pgc-page.is-landscape .pgc-stats {
  border-left: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding: 10px 0 0;
  justify-content: space-between;
  gap: 8px;
}
.pgc-page.is-landscape .pgc-v { margin: 1px 0 0; }
.pgc-page.is-landscape .pgc-k + .pgc-v { margin-bottom: 6px; }
.pgc-page.is-landscape .pgc-chart-card { margin-top: 0; height: 100%; min-height: 0; }
.pgc-page.is-landscape .pgc-foot { margin-top: 8px; }
.pgc-page.is-landscape .pgc-hint { margin-top: 4px; }
.pgc-foot {
  display: flex; align-items: center; gap: 6px;
  margin-top: 12px;
  font-size: 9.5px; color: rgba(255, 255, 255, 0.66);
}
.pgc-foot .note { margin-left: auto; opacity: 0.85; }
.pgc-foot i { width: 12px; height: 3px; border-radius: 2px; display: inline-block; }
.pgc-hint { margin-top: 8px; font-size: 10px; color: rgba(255, 255, 255, 0.6); text-align: center; }

.pgc-chart text { font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace; }
.pgc-chart .c-axis { font-size: 8.5px; fill: #a3abb8; }
.pgc-chart .c-grid { stroke: #eef0f5; stroke-width: 1; }
.pgc-chart .c-grid.base { stroke: #e2e6ee; }
.pgc-chart .c-station { stroke: #f1f3f7; stroke-width: 1; stroke-dasharray: 3 4; }
.pgc-chart .c-km { font-size: 9px; fill: #8b93a1; }
.pgc-chart .c-rank { font-size: 8.5px; fill: #a3abb8; }
.pgc-chart .c-rank.top { fill: var(--red); font-weight: 700; }
.pgc-chart .c-speed-red { font-size: 9.5px; fill: #d92a22; font-weight: 700; paint-order: stroke; stroke: #fff; stroke-width: 3px; stroke-linejoin: round; }
.pgc-chart .c-speed-blue { font-size: 9.5px; fill: #2f7bf6; font-weight: 700; paint-order: stroke; stroke: #fff; stroke-width: 3px; stroke-linejoin: round; }
.pgc-chart .c-line-red { fill: none; stroke: #e0362d; stroke-width: 2.4; stroke-linecap: round; }
.pgc-chart .c-line-blue { fill: none; stroke: #2f7bf6; stroke-width: 2.4; stroke-linecap: round; }
.pgc-chart .c-area-blue { fill: url(#pgcBlueFade); }
.pgc-chart .c-dot-red { fill: #fff; stroke: #e0362d; stroke-width: 2.4; }
.pgc-chart .c-dot-blue { fill: #fff; stroke: #2f7bf6; stroke-width: 2.4; }
.pgc-chart .c-halo-red { fill: rgba(224, 54, 45, 0.14); }
.pgc-chart .c-halo-blue { fill: rgba(47, 123, 246, 0.12); }

/* ============================================================
   公棚详情：标题条 + 悬浮信息卡
   ============================================================ */
.rd-hero { padding-bottom: 38px; }
.rd-hall {
  position: relative; z-index: 1;
  margin: -8px 14px 0;
  background: linear-gradient(135deg, var(--orange-1), var(--orange-2));
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 18px;
  padding: 16px 16px 14px;
  box-shadow: 0 12px 28px -18px rgba(217, 48, 42, 0.35);
}
.rd-hall-name {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: 0.2px;
  color: var(--brown);
}
.rd-hall-meta {
  margin-top: 9px;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 12px; color: rgba(138, 75, 18, 0.78);
}
.rd-entry {
  display: inline-flex; align-items: center; gap: 4px;
  background: rgba(255, 255, 255, 0.62); color: var(--brown);
  font-size: 11.5px; font-weight: 700;
  border-radius: 999px; padding: 3px 9px;
}
.rd-entry.none {
  background: rgba(255, 255, 255, 0.42); color: rgba(138, 75, 18, 0.62); font-weight: 600;
}
.rd-season-line {
  margin-top: 9px;
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  font-size: 11.5px; font-weight: 600; color: rgba(92, 45, 37, 0.72);
}
.rd-season-pill {
  display: inline-flex; align-items: center;
  background: rgba(255, 255, 255, 0.82); color: #5c2d25;
  border-radius: 999px; padding: 3px 9px;
  font-size: 11.5px; font-weight: 800; letter-spacing: 0.2px;
}
.rd-season-line .rd-dot { background: rgba(92, 45, 37, 0.28); }

.rd-count { white-space: nowrap; flex: 0 0 auto; }
.rd-dot {
  display: inline-block; width: 3px; height: 3px; border-radius: 50%;
  background: #c8ccd4; margin: 0 6px; vertical-align: 3px;
}
.rd-rate {
  color: #b4691a; font-weight: 800;
  font-variant-numeric: tabular-nums;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
}

.rd-line { padding: 0; }
.rd-date { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

/* 每一关的指定费输入（赛程详情卡片里，填完自动记入收支账单） */
.rd-fee-row {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  margin-top: 10px; padding-top: 10px;
  border-top: 1px dashed #edf0f4;
  font-size: 12px; color: #6b7280;
}
.rd-fee-label { font-weight: 700; color: #4b5563; flex: 0 0 auto; display: inline-flex; align-items: baseline; min-width: 0; }
.rd-fee-entry { font-style: normal; font-weight: 500; font-size: 11px; color: #a3a9b3; margin-left: 5px; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rd-fee-cur { color: #9aa1ab; flex: 0 0 auto; }
.rd-fee-input {
  width: 104px; padding: 5px 8px;
  border: 1px solid #e3e7ee; border-radius: 8px;
  background: #fff; color: #1f2329;
  font-size: 13px; text-align: right;
  font-variant-numeric: tabular-nums;
}
.rd-fee-input:focus {
  border-color: #d9302a; outline: none;
  box-shadow: 0 0 0 3px rgba(217, 48, 42, 0.08);
}
.rd-fee-tip { margin-left: auto; color: #a0a6b0; font-size: 11px; }
/* 参赛名切换（一个公棚绑多个参赛名） */
.rd-entry { border: 0; background: none; padding: 0; font: inherit; color: inherit; display: inline-flex; align-items: center; gap: 4px; }
.rd-entry.switchable { cursor: pointer; }
.rd-entry.switchable:active { opacity: 0.7; }
.rd-entry-more { font-style: normal; font-size: 11px; color: #b4691a; background: #fdf1dc; border-radius: 999px; padding: 1px 6px; }
.entry-pick { display: flex; flex-direction: column; gap: 8px; }
.entry-pick-row {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  width: 100%; padding: 10px 12px; border-radius: 12px;
  border: 1px solid #e9edf2; background: #fff; text-align: left;
}
.entry-pick-row b { font-size: 15px; color: #1f2329; }
.entry-pick-row span { font-size: 12px; color: #8a9099; }
.entry-pick-row.on { border-color: var(--red); background: var(--red-soft); }
.entry-pick-row.on b { color: var(--red); }
.rc-entry-more { flex: 0 0 auto; font-size: 10.5px; color: #b4691a; background: #fdf1dc; border-radius: 999px; padding: 1px 6px; }
/* 解除匹配：选择要解除的参赛名 */
.unmatch-entries { display: flex; flex-direction: column; gap: 8px; }
.unmatch-entry {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 12px; border: 1px solid #e9edf2; border-radius: 12px; background: #fff;
}
.unmatch-entry b { font-size: 14px; color: #1f2329; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 历史比赛：按年份的赛季列表（图2 样式） */
.rd-history-head { padding: 2px 2px 12px; }
.rd-history-hall { font-size: 17px; font-weight: 800; color: #1f2329; letter-spacing: 0.2px; }
.rc-season-list {
  background: #fff; border-radius: 16px; box-shadow: var(--shadow);
  overflow: hidden;
}
.rc-season-item {
  width: 100%; display: flex; align-items: center; gap: 12px;
  padding: 16px 14px; background: #fff; border: 0; border-bottom: 1px solid var(--line);
  text-align: left; cursor: pointer;
}
.rc-season-item:last-child { border-bottom: 0; }
.rc-season-item:active { background: #fafbfc; }
.rc-season-main { flex: 1; min-width: 0; }
.rc-season-name {
  font-size: 15px; font-weight: 700; color: #1f2329;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rc-season-sub { margin-top: 5px; font-size: 12px; color: var(--ink-3); }
.rc-season-status {
  flex: 0 0 auto; display: flex; align-items: center; gap: 2px;
  font-size: 12px; color: #9aa1ad;
}
.rc-season-chev { color: #c3c9d1; font-size: 18px; line-height: 1; }

/* 种鸽/预备列表：置顶与重点飘红 */
.pigeon-row .title.hot { color: var(--red); }
.pin-tag {
  display: inline-block;
  margin-right: 6px;
  vertical-align: 2px;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
  color: #b97614;
  background: #fdf1de;
  border-radius: 5px;
  padding: 2px 5px;
}

/* 我的赛事卡片：参赛费移到公棚名右侧，底部显示归巢/归巢率 */
.rc-name-row { display: flex; align-items: flex-start; gap: 8px; }
.rc-name-row .rc-name { flex: 1; min-width: 0; }
.rc-fee {
  flex: 0 0 auto;
  margin-top: 1px;
  font-size: 11px;
  font-weight: 700;
  color: #b97614;
  background: #fff6e3;
  border-radius: 6px;
  padding: 2px 6px;
  white-space: nowrap;
}
.rc-rate { color: #b4691a; }

/* 我的赛事：公棚置顶按钮 */
.rc-pinbadge {
  flex: 0 0 auto;
  border: 1px solid #e6e9ee;
  background: #fff;
  color: #8b929c;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  padding: 5px 8px;
  border-radius: 8px;
  white-space: nowrap;
}
.rc-pinbadge.on {
  border-color: #f3c9c5;
  background: #fdeceb;
  color: var(--red);
}
.rc-pinbadge:disabled { opacity: 0.6; }
/* 置顶 / 有新比赛 分组标题 */
.rc-group-pin .rc-group-title { color: #1f2329; }
.rc-group-pin .rc-group-title em {
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
  color: #9aa0a8;
  margin-left: auto;
}

/* 子代成绩汇总 */
.os-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.os-field { font-size: 12px; color: #6b7280; display: inline-flex; align-items: center; gap: 4px; }
.os-field input {
  width: 62px; height: 32px; border: 1px solid var(--line); border-radius: 8px;
  padding: 0 8px; font-size: 13px; background: #fff; color: var(--ink);
}
.os-list { margin-top: 8px; }
.os-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid #f4f5f8; font-size: 12.5px; }
.os-row:last-child { border-bottom: 0; }
.os-ring { font-weight: 600; color: #1d2a3f; white-space: nowrap; }
.os-race { color: #6b7280; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
.os-rank { color: #d9302a; white-space: nowrap; }
.os-list .hint-line { padding: 8px 0; }

/* 我的赛事 · 赛事总结 */
.rc-summary {
  margin-top: 12px;
  padding: 14px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
}
.rc-summary-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin-bottom: 4px;
}
.rc-summary-title { font-size: 14px; font-weight: 800; color: #1f2329; }
.rc-summary-meta { display: block; font-size: 11.5px; font-weight: 500; color: #9aa0a8; margin-bottom: 8px; }
/* 没查询过时这两行是空的：别让它们撑出空白 */
.rc-summary-meta:empty,
#sumEntries:empty { display: none; margin: 0; }
.rc-summary .os-list { margin-top: 6px; }

.rc-summary-share {
  margin-left: auto;
  border: 0;
  background: #f4f5f8;
  color: #4b5563;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
}

.os-btn { height: 40px; font-size: 13.5px; padding: 0 10px; white-space: nowrap; }

.os-new {
  font-style: normal;
  font-size: 10px;
  font-weight: 600;
  color: #b4691a;
  background: #fdf3e3;
  border-radius: 6px;
  padding: 1px 4px;
  margin-left: 4px;
  vertical-align: 1px;
}

/* ---------- 赛程详情：公棚收鸽清单入口 ---------- */
.rd-hall.has-intake { padding-right: 112px; }
.rd-intake {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 80px; padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.62);
  border-radius: 12px;
  color: var(--brown);
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(150, 80, 10, 0.08);
}
.rd-intake:active { transform: translateY(-50%) scale(0.97); }
.rd-intake-num { font-size: 11px; font-weight: 600; line-height: 1.15; white-space: nowrap; }
.rd-intake-num b { font-size: 16px; font-weight: 700; letter-spacing: 0; }
.rd-intake-season { margin-bottom: 1px; font-size: 9px; font-weight: 700; color: rgba(138, 75, 18, 0.62); white-space: nowrap; }
.rd-intake-label { margin-top: 2px; font-size: 10px; font-weight: 500; color: rgba(138, 75, 18, 0.82); white-space: nowrap; }

/* ---------- 收鸽清单弹层 ---------- */
.intake-card { max-width: 560px; max-height: 84vh; display: flex; flex-direction: column; padding-bottom: 14px; }
.intake-hall { margin-top: 6px; padding-right: 30px; font-size: 15px; font-weight: 800; color: var(--ink); line-height: 1.35; }
.intake-total { margin-top: 4px; font-size: 12px; color: var(--ink-3); }
.intake-search { display: flex; gap: 8px; margin-top: 12px; }
.intake-search input {
  flex: 1; min-width: 0; height: 38px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: 14px;
}
.intake-list { margin-top: 8px; overflow: auto; flex: 1; min-height: 140px; }
.intake-row { display: flex; align-items: flex-start; gap: 10px; padding: 9px 2px; border-bottom: 1px solid var(--line); }
.intake-ring {
  flex: 0 0 auto; min-width: 122px; padding-top: 1px;
  font-family: "Bahnschrift", "DIN Alternate", "Consolas", ui-monospace, monospace;
  font-size: 13px; font-weight: 700; color: var(--ink);
}
.intake-main { min-width: 0; }
.intake-name { font-size: 13px; font-weight: 600; color: var(--ink); word-break: break-all; }
.intake-sub { margin-top: 3px; font-size: 11.5px; color: var(--ink-3); }
.intake-empty { padding: 28px 0; text-align: center; color: var(--ink-3); font-size: 13px; }

/* 参赛鸽档案：参赛名/地区行、无成绩提示 */
.pg-sub { margin-top: 6px; font-size: 12px; color: var(--ink-3); line-height: 1.4; }
.pg-hint { padding: 8px 0 2px; text-align: center; font-size: 12px; color: var(--ink-3); line-height: 1.5; }

/* 我的赛事卡片：参赛费放到最右侧，场次在下方 */
.rc-side { flex-direction: column; align-items: flex-end; justify-content: flex-start; gap: 6px; padding-top: 1px; }
.rc-side-count { display: flex; align-items: center; gap: 6px; }
.rc-side .rc-fee { margin-top: 0; }

/* 公棚名旁边的春/秋棚徽标间距 */
.rd-hall-name .rc-chip { margin-left: 6px; vertical-align: 2px; }
.mx-hall .rc-chip { margin-left: 0; vertical-align: 2px; }
.mx-hall .mx-year { margin-left: 0; }
.rc-meta .rc-chip { margin-right: 2px; }

/* 公棚名过长时省略，春/秋棚徽标保持完整显示 */
.rc-name-text { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 公棚有更新：卡片与底部 Tab 的红点 */
.rc-new-dot {
  display: inline-block; width: 7px; height: 7px; margin-left: 5px;
  border-radius: 50%; background: var(--red); vertical-align: 1px;
}
.tabbar button { position: relative; }
.tabbar .tab-new {
  position: absolute; top: 3px; left: calc(50% + 7px);
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--red); border: 2px solid #fff; box-sizing: content-box;
}

/* 「我的赛事」头部：已匹配/春棚/秋棚 下面显示参赛羽数 */
.rc-stat-birds {
  display: block; margin-top: 2px;
  font-style: normal; font-size: 10.5px; color: #9aa0a8; font-variant-numeric: tabular-nums;
}
.rc-stat.on .rc-stat-birds { color: var(--red); opacity: 0.75; }

/* 参赛名过长时省略，羽数固定在右侧同一行，不被挤到下一行 */
.rc-meta-line { flex-wrap: nowrap; }
.rc-entry-text { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rc-birds { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }

/* 「参赛名」小标签不要被挤成两行 */
.rc-cap { flex: 0 0 auto; white-space: nowrap; }

/* 赛程详情：公棚名过长时省略，春/秋棚徽标整体不拆行 */
.rd-hall-name { display: flex; align-items: center; gap: 6px; min-width: 0; }
.rd-hall-name-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rd-hall-name .rc-chip { flex: 0 0 auto; white-space: nowrap; }
.rc-chip { white-space: nowrap; }
.mx-hall .rc-chip { white-space: nowrap; }

/* 我的赛事：收支账单入口与账单页 */
.rc-ledger-entry {
  width: calc(100% - 24px); margin: 12px auto 0; padding: 12px 14px;
  display: flex; align-items: center; gap: 10px;
  background: #fff; border: 0; border-radius: 14px; text-align: left;
  box-shadow: 0 4px 14px rgba(16,18,22,0.06);
}
.rc-ledger-ico {
  width: 32px; height: 32px; border-radius: 10px; flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  background: #fff4e5; color: #b4691a; font-weight: 800;
}
.rc-ledger-txt { flex: 1; min-width: 0; }
.rc-ledger-txt b { display: block; font-size: 14px; color: #1f2329; }
.rc-ledger-txt i { display: block; margin-top: 2px; font-style: normal; font-size: 11px; color: #9aa0a8; }
.lg-page { padding-bottom: 96px; }
.lg-summary { background: #fff; border-radius: 16px; padding: 16px; box-shadow: 0 6px 18px rgba(16,18,22,0.07); }
.lg-balance span { font-size: 12px; color: #9aa0a8; }
.lg-balance b { display: block; margin-top: 4px; font-size: 30px; font-weight: 800; }
.lg-two { display: flex; gap: 12px; margin-top: 12px; padding-top: 12px; border-top: 1px solid #f0f2f5; }
.lg-two > div { flex: 1; }
.lg-two span { font-size: 12px; color: #9aa0a8; }
.lg-two b { display: block; margin-top: 2px; font-size: 17px; }
.lg-cats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.lg-cats > div { display: flex; justify-content: space-between; gap: 6px; padding: 6px 8px; border-radius: 8px; background: #f7f8fa; font-size: 12px; color: #6b7280; }
.lg-item { position: relative; margin-top: 10px; padding: 12px 14px; background: #fff; border-radius: 14px; box-shadow: 0 4px 14px rgba(16,18,22,0.05); }
.lg-item-head { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; }
.lg-item-head b { color: #1f2329; }
.lg-del { margin-top: 6px; padding: 0; border: 0; background: none; color: #b6bcc4; font-size: 12px; }
.pos { color: #1e8c5c; }
.neg { color: var(--red); }
.lg-form label { display: block; margin-top: 10px; font-size: 13px; color: #5c636e; }
.lg-form label[hidden] { display: none; }
.lg-form input, .lg-form select {
  width: 100%; margin-top: 5px; padding: 10px 12px;
  border: 1px solid #e5e8ee; border-radius: 10px; background: #fafbfc; font-size: 14px;
}

/* 我的赛事页内嵌收支账单卡片 */
.rc-ledger-card {
  margin: 12px 0 0; padding: 12px 14px;
  background: #fff; border-radius: 16px;
  box-shadow: 0 6px 18px rgba(16,18,22,0.07);
  cursor: pointer;
}
.rc-ledger-head { display: flex; justify-content: space-between; align-items: center; font-size: 14px; font-weight: 700; color: #1f2329; }
.rc-ledger-more { font-size: 12px; font-weight: 400; color: #9aa0a8; }
.rc-ledger-total { margin-top: 4px; display: flex; align-items: baseline; gap: 8px; }
.rc-ledger-total span { font-size: 12px; color: #9aa0a8; }
.rc-ledger-total b { margin-top: 0; font-size: 18px; font-weight: 800; }
.rc-ledger-total b.pos { color: #1e8c5c; }
.rc-ledger-total b.neg { color: var(--red); }
.rc-ledger-two { display: flex; gap: 12px; margin-top: 6px; padding-top: 6px; border-top: 1px solid #f0f2f5; }
.rc-ledger-two > div { flex: 1; }
.rc-ledger-two span { font-size: 11px; color: #9aa0a8; }
.rc-ledger-two b { display: block; margin-top: 0; font-size: 15px; }
.rc-ledger-cats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 8px; }
.rc-ledger-cats > div { display: flex; justify-content: space-between; gap: 6px; padding: 6px 8px; border-radius: 8px; background: #f7f8fa; font-size: 12px; color: #6b7280; }
.rc-ledger-cats > .rc-cat-wide { grid-column: 1 / -1; }
.rc-cat-hint { font-style: normal; font-size: 10px; color: #a3a9b3; margin-left: 5px; }

/* 我的赛事头部统计卡稍微压扁 */
.rc-stats { padding: 11px 6px; border-radius: 16px; }
.rc-stat { padding: 2px 0; }
.rc-stat b { font-size: 19px; }
.rc-stat span { font-size: 11px; }
.rc-stat-birds { margin-top: 1px; font-size: 10px; }

/* 账单里的自动参赛费 */
.lg-auto { margin-left: 6px; padding: 1px 5px; border-radius: 5px; background: #eef4ff; color: #2b6cd4; font-size: 10.5px; font-weight: 600; vertical-align: 1px; }

/* 赛程详情：本公棚收支卡整体上移一点 */
.rd-ledger-wrap .rc-ledger-card { margin-top: 0; }

/* 暖色卡片配色统一：从橙黄改为更接近品牌红的柔和珊瑚色 */
:root {
  --orange-1: #fff6f3;
  --orange-2: #ffe3db;
  --brown: #6d3328;
}
/* 赛程详情 · 公棚卡：把「粉雾底 + 棕字 + 蓝徽标」收进一套暖白＋品牌红体系。
   底色用暖白瓷面（不再和上方红头抢视线），一级信息近黑、二级信息暖灰，
   红只留给「年份 pill、羽数、徽标描边」，和下面的白色账单卡同一色阶。 */
.rd-hall {
  background:
    radial-gradient(130% 120% at 100% 0%, rgba(217, 48, 42, 0.055) 0%, rgba(217, 48, 42, 0) 62%),
    linear-gradient(180deg, #fffdfc 0%, #fff7f3 100%);
  border: 1px solid rgba(217, 48, 42, 0.11);
  box-shadow: 0 16px 30px -24px rgba(120, 42, 32, 0.5), 0 2px 6px rgba(120, 42, 32, 0.04);
}
.rd-hall-name { color: #241b18; }
.rd-hall-meta { color: #6f625c; }
.rd-entry { background: none; color: #3f3733; }
.rd-entry.none { background: none; color: #9a8d87; }
.rd-entry-more { color: #8a7b74; background: #f5efec; }
.rd-season-pill {
  background: #fff0ed;
  color: #b8281f;
  box-shadow: inset 0 0 0 1px rgba(217, 48, 42, 0.14);
}
.rd-hall-name .rc-chip.spring { color: #16845b; background: #e9f7ef; }
.rd-hall-name .rc-chip.autumn { color: #9a5b08; background: #fdf0df; }
.rd-intake {
  background: #fff;
  border: 1px solid rgba(217, 48, 42, 0.13);
  color: #2b2320;
  box-shadow: 0 8px 18px -16px rgba(120, 42, 32, 0.38), 0 1px 2px rgba(120, 42, 32, 0.04);
}
.rd-intake-num { color: #8a7b74; }
.rd-intake-num b { color: #2b2320; }
.rd-intake-season { color: #a8958d; }
.rd-intake-label { color: #8a7b74; }
.rc-chip.autumn { color: #9a5b08; background: #fff3dd; }
.rc-fee { color: #9a5b08; background: #fff3dd; }

/* 收支账单新版布局：左总收入，右上支出、右下收入 */
.rc-ledger-body { display: flex; gap: 14px; margin-top: 10px; align-items: stretch; }
.rc-ledger-main {
  flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center;
  padding-right: 14px; border-right: 1px solid #f0f2f5;
}
.rc-ledger-main span { font-size: 12px; color: #9aa0a8; }
.rc-ledger-main b { margin-top: 2px; font-size: 24px; font-weight: 800; }
.rc-ledger-side { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.rc-ledger-side > div { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.rc-ledger-side span { font-size: 12px; color: #9aa0a8; }
.rc-ledger-side b { font-size: 16px; }

/* 快捷操作：标题一行，小字另起一行 */
.quick-item .qm { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.quick-item .qt, .quick-item .qs { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* 配对详情：繁育汇总嵌入配对卡右侧 */
.pd-pair-card { position: relative; padding-right: 134px; }
.pd-pair-card .pd-bird { gap: 6px; }
.pd-pair-card .pd-ring { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.pd-pair-card .pd-name { max-width: 34%; font-size: 10.5px; }
.pd-summary-side {
  position: absolute; right: 14px; top: 14px; bottom: 12px; width: 106px;
  padding-left: 10px; border-left: 1px solid #f0f2f5;
}
.pd-summary-title { margin-bottom: 5px; font-size: 10.5px; color: #9aa0a8; }
.pd-bs { grid-template-columns: 1fr 1fr; gap: 6px 2px; }
.pd-bs .bs b { font-size: 15px; }
.pd-bs .bs span { margin-top: 1px; font-size: 10px; }
.pd-summary-side .pd-rate { margin-top: 7px; }
.pd-summary-side .pd-rate-txt { font-size: 9.5px; }

/* 配对详情：繁育汇总压成一条横条，放在父母与状态之间 */
.pd-pair-card { padding-right: 14px; }
.pd-summary-side { display: none; }
.pd-summary-strip {
  display: flex; align-items: baseline; gap: 10px; flex-wrap: nowrap; overflow: hidden;
  margin-top: 8px; padding: 7px 0 6px;
  border-top: 1px dashed #f0f2f5;
  font-size: 10.5px; color: #9aa0a8; white-space: nowrap;
}
.pd-summary-strip span { display: inline-flex; align-items: baseline; gap: 3px; }
.pd-summary-strip b { font-size: 14px; font-weight: 800; color: #1f2329; }
.pd-summary-strip b.red { color: #d9302a; }
.pd-summary-strip b.blue { color: #2b6cd4; }
.pd-summary-rate { margin-left: auto; color: #9aa0a8; }
.pd-pair-card .pd-chips { margin-top: 6px; padding-top: 8px; border-top: 0; }

/* 繁育汇总横条与雌/雄标签左对齐 */
.pd-summary-strip { padding-left: 40px; gap: 8px; }

/* 配对详情：父母字体略放大；子代收支账单更扁 */
.pd-pair-card .pd-ring { font-size: 15px; }
.pd-pair-card .pd-name { font-size: 12px; max-width: 38%; }
.pd-pair-card .pd-role { font-size: 11px; }
.pd-ledger-card { padding: 10px 12px !important; }
.pd-ledger-card .rc-ledger-body { margin-top: 4px; }
.pd-ledger-card .rc-ledger-main b { font-size: 20px; }
.pd-ledger-card .rc-ledger-side { gap: 4px; }
.pd-ledger-card .rc-ledger-cats { margin-top: 6px; gap: 4px; }
.pd-ledger-card .rc-ledger-cats > div { padding: 4px 8px; }
.pd-ledger-card .hint-line { margin-top: 6px !important; }

/* 配对详情：雄/雌字略大，产蛋记录与子代列表压扁 */
.pd-pair-card .pd-role { font-size: 12px; }
.clutch-card { padding: 9px 12px; margin-bottom: 8px; }
.clutch-head { padding-bottom: 6px; }
.egg-row { padding: 6px 0; }
.egg-chips { margin-top: 4px; }
#kidList .row { padding: 9px 12px; }
#kidList .row .title { font-size: 13.5px; }

/* 配对库列表：父母信息改为上下两行，环号尽量放大且不截断 */
.pair-birds { display: flex; flex-direction: column; gap: 9px; padding: 2px 0 7px; }
.pair-birds .bird-cell { gap: 10px; }
.pair-birds .bird-thumb-sm { width: 40px; height: 40px; border-radius: 11px; }
.pair-birds .bird-ring {
  font-size: 16px; letter-spacing: -0.2px;
  /* 手机系统字体放大后环号别再被省略号截断：换行显示全（优先在「-」处断行） */
  white-space: normal; overflow: visible; text-overflow: clip;
  overflow-wrap: anywhere; line-height: 1.22;
}
.pair-birds .bird-name { font-size: 13px; margin-top: 2px; }
.pair-birds .sex-dot { width: 16px; height: 16px; font-size: 9.5px; }
/* 窄屏把环号字号收一点，保证整串显示（16px 在 375 宽以内放得下，再窄就降档） */
@media (max-width: 370px) {
  .pair-birds .bird-ring { font-size: 15px; }
}
@media (max-width: 330px) {
  .pair-birds .bird-ring { font-size: 13px; }
}

/* 配对库列表：窝/蛋/套环统计移到父母右侧 */
.pair-body { display: flex; align-items: flex-start; gap: 10px; }
.pair-birds { flex: 1; min-width: 0; }
.pair-stats {
  flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end;
  gap: 6px; padding-top: 3px;
}
.pair-stats .stat-chip { white-space: nowrap; font-size: 12px; padding: 3px 8px; }
.pair-foot .pair-date { font-size: 12.5px; }
.pair-foot .badge { font-size: 12px; }
.pair-card { padding: 15px 15px 12px; }

/* 新建配对：父母对比界面 */
.pc-heads { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pc-pick {
  display: flex; align-items: center; gap: 8px; padding: 10px;
  border: 1px solid #e7ebf0; border-radius: 12px; background: #fff; text-align: left;
}
.pc-pick.cock { background: #eef4ff; border-color: #dbe7ff; }
.pc-pick.hen { background: #fff0f1; border-color: #ffdce0; }
.pc-pick-ico {
  width: 30px; height: 30px; border-radius: 9px; flex: 0 0 auto;
  display: grid; place-items: center; background: #fff; font-size: 18px; font-weight: 800;
}
.pc-pick.cock .pc-pick-ico { color: #2b6cd4; }
.pc-pick.hen .pc-pick-ico { color: #d9302a; }
.pc-pick-main { flex: 1; min-width: 0; }
.pc-pick-main b { display: block; font-size: 15px; color: #1f2329; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-pick-main i { display: block; margin-top: 2px; font-style: normal; font-size: 10.5px; color: #8a9099; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-pick-arrow { flex: 0 0 auto; color: #b6bcc4; font-size: 18px; }
.pc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; align-items: start; }
.pc-col { min-width: 0; }
.pc-col.empty { min-height: 220px; display: grid; place-items: center; border: 1px dashed #e2e6ec; border-radius: 12px; }
.pc-empty { font-size: 12px; color: #b6bcc4; }
.pc-row {
  display: flex; align-items: flex-start; gap: 4px; margin-top: 7px; padding: 7px 8px;
  border-radius: 8px; background: #f7f8fa; font-size: 11px; color: #8a9099;
}
.pc-row span { flex: 0 0 auto; }
.pc-row b { flex: 1; min-width: 0; font-size: 12px; color: #1f2329; word-break: break-all; }
.pc-photo { margin-top: 8px; padding: 8px; border-radius: 10px; background: #f7f8fa; font-size: 11px; color: #8a9099; }
.pc-photo img { display: block; width: 100%; aspect-ratio: 1 / 1; margin-top: 5px; border-radius: 8px; object-fit: cover; background: #eef1f5; }
.pc-noimg { margin-top: 5px; height: 90px; display: grid; place-items: center; border-radius: 8px; background: #eef1f5; color: #b6bcc4; font-size: 11px; }
.pc-edit {
  margin-top: 8px; width: 100%; height: 36px; border: 1px solid #dfe3e9; border-radius: 999px;
  background: #fff; font-size: 14px; font-weight: 600; color: #1f2329;
}
.pc-code { display: flex; align-items: center; gap: 10px; margin-top: 14px; padding: 12px; background: #f7f8fa; border-radius: 10px; }
.pc-code label { flex: 0 0 auto; font-size: 13px; color: #5c636e; }
.pc-code label em { color: #d9302a; font-style: normal; }
.pc-code input { flex: 1; min-width: 0; height: 38px; border: 1px solid #e1e5eb; border-radius: 8px; padding: 0 10px; background: #fff; font-size: 14px; }
.pc-compare {
  width: 100%; margin-top: 12px; padding: 12px 0; display: flex; justify-content: space-between;
  border: 0; border-top: 1px solid #eef1f5; border-bottom: 1px solid #eef1f5;
  background: #fff; font-size: 14px; color: #1f2329;
}
.pc-cmp { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pc-cmp img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 10px; }
.pc-cmp span { display: block; margin-top: 4px; text-align: center; font-size: 12px; color: #8a9099; }

.pc-compare[hidden] { display: none; }

/* 鸽眼对比：上下排列 */
.pc-cmp { grid-template-columns: 1fr; gap: 12px; }
.pc-cmp img { max-height: 46vh; }

/* 鸽眼对比：上下全屏 */
.pc-full { position: fixed; inset: 0; z-index: 60; background: #000; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.pc-full-img { position: relative; width: 100%; height: 100vh; display: flex; align-items: center; justify-content: center; }
.pc-full-img img { max-width: 100%; max-height: 100vh; object-fit: contain; }
.pc-full-img span {
  position: absolute; left: 16px; top: 16px; padding: 3px 12px;
  border-radius: 999px; background: rgba(0,0,0,0.45); color: #fff; font-size: 12px;
}
.pc-full-close {
  position: fixed; right: 14px; top: calc(14px + env(safe-area-inset-top, 0px)); z-index: 61;
  width: 46px; height: 46px; padding: 0; border: 0; border-radius: 50%;
  background: #fff; color: #1f2329; font-size: 26px; font-weight: 600; line-height: 44px; text-align: center;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(0, 0, 0, 0.06);
  cursor: pointer;
}
.pc-full-close:active { transform: scale(0.94); }
/* 顶部压一层渐变，图片顶边再亮也能看清关闭按钮和「雄/雌」标签 */
.pc-full::before {
  content: ''; position: fixed; left: 0; right: 0; top: 0; height: 96px; z-index: 60;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0));
  pointer-events: none;
}

/* 鸽眼对比：一屏上下两图，不滚动 */
.pc-full { display: flex; flex-direction: column; overflow: hidden; }
.pc-full-img { flex: 1 1 50%; height: auto; min-height: 0; padding: 6px 0; }
.pc-full-img img { max-height: 100%; }

/* ---------- 血统识别确认：足环关系树 + 原图选区 ---------- */
.ocr-tree {
  display: grid; grid-auto-flow: column; gap: 4px; padding: 8px;
  background: var(--card); border-radius: var(--r); box-shadow: var(--shadow);
  grid-auto-rows: minmax(18px, auto); overflow-x: auto;
}
.ocr-tree-col { display: contents; }
.ocr-tree-gen { display: none; }
.ocr-tree-cell { display: flex; flex-direction: column; justify-content: center; height: 100%; min-height: 0; overflow: hidden; }
.ocr-tree-cell .ot-gen { font-size: 10px; color: var(--ink-3); }
.ocr-tree-cell .ot-ring { font-size: 11px; font-weight: 800; font-family: ui-monospace, monospace; word-break: break-all; line-height: 1.25; }
.ocr-tree-cell .ot-name { font-size: 11px; font-weight: 700; margin-top: 3px; }
.ocr-tree-cell .ot-meta { font-size: 10.5px; color: #6b7280; margin-top: 1px; }
.ocr-tree-cell .ot-bl { font-size: 10.5px; color: #3f454d; margin-top: 2px; }
.ocr-tree-cell .ot-ow {
  font-size: 10px; color: #8a919c; margin-top: 3px; line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.ocr-tree-cell { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 4px 6px; line-height: 1.3; text-align: left; width: 100%; }
.ocr-tree-cell:active { background: #f2f4f7; }
.ocr-tree-cell.editing { border-color: var(--red); box-shadow: 0 0 0 2px rgba(217, 48, 42, 0.12); }
/* 正在填写足环的编辑条 */
.ocr-edit { background: #fff; border: 1px solid #dfe3e9; border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; box-shadow: var(--shadow); }
.ocr-edit-tip { font-size: 12.5px; color: var(--ink-2); margin-bottom: 8px; }
.ocr-edit-row { display: flex; gap: 6px; align-items: center; justify-content: flex-end; margin-top: 8px; }
.ocr-edit-row input { flex: 1; min-width: 0; height: 38px; border: 1px solid var(--line); border-radius: 9px; padding: 0 10px; font-size: 15px; font-weight: 600; }
.ocr-edit-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 8px; }
.ocr-edit .field { margin-bottom: 8px; }
.ocr-edit .field label { font-size: 12px; }
.ocr-tree-cell span { display: block; color: var(--ink-3); font-size: 10px; }
.ocr-tree-cell b { display: block; font-size: 11px; font-weight: 700; word-break: break-all; }
.ocr-tree-cell.empty { opacity: 0.45; }
.ocr-img-wrap { position: relative; border-radius: 12px; overflow: hidden; background: #0b0c0e; line-height: 0; }
.ocr-img-wrap img { width: 100%; display: block; }
.ocr-boxes { position: absolute; inset: 0; }
.ocr-box { position: absolute; border: 2px solid #ff3b30; border-radius: 4px; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.6); }
/* 第二屏：逐羽卡片（窄屏一列、宽屏两列） */
.ocr-cards { display: grid; gap: 10px; }
.ocr-cards > .card { margin-top: 0 !important; }
@media (min-width: 640px) {
  .ocr-cards { grid-template-columns: 1fr 1fr; align-items: start; }
}
/* 只读卡片：像看血统书一样逐羽扫 */
.ocr-pcard {
  display: block; width: 100%; text-align: left; background: #fff; border: 1px solid #eef0f4;
  border-radius: 12px; padding: 10px 12px; box-shadow: 0 4px 14px rgba(20, 24, 31, 0.05);
}
.ocr-pcard:active { background: #fafbfc; }
.ocr-pcard-ring { font-size: 13px; font-weight: 800; font-family: ui-monospace, monospace; color: #1f2329; word-break: break-all; }
.ocr-pcard-name { font-size: 15px; font-weight: 700; margin-top: 4px; }
.ocr-pcard-sex { font-weight: 800; margin-right: 4px; }
.ocr-pcard-sex.cock { color: #2b6cd4; }
.ocr-pcard-sex.hen { color: #d9302a; }
.ocr-pcard-sex.unknown { color: #98a0ae; }
.ocr-pcard-meta { font-size: 12.5px; color: #6b7280; margin-top: 2px; }
.ocr-pcard-line { font-size: 12.5px; color: #3f454d; margin-top: 4px; }
.ocr-pcard-own {
  font-size: 12px; color: #6b7280; margin-top: 6px; line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
}
.ocr-pcard-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; font-size: 12px; color: #9aa0a8; }

/* ---------- 导入数据 ---------- */
.imp-list { margin-top: 8px; border-top: 1px solid var(--line); }
.imp-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.imp-ring { flex: 1; min-width: 0; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.imp-name { flex: 0 0 auto; max-width: 30%; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.imp-sex { flex: 0 0 auto; font-size: 12px; color: var(--ink-3); }
.imp-act { flex: 0 0 auto; padding: 2px 6px; border-radius: 6px; font-size: 11px; }
.imp-act.new { background: #e9f7f0; color: #1a7f5a; }
.imp-act.dup { background: #fdf3e0; color: #a4701a; }
.imp-more { padding: 8px 0; font-size: 12px; color: var(--ink-3); }
.imp-err { margin-top: 8px; padding: 8px 10px; border-radius: 8px; background: var(--red-soft); border: 1px solid #f6cdc9; color: #a3201b; font-size: 12px; line-height: 1.5; }


/* ---------- 查鸽宝 ---------- */
.qg-page { display: flex; flex-direction: column; min-height: calc(100vh - 84px); padding-bottom: 28px; }
.qg-brand { text-align: center; padding: 20px 0 24px; }
.qg-brand-mark { display: flex; justify-content: center; margin-bottom: 4px; }
.qg-brand-mark svg { width: 72px; height: 72px; filter: drop-shadow(0 6px 12px rgba(217,48,42,.10)); }
.qg-brand-name { font-size: 31px; line-height: 1.1; font-weight: 800; letter-spacing: 2px; color: #1f1f1f; }
.qg-brand-saas { margin-left: 3px; font-size: 0.62em; letter-spacing: 0; color: var(--red, #D9302A); vertical-align: 2px; }
.qg-brand-sub { margin-top: 5px; font-size: 9px; letter-spacing: 2px; color: #b8bbc0; }
.qg-tabs { display: flex; justify-content: center; border-bottom: 1px solid var(--line); }
.qg-tab { position: relative; border: 0; background: none; padding: 10px 18px 12px; font-size: 18px; color: #8b8f96; }
.qg-tab.on { color: #1f1f1f; font-weight: 700; }
.qg-tab.on::after { content: ''; position: absolute; left: 18px; right: 18px; bottom: -1px; height: 3px; border-radius: 2px; background: var(--red, #B01F1A); }
.qg-form { display: flex; gap: 10px; margin-top: 18px; }
.qg-year { flex: 0 0 31%; min-width: 0; height: 52px; border: 1px solid transparent; border-radius: 12px; background: #f4f5f7; color: #1f1f1f; font-size: 18px; font-weight: 700; padding: 0 12px; outline: none; }
.qg-input { flex: 1 1 auto; min-width: 0; height: 52px; border: 1px solid transparent; border-radius: 12px; background: #f4f5f7; color: #1f1f1f; font-size: 17px; padding: 0 16px; outline: none; }
.qg-input::placeholder { color: #b4b7bd; font-size: 16px; }
.qg-year:focus, .qg-input:focus { border-color: rgba(217,48,42,.45); background: #fff; box-shadow: 0 0 0 3px rgba(217,48,42,.08); }
.qg-go { display: block; width: 100%; height: 52px; margin: 30px 0 12px; border: 0; border-radius: 999px; background: linear-gradient(180deg, #DE3A34, #C42520); color: #fff; font-size: 19px; font-weight: 700; letter-spacing: 2px; box-shadow: 0 8px 20px rgba(196,37,32,.22); }
.qg-go:active { transform: translateY(1px); box-shadow: 0 4px 12px rgba(196,37,32,.18); }
.qg-history-link { display: block; margin-left: auto; border: 0; background: none; color: #2B6CD4; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; }
.qg-results { margin-top: 18px; }
.qg-result-head { margin-bottom: 8px; font-size: 13px; color: var(--ink-3); }
.qg-note { margin: auto 0 0; padding-top: 42px; text-align: center; font-size: 12px; line-height: 1.7; color: #b8bbc0; }

/* 参赛名选择 */
.qg-owner-page { padding: 0 16px 96px; min-height: 100vh; background: var(--bg); }
.qg-owner-banner { margin: 0 -16px; padding: 13px 16px; background: linear-gradient(180deg, #DE3A34, #C42520); color: #fff; font-size: 18px; font-weight: 700; letter-spacing: 1px; }
.qg-owner-list { margin-top: 0; background: #fff; border-radius: 0 0 14px 14px; overflow: hidden; box-shadow: 0 4px 16px rgba(20,24,31,.04); }
.qg-owner-row { position: relative; display: flex; align-items: center; gap: 12px; padding: 15px 12px; border-bottom: 1px solid var(--line); cursor: pointer; transition: background .15s; }
.qg-owner-row:last-child { border-bottom: 0; }
.qg-owner-row:has(input:checked) { background: #fff8f6; }
.qg-owner-row input { position: absolute; opacity: 0; pointer-events: none; }
.qg-owner-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.qg-owner-main b { font-size: 16px; font-weight: 600; color: #1f1f1f; line-height: 1.35; word-break: break-all; }
.qg-owner-main i { font-style: normal; font-size: 12.5px; color: #8b8f96; }
.qg-owner-main em { font-style: normal; font-size: 12px; color: #b4b7bd; }
.qg-owner-radio { flex: 0 0 22px; width: 22px; height: 22px; border: 2px solid #d6d8dc; border-radius: 50%; transition: border-color .15s; }
.qg-owner-row input:checked ~ .qg-owner-radio { border-color: var(--red, #B01F1A); background: radial-gradient(circle, var(--red, #B01F1A) 0 6px, #fff 7px 100%); }
.qg-owner-actions { position: fixed; left: 50%; bottom: 0; z-index: 20; width: 100%; max-width: 520px; transform: translateX(-50%); display: flex; align-items: center; gap: 14px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -4px 16px rgba(0,0,0,.05); }
.qg-select-all { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #555; white-space: nowrap; }
.qg-select-all input { width: 20px; height: 20px; accent-color: var(--red, #B01F1A); }
.qg-next { flex: 1 1 auto; height: 46px; border: 0; border-radius: 999px; background: linear-gradient(180deg, #DE3A34, #C42520); color: #fff; font-size: 17px; font-weight: 700; letter-spacing: 1px; box-shadow: 0 6px 14px rgba(196,37,32,.18); }
.qg-next:disabled { background: #e7e9ec; color: #a7abb2; box-shadow: none; }

/* 参赛名汇总 */
.qg-summary-page { padding: 0 16px 32px; min-height: 100vh; background: var(--bg); }
.qg-selected-tip { margin: 0 -16px; padding: 10px 16px; background: #fdf3e6; color: #8a5a2a; font-size: 14px; }
.qg-selected-tip b { color: var(--red, #B01F1A); font-size: 18px; }
.qg-summary-card { position: relative; overflow: hidden; margin: 12px 0 0; padding: 18px; border-radius: 16px; background: linear-gradient(135deg, #fbe8d7, #f2c9ae); box-shadow: 0 6px 18px rgba(196,120,50,.10); }
.qg-summary-card::after { content: ''; position: absolute; right: -18px; top: -22px; width: 92px; height: 92px; border-radius: 50%; background: rgba(255,255,255,.20); }
.qg-summary-title { position: relative; z-index: 1; font-size: 18px; font-weight: 800; color: #4a2b18; }
.qg-summary-stats { position: relative; z-index: 1; display: flex; gap: 10px; margin-top: 16px; }
.qg-summary-stats > div { flex: 1 1 0; min-width: 0; padding: 12px; border-radius: 12px; background: rgba(255,255,255,.82); display: flex; flex-direction: column; gap: 4px; }
.qg-summary-stats span { font-size: 13px; color: #5d5148; }
.qg-summary-stats b { font-size: 27px; line-height: 1.1; color: #3d2a1c; font-variant-numeric: tabular-nums; }
.qg-season-tabs { display: flex; justify-content: space-around; margin: 14px -16px 0; padding: 0 6px; border-bottom: 1px solid var(--line); background: #fafafa; }
.qg-season-tab { flex: 1 1 0; border: 0; background: none; padding: 12px 0; font-size: 15px; color: #555; position: relative; }
.qg-season-tab.on { color: var(--red, #B01F1A); font-weight: 700; }
.qg-season-tab.on::after { content: ''; position: absolute; left: 22%; right: 22%; bottom: -1px; height: 2px; background: var(--red, #B01F1A); }
.qg-summary-list { padding-top: 12px; }

/* 公棚卡片 */
.qg-hall { display: flex; align-items: center; gap: 12px; width: 100%; margin-bottom: 10px; padding: 14px; border: 0; border-radius: 14px; background: #fff; text-align: left; box-shadow: 0 2px 10px rgba(20,24,31,.045); transition: transform .12s, box-shadow .12s; }
.qg-hall:active { transform: scale(.995); box-shadow: 0 1px 5px rgba(20,24,31,.04); }
.qg-hall-ico { flex: 0 0 46px; width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: #f7e9e7; color: var(--red, #B01F1A); font-size: 18px; font-weight: 800; }
.qg-hall-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.qg-hall-main b { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 16px; color: #1f1f1f; }
.qg-hall-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qg-season-chip { flex: 0 0 auto; display: inline-flex; align-items: center; padding: 1px 7px; border-radius: 6px; font-size: 11px; font-weight: 700; line-height: 1.7; letter-spacing: 0; }
.qg-season-chip::before { content: ''; width: 5px; height: 5px; margin-right: 3px; border-radius: 50%; background: currentColor; }
.qg-season-chip.spring { background: #e9f7ef; color: #16845b; }
.qg-season-chip.autumn { background: #fdf0df; color: #a96913; }
.qg-hall-main i { font-style: normal; font-size: 13px; color: #555; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qg-hall-main em { font-style: normal; font-size: 12px; color: #8b8f96; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qg-chev { flex: 0 0 auto; color: #c0c3c8; font-size: 22px; }

/* 公棚成绩表 */
.qg-hall-page { padding: 0 16px 32px; min-height: 100vh; background: var(--bg); }
.qg-hall-hero { position: relative; overflow: hidden; margin: 12px 0 0; padding: 16px; border-radius: 16px; background: linear-gradient(135deg, #fbe8d7, #f2c9ae); box-shadow: 0 6px 18px rgba(196,120,50,.10); }
.qg-hall-hero::after { content: ''; position: absolute; right: -24px; bottom: -30px; width: 110px; height: 110px; border-radius: 50%; background: rgba(255,255,255,.18); }
.qg-hall-hero-name { position: relative; z-index: 1; max-width: calc(100% - 110px); font-size: 18px; font-weight: 700; color: #3d2a1c; line-height: 1.35; }
.qg-hall-season { position: relative; z-index: 1; margin-top: 8px; font-size: 15px; color: #4a2b18; }
.qg-hall-best { position: absolute; right: 14px; top: 14px; z-index: 1; width: 96px; padding: 8px; border-radius: 12px; background: rgba(255,255,255,.88); text-align: center; box-shadow: 0 2px 8px rgba(196,120,50,.08); }
.qg-hall-best b { display: block; font-size: 27px; color: #b07b28; line-height: 1.1; font-variant-numeric: tabular-nums; }
.qg-hall-best span { font-size: 11px; color: #8a6a38; }
.qg-hall-stats { position: relative; z-index: 1; display: flex; gap: 8px; margin-top: 16px; }
.qg-hall-stats > div { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,.42); }
.qg-hall-stats b { font-size: 21px; color: #3d2a1c; font-variant-numeric: tabular-nums; }
.qg-hall-stats span { font-size: 12px; color: #6b5a4b; }
.qg-table-tools { display: flex; align-items: center; justify-content: space-between; margin: 14px 0 9px; }
.qg-mode { display: inline-flex; border-radius: 9px; overflow: hidden; border: 1px solid var(--red, #B01F1A); background: #fff; }
.qg-mode button { border: 0; background: transparent; color: var(--red, #B01F1A); padding: 7px 24px; font-size: 15px; }
.qg-mode button.on { background: var(--red, #B01F1A); color: #fff; font-weight: 600; }
.qg-full-btn { border: 0; background: none; color: #444; font-size: 14px; }
.qg-table-wrap { overflow: auto; border-radius: 12px; background: #fff; box-shadow: 0 2px 10px rgba(20,24,31,.045); -webkit-overflow-scrolling: touch; }
.qg-table { width: 100%; border-collapse: collapse; font-size: 13px; white-space: nowrap; }
.qg-table th, .qg-table td { padding: 12px 10px; text-align: center; border-bottom: 1px solid #f1f2f4; }
.qg-table tbody tr:nth-child(even) td { background: #fcfcfd; }
.qg-table th { background: #fdf5ea; color: #4a3b2c; font-weight: 600; position: sticky; top: 0; z-index: 1; }
.qg-table td:first-child, .qg-table th:first-child { text-align: left; position: sticky; left: 0; background: #fff; z-index: 1; }
.qg-table th:first-child { background: #fdf5ea; z-index: 2; }
.qg-table tbody tr:nth-child(even) td:first-child { background: #fcfcfd; }
.qg-ring { color: #2B6CD4; text-decoration: underline; text-underline-offset: 2px; font-variant-numeric: tabular-nums; }

/* 全屏成绩表 */
body.qg-table-full #view { padding: 0; }
body.qg-table-full .qg-hall-hero { display: none; }
body.qg-table-full .qg-table-tools { position: fixed; top: 0; left: 0; right: 0; z-index: 10000; margin: 0; padding: 8px 16px; background: #fff; border-bottom: 1px solid var(--line); }
body.qg-table-full .qg-table-wrap { position: fixed; top: 52px; left: 0; right: 0; bottom: 0; z-index: 9999; border-radius: 0; box-shadow: none; }


















/* ---------- 天气预报（赛线沿途） ---------- */
.wx-hall { background: #fff; border-radius: 14px; padding: 12px 14px; box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05); }
.wx-hall-name { font-size: 16px; font-weight: 800; color: #1f2937; line-height: 1.3; }
.wx-hall-meta { margin-top: 3px; font-size: 11.5px; color: #8b9199; }
.wx-races { background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05); }
.wx-race { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; padding: 13px 14px; border: 0; border-bottom: 1px solid #f1f3f6; background: #fff; text-align: left; }
.wx-race:last-child { border-bottom: 0; }
.wx-race:active { background: #fafbfc; }
.wx-race-name { flex: 1 1 auto; min-width: 0; font-size: 14px; font-weight: 600; color: #1f2937; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wx-race-meta { flex: 0 0 auto; font-size: 12px; color: #9aa0a8; white-space: nowrap; }
.wx-race-meta b { color: #d9302a; font-variant-numeric: tabular-nums; }
.wx-race-meta i { font-style: normal; color: #c0c5cc; }
.wx-race.off .wx-race-name { color: #b6bcc4; }
.wx-race.is-done { opacity: 0.55; }
.wx-race.is-done .wx-race-name { color: #9aa0a8; }
.wx-race.is-done .wx-race-meta b { color: #b3b9c1; }
.wx-done-tag { display: inline-block; margin-right: 6px; padding: 1px 6px; border-radius: 999px; background: #f1f3f5; color: #8a9099; font-size: 11px; vertical-align: 1px; }
.wx-race.off:active { background: #fff; }

.wx-page { position: relative; padding: 0; margin-bottom: -96px; background: #e9edf2; }
.wx-map { height: 100%; min-height: 0; border-radius: 0; overflow: hidden; background: #e9edf2; }
.wx-sheet {
  position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 600;
  background: #fff; border-radius: 16px; padding: 14px;
  box-shadow: 0 8px 24px rgba(16, 18, 22, 0.18);
  max-height: 58%; overflow-y: auto; -webkit-overflow-scrolling: touch;
}
.wx-sheet-title { font-size: 12px; color: #9aa0a8; line-height: 1.4; word-break: break-all; }
.wx-sheet-race { margin-top: 2px; font-size: 16px; font-weight: 800; color: #1f2937; line-height: 1.3; }
.wx-sheet-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; font-size: 11.5px; color: #8b9199; }
.wx-sheet-meta b { color: #d9302a; font-variant-numeric: tabular-nums; }
.wx-points { display: flex; gap: 8px; margin-top: 12px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 2px; }
.wx-point { flex: 0 0 auto; min-width: 74px; padding: 8px 10px; border-radius: 12px; background: #f6f8fa; text-align: center; }
.wx-point-km { font-size: 10.5px; color: #d9302a; font-weight: 700; white-space: nowrap; }
.wx-point-km.km { font-variant-numeric: tabular-nums; }
.wx-point-city { margin-left: 4px; color: #8b9199; font-weight: 400; }
.wx-point-temp { margin-top: 2px; font-size: 17px; font-weight: 800; color: #1f2937; font-variant-numeric: tabular-nums; }
.wx-point-wind { margin-top: 1px; font-size: 10.5px; color: #6b7280; white-space: nowrap; }
.wx-note { margin-top: 10px; font-size: 10.5px; line-height: 1.6; color: #a2a8b0; }

.wx-mk { background: none; border: 0; }
.wx-mk-in { display: flex; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1px 4px; min-width: 0; padding: 3px 6px; border-radius: 9px; background: rgba(43, 108, 212, 0.92); color: #fff; box-shadow: 0 4px 10px rgba(20, 40, 80, 0.25); white-space: nowrap; }
.wx-mk-in b { font-size: 12px; font-weight: 800; line-height: 1.15; }
.wx-mk-in span { font-size: 9px; opacity: 0.92; line-height: 1.15; }
.wx-mk-in i { flex: 0 0 100%; font-style: normal; font-size: 8.5px; opacity: 0.75; line-height: 1.15; text-align: center; max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.wx-map .leaflet-container { background: #e9edf2; font: inherit; }
/* 天气预报：地图容器 + 赛线概览按钮 + 概览表 */
.wx-mapwrap { position: absolute; inset: 0; z-index: 0; isolation: isolate; }
.wx-ov-btn {
  position: absolute; right: 14px; top: 12px; z-index: 650;
  border: 0; border-radius: 999px; padding: 9px 14px;
  background: #fff; color: #2b6cd4; font-size: 13px; font-weight: 700;
  box-shadow: 0 6px 18px rgba(16, 18, 22, 0.16);
}
.wx-ov-btn:active { transform: translateY(1px); }
.wx-ov-card {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 14px; padding: 14px 16px;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
}
.wx-ov-card > div { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wx-ov-card > div:last-child { align-items: flex-end; text-align: right; }
.wx-ov-card b { font-size: 20px; font-weight: 800; color: #1f2329; }
.wx-ov-card span { font-size: 11.5px; color: #9aa0a8; }
.wx-ov-head {
  display: flex; align-items: baseline; gap: 8px; margin: 14px 2px 8px;
  font-size: 12.5px; font-weight: 700; color: #3f454d;
}
.wx-ov-head em { margin-left: auto; font-style: normal; font-weight: 400; font-size: 11px; color: #9aa0a8; }
.wx-ov-table {
  width: 100%; border-collapse: separate; border-spacing: 0;
  background: #fff; border-radius: 14px; overflow: hidden;
  box-shadow: 0 2px 10px rgba(16, 18, 22, 0.05);
  font-size: 12.5px; color: #3f454d;
}
.wx-ov-table th {
  background: #f3f6fb; color: #5b6472; font-weight: 600;
  padding: 9px 6px; font-size: 11.5px; white-space: nowrap;
}
.wx-ov-table td { padding: 10px 6px; text-align: center; border-top: 1px solid #f2f4f7; white-space: nowrap; }
.wx-ov-table td.wx-ov-city { font-weight: 600; color: #1f2329; }
.wx-ov-table td.wx-ov-wi { font-size: 15px; }
.wx-ov-table tr:first-child td { border-top: 0; }
/* 赛线概览：日期条 */
.wx-ov-caret { font-style: normal; font-size: 12px; color: #9aa0a8; }
.wx-dates { display: flex; gap: 8px; margin: 10px 0 2px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 2px; }
.wx-date {
  flex: 1 0 auto; min-width: 52px; padding: 7px 8px; border: 1px solid #eef0f3; border-radius: 12px;
  background: #fff; display: flex; flex-direction: column; align-items: center; gap: 1px;
}
.wx-date b { font-size: 13px; font-weight: 700; color: #3f454d; font-variant-numeric: tabular-nums; }
.wx-date span { font-size: 10px; color: #9aa0a8; }
.wx-date.on { background: #d9302a; border-color: #d9302a; }
.wx-date.on b, .wx-date.on span { color: #fff; }
/* 天气预报：风向箭头（箭头指风吹去的方向） */
.wx-wind-arrow {
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-right: 3px;
  vertical-align: -1px;
  transform-origin: 50% 50%;
  opacity: 0.95;
}
.wx-wind-arrow path { fill: currentColor; }
.wx-point-wind .wx-wind-arrow { width: 12px; height: 12px; vertical-align: -2px; }
/* 天气预报：加载中遮罩 */
.wx-loading-layer {
  position: absolute; inset: 0; z-index: 700;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  background: #eef1f5; color: #3f454d; font-size: 17px; font-weight: 600; letter-spacing: 0.5px;
}
.wx-spinner {
  width: 38px; height: 38px; border-radius: 50%;
  border: 3.5px solid #d5dbe3; border-top-color: #d9302a;
  animation: wx-spin 0.8s linear infinite;
}
@keyframes wx-spin { to { transform: rotate(360deg); } }
/* 分速预测 */
.wx-sheet-head { display: flex; align-items: flex-start; gap: 10px; }
.wx-sheet-main { flex: 1 1 auto; min-width: 0; }
.wx-predict-wrap { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 5px; flex: 0 0 auto; }
.wx-predict-val { font-size: 24px; font-weight: 800; color: #d9302a; line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -0.5px; }
.wx-predict-val i { font-style: normal; font-size: 10px; font-weight: 400; color: #9aa0a8; margin-left: 3px; letter-spacing: 0; }
.wx-predict-btn {
  border: 1px solid #f0bdb9; background: #fff1ef; color: #d9302a;
  border-radius: 999px; padding: 5px 14px; font-size: 12.5px; font-weight: 700;
}
.wx-predict-btn:active { transform: translateY(1px); }
.wx-predict-btn b { font-size: 13px; font-variant-numeric: tabular-nums; margin-left: 2px; }
.wx-predict-btn.is-off { border-color: #e6e8ec; background: #f6f7f9; color: #9aa0a8; }
.wx-modal-mask {
  position: fixed; inset: 0; z-index: 2000; background: rgba(15, 18, 22, 0.45);
  display: flex; align-items: flex-end; justify-content: center; padding: 0 0 18px;
}
.wx-modal {
  width: min(460px, 92vw); background: #fff; border-radius: 18px; padding: 16px 18px 18px;
  box-shadow: 0 18px 40px rgba(16, 18, 22, 0.25);
}
.wx-modal-head { display: flex; align-items: center; justify-content: space-between; }
.wx-modal-head b { font-size: 15px; color: #1f2329; }
.wx-modal-x { border: 0; background: transparent; font-size: 22px; line-height: 1; color: #9aa0a8; padding: 0 2px; }
.wx-modal-title { margin-top: 2px; font-size: 12px; color: #8b9199; }
.wx-pred-speed { margin-top: 14px; display: flex; align-items: baseline; gap: 6px; justify-content: center; }
.wx-pred-speed b { font-size: 40px; font-weight: 800; color: #d9302a; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.wx-pred-speed span { font-size: 12px; color: #8b9199; }
.wx-pred-sub { margin-top: 2px; text-align: center; font-size: 12px; color: #6b7280; }
.wx-pred-rows { margin-top: 14px; border-top: 1px solid #f2f4f7; }
.wx-pred-rows > div { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid #f2f4f7; font-size: 13px; }
.wx-pred-rows span { color: #8b9199; }
.wx-pred-rows b { color: #1f2329; font-weight: 600; }
.wx-pred-note { margin-top: 10px; font-size: 10.5px; line-height: 1.6; color: #a2a8b0; }
.wx-pred-empty { margin-top: 16px; text-align: center; font-size: 13px; color: #8b9199; }
/* ================= PC / 宽屏（>=1024px） ================= */
/* 手机端维持原来的 520px 单列；宽屏切成「左侧导航 + 内容区」，方便入库、看列表、打印血统书 */
.sidebar { display: none; }

@media (min-width: 1024px) {
  body { background: #e9ecf1; }
  #app { max-width: 1440px; }
  body.has-sidebar #app { display: grid; grid-template-columns: 224px minmax(0, 1fr); align-items: start; box-shadow: 0 0 48px rgba(16, 18, 22, 0.07); }

  .sidebar { display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; padding: 18px 12px 14px; background: #fff; border-right: 1px solid var(--line); }
  .sidebar[hidden] { display: none; }
  .sb-brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 18px; }
  .sb-logo { width: 40px; height: 40px; border-radius: 12px; background: linear-gradient(180deg, var(--red), var(--red-dark)); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 18px; flex: 0 0 auto; }
  .sb-brand b { font-size: 15.5px; letter-spacing: 0.2px; }
  .sb-brand small { display: block; font-size: 11.5px; color: var(--ink-3); margin-top: 2px; font-weight: 400; }
  .sb-nav { display: flex; flex-direction: column; gap: 4px; }
  .sb-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 0; border-radius: 10px; background: none; font-size: 14.5px; color: var(--ink-2); text-align: left; cursor: pointer; }
  .sb-item svg { width: 20px; height: 20px; flex: 0 0 auto; }
  .sb-item:hover { background: #f6f7f9; }
  .sb-item.on { background: var(--red-soft); color: var(--red); font-weight: 700; }
  .sb-tool { font-size: 14px; color: var(--ink-3); }
  .sb-gap { height: 1px; margin: 10px 8px; background: var(--line); }
  .sb-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
  .sb-new { width: 100%; height: 40px; border: 0; border-radius: 10px; background: linear-gradient(180deg, var(--red), var(--red-dark)); color: #fff; font-size: 14px; font-weight: 700; cursor: pointer; }

  .tabbar { display: none !important; }
  .view { padding-bottom: 32px; min-height: 100vh; }
  .section { padding: 20px 28px; }
  .section > .card, .section > .list, .section > .section-title { max-width: 1200px; }
  .field input, .field select, .field textarea { max-width: 680px; }

  /* 弹层改成居中大弹窗 */
  .sheet { top: 50%; bottom: auto; left: 50%; right: auto; transform: translate(-50%, -50%); width: min(680px, calc(100vw - 96px)); max-height: 84vh; border-radius: 16px; padding: 20px 22px; }
  .toast { bottom: 40px; }

  /* 底部操作条跟着内容区居中（内容区中心 = 视口中心 + 侧栏一半） */
  .actionbar { left: calc(50% + 112px); right: auto; transform: translateX(-50%); width: min(1080px, calc(100vw - 280px)); max-width: none; bottom: 16px; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 10px 30px rgba(16, 18, 22, 0.12); }

  /* 血统书预览：按 A4 宽度显示，不再拉伸满屏 */
  .cert-print-stage { padding: 24px; }
  .cert-print-stage svg { width: min(210mm, 100%); margin: 0 auto; }
}

@media (min-width: 1024px) {
  .hero { padding: 16px 28px 20px; }
  .hero.compact { padding-bottom: 16px; }
  .fab { right: calc(max(0px, (100vw - 1440px) / 2) + 32px); bottom: 104px; }
}

/* 鸽子列表：宽屏两列，少滚动、方便逐只核对 */
@media (min-width: 1280px) {
  .list.grid-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; background: transparent; box-shadow: none; overflow: visible; max-width: 1200px; }
  .list.grid-list .row { background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 2px 10px rgba(16, 18, 22, 0.04); }
  .list.grid-list .row:last-child { border-bottom: 1px solid var(--line); }
}

@media (min-width: 1024px) {
  .form { padding: 20px 28px; max-width: 1080px; }
  .form .ring-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .form .photo-pair { grid-template-columns: repeat(2, minmax(0, 300px)); }
}

@media (min-width: 1024px) {
  .auth { max-width: 560px; margin: 0 auto; }
}

/* ---------- PC 列表：表头 + 批量选择 ---------- */
@media (min-width: 1024px) {
  .pg-table-wrap { background: #fff; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; max-width: 1200px; }
  .pg-table { width: 100%; border-collapse: collapse; font-size: 14px; }
  .pg-table th { text-align: left; font-size: 12.5px; font-weight: 600; color: var(--ink-3); background: #fafbfc; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
  .pg-table td { padding: 11px 12px; border-bottom: 1px solid #f1f3f6; vertical-align: middle; }
  .pg-table tbody tr:last-child td { border-bottom: 0; }
  .pg-table tbody tr:hover { background: #fbfcfe; cursor: pointer; }
  .pg-table .pg-check { width: 40px; text-align: center; }
  .pg-table .pg-check input { width: 16px; height: 16px; accent-color: var(--red); }
  .pg-table .pg-ring { font-weight: 700; letter-spacing: 0.2px; font-size: 13px; }
  .pg-table .pg-ring.hot { color: var(--red); }
  .pg-table .pg-sex { font-style: normal; margin-left: 6px; font-size: 12px; }
  .pg-table .pg-sex.cock { color: #2B6CD4; }
  .pg-table .pg-sex.hen { color: #D9302A; }
  .pg-table .pg-name { color: var(--ink-2); }
  .pg-table .pg-meta, .pg-table .pg-status, .pg-table .pg-lib { color: var(--ink-3); white-space: nowrap; }
  .pg-table .pg-status .badge + .badge { margin-left: 6px; }
  .pg-table .pg-act { text-align: right; }
  .pg-table .act-btn { min-width: 66px; }

  .batchbar { position: fixed; left: calc(50% + 112px); transform: translateX(-50%); bottom: 16px; z-index: 26; display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 10px 30px rgba(16, 18, 22, 0.14); }
  .batchbar[hidden] { display: none; }
  .batchbar .batch-count { font-size: 13px; color: var(--ink-2); white-space: nowrap; }
  .batchbar .batch-count b { color: var(--red); }
  .batchbar .btn { height: 36px; width: auto; }
}

@media print {
  #certPrint svg { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
}

@media (min-width: 1024px) {
  /* 快捷操作挪到左侧导航，首页宫格在电脑上不再重复显示 */
  #quickSection { display: none; }
  .sidebar { overflow-y: auto; }
  .sb-sub { padding: 4px 12px 6px; font-size: 11.5px; color: var(--ink-3); letter-spacing: 0.5px; }
  .sb-qitem { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 12px; border: 0; border-radius: 10px; background: none; font-size: 13.5px; color: var(--ink-2); text-align: left; cursor: pointer; }
  .sb-qitem svg { width: 18px; height: 18px; flex: 0 0 auto; }
  .sb-qitem:hover { background: #f6f7f9; }
  .sb-qitem.on { background: var(--red-soft); color: var(--red); font-weight: 700; }
}

/* 只在电脑端显示（手机 <1024px 隐藏）：适合「从别的平台导入」这类手机上做不了的操作 */
@media (max-width: 1023px) {
  .pc-only { display: none !important; }
}

/* ============ 新手教程页 ============ */
.guide-toc { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.guide-toc a { font-size: 12.5px; color: var(--red); background: var(--red-soft); border-radius: 999px; padding: 6px 12px; text-decoration: none; font-weight: 600; }
.guide-toc a:active { opacity: .7; }
.guide-list { display: flex; flex-direction: column; gap: 14px; }
.guide-step { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.guide-head { display: flex; gap: 10px; align-items: flex-start; }
.guide-no { flex: 0 0 26px; width: 26px; height: 26px; border-radius: 50%; background: linear-gradient(180deg, var(--red), var(--red-dark)); color: #fff; font-weight: 800; font-size: 14px; display: grid; place-items: center; }
.guide-title { font-size: 15.5px; font-weight: 800; color: var(--ink); }
.guide-goal { font-size: 12.5px; color: var(--ink-3); margin-top: 3px; line-height: 1.5; }
.guide-points { margin: 12px 0 0; padding-left: 18px; }
.guide-points li { font-size: 13.5px; line-height: 1.75; color: var(--ink-2); margin-bottom: 6px; }
.guide-points li b { color: var(--ink); }
.guide-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.guide-actions .btn { text-decoration: none; }
.guide-faq { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-top: 10px; }
.guide-faq summary { font-size: 13.5px; font-weight: 700; color: var(--ink); cursor: pointer; }
.guide-answer { font-size: 13px; line-height: 1.75; color: var(--ink-2); margin-top: 8px; }
/* ---------- iPhone「添加到主屏幕」引导条 ---------- */
.ios-install-tip {
  position: fixed; left: 0; right: 0; top: 0; z-index: 60;
  display: flex; align-items: flex-start; gap: 10px;
  padding: calc(8px + var(--safe-top, 0px)) 14px 10px;
  background: rgba(31, 35, 41, .95);
  color: #fff; font-size: 12.5px; line-height: 1.55;
  backdrop-filter: blur(6px);
}
.ios-install-tip .iit-text { flex: 1; }
.ios-install-tip .iit-close {
  flex: 0 0 auto; border: 0; background: transparent; color: #fff;
  font-size: 15px; line-height: 1; padding: 2px 4px; opacity: .75;
}