:root{
  --bg:#162032;
  --surface:#1e2a3f;
  --surface-2:#263349;
  --ink:#e8eaef;
  --muted:#8b95a8;
  --line:#334155;
  --amber:#f59e0b;
  --amber-light:#fbbf24;
  --amber-deep:#d97706;
  --amber-glow:rgba(245,158,11,.14);
  --rail-w:252px;
  --max:840px;
  --shadow:0 24px 56px rgba(8,12,24,.58);
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:"Source Han Sans SC","Noto Sans SC","PingFang SC","Microsoft YaHei",sans-serif;
  color:var(--ink);
  background:
    radial-gradient(920px 420px at 6% -2%,rgba(245,158,11,.07),transparent 54%),
    radial-gradient(640px 320px at 94% 12%,rgba(30,58,95,.35),transparent 50%),
    var(--bg);
  line-height:1.88;
}
a{color:var(--amber-light)}
a:hover{color:var(--amber)}
img{max-width:100%;height:auto;display:block}

.top-strip{
  background:linear-gradient(90deg,#111827,var(--surface));
  border-bottom:1px solid var(--line);
  color:var(--muted);
  font-size:.82rem;
  padding:.45rem 1rem;
  display:flex;justify-content:space-between;align-items:center;gap:.75rem;
}
.top-strip b{color:var(--amber-light);font-weight:600}

.rail-shell{display:flex;min-height:calc(100vh - 35px)}
.rail{
  width:var(--rail-w);
  flex-shrink:0;
  background:var(--surface);
  border-right:1px solid var(--line);
  position:sticky;top:0;height:calc(100vh - 35px);
  overflow-y:auto;
  display:flex;flex-direction:column;
}
.rail-brand{
  padding:1.4rem 1.25rem 1.05rem;
  border-bottom:1px solid var(--line);
}
.rail-brand a{display:flex;align-items:center;gap:.75rem;text-decoration:none;color:inherit}
.rail-brand img{width:44px;height:44px;border-radius:11px;border:1px solid var(--line)}
.rail-brand b{display:block;font-size:1.04rem;color:var(--amber-light)}
.rail-brand span{font-size:.74rem;color:var(--muted)}
.rail-nav{flex:1;padding:.8rem 0}
.rail-nav section{padding:0 .9rem;margin-bottom:.55rem}
.rail-nav h3{
  margin:0 0 .38rem;padding:0 .42rem;
  font-size:.67rem;text-transform:uppercase;letter-spacing:.13em;
  color:var(--muted);font-weight:600;
}
.rail-nav a{
  display:block;padding:.54rem .78rem;margin:.1rem 0;
  border-radius:9px;text-decoration:none;color:var(--ink);font-size:.9rem;
  border-left:3px solid transparent;
}
.rail-nav a:hover,.rail-nav a.active{
  background:var(--amber-glow);color:var(--amber-light);
  border-left-color:var(--amber);
}
.rail-nav a.btn-rail{
  margin:.55rem .9rem 0;background:var(--amber-deep);color:#1a1208;
  font-weight:700;text-align:center;border-left:none;
}
.rail-nav a.btn-rail:hover{background:var(--amber);color:#1a1208}
.rail-foot{
  padding:1.05rem 1.25rem;border-top:1px solid var(--line);
  font-size:.76rem;color:var(--muted);
}
.rail-foot a{display:block;margin:.28rem 0;color:var(--muted);font-size:.78rem}

.rail-main{flex:1;min-width:0;background:var(--bg)}
.rail-content{
  max-width:calc(var(--max) + 4rem);
  margin:0 auto;padding:1.55rem clamp(1rem,3vw,2.1rem) 3.2rem;
}

.rail-toggle{
  display:none;position:fixed;bottom:1.3rem;right:1.3rem;z-index:50;
  width:54px;height:54px;border-radius:15px;border:none;
  background:var(--amber-deep);color:#1a1208;cursor:pointer;
  box-shadow:var(--shadow);font-size:1.28rem;line-height:1;
}
.rail-overlay{display:none}

.ads-slot{margin-bottom:1.3rem}
.ads-wrap{margin:0;padding:.75rem 1rem 1rem;border:1px solid var(--line);border-radius:13px;background:var(--surface-2)}
.ads-head{margin:0;padding:0}
.applist-title{text-align:center;color:var(--muted);font-size:.92rem;margin:0 0 .55rem}
#applist{width:100%}
#ads{display:flex!important;justify-content:center;align-items:flex-start;flex-wrap:wrap;gap:12px;margin:0;padding:0;background:transparent}
#ads>div{display:flex!important;flex-direction:column;align-items:center;width:72px!important;min-width:72px;flex:0 0 72px}
#ads figure{margin:0;padding:0;width:72px;display:flex;flex-direction:column;align-items:center}
#ads a{display:block;width:65px;height:65px;border-radius:14px;overflow:hidden;text-decoration:none}
#ads img{width:65px!important;height:65px!important;object-fit:cover!important;border-radius:14px;display:block!important;border:0;background:#1a2332}
#ads figcaption,#ads .caption{display:block;width:72px;margin-top:6px;font-size:11px!important;line-height:1.2;color:var(--muted);text-align:center;white-space:nowrap!important;overflow:hidden;text-overflow:ellipsis}

.doc-head{margin-bottom:1.8rem;padding-bottom:1.3rem;border-bottom:1px solid var(--line)}
.doc-head h1{
  margin:0 0 .68rem;font-size:clamp(1.58rem,3.6vw,2.15rem);
  line-height:1.3;color:var(--amber-light);
}
.doc-head .lede{color:var(--muted);font-size:1.03rem;margin:0;max-width:56ch}
.doc-meta{display:flex;flex-wrap:wrap;gap:.52rem;margin-top:.9rem}
.doc-meta span{
  font-size:.78rem;padding:.3rem .68rem;border-radius:999px;
  background:var(--surface-2);border:1px solid var(--line);color:var(--amber);
}

.prose h2{
  margin:2.1rem 0 .78rem;font-size:1.3rem;color:var(--amber-light);
  padding-left:.78rem;border-left:3px solid var(--amber);
}
.prose h3{margin:1.4rem 0 .52rem;font-size:1.06rem;color:var(--amber)}
.prose p{margin:0 0 1.02rem;color:#b4bcc8}
.prose ul,.prose ol{margin:0 0 1.02rem;padding-left:1.4rem;color:#b4bcc8}
.prose li{margin-bottom:.38rem}

.figure-row{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
  gap:1.05rem;margin:1.3rem 0 1.55rem;
}
.figure-row figure{
  margin:0;background:var(--surface);border:1px solid var(--line);
  border-radius:13px;overflow:hidden;
}
.figure-row img{width:100%;aspect-ratio:16/10;object-fit:cover}
.figure-row figcaption{padding:.68rem .88rem;font-size:.83rem;color:var(--muted)}

.card-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(205px,1fr));gap:.88rem;margin:1.05rem 0 1.55rem}
.card{
  background:var(--surface);border:1px solid var(--line);border-radius:13px;
  padding:1.05rem 1.15rem;
}
.card h3{margin:0 0 .42rem;font-size:.99rem;color:var(--amber)}
.card p{margin:0;font-size:.88rem;color:var(--muted);line-height:1.66}

.amber-band{
  background:linear-gradient(135deg,rgba(245,158,11,.11),rgba(217,119,6,.06));
  border:1px solid rgba(245,158,11,.28);border-radius:15px;
  padding:1.3rem 1.4rem;margin:1.55rem 0;
}
.amber-band h2{margin:0 0 .52rem;font-size:1.12rem;border:none;padding:0;color:var(--amber-light)}
.amber-band p{margin:0;color:#b4bcc8}

.price-strip{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(142px,1fr));
  gap:.78rem;margin:1.05rem 0;
}
.price-strip figure{margin:0;text-align:center}
.price-strip img{border-radius:11px;border:1px solid var(--line)}
.price-strip figcaption{font-size:.78rem;color:var(--muted);margin-top:.42rem}

.outlinks{
  display:flex;flex-wrap:wrap;gap:.68rem;margin:1.55rem 0;
}
.outlinks a{
  padding:.58rem 1.05rem;border-radius:999px;text-decoration:none;
  background:var(--surface-2);border:1px solid var(--line);
  color:var(--amber);font-size:.88rem;
}
.outlinks a:hover{border-color:var(--amber);background:var(--amber-glow)}

.faq details{
  background:var(--surface);border:1px solid var(--line);border-radius:11px;
  padding:.78rem 1.05rem;margin-bottom:.58rem;
}
.faq summary{cursor:pointer;font-weight:600;color:var(--amber-light)}
.faq p{margin:.58rem 0 0;font-size:.92rem;color:var(--muted)}

.site-footer{
  margin-top:2.6rem;padding-top:1.55rem;border-top:1px solid var(--line);
  font-size:.84rem;color:var(--muted);
}
.footer-links{display:flex;flex-wrap:wrap;gap:.68rem 1.05rem;margin-bottom:.78rem}
.footer-links a{color:var(--muted);text-decoration:none}
.footer-links a:hover{color:var(--amber)}

.page-simple .doc-head h1{font-size:1.68rem}
.simple-card{
  background:var(--surface);border:1px solid var(--line);border-radius:13px;
  padding:1.4rem 1.55rem;
}
.simple-card h2{font-size:1.1rem;color:var(--amber);margin:1.3rem 0 .52rem}
.simple-card h2:first-child{margin-top:0}
.simple-card p{color:#b4bcc8;margin:0 0 .88rem}

.error-page{
  min-height:100vh;display:flex;align-items:center;justify-content:center;
  padding:2rem;background:var(--bg);
}
.error-box{
  max-width:430px;text-align:center;background:var(--surface);
  border:1px solid var(--line);border-radius:17px;padding:2.1rem;
}
.error-box h1{font-size:3.1rem;margin:0;color:var(--amber);line-height:1}
.error-box p{color:var(--muted)}
.cta{
  display:inline-block;padding:.68rem 1.3rem;border-radius:999px;
  text-decoration:none;font-weight:700;margin-top:.55rem;
}
.cta-primary{background:var(--amber-deep);color:#1a1208}
.cta-primary:hover{background:var(--amber);color:#1a1208}

@media (max-width:900px){
  .rail{
    position:fixed;left:0;top:35px;z-index:45;height:calc(100vh - 35px);
    transform:translateX(-100%);transition:transform .28s ease;
    box-shadow:var(--shadow);
  }
  .rail.open{transform:translateX(0)}
  .rail-overlay{
    display:none;position:fixed;inset:35px 0 0 0;background:rgba(8,12,24,.62);z-index:44;
  }
  .rail-overlay.show{display:block}
  .rail-toggle{display:flex;align-items:center;justify-content:center}
  .rail-shell{display:block}
  .rail-content{padding-top:1.05rem}
}
