/* ===== Pricing 页（V0.8.1 套餐体系）=====
 * 独立样式页，与主应用同风格：暗色玻璃拟态 + 蓝紫主色。
 * 数据全部来自 /api/plans，本页只负责展示与升级引导。 */
:root {
  --bg: #0b0d16;
  --panel: rgba(255, 255, 255, .045);
  --glass-border: rgba(255, 255, 255, .1);
  --accent: #6c7ff8;
  --accent2: #a78bfa;
  --text: #eef0ff;
  --text-dim: #9aa3c0;
  --ok: #34d399;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 15% -10%, rgba(108, 127, 248, .18), transparent 60%),
    radial-gradient(900px 500px at 90% 0%, rgba(167, 139, 250, .14), transparent 55%),
    var(--bg);
}
a { color: var(--accent); text-decoration: none; }
.page { max-width: 1080px; margin: 0 auto; padding: 0 20px 60px; }

/* ===== 顶部导航 ===== */
.pricing-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 0; border-bottom: 1px solid var(--glass-border);
}
.pricing-nav .brand { font-size: 18px; font-weight: 800; color: var(--text); letter-spacing: .5px; }
.pricing-nav .brand span { color: var(--accent); }
.pricing-nav .nav-links { display: flex; gap: 16px; font-size: 13px; color: var(--text-dim); }
.pricing-nav .nav-links a { color: var(--text-dim); transition: color .15s ease; }
.pricing-nav .nav-links a:hover { color: var(--text); }

