/* ============================================================
   峡谷竞猜 · Canyon Bets
   移动优先的暗色电竞风格
   ============================================================ */

:root {
  --bg: #070b13;
  --bg-2: #0a0f1b;
  --panel: rgba(17, 24, 39, 0.82);
  --panel-solid: #101726;
  --panel-soft: rgba(255, 255, 255, 0.035);
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.15);
  --text: #f4f6fb;
  --muted: #8b96ad;
  --muted-2: #5b6579;
  --gold: #f3c969;
  --gold-2: #d9a441;
  --gold-soft: rgba(243, 201, 105, 0.14);
  --teal: #3ddbc3;
  --teal-soft: rgba(61, 219, 195, 0.12);
  --red: #ff6b7d;
  --red-soft: rgba(255, 107, 125, 0.13);
  --green: #55d98a;
  --green-soft: rgba(85, 217, 138, 0.13);
  --radius: 20px;
  --radius-sm: 13px;
  --radius-lg: 26px;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.5);
  --shadow-sm: 0 8px 26px rgba(0, 0, 0, 0.4);
  --font: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-num: "DIN Alternate", "Bahnschrift", "Segoe UI", var(--font);
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  min-height: 100dvh;
  line-height: 1.5;
  overflow-x: hidden;
}

button {
  font-family: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

input, textarea, select {
  font-family: inherit;
  color: inherit;
}

svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hidden,
[hidden] {
  display: none !important;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ---------- 环境背景 ---------- */

.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.ambient__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
}

.ambient__orb--gold {
  width: 55vw;
  height: 55vw;
  max-width: 520px;
  max-height: 520px;
  right: -18vw;
  top: -16vw;
  background: radial-gradient(circle, rgba(243, 201, 105, 0.22), transparent 65%);
}

.ambient__orb--teal {
  width: 60vw;
  height: 60vw;
  max-width: 560px;
  max-height: 560px;
  left: -24vw;
  top: 34vh;
  background: radial-gradient(circle, rgba(61, 219, 195, 0.14), transparent 60%);
}

.ambient__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse at 50% 0%, black 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, black 30%, transparent 78%);
}

/* ---------- 通用组件 ---------- */

.eyebrow {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.18em;
  color: var(--muted-2);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-transform: uppercase;
}

.eyebrow__line {
  width: 18px;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), transparent);
  border-radius: 2px;
  display: inline-block;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 11px;
  font-size: 21px;
  font-weight: 900;
  color: #171208;
  background: linear-gradient(145deg, #ffe3a1, var(--gold) 45%, #b98a2c);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), 0 6px 18px rgba(243, 201, 105, 0.28);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.brand-mark--lg {
  width: 52px;
  height: 52px;
  font-size: 29px;
  border-radius: 15px;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  border: 1px solid var(--line-strong);
  color: var(--muted);
}

.tag--gold {
  color: var(--gold);
  border-color: rgba(243, 201, 105, 0.35);
  background: var(--gold-soft);
}

.tag--teal {
  color: var(--teal);
  border-color: rgba(61, 219, 195, 0.35);
  background: var(--teal-soft);
}

.tag--red {
  color: var(--red);
  border-color: rgba(255, 107, 125, 0.35);
  background: var(--red-soft);
}

.tag--green {
  color: var(--green);
  border-color: rgba(85, 217, 138, 0.35);
  background: var(--green-soft);
}

.tag--ghost {
  color: var(--muted);
}

.icon-btn {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  font-size: 18px;
  transition: 0.18s ease;
}

.icon-btn:active {
  transform: scale(0.94);
  color: var(--text);
}

.ghost-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  transition: 0.18s ease;
}

.ghost-btn:active {
  color: var(--text);
  border-color: var(--line-strong);
}

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: transform 0.14s ease, filter 0.14s ease, background 0.2s ease;
}

.btn:active {
  transform: translateY(1px);
  filter: brightness(0.94);
}

