:root {
  --bg: #f4f6f2;
  --card: #ffffff;
  --ink: #14201a;
  --ink-2: #3d4f45;
  --muted: #7d8d83;
  --line: #e3e8e0;
  --primary: #1c6b4a;
  --primary-soft: #e6f1ea;
  --accent: #c9f13c;
  --gold: #d9a838;
  --silver: #98a3a8;
  --bronze: #b5794b;
  --up: #c0392b;
  --down: #1e8449;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(20, 32, 26, .04), 0 8px 24px -12px rgba(20, 32, 26, .18);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
  padding-bottom: calc(72px + env(safe-area-inset-bottom));
}

.shell {
  max-width: 480px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ---------- header ---------- */
.appbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: linear-gradient(180deg, var(--bg) 70%, rgba(244, 246, 242, 0));
  padding: 18px 0 10px;
}
.appbar-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand-mark {
  width: 34px; height: 34px;
  border-radius: 11px;
  background: var(--primary);
  display: grid; place-items: center;
  flex: none;
}
.brand-mark svg { width: 19px; height: 19px; }
.brand-title { font-size: 17px; font-weight: 700; letter-spacing: -.2px; }
.brand-sub { font-size: 11.5px; color: var(--muted); margin-top: -1px; letter-spacing: .3px; }

.icon-btn {
  width: 36px; height: 36px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--card);
  display: grid; place-items: center;
  color: var(--ink-2);
  cursor: pointer;
  flex: none;
}
.icon-btn:active { transform: scale(.95); }
.icon-btn svg { width: 17px; height: 17px; }

/* ---------- section ---------- */
.sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 22px 2px 10px;
}
.sec-title { font-size: 13px; font-weight: 700; letter-spacing: .6px; color: var(--ink-2); }
.sec-note { font-size: 12px; color: var(--muted); }

/* ---------- segmented ---------- */
.seg {
  display: flex;
  gap: 4px;
  background: #e9ede6;
  padding: 4px;
  border-radius: 13px;
  margin-bottom: 14px;
}
.seg button {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 8px 6px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-2);
  font-family: inherit;
  cursor: pointer;
  transition: background .16s, color .16s, box-shadow .16s;
}
.seg button.on {
  background: var(--card);
  color: var(--primary);
  box-shadow: 0 1px 3px rgba(20, 32, 26, .1);
}

/* ---------- ranking list ---------- */
.rank-row {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card);
  border-radius: var(--radius);
  padding: 12px 14px;
  box-shadow: var(--shadow);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .12s;
}
.rank-row:active { transform: scale(.99); }

