/* ============================================================
   观星问命 · 墨韵星图
   新中式深色古籍报告风：墨黑底 / 宣纸米白正文 / 古铜金主强调 / 暗红次强调
   ============================================================ */
:root {
  --ink: #12100c;
  --ink-2: #191610;
  --ink-3: #211c15;
  --ink-4: #2b251b;
  --paper: #f0e8d5;
  --paper-2: #d9cfb8;
  --paper-dim: #a89e86;
  --paper-faint: #7d7460;
  --gold: #c2a15e;
  --gold-bright: #e6c886;
  --gold-dim: rgba(194, 161, 94, .16);
  --cinnabar: #a5382c;
  --cinnabar-bright: #c9503f;
  --line: rgba(194, 161, 94, .22);
  --line-soft: rgba(194, 161, 94, .1);
  --serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, sans-serif;
  --shadow: 0 12px 40px rgba(0, 0, 0, .5);
  --radius: 10px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(194, 161, 94, .07), transparent),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0.76 0 0 0 0 0.69 0 0 0 0 0.5 0 0 0 0.03 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
::selection { background: rgba(194, 161, 94, .32); color: #fff; }

/* ---------- 通用 ---------- */
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 28px; }
a { color: var(--gold-bright); text-decoration: none; }
a:hover { text-decoration: underline; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--sans); font-size: 15px; font-weight: 600;
  padding: 12px 26px; border-radius: 6px; border: 1px solid var(--gold);
  background: linear-gradient(180deg, rgba(194,161,94,.22), rgba(194,161,94,.08));
  color: var(--gold-bright); cursor: pointer;
  transition: all .25s ease; letter-spacing: .05em;
}
.btn:hover { background: linear-gradient(180deg, rgba(194,161,94,.34), rgba(194,161,94,.14)); text-decoration: none; transform: translateY(-1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.btn-primary {
  background: linear-gradient(180deg, #b08c42, #8f6e2f);
  border-color: #d4b26e; color: #1c1508;
}
.btn-primary:hover { background: linear-gradient(180deg, #c29c4c, #a3813a); }
.btn-ghost { border-color: var(--line); color: var(--paper-dim); background: transparent; }
.btn-ghost:hover { color: var(--paper); border-color: var(--gold); }
.tag {
  display: inline-block; font-family: var(--sans); font-size: 12px;
  padding: 2px 10px; border: 1px solid var(--line); border-radius: 99px;
  color: var(--gold); letter-spacing: .12em;
}
.section-title {
  font-size: 30px; font-weight: 600; letter-spacing: .08em;
  margin-bottom: 6px; color: var(--paper);
}
.section-title::after {
  content: ""; display: block; width: 44px; height: 2px;
  background: linear-gradient(90deg, var(--gold), transparent); margin-top: 12px;
}
.section-sub { color: var(--paper-dim); font-size: 15px; margin-bottom: 34px; }

/* ---------- 顶栏 ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  background: rgba(18, 16, 12, .82);
  border-bottom: 1px solid var(--line-soft);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 62px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--paper); }
.brand:hover { text-decoration: none; }
.brand-seal {
  width: 36px; height: 36px; border-radius: 5px;
  background: linear-gradient(160deg, #b23a2e, #7e241c);
  display: grid; place-items: center;
  font-size: 17px; font-weight: 700; color: #f6e9d8;
  box-shadow: inset 0 0 0 1px rgba(255, 220, 180, .25), 0 2px 8px rgba(0,0,0,.4);
  letter-spacing: 0;
}
.brand-name { font-size: 19px; font-weight: 600; letter-spacing: .14em; }
.brand-name small { display: block; font-size: 10px; color: var(--paper-faint); letter-spacing: .3em; font-family: var(--sans); }
.nav-links { display: flex; gap: 26px; font-family: var(--sans); font-size: 14px; }
.nav-links a { color: var(--paper-dim); }
.nav-links a:hover { color: var(--gold-bright); text-decoration: none; }
@media (max-width: 720px) { .nav-links { display: none; } }

/* ---------- 首屏 ---------- */
.hero {
  position: relative; min-height: 92vh;
  display: flex; align-items: center; justify-content: center;
  text-align: center; overflow: hidden; padding: 120px 20px 60px;
}
.hero-bg { position: absolute; inset: 0; opacity: .5; pointer-events: none; }
.hero-bg svg { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.hero-content { position: relative; max-width: 760px; }
.hero-kicker { font-family: var(--sans); font-size: 13px; color: var(--gold); letter-spacing: .5em; margin-bottom: 22px; }
.hero h1 {
  font-size: clamp(44px, 7vw, 72px); font-weight: 700;
  letter-spacing: .1em; line-height: 1.25; margin-bottom: 10px;
  background: linear-gradient(180deg, #f5ecd9 30%, #cbb26f);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-slogan { font-size: 18px; color: var(--paper-2); margin-bottom: 8px; letter-spacing: .06em; }
.hero-desc { font-size: 15px; color: var(--paper-dim); max-width: 560px; margin: 0 auto 36px; }
.hero-cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 40px; justify-content: center; margin-top: 54px; flex-wrap: wrap; }
.stat b { display: block; font-size: 26px; color: var(--gold-bright); font-weight: 600; }
.stat span { font-family: var(--sans); font-size: 12px; color: var(--paper-faint); letter-spacing: .1em; }
.hero-disclaimer {
  margin-top: 44px; font-family: var(--sans); font-size: 12px;
  color: var(--paper-faint); border-top: 1px solid var(--line-soft);
  padding-top: 18px; max-width: 640px; margin-left: auto; margin-right: auto;
}

/* ---------- 能力菜单 ---------- */
.section { padding: 84px 0; }
.modules-head { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.cat-label {
  font-family: var(--sans); font-size: 13px; color: var(--gold);
  letter-spacing: .3em; margin: 34px 0 16px;
  display: flex; align-items: center; gap: 12px;
}
.cat-label::after { content: ""; flex: 1; height: 1px; background: var(--line-soft); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.mod-card {
  background: linear-gradient(170deg, var(--ink-3), var(--ink-2));
  border: 1px solid var(--line-soft); border-radius: var(--radius);
  padding: 22px; cursor: pointer; position: relative; overflow: hidden;
  transition: all .3s ease;
}
.mod-card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(400px 200px at 50% -20%, rgba(194,161,94,.12), transparent);
  opacity: 0; transition: opacity .3s;
}
.mod-card:hover { border-color: var(--line); transform: translateY(-3px); box-shadow: var(--shadow); }
.mod-card:hover::before { opacity: 1; }
.mod-card.active { border-color: var(--gold); }
.mod-card.active::after {
  content: "测算中"; position: absolute; top: 12px; right: 12px;
  font-family: var(--sans); font-size: 11px; color: var(--gold-bright);
  border: 1px solid var(--gold); padding: 1px 8px; border-radius: 99px;
}
.mod-icon { font-size: 26px; margin-bottom: 12px; }
.mod-name { font-size: 18px; font-weight: 600; margin-bottom: 2px; }
.mod-sub { font-family: var(--sans); font-size: 12px; color: var(--gold); margin-bottom: 10px; letter-spacing: .05em; }
.mod-desc { font-size: 13px; color: var(--paper-dim); line-height: 1.6; }

/* ---------- 测算台 ---------- */
.workbench { display: none; }
.workbench.show { display: block; }
.wb-grid { display: grid; grid-template-columns: 400px 1fr; gap: 24px; align-items: start; }
@media (max-width: 960px) { .wb-grid { grid-template-columns: 1fr; } }
.panel {
  background: linear-gradient(170deg, var(--ink-3), var(--ink-2));
  border: 1px solid var(--line-soft); border-radius: var(--radius);
  padding: 26px;
}
.panel-title {
  font-size: 19px; font-weight: 600; margin-bottom: 4px;
  display: flex; align-items: center; gap: 10px;
}
.panel-sub { font-family: var(--sans); font-size: 12px; color: var(--paper-faint); margin-bottom: 20px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-family: var(--sans); font-size: 13px; color: var(--paper-2); margin-bottom: 6px; }
.field label .req { color: var(--cinnabar-bright); margin-left: 2px; }
.field .help { font-family: var(--sans); font-size: 11px; color: var(--paper-faint); margin-top: 4px; }
.field input[type=text], .field input[type=number], .field input[type=date], .field input[type=time],
.field select, .field textarea {
  width: 100%; background: var(--ink); color: var(--paper);
  border: 1px solid var(--line); border-radius: 6px;
  padding: 10px 12px; font-family: var(--sans); font-size: 14px;
  transition: border-color .2s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(194, 161, 94, .12);
}
.field textarea { min-height: 88px; resize: vertical; }
.radio-row { display: flex; gap: 10px; }
.radio-row label {
  flex: 1; text-align: center; padding: 9px 0; margin: 0;
  border: 1px solid var(--line); border-radius: 6px; cursor: pointer;
  font-family: var(--sans); font-size: 14px; color: var(--paper-dim);
  transition: all .2s;
}
.radio-row input { display: none; }
.radio-row label.on { border-color: var(--gold); color: var(--gold-bright); background: var(--gold-dim); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 480px) { .field-row { grid-template-columns: 1fr; } }

.result-empty {
  text-align: center; color: var(--paper-faint); padding: 80px 20px;
  font-family: var(--sans); font-size: 14px;
}
.result-empty .big { font-size: 40px; margin-bottom: 14px; opacity: .5; }
.spinner {
  display: inline-block; width: 18px; height: 18px;
  border: 2px solid var(--line); border-top-color: var(--gold);
  border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -3px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* 订单徽标 */
.order-badge {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: var(--gold-dim); border: 1px dashed var(--gold);
  border-radius: 8px; padding: 10px 16px; margin-bottom: 18px;
  font-family: var(--sans); font-size: 14px; flex-wrap: wrap;
}
.order-badge b { color: var(--gold-bright); letter-spacing: .1em; font-size: 16px; }
.order-badge .hint { font-size: 12px; color: var(--paper-dim); }

/* 报告卡片（四段式：标题→命盘→解读→结论） */
.report-card { animation: fadeUp .5s ease both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.report-h {
  font-size: 21px; font-weight: 600; margin-bottom: 14px;
  padding-bottom: 12px; border-bottom: 1px solid var(--line-soft);
}
.md-body { font-size: 15px; line-height: 1.9; }
.md-body h1, .md-body h2, .md-body h3 { margin: 18px 0 10px; color: var(--gold-bright); }
.md-body h1 { font-size: 20px; } .md-body h2 { font-size: 18px; } .md-body h3 { font-size: 16px; }
.md-body p { margin: 10px 0; }
.md-body table {
  width: 100%; border-collapse: collapse; margin: 14px 0;
  font-family: var(--sans); font-size: 13px;
}
.md-body th, .md-body td { border: 1px solid var(--line-soft); padding: 7px 10px; text-align: left; }
.md-body th { background: rgba(194, 161, 94, .1); color: var(--gold-bright); font-weight: 600; }
.md-body tr:nth-child(even) td { background: rgba(255, 255, 255, .015); }
.md-body blockquote {
  border-left: 3px solid var(--cinnabar); background: rgba(165, 56, 44, .1);
  padding: 10px 16px; margin: 14px 0; border-radius: 0 6px 6px 0;
  color: var(--paper-2); font-size: 14px;
}
.md-body hr { border: none; border-top: 1px solid var(--line-soft); margin: 20px 0; }
.md-body code { background: var(--ink); padding: 2px 6px; border-radius: 4px; font-size: 13px; }
.md-body ul, .md-body ol { padding-left: 22px; margin: 10px 0; }
.md-body strong { color: var(--gold-bright); }
.md-body em { color: var(--paper-2); }

/* 付费墙 */
.paywall {
  margin-top: 18px; text-align: center;
  background: linear-gradient(170deg, rgba(165,56,44,.14), rgba(18,16,12,.6));
  border: 1px solid rgba(194, 161, 94, .3); border-radius: var(--radius);
  padding: 28px 22px;
}
.paywall h3 { font-size: 19px; margin-bottom: 8px; color: var(--gold-bright); }
.paywall p { font-size: 14px; color: var(--paper-dim); max-width: 460px; margin: 0 auto 16px; }
.qr-box { display: inline-block; background: #f5efdf; padding: 10px; border-radius: 8px; margin-bottom: 12px; }
.qr-box img { display: block; width: 200px; height: auto; }
.paywall .price { font-size: 22px; color: var(--gold-bright); font-weight: 700; }
.unlock-row { display: flex; gap: 10px; max-width: 380px; margin: 16px auto 0; }
.unlock-row input {
  flex: 1; background: var(--ink); color: var(--paper); text-align: center;
  border: 1px solid var(--line); border-radius: 6px; padding: 11px;
  font-family: var(--sans); font-size: 18px; letter-spacing: .4em;
}
.unlock-row input:focus { outline: none; border-color: var(--gold); }
.unlock-tip { font-family: var(--sans); font-size: 13px; margin-top: 12px; min-height: 20px; }
.unlock-tip.ok { color: #7fbf7f; }
.unlock-tip.err { color: var(--cinnabar-bright); }
.dl-btn { margin-top: 14px; }

/* ---------- 流程 / 价格 ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }
.step {
  background: linear-gradient(170deg, var(--ink-3), var(--ink-2));
  border: 1px solid var(--line-soft); border-radius: var(--radius); padding: 26px;
}
.step-num {
  font-size: 13px; color: var(--gold); font-family: var(--sans);
  letter-spacing: .2em; margin-bottom: 10px;
}
.step h3 { font-size: 18px; margin-bottom: 8px; }
.step p { font-size: 14px; color: var(--paper-dim); }
.price-card {
  margin-top: 22px; text-align: center; padding: 30px;
  background: linear-gradient(170deg, rgba(194,161,94,.1), var(--ink-2));
  border: 1px solid var(--gold); border-radius: var(--radius);
}
.price-card .p { font-size: 40px; color: var(--gold-bright); font-weight: 700; }
.price-card .p small { font-size: 15px; color: var(--paper-dim); font-weight: 400; }
.price-card p { color: var(--paper-dim); font-size: 14px; margin-top: 8px; }

/* ---------- FAQ ---------- */
.faq-item { border-bottom: 1px solid var(--line-soft); padding: 18px 0; }
.faq-item summary {
  cursor: pointer; font-size: 16px; font-weight: 600;
  display: flex; justify-content: space-between; align-items: center;
  list-style: none; color: var(--paper);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "＋"; color: var(--gold); font-family: var(--sans); }
.faq-item[open] summary::after { content: "－"; }
.faq-item p { margin-top: 12px; color: var(--paper-dim); font-size: 14px; }

/* ---------- 页脚 ---------- */
.footer { border-top: 1px solid var(--line-soft); padding: 48px 0 36px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 30px; margin-bottom: 34px; }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr; } }
.footer h4 { font-family: var(--sans); font-size: 13px; color: var(--gold); letter-spacing: .2em; margin-bottom: 14px; }
.footer p, .footer a { font-size: 13px; color: var(--paper-dim); line-height: 2; }
.footer-disclaimer {
  border-top: 1px solid var(--line-soft); padding-top: 20px;
  font-family: var(--sans); font-size: 12px; color: var(--paper-faint);
  text-align: center; line-height: 1.9;
}

/* ---------- 提示条 ---------- */
.toast {
  position: fixed; left: 50%; bottom: 34px; transform: translateX(-50%) translateY(20px);
  background: var(--ink-4); border: 1px solid var(--gold); color: var(--paper);
  padding: 12px 22px; border-radius: 8px; font-family: var(--sans); font-size: 14px;
  opacity: 0; pointer-events: none; transition: all .3s; z-index: 200;
  box-shadow: var(--shadow); max-width: 86vw;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============================================================
   交互增强：OTP / 生成动画 / 目录 / 进度 / 弹窗 / 显现
   ============================================================ */

/* ---------- OTP 口令输入 ---------- */
.otp-row { display: flex; gap: 10px; justify-content: center; margin: 18px auto 0; max-width: 380px; }
.otp-cell {
  width: 46px; height: 56px; text-align: center;
  background: var(--ink); color: var(--gold-bright);
  border: 1px solid var(--line); border-radius: 8px;
  font-family: var(--sans); font-size: 24px; font-weight: 700;
  transition: all .2s;
}
.otp-cell:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(194,161,94,.15); transform: translateY(-2px); }
.otp-cell.filled { border-color: var(--gold); background: rgba(194,161,94,.08); }

/* ---------- 生成中动画 ---------- */
.gen-stage { text-align: center; padding: 46px 16px; }
.gen-orbit { position: relative; width: 130px; height: 130px; margin: 0 auto 26px; }
.gen-orbit .core {
  position: absolute; inset: 38px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #e6c886, #8f6e2f 70%);
  box-shadow: 0 0 26px rgba(230, 200, 134, .5);
  animation: pulse 1.6s ease-in-out infinite;
}
.gen-orbit .ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 1px dashed rgba(194, 161, 94, .5);
  animation: spin 9s linear infinite;
}
.gen-orbit .ring2 {
  position: absolute; inset: 18px; border-radius: 50%;
  border: 1px dashed rgba(194, 161, 94, .3);
  animation: spin 6s linear infinite reverse;
}
.gen-orbit .star {
  position: absolute; width: 5px; height: 5px; border-radius: 50%;
  background: var(--gold-bright); box-shadow: 0 0 8px var(--gold-bright);
  top: -3px; left: 50%;
}
@keyframes pulse { 0%,100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.12); opacity: 1; } }
.gen-stage h3 { font-size: 19px; margin-bottom: 8px; color: var(--gold-bright); }
.gen-stage p { font-family: var(--sans); font-size: 13px; color: var(--paper-dim); }
.gen-steps { margin-top: 22px; font-family: var(--sans); font-size: 13px; color: var(--paper-dim); }
.gen-steps div { margin: 6px 0; opacity: .35; transition: opacity .4s; }
.gen-steps div.on { opacity: 1; color: var(--paper); }
.gen-steps div.on::before { content: "✦ "; color: var(--gold); }

/* ---------- 章节预告 ---------- */
.outline-box {
  background: rgba(194, 161, 94, .06); border: 1px solid var(--line-soft);
  border-radius: 8px; padding: 16px 18px; margin: 16px 0; text-align: left;
}
.outline-box h4 { font-family: var(--sans); font-size: 12px; color: var(--gold); letter-spacing: .2em; margin-bottom: 10px; }
.outline-box ol { padding-left: 20px; }
.outline-box li { font-size: 14px; color: var(--paper-2); margin: 5px 0; }
.outline-box li::marker { color: var(--gold); font-family: var(--sans); font-size: 12px; }

/* ---------- 命盘渐显 ---------- */
.md-body table { animation: fadeUp .45s ease both; }
.md-body table:nth-of-type(2) { animation-delay: .08s; }
.md-body table:nth-of-type(3) { animation-delay: .16s; }

/* ---------- 报告目录 ---------- */
.report-layout { display: grid; grid-template-columns: 1fr 190px; gap: 20px; align-items: start; }
@media (max-width: 1100px) {
  .report-layout { grid-template-columns: 1fr; }
  .toc-box { display: none; }
  .toc-box.mobile-open {
    display: block; position: fixed; left: 12px; right: 12px; bottom: 84px; top: auto;
    z-index: 170; max-height: 56vh; overflow-y: auto;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .55);
  }
}
.toc-box {
  position: sticky; top: 84px;
  background: var(--ink-2); border: 1px solid var(--line-soft);
  border-radius: var(--radius); padding: 16px;
}
.toc-box h4 { font-family: var(--sans); font-size: 12px; color: var(--gold); letter-spacing: .2em; margin-bottom: 10px; }
.toc-box a { display: block; font-size: 13px; color: var(--paper-dim); padding: 4px 0; line-height: 1.5; }
.toc-box a:hover, .toc-box a.active { color: var(--gold-bright); text-decoration: none; }
.toc-box a.active { border-left: 2px solid var(--gold); padding-left: 8px; }
.md-body h2 { scroll-margin-top: 80px; }

/* ---------- 阅读进度 ---------- */
.read-progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0;
  background: linear-gradient(90deg, var(--gold), var(--cinnabar-bright));
  z-index: 300; transition: width .15s linear;
}

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(5, 4, 2, .78);
  display: none; align-items: center; justify-content: center;
  z-index: 400; padding: 20px; backdrop-filter: blur(6px);
}
.modal-mask.show { display: flex; }
.modal {
  position: relative; width: 100%; max-width: 420px;
  background: linear-gradient(170deg, var(--ink-3), var(--ink-2));
  border: 1px solid var(--gold); border-radius: 12px; padding: 30px;
  animation: fadeUp .3s ease both;
  max-height: 90vh; overflow-y: auto;
}
.modal h3 { font-size: 20px; margin-bottom: 6px; }
.modal-sub { font-family: var(--sans); font-size: 13px; color: var(--paper-dim); margin-bottom: 20px; }
.modal-close {
  position: absolute; top: 12px; right: 14px; background: none;
  border: none; color: var(--paper-dim); font-size: 22px; cursor: pointer;
}
.modal-close:hover { color: var(--gold-bright); }

/* ---------- 滚动显现 ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- 生肖星座提示 chip ---------- */
.zodiac-chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--sans); font-size: 12px; color: var(--gold);
  background: var(--gold-dim); border: 1px solid var(--line);
  border-radius: 99px; padding: 2px 12px; margin-top: 6px;
  animation: fadeUp .3s ease both;
}
.zodiac-chip:empty { display: none; }

/* ---------- 日期快捷 ---------- */
.quick-dates { display: flex; gap: 8px; margin-top: 6px; }
.quick-dates button {
  font-family: var(--sans); font-size: 12px; color: var(--paper-dim);
  background: transparent; border: 1px solid var(--line-soft);
  border-radius: 99px; padding: 3px 12px; cursor: pointer; transition: all .2s;
}
.quick-dates button:hover { color: var(--gold-bright); border-color: var(--gold); }

/* ---------- 复制按钮 ---------- */
.copy-btn {
  font-family: var(--sans); font-size: 12px; color: var(--gold);
  background: transparent; border: 1px solid var(--line);
  border-radius: 99px; padding: 2px 12px; cursor: pointer; margin-left: 8px;
  transition: all .2s;
}
.copy-btn:hover { background: var(--gold-dim); }

/* ---------- 卡片微倾斜 ---------- */
.mod-card { transform-style: preserve-3d; will-change: transform; }

/* ============================================================
   订单持久化：恢复横幅 / 防刷新警告 / 订单号强调
   ============================================================ */
.order-badge b { font-size: 17px; letter-spacing: .06em; color: var(--gold-bright); }
.restore-banner {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  background: linear-gradient(90deg, rgba(194,161,94,.16), rgba(194,161,94,.05));
  border: 1px solid var(--gold); border-radius: 8px;
  padding: 10px 14px; margin-bottom: 16px;
  font-family: var(--sans); font-size: 13px; color: var(--gold-bright); line-height: 1.7;
}
.restore-banner b { font-size: 15px; }
.restore-banner .copy-btn { margin-left: auto; }
.warn-strip {
  margin-top: 16px; padding: 10px 14px;
  background: rgba(178, 58, 45, .10); border: 1px dashed rgba(178, 58, 45, .45);
  border-radius: 8px; font-family: var(--sans); font-size: 12.5px;
  color: #d98a80; line-height: 1.8;
}

/* ============================================================
   防滚动疲劳：平滑滚动 / 面板快捷导航 / 折叠盘面 / 悬浮钮 / 吸底条
   ============================================================ */
html { scroll-behavior: smooth; }
#pwUnlock, #pwChart, #pwOutline, #rpFull, #rpChart, .report-h { scroll-margin-top: 122px; }

/* ---------- 面板内吸顶快捷导航 ---------- */
.panel-quicknav {
  position: sticky; top: 62px; z-index: 30;
  display: flex; flex-wrap: wrap; gap: 8px;
  padding: 8px; margin-bottom: 16px;
  background: rgba(18, 16, 12, .93);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border: 1px solid var(--line-soft); border-radius: 10px;
}
.panel-quicknav a {
  font-family: var(--sans); font-size: 12.5px; color: var(--paper-dim);
  padding: 5px 12px; border-radius: 99px; border: 1px solid var(--line-soft);
  text-decoration: none; transition: all .2s; background: var(--ink);
}
.panel-quicknav a:hover { color: var(--gold-bright); border-color: var(--gold); }
.panel-quicknav a.hl { color: var(--gold-bright); border-color: var(--gold); background: var(--gold-dim); }

/* ---------- 可折叠盘面 / 章节预告 ---------- */
.panel details {
  border: 1px solid var(--line-soft); border-radius: 10px;
  margin: 16px 0; background: rgba(0, 0, 0, .16); overflow: hidden;
}
.panel details summary {
  cursor: pointer; list-style: none; padding: 11px 14px;
  font-family: var(--sans); font-size: 13px; color: var(--gold);
  display: flex; align-items: center; gap: 8px; user-select: none;
}
.panel details summary::-webkit-details-marker { display: none; }
.panel details summary::before { content: "▸"; font-size: 11px; transition: transform .2s; }
.panel details[open] summary::before { transform: rotate(90deg); }
.panel details .det-body { padding: 0 14px 14px; }

/* ---------- 悬浮「开始测算」按钮 ---------- */
.fab {
  position: fixed; right: 18px; bottom: 24px; z-index: 150;
  display: none; align-items: center; gap: 8px;
  background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  color: #1a1408; font-family: var(--sans); font-size: 14px; font-weight: 700;
  border: none; border-radius: 99px; padding: 12px 20px; cursor: pointer;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .45);
}
.fab.show { display: inline-flex; animation: fadeUp .35s ease both; }
.fab:active { transform: scale(.96); }

/* ---------- 移动端吸底操作条 ---------- */
.mobile-bar { display: none; }
@media (max-width: 960px) {
  .mobile-bar.show {
    display: flex; align-items: center; gap: 12px;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 160;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: rgba(14, 11, 7, .94);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    border-top: 1px solid var(--gold);
  }
  .mobile-bar .mb-price { font-size: 20px; font-weight: 700; color: var(--gold-bright); font-family: var(--sans); white-space: nowrap; }
  .mobile-bar .mb-btn { flex: 1; }
  body.mb-active { padding-bottom: 68px; }
}

/* ---------- 移动端目录浮动按钮 ---------- */
.toc-fab {
  position: fixed; right: 18px; bottom: 88px; z-index: 155;
  display: none; align-items: center; gap: 6px;
  background: var(--ink-3); color: var(--gold-bright);
  border: 1px solid var(--gold); border-radius: 99px;
  font-family: var(--sans); font-size: 13px; padding: 9px 16px; cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .4);
}
.toc-fab.show { display: inline-flex; }
@media (min-width: 1101px) { .toc-fab { display: none !important; } }