.btn--primary {
  color: #171208;
  background: linear-gradient(160deg, #ffe3a1, var(--gold) 55%, #c89a3c);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5), 0 10px 28px rgba(243, 201, 105, 0.28);
}

.btn--teal {
  color: #04201c;
  background: linear-gradient(160deg, #a9f3e6, var(--teal) 60%, #27b7a0);
  box-shadow: 0 10px 28px rgba(61, 219, 195, 0.24);
}

.btn--ghost {
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line-strong);
}

.btn--danger {
  color: var(--red);
  background: var(--red-soft);
  border: 1px solid rgba(255, 107, 125, 0.35);
}

.btn--block {
  width: 100%;
}

.btn--sm {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 11px;
  font-size: 13px;
}

.btn:disabled {
  opacity: 0.5;
  pointer-events: none;
}

.btn__spinner {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(0, 0, 0, 0.25);
  border-top-color: rgba(0, 0, 0, 0.85);
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.field {
  display: block;
  margin-bottom: 14px;
}

.field > span {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 7px;
}

.input-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 13px;
  transition: border 0.2s ease, background 0.2s ease;
}

.input-wrap:focus-within {
  border-color: rgba(243, 201, 105, 0.5);
  background: rgba(255, 255, 255, 0.06);
}

.input-wrap svg {
  font-size: 17px;
  color: var(--muted-2);
  flex: none;
}

.input-wrap input {
  flex: 1;
  min-width: 0;
  height: 48px;
  background: none;
  border: 0;
  outline: none;
  font-size: 15px;
  color: var(--text);
}

.input-wrap input::placeholder {
  color: var(--muted-2);
}

.form-error {
  margin: 2px 0 14px;
  padding: 10px 13px;
  border-radius: 11px;
  background: var(--red-soft);
  border: 1px solid rgba(255, 107, 125, 0.3);
  color: #ffaeb9;
  font-size: 13px;
  line-height: 1.45;
}

/* ---------- 启动屏 ---------- */

.splash {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  background: var(--bg);
}

.splash__mark {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  border-radius: 24px;
  font-size: 42px;
  font-weight: 900;
  color: #171208;
  background: linear-gradient(145deg, #ffe3a1, var(--gold) 48%, #b98a2c);
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.55), 0 18px 50px rgba(243, 201, 105, 0.3);
  animation: float 2.4s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

.splash__bar {
  width: 150px;
  height: 3px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.splash__bar span {
  display: block;
  height: 100%;
  width: 40%;
  border-radius: 3px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  animation: load 1.2s ease-in-out infinite;
}

@keyframes load {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(320%); }
}

.splash p {
  font-size: 13px;
  color: var(--muted);
  letter-spacing: 0.06em;
}

/* ---------- 认证页 ---------- */

.auth-screen {
  min-height: 100vh;
  min-height: 100dvh;
  padding: 24px 20px 40px;
  display: flex;
  justify-content: center;
  animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.auth-shell {
  width: 100%;
  max-width: 440px;
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 30px;
}

.auth-brand__name {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.auth-brand__sub {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--muted-2);
  margin-top: 2px;
  white-space: nowrap;
}

.auth-brand .tag {
  margin-left: auto;
  white-space: nowrap;
  flex: none;
}

.auth-hero h1 {
  font-size: 34px;
  line-height: 1.22;
  font-weight: 900;
  letter-spacing: -0.01em;
  margin: 8px 0 14px;
}

.auth-hero h1 span {
  background: linear-gradient(100deg, var(--gold), #ffe9b3 55%, var(--gold-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.auth-lede {
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--muted);
}

.auth-facts {
  display: flex;
  gap: 10px;
  margin: 24px 0;
}

.fact {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 14px 6px;
  border-radius: 15px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.fact svg {
  font-size: 19px;
  color: var(--gold);
}

.fact strong {
  font-family: var(--font-num);
  font-size: 19px;
  font-weight: 800;
}

.fact span {
  font-size: 11px;
  color: var(--muted-2);
}

.auth-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  margin-bottom: 18px;
}

.auth-tab {
  height: 40px;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  transition: 0.2s ease;
}

.auth-tab.is-active {
  color: var(--text);
  background: var(--panel-solid);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.auth-hint {
  text-align: center;
  font-size: 12px;
  color: var(--muted-2);
  margin-top: 14px;
}

.fine-print {
  text-align: center;
  font-size: 11px;
  color: var(--muted-2);
  margin-top: 22px;
  line-height: 1.6;
}

.noscript {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 30px;
  text-align: center;
  color: var(--muted);
  background: var(--bg);
}

/* ---------- 应用外壳 ---------- */

.app-shell {
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  padding-bottom: calc(78px + env(safe-area-inset-bottom));
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  padding-top: calc(12px + env(safe-area-inset-top));
  background: linear-gradient(180deg, rgba(7, 11, 19, 0.92), rgba(7, 11, 19, 0.72));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.brand-button {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
}

.brand-button .brand-mark {
  width: 34px;
  height: 34px;
  font-size: 19px;
  border-radius: 10px;
}

.brand-word {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.conn-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
}

.conn-pill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--muted-2);
}

.conn-pill.is-on i {
  background: var(--green);
  box-shadow: 0 0 8px rgba(85, 217, 138, 0.8);
  animation: pulse 2s ease-in-out infinite;
}

.conn-pill.is-off i {
  background: var(--red);
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.balance-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 13px;
  border-radius: 12px;
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.35);
  color: var(--gold);
}

.balance-pill svg {
  font-size: 16px;
}

.balance-pill strong {
  font-family: var(--font-num);
  font-size: 15.5px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.main {
  padding: 14px 16px 30px;
}

.view {
  animation: fadeIn 0.3s ease;
}

.page-foot {
  text-align: center;
  font-size: 11px;
  color: var(--muted-2);
  margin-top: 26px;
  letter-spacing: 0.04em;
}

.page-foot span {
  color: var(--gold);
}

/* ---------- 英雄卡片 ---------- */

.hero-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 20px;
  background:
    radial-gradient(120% 130% at 88% -10%, rgba(243, 201, 105, 0.2), transparent 55%),
    linear-gradient(150deg, #141c2e, #0c1320);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.hero-card::after {
  content: "";
  position: absolute;
  right: -40px;
  bottom: -60px;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  border: 1px dashed rgba(243, 201, 105, 0.18);
}

.hero-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hero-card__label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}

.hero-card__balance {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 8px 0 4px;
}

.hero-card__balance .coin {
  color: var(--gold);
  font-size: 24px;
}

.hero-card__balance strong {
  font-family: var(--font-num);
  font-size: 44px;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1;
}

.hero-card__balance span.unit {
  font-size: 15px;
  font-weight: 700;
  color: var(--muted);
}

.hero-card__meta {
  display: flex;
  gap: 16px;
  font-size: 12.5px;
  color: var(--muted);
  position: relative;
  z-index: 1;
}

.hero-card__meta b {
  color: var(--text);
  font-family: var(--font-num);
  font-weight: 700;
}

.hero-card--admin {
  background:
    radial-gradient(120% 130% at 88% -10%, rgba(61, 219, 195, 0.16), transparent 55%),
    linear-gradient(150deg, #141c2e, #0c1320);
}

.admin-hero-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 14px 0 16px;
  position: relative;
  z-index: 1;
}

.admin-hero-row strong {
  display: block;
  font-family: var(--font-num);
  font-size: 28px;
  font-weight: 900;
  line-height: 1.1;
}

.admin-hero-row span {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
}

.admin-hero-row .btn {
  flex: none;
}

/* ---------- 区块标题 ---------- */

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 14px;
}

.section-head h2 {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -0.01em;
  margin-top: 3px;
}

.section-head h3 {
  font-size: 17px;
  font-weight: 800;
  margin-top: 3px;
}

/* ---------- 筛选 chips ---------- */

.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin-bottom: 14px;
  scrollbar-width: none;
}

