/* ============================================================
   球队管家 · 样式
   手机优先；≥920px 切换为左侧栏布局
   ============================================================ */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
:root {
  --bg: #f1f5f0;
  --card: #fff;
  --ink: #13211a;
  --muted: #6b7b72;
  --line: #e3e9e3;
  --green: #0f7a45;
  --green-d: #0a5731;
  --green-l: #e8f6ee;
  --gold: #e9a12a;
  --gold-l: #fdf3e0;
  --red: #d64c48;
  --red-l: #fdeceb;
  --blue: #2f6feb;
  --blue-l: #eaf0fe;
  --r: 16px;
  --shadow: 0 1px 2px rgba(16, 40, 26, .05), 0 10px 26px -18px rgba(16, 40, 26, .35);
}
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
a { color: var(--green); text-decoration: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
summary { cursor: pointer; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .92em; background: #eef3ee; padding: 1px 5px; border-radius: 5px; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #cdd8cf; border-radius: 8px; }

/* ---------------- 布局 ---------------- */
.shell { display: flex; min-height: 100vh; }
.sidebar { display: none; }
.main { flex: 1; min-width: 0; padding-bottom: 92px; }
.page { padding: 0 14px 26px; max-width: 780px; margin: 0 auto; }
@media (min-width: 920px) {
  .shell { max-width: 1180px; margin: 0 auto; gap: 28px; padding: 22px; }
  .sidebar { display: flex; flex-direction: column; width: 216px; flex: 0 0 216px; position: sticky; top: 22px; height: calc(100vh - 44px); }
  .main { padding-bottom: 24px; }
  .page { padding: 0 4px 24px; max-width: 840px; margin: 0; }
  .tabbar { display: none !important; }
  .appbar { display: none !important; }
  .banner { margin-top: 0; }
}

/* ---------------- 顶栏 ---------------- */
.appbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 8px;
  padding: 9px 12px; padding-top: max(9px, env(safe-area-inset-top));
  background: rgba(241, 245, 240, .9);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(227, 233, 227, .85);
}
.team-pill {
  display: inline-flex; align-items: center; gap: 7px; max-width: 70%; min-width: 0;
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 4px 10px 4px 5px; font-weight: 700; font-size: 13.5px; color: var(--ink);
}
.team-pill .dot { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 11px; font-weight: 800; flex: 0 0 22px; }
.team-pill .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-pill .caret { color: #a3b1a7; font-size: 10px; }
.icon-btn {
  width: 36px; height: 36px; flex: 0 0 36px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; display: grid; place-items: center; color: var(--ink);
}
.icon-btn:active { transform: scale(.95); }
.ic { display: inline-flex; align-items: center; justify-content: center; }
.ic svg { width: 20px; height: 20px; display: block; }

/* ---------------- 侧栏 ---------------- */
.side-brand { display: flex; align-items: center; gap: 10px; padding: 2px 6px 16px; }
.side-brand .logo { width: 40px; height: 40px; border-radius: 13px; background: linear-gradient(140deg, #16a35c, #0a5731); display: grid; place-items: center; font-size: 20px; }
.side-brand b { font-size: 17px; display: block; line-height: 1.2; }
.side-brand small { color: var(--muted); font-size: 11px; }
.side-teams { display: flex; flex-direction: column; gap: 3px; }
.side-team { display: flex; align-items: center; gap: 9px; padding: 7px 9px; border-radius: 11px; color: #3c4f44; font-size: 13.5px; font-weight: 600; }
.side-team:hover { background: #e8efe9; }
.side-team .dot { width: 24px; height: 24px; flex: 0 0 24px; border-radius: 8px; color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 800; }
.side-team .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-team .cur { font-size: 10px; color: var(--green); background: var(--green-l); padding: 1px 6px; border-radius: 6px; }
.side-team.on { background: #fff; box-shadow: var(--shadow); }
.side-empty { font-size: 12px; color: var(--muted); padding: 6px 9px; }
.side-sep { height: 1px; background: var(--line); margin: 12px 6px; }
.side-nav { display: flex; flex-direction: column; gap: 1px; }
.side-nav a { display: flex; align-items: center; gap: 11px; padding: 9px 11px; border-radius: 11px; color: #43544a; font-weight: 600; font-size: 14px; }
.side-nav a:hover { background: #e8efe9; }
.side-nav a.on { background: var(--green); color: #fff; box-shadow: 0 8px 18px -12px rgba(15, 122, 69, .95); }
.side-nav a svg { width: 19px; height: 19px; }
.side-foot { margin-top: auto; padding: 10px 8px 0; font-size: 11.5px; color: var(--muted); line-height: 1.6; }
.side-user { display: flex; align-items: center; justify-content: space-between; font-weight: 600; color: #43544a; margin-bottom: 2px; }
.side-user a { color: var(--red); font-weight: 600; }
.version { opacity: .8; }

/* ---------------- 底部导航 ---------------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; justify-content: space-around;
  background: rgba(255, 255, 255, .95);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-top: 1px solid var(--line);
  padding: 6px 2px calc(6px + env(safe-area-inset-bottom));
}
.tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 10.5px; color: #85968b; font-weight: 600; padding: 3px 9px; border-radius: 10px; }
.tabbar a svg { width: 21px; height: 21px; }
.tabbar a.on { color: var(--green); }
.tabbar a.on svg { transform: translateY(-1px); }

/* ---------------- 通用 ---------------- */
.card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid rgba(227, 233, 227, .7); overflow: hidden; }
.card + .card { margin-top: 12px; }
.card-b { padding: 14px 15px 15px; }
.card-b.tight { padding: 6px 12px 8px; }
.card-h { display: flex; align-items: center; gap: 8px; padding: 13px 15px 0; }
.sect { display: flex; align-items: baseline; gap: 8px; margin: 20px 3px 9px; }
.sect h2 { font-size: 16px; }
.sect .sp { flex: 1; }
.sect .more { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--line); background: #fff; color: var(--ink);
  border-radius: 12px; padding: 10px 14px; font-weight: 700; font-size: 14px;
  cursor: pointer; transition: transform .08s ease, background .15s ease;
  white-space: nowrap; text-decoration: none;
}
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--green); border-color: var(--green); color: #fff; box-shadow: 0 8px 18px -12px rgba(15, 122, 69, 1); }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--red); border-color: #f2cdcb; background: var(--red-l); }
.btn.sm { padding: 7px 11px; font-size: 12.5px; border-radius: 10px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: stretch; }
.btn-row > .btn { flex: 1 1 auto; }
.btn-row form { margin: 0; display: flex; }
.btn svg { width: 16px; height: 16px; }

.chip-row { display: flex; gap: 7px; overflow-x: auto; padding: 2px 2px 10px; scrollbar-width: none; }
.chip-row::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; border: 1px solid var(--line); background: #fff; color: #4c5e53;
  padding: 6px 13px; border-radius: 999px; font-size: 13px; font-weight: 700;
}
.chip.on { background: #16241c; border-color: #16241c; color: #fff; }

.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 7px; background: #eef2ee; color: #4f6156; white-space: nowrap; }
.tag.g { background: var(--green-l); color: var(--green-d); }
.tag.y { background: var(--gold-l); color: #9a6410; }
.tag.r { background: var(--red-l); color: #a83b37; }
.tag.b { background: var(--blue-l); color: #1e4fc4; }
.tag.on-dark { background: rgba(255, 255, 255, .18); color: #fff; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.mono { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }
.sp { flex: 1; }
.row { display: flex; align-items: center; gap: 10px; }
.wrap { flex-wrap: wrap; }
.ink { color: var(--ink); }
.req { color: var(--red); }

.avatar {
  width: 40px; height: 40px; border-radius: 50%; flex: 0 0 40px; display: grid; place-items: center;
  background: linear-gradient(145deg, #dcebe1, #c7ddce); color: var(--green-d);
  font-weight: 800; font-size: 16px; overflow: hidden; border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--line);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 60px; height: 60px; flex-basis: 60px; font-size: 22px; }
.avatar.xl { width: 86px; height: 86px; flex-basis: 86px; font-size: 32px; }
.avatar.sm { width: 26px; height: 26px; flex-basis: 26px; font-size: 11px; border-width: 1px; }
.person-chip { display: inline-flex; align-items: center; gap: 6px; background: #f6f9f6; border: 1px solid #eef2ee; border-radius: 999px; padding: 3px 10px 3px 3px; font-size: 12.5px; font-weight: 600; }
.person-chip .avatar { border: 0; box-shadow: none; }
.person-chip .ext { color: var(--muted); font-size: 10.5px; font-weight: 600; }

.empty { text-align: center; padding: 30px 16px; color: var(--muted); font-size: 13.5px; }
.empty b { display: block; color: var(--ink); font-size: 14.5px; margin-top: 2px; }
.empty .ico { font-size: 32px; opacity: .6; display: block; margin-bottom: 4px; }

.page-head { display: flex; align-items: center; gap: 8px; padding: 16px 2px 4px; }
.page-head h1 { font-size: 21px; letter-spacing: -.02em; }
.page-head .back { width: 32px; height: 32px; border-radius: 10px; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; color: var(--ink); flex: 0 0 32px; }
.page-head .back svg { width: 17px; height: 17px; }
.page-head .sp { flex: 1; }

.flash { border-radius: 12px; padding: 10px 13px; font-size: 13px; font-weight: 600; margin: 10px 0 2px; animation: fade .2s ease; }
.flash.ok { background: var(--green-l); color: var(--green-d); border: 1px solid #cbe8d7; }
.flash.err { background: var(--red-l); color: #a33; border: 1px solid #f3d2d0; }
@keyframes fade { from { opacity: 0; transform: translateY(-4px); } }

/* ---------------- 首页 ---------------- */
.banner {
  position: relative; margin: 12px 0 0; border-radius: 22px; padding: 19px 18px 17px;
  background: radial-gradient(120% 140% at 85% 0%, #18a95e 0%, #0e6f40 46%, #0a3f26 100%);
  color: #fff; box-shadow: 0 18px 36px -24px rgba(10, 63, 38, .95); overflow: hidden;
}
.banner::after {
  content: ""; position: absolute; right: -46px; top: -42px; width: 180px; height: 180px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .16);
  box-shadow: 0 0 0 26px rgba(255, 255, 255, .04), inset 0 0 0 1px rgba(255, 255, 255, .05);
}
.banner-top { display: flex; align-items: center; gap: 11px; position: relative; z-index: 1; }
.crest {
  width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-weight: 900; font-size: 20px;
  background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .25); flex: 0 0 46px; color: #fff;
}
.crest.sm { width: 36px; height: 36px; flex-basis: 36px; font-size: 16px; border-radius: 11px; }
.crest.lg { width: 64px; height: 64px; flex-basis: 64px; font-size: 26px; border-radius: 18px; }
.crest.has-logo, .dot.has-logo { background: #fff; overflow: hidden; }
.crest img, .dot img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: inherit; }
.banner h1 { font-size: 21px; letter-spacing: -.02em; line-height: 1.25; }
.banner .sub { font-size: 12px; opacity: .78; margin-top: 1px; }
.banner .record { display: flex; gap: 20px; margin-top: 15px; position: relative; z-index: 1; }
.banner .record div { font-size: 11px; opacity: .72; }
.banner .record b { display: block; font-size: 19px; opacity: 1; letter-spacing: -.02em; line-height: 1.2; }

.match-hero { border-radius: 18px; padding: 14px 15px 15px; background: #fff; box-shadow: var(--shadow); border: 1px solid var(--line); }
.match-hero .top { display: flex; align-items: center; gap: 8px; }
.countdown { color: var(--gold); font-size: 13px; }
.hero-vs { margin: 10px 0 2px; }
.hero-vs .nm { font-size: 18px; font-weight: 800; letter-spacing: -.02em; }
.hero-meta { font-size: 12px; color: var(--muted); margin-top: 2px; }
.progress { height: 7px; border-radius: 99px; background: #edf1ed; overflow: hidden; margin: 10px 0 6px; }
.progress > i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #16a35c, #0f7a45); }

.quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.quick-btn {
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 11px 4px 9px;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  font-size: 11.5px; font-weight: 700; color: #3c4f44;
}
.quick-btn:active { transform: scale(.96); }
.quick-btn .q { font-size: 18px; line-height: 1; }
.home-foot { text-align: center; font-size: 11.5px; color: var(--muted); margin: 22px 0 4px; }

/* 三步开张 */
.step-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px dashed #edf1ed; }
.step-row:last-child { border-bottom: 0; padding-bottom: 2px; }
.step-no { width: 24px; height: 24px; flex: 0 0 24px; border-radius: 50%; background: var(--green-l); color: var(--green-d); display: grid; place-items: center; font-size: 12px; font-weight: 800; }
.step-tx { flex: 1; min-width: 0; }
.step-tx b { display: block; font-size: 13.5px; }
.step-tx p { font-size: 11.5px; color: var(--muted); margin: 1px 0 0; line-height: 1.45; }

/* 使用说明 */
.help h3 { font-size: 14px; margin: 16px 0 3px; color: #1d2f24; }
.help h3:first-child { margin-top: 0; }
.help p { font-size: 13.5px; color: #4a5b50; margin: 0 0 3px; line-height: 1.6; }

/* ---------------- 比赛 ---------------- */
.match-row { display: flex; gap: 12px; padding: 12px 14px; border-bottom: 1px solid #eef2ee; align-items: center; color: var(--ink); }
.match-row:last-child { border-bottom: 0; }
.match-row:active { background: #f7faf7; }
.mdate { text-align: center; width: 42px; flex: 0 0 42px; }
.mdate b { display: block; font-size: 18px; line-height: 1.1; letter-spacing: -.03em; }
.mdate span { font-size: 10.5px; color: var(--muted); }
.mmain { flex: 1; min-width: 0; }
.mmain .t1 { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mmain .t2 { font-size: 11.5px; color: var(--muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.score-badge { font-weight: 800; font-size: 15px; padding: 3px 9px; border-radius: 9px; background: #eef2ee; color: #33443a; letter-spacing: -.02em; white-space: nowrap; }
.score-badge.w { background: var(--green-l); color: var(--green-d); }
.score-badge.l { background: var(--red-l); color: #a83b37; }
.score-badge.d { background: #eef2ee; color: #55665b; }
.score-badge.up { background: var(--blue-l); color: #1e4fc4; font-size: 12px; }
.score-badge.x { background: #eef2ee; color: #8b978e; font-size: 12px; }

.detail-hero { margin-top: 12px; border-radius: 20px; padding: 16px 16px 15px; color: #fff; background: radial-gradient(120% 130% at 80% 0%, #18a95e, #0c5a34 55%, #09331e 100%); box-shadow: 0 15px 32px -24px rgba(9, 51, 30, .9); }
.detail-hero .row { justify-content: center; }
.detail-hero .vs { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 14px 0 8px; }
.detail-hero .side { flex: 1; text-align: center; min-width: 0; }
.detail-hero .side .nm { font-weight: 800; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.detail-hero .num { font-size: 34px; font-weight: 900; letter-spacing: -.04em; line-height: 1; padding: 0 4px; }
.detail-hero .meta { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; font-size: 11.5px; opacity: .85; text-align: center; }

.kv { display: flex; gap: 10px; padding: 9px 0; border-bottom: 1px dashed #edf1ed; font-size: 13.5px; }
.kv:last-child { border-bottom: 0; }
.kv .k { color: var(--muted); width: 62px; flex: 0 0 62px; }
.kv .v { flex: 1; font-weight: 600; word-break: break-word; }

.signup-row { display: flex; align-items: center; gap: 9px; padding: 8px 0; border-bottom: 1px solid #f0f4f0; }
.signup-row:last-child { border-bottom: 0; }
.signup-row .nm { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seg-form { margin: 0; flex: 0 0 auto; }
.seg { display: inline-flex; background: #eef2ee; border-radius: 10px; padding: 2px; gap: 2px; }
.seg button { border: 0; background: transparent; border-radius: 8px; padding: 4px 8px; font-size: 11.5px; font-weight: 700; color: #66776c; cursor: pointer; }
.seg button.on.in { background: var(--green); color: #fff; }
.seg button.on.out { background: #f0b8b5; color: #8d2f2b; }
.seg button.on.maybe { background: var(--gold); color: #fff; }

.stat-head { display: grid; grid-template-columns: 1fr 50px 50px 40px; gap: 6px; font-size: 11px; color: var(--muted); padding-bottom: 4px; text-align: center; }
.stat-head .nm { text-align: left; padding-left: 2px; }
.plain-fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
fieldset[disabled] .stat-inputs { opacity: .8; }
.stat-inputs { display: grid; grid-template-columns: 1fr 50px 50px 40px; gap: 6px; align-items: center; padding: 5px 0; border-bottom: 1px solid #f4f7f4; }
.stat-inputs .nm { font-size: 13px; font-weight: 600; min-width: 0; display: flex; align-items: center; gap: 6px; overflow: hidden; }
.stat-inputs .nm span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stat-inputs .avatar { width: 26px; height: 26px; flex-basis: 26px; font-size: 11px; border-width: 1px; }
.stat-inputs input { width: 100%; border: 1px solid var(--line); border-radius: 9px; padding: 6px 2px; text-align: center; font-weight: 700; font-size: 16px; background: #fbfdfb; -moz-appearance: textfield; }
.stat-inputs input::-webkit-outer-spin-button, .stat-inputs input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stat-inputs input:focus { outline: 2px solid rgba(15, 122, 69, .18); border-color: var(--green); }
.stat-inputs .mvp { display: grid; place-items: center; }
.stat-inputs .mvp label { cursor: pointer; font-size: 17px; opacity: .3; filter: grayscale(1); }
.stat-inputs .mvp input { display: none; }
.stat-inputs .mvp input:checked + label { opacity: 1; filter: none; }

.fee-list { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 6px; }
.fee-row { margin: 0; }
.fee-btn { border: 1px solid var(--line); background: #fbfdfb; color: #67776c; border-radius: 999px; padding: 5px 11px; font-size: 12px; font-weight: 700; cursor: pointer; }
.fee-btn.on { background: var(--green-l); border-color: #c9e6d5; color: var(--green-d); }

/* 费用分摊名单 */
.fee-lines { margin-top: 10px; }
.fee-line { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed #edf1ed; font-size: 13.5px; }
.fee-line:last-child { border-bottom: 0; }
.fee-line .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.fee-line .nm i { font-style: normal; color: var(--gold); font-size: 12px; font-weight: 700; }
.fee-line .amt { font-weight: 800; }
.fee-line.paid .amt { color: var(--green-d); }
.fee-pick-list { margin-bottom: 10px; }
.fee-pick { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-bottom: 1px solid #f4f7f4; font-size: 13.5px; }
.fee-pick input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--green); flex: 0 0 auto; }
.fee-pick .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fee-pick input[type="number"] { width: 56px; text-align: center; border: 1px solid var(--line); border-radius: 8px; padding: 5px; font-weight: 700; font-size: 15px; background: #fbfdfb; }
.fee-pick .unit { color: var(--muted); font-size: 12px; }
.fee-custom { display: flex; gap: 8px; margin-top: 8px; }
.fee-custom .input { flex: 1; }
.fee-custom input[type="number"] { flex: 0 0 70px; text-align: center; }
.fee-editor summary { cursor: pointer; color: var(--green); font-weight: 700; font-size: 13px; margin-top: 14px; }
.player-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.fee-line .avatar, .fee-selected-row .avatar { width: 30px; height: 30px; flex-basis: 30px; font-size: 12px; }
.fee-pick .avatar { width: 30px; height: 30px; flex-basis: 30px; font-size: 12px; }
.leader-row .avatar { width: 28px; height: 28px; flex-basis: 28px; font-size: 11px; }
.fee-selected-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 6px 0 8px; }
.fee-selected-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid #f4f7f4; font-size: 13.5px; }
.fee-selected-row .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fee-selected-row input[type="number"] { width: 56px; text-align: center; border: 1px solid var(--line); border-radius: 8px; padding: 5px; font-weight: 700; font-size: 15px; background: #fbfdfb; }
.fee-selected-row .unit { color: var(--muted); font-size: 12px; }
.fee-remove { border: 0; background: #f3f5f3; color: #8a998f; width: 26px; height: 26px; border-radius: 50%; font-size: 15px; line-height: 1; cursor: pointer; flex: 0 0 26px; }
.fee-remove:hover { background: var(--red-l); color: var(--red); }
.fee-picker-dialog { width: min(480px, calc(100% - 32px)); max-height: 80vh; padding: 0; border: 0; border-radius: 20px; background: #fff; overflow: hidden; }
.fee-picker-dialog::backdrop { background: rgba(10, 24, 16, .45); }
.fee-picker-dialog.fallback-open { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 300; box-shadow: 0 20px 60px rgba(0, 0, 0, .35); }
.fee-picker { display: flex; flex-direction: column; max-height: 80vh; }
.fee-picker-h { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid #f0f4f0; }
.fee-picker-list { overflow-y: auto; padding: 4px 16px 16px; }
.fee-picker-list .fee-pick { padding: 9px 0; }
[hidden] { display: none !important; }
#fee, #invite { scroll-margin-top: 76px; }

.report-pre { margin: 12px 0 0; padding: 12px; background: #f7faf7; border: 1px dashed #dde7df; border-radius: 11px; font-size: 12.5px; line-height: 1.7; white-space: pre-wrap; word-break: break-word; font-family: inherit; color: #3c4f44; }

.upload-card summary { list-style: none; padding: 13px 15px; font-weight: 700; font-size: 13.5px; color: var(--green); }
.upload-card summary::-webkit-details-marker { display: none; }
.upload-card[open] summary { border-bottom: 1px solid #f0f4f0; }

/* ---------------- 成员 ---------------- */
.member-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 560px) { .member-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 920px) { .member-grid { grid-template-columns: repeat(4, 1fr); } }
.member-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 14px 10px 11px; text-align: center; position: relative; overflow: hidden; color: var(--ink); box-shadow: 0 1px 2px rgba(16, 40, 26, .03); }
.member-card:active { transform: scale(.98); }
.member-card .no { position: absolute; right: 8px; top: 5px; font-size: 21px; font-weight: 900; color: #edf2ee; letter-spacing: -.05em; }
.member-card .avatar { margin: 0 auto; }
.member-card .nm { font-weight: 700; font-size: 13.5px; margin-top: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member-card .pos { font-size: 11px; color: var(--muted); margin-top: 1px; }
.member-card .mini { display: flex; justify-content: center; gap: 10px; margin-top: 8px; font-size: 10px; color: var(--muted); }
.member-card .mini b { color: var(--ink); font-size: 12.5px; display: block; line-height: 1.15; }

.profile-hero { text-align: center; padding: 4px 0 2px; }
.profile-hero .avatar { margin: 0 auto; }
.profile-hero .nm { font-size: 19px; font-weight: 800; margin-top: 8px; }
.profile-hero .meta { font-size: 12.5px; color: var(--muted); margin-top: 3px; display: flex; align-items: center; justify-content: center; gap: 6px; flex-wrap: wrap; }
.avatar-edit { margin-top: 10px; }
.avatar-edit summary { display: inline-block; list-style: none; cursor: pointer; font-size: 12.5px; font-weight: 700; color: var(--green-d); background: var(--green-l); padding: 5px 13px; border-radius: 999px; }
.avatar-edit summary::-webkit-details-marker { display: none; }
.avatar-edit form { margin-top: 10px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.avatar-edit form .input { max-width: 250px; }
.profile-hero .avatar-edit form { justify-content: center; }
.stats-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 14px 0; }
.stats-4 div { background: #f6f9f6; border-radius: 12px; padding: 9px 4px; text-align: center; }
.stats-4 b { display: block; font-size: 16.5px; letter-spacing: -.02em; }
.stats-4 span { font-size: 10.5px; color: var(--muted); }
.badge-list { display: flex; flex-wrap: wrap; gap: 7px; justify-content: center; }
.badge-item { display: inline-flex; align-items: center; gap: 5px; background: var(--gold-l); color: #96610d; border-radius: 9px; padding: 4px 9px; font-size: 11.5px; font-weight: 700; }

/* ---------------- 榜单 ---------------- */
.leader-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; }
.rank { width: 24px; text-align: center; font-weight: 900; font-size: 14px; color: #9aa79f; flex: 0 0 24px; }
.rank.r1, .rank.r2, .rank.r3 { font-size: 16px; }
.leader-row .bar-wrap { flex: 1; min-width: 0; }
.leader-row .nm { font-size: 13px; font-weight: 700; display: flex; gap: 6px; align-items: center; }
.leader-row .nm .no { color: #9aa79f; font-weight: 600; font-size: 11px; }
.bar { height: 5px; background: #eef2ee; border-radius: 99px; margin-top: 5px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, #1db268, #0f7a45); border-radius: 99px; }
.leader-row .val { font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; }
.leader-row .val .unit { font-size: 10.5px; color: var(--muted); font-weight: 600; margin-left: 2px; }
.record-line { display: flex; gap: 14px; justify-content: center; font-size: 12.5px; font-weight: 700; margin-top: 12px; }
.record-line .w { color: var(--green); }
.record-line .d { color: var(--muted); }
.record-line .l { color: var(--red); }

/* ---------------- 相册 ---------------- */
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.video-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.video-cell { position: relative; }
.video-card { display: block; border-radius: 12px; overflow: hidden; background: #151a16; }
.vcover { position: relative; aspect-ratio: 16 / 9; background: linear-gradient(135deg, #26322b, #101512); background-size: cover; background-position: center; display: flex; align-items: center; justify-content: center; }
.vplay { width: 46px; height: 46px; border-radius: 50%; background: rgba(0, 0, 0, .55); color: #fff; display: grid; place-items: center; font-size: 18px; }
.vsource { position: absolute; right: 6px; bottom: 6px; display: flex; align-items: center; justify-content: center; padding: 3px 4px; border-radius: 6px; background: rgba(255, 255, 255, .92); box-shadow: 0 1px 4px rgba(0, 0, 0, .35); }
.vsource.text { padding: 2px 7px; color: #fff; font-size: 10px; font-weight: 700; }
.vlogo { height: 16px; width: auto; display: block; }
.vcap { position: absolute; left: 8px; right: 58px; bottom: 6px; color: #fff; font-size: 12px; font-weight: 600; text-shadow: 0 1px 4px rgba(0, 0, 0, .8); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.photo-cell { position: relative; }
.photo-cell .photo { width: 100%; }
.photo-del { position: absolute; top: 6px; right: 6px; margin: 0; z-index: 3; }
.photo-del-btn { width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: rgba(0, 0, 0, .55); color: #fff; font-size: 16px; line-height: 1; display: grid; place-items: center; cursor: pointer; }
.viewer-page { position: fixed; inset: 0; z-index: 80; background: #000; color: #fff; overflow: hidden; }
.viewer-top { position: absolute; top: 0; left: 0; right: 0; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: linear-gradient(rgba(0, 0, 0, .65), transparent); }
.viewer-cap { flex: 1; min-width: 0; font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.viewer-actions { display: flex; align-items: center; gap: 8px; }
.viewer-btn { display: inline-flex; align-items: center; justify-content: center; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .28); background: rgba(255, 255, 255, .12); color: #fff; font-size: 12px; font-weight: 600; text-decoration: none; }
.viewer-btn.close { width: 34px; padding: 0; font-size: 20px; line-height: 1; }
.viewer-stage { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; touch-action: none; cursor: grab; }
.viewer-stage:active { cursor: grabbing; }
.viewer-stage img { max-width: 100%; max-height: 100%; transform-origin: center center; will-change: transform; user-select: none; -webkit-user-drag: none; }
.viewer-hint { position: absolute; color: #7f8c84; font-size: 13px; }
.viewer-video { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.viewer-video .vplay { font-size: 46px; }
@media (min-width: 560px) { .photo-grid { grid-template-columns: repeat(4, 1fr); gap: 7px; } }
.photo { position: relative; border-radius: 10px; overflow: hidden; background: #e6ece7; aspect-ratio: 1/1; display: block; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 6px 4px; font-size: 10px; color: #fff; background: linear-gradient(transparent, rgba(0, 0, 0, .55)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.photo .vplay { position: absolute; inset: 0; display: grid; place-items: center; font-size: 26px; color: #fff; text-shadow: 0 2px 10px rgba(0, 0, 0, .5); }
.photo.ext { display: grid; place-items: center; background: linear-gradient(145deg, #e9f1ea, #d9e5dc); }
.photo.ext .pico { font-size: 26px; color: #6b7b72; }
.photo .vtag { position: absolute; top: 6px; left: 6px; padding: 2px 6px; border-radius: 6px; background: rgba(0, 0, 0, .55); color: #fff; font-size: 10px; font-weight: 700; }
.admin-media { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid #f0f4f0; }
.admin-media:last-child { border-bottom: 0; }
.admin-media .t { flex: 1; min-width: 0; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-media form { margin: 0; }

/* ---------------- 表单 ---------------- */
.field { margin-bottom: 12px; }
.label { display: block; font-size: 12px; font-weight: 700; color: #59695f; margin-bottom: 5px; }
.input, .select, .textarea {
  width: 100%; border: 1px solid var(--line); background: #fbfdfb; border-radius: 11px;
  padding: 10px 12px; font-size: 16px; outline: none; transition: border .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
.select { background-image: linear-gradient(45deg, transparent 50%, #8b9a90 50%), linear-gradient(135deg, #8b9a90 50%, transparent 50%); background-position: calc(100% - 17px) 18px, calc(100% - 12px) 18px; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 30px; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(15, 122, 69, .12); background-color: #fff; }
.textarea { min-height: 72px; resize: vertical; }
.file-input { padding: 8px 10px; font-size: 13px; }
input[type="color"].input { padding: 4px; height: 42px; }
.hint { font-size: 11.5px; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.three { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
@media (max-width: 380px) { .three { grid-template-columns: 1fr 1fr; } }

/* ---------------- 球队 ---------------- */
.team-row { display: flex; align-items: center; gap: 10px; padding: 11px 13px; border-bottom: 1px solid #f0f4f0; color: var(--ink); }
.team-row:last-child { border-bottom: 0; }
.team-row.on { background: #f7fbf8; }
.team-row .tx { flex: 1; min-width: 0; }
.team-row .tx b { display: block; font-size: 14px; }
.team-row .tx span { font-size: 11.5px; color: var(--muted); }
.team-row .ar { color: #b9c6bd; font-size: 17px; }
.invite-box { text-align: center; padding: 6px 0 2px; }
.invite-code { font-size: 30px; font-weight: 900; letter-spacing: .16em; color: var(--green-d); margin: 6px 0 10px; }
.list-line { display: flex; align-items: center; gap: 11px; padding: 12px 14px; border-bottom: 1px solid #f0f4f0; color: var(--ink); }
.list-line:last-child { border-bottom: 0; }
.list-line:active { background: #f7faf7; }
.list-line .ic { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: var(--green-l); font-size: 16px; flex: 0 0 34px; }
.list-line .tx { flex: 1; min-width: 0; }
.list-line .tx b { display: block; font-size: 13.5px; font-weight: 700; }
.list-line .tx span { font-size: 11.5px; color: var(--muted); }
.list-line .ar { color: #b9c6bd; font-size: 17px; }

/* ---------------- 杂项 ---------------- */
.notice { background: var(--blue-l); color: #1d47b8; border-radius: 12px; padding: 10px 12px; font-size: 12.5px; line-height: 1.55; }
.notice.g { background: var(--green-l); color: var(--green-d); }
.notice.y { background: var(--gold-l); color: #8d5c0c; }
.diag { font-size: 12.5px; }
.diag div { padding: 7px 0; border-bottom: 1px dashed #eef2ee; display: flex; gap: 8px; }
.diag div:last-child { border-bottom: 0; }
.diag .ok { color: var(--green); font-weight: 900; }
.diag .no { color: var(--red); font-weight: 900; }
.link-summary { font-size: 13px; font-weight: 700; color: var(--green); }
.poster-box { display: flex; justify-content: center; padding: 6px 0 10px; }
.poster-box img { width: 100%; max-width: 300px; border-radius: 14px; box-shadow: 0 14px 30px -18px rgba(0, 0, 0, .5); }

/* ---------------- 登录页 ---------------- */
.auth-body { background: radial-gradient(120% 90% at 50% 0%, #e5f2e9 0%, #f1f5f0 55%); }
.auth { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 26px 18px 34px; }
.auth-brand { text-align: center; margin-bottom: 18px; }
.auth-ball { display: block; font-size: 40px; line-height: 1; margin-bottom: 6px; }
.auth-brand b { display: block; font-size: 22px; letter-spacing: -.02em; }
.auth-brand small { color: var(--muted); font-size: 12px; }
.auth-card { width: 100%; max-width: 390px; background: #fff; border-radius: 22px; padding: 22px 20px 20px; box-shadow: 0 20px 50px -30px rgba(16, 40, 26, .55); border: 1px solid rgba(227, 233, 227, .9); }
.auth-title { font-size: 20px; }
.auth-sub { font-size: 12.5px; color: var(--muted); margin: 3px 0 16px; }
.auth-submit { margin-top: 6px; padding: 12px; }
.auth-links { text-align: center; font-size: 12.5px; color: var(--muted); margin-top: 16px; }
.auth-links a { font-weight: 700; }
.dot-sep { margin: 0 6px; color: #c6d2c9; }
.auth-sep { height: 1px; background: var(--line); margin: 14px 0; }
.auth-foot { margin-top: 18px; font-size: 11px; color: var(--muted); }
.auth.top { justify-content: flex-start; padding-top: 34px; }
.auth-card.wide { max-width: 720px; padding: 20px 18px; }
.join-team { display: flex; align-items: center; gap: 11px; padding: 12px; background: #f6f9f6; border-radius: 14px; margin-bottom: 12px; }
.join-team b { font-size: 15px; }
.join-team .crest { width: 42px; height: 42px; flex-basis: 42px; font-size: 18px; border-radius: 12px; }

/* ---------------- Toast ---------------- */
#toast-root { position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 7px; align-items: center; pointer-events: none; width: max-content; max-width: 88vw; }
.toast { background: rgba(20, 34, 26, .94); color: #fff; padding: 9px 16px; border-radius: 12px; font-size: 13px; font-weight: 600; box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .5); animation: tin .18s ease; }
@keyframes tin { from { opacity: 0; transform: translateY(8px); } }

/* ---------------- 弹窗 ---------------- */
.modal-mask { position: fixed; inset: 0; background: rgba(10, 24, 16, .5); z-index: 100; display: flex; align-items: flex-end; justify-content: center; animation: fade .16s ease; }
@media (min-width: 560px) { .modal-mask { align-items: center; padding: 20px; } }
.modal { background: #fff; width: 100%; max-width: 480px; max-height: 92vh; display: flex; flex-direction: column; border-radius: 20px 20px 0 0; animation: up .2s cubic-bezier(.2, .8, .3, 1); }
@media (min-width: 560px) { .modal { border-radius: 20px; max-height: 86vh; } }
.modal-head { display: flex; align-items: center; gap: 10px; padding: 13px 15px 10px; border-bottom: 1px solid #f0f4f0; }
.modal-head h3 { font-size: 15.5px; flex: 1; }
.modal-body { padding: 14px 16px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.modal-foot { padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid #f0f4f0; display: flex; gap: 9px; }
.modal-foot .btn { flex: 1; padding: 11px; }
@keyframes up { from { transform: translateY(26px); opacity: .6; } }