.rank-row.top1 { border-color: rgba(217, 168, 56, .45); background: linear-gradient(105deg, #fffdf6, #fff 55%); }
.rank-row.top2 { border-color: rgba(152, 163, 168, .4); }
.rank-row.top3 { border-color: rgba(181, 121, 75, .35); }

.rank-no {
  width: 24px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  flex: none;
}
.rank-row.top1 .rank-no { color: var(--gold); }
.rank-row.top2 .rank-no { color: var(--silver); }
.rank-row.top3 .rank-no { color: var(--bronze); }

.rank-desk {
  --rank-court: #102f25;
  --rank-subtle: #53675b;
  margin: 14px 0 24px;
}
.rank-title {
  margin: 0 0 12px;
  font-size: clamp(23px, 5vw, 32px);
  line-height: 1.22;
  letter-spacing: -.04em;
}
.rank-board { margin-top: 22px; }
.rank-board-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 0 2px 12px;
}
.rank-board-head h2 { margin: 0; font-size: clamp(18px, 4vw, 23px); letter-spacing: -.035em; }
.rank-board-note { margin: 9px 2px 0; color: var(--rank-subtle); font-size: 11px; }
.rank-unranked { margin-top: 12px; }
.rank-unranked summary { padding: 9px 2px; color: var(--primary); font-size: 13px; font-weight: 600; cursor: pointer; }
.rank-unranked ul { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 4px 0 0; }
.rank-unranked a { display: block; padding: 8px 11px; border-radius: 9px; border: 1px solid var(--line); background: var(--card); color: var(--ink); font-size: 13px; }
.rank-count { flex: none; font-size: 11px; color: var(--rank-subtle); white-space: nowrap; }
.rank-count strong { color: var(--ink); font-size: 19px; font-variant-numeric: tabular-nums; margin-right: 2px; }

.reward-entry {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-top: 11px; padding: 10px 12px;
  border: 1px solid #dedbc9; border-radius: 11px;
  color: #234334; background: #f8f6ec; text-decoration: none; font-size: 14px;
}
.reward-entry small, .reward-list small, .reward-week small {
  display: block; margin-top: 2px; font-size: 11.5px; font-weight: 400;
}
.reward-entry small { color: #5e675b; }
.reward-entry > span:last-child { font-size: 17px; }
.reward-club-select { display: grid; gap: 5px; margin-bottom: 12px; font-size: 13px; }
.reward-navigation { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.reward-card, .reward-pool { margin-bottom: 12px; }
.reward-card header, .reward-pool header {
  display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 5px 10px;
}
.reward-card header h2, .reward-pool header h2 { margin: 0; font-size: 17px; }
.reward-card header > span, .reward-pool header > span { font-size: 12px; }
.reward-card p, .reward-pool p { margin: 8px 0 0; font-size: 13px; }
.reward-card p, .reward-card header > span, .reward-week small, .reward-list small { color: var(--ink-2); }
.card.reward-pool { color: #eaf7ec; background: #12342a; }
.reward-pool header strong { color: #e0f18a; font-size: 23px; font-variant-numeric: tabular-nums; }
.reward-pool p, .reward-pool header > span, .reward-pool .reward-list small { color: #d4e7db; }
.reward-item-amount { text-align: right; }
.reward-item-amount b { color: #e0f18a; }
.reward-list { margin: 7px 0 0; padding: 0; list-style: none; }
.reward-list li {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, max-content);
  align-items: center; gap: 9px; padding: 8px 0;
  border-bottom: 1px solid var(--line); overflow-wrap: anywhere; font-size: 13px;
}
.reward-list li:last-child { border-bottom: 0; }
.reward-pool li { border-color: #416559; }
.reward-list li > span:last-child { text-align: right; }
.reward-inventory-controls {
  grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 5px 8px;
}
.reward-inventory-controls label, .reward-auto-toggle {
  display: inline-flex; align-items: center; gap: 5px; min-height: 32px; font-size: 13px;
}
.reward-inventory-controls label { margin-right: auto; white-space: nowrap; }
.reward-inventory-controls select {
  width: auto; min-height: 32px; padding: 3px 5px; border: 1px solid #719386; border-radius: 7px;
  background: #21483a; color: #f1faef; font: inherit;
}
.reward-auto-toggle input {
  width: 16px; height: 16px; margin: 0; accent-color: var(--primary);
}
.reward-auto-toggle { margin-top: 8px; font-weight: 650; }
.reward-week {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .9fr);
  gap: 7px 14px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.reward-week:last-child { border-bottom: 0; }
.reward-week-prize { text-align: right; color: var(--primary); font-size: 14px; }
.reward-balances { margin-bottom: 8px; }
.reward-balances + .reward-list { border-top: 1px solid var(--line); }
.reward-card .label, .reward-card .btn { margin-top: 10px; }
.reward-admin-link { display: inline-block; margin-top: 5px; font-size: 13px; color: var(--primary); }
.reward-profile { margin-top: 12px; }
.maintenance-details > summary { cursor: pointer; font-size: 16px; font-weight: 750; }
.maintenance-details > summary small { margin-left: 6px; color: var(--ink-2); font-size: 12px; font-weight: 500; }
.maintenance-details[open] > summary { margin-bottom: 12px; }
.club-admin-row { padding: 13px 0; border-bottom: 1px solid var(--line); }
.club-admin-row:last-child { border-bottom: 0; padding-bottom: 0; }
.club-admin-row h3 { margin: 0 0 8px; font-size: 15px; overflow-wrap: anywhere; }
.club-admin-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.club-admin-actions a {
  background: #edf5ef; border-radius: 9px; padding: 8px 10px; margin-top: 0; font-weight: 700; text-decoration: none;
}
.club-invite-details { margin-top: 10px; font-size: 13px; }
.club-invite-details > summary { cursor: pointer; color: var(--ink-2); }
.club-code-input { display: flex; gap: 8px; }
.club-code-input input { min-width: 0; }
.club-code-input button { flex-shrink: 0; }
.operations-card { margin-bottom: 12px; }
.operations-card h2, .club-finance h2, .club-resources h2 { margin: 0; font-size: 17px; }
.operations-card h2 small { float: right; font-size: 13px; font-weight: 500; color: var(--ink-2); }
.ops-row header { display: flex; gap: 8px; justify-content: space-between; flex-wrap: wrap; align-items: baseline; }
.card.club-finance { padding: 0; overflow: hidden; }
.club-finance > header { padding: 16px; color: #eff8ed; background: #16372c; }
.cash-balance { display: flex; gap: 8px; align-items: baseline; margin-top: 8px; }
.cash-balance strong { color: #dcf49a; font-size: clamp(24px, 6vw, 34px); line-height: 1.25; }
.club-finance strong, .resource-line strong { font-variant-numeric: tabular-nums; }
.cash-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 12px 14px 0; }
.cash-switch button { padding: 9px 8px; color: var(--ink-2); background: #f5f7f3; border: 1px solid transparent;
  border-radius: 9px; text-align: left; font: inherit; cursor: pointer; min-width: 0; }
.cash-switch button[aria-pressed="true"] { color: #14583e; border-color: #82a995; background: #ecf5ee; }
.cash-switch span { font-size: 12px; }
.cash-switch strong { display: block; font-size: clamp(15px, 4.2vw, 21px); overflow-wrap: anywhere; }
#finance-detail { padding: 8px 16px 14px; }
#finance-detail .card { margin: 0; padding: 0; box-shadow: none; border: 0; }
#finance-detail h2 { font-size: 14px; margin-top: 4px; }
.ledger-budget { margin: 0 16px 14px; font-size: 13px; }
.ledger-budget summary { cursor: pointer; }
.ledger-more { border-top: 1px solid var(--line); margin-top: 10px; }
.ledger-more summary { padding-top: 10px; color: var(--primary); cursor: pointer; font-size: 13px; }
.ledger-more .card h2 { display: none; }
.club-resources { margin: 16px 0; }
.club-resources h2 { margin-bottom: 8px; }
.card.resource-list { padding: 0 15px; margin: 0; }
.resource-line + .resource-line { border-top: 1px solid var(--line); }
.resource-line summary, .resource-prizes { display: grid; grid-template-columns: minmax(0,1fr) auto 8px; gap: 9px;
  align-items: center; padding: 13px 0; min-height: 44px; cursor: pointer; color: var(--ink); text-decoration: none; }
.resource-line summary { list-style: none; }
.resource-line summary::-webkit-details-marker { display: none; }
.resource-line summary::after, .resource-prizes::after { content: ''; width: 6px; height: 6px; border: solid var(--ink-2); border-width: 1.5px 1.5px 0 0; transform: rotate(45deg); }
.resource-line[open] summary::after { transform: rotate(135deg); }
.resource-line span { font-weight: 650; overflow-wrap: anywhere; }
.resource-line small { display: block; color: var(--ink-2); font-size: 12px; font-weight: 400; margin-top: 3px; }
.resource-line .ops-row { padding: 9px 0; font-size: 13px; }
.stock-by-type { margin: 0; padding: 8px 12px; background: #eff5ef; border-radius: 8px; list-style: none; }
.stock-by-type li { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; }
.resource-empty { font-size: 13px; color: var(--ink-2); margin: 0; padding-bottom: 12px; }
.ball-spec-fields, .payment-choice { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
.event-resources { margin: 14px 0 0; border: 1px solid var(--line); padding: 10px 12px; min-width: 0; border-radius: 10px; }
.event-resources legend { font-weight: 700; }
.event-resources .label { margin: 7px 0 3px; }
.payment-choice label, .ball-check { display: flex; align-items: center; gap: 6px; min-height: 38px; cursor: pointer; }
.event-resources input[type=radio], .ball-check input { accent-color: var(--primary); }
.event-resources > small { display: block; margin-top: 6px; color: var(--ink-2); }
.resource-moves > summary { cursor: pointer; color: var(--primary); font-size: 14px; font-weight: 700; }
.operations-card label, .operations-card .btn { margin-top: 10px; }
.operations-card p { font-size: 13px; margin: 6px 0; }
.ops-attendance { padding: 10px; margin: 10px 0 0; min-width: 0; border: 1px solid var(--line); border-radius: 10px; }
.ops-attendance legend { font-size: 13px; font-weight: 700; }
.ops-roster { max-height: 270px; overflow-y: auto; }
.ops-player { padding: 4px 0; border-bottom: 1px solid var(--line); }
.ops-player:last-child { border-bottom: 0; }
.ops-player .ops-player-check { display: flex; align-items: center; gap: 6px; margin: 0; min-height: 30px; font-size: 14px; }
.ops-player [data-ops-plan]:not([hidden]) { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 6px; }
.ops-player .input { min-width: 0; }
.ops-row { padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; overflow-wrap: anywhere; }
.ops-row:last-child { border-bottom: 0; padding-bottom: 0; }
.ops-row small { color: var(--ink-2); }
.ops-row details { margin: 5px 0; font-size: 13px; }
.ops-row .mini-btn { margin-top: 6px; }
.club-tools { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 16px; margin: 0 0 12px; }
.club-tools a { color: var(--primary); font-size: 14px; }
.club-invite { margin-top: 16px; }
.club-invite .input { margin-top: 10px; }
.club-member { border-bottom: 1px solid var(--line); padding: 10px 0; overflow-wrap: anywhere; }
.club-member summary { cursor: pointer; }
.club-member small { display: block; color: var(--ink-2); }
.club-member h3 { font-size: 14px; margin: 10px 0 4px; }
.club-member ul { padding-left: 18px; margin: 4px 0; font-size: 14px; }
.club-member li + li { margin-top: 6px; }
.ops-voided header { text-decoration: line-through; }

.rank-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 3px;
  padding: 4px;
  margin-bottom: 9px;
  border: 1px solid #dfe7de;
  border-radius: 11px;
  background: #eaf0e8;
}
.rank-tab {
  min-height: 36px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-2);
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}
.rank-tab[aria-pressed="true"] { background: var(--rank-court); color: #fff; }
.rank-desk button:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; }

.rank-feature {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(8px, 2vw, 14px);
}
.rank-spotlight {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  box-sizing: border-box;
  min-width: 0;
  padding: clamp(10px, 3vw, 21px);
  border: 1px solid transparent;
  border-radius: 14px;
  font: inherit;
  text-align: left;
  box-shadow: 0 6px 16px rgba(16, 47, 37, .1);
}
button.rank-spotlight { cursor: pointer; }
.rank-spotlight-history {
  --spotlight-note: #d4e6da;
  --spotlight-number: #ddf77c;
  color: #fff;
  border-color: #234d3b;
  background: linear-gradient(145deg, #12362a, #0c231c 78%);
}
.rank-spotlight-week {
  --spotlight-note: #304420;
  --spotlight-number: #10280e;
  color: #162b14;
  border-color: #b6d44e;
  background: linear-gradient(145deg, #e6f799, #c4eb57 78%);
}
.rank-spotlight::before {
  content: '';
  position: absolute;
  z-index: -1;
  pointer-events: none;
}
.rank-spotlight-history::before {
  width: 74%;
  min-width: 115px;
  aspect-ratio: 1.56;
  top: 9%;
  right: -23%;
  transform: rotate(-26deg);
  border: 1px solid rgba(221, 247, 124, .24);
  background:
    linear-gradient(rgba(221, 247, 124, .21), rgba(221, 247, 124, .21)) 50% 23% / 100% 1px no-repeat,
    linear-gradient(rgba(221, 247, 124, .21), rgba(221, 247, 124, .21)) 50% 77% / 100% 1px no-repeat,
    linear-gradient(90deg, transparent 49%, rgba(221, 247, 124, .21) 50%, transparent 51%);
}
.rank-spotlight-week::before {
  width: 100%;
  height: 155%;
  top: -32%;
  right: -49%;
  transform: rotate(20deg);
  background: repeating-linear-gradient(90deg, transparent 0 9px, rgba(47, 80, 14, .11) 9px 11px, transparent 11px 16px);
  mask-image: linear-gradient(90deg, transparent, #000 40%);
}
.rank-spotlight-top, .rank-spotlight-person { display: flex; align-items: center; }
.rank-spotlight-top { justify-content: space-between; gap: 3px; min-height: 22px; }
.rank-spotlight-title { font-size: clamp(12px, 3.35vw, 16px); font-weight: 750; white-space: nowrap; }
.rank-spotlight-link {
  display: grid;
  place-items: center;
  flex: none;
  width: 22px;
  height: 22px;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 13px;
  line-height: 1;
}
.rank-spotlight-score {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin: 6px 0 10px;
  color: var(--spotlight-number);
  font-size: clamp(29px, 8.7vw, 62px);
  font-weight: 820;
  line-height: 1;
  letter-spacing: -.075em;
  font-variant-numeric: tabular-nums;
}
.rank-spotlight-unit { font-size: 11px; font-weight: 650; letter-spacing: 0; }
.rank-spotlight-person { gap: 6px; min-height: 28px; }
.rank-spotlight-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: clamp(14px, 4vw, 21px); font-weight: 750; }
.rank-spotlight-period { margin-top: 5px; color: var(--spotlight-note); font-size: clamp(10px, 2.8vw, 12px); font-variant-numeric: tabular-nums; }
.rank-spotlight.is-empty .rank-spotlight-name { color: var(--spotlight-note); font-size: 12px; font-weight: 600; }

.rank-desk .rank-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) minmax(62px, auto);
  grid-template-areas: "pos person score" "pos record score";
  align-content: center;
  gap: 3px 8px;
  width: 100%;
  min-width: 0;
  font: inherit;
  text-align: left;
  color: inherit;
}
.rank-desk .rank-no {
  grid-area: pos;
  width: auto;
  text-align: left;
  color: var(--rank-subtle);
  font-size: 13px;
}
.rank-desk .rank-person { grid-area: person; min-width: 0; display: flex; align-items: center; gap: 8px; }
.rank-desk .who-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-desk .who-meta {
  grid-area: record;
  min-width: 0;
  color: var(--rank-subtle);
  white-space: normal;
  overflow: visible;
  overflow-wrap: anywhere;
  font-size: 11px;
}
.rank-desk .rank-win { display: inline-block; white-space: nowrap; }
.rank-desk .avatar { width: 28px; height: 28px; border-radius: 7px; font-size: 12px; flex: none; }
.rank-desk .points { grid-area: score; display: grid; justify-items: end; gap: 2px; margin: 0; line-height: 1.15; }
.rank-desk .rank-score { display: flex; align-items: baseline; gap: 3px; }
.rank-desk .points-val { color: var(--ink); font-variant-numeric: tabular-nums; font-size: 19px; }
.rank-desk .rank-score-unit { font-size: 10.5px; color: var(--rank-subtle); }
.rank-desk .points-delta { font-variant-numeric: tabular-nums; font-size: 10.5px; font-weight: 650; white-space: nowrap; }
.rank-desk .points-delta.up { color: #236249; }
.rank-desk .points-delta.down { color: #a24531; }

.rank-table {
  overflow: visible;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--card);
}
.rank-table-head {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  gap: 8px;
  padding: 8px 11px;
  color: var(--rank-subtle);
  background: #eaf0e8;
  border-radius: 10px 10px 0 0;
  font-size: 11px;
  font-weight: 650;
}
.rank-desk .rank-table-row { padding: 8px 11px; border: 0; border-top: 1px solid var(--line); border-radius: 0; box-shadow: none; }
.rank-desk .rank-first { background: #f4f8ef; }
.rank-desk .rank-first .rank-no { color: var(--primary); }
.rank-desk .rank-table-row:last-child { border-radius: 0 0 10px 10px; }
.rank-table-row .who-meta { padding-left: 36px; }
.rank-desk .rank-table-row:focus-visible { position: relative; z-index: 1; outline-offset: -2px; }
.rank-empty { padding: 22px 16px; border: 1px dashed #b8cbbf; border-radius: 11px; background: var(--card); color: var(--ink-2); }
.rank-empty p { margin: 6px 0 11px; color: var(--rank-subtle); font-size: 13px; }

@media (min-width: 680px) {
  .shell:has(> .rank-desk) { max-width: 748px; }
  .rank-spotlight-score { margin-top: 12px; }
}
@media (hover: hover) {
  .rank-desk .rank-table-row:hover { background: #eaf2e8; }
  .rank-tab:hover:not([aria-pressed="true"]) { background: #f5f8f4; }
  .rank-spotlight:hover .rank-spotlight-link { color: #fff; background: #234d3b; border-color: #234d3b; }
}
@media (prefers-reduced-motion: no-preference) {
  .rank-feature-refresh .rank-spotlight { animation: rank-arrive .42s cubic-bezier(.2, .75, .25, 1) both; }
  .rank-feature-refresh .rank-spotlight-week { animation-delay: .08s; }
  .rank-feature-refresh .rank-spotlight-score { animation: rank-reveal .6s ease-out both; }
  .rank-feature-refresh .rank-spotlight-week .rank-spotlight-score { animation-delay: .08s; }
  .rank-spotlight-link { transition: background-color .18s, color .18s, border-color .18s; }
}
@keyframes rank-arrive {
  from { opacity: .35; transform: translateY(9px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes rank-reveal {
  from { clip-path: inset(0 100% 0 0); }
  to { clip-path: inset(0); }
}

.avatar {
  width: 40px; height: 40px;
  border-radius: 13px;
  display: grid; place-items: center;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  flex: none;
  letter-spacing: -.5px;
}

.who { flex: 1; min-width: 0; }
.who-name {
  font-size: 15px;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.who-meta {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.points { text-align: right; flex: none; }
.points-val {
  font-size: 17px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  letter-spacing: -.4px;
}
.points-delta {
  font-size: 11px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.points-delta.up { color: var(--up); }
.points-delta.down { color: var(--down); }

/* ---------- cards / forms ---------- */
.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.card + .card { margin-top: 12px; }

.field { margin-bottom: 16px; }
.field:last-child { margin-bottom: 0; }
.label {
  font-size: 12px;
  font-weight: 700;
  color: var(--ink-2);
  letter-spacing: .4px;
  margin-bottom: 8px;
  display: block;
}

.pick-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.pick {
  border: 1.5px solid var(--line);
  background: #fbfcfa;
  border-radius: 13px;
  padding: 10px 6px;
  text-align: center;
  cursor: pointer;
  font-family: inherit;
  transition: border-color .14s, background .14s;
}
.pick:active { transform: scale(.97); }
.pick.on {
  border-color: var(--primary);
  background: var(--primary-soft);
}
.pick .avatar { margin: 0 auto 6px; width: 34px; height: 34px; border-radius: 11px; font-size: 13px; }
.pick-name {
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pick-level { font-size: 10.5px; color: var(--muted); }

.vs-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 8px;
  align-items: center;
}
.vs-tag {
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  letter-spacing: 1px;
}

/* score */
.set-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
}
.set-row:last-child { border-bottom: 0; }
.set-label { font-size: 12px; color: var(--muted); width: 34px; flex: none; font-weight: 600; }
.stepper {
  display: flex;
  align-items: center;
  gap: 2px;
  background: #f2f5ef;
  border-radius: 11px;
  padding: 3px;
}
.stepper button {
  width: 30px; height: 30px;
  border: 0;
  border-radius: 9px;
  background: var(--card);
  color: var(--ink-2);
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(20, 32, 26, .08);
}
.stepper button:active { transform: scale(.94); }
.stepper .num {
  width: 34px;
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.set-winner {
  margin-left: auto;
  font-size: 11px;
  color: var(--muted);
}

/* 提前结束 / 本场按平分：三个录分入口共用的开关 */
.draw-toggle {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 12px;
  padding: 10px 12px;
  border: 1.5px solid var(--line);
  border-radius: 11px;
  background: transparent;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.draw-toggle.on { border-color: var(--primary); background: var(--primary-soft); }
.draw-box {
  flex: none;
  width: 18px; height: 18px;
  margin: 1px 0 0;
  border: 1.5px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: #fff;
  font-size: 13px;
  line-height: 15px;
  text-align: center;
  box-sizing: border-box;
}
.draw-toggle.on .draw-box { background: var(--primary); border-color: var(--primary); }
.draw-txt { display: flex; flex-direction: column; gap: 2px; }
.draw-txt b { font-size: 13px; color: var(--ink); font-weight: 700; }
.draw-txt small { font-size: 11px; color: var(--muted); line-height: 1.5; }
.draw-mark {
  display: inline-block;
  margin-left: 3px;
  padding: 0 3px;
  font-size: 10px;
  font-weight: 700;
  color: #8a6d2f;
  background: #fdf3dc;
  border-radius: 4px;
}

.add-set {
  border: 1px dashed var(--line);
  background: transparent;
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  padding: 9px;
  border-radius: 11px;
  width: 100%;
  margin-top: 10px;
  cursor: pointer;
}

/* buttons */
.btn {
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 15px;
  font-size: 15.5px;
  font-weight: 700;
  font-family: inherit;
  background: var(--primary);
  color: #fff;
  cursor: pointer;
  letter-spacing: .3px;
  transition: transform .12s, opacity .12s;
}
.btn:active { transform: scale(.985); }
.btn:disabled { opacity: .4; }
.btn.ghost {
  background: transparent;
  color: var(--ink-2);
  border: 1.5px solid var(--line);
}
.btn.danger { background: #fdecea; color: #b93a2b; }

.hint {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  margin: 12px 0 0;
  line-height: 1.6;
}

/* match list */
.match {
  background: var(--card);
  border-radius: 14px;
  padding: 13px 14px;
  box-shadow: var(--shadow);
  margin-bottom: 8px;
}
.match-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--muted);
  margin-bottom: 9px;
}
.tag {
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--primary-soft);
  color: var(--primary);
  letter-spacing: .3px;
}
.tag.void { background: #f2f2f2; color: #999; }
.tag.dispute { background: #fff4e0; color: #a76b00; }
.tag.draw { background: #fdf3dc; color: #8a6d2f; }

.match-body {
  display: flex;
  align-items: center;
  gap: 12px;
}
.match-sides {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.match-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 3px 0;
  font-size: 14.5px;
}
.match-side { display: flex; align-items: center; gap: 7px; min-width: 0; }
.match-side .avatar { width: 26px; height: 26px; border-radius: 9px; font-size: 11px; }
.match-side span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.match-side.win { font-weight: 700; }
.match-score {
  flex: none;
  max-width: 44%;
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-2);
  word-spacing: 2px;
}

/* empty */
.empty {
  text-align: center;
  padding: 44px 20px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.8;
}

/* tabbar */
.tabbar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 30;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}
.tabbar-inner {
  max-width: 480px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.tab {
  border: 0;
  background: transparent;
  padding: 9px 0 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--muted);
  font-family: inherit;
  font-size: 10.5px;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: .3px;
}
.tab svg { width: 21px; height: 21px; }
.tab.on { color: var(--primary); }

.game-menu { display: grid; gap: 10px; }
.game-card {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px;
  color: var(--ink); text-decoration: none; padding: 15px;
}
.game-card strong { display: block; font-size: 16px; }
.game-card small { display: block; margin-top: 4px; color: var(--ink-2); }
.game-card > span:last-child { color: var(--primary); font-size: 19px; }
.game-card:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

/* profile */
.profile-hero {
  background: linear-gradient(150deg, #1c6b4a, #144d36 70%);
  border-radius: 20px;
  padding: 22px 18px;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.profile-hero::after {
  content: "";
  position: absolute;
  right: -40px; top: -40px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: rgba(201, 241, 60, .13);
}
.profile-hero .avatar { width: 52px; height: 52px; border-radius: 16px; font-size: 20px; background: rgba(255,255,255,.16) !important; }
.profile-name { font-size: 20px; font-weight: 700; margin-top: 12px; letter-spacing: -.3px; }
.profile-sub { font-size: 12.5px; opacity: .72; margin-top: 2px; }
.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 18px;
  position: relative;
  z-index: 1;
}
.pstat .v { font-size: 19px; font-weight: 750; font-variant-numeric: tabular-nums; }
.pstat .k { font-size: 10.5px; opacity: .66; letter-spacing: .4px; }

.spark { width: 100%; height: 64px; display: block; }

/* 积分走势：累积折线 + 点按浮层（浮层不常驻，不占画面） */
.spark-wrap { position: relative; margin-top: 16px; z-index: 1; }
.spark-head {
  display: flex; justify-content: space-between; gap: 8px;
  font-size: 10.5px; opacity: .7; letter-spacing: .2px;
}
.spark-canvas {
  width: 100%; height: 76px; display: block;
  touch-action: pan-y; cursor: crosshair;
}
.spark-tip {
  position: absolute; top: 24px; left: 50%;
  transform: translate(-50%, -4px);
  background: rgba(8, 26, 17, .92);
  color: #fff;
  font-size: 11px; line-height: 1.5;
  padding: 6px 10px; border-radius: 9px;
  white-space: nowrap; pointer-events: none;
  opacity: 0; transition: opacity .16s, transform .16s;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .22);
  z-index: 2;
}
.spark-tip.show { opacity: 1; transform: translate(-50%, 0); }
.spark-tip b { font-size: 12.5px; font-variant-numeric: tabular-nums; }
.spark-tip-d { margin-left: 7px; font-weight: 700; font-variant-numeric: tabular-nums; }
.spark-tip-d.up { color: #ff9d90; }
.spark-tip-d.down { color: #8fe6b2; }
.spark-tip-d.flat { color: #c7d3ca; }

/* 最近战绩：全部列出，容器自己竖向滚动 */
.recent-list {
  max-height: 320px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.recent-list::-webkit-scrollbar { width: 4px; }
.recent-list::-webkit-scrollbar-track { background: transparent; }
.recent-list::-webkit-scrollbar-thumb { background: #cfd9d0; border-radius: 4px; }
.recent-item {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 10px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.recent-item:last-child { border-bottom: 0; }
.recent-item:active { background: #f7faf6; }
.recent-left { flex: 1; min-width: 0; }
.recent-line { display: flex; align-items: baseline; gap: 5px; min-width: 0; }
.recent-res { font-size: 13px; flex: none; }
.recent-mode { font-size: 11px; color: var(--muted); flex: none; }
.recent-opp {
  font-size: 13px; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.recent-score { font-size: 12px; color: var(--muted); margin-top: 1px; }
.recent-right { flex: none; text-align: right; }
.recent-when { font-size: 11px; color: var(--muted); white-space: nowrap; }
.recent-delta {
  font-size: 13px; font-weight: 700; margin-top: 1px;
  font-variant-numeric: tabular-nums;
}
.recent-delta.up { color: var(--up); }
.recent-delta.down { color: var(--down); }
.recent-delta.flat { color: var(--muted); }

/* toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 96px;
  transform: translate(-50%, 12px);
  background: rgba(20, 32, 26, .93);
  color: #fff;
  font-size: 13.5px;
  font-weight: 500;
  padding: 11px 18px;
  border-radius: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s, transform .22s;
  z-index: 100;
  max-width: 86vw;
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* sheet */
.sheet-mask {
  position: fixed;
  inset: 0;
  background: rgba(20, 32, 26, .38);
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
.sheet-mask.show { opacity: 1; pointer-events: auto; }
.sheet {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 51;
  background: var(--card);
  border-radius: 22px 22px 0 0;
  padding: 10px 16px calc(20px + env(safe-area-inset-bottom));
  transform: translateY(100%);
  transition: transform .26s cubic-bezier(.32, .72, 0, 1);
  max-width: 480px;
  margin: 0 auto;
  max-height: 86vh;
  overflow-y: auto;
}
.sheet.show { transform: translateY(0); }
.sheet-grip {
  width: 38px; height: 4px;
  border-radius: 2px;
  background: var(--line);
  margin: 4px auto 14px;
}
.sheet h3 { margin: 0 0 4px; font-size: 17px; }
.sheet .sub { font-size: 12.5px; color: var(--muted); margin-bottom: 16px; }

.list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  cursor: pointer;
}
.list-item:last-child { border-bottom: 0; }
.list-item .chev { color: var(--muted); }

input[type="text"], input[type="password"], input[type="date"], textarea, select {
  width: 100%;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 12px 13px;
  font-size: 15px;
  font-family: inherit;
  color: var(--ink);
  background: #fbfcfa;
  outline: none;
  transition: border-color .15s;
}
input:focus, textarea:focus, select:focus { border-color: var(--primary); }
textarea { resize: vertical; min-height: 72px; }

.banner {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: #fff8e8;
  border: 1px solid #f2e2bd;
  border-radius: 13px;
  padding: 11px 13px;
  font-size: 12.5px;
  line-height: 1.6;
  color: #7a5a12;
  margin-bottom: 12px;
}
.banner svg { width: 16px; height: 16px; flex: none; margin-top: 1px; }

/* 加载态 */
.loading-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 96px;
  color: var(--muted);
}
.spinner {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2.5px solid var(--line);
  border-top-color: var(--primary);
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-title { margin-top: 16px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.loading-sub { margin-top: 6px; font-size: 12px; color: var(--muted); }

/* 加入页隐藏底部导航 */
body.join-mode { padding-bottom: 40px; }
body.join-mode .tabbar { display: none; }

/* ---------- 赛事 ---------- */
.tour-card {
  background: var(--card);
  border-radius: 14px;
  padding: 14px;
  box-shadow: var(--shadow);
  margin-bottom: 8px;
  cursor: pointer;
  transition: transform .12s;
}
.tour-card:active { transform: scale(.99); }
.tour-name { font-size: 15px; font-weight: 650; letter-spacing: -.2px; }
.tour-meta { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.tour-bar {
  height: 4px;
  background: #eef1ec;
  border-radius: 2px;
  margin-top: 11px;
  overflow: hidden;
}
.tour-bar i { display: block; height: 100%; background: var(--primary); border-radius: 2px; }

.fmt-card {
  text-align: left;
  border: 1.5px solid var(--line);
  background: #fbfcfa;
  border-radius: 14px;
  padding: 13px 15px;
  cursor: pointer;
  font-family: inherit;
  transition: border-color .14s, background .14s;
}
.fmt-card.on { border-color: var(--primary); background: var(--primary-soft); }
.fmt-name { font-size: 14.5px; font-weight: 650; color: var(--ink); }
.fmt-desc { font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.5; }

.tmatch {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}
.tmatch:last-child { border-bottom: 0; }
.tmatch[data-tm] { cursor: pointer; }
.tmatch[data-tm]:active { background: #f7f9f5; }
.t-time {
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  width: 36px;
  flex: none;
}
.t-court {
  font-size: 10px;
  background: #f0f3ee;
  color: var(--ink-2);
  padding: 2px 5px;
  border-radius: 5px;
  flex: none;
  min-width: 26px;
  text-align: center;
}
.t-a, .t-b {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.t-a { text-align: right; }
.t-score {
  flex: none;
  width: 66px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: 12px;
  color: var(--muted);
}
.t-a.win, .t-b.win { font-weight: 700; color: var(--primary); }
.t-a.win + .t-score, .t-b.win ~ .t-score { color: var(--ink-2); }

/* ==========================================================================
   网页版补充：按钮化组件 + 新增元素
   ========================================================================== */

/* 分段器用 <button class="seg-item">，需要重置原生按钮 */
.seg-item {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 8px 6px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-2);
  font-family: inherit;
  cursor: pointer;
  transition: background .16s, color .16s, box-shadow .16s;
  -webkit-appearance: none;
  appearance: none;
}
.seg-item.on {
  background: var(--card);
  color: var(--primary);
  box-shadow: 0 1px 3px rgba(20, 32, 26, .1);
}

/* 选人卡片：<button class="pick">，纵向排列头像/名字/级别 */
.pick {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 100%;
  font-size: 12.5px;
  color: var(--ink);
  -webkit-appearance: none;
  appearance: none;
}
.pick:active { transform: scale(.97); }
.pick.on { border-color: var(--primary); background: var(--primary-soft); }
.pick .avatar { width: 34px; height: 34px; border-radius: 11px; font-size: 13px; margin-bottom: 2px; }
.pick .pick-name { font-size: 12.5px; font-weight: 600; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pick .pick-level { font-size: 10.5px; color: var(--muted); }

/* 对阵行可点 */
.tmatch.tappable { cursor: pointer; }
.tmatch.tappable:active { background: #f2f5ef; }

/* 单场换人入口：挤在每一场最右侧，别和整行的「录入」点击冲突 */
.slot-swap {
  flex: none;
  border: 1px solid var(--line);
  background: #fbfcfa;
  color: var(--muted);
  border-radius: 7px;
  font-size: 10px;
  font-family: inherit;
  line-height: 1.2;
  padding: 3px 5px;
  cursor: pointer;
  white-space: nowrap;
}
.slot-swap:active { background: #eaf0e6; }

/* 单场换人弹层：每个位置一行「左/右 + 选人 + 陪」 */
.slot-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.slot-side { flex: none; width: 30px; font-size: 12px; color: var(--muted); }
.slot-row .input { flex: 1; min-width: 0; }
.slot-pad {
  flex: none;
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  color: var(--ink-2);
  white-space: nowrap;
  cursor: pointer;
}
.slot-pad input { accent-color: var(--primary); width: 15px; height: 15px; }

/* 返回条 */
.back-bar { padding: 4px 0 10px; }
.back-link {
  display: inline-block;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  padding: 4px 0;
}

/* 小操作按钮 */
.mini-btn {
  border: 1px solid var(--line);
  background: #fbfcfa;
  color: var(--ink-2);
  font-size: 11.5px;
  font-weight: 600;
  font-family: inherit;
  padding: 4px 10px;
  border-radius: 8px;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
.mini-btn.danger { color: #b93a2b; border-color: #f0d5d1; background: #fdf3f2; }
.mini-btn:active { transform: scale(.96); }

/* 表单控件统一（select 复用 .input） */
select.input {
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%237d8d83' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  background-size: 11px;
  padding-right: 34px;
}

/* 比分弹层里的 h3/sub 已在原样式里，这里只补间距 */
.sheet h3 { margin: 0; font-size: 17px; }
.sheet .sub { font-size: 12.5px; color: var(--muted); margin: 4px 0 16px; }

/* 动画降级：偏好减少动态效果时不转 */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* 防止任何元素意外撑出横向滚动 */
html, body { overflow-x: hidden; }
body { -webkit-text-size-adjust: 100%; }
/* 底部留出 tabbar 高度，避免最后一行被遮挡 */
.shell { padding-bottom: 24px; }

/* ---------- 表单控件：让 .input 类本身生效 ---------- */
/* 原样式只命中 input[type="text"]，不带 type 的 <input class="input"> 会退化成浏览器默认窄框，
   导致同一表单里输入框和下拉框宽度不一致。这里补一条 .input 规则统一。 */
.input {
  width: 100%;
  box-sizing: border-box;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 12px 13px;
  font-size: 15px;
  font-family: inherit;
  color: var(--ink);
  background: #fbfcfa;
  outline: none;
  transition: border-color .15s;
}
.input:focus { border-color: var(--primary); }

/* 赛事时间地点摘要（详情页标题下方一行） */
.tour-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: -2px 0 14px;
  padding: 0 2px;
  font-size: 13px;
  line-height: 1.5;
  color: #5c6f63;
}
.tour-meta-sep { color: #c3ccc6; }
.tour-meta-empty { color: #a8b4ac; }

.guest-badge { font-size: 11px; color: var(--primary); font-weight: 600; }
.guest-rank { margin: 8px 0; }
.guest-person { display: flex; align-items: center; justify-content: space-between; }
.guest-receipt { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; align-items: end; }
.guest-receipt input, .guest-receipt select { min-width: 0; }
.guest-receipt button { justify-self: start; }
.event-ledger summary small { overflow-wrap: anywhere; }
.event-resources .payment-choice { display:flex; flex-wrap:wrap; column-gap: 14px; }
.event-resources [data-ball-picker] label, .event-resources [data-hosted] label { display:block; margin-top:8px; }

.guest-share-card{margin-top:16px;border-left:4px solid #137653;background:linear-gradient(110deg,#eff6eb,#fff)}
.guest-share-card h2{font-size:19px;margin:0 0 6px;color:#184d39}
.guest-share-card p{margin:0 0 12px;color:#456556}
#guest-share-actions input{margin-top:10px}