.chips::-webkit-scrollbar {
  display: none;
}

.chip {
  flex: none;
  padding: 8px 15px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
  transition: 0.18s ease;
}

.chip.is-active {
  color: #171208;
  background: var(--gold);
  border-color: var(--gold);
  font-weight: 800;
}

/* ---------- 赛事卡片 ---------- */

.match-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.match-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  transition: border 0.2s ease, transform 0.15s ease;
  backdrop-filter: blur(10px);
}

.match-card:active {
  transform: scale(0.995);
}

.match-card--live {
  border-color: rgba(255, 107, 125, 0.4);
}

.match-card--settled {
  opacity: 0.82;
}

.match-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
}

.match-card__tourney {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.match-card__tourney span:last-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.match-card__format {
  flex: none;
  font-family: var(--font-num);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--muted-2);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 2px 7px;
}

.status-pill {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 999px;
}

.status-pill--upcoming {
  color: var(--gold);
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.3);
}

.status-pill--live {
  color: var(--red);
  background: var(--red-soft);
  border: 1px solid rgba(255, 107, 125, 0.35);
}

.status-pill--live::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
  animation: pulse 1.4s ease-in-out infinite;
}

.status-pill--finished {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
}

.status-pill--canceled {
  color: var(--red);
  background: var(--red-soft);
  border: 1px solid rgba(255, 107, 125, 0.3);
}

.team-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 4px 0;
}

.team-badge {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  font-family: var(--font-num);
  font-size: 15px;
  font-weight: 900;
  color: #fff;
  letter-spacing: 0.02em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  background: linear-gradient(145deg, var(--team, #3a4560), rgba(0, 0, 0, 0.45));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 6px 14px rgba(0, 0, 0, 0.4);
}

.team-info {
  flex: 1;
  min-width: 0;
}

.team-info b {
  display: block;
  font-size: 16px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.team-info small {
  font-size: 11.5px;
  color: var(--muted-2);
}

.team-info .winner-mark {
  color: var(--gold);
  font-weight: 700;
}

.odds-btn {
  flex: none;
  min-width: 92px;
  height: 52px;
  padding: 0 12px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  transition: 0.15s ease;
}

.odds-btn:not(:disabled) {
  cursor: pointer;
}

.odds-btn:not(:disabled):active {
  transform: scale(0.96);
}

.odds-btn:disabled {
  opacity: 0.55;
}

.odds-btn.is-picked {
  background: var(--gold-soft);
  border-color: rgba(243, 201, 105, 0.55);
}

.odds-btn.is-win {
  background: var(--green-soft);
  border-color: rgba(85, 217, 138, 0.5);
}

.odds-btn.is-lose {
  background: rgba(255, 255, 255, 0.03);
}

.odds-btn .odds-val {
  font-family: var(--font-num);
  font-size: 19px;
  font-weight: 900;
  line-height: 1;
}

.odds-btn.is-picked .odds-val,
.odds-btn:not(:disabled) .odds-val {
  color: var(--gold);
}

.odds-btn.is-win .odds-val {
  color: var(--green);
}

.odds-btn .odds-label {
  font-size: 10.5px;
  color: var(--muted-2);
  font-weight: 600;
}

.odds-btn .odds-mine {
  font-size: 10px;
  color: var(--gold);
  font-weight: 700;
  margin-top: 2px;
}

.vs-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 6px 0 8px;
  padding-left: 55px;
}

.vs-divider .vs {
  font-family: var(--font-num);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.1em;
  color: var(--muted-2);
}

.vs-divider .line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--line), transparent);
}

