/* 分发站样式 —— 基于 finance-ui 设计令牌(Apple 风,#007AFF) */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  background: var(--background, #f5f5f7);
  color: var(--foreground, #1d1d1f);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
.ic { width: 1em; height: 1em; vertical-align: -0.125em; }

/* 顶栏:iOS 毛玻璃 */
.nav {
  position: sticky; top: 0; z-index: 10;
  backdrop-filter: saturate(180%) blur(20px);
  background: color-mix(in srgb, var(--background) 78%, transparent);
  border-bottom: 1px solid var(--border, #e5e5ea);
}
.nav-inner {
  max-width: 980px; margin: 0 auto; padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-title { font-size: 17px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.nav-title .ic { color: var(--brand-500, #007AFF); font-size: 20px; }
.nav a.link { color: var(--brand-500, #007AFF); font-size: 14px; }

.wrap { max-width: 980px; margin: 0 auto; padding: 28px 20px 60px; }

/* 首页卡片网格 */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.card {
  background: var(--card, #fff); border: 1px solid var(--border, #e5e5ea);
  border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
  transition: transform .15s ease, box-shadow .15s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.card-head { display: flex; align-items: center; gap: 14px; }
.appicon {
  width: 60px; height: 60px; border-radius: 14px; object-fit: cover; flex: none;
  border: 1px solid var(--border, #e5e5ea);
}
.card h3 { font-size: 16px; font-weight: 600; }
.card .meta { font-size: 13px; color: var(--muted-foreground, #86868b); margin-top: 3px; }
.card p.desc {
  font-size: 13px; color: var(--muted-foreground, #86868b); line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* 徽章 */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; font-weight: 500; padding: 2px 10px; border-radius: 999px;
}
.badge.ios { background: var(--brand-50, #e8f2ff); color: var(--brand-600, #0071e3); }
.badge.android { background: #e8f9ee; color: #248a3d; }
.badge.gray { background: var(--muted, #f5f5f7); color: var(--muted-foreground, #86868b); }

/* 按钮:Apple 系统蓝 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 15px; font-weight: 500; padding: 10px 20px; border-radius: 12px;
  border: none; cursor: pointer; transition: opacity .15s;
}
.btn:hover { opacity: .85; }
.btn-primary { background: var(--brand-500, #007AFF); color: #fff; }
.btn-secondary {
  background: var(--muted, #f5f5f7); color: var(--brand-500, #007AFF);
}
.btn-danger { background: #fff1f0; color: var(--state-error-500, #FF3B30); }
.btn-sm { font-size: 13px; padding: 6px 12px; border-radius: 9px; }

/* 详情页 */
.hero { display: flex; gap: 20px; align-items: center; margin-bottom: 24px; }
.hero .appicon { width: 96px; height: 96px; border-radius: 22px; }
.hero h1 { font-size: 24px; font-weight: 700; }
.panel {
  background: var(--card, #fff); border: 1px solid var(--border, #e5e5ea);
  border-radius: 18px; padding: 20px; margin-bottom: 16px;
}
.panel h2 { font-size: 15px; font-weight: 600; margin-bottom: 12px; }
.vrow {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 0; border-top: 1px solid var(--border, #e5e5ea); font-size: 14px;
}
.vrow:first-of-type { border-top: none; }
.hint { font-size: 13px; color: var(--muted-foreground, #86868b); line-height: 1.7; }
.hint ol { padding-left: 18px; }

/* 表单与表格(后台) */
.form { display: grid; gap: 12px; }
.form label { font-size: 13px; font-weight: 500; display: block; margin-bottom: 4px; }
.form input, .form select, .form textarea {
  width: 100%; font-size: 14px; padding: 9px 12px; border-radius: 10px;
  border: 1px solid var(--border, #d2d2d7); background: var(--card, #fff); color: inherit;
}
.form input:focus, .form select:focus, .form textarea:focus {
  outline: none; border-color: var(--brand-500, #007AFF);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-500) 22%, transparent);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; color: var(--muted-foreground, #86868b); font-weight: 500; padding: 8px 10px; }
td { padding: 10px; border-top: 1px solid var(--border, #e5e5ea); vertical-align: middle; }
.error {
  background: #fff1f0; color: var(--state-error-500, #FF3B30);
  border-radius: 10px; padding: 10px 14px; font-size: 13px; margin-bottom: 12px;
}
.center { text-align: center; }
.mt { margin-top: 16px; }
.login-box { max-width: 360px; margin: 80px auto 0; }

/* ===== App Store 风格 ===== */
.topbar {
  position: sticky; top: 0; z-index: 10; display: flex; justify-content: space-between;
  padding: 12px 16px; backdrop-filter: saturate(180%) blur(20px);
  background: color-mix(in srgb, var(--background) 82%, transparent);
  border-bottom: 1px solid var(--border, #e5e5ea);
}
.topbar .iconbtn { color: var(--brand-500, #007AFF); font-size: 20px; }
.bigtitle { font-size: 30px; font-weight: 800; letter-spacing: -.5px; margin-bottom: 14px; }

.appstore-head { display: flex; gap: 16px; padding: 8px 0 4px; }
.appstore-head .appicon { width: 108px; height: 108px; border-radius: 24px; }
.appstore-head h1 { font-size: 21px; font-weight: 700; line-height: 1.2; }
.appstore-head .sub { font-size: 14px; color: var(--muted-foreground, #86868b); margin-top: 2px; }
.getbtn {
  display: inline-block; background: var(--brand-500, #007AFF); color: #fff;
  font-size: 14px; font-weight: 700; padding: 5px 18px; border-radius: 999px; margin-top: 8px;
}
.getbtn:hover { opacity: .85; }
.getsub { display: block; font-size: 10px; color: var(--muted-foreground, #86868b); text-align: center; margin-top: 2px; }

.meter-row { display: flex; padding: 14px 0; border-bottom: 1px solid var(--border, #e5e5ea); }
.meter { flex: 1; text-align: center; font-size: 11px; color: var(--muted-foreground, #86868b); }
.meter + .meter { border-left: 1px solid var(--border, #e5e5ea); }
.meter b { display: block; font-size: 17px; color: var(--muted-foreground, #86868b); font-weight: 600; margin-bottom: 3px; }
.meter .cap { text-transform: uppercase; letter-spacing: .3px; }

.shots { display: flex; gap: 12px; overflow-x: auto; padding: 16px 0; scrollbar-width: none; }
.shots::-webkit-scrollbar { display: none; }
.shots img { height: 380px; border-radius: 22px; border: 1px solid var(--border, #e5e5ea); flex: none; }

.sec { border-bottom: 1px solid var(--border, #e5e5ea); padding: 16px 0; }
.sec > h2 {
  font-size: 20px; font-weight: 700; display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px; color: var(--foreground, #1d1d1f);
}
.sec > h2 .chev { color: var(--muted-foreground, #86868b); font-size: 16px; font-weight: 400; }
.desc { font-size: 14px; line-height: 1.6; color: var(--foreground, #1d1d1f); }
.desc.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.more-link { color: var(--brand-500, #007AFF); cursor: pointer; }

.devcell { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; }
.devcell b { font-size: 15px; }
.devcell .cap, .cap2 { font-size: 11px; color: var(--muted-foreground, #86868b); }

.score-box { display: flex; justify-content: space-between; align-items: center; }
.score-box .num { font-size: 44px; font-weight: 800; line-height: 1; }
.score-box .right { text-align: right; font-size: 12px; color: var(--muted-foreground, #86868b); }
.star { color: #d2d2d7; font-size: 15px; letter-spacing: 1px; }
.star.on { color: var(--muted-foreground, #86868b); }
.star.on.blue { color: var(--brand-500, #007AFF); }
.review-card {
  background: var(--muted, #f5f5f7); border-radius: 14px; padding: 14px; margin-top: 10px;
}
.review-card h4 { font-size: 14px; margin-bottom: 4px; }
.review-card .rmeta { font-size: 12px; color: var(--muted-foreground, #86868b); margin-bottom: 6px; }
.review-card p { font-size: 13px; line-height: 1.55; }

.vnotes-date { float: right; font-size: 12px; color: var(--muted-foreground, #86868b); }
.infotable { width: 100%; font-size: 13px; border-collapse: collapse; }
.infotable td { border: none; border-top: 1px solid var(--border, #e5e5ea); padding: 10px 0; vertical-align: top; }
.infotable td:first-child { color: var(--muted-foreground, #86868b); width: 38%; }
.infotable td:last-child { text-align: right; }
.infotable tr:first-child td { border-top: none; }

/* App Store 风首页列表 */
.applist .approw {
  display: flex; align-items: center; gap: 14px; padding: 12px 0;
  border-bottom: 1px solid var(--border, #e5e5ea);
}
.applist .approw .appicon { width: 60px; height: 60px; border-radius: 14px; }
.approw .grow { flex: 1; min-width: 0; }
.approw h3 { font-size: 15px; }
.approw .rline { font-size: 12px; color: var(--muted-foreground, #86868b); margin-top: 2px; }
.approw .stars-sm { font-size: 11px; }

/* ===== 后台(分离页面 + 侧栏布局) ===== */
.admin { display: flex; min-height: 100vh; }
.sidebar {
  width: 200px; flex: none; background: var(--card, #fff);
  border-right: 1px solid var(--border, #e5e5ea); padding: 20px 12px;
}
.sidebar .logo { font-weight: 700; font-size: 15px; padding: 0 10px 14px; }
.sidebar a {
  display: flex; align-items: center; gap: 8px; font-size: 14px; padding: 9px 10px;
  border-radius: 9px; color: var(--foreground, #1d1d1f); margin-bottom: 2px;
}
.sidebar a:hover { background: var(--muted, #f5f5f7); }
.sidebar a.on { background: var(--brand-50, #e8f2ff); color: var(--brand-600, #0071e3); font-weight: 600; }
.sidebar a.out { color: var(--state-error-500, #FF3B30); margin-top: 14px; }
.main { flex: 1; padding: 24px 28px; max-width: 960px; }
.main h1 { font-size: 22px; font-weight: 700; margin-bottom: 16px; }
.stat-row { display: flex; gap: 14px; margin-bottom: 20px; }
.stat { flex: 1; background: var(--card, #fff); border: 1px solid var(--border, #e5e5ea); border-radius: 14px; padding: 14px 16px; }
.stat b { font-size: 24px; display: block; }
.stat span { font-size: 12px; color: var(--muted-foreground, #86868b); }
.shot-thumb { height: 90px; border-radius: 10px; border: 1px solid var(--border, #e5e5ea); }