/* ===== 首屏 ===== */
.hero { text-align: center; padding: 48px 0 8px; }
.hero h1 { font-size: 30px; font-weight: 800; background: linear-gradient(90deg, #a5b4fc, #c4b5fd); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p { margin-top: 10px; color: var(--text-dim); font-size: 14px; line-height: 1.6; }

.billing-toggle {
  display: inline-flex; gap: 4px; margin-top: 22px; padding: 4px;
  background: var(--panel); border: 1px solid var(--glass-border); border-radius: 999px;
}
.billing-toggle button {
  border: 0; background: transparent; color: var(--text-dim); font-size: 13px;
  padding: 7px 22px; border-radius: 999px; cursor: pointer; transition: all .15s ease;
}
.billing-toggle button.active { background: var(--accent); color: #fff; font-weight: 700; }
.billing-toggle .save-tip { display: inline-block; margin-left: 6px; font-size: 10px; color: var(--ok); }

.current-tier { margin-top: 14px; font-size: 13px; color: var(--text-dim); }
.current-tier b { color: var(--accent2); }

/* ===== 5 档套餐卡片 ===== */
.plan-grid {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin-top: 34px;
}
.plan-card {
  position: relative; display: flex; flex-direction: column; gap: 12px;
  padding: 20px 18px; border-radius: 16px; text-align: center;
  background: var(--panel); border: 1px solid var(--glass-border);
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.plan-card:hover { transform: translateY(-3px); border-color: rgba(108, 127, 248, .55); }
.plan-card.popular {
  border-color: var(--accent);
  box-shadow: 0 0 24px rgba(108, 127, 248, .28), inset 0 0 0 1px rgba(108, 127, 248, .4);
  background: linear-gradient(180deg, rgba(108, 127, 248, .16), rgba(108, 127, 248, .05));
}
.pop-badge {
  position: absolute; top: -10px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  color: #fff; font-size: 11px; font-weight: 700; padding: 3px 12px; border-radius: 999px;
  white-space: nowrap;
}
.plan-card h3 { font-size: 18px; font-weight: 800; }
.plan-tag { font-size: 11px; color: var(--text-dim); }
.plan-price { min-height: 48px; display: flex; flex-direction: column; justify-content: center; gap: 2px; }
.plan-price b { font-size: 24px; color: #fff; }
.plan-price small { font-size: 11px; color: var(--text-dim); }
.plan-rights { list-style: none; display: flex; flex-direction: column; gap: 7px; text-align: left; margin: 4px 0 8px; }
.plan-rights li { font-size: 12px; color: var(--text-dim); line-height: 1.5; }
.plan-btn {
  margin-top: auto; border: 0; border-radius: 10px; cursor: pointer;
  padding: 10px 0; font-size: 13px; font-weight: 700; color: #fff;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  transition: transform .15s ease, box-shadow .15s ease;
}
.plan-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(108, 127, 248, .45); }
.plan-btn.current { background: rgba(255, 255, 255, .1); color: var(--text-dim); cursor: default; }
.plan-btn.ghost { background: rgba(255, 255, 255, .08); color: var(--text-dim); cursor: default; }

/* ===== 权益对比表 ===== */
.compare-wrap { margin-top: 52px; }
.compare-wrap h2 { font-size: 20px; font-weight: 800; text-align: center; margin-bottom: 18px; }
.table-scroll { overflow-x: auto; border-radius: 14px; border: 1px solid var(--glass-border); }
.compare-table { width: 100%; border-collapse: collapse; min-width: 720px; background: var(--panel); }
.compare-table th, .compare-table td { padding: 12px 14px; font-size: 12.5px; text-align: center; border-bottom: 1px solid var(--glass-border); }
.compare-table thead th { font-weight: 800; color: #fff; background: rgba(108, 127, 248, .12); }
.compare-table thead .popular-col { color: var(--accent2); }
.cur-flag {
  display: block; margin: 4px auto 0; width: fit-content; font-style: normal;
  font-size: 10px; color: var(--ok); border: 1px solid rgba(52, 211, 153, .4);
  border-radius: 999px; padding: 1px 8px;
}
.compare-table .row-label { text-align: left; font-weight: 700; color: var(--text); white-space: nowrap; }
.compare-table .row-label small { display: block; font-weight: 400; font-size: 11px; color: var(--text-dim); margin-top: 2px; }
.compare-table tbody tr:hover td { background: rgba(108, 127, 248, .06); }
.compare-table td.yes { color: var(--ok); font-weight: 800; }
.compare-table td.no { color: var(--text-dim); }

/* ===== 页脚与升级浮层 ===== */
/* ★V0.9.37★ FAQ 常见问题（手风琴）：中英双语，跟随全局语言（body.en 切换，与主应用 LANG 一致）。
   revert 恢复元素默认 display（details=block / a=inline / button=inline-block），适配导航栏/按钮等非块级元素 */
[data-lang="en"] { display: none; }
body.en [data-lang="zh"] { display: none; }
body.en [data-lang="en"] { display: revert; }
.faq-wrap { margin-top: 52px; max-width: 820px; margin-left: auto; margin-right: auto; }
.faq-title { font-size: 20px; font-weight: 800; text-align: center; margin-bottom: 18px; }
.faq-item {
  margin-bottom: 10px; border-radius: 12px; overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border: 1px solid rgba(216,184,119,.16);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
}
.faq-item[open] { border-color: rgba(216,184,119,.35); }
.faq-item summary {
  list-style: none; cursor: pointer; padding: 14px 18px;
  font-size: 14px; font-weight: 600; color: var(--text);
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  transition: color .15s ease;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+'; flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 14px; color: var(--gold-bright, #e8cf93);
  border: 1px solid rgba(216,184,119,.4); transition: transform .2s ease;
}
.faq-item[open] summary::after { content: '−'; transform: rotate(180deg); }
.faq-item summary:hover { color: var(--gold-bright, #e8cf93); }
.faq-item p {
  margin: 0; padding: 0 18px 14px; color: var(--text-dim);
  font-size: 13px; line-height: 1.8;
}
.faq-item p b { color: var(--gold-bright, #e8cf93); }
.faq-item p a { color: var(--gold-bright, #e8cf93); }

.pricing-foot { text-align: center; margin-top: 52px; font-size: 12px; color: var(--text-dim); line-height: 2; }
.pricing-foot p:first-child { color: var(--accent2); }

.hidden { display: none !important; }
.coming-mask {
  position: fixed; inset: 0; z-index: 99;
  background: rgba(5, 7, 14, .72); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.coming-box {
  max-width: 380px; width: 100%; text-align: center;
  background: #131627; border: 1px solid var(--glass-border); border-radius: 18px;
  padding: 32px 26px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
}
.coming-icon { font-size: 44px; }
.coming-box h3 { margin: 12px 0 8px; font-size: 18px; }
.coming-box p { font-size: 13px; color: var(--text-dim); line-height: 1.7; margin-bottom: 20px; }
.btn-primary {
  border: 0; border-radius: 10px; cursor: pointer; padding: 10px 28px;
  font-size: 13px; font-weight: 700; color: #fff;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
}

/* ===== 响应式：手机改单列/两列卡片 ===== */
@media (max-width: 900px) {
  .plan-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .plan-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 24px; }
  .pricing-nav .nav-links a { font-size: 12px; }
}

/* ============================================================
   轻奢渐变主题（V0.8.2 视觉升级）：与主应用同语言
   深墨蓝底 + 金色/香槟点缀 + 卡片顶部高光渐变
   ============================================================ */
:root {
  --gold: #d8b877;
  --gold-bright: #f3e3bb;
  --gold-deep: #a5813f;
  --gold-line: rgba(216,184,119,.32);
  --gold-strong: rgba(216,184,119,.55);
  --gold-soft: rgba(216,184,119,.12);
  --gold-grad: linear-gradient(135deg, #c8a25d 0%, #f2dfa5 48%, #c8a25d 100%);
}
body {
  background:
    radial-gradient(1200px 600px at 15% -10%, rgba(216,184,119,.14), transparent 60%),
    radial-gradient(900px 500px at 90% 0%, rgba(108,127,248,.1), transparent 55%),
    linear-gradient(165deg, #0a0c13 0%, #14101d 50%, #0a0c13 100%);
}
.hero h1 {
  background: linear-gradient(120deg, #f6e7bd 10%, #d8b877 45%, #f6e7bd 80%);
  -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 2px 14px rgba(216,184,119,.25));
}
.billing-toggle button.active { background: var(--gold-grad); color: #3a2c10; }
.current-tier b { color: var(--gold-bright); }
.plan-card {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border-color: rgba(216,184,119,.16);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
}
.plan-card::before {
  content: ''; position: absolute; top: 0; left: 14%; right: 14%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(216,184,119,.65), transparent);
  pointer-events: none;
}
.plan-card::after {
  content: ''; position: absolute; top: -40px; right: -40px; width: 110px; height: 110px;
  border-radius: 50%; background: radial-gradient(circle, rgba(216,184,119,.12), transparent 70%);
  pointer-events: none;
}
.plan-card:hover { border-color: rgba(216,184,119,.6); box-shadow: 0 12px 34px rgba(0,0,0,.45), inset 0 1px 0 rgba(243,227,187,.15); }
.plan-card.popular {
  border-color: var(--gold);
  box-shadow: 0 0 30px rgba(216,184,119,.25), inset 0 0 0 1px rgba(216,184,119,.45);
  background: linear-gradient(180deg, rgba(216,184,119,.16), rgba(216,184,119,.04));
}
.pop-badge { background: var(--gold-grad); color: #3a2c10; }
.plan-price b { background: linear-gradient(120deg, #f6e7bd, #d8b877); -webkit-background-clip: text; background-clip: text; color: transparent; }
.plan-btn { background: var(--gold-grad); color: #3a2c10; box-shadow: 0 6px 20px rgba(216,184,119,.25), inset 0 1px 0 rgba(255,255,255,.4); }
.plan-btn:hover { box-shadow: 0 10px 28px rgba(216,184,119,.45), inset 0 1px 0 rgba(255,255,255,.45); }
.compare-table thead th { background: rgba(216,184,119,.1); }
.compare-table thead .popular-col { color: var(--gold-bright); }
.compare-table tbody tr:hover td { background: rgba(216,184,119,.06); }
.pricing-foot p:first-child { color: var(--gold-bright); }
.coming-box {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, rgba(30,27,36,.96), rgba(18,17,25,.98));
  border-color: rgba(216,184,119,.3);
  box-shadow: 0 24px 70px rgba(0,0,0,.6), inset 0 1px 0 rgba(243,227,187,.12);
}
.coming-box::before {
  content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}
.btn-primary { background: var(--gold-grad); color: #3a2c10; box-shadow: 0 6px 20px rgba(216,184,119,.3), inset 0 1px 0 rgba(255,255,255,.4); }
.pricing-nav .brand span { color: var(--gold); }

/* ★V0.9.26★ 邮箱登录弹层 */
.nav-login {
  background: none; border: 1px solid rgba(216,184,119,.45); color: var(--gold-bright, #e8cf93);
  border-radius: 20px; padding: 4px 16px; font-size: 13px; cursor: pointer; font-family: inherit;
  transition: background .2s, box-shadow .2s;
}
.nav-login:hover { background: rgba(216,184,119,.12); box-shadow: 0 0 12px rgba(216,184,119,.25); }

/* ★V0.10.4★ 账号状态徽章：已关联邮箱 + 套餐档位（登录后替换 Sign in 按钮） */
.nav-account {
  display: inline-flex; align-items: center; gap: 7px; max-width: 100%;
  padding: 3px 10px 3px 14px; border: 1px solid rgba(216,184,119,.3);
  border-radius: 20px; background: rgba(216,184,119,.08);
  color: var(--text-dim); font-size: 12px; white-space: nowrap;
}
.nav-account b { color: var(--text); font-weight: 600; max-width: 200px; overflow: hidden; text-overflow: ellipsis; }
.nav-account .acct-tier {
  padding: 1px 8px; border-radius: 999px; flex-shrink: 0;
  background: var(--gold-grad, linear-gradient(135deg, #d8b877, #b6914d)); color: #3a2c10;
  font-size: 11px; font-weight: 800; letter-spacing: .3px;
}
.login-desc { font-size: 13px; line-height: 1.7; color: var(--text-dim); margin: 4px 0 14px; text-align: left; }
.login-input {
  width: 100%; padding: 10px 12px; margin-bottom: 10px; border-radius: 8px;
  border: 1px solid rgba(216,184,119,.35); background: rgba(255,255,255,.05); color: var(--text);
  font-size: 14px; font-family: inherit; outline: none;
}
.login-input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(216,184,119,.15); }
.login-status { font-size: 13px; min-height: 20px; margin-bottom: 10px; line-height: 1.5; }
.login-status.ok { color: var(--ok); }
.login-status.err { color: #f87171; }
.btn-ghost {
  background: none; border: 1px solid rgba(255,255,255,.18); color: var(--text-dim);
  border-radius: 8px; padding: 10px 22px; font-size: 14px; cursor: pointer; font-family: inherit;
  margin-top: 8px; transition: border-color .2s, color .2s;
}
.btn-ghost:hover { border-color: rgba(255,255,255,.4); color: var(--text); }