.match-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.match-card__time {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}

.match-card__time svg {
  font-size: 14px;
  color: var(--gold);
}

.match-card__time b {
  color: var(--text);
  font-weight: 700;
}

.match-card__pool {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  color: var(--muted-2);
}

.match-card__pool b {
  color: var(--text);
  font-family: var(--font-num);
}

.pool-track {
  flex: none;
  width: 70px;
  height: 5px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  display: flex;
}

.pool-track i {
  height: 100%;
  display: block;
  transition: width 0.4s ease;
}

.pool-track i.a {
  background: var(--gold);
}

.pool-track i.b {
  background: var(--teal);
}

.source-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--muted-2);
}

.source-link svg {
  font-size: 12px;
}

/* ---------- 空状态 ---------- */

.empty {
  text-align: center;
  padding: 42px 24px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
}

.empty__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 26px;
}

.empty h3 {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 6px;
}

.empty p {
  font-size: 13px;
  color: var(--muted);
}

/* ---------- 动态 ---------- */

.feed-card {
  margin-top: 26px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
}

.feed-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 12px;
}

.online-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
}

.online-label i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px rgba(85, 217, 138, 0.8);
}

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.activity-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 6px;
  border-radius: 12px;
  transition: background 0.15s ease;
}

.activity-item + .activity-item {
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.avatar {
  flex: none;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(145deg, var(--hue, #3a4560), rgba(0, 0, 0, 0.4));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.activity-main {
  flex: 1;
  min-width: 0;
}

.activity-main p {
  font-size: 13px;
  line-height: 1.45;
}

.activity-main p b {
  font-weight: 800;
}

.activity-main p .dim {
  color: var(--muted);
}

.activity-main time {
  display: block;
  font-size: 11px;
  color: var(--muted-2);
  margin-top: 2px;
}

.activity-amount {
  flex: none;
  font-family: var(--font-num);
  font-size: 14px;
  font-weight: 800;
  color: var(--gold);
}

.activity-amount.is-neg {
  color: var(--red);
}

/* ---------- 底部导航 ---------- */

.tabbar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  z-index: 60;
  width: min(100%, 560px);
  display: flex;
  background: rgba(9, 13, 22, 0.9);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}

.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 9px 4px 8px;
  color: var(--muted-2);
  font-size: 11px;
  font-weight: 600;
  position: relative;
  transition: color 0.18s ease;
}

.tab__icon {
  width: 34px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  font-size: 20px;
  transition: 0.18s ease;
}

.tab.is-active {
  color: var(--gold);
}

.tab.is-active .tab__icon {
  background: var(--gold-soft);
}

/* ---------- 我的 ---------- */

.profile-card {
  border-radius: var(--radius-lg);
  padding: 20px;
  background: linear-gradient(150deg, #141c2e, #0c1320);
  border: 1px solid var(--line-strong);
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
}

.profile-head {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 18px;
}

.profile-head .avatar {
  width: 54px;
  height: 54px;
  font-size: 23px;
  border-radius: 16px;
}

.profile-head h2 {
  font-size: 20px;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile-head p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.profile-balance {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.profile-balance .coin {
  color: var(--gold);
  font-size: 22px;
  margin-bottom: 6px;
}

.profile-balance strong {
  font-family: var(--font-num);
  font-size: 38px;
  font-weight: 900;
  line-height: 1;
}

.profile-balance .unit {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 4px;
}

.profile-sub {
  display: flex;
  gap: 16px;
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--muted);
}

.profile-sub b {
  color: var(--text);
  font-family: var(--font-num);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 9px;
  margin-bottom: 16px;
}

.stat-cell {
  padding: 13px 6px;
  border-radius: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  text-align: center;
}

.stat-cell strong {
  display: block;
  font-family: var(--font-num);
  font-size: 19px;
  font-weight: 900;
  margin-bottom: 2px;
}

.stat-cell strong.good {
  color: var(--green);
}

.stat-cell strong.bad {
  color: var(--red);
}

.stat-cell span {
  font-size: 11px;
  color: var(--muted-2);
}

.profile-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  margin-bottom: 22px;
}

.profile-actions .btn {
  font-size: 12.5px;
}

.bet-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.bet-tabs button {
  padding: 8px 15px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
}

.bet-tabs button.is-active {
  color: #171208;
  background: var(--gold);
  border-color: var(--gold);
  font-weight: 800;
}

.bet-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bet-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 14px;
}

.bet-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 11px;
}

.bet-card__teams {
  font-size: 14px;
  font-weight: 800;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bet-card__side {
  flex: none;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
}

.bet-card__side.is-a { color: var(--gold); border-color: rgba(243,201,105,.3); }
.bet-card__side.is-b { color: var(--teal); border-color: rgba(61,219,195,.3); }

.bet-card__row {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--muted);
  padding: 3px 0;
}

