:root {
  --bg: #f4f6f9;
  --panel: #ffffff;
  --ink: #16181d;
  --ink-2: #434852;
  --muted: #7b8290;
  --line: #e7eaef;
  --brand: #16c8ff;
  --brand-2: #5b7cff;
  --brand-ink: #0786b4;
  --shadow: 0 6px 24px rgba(22, 30, 45, .08);
  --shadow-lg: 0 18px 60px rgba(22, 30, 45, .16);
  --radius: 14px;
  --wrap: 1240px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  font-size: 14px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(16px); border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: var(--wrap); margin: 0 auto; height: 66px; padding: 0 20px;
  display: flex; align-items: center; gap: 26px;
}
.brand { display: flex; align-items: center; gap: 10px; flex: none; }
.brand-mark {
  width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff; font-weight: 800; font-size: 19px; letter-spacing: -1px;
  box-shadow: 0 6px 16px rgba(22, 200, 255, .35);
}
.brand-mark.small { width: 26px; height: 26px; font-size: 14px; border-radius: 8px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text b { font-size: 16px; letter-spacing: .5px; }
.brand-text i { font-style: normal; font-size: 9px; letter-spacing: 2.4px; color: var(--muted); }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  padding: 7px 13px; border-radius: 9px; color: var(--ink-2); font-weight: 600; font-size: 14px;
}
.nav a:hover { background: #eef2f7; color: var(--ink); }
.nav a.active { color: var(--brand-ink); background: #e6f8ff; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.search { display: flex; align-items: center; gap: 8px; background: #f1f4f8; border: 1px solid transparent;
  border-radius: 10px; padding: 0 12px; height: 40px; width: 260px; transition: .2s; }
.search:focus-within { background: #fff; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(22,200,255,.14); }
.search svg { width: 17px; height: 17px; color: var(--muted); flex: none; }
.search input { border: 0; background: transparent; outline: 0; width: 100%; font-size: 13px; }
.account-slot { display: flex; align-items: center; gap: 8px; }
.lang-btn {
  width: 42px; height: 34px; border-radius: 9px; border: 1px solid var(--line); background: #fff;
  font-size: 12px; font-weight: 700; color: var(--ink-2); transition: .18s; flex: none;
}
.lang-btn:hover { border-color: var(--brand); color: var(--brand-ink); background: #f4fcff; }


/* ---------- 通用 ---------- */
.app { max-width: var(--wrap); margin: 0 auto; padding: 24px 20px 70px; min-height: 60vh; }
.btn {
  border: 0; border-radius: 10px; padding: 10px 18px; font-weight: 700; font-size: 14px;
  background: #eef2f7; color: var(--ink); transition: .18s; white-space: nowrap;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn:hover { background: #e3e9f1; transform: translateY(-1px); }
.btn.primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; box-shadow: 0 8px 22px rgba(22,200,255,.32); }
.btn.primary:hover { filter: brightness(1.05); }
.btn.ghost { background: transparent; border: 1px solid var(--line); }
.btn.ghost:hover { border-color: #c9d2de; background: #fff; }
.btn.small { padding: 6px 12px; font-size: 12.5px; border-radius: 8px; }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn.danger { background: #fff1f1; color: #d33; }
.avatar {
  width: 38px; height: 38px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: linear-gradient(135deg, #e8f8ff, #dfe7ff); color: var(--brand-ink); font-weight: 800;
  border: 1px solid #dbe6f2; overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 72px; height: 72px; font-size: 26px; border-radius: 18px; }
.user-menu { position: relative; }
.user-btn { display: flex; align-items: center; gap: 9px; background: none; border: 0; padding: 4px 6px; border-radius: 10px; }
.user-btn:hover { background: #eef2f7; }
.user-btn b { font-size: 13.5px; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu-pop {
  position: absolute; right: 0; top: calc(100% + 10px); min-width: 180px; background: #fff;
  border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; display: none;
}
.menu-pop.open { display: block; }
.menu-pop a, .menu-pop button {
  display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px;
  border: 0; background: none; font-size: 13.5px; color: var(--ink-2);
}
.menu-pop a:hover, .menu-pop button:hover { background: #f1f5fa; color: var(--ink); }
.menu-pop hr { border: 0; border-top: 1px solid var(--line); margin: 5px 0; }

/* ---------- 首页 Hero ---------- */
.hero {
  position: relative; border-radius: 20px; overflow: hidden; min-height: 360px;
  background: #0b0d12 center/cover no-repeat; box-shadow: var(--shadow-lg);
  display: flex; align-items: flex-end;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(6,8,13,.9) 0%, rgba(6,8,13,.62) 46%, rgba(6,8,13,.12) 78%, rgba(6,8,13,.05) 100%),
              linear-gradient(0deg, rgba(6,8,13,.55), transparent 55%);
}
.hero-body { position: relative; padding: 38px 42px; max-width: 620px; color: #fff; }
.hero-kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; letter-spacing: 1px; color: #9fe8ff; font-weight: 700; margin-bottom: 12px; }
.hero-kicker::before { content: ""; width: 18px; height: 2px; background: var(--brand); border-radius: 2px; }
.hero h1 { margin: 0 0 10px; font-size: 40px; line-height: 1.15; letter-spacing: .5px; }
.hero p { margin: 0 0 18px; color: #cfd6e2; font-size: 14.5px; max-width: 500px; }
.hero-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.hero-tags span { font-size: 12px; padding: 3px 10px; border-radius: 20px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.16); }
.hero-actions { display: flex; align-items: center; gap: 14px; }
.hero-actions .btn.primary { padding: 13px 30px; font-size: 15px; border-radius: 12px; }
.hero-score { display: flex; align-items: baseline; gap: 6px; color: #fff; font-weight: 800; font-size: 26px; }
.hero-score small { font-size: 12px; color: #aeb6c4; font-weight: 500; }

/* ---------- 区块 ---------- */
.section { margin-top: 42px; }
.section-head { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 18px; }
.section-head h2 { margin: 0; font-size: 22px; letter-spacing: .3px; }
.section-head .sub { color: var(--muted); font-size: 13px; }
.section-head .more { margin-left: auto; color: var(--brand-ink); font-weight: 700; font-size: 13px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.chip {
  border: 1px solid var(--line); background: #fff; color: var(--ink-2); border-radius: 20px;
  padding: 7px 16px; font-size: 13px; font-weight: 600; transition: .18s;
}
.chip:hover { border-color: #c6d2e0; }
.chip.active { background: var(--ink); color: #fff; border-color: var(--ink); }

.layout-2col { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 26px; align-items: start; }
.layout-2col > *, .detail-grid > *, .dev-grid > * { min-width: 0; }

/* ---------- 游戏卡片 ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(238px, 1fr)); gap: 20px; }
.card {
  background: var(--panel); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line);
  transition: .22s; display: flex; flex-direction: column; cursor: pointer;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #d8e2ee; }
.card-cover { aspect-ratio: 16 / 9; background: linear-gradient(135deg, #dff4ff, #e5e9ff 60%, #ffe9f3); overflow: hidden; position: relative; }
.card-cover img { width: 100%; height: 100%; object-fit: cover; transition: .3s; }
.card:hover .card-cover img { transform: scale(1.05); }
.card-body { padding: 12px 14px 14px; display: flex; gap: 11px; align-items: flex-start; }
.card-icon {
  width: 44px; height: 44px; border-radius: 11px; overflow: hidden; flex: none;
  background: linear-gradient(135deg, #e8f8ff, #dfe7ff); border: 1px solid var(--line);
  display: grid; place-items: center; font-weight: 800; color: var(--brand-ink); font-size: 17px;
}
.card-icon img { width: 100%; height: 100%; object-fit: cover; }
.card-info { min-width: 0; flex: 1; }
.card-info h3 { margin: 1px 0 3px; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-meta { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.stars { color: #ff9f1c; font-weight: 700; letter-spacing: -.5px; }
.card-tags { display: flex; gap: 6px; margin-top: 7px; flex-wrap: wrap; }
.card-tags span { font-size: 11px; color: #6a7484; background: #f1f5fa; padding: 2px 8px; border-radius: 6px; }
.card-title-line { display: flex; align-items: baseline; gap: 6px; }
.card-title-line small { font-size: 11px; color: var(--muted); font-weight: 600; }

/* ---------- 排行榜 ---------- */
.rank-panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 16px 14px; }
.rank-panel h3 { font-size: 16px; margin: 14px 4px 10px; display: flex; align-items: center; gap: 8px; }
.rank-panel h3 span { color: var(--muted); font-size: 12px; font-weight: 500; }
.rank-item { display: flex; align-items: center; gap: 12px; padding: 9px 4px; border-radius: 10px; cursor: pointer; }
.rank-item:hover { background: #f5f8fb; }
.rank-no { width: 24px; text-align: center; font-weight: 800; color: #a7b0be; font-size: 14px; }
.rank-item:nth-child(2) .rank-no { color: #ff8a00; }
.rank-item:nth-child(3) .rank-no { color: #ff5f6d; }
.rank-item:nth-child(4) .rank-no { color: #15b0d8; }
.rank-icon { width: 38px; height: 38px; border-radius: 10px; overflow: hidden; background: #eef3fa; flex: none; }
.rank-icon img { width: 100%; height: 100%; object-fit: cover; }
.rank-info { min-width: 0; flex: 1; }
.rank-info b { display: block; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-info small { color: var(--muted); font-size: 11.5px; }

/* ---------- 详情页 ---------- */
.detail-hero { position: relative; border-radius: 20px; overflow: hidden; min-height: 290px; background: #0b0d12 center/cover; }
.detail-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,10,15,.25), rgba(8,10,15,.86)); }
.detail-head { position: relative; z-index: 2; display: flex; gap: 22px; align-items: flex-end; padding: 34px 38px; color: #fff; margin-top: -150px; }
.detail-icon { width: 104px; height: 104px; border-radius: 22px; overflow: hidden; border: 3px solid rgba(255,255,255,.25); background: #fff; box-shadow: var(--shadow-lg); flex: none; }
.detail-icon img { width: 100%; height: 100%; object-fit: cover; }
.detail-title h1 { margin: 0 0 5px; font-size: 32px; line-height: 1.2; }
.detail-title .sub { color: #c3cbd8; font-size: 13.5px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.detail-title .tags { display: flex; gap: 7px; margin-top: 10px; flex-wrap: wrap; }
.detail-title .tags span { font-size: 12px; padding: 3px 10px; border-radius: 20px; background: rgba(255,255,255,.13); }
.detail-actions { margin-left: auto; display: flex; gap: 10px; align-items: center; padding-bottom: 6px; }
.detail-actions .btn.primary { padding: 13px 30px; font-size: 15px; }

.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 26px; margin-top: 26px; align-items: start; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.panel h2 { font-size: 17px; margin: 0 0 14px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.tabs button { border: 0; background: none; padding: 11px 16px; font-weight: 700; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs button.active { color: var(--ink); border-color: var(--brand); }
.prose { white-space: pre-wrap; color: var(--ink-2); font-size: 14px; line-height: 1.85; }
.shots { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(280px, 340px); gap: 12px; overflow-x: auto; padding-bottom: 8px; margin-top: 20px; }
.shots img { border-radius: 10px; aspect-ratio: 16/9; object-fit: cover; border: 1px solid var(--line); }
.info-row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.info-row:last-child { border-bottom: 0; }
.info-row span { color: var(--muted); }
.info-row b { font-weight: 600; text-align: right; }
.notice { background: #f0faff; border: 1px solid #cdeeff; color: #0f6f8c; border-radius: 10px; padding: 11px 13px; font-size: 12.5px; line-height: 1.7; margin-top: 14px; }

/* ---------- 评价 ---------- */
.review-form { background: #f7f9fc; border: 1px solid var(--line); border-radius: 12px; padding: 16px; margin-bottom: 20px; }
.star-pick { display: flex; gap: 4px; margin-bottom: 10px; font-size: 26px; color: #d5dbe4; }
.star-pick button { border: 0; background: none; font-size: 26px; line-height: 1; color: inherit; padding: 0 1px; }
.star-pick button.on { color: #ff9f1c; }
.review-form textarea { width: 100%; min-height: 76px; resize: vertical; border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px; outline: 0; background: #fff; }
.review-form textarea:focus { border-color: var(--brand); }
.review-form .row { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }
.review { display: flex; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.review:last-child { border-bottom: 0; }
.review .who { font-weight: 700; font-size: 13.5px; }
.review .when { color: var(--muted); font-size: 11.5px; margin-left: 8px; font-weight: 400; }
.review p { margin: 4px 0 0; color: var(--ink-2); font-size: 13.5px; }
.rating-big { display: flex; align-items: center; gap: 16px; margin-bottom: 8px; }
.rating-big .score { font-size: 42px; font-weight: 800; line-height: 1; }
.dist-row { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); margin: 4px 0; }
.dist-bar { flex: 1; height: 6px; border-radius: 6px; background: #eef2f7; overflow: hidden; }
.dist-bar i { display: block; height: 100%; background: #ffb020; border-radius: 6px; }

/* ---------- 认证页 ---------- */
.auth-wrap { max-width: 460px; margin: 40px auto 0; }
.auth-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 30px 32px; }
.auth-card h1 { font-size: 24px; margin: 0 0 4px; }
.auth-card .lead { color: var(--muted); font-size: 13px; margin: 0 0 22px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12.5px; font-weight: 700; color: var(--ink-2); margin-bottom: 6px; }
.field input, .field textarea, .field select {
  width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 11px 13px;
  outline: 0; background: #fbfcfe; transition: .18s;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--brand); background: #fff; box-shadow: 0 0 0 3px rgba(22,200,255,.12); }
.field textarea { min-height: 96px; resize: vertical; }
.field .hint { font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.auth-switch { text-align: center; margin-top: 16px; color: var(--muted); font-size: 13px; }
.auth-switch a { color: var(--brand-ink); font-weight: 700; }
.auth-card .btn { width: 100%; padding: 12px; margin-top: 6px; }
.form-error { color: #d33; font-size: 12.5px; min-height: 18px; margin: 4px 0 8px; }

/* ---------- 开发者中心 ---------- */
.dev-head { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.dev-head h1 { margin: 0; font-size: 26px; }
.dev-head p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.dev-grid { display: grid; grid-template-columns: minmax(0, 1fr) 430px; gap: 24px; align-items: start; }
.dev-game { display: flex; gap: 14px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px; background: #fff; }
.dev-game .meta { flex: 1; min-width: 0; }
.dev-game h3 { margin: 0 0 3px; font-size: 15px; }
.dev-game .tagline { color: var(--muted); font-size: 12px; }
.cred { margin-top: 10px; background: #f7f9fc; border: 1px dashed #d7e0ea; border-radius: 9px; padding: 10px 12px; font-size: 12px; }
.cred div { display: flex; gap: 8px; align-items: center; margin: 3px 0; min-width: 0; }
.cred code { min-width: 0; font-family: ui-monospace, Consolas, monospace; background: #fff; border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
.cred .btn { flex: none; }
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; position: sticky; top: 90px; }
.form-card h2 { margin: 0 0 4px; font-size: 18px; }
.form-card .lead { color: var(--muted); font-size: 12.5px; margin: 0 0 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.empty { text-align: center; color: var(--muted); padding: 40px 20px; border: 1px dashed var(--line); border-radius: 12px; }

/* ---------- 其他 ---------- */
.page-title { display: flex; align-items: baseline; gap: 12px; margin: 4px 0 20px; }
.page-title h1 { font-size: 26px; margin: 0; }
.page-title span { color: var(--muted); font-size: 13px; }
.loading { text-align: center; color: var(--muted); padding: 60px 0; }
.toast {
  position: fixed; left: 50%; bottom: 40px; transform: translate(-50%, 20px); z-index: 100;
  background: rgba(20,24,32,.92); color: #fff; padding: 11px 20px; border-radius: 10px;
  font-size: 13.5px; opacity: 0; pointer-events: none; transition: .25s; max-width: 80vw;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.footer { border-top: 1px solid var(--line); background: #fff; margin-top: 30px; }
.footer-inner { max-width: var(--wrap); margin: 0 auto; padding: 30px 20px; color: var(--muted); font-size: 12.5px; }
.footer-brand { display: flex; align-items: center; gap: 9px; font-weight: 800; color: var(--ink); font-size: 14px; margin-bottom: 8px; }
.footer-meta a { color: var(--brand-ink); }

/* ---------- 响应式 ---------- */
@media (max-width: 1080px) {
  .layout-2col, .detail-grid, .dev-grid { grid-template-columns: 1fr; }
  .rank-panel { order: 2; }
  .search { width: 190px; }
}
@media (max-width: 860px) {
  .nav { display: none; }
  .topbar-inner { gap: 14px; }
  .search { width: 150px; }
  .hero h1 { font-size: 30px; }
  .hero-body { padding: 26px 24px; }
  .detail-hero { min-height: 210px; border-radius: 16px 16px 0 0; }
  .detail-head {
    flex-wrap: wrap; padding: 18px 20px 20px; margin-top: 0; gap: 14px;
    background: #fff; border: 1px solid var(--line); border-top: 0;
    border-radius: 0 0 16px 16px; color: var(--ink);
  }
  .detail-actions { margin-left: 0; width: 100%; }
  .detail-icon { width: 78px; height: 78px; border-radius: 18px; }
  .detail-title h1 { font-size: 23px; }
  .detail-title .sub { color: var(--muted); }
  .detail-title .tags span { background: #eef3fa; color: var(--ink-2); }
}
@media (max-width: 620px) {
  .app { padding: 16px 14px 50px; }
  .brand-text i { display: none; }
  .brand-text b { font-size: 14px; }
  .search { display: none; }
  .user-btn b { display: none; }
  .topbar-inner { gap: 8px; padding: 0 14px; }
  .lang-btn { width: 38px; }
  .hero { min-height: 300px; }
  .grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .card-body { padding: 10px; gap: 8px; }
  .card-icon { width: 34px; height: 34px; border-radius: 9px; font-size: 14px; }
  .card-info h3 { font-size: 13.5px; }
  .card-tags { display: none; }
  .form-row { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  .grid { grid-template-columns: 1fr; }
}

/* ============ TapTap 式布局：左侧导航 + 内容流 ============ */
body { background: #f6f8fb; }
.shell { display: flex; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; width: 210px; flex: none; background: #fff;
  border-right: 1px solid var(--line); padding: 18px 12px 14px; display: flex; flex-direction: column; gap: 4px; z-index: 60;
}
.sidebar .brand { padding: 4px 10px 18px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px;
  color: var(--ink-2); font-weight: 600; font-size: 14px; white-space: nowrap;
}
.side-nav a:hover { background: #f2f6fb; color: var(--ink); }
.side-nav a.active { background: #e8f8ff; color: var(--brand-ink); }
.side-sep { height: 1px; background: var(--line); margin: 10px 8px; }
.side-foot { margin-top: auto; padding: 10px 12px 2px; color: var(--muted); font-size: 11.5px; line-height: 1.6; }
.content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--line);
  backdrop-filter: none;
}
.topbar-inner { max-width: 1240px; height: 68px; padding: 0 24px; gap: 18px; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.search { width: 420px; max-width: 46vw; }
.app { width: 100%; max-width: 1240px; padding: 24px 24px 46px; }
.footer { border-top: 1px solid var(--line); background: #fff; margin-top: auto; }
.footer-inner { max-width: 1240px; padding: 26px 24px; }

/* Hero 三格 */
.hero-row { display: grid; grid-template-columns: minmax(0, 2.1fr) minmax(0, 1fr); gap: 14px; }
.hero-main {
  position: relative; border-radius: 18px; overflow: hidden; min-height: 372px;
  background: #0b0d12 center/cover no-repeat; display: flex; align-items: flex-end; box-shadow: var(--shadow);
}
.hero-main::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(6,8,13,.88) 0%, rgba(6,8,13,.5) 52%, rgba(6,8,13,.06) 82%),
              linear-gradient(0deg, rgba(6,8,13,.6), transparent 58%);
}
.hero-main .hero-body { position: relative; padding: 30px 34px; color: #fff; max-width: 560px; }
.hero-main h1 { margin: 0 0 8px; font-size: 36px; line-height: 1.16; }
.hero-main p { margin: 0 0 14px; color: #cfd6e2; font-size: 14px; }
.hero-side { display: grid; grid-template-rows: 1fr 1fr; gap: 14px; min-width: 0; }
.mini-card {
  position: relative; border-radius: 16px; overflow: hidden; background: #0b0d12 center/cover no-repeat;
  display: flex; align-items: flex-end; padding: 16px; color: #fff; min-height: 0;
}
.mini-card::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(6,8,13,.82), rgba(6,8,13,.12) 70%);
}
.mini-card .mc-body { position: relative; display: flex; align-items: center; gap: 10px; min-width: 0; }
.mini-card .mc-body b { display: block; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-card .mc-body small { color: #c2cad7; font-size: 11.5px; }
.mini-card .mc-tag {
  position: absolute; top: 12px; left: 12px; font-size: 11px; padding: 3px 9px; border-radius: 20px;
  background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.16);
}
.mini-cta { background: linear-gradient(135deg, #eaf9ff, #eef1ff 60%, #ffeef7); color: var(--ink); display: flex; }
.mini-cta::before { display: none; }
.mini-cta .mc-cta { position: relative; }
.mini-cta h3 { margin: 0 0 6px; font-size: 18px; }
.mini-cta p { margin: 0 0 12px; color: var(--muted); font-size: 12.5px; }

/* 榜单双列 */
.rank-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); column-gap: 26px; }
.rank-panel .rank-item { border-bottom: 1px dashed transparent; }

@media (max-width: 1100px) {
  .sidebar { width: 176px; }
  .search { width: 300px; }
  .hero-main { min-height: 320px; }
  .hero-main h1 { font-size: 30px; }
}
@media (max-width: 900px) {
  .shell { display: block; }
  .sidebar {
    position: sticky; top: 0; height: auto; width: auto; flex-direction: row; align-items: center;
    overflow-x: auto; padding: 8px 12px; gap: 4px; border-right: 0; border-bottom: 1px solid var(--line);
  }
  .sidebar .brand { display: none; }
  .side-nav { flex-direction: row; gap: 2px; }
  .side-sep, .side-foot { display: none; }
  .side-nav a { padding: 8px 11px; font-size: 13.5px; }
  .topbar { position: static; }
  .topbar-inner { height: 56px; padding: 0 14px; }
  .search { display: none; }
  .app { padding: 16px 14px 40px; }
  .hero-row { grid-template-columns: 1fr; }
  .hero-main { min-height: 268px; }
  .hero-main .hero-body { padding: 22px 20px; }
  .hero-main h1 { font-size: 26px; }
  .hero-side { grid-template-columns: 1fr 1fr; grid-template-rows: auto; }
  .mini-card { min-height: 126px; }
  .rank-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .hero-side { grid-template-columns: 1fr; }
  .footer-inner { padding: 22px 16px; }
}

/* ---------- 我的 ---------- */
.stat-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 0 0 24px; }
.stat-row .stat { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; box-shadow: var(--shadow); }
.stat-row .stat b { display: block; font-size: 24px; letter-spacing: .3px; }
.stat-row .stat span { color: var(--muted); font-size: 12.5px; }
@media (max-width: 620px) { .stat-row { grid-template-columns: 1fr; gap: 10px; } }

/* ============ v2：三端下载 / 管理后台 / 移动端适配 ============ */
.badge {
  display: inline-flex; align-items: center; padding: 2px 9px; border-radius: 999px;
  background: #eef3fa; color: var(--ink-2); font-size: 12px; font-weight: 700;
}
.st-online, .st-approved, .st-paid, .st-active { background: #e5f8ee; color: #0a7b46; }
.st-pending, .st-open { background: #fff4e0; color: #a35b00; }
.st-rejected, .st-offline, .st-offlined, .st-banned, .st-failed { background: #fdeaea; color: #b3261e; }
.st-warned, .st-refunded, .st-dismissed { background: #eef0ff; color: #4447a8; }
.st-admin { background: #e6f8ff; color: var(--brand-ink); }
.st-developer { background: #f0ecff; color: #6a3fd1; }

.admin-tabs {
  display: flex; gap: 4px; overflow-x: auto; padding: 6px; margin-bottom: 16px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
}
.admin-tabs a {
  padding: 8px 14px; border-radius: 8px; font-size: 13px; font-weight: 700; color: var(--ink-2); white-space: nowrap;
}
.admin-tabs a.active { background: #e6f8ff; color: var(--brand-ink); }
.admin-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.stat-cell { padding: 18px 20px; }
.stat-cell b { display: block; font-size: 26px; letter-spacing: -.5px; }
.stat-cell span { color: var(--muted); font-size: 12.5px; }

.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 680px; }
.data-table th, .data-table td { padding: 11px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data-table th { background: #f8fafc; color: var(--muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table td a { color: var(--brand-ink); }

.client-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.client-card { padding: 22px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.client-ico { font-size: 40px; line-height: 1; margin-bottom: 4px; }
.client-card h2 { font-size: 16px; margin: 0; }
.client-card .lead { font-size: 12.5px; min-height: 20px; margin: 0; }
.client-card .btn { margin-top: 10px; width: 100%; }
.platform-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.flat-select {
  border: 1px solid var(--line); border-radius: 9px; padding: 8px 10px; background: #fff; font-size: 13px;
}

.mobile-tabs { display: none; }
@media (max-width: 860px) {
  .sidebar { display: none; }
  .shell { display: block; }
  .app { padding-bottom: 82px; }
  body { padding-bottom: 0; }
  .mobile-tabs {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 80;
    background: rgba(255,255,255,.96); border-top: 1px solid var(--line);
    padding: 4px 4px calc(4px + env(safe-area-inset-bottom));
    backdrop-filter: saturate(180%) blur(14px);
  }
  .mobile-tabs a {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 1px;
    padding: 6px 0; font-size: 11px; color: var(--muted); border-radius: 8px; font-weight: 600;
  }
  .mobile-tabs a i { font-style: normal; font-size: 18px; line-height: 1.2; }
  .mobile-tabs a.active { color: var(--brand-ink); }
  .client-grid { grid-template-columns: 1fr 1fr; }
  .admin-stats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .client-grid { grid-template-columns: 1fr; }
  .admin-stats { grid-template-columns: 1fr; }
}
