/* =========================================================
   绿茵引擎数据中心 · 样式（浅色版）
   字号下限 14px：正文 15px，次级信息靠颜色/字重区分，不靠缩字
   ========================================================= */

:root {
  --bg: #F3F5F9;
  --bg-2: #FAFBFD;
  --card: #FFFFFF;
  --card-2: #FFFFFF;
  --fill: #F7F8FB;          /* 卡片内的次级填充 */
  --line: rgba(15, 23, 42, 0.065);
  --line-2: rgba(15, 23, 42, 0.12);
  --txt: #0F172A;
  --txt-2: #56667E;
  --dim: #8B99AD;
  --acc: #00A06E;
  --acc-d: #00805A;
  --blue: #2563EB;
  --red: #E5484D;
  --gold: #B0781A;
  --purple: #7C5CE0;
  --r: 14px;
  --fs: 15px;               /* 正文 */
  --fs-2: 14px;             /* 次级，也是全站最小字号 */
  --sd-1: 0 1px 2px rgba(16, 24, 40, 0.04);
  --sd-2: 0 1px 2px rgba(16, 24, 40, 0.04), 0 10px 24px -16px rgba(16, 24, 40, 0.42);
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  background: var(--bg);
  color: var(--txt);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "HarmonyOS Sans SC",
               "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: var(--fs);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

body { min-height: 100vh; display: flex; justify-content: center; }

/* 背景光斑 */
.aurora {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(620px 400px at 10% -8%, rgba(37, 99, 235, 0.10), transparent 64%),
    radial-gradient(520px 340px at 94% 2%, rgba(0, 160, 110, 0.10), transparent 62%),
    radial-gradient(720px 520px at 50% 110%, rgba(124, 92, 224, 0.07), transparent 70%);
}

.app {
  position: relative; z-index: 1;
  width: 100%; max-width: 430px;
  padding: 0 12px calc(40px + env(safe-area-inset-bottom, 0px));
}

/* ================= 顶部 ================= */

.top {
  position: sticky; top: 0; z-index: 20;
  margin: 0 -12px;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 12px 0;
  background: linear-gradient(180deg, rgba(243, 245, 249, 0.97) 62%, rgba(243, 245, 249, 0));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.top-row { display: flex; align-items: center; justify-content: space-between; }

.brand { display: flex; align-items: center; gap: 9px; }

.mark {
  width: 36px; height: 36px; border-radius: 11px;
  display: grid; place-items: center;
  font-size: 18px;
  background: linear-gradient(145deg, #00D193 0%, #0FA9C9 48%, #2F6BF0 100%);
  box-shadow: 0 4px 12px -4px rgba(0, 160, 110, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.brand-txt h1 {
  font-size: 17px; font-weight: 700; letter-spacing: 0.4px;
  background: linear-gradient(92deg, #0F172A, #475569 82%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.brand-txt p { font-size: var(--fs-2); color: var(--dim); letter-spacing: 0.2px; margin-top: 1px; }

.icon-btn {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--line-2); background: #fff;
  color: var(--txt-2); display: grid; place-items: center; cursor: pointer;
  box-shadow: var(--sd-1);
  transition: 0.2s;
}
.icon-btn:active { transform: scale(0.92); background: #F1F4F8; }
.icon-btn svg { width: 17px; height: 17px; }
/* 语言切换：与刷新按钮同高，宽度随文字 */
.lang-btn {
  height: 36px; min-width: 36px; padding: 0 10px; border-radius: 18px;
  border: 1px solid var(--line-2); background: #fff;
  color: var(--txt-2); display: grid; place-items: center;
  box-shadow: var(--sd-1); transition: 0.2s;
  text-decoration: none; font-size: 12px; font-weight: 600;
  letter-spacing: 0.3px; flex: none;
}
.lang-btn:active { transform: scale(0.92); background: #F1F4F8; }
.spin { animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* 日期 */
.datebar { display: flex; align-items: center; gap: 6px; margin-top: 12px; }

.date-chip {
  padding: 5px 9px; border-radius: 9px; cursor: pointer;
  border: 1px solid var(--line); background: #fff;
  color: var(--txt-2); font-size: var(--fs-2); font-family: inherit;
  box-shadow: var(--sd-1); white-space: nowrap;
  transition: 0.18s;
}
.date-chip b { font-weight: 600; color: var(--dim); margin-left: 2px; }
.date-chip.active {
  background: #E4F6EF; border-color: rgba(0, 160, 110, 0.32);
  color: var(--acc-d); box-shadow: none;
}
.date-chip.active b { color: rgba(0, 128, 90, 0.6); }

.date-meta {
  margin-left: auto; font-size: var(--fs-2); color: var(--dim);
  letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  min-width: 0;
}

/* 玩法 tabs */
.plays {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 3px; margin-top: 11px; padding: 3px;
  background: rgba(15, 23, 42, 0.07);
  border-radius: 12px;
}
.play {
  padding: 7px 0; border: 0; border-radius: 9px; cursor: pointer;
  background: transparent; color: var(--txt-2);
  font-size: var(--fs); font-family: inherit; font-weight: 500;
  transition: 0.2s;
}
.play.active {
  background: #fff;
  color: var(--txt);
  font-weight: 650;
  box-shadow: 0 1px 3px rgba(16, 24, 40, 0.12), 0 3px 10px -4px rgba(16, 24, 40, 0.2);
}

/* ================= 列表头 ================= */

.list-head {
  display: flex; align-items: center; justify-content: space-between;
  margin: 14px 2px 8px;
}
.cnt { font-size: var(--fs-2); color: var(--txt-2); }
.cnt b { color: var(--txt); font-weight: 600; font-size: 15px; }

.sort-btn {
  display: flex; align-items: center; gap: 5px;
  padding: 5px 9px; border-radius: 7px; cursor: pointer;
  background: #fff; border: 1px solid var(--line);
  color: var(--txt-2); font-size: var(--fs-2); font-family: inherit;
  box-shadow: var(--sd-1);
  transition: 0.18s;
}
.sort-btn svg { width: 13px; height: 13px; opacity: 0.65; }
.sort-btn.on {
  color: var(--gold);
  border-color: rgba(176, 120, 26, 0.26);
  background: #FDF6E7;
  box-shadow: none;
}

/* ================= 比赛卡 ================= */

.list { display: flex; flex-direction: column; gap: 9px; }

.card {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 11px 12px 12px;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.16s ease, border-color 0.2s, box-shadow 0.2s;
  box-shadow: var(--sd-2);
  animation: rise 0.34s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

.card:active { transform: scale(0.985); border-color: var(--line-2); box-shadow: var(--sd-1); }

/* 卡片顶部条 */
.c-top { display: flex; align-items: center; gap: 6px; }

.lg {
  font-size: var(--fs-2); padding: 1px 6px; border-radius: 5px;
  font-weight: 600; letter-spacing: 0;
  background: color-mix(in srgb, var(--lc, #2563EB) 11%, #fff);
  color: var(--lc, #2563EB);
  border: 1px solid color-mix(in srgb, var(--lc, #2563EB) 22%, #fff);
  white-space: nowrap;
}

.no { font-size: var(--fs-2); color: var(--dim); letter-spacing: 0; white-space: nowrap; }
.no b { color: var(--txt-2); font-weight: 600; }

.time { margin-left: auto; font-size: var(--fs-2); color: var(--txt-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.live-dot {
  width: 5px; height: 5px; border-radius: 50%; background: var(--acc);
  box-shadow: 0 0 0 0 rgba(0, 160, 110, 0.5); animation: pulse 1.8s infinite;
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 6px rgba(0, 160, 110, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 160, 110, 0); }
}

.flag {
  font-size: var(--fs-2); padding: 1px 5px; border-radius: 4px;
  background: #FDF4E3; color: var(--gold);
  border: 1px solid rgba(176, 120, 26, 0.2);
  white-space: nowrap;
}
.flag.div {
  background: #F2EEFE;
  color: #6244C8;
  border-color: rgba(124, 92, 224, 0.22);
}

/* 对阵 */
.c-mid {
  display: flex; align-items: center; gap: 5px;
  margin: 10px 0 9px;
}

.team { flex: 1; display: flex; align-items: center; gap: 6px; min-width: 0; }
.team.home { justify-content: flex-start; }
.team.home .name { margin-left: auto; }
.team.away { justify-content: flex-start; }
.team.away .name { margin-right: auto; }

.logo {
  width: 24px; height: 24px; border-radius: 7px; flex: none;
  display: grid; place-items: center;
  font-size: var(--fs-2); font-weight: 700; color: #fff;
  background: linear-gradient(150deg, var(--c1, #3B82F6), var(--c2, #1E3A8A));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 1px 3px rgba(16, 24, 40, 0.14);
  overflow: hidden;
}
.logo img { width: 100%; height: 100%; object-fit: contain; }

.team .name {
  font-size: var(--fs); font-weight: 600; letter-spacing: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  color: var(--txt);
}

.vs {
  flex: none; width: 22px; text-align: center;
  font-size: var(--fs-2); color: #B3BDCB; font-weight: 600;
  letter-spacing: 0.5px;
}

/* 进行中 / 完场比分 */
.vs.score {
  width: auto; min-width: 46px; font-size: 17px; font-weight: 700;
  color: var(--txt); letter-spacing: 0; font-variant-numeric: tabular-nums;
}
.vs.score em { font-style: normal; font-weight: 500; color: var(--dim); margin: 0 2px; }

.time.live { display: inline-flex; align-items: center; gap: 4px; color: #C0332F; }
.time.live i {
  width: 5px; height: 5px; border-radius: 50%; background: #E5484D;
  animation: blinkDot 1.1s ease-in-out infinite;
}
@keyframes blinkDot { 50% { opacity: 0.25; } }
.time.done { color: var(--dim); }

/* 排名小标 */
.rk {
  font-style: normal; display: inline-block; vertical-align: 1px;
  font-size: var(--fs-2); font-weight: 500; color: #93A1B5;
  margin: 0 2px; padding: 0 3px; border-radius: 4px;
  background: rgba(15, 23, 42, 0.045);
  white-space: nowrap;
}
.sh-team .rk { margin: 0; }

.sh-score {
  font-size: 24px; font-weight: 700; letter-spacing: 1px;
  font-variant-numeric: tabular-nums; line-height: 1.1;
}
.sh-score em { font-style: normal; font-weight: 500; color: var(--dim); margin: 0 3px; }
.sh-vs-wrap { display: flex; flex-direction: column; align-items: center; gap: 5px; padding-top: 12px; }
.sh-tag { font-size: var(--fs-2); padding: 1px 6px; border-radius: 4px; white-space: nowrap; }
.sh-tag.live { color: #C0332F; background: rgba(229, 72, 77, 0.1); }
.sh-tag.post { color: var(--dim); background: rgba(15, 23, 42, 0.05); }

/* 数据行 */
.c-bot { display: flex; align-items: center; gap: 8px; }

.odds { display: flex; gap: 5px; flex: none; }
.odds.fill { flex: 0 0 auto; }
.odds.fill .o { flex: 0 0 auto; width: auto; min-width: 68px; }

.o {
  display: flex; flex-direction: column; align-items: center;
  min-width: 52px; padding: 4px 5px 5px;
  border-radius: 8px;
  background: var(--fill);
  border: 1px solid rgba(15, 23, 42, 0.045);
}
.o i {
  font-style: normal; font-size: var(--fs-2); color: var(--dim);
  line-height: 1.25; white-space: nowrap;
}
.o b {
  font-size: 15px; font-weight: 650; line-height: 1.3;
  font-variant-numeric: tabular-nums; letter-spacing: -0.3px;
  white-space: nowrap;
}
.o.h b { color: var(--red); }
.o.d b { color: var(--txt-2); }
.o.a b { color: var(--blue); }
.o.hl { background: #EAF8F2; border-color: rgba(0, 160, 110, 0.2); }
.o.hl b { color: var(--acc-d); }

/* 三段概率微条 */
.pbar {
  flex: 1; height: 5px; border-radius: 3px; overflow: hidden;
  display: flex; gap: 1.5px; min-width: 0;
  background: rgba(15, 23, 42, 0.07);
}
.pbar span { height: 100%; border-radius: 2px; transition: width 0.5s ease; }
.pbar .ph { background: linear-gradient(90deg, #E5484D, #F4796C); }
.pbar .pd { background: #C2CBD8; }
.pbar .pa { background: linear-gradient(90deg, #2563EB, #5B92F5); }
.pbar .s1 { background: linear-gradient(90deg, #00A06E, #14A9C4); }
.pbar .s2 { background: rgba(0, 160, 110, 0.5); }
.pbar .s3 { background: rgba(0, 160, 110, 0.28); }

.pick {
  flex: none; font-size: var(--fs-2); font-weight: 600;
  color: var(--acc-d); white-space: nowrap;
}
.pick.mid { color: var(--txt-2); }
/* 已完场：赛果用中性底色，和预测的强调色区分开 */
.pick.done {
  color: var(--txt);
  background: var(--line);
  padding: 2px 6px;
  border-radius: 5px;
}

/* ================= 底部抽屉 ================= */

.sheet-mask {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(15, 23, 42, 0.32);
  backdrop-filter: blur(3px);
  opacity: 0; pointer-events: none; transition: opacity 0.26s;
}
.sheet-mask.on { opacity: 1; pointer-events: auto; }

.sheet {
  position: fixed; left: 50%; bottom: 0; z-index: 51;
  width: 100%; max-width: 430px;
  max-height: 90vh; overflow-y: auto;
  transform: translate(-50%, 102%);
  transition: transform 0.34s cubic-bezier(0.22, 1, 0.36, 1);
  background: linear-gradient(180deg, #FFFFFF 0%, #FBFCFE 45%);
  border-radius: 22px 22px 0 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 -24px 60px -24px rgba(16, 24, 40, 0.35);
  padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px));
  -webkit-overflow-scrolling: touch;
}
.sheet.on { transform: translate(-50%, 0); }
.sheet::-webkit-scrollbar { width: 0; }

.grab {
  width: 38px; height: 4px; border-radius: 3px; margin: 9px auto 2px;
  background: rgba(15, 23, 42, 0.14);
}

/* 抽屉头部 */
.sh-head { padding: 12px 16px 0; }
.sh-meta { display: flex; align-items: center; gap: 6px; font-size: var(--fs-2); color: var(--dim); }
.sh-close {
  margin-left: auto; width: 28px; height: 28px; border-radius: 50%;
  border: 1px solid var(--line-2); background: #F6F8FB;
  color: var(--txt-2); font-size: 15px; line-height: 1; cursor: pointer;
  display: grid; place-items: center; flex: none;
}

.sh-teams {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  margin: 14px 0 6px;
}
.sh-team { display: flex; flex-direction: column; align-items: center; gap: 7px; width: 104px; }
.sh-team .logo { width: 46px; height: 46px; border-radius: 14px; font-size: 17px; }
.sh-team .nm { font-size: var(--fs); font-weight: 650; text-align: center; line-height: 1.3; }
.sh-vs { font-size: var(--fs-2); color: #B3BDCB; letter-spacing: 1px; padding-top: 18px; }

/* 共识概率 */
.consensus {
  margin: 14px 16px 0; padding: 12px 13px;
  background: var(--fill);
  border: 1px solid var(--line);
  border-radius: 14px;
}
.cs-title {
  display: flex; align-items: center; justify-content: space-between;
  font-size: var(--fs-2); color: var(--dim); margin-bottom: 9px;
}
.cs-title .dv { color: var(--gold); }
.cs-title .dv.low { color: var(--acc-d); }

.cs-row { display: flex; align-items: flex-end; gap: 8px; }
.cs-item { flex: 1; text-align: center; }
.cs-item .lbl { font-size: var(--fs-2); color: var(--dim); }
.cs-item .val {
  font-size: 22px; font-weight: 700; letter-spacing: -0.6px;
  font-variant-numeric: tabular-nums; line-height: 1.25;
}
.cs-item .val small { font-size: 14px; font-weight: 500; opacity: 0.45; margin-left: 1px; }
.cs-item.h .val { color: var(--red); }
.cs-item.d .val { color: var(--txt-2); }
.cs-item.a .val { color: var(--blue); }

.cs-bar {
  display: flex; height: 6px; border-radius: 4px; overflow: hidden;
  margin-top: 10px; gap: 2px;
}
.cs-bar span { height: 100%; border-radius: 3px; }
.cs-bar .h { background: linear-gradient(90deg, #E5484D, #F4796C); }
.cs-bar .d { background: #C2CBD8; }
.cs-bar .a { background: linear-gradient(90deg, #2563EB, #5B92F5); }

/* 小节标题 */
.sec-t {
  display: flex; align-items: center; gap: 7px;
  margin: 18px 16px 9px;
  font-size: 16px; font-weight: 650; color: var(--txt);
}
.sec-t::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.sec-t em {
  font-style: normal; font-size: var(--fs-2); font-weight: 400; color: var(--dim);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}

/* 各家来源 */
.srcs { padding: 0 16px; display: flex; flex-direction: column; gap: 7px; }

.src {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 10px; border-radius: 11px;
  background: var(--fill);
  border: 1px solid var(--line);
}
.src-ico {
  width: 7px; height: 7px; border-radius: 50%; flex: none;
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.035);
}
.src-id { flex: none; width: 96px; min-width: 0; }
.src-id .n {
  font-size: 15px; font-weight: 600; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; color: var(--txt);
}
.src-id .t {
  font-size: var(--fs-2); color: var(--dim); margin-top: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.src-bar { flex: 1; min-width: 0; }
.src-bar .mini {
  display: flex; height: 5px; border-radius: 3px; overflow: hidden; gap: 1.5px;
  background: rgba(15, 23, 42, 0.06);
}
.src-bar .mini span { height: 100%; }
.src-bar .mini .h { background: #E5484D; }
.src-bar .mini .d { background: #C2CBD8; }
.src-bar .mini .a { background: #2563EB; }
.src-bar .pcts {
  display: flex; justify-content: space-between; margin-top: 3px;
  font-size: var(--fs-2); color: var(--dim); font-variant-numeric: tabular-nums;
}
.src-bar .pcts span { color: inherit; }

.src-score {
  flex: none; text-align: right; width: 60px;
}
.src-score b {
  font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums;
  color: var(--txt); white-space: nowrap;
}
.src-score i { font-style: normal; display: block; font-size: var(--fs-2); color: var(--dim); white-space: nowrap; }

/* ---------- AI 模型观点 ---------- */

.ai-wrap { padding: 0 16px; display: flex; flex-direction: column; gap: 8px; }
.ai-item { display: flex; flex-direction: column; gap: 3px; }

.src.ai { background: #FBFCFE; border-color: rgba(15, 23, 42, 0.085); }

.ai-reason {
  font-size: var(--fs-2); line-height: 1.6; color: #47566B;
  padding-left: 20px; margin-top: 1px;
}

.ai-note {
  font-size: var(--fs-2); line-height: 1.5; color: var(--dim);
  padding: 3px 2px 0; text-align: center;
}

/* 自动补算提示：一行轻量文案 + 呼吸圆点，不占一块按钮的位置 */
.ai-auto {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  margin-top: 8px; padding: 6px 2px;
  font-size: var(--fs-2); line-height: 1.5; color: var(--dim); text-align: center;
}
.ai-auto i {
  width: 7px; height: 7px; border-radius: 50%; flex: none;
  background: var(--blue); animation: blink 1.1s ease-in-out infinite;
}

.ai-btn {
  width: 100%; padding: 13px 12px; border-radius: 12px;
  background: linear-gradient(135deg, #F1F5FF 0%, #EDF9F4 100%);
  border: 1px dashed rgba(37, 99, 235, 0.3);
  color: var(--blue); font-family: inherit; font-size: 15px; font-weight: 600;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  cursor: pointer; transition: 0.2s;
}
.ai-btn:active { transform: scale(0.985); }
.ai-btn em { font-style: normal; font-size: var(--fs-2); font-weight: 400; color: var(--dim); }

.src-ico.spinning { animation: blink 1.1s ease-in-out infinite; }
@keyframes blink { 50% { opacity: 0.22; } }

.ai-skel {
  height: 5px; border-radius: 3px;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.06) 25%, rgba(15, 23, 42, 0.13) 50%, rgba(15, 23, 42, 0.06) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.3s linear infinite;
}
@keyframes shimmer { to { background-position: -200% 0; } }

.ai-skel.err {
  height: auto; padding: 2px 0; background: none;
  animation: none; font-size: var(--fs-2); color: var(--red);
}

/* 比分热力图 */
.heat { padding: 0 16px; }
.heat-grid {
  display: grid;
  grid-template-columns: 22px repeat(6, minmax(0, 1fr));
  gap: 3px;
}
.hg-lbl {
  font-size: var(--fs-2); color: var(--dim); display: grid; place-items: center;
  font-variant-numeric: tabular-nums;
}
.hg-cell {
  aspect-ratio: 1.15; border-radius: 5px;
  display: grid; place-items: center;
  font-size: var(--fs-2); font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  min-width: 0; overflow: hidden;
  transition: 0.2s;
}
.hg-cell.top {
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.85);
  font-weight: 700;
}

/* 其它玩法 */
.duo { display: flex; gap: 8px; padding: 0 16px; }
.duo-card {
  flex: 1; padding: 10px 11px; border-radius: 12px;
  background: var(--fill);
  border: 1px solid var(--line);
}
.duo-card .k { font-size: var(--fs-2); color: var(--dim); }
.duo-card .v {
  font-size: 18px; font-weight: 700; margin-top: 2px;
  font-variant-numeric: tabular-nums;
  color: var(--txt);
}
.duo-card .v span { font-size: var(--fs-2); font-weight: 500; color: var(--dim); }
.duo-card .s { font-size: var(--fs-2); color: var(--dim); margin-top: 1px; }

.disc {
  margin: 18px 16px 0; padding: 10px 12px;
  border-radius: 10px;
  background: #FEF9EF;
  border: 1px solid rgba(176, 120, 26, 0.16);
  font-size: var(--fs-2); line-height: 1.6; color: #96751F;
}

/* 底部 */
.foot {
  margin-top: 20px; text-align: center;
  font-size: var(--fs-2); color: #A3AEBE; line-height: 1.7;
}
.foot-link {
  display: inline-block; margin-top: 5px; color: #8B99AD;
  text-decoration: none; border-bottom: 1px dashed rgba(139, 153, 173, 0.5);
}
.foot-link:hover { color: var(--blue); border-color: rgba(37, 99, 235, 0.5); }

/* 展开视图（大屏 / 分享长图）：?flat=1 */
.flat body { display: block; }
.flat .app { margin: 0 auto; }
.flat .sheet-mask, .flat .list, .flat .list-head,
.flat .datebar, .flat .plays, .flat .foot { display: none; }
.flat .sheet {
  position: static; left: auto; bottom: auto;
  transform: none !important;
  width: calc(100% - 24px);
  max-height: none; margin: 16px auto 0;
  border-radius: 20px;
  border: 1px solid var(--line);
  box-shadow: 0 10px 40px -20px rgba(16, 24, 40, 0.22);
}

/* 空状态 */
.empty { text-align: center; padding: 48px 0; color: var(--dim); font-size: 15px; }

/* ---------- 国际模型配置（两版共用同一套类名） ---------- */

.ai-cfg { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line-2); }
.ai-cfg-tg {
  width: 100%; display: flex; align-items: center; gap: 8px;
  font-family: inherit; font-size: 14px; color: var(--txt-2);
  background: none; border: 0; padding: 2px 0; cursor: pointer; text-align: left;
}
.ai-cfg-tg em { font-style: normal; font-size: 14px; color: var(--dim); }
.ai-cfg-tg::after { content: '＋'; margin-left: auto; color: var(--dim); }
.ai-cfg-tg.open::after { content: '－'; }
.ai-cfg-body { display: flex; flex-direction: column; gap: 9px; margin-top: 9px; }
.ai-cfg-body[hidden] { display: none; }   /* 收起时不留空档 */
.ai-cfg-row { display: flex; flex-direction: column; gap: 4px; }
.ai-cfg-row .k { font-size: 14px; color: var(--txt-2); }
.ai-cfg-row .k a { color: var(--blue); text-decoration: none; border-bottom: 1px dashed rgba(37, 99, 235, 0.4); }
.ai-cfg-row .v { font-size: 14px; color: var(--dim); }
.ai-cfg-in {
  font-family: inherit; font-size: 14px; color: var(--txt);
  padding: 7px 9px; border: 1px solid var(--line-2); border-radius: 8px; background: #fff;
  min-width: 0;
}
.ai-cfg-in:focus { outline: none; border-color: rgba(37, 99, 235, 0.45); }
.ai-cfg-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  font-size: 14px; color: var(--dim); flex-wrap: wrap;
}
.ai-cfg-save {
  font-family: inherit; font-size: 14px; font-weight: 600; padding: 7px 13px;
  border-radius: 8px; border: 1px solid rgba(37, 99, 235, 0.3);
  background: #EEF4FF; color: var(--blue); cursor: pointer;
}
.ai-cfg-save:active { transform: scale(0.97); }


/* ---------- 英文版微调 ----------
   英文队名普遍比中文长 2-3 倍（法罗群岛 vs Faroe Islands），
   字号略降并允许标题收缩，避免在 375 宽下被省略号切掉 */
html[lang="en"] .team .name { font-size: 12.8px; }
/* 英文三个 chip 已经占满一行，这句装饰文案留着只会被截成 "Mon · 10 mod…" */
html[lang="en"] .date-meta { display: none; }
html[lang="en"] .team .rk { font-size: 9.5px; padding: 0 2px; }
html[lang="en"] .team .logo { width: 20px; height: 20px; font-size: 10.5px; border-radius: 6px; }
html[lang="en"] .brand-txt h1 { font-size: 15.5px; letter-spacing: 0.1px; }
html[lang="en"] .c-top .lg { min-width: 0; overflow: hidden; text-overflow: ellipsis; }


/* ---------- 数据过期提示 ----------
   只在数据源拉不到、退回离线快照且超过 12 小时时出现。
   正常浏览看不到这条，所以用暖黄而不是红色，避免误读成报错 */
.stale-tip {
  margin-top: 8px; padding: 7px 10px; border-radius: 8px;
  font-size: var(--fs-2); line-height: 1.5;
  background: #FDF4E3; color: #8A5A12;
  border: 1px solid rgba(176, 120, 26, 0.25);
}
.stale-tip[hidden] { display: none; }

/* ---------- 首屏骨架 ----------
   手机版只加载 style.css，所以这套样式单独放这里，不跟 web.css 共用。
   骨架卡片高度贴近真实卡片，渲染完成时整块替换，不会跳。
   ------------------------------------ */

.sk-card { pointer-events: none; cursor: default; }

.sk {
  position: relative; overflow: hidden;
  display: block; height: 14px; border-radius: 5px;
  background: #E6EAF1;
}
.sk::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg,
    rgba(255,255,255,0) 0%, rgba(255,255,255,.92) 50%, rgba(255,255,255,0) 100%);
  transform: translateX(-100%);
  animation: sk-shine 1.3s ease-in-out infinite;
}
@keyframes sk-shine { to { transform: translateX(100%); } }

.sk-row { display: flex; align-items: center; gap: 8px; margin-bottom: 11px; }
.sk-lg   { width: 52px; height: 18px; border-radius: 5px; }
.sk-t    { width: 38px; height: 13px; }
.sk-team { width: 78%; height: 15px; margin-bottom: 13px; }

.sk-barw { display: flex; gap: 3px; }
.sk-barw i {
  display: block; height: 7px; border-radius: 3px; background: #ECEFF3;
  position: relative; overflow: hidden;
}
.sk-barw i::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg,
    rgba(255,255,255,0) 0%, rgba(255,255,255,.92) 50%, rgba(255,255,255,0) 100%);
  transform: translateX(-100%);
  animation: sk-shine 1.3s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .sk::after, .sk-barw i::after { animation: none; }
}

/* ================= AI 模型战绩榜 ================= */

.rank { margin: 14px 12px 6px; }

.rk-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  padding: 13px 13px 12px; box-shadow: var(--sd-2);
}

.rk-head { display: flex; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.rk-head h2 { font-size: 16px; font-weight: 650; }
.rk-head span {
  font-size: var(--fs-2); color: var(--dim);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.rk-row {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) 104px;
  align-items: center; gap: 9px;
  padding: 8px 0;
}
.rk-row + .rk-row { border-top: 1px solid rgba(15, 23, 42, 0.045); }
.rk-row.top {
  background: linear-gradient(90deg, rgba(0, 200, 138, 0.07), rgba(0, 200, 138, 0) 75%);
  border-radius: 8px; margin: 0 -6px; padding: 8px 6px;
}

.rk-no {
  width: 21px; height: 21px; border-radius: 7px;
  display: flex; align-items: center; justify-content: center;
  font-size: var(--fs-2); font-weight: 700; font-variant-numeric: tabular-nums;
  color: var(--dim); background: var(--fill);
}
.rk-no.r1 { color: #fff; background: linear-gradient(135deg, #00D896, #00A06E); }
.rk-no.r2 { color: #0C6A4C; background: #D6F2E6; }
.rk-no.r3 { color: #8A6100; background: #FAF0D8; }

.rk-who { display: flex; align-items: center; gap: 6px; min-width: 0; }
.rk-dot { width: 7px; height: 7px; border-radius: 50%; flex: none; }
.rk-who b { font-size: var(--fs); font-weight: 600; white-space: nowrap; }
.rk-who i {
  font-style: normal; font-size: var(--fs-2); color: var(--dim);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0;
}

/* 手机上条形压成细条垫在名字下方，右列只留命中率 */
.rk-bar { display: none; }

.rk-val { text-align: right; }
.rk-val b {
  font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums;
  color: var(--acc-d); white-space: nowrap;
}
.rk-val b em { font-style: normal; font-size: var(--fs-2); font-weight: 500; }
.rk-val i {
  display: block; font-style: normal; font-size: var(--fs-2); color: var(--dim);
  white-space: nowrap;
}

.rk-foot { margin-top: 9px; font-size: var(--fs-2); color: var(--txt-2); }
.rk-note { margin-top: 3px; font-size: var(--fs-2); color: var(--dim); line-height: 1.5; }

.rk-empty {
  display: flex; flex-direction: column; gap: 4px;
  padding: 12px; border-radius: 10px; background: var(--fill);
}
.rk-empty b { font-size: var(--fs); font-weight: 600; }
.rk-empty span { font-size: var(--fs-2); color: var(--dim); line-height: 1.55; }

/* ================= 「看理由」按钮 + 展开的依据 ================= */

.more {
  width: 100%; margin-top: 9px; padding: 10px 12px; border-radius: 11px;
  display: flex; align-items: center; justify-content: center; gap: 7px;
  background: #fff; border: 1px dashed var(--line-2); cursor: pointer;
  font-family: inherit; font-size: var(--fs-2); transition: 0.16s;
}
.more:active { transform: scale(0.99); }
.more span { font-weight: 600; color: var(--blue); }
.more em { font-style: normal; color: var(--dim); }
.more i {
  width: 6px; height: 6px; flex: none; margin-left: 2px;
  border-right: 1.6px solid var(--dim); border-bottom: 1.6px solid var(--dim);
  transform: rotate(45deg) translateY(-1px); transition: transform 0.18s;
}
.more[aria-expanded="true"] i { transform: rotate(-135deg) translateY(-1px); }

/* 按钮贴在卡片文字的左内边距上，和上方内容对齐 */
.ai-wrap .more, .cmp-wrap .more { margin-left: 16px; margin-right: 16px; width: auto; }

.src { flex-wrap: wrap; }

.src-why {
  display: none; flex: 1 0 100%; order: 9;
  margin: 3px 0 1px 15px; padding: 5px 0 5px 9px;
  border-left: 2px solid rgba(0, 160, 110, 0.25);
  font-size: var(--fs-2); line-height: 1.6; color: #47566B;
}
.show-why .src-why { display: block; }

.ai-reason { display: none; }
.show-why .ai-reason { display: block; }