.bet-card__row b {
  color: var(--text);
  font-family: var(--font-num);
}

.bet-card__row .good { color: var(--green); }
.bet-card__row .bad { color: var(--red); }

/* ---------- 榜单 ---------- */

.rank-head {
  margin-bottom: 16px;
}

.rank-head h2 {
  font-size: 21px;
  font-weight: 900;
  margin-top: 3px;
}

.podium {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
  padding-top: 8px;
}

.podium__slot {
  flex: 1;
  max-width: 150px;
  text-align: center;
}

.podium__avatar {
  width: 64px;
  height: 64px;
  margin: 0 auto 9px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  font-size: 25px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(145deg, var(--hue, #3a4560), rgba(0, 0, 0, 0.45));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 10px 26px rgba(0, 0, 0, 0.45);
}

.podium__slot--1 .podium__avatar {
  width: 78px;
  height: 78px;
  border-radius: 24px;
  font-size: 30px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.2), 0 0 0 2px rgba(243,201,105,.4), 0 14px 34px rgba(243,201,105,.22);
}

.podium__name {
  font-size: 13.5px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.podium__assets {
  font-family: var(--font-num);
  font-size: 16px;
  font-weight: 900;
  color: var(--gold);
  margin-top: 2px;
}

.podium__rank {
  display: inline-block;
  margin-top: 6px;
  font-family: var(--font-num);
  font-size: 11px;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
}

.podium__slot--1 .podium__rank {
  color: #171208;
  background: var(--gold);
  border-color: var(--gold);
}

.rank-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rank-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 13px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.rank-row.is-me {
  border-color: rgba(243, 201, 105, 0.45);
  background: var(--gold-soft);
}

.rank-row__num {
  flex: none;
  width: 26px;
  font-family: var(--font-num);
  font-size: 14px;
  font-weight: 800;
  color: var(--muted);
  text-align: center;
}

.rank-row .avatar {
  width: 38px;
  height: 38px;
  font-size: 16px;
}

.rank-row__info {
  flex: 1;
  min-width: 0;
}

.rank-row__info b {
  font-size: 14px;
  font-weight: 800;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-row__info small {
  font-size: 11px;
  color: var(--muted-2);
}

.rank-row__assets {
  text-align: right;
}

.rank-row__assets strong {
  font-family: var(--font-num);
  font-size: 15px;
  font-weight: 800;
  display: block;
}

.rank-row__assets small {
  font-size: 10.5px;
  color: var(--muted-2);
}

.rank-invite {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  border: 1px dashed var(--line-strong);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.02);
}

.rank-invite__mark {
  flex: none;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: var(--gold);
  background: var(--gold-soft);
  font-size: 19px;
}

.rank-invite > div:nth-child(2) {
  flex: 1;
  min-width: 0;
}

.rank-invite b {
  font-size: 13.5px;
}

.rank-invite p {
  font-size: 11px;
  color: var(--muted-2);
  margin-top: 2px;
}

.rank-invite .btn {
  flex: none;
}

/* ---------- 管理后台 ---------- */

.admin-hero {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-radius: var(--radius);
  background: linear-gradient(150deg, #14202e, #0c1320);
  border: 1px solid var(--line-strong);
  margin-bottom: 16px;
}

.admin-hero .brand-mark {
  width: 46px;
  height: 46px;
  font-size: 24px;
}

.admin-hero h2 {
  font-size: 19px;
  font-weight: 900;
}

.admin-hero p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  margin-bottom: 16px;
}

.kpi {
  padding: 14px 12px;
  border-radius: 15px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.kpi strong {
  display: block;
  font-family: var(--font-num);
  font-size: 22px;
  font-weight: 900;
  margin: 2px 0;
}

.kpi span {
  font-size: 11px;
  color: var(--muted-2);
}

.admin-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  overflow-x: auto;
  scrollbar-width: none;
}

.admin-tabs::-webkit-scrollbar { display: none; }

.admin-tabs button {
  flex: none;
  padding: 9px 16px;
  border-radius: 11px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
}

.admin-tabs button.is-active {
  color: var(--gold);
  border-color: rgba(243, 201, 105, 0.45);
  background: var(--gold-soft);
}

.admin-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
}

.copy-board {
  margin-bottom: 16px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(61, 219, 195, 0.045);
  border: 1px solid rgba(61, 219, 195, 0.18);
}

.copy-board__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.copy-board__head b {
  display: block;
  margin-top: 3px;
  font-size: 14px;
}

.copy-board__controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.copy-board__controls .select-wrap {
  flex: 1;
  min-width: 0;
}

.copy-board__controls .select-wrap select {
  height: 40px;
  font-size: 12px;
}

.copy-board__controls .btn {
  flex: none;
  min-height: 40px;
}

.copy-board__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.copy-board__actions .help-text {
  flex: 1;
  min-width: 160px;
  margin: 0;
}

.import-help {
  margin-bottom: 14px;
  padding: 12px;
  border-radius: 12px;
  background: var(--teal-soft);
  border: 1px solid rgba(61, 219, 195, 0.2);
}

.import-help b {
  font-size: 13px;
  color: var(--teal);
}

.import-help p {
  margin-top: 4px;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--muted);
}

.template-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.admin-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.admin-panel__head h3 {
  font-size: 16px;
  font-weight: 800;
}

.admin-match {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 10px;
  background: rgba(255, 255, 255, 0.02);
}

.admin-match__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.admin-match__teams {
  font-size: 13.5px;
  font-weight: 800;
}

.admin-match__actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.admin-player {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.admin-player:last-child {
  border-bottom: 0;
}

.admin-player .avatar {
  width: 40px;
  height: 40px;
}

.admin-player__info {
  flex: 1;
  min-width: 0;
}

.admin-player__info b {
  font-size: 14px;
  font-weight: 800;
}

.admin-player__info small {
  display: block;
  font-size: 11px;
  color: var(--muted-2);
}

.admin-player__coins {
  font-family: var(--font-num);
  font-size: 14px;
  font-weight: 800;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 12px;
}

.form-grid .span-2 {
  grid-column: span 2;
}

.select-wrap {
  position: relative;
  display: block;
}

.select-wrap::after {
  content: "";
  position: absolute;
  right: 15px;
  top: 50%;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid var(--muted);
  border-bottom: 1.5px solid var(--muted);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.select-wrap select {
  width: 100%;
  height: 48px;
  padding: 0 36px 0 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 15px;
  color: var(--text);
  appearance: none;
  outline: none;
}

.select-wrap select option {
  background: var(--panel-solid);
  color: var(--text);
}

.textarea-wrap textarea {
  width: 100%;
  min-height: 110px;
  padding: 12px 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 13px;
  color: var(--text);
  resize: vertical;
  outline: none;
  line-height: 1.6;
}

.help-text {
  font-size: 11.5px;
  color: var(--muted-2);
  margin-top: 8px;
  line-height: 1.6;
}

/* ---------- 弹窗 ---------- */

.modal-layer {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 5, 10, 0.7);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease;
}

.modal-panel {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  max-height: 90dvh;
  overflow-y: auto;
  background: #101724;
  border: 1px solid var(--line-strong);
  border-bottom: 0;
  border-radius: 26px 26px 0 0;
  padding: 8px 18px calc(20px + env(safe-area-inset-bottom));
  box-shadow: var(--shadow);
  animation: slideUp 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes slideUp {
  from { transform: translateY(40px); opacity: 0.4; }
  to { transform: none; opacity: 1; }
}

.modal-grab {
  width: 40px;
  height: 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.15);
  margin: 6px auto 14px;
}

.modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.modal-head h3 {
  font-size: 18px;
  font-weight: 900;
}

.modal-head p {
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 3px;
}

.modal-close {
  width: 34px;
  height: 34px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--muted);
  background: var(--panel-soft);
  font-size: 16px;
}

/* 下注面板 */
.bet-match {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border-radius: 15px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  margin-bottom: 16px;
}

.bet-match .team-badge {
  width: 40px;
  height: 40px;
  font-size: 13px;
  border-radius: 12px;
}

.bet-match__names {
  flex: 1;
  min-width: 0;
  font-size: 14.5px;
  font-weight: 800;
}

.bet-match__names small {
  display: block;
  font-size: 11px;
  color: var(--muted-2);
  font-weight: 500;
}

.bet-side-badge {
  flex: none;
  font-size: 12px;
  font-weight: 800;
  padding: 5px 10px;
  border-radius: 10px;
  color: var(--gold);
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.35);
}

.bet-odds-strip {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.bet-odds-strip .big-odds {
  font-family: var(--font-num);
  font-size: 34px;
  font-weight: 900;
  color: var(--gold);
  line-height: 1;
}

.bet-odds-strip .meta {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
}

.bet-odds-strip .meta .lock {
  color: var(--teal);
  font-weight: 700;
}

.pool-bet-info {
  margin: -6px 0 16px;
  padding: 10px 12px;
  border-radius: 11px;
  background: var(--teal-soft);
  border: 1px solid rgba(61, 219, 195, 0.22);
  color: var(--teal);
  font-size: 11.5px;
  line-height: 1.5;
}

.stake-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 0 14px;
}

.stake-input-row:focus-within {
  border-color: rgba(243, 201, 105, 0.5);
}

.stake-input-row svg {
  color: var(--gold);
  font-size: 19px;
}

.stake-input-row input {
  flex: 1;
  min-width: 0;
  height: 56px;
  background: none;
  border: 0;
  outline: none;
  font-family: var(--font-num);
  font-size: 24px;
  font-weight: 900;
  color: var(--text);
}

.stake-input-row span {
  font-size: 13px;
  color: var(--muted);
}

.stake-cap {
  font-size: 12px;
  color: var(--muted-2);
  margin: 8px 2px 12px;
}

.stake-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.stake-chip {
  flex: 1;
  min-width: 60px;
  height: 40px;
  border-radius: 11px;
  font-family: var(--font-num);
  font-size: 13.5px;
  font-weight: 700;
  color: var(--muted);
  background: var(--panel-soft);
  border: 1px solid var(--line);
}

.stake-chip.is-active {
  color: var(--gold);
  border-color: rgba(243, 201, 105, 0.45);
  background: var(--gold-soft);
}

.summary-box {
  padding: 13px;
  border-radius: 14px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  margin-bottom: 16px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--muted);
  padding: 4px 0;
}

.summary-row b {
  color: var(--text);
  font-family: var(--font-num);
}

.summary-row--total {
  border-top: 1px solid var(--line);
  margin-top: 6px;
  padding-top: 10px;
  font-size: 14px;
  color: var(--text);
}

.summary-row--total b {
  color: var(--green);
  font-size: 16px;
}

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.modal-actions .btn {
  flex: 1;
}

/* ---------- 提示 ---------- */

.toast-root {
  position: fixed;
  top: calc(env(safe-area-inset-top) + 70px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 400;
  width: min(90vw, 420px);
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 12px 15px;
  border-radius: 13px;
  background: rgba(20, 27, 40, 0.95);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  font-size: 13.5px;
  font-weight: 600;
  animation: toastIn 0.25s ease;
}

.toast.is-success svg { color: var(--green); }
.toast.is-error svg { color: var(--red); }
.toast.is-info svg { color: var(--gold); }

@keyframes toastIn {
  from { opacity: 0; transform: translateY(-12px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

.toast.leaving {
  animation: toastOut 0.25s ease forwards;
}

@keyframes toastOut {
  to { opacity: 0; transform: translateY(-10px) scale(0.96); }
}

.offline-bar {
  position: fixed;
  top: calc(env(safe-area-inset-top) + 70px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 390;
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
  color: #fff;
  background: rgba(255, 107, 125, 0.92);
  box-shadow: var(--shadow);
}

/* ---------- 补充：卡片细节 / 管理 / 弹窗 ---------- */

.match-card__badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: none;
}

.match-card__source {
  flex: none;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--gold);
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.25);
  border-radius: 5px;
  padding: 1px 5px;
}

.match-card__source.is-link {
  text-decoration: none;
  transition: background 0.15s ease;
}

.match-card__source.is-link:active {
  background: rgba(243, 201, 105, 0.25);
}

.demo-tag {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--muted-2);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 1px 5px;
}

.demo-tag--pool {
  color: var(--teal);
  border-color: rgba(61, 219, 195, 0.3);
  background: var(--teal-soft);
}

.time-sep {
  color: var(--muted-2);
}

.match-card__note {
  margin-top: 8px;
  font-size: 10.5px;
  color: var(--muted-2);
  line-height: 1.5;
}

.match-card__note--pool {
  color: var(--teal);
  opacity: 0.8;
}

.vs-small {
  font-family: var(--font-num);
  font-size: 10px;
  font-weight: 800;
  color: var(--muted-2);
  letter-spacing: 0.06em;
}

.bet-pool-hint {
  margin-top: 6px;
  font-size: 10.5px;
  color: var(--teal);
  opacity: 0.8;
}

.bet-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 11px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--muted-2);
}

.bet-card__foot .tag {
  padding: 2px 8px;
  font-size: 10px;
}

.rank-note {
  font-size: 12px;
  color: var(--muted-2);
  margin-top: 5px;
}

.podium__slot.is-me .podium__name {
  color: var(--gold);
}

.podium__slot.is-me .podium__avatar {
  box-shadow: inset 0 1px 0 rgba(255,255,255,.2), 0 0 0 2px rgba(243,201,105,.65), 0 12px 28px rgba(243,201,105,.2);
}

.input {
  width: 100%;
  height: 48px;
  padding: 0 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 14.5px;
  color: var(--text);
  outline: none;
  transition: border 0.2s ease, background 0.2s ease;
}

.input:focus {
  border-color: rgba(243, 201, 105, 0.5);
  background: rgba(255, 255, 255, 0.06);
}

.input::placeholder {
  color: var(--muted-2);
}

.input:disabled,
select:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.input[type="datetime-local"] {
  color-scheme: dark;
  font-size: 13px;
}

.textarea {
  width: 100%;
  min-height: 150px;
  padding: 12px 13px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 12px;
  line-height: 1.65;
  color: var(--text);
  resize: vertical;
  outline: none;
}

.textarea:focus {
  border-color: rgba(243, 201, 105, 0.5);
}

.muted-count {
  font-family: var(--font-num);
  font-size: 12px;
  font-weight: 700;
  color: var(--muted-2);
  margin-left: 4px;
}

.admin-head-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.admin-head-actions .btn {
  padding: 0 9px;
  min-height: 34px;
  font-size: 11.5px;
}

.admin-match__meta {
  font-size: 11px;
  color: var(--muted-2);
  margin-top: 3px;
  line-height: 1.5;
}

.nowrap {
  white-space: nowrap;
}

.admin-match__odds {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 11.5px;
  color: var(--muted-2);
  margin-bottom: 10px;
}

.admin-match__odds b {
  color: var(--text);
  font-family: var(--font-num);
  font-size: 13px;
}

.admin-source {
  padding: 1px 6px;
  border-radius: 5px;
  color: var(--gold);
  background: var(--gold-soft);
  font-size: 10px;
  font-weight: 700;
}

.modal-section {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.modal-section h4 {
  font-size: 14px;
  font-weight: 800;
  margin-bottom: 5px;
}

.modal-section > p {
  font-size: 11.5px;
  color: var(--muted-2);
  line-height: 1.55;
  margin-bottom: 12px;
}

.settle-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.settle-grid .btn {
  padding: 0 8px;
  font-size: 11.5px;
  min-height: 40px;
}

.modal-danger {
  display: flex;
  gap: 7px;
  margin-top: 9px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 107, 125, 0.12);
  flex-wrap: wrap;
}

.modal-danger .btn {
  flex: 1;
  font-size: 11.5px;
}

.confirm-message {
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
  margin-bottom: 18px;
}

.confirm-message b {
  color: var(--gold);
}

.rules {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 20px;
}

.rule {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.rule > span {
  flex: none;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.25);
  color: var(--gold);
  font-family: var(--font-num);
  font-size: 11px;
  font-weight: 800;
}

.rule b {
  display: block;
  font-size: 14px;
  margin-bottom: 3px;
}

.rule p {
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--muted);
}

.invite-hero {
  display: flex;
  gap: 13px;
  align-items: center;
  padding: 14px;
  border-radius: 15px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  margin-bottom: 14px;
}

.invite-icon {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--teal-soft);
  color: var(--teal);
  font-size: 22px;
}

.invite-hero p {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted);
}

.invite-code {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.28);
  margin-bottom: 10px;
}

.invite-code > span {
  flex: none;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
}

.invite-code code {
  flex: 1;
  font-family: var(--font-num);
  font-size: 17px;
  font-weight: 900;
  letter-spacing: 0.14em;
  color: var(--gold);
}

.invite-code button {
  flex: none;
  padding: 5px 10px;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 700;
  color: #171208;
  background: var(--gold);
}

.invite-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 10px;
}

.invite-tag {
  flex: none;
  padding: 2px 6px;
  border-radius: 5px;
  font-size: 9px;
  font-weight: 800;
  color: var(--teal);
  background: var(--teal-soft);
  border: 1px solid rgba(61, 219, 195, 0.25);
}

.invite-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 9px 8px 12px;
  border-radius: 11px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--line);
}

.invite-row code {
  flex: 1;
  min-width: 0;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 11.5px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.invite-row button {
  flex: none;
  padding: 5px 10px;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 700;
  color: var(--gold);
  background: var(--gold-soft);
  border: 1px solid rgba(243, 201, 105, 0.25);
}

.modal-body--flush {
  padding-top: 2px;
}

.modal-open {
  overflow: hidden;
}

.btn svg {
  font-size: 15px;
}

@media (max-width: 390px) {
  .brand-word {
    font-size: 14px;
  }

  .conn-pill {
    padding: 6px 8px;
  }

  .topbar {
    padding-left: 12px;
    padding-right: 12px;
  }

  .main {
    padding-left: 12px;
    padding-right: 12px;
  }

  .match-card {
    padding: 14px;
  }

  .team-badge {
    width: 40px;
    height: 40px;
    font-size: 13px;
  }

  .odds-btn {
    min-width: 82px;
  }

  .topbar__actions {
    gap: 6px;
  }

  .balance-pill {
    padding: 0 10px;
  }

  .hero-card__meta {
    gap: 11px;
    font-size: 11.5px;
  }

  .profile-actions .btn {
    padding: 0 8px;
    font-size: 11.5px;
  }

  .settle-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 380px) {
  .auth-brand .tag {
    display: none;
  }

  .auth-brand__sub {
    font-size: 9px;
    letter-spacing: 0.1em;
  }

  .admin-panel__head {
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 10px;
  }

  .admin-panel__head h3 {
    flex: 1 1 auto;
  }

  .admin-head-actions {
    width: 100%;
    justify-content: stretch;
  }

  .admin-head-actions .btn {
    flex: 1;
    justify-content: center;
  }

  .admin-hero p {
    font-size: 11.5px;
    line-height: 1.45;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .form-grid .span-2 {
    grid-column: auto;
  }
}

/* ---------- 桌面适配 ---------- */

@media (min-width: 640px) {
  body {
    padding: 0;
  }

  .app-shell {
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
    background: rgba(7, 11, 19, 0.5);
    min-height: 100vh;
    min-height: 100dvh;
  }

  .auth-shell {
    padding-top: 40px;
  }

  .modal-layer {
    align-items: center;
    padding: 24px;
  }

  .modal-panel {
    border-radius: 26px;
    border-bottom: 1px solid var(--line-strong);
    max-height: 86vh;
  }
}

@media (max-width: 360px) {
  .hero-card__balance strong {
    font-size: 38px;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .conn-pill span {
    display: none;
  }

  .conn-pill {
    padding: 6px 9px;
  }
}
