/* ===== 声屿 · 搜狗收录优化站点样式 ===== */
:root{
  --ink:#12172b; --ink2:#3a4259; --muted:#7a8399; --line:#e6e9f0;
  --bg:#f4f6fa; --card:#fff; --brand:#4f46e5; --brand2:#7c6ff5;
  --warm:#ff7a45; --ok:#16a34a; --okbg:#eafbf1; --ad:#f59e0b; --adbg:#fffbeb;
  --shadow:0 10px 40px rgba(20,28,60,.10);
}
*{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth}
body{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif;background:var(--bg);color:var(--ink);line-height:1.65;-webkit-font-smoothing:antialiased}
a{color:inherit;text-decoration:none}
.wrap{max-width:1080px;margin:0 auto;padding:0 24px}

/* 头部 */
.site-header{background:#fff;border-bottom:1px solid var(--line);position:sticky;top:0;z-index:50}
.nav{height:62px;display:flex;align-items:center;gap:28px}
.logo{display:flex;align-items:center;gap:9px;font-size:18px;font-weight:800;letter-spacing:-.3px;flex:0 0 auto}
.logo .mark{width:28px;height:28px;border-radius:8px;background:linear-gradient(135deg,#4f46e5,#7c6ff5);position:relative;display:inline-flex;align-items:center;justify-content:center}
.logo .mark::after{content:"";width:11px;height:11px;border:2.5px solid #fff;border-radius:50%;border-bottom-color:transparent;transform:rotate(35deg)}
.nav .links{display:flex;gap:22px;font-size:13px;color:#5b6479;flex:1;flex-wrap:wrap}
.nav .links a:hover,.nav .links a:focus{color:var(--brand)}
.nav .search{margin-left:auto;width:190px;height:32px;border:1px solid #e4e7ef;border-radius:8px;display:flex;align-items:center;padding:0 8px 0 12px;gap:6px;flex:0 0 auto}
.nav .search input{border:none;outline:none;width:100%;font-size:12px;color:#3a4259;background:transparent}
.nav .search input::placeholder{color:#a3aabb}
.nav .search button{border:none;background:transparent;color:var(--brand);font-size:17px;cursor:pointer;line-height:1}
.menu-btn{display:none;border:none;background:transparent;font-size:20px;cursor:pointer;color:#5b6479}

/* 首页 Hero */
.hero-site{padding:44px 0 38px;background:linear-gradient(120deg,#fafaff,#f3f4ff);border-bottom:1px solid #eef0f5}
.hero-inner{display:flex;gap:40px;align-items:center}
.hero-site .ht{flex:1;min-width:0}
.hero-site .kick{font-size:11px;color:var(--brand);font-weight:700;letter-spacing:1px;margin-bottom:11px}
.hero-site h1{font-size:31px;line-height:1.3;font-weight:800;letter-spacing:-.5px;margin-bottom:12px}
.hero-site h1 em{font-style:normal;background:linear-gradient(120deg,#4f46e5,#9b6ff5);-webkit-background-clip:text;background-clip:text;color:transparent}
.hero-site p{font-size:13px;color:#5b6479;max-width:500px}
.hero-site .cta{display:flex;gap:10px;margin-top:20px;flex-wrap:wrap}
.btn{height:38px;padding:0 18px;border-radius:8px;font-size:12px;font-weight:700;display:inline-flex;align-items:center;justify-content:center}
.btn.p{background:var(--brand);color:#fff}.btn.p:hover{background:#4338ca}
.btn.g{background:#fff;color:var(--ink);border:1px solid #dfe3ec}
.hero-site .art{width:240px;height:150px;border-radius:13px;background:linear-gradient(135deg,#6a5cff,#8f7bff 45%,#ff9d7a 130%);box-shadow:0 16px 40px rgba(79,70,229,.28);position:relative;overflow:hidden;flex:0 0 240px}
.hero-site .art .tagline{position:absolute;top:16px;left:18px;color:#fff;font-size:10px;font-weight:700;letter-spacing:2px;opacity:.9}
.hero-site .art .bars{position:absolute;bottom:18px;left:20px;display:flex;gap:4px;align-items:flex-end;height:40px}
.hero-site .art .bars i{width:4px;background:rgba(255,255,255,.85);border-radius:3px;display:block}

/* 面包屑 */
.crumb{padding:14px 0 0;font-size:11px;color:#9aa2b4}
.crumb a{color:#5b6479}.crumb a:hover{color:var(--brand)}
.crumb b{color:#5b6479;font-weight:500}
.crumb .sep{margin:0 4px;color:#c3c9d6}

/* 内容区 */
.content{padding:22px 0 40px;display:flex;gap:34px}
.main{flex:1;min-width:0}
.side{width:250px;flex:0 0 250px}
.sec-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px;flex-wrap:wrap;gap:10px}
.sec-title h2{font-size:18px;font-weight:800}
.sec-title .tabs{display:flex;gap:7px;flex-wrap:wrap}
.sec-title .tabs a{font-size:11px;color:#8a92a6;padding:5px 11px;border:1px solid #e8ebf2;border-radius:20px}
.sec-title .tabs a.on{background:#eef0ff;color:var(--brand);border-color:#dfe2ff;font-weight:700}
.cat-desc{font-size:12px;color:#7a8399;margin:0 0 8px}

/* 文章列表项 */
.post{display:flex;gap:16px;padding:16px 0;border-bottom:1px solid #f0f2f6}
.post .thumb{width:140px;height:92px;border-radius:9px;flex:0 0 140px;display:block}
.t1{background:linear-gradient(135deg,#5b6cff,#9a7bff)}.t2{background:linear-gradient(135deg,#ff8a5b,#ffb37a)}.t3{background:linear-gradient(135deg,#2bb6a8,#6ee0c8)}.t4{background:linear-gradient(135deg,#8b5cf6,#c084fc)}
.post .body{flex:1;min-width:0}
.post .cat,.post .cat a{font-size:10.5px;color:var(--brand);font-weight:700;margin-bottom:5px;display:inline-block}
.post h3{font-size:14.5px;font-weight:750;line-height:1.5;margin-bottom:7px}
.post h3 a:hover{color:var(--brand)}
.post .desc{font-size:12px;color:#7a8399;line-height:1.6;margin-bottom:8px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.post .foot{font-size:10.5px;color:#a3aabb;display:flex;gap:13px;flex-wrap:wrap;align-items:center}
.post .foot .origin{color:var(--ok);background:var(--okbg);padding:2px 7px;border-radius:5px;font-weight:600}
.empty{padding:40px 0;color:#9aa2b4;font-size:13px;text-align:center}
.pager{display:flex;gap:6px;flex-wrap:wrap;padding:20px 0}
.pager a{min-width:32px;height:32px;padding:0 10px;border:1px solid #e4e7ef;border-radius:7px;display:inline-flex;align-items:center;justify-content:center;font-size:12px;color:#5b6479}
.pager a.on{background:var(--brand);color:#fff;border-color:var(--brand)}

/* 侧栏 */
.box{border:1px solid #eef0f5;border-radius:11px;padding:16px;margin-bottom:16px;background:#fff}
.box h4{font-size:13px;font-weight:750;margin-bottom:12px;display:flex;align-items:center;gap:7px}
.box h4::before{content:"";width:3px;height:13px;background:var(--brand);border-radius:2px}
.hot li{list-style:none;font-size:12px;padding:7px 0;border-bottom:1px dashed #e8ebf2;display:flex;gap:7px;color:#4a5266}
.hot li span{color:var(--warm);font-weight:800;font-style:italic;flex:0 0 auto}
.hot li:last-child{border:none}
.hot li a:hover{color:var(--brand)}
.verified{background:linear-gradient(135deg,#f0fdf6,#eafbf1);border-color:#d3f2e0}
.verified .row{display:flex;justify-content:space-between;font-size:11px;padding:5px 0;color:#4a5266}
.verified .row b{color:#1a7f43;font-weight:700}

/* ===== 广告位：文章开头唯一展示位，紧凑小横条，明确标注、固定、不可关闭 ===== */
.adslot{position:relative;border:1px dashed #f0c674;background:var(--adbg);border-radius:7px;padding:9px 12px 8px;text-align:center;margin-bottom:12px}
.adslot .adtag{position:absolute;top:0;left:12px;transform:translateY(-50%);background:var(--ad);color:#fff;font-size:9px;font-weight:800;letter-spacing:1px;padding:2px 7px;border-radius:4px;z-index:2}
.ad-inner{margin:0 auto;line-height:1.4}
/* 上传的本地广告图：等比缩放、不铺底色，避免图片自带的颜色影响正文区 */
.adslot.has-img{background:#fff;border-color:#e8e4d8}
.adslot .ad-img{display:block;margin:0 auto;max-width:100%;max-height:90px;width:auto;height:auto;object-fit:contain;border-radius:5px}
.adslot .ad-link{display:block;text-decoration:none}
.adslot .ad-link:hover{opacity:.92}
/* 兼容旧版自定义代码里的大图，防止撑开版面 */
.ad-inner img{max-height:90px;height:auto;max-width:100%}
.ad-ph{border-radius:6px;background:linear-gradient(135deg,#fde9c8,#fcd9a0);min-height:44px;padding:8px 12px;display:flex;flex-direction:row;align-items:center;justify-content:center;gap:10px;color:#8a5a1a}
.ad-ph .big{font-size:12px;font-weight:800;margin:0}.ad-ph .small{font-size:10px;opacity:.85;margin:0}

/* 文章页 */
.article-layout{padding:20px 0 40px;display:flex;gap:34px}
.article{flex:1;min-width:0}
.article .cat{color:var(--brand);font-size:11px;font-weight:700}
.article h1{font-size:25px;font-weight:800;line-height:1.4;letter-spacing:-.4px;margin:12px 0 14px}
.article .byline{display:flex;align-items:center;gap:12px;font-size:11px;color:#8a92a6;padding-bottom:16px;border-bottom:1px solid #eef0f5;flex-wrap:wrap}
.article .byline .av{width:30px;height:30px;border-radius:50%;background:linear-gradient(135deg,#4f46e5,#7c6ff5);display:inline-block;flex:0 0 30px}
.article .byline b{color:#3a4259}
.article .lead{font-size:13.5px;color:#4a5266;line-height:1.85;margin:18px 0;background:#f8f9ff;border-left:3px solid var(--brand);padding:14px 18px;border-radius:0 9px 9px 0}
.post-content{font-size:13px;color:#4a5266;line-height:1.95}
.post-content h2{font-size:18px;font-weight:800;margin:26px 0 12px;padding-left:11px;border-left:4px solid var(--brand);color:var(--ink);scroll-margin-top:80px}
.post-content p{margin-bottom:14px}
.post-content a{color:var(--brand);text-decoration:underline}
.post-content ul,.post-content ol{padding-left:22px;margin-bottom:14px}
.post-content li{margin-bottom:6px}
.article .note{background:#fff9f6;border:1px solid #ffe2d2;border-radius:9px;padding:12px 16px;font-size:11.5px;color:#8a5a3a;margin:16px 0}
.article .note b{color:var(--warm)}
.article .tags2{display:flex;gap:7px;margin-top:22px;flex-wrap:wrap}
.article .tags2 span{font-size:10.5px;background:#f0f2f8;color:#5b6479;padding:4px 10px;border-radius:6px}
.art-side{width:250px;flex:0 0 250px}
.art-side .toc{border:1px solid #eef0f5;border-radius:10px;padding:15px;margin-bottom:16px;background:#fff}
.art-side .toc h4{font-size:12.5px;font-weight:750;margin-bottom:10px}
.art-side .toc a{display:block;font-size:11px;color:#5b6479;padding:5px 0 5px 10px;border-left:2px solid #eef0f5}
.art-side .toc a:hover{color:var(--brand);border-left-color:var(--brand)}
.static-page .post-content h2{font-size:17px}

/* 页脚 */
.site-foot{background:#12172b;color:#aab3d6;padding:26px 0;font-size:11px;margin-top:20px}
.site-foot .cols{display:flex;gap:54px;margin-bottom:18px;flex-wrap:wrap}
.site-foot .cols div{min-width:130px}
.site-foot .cols div b{color:#fff;display:block;margin-bottom:8px;font-size:11.5px}
.site-foot .cols a{display:block;color:#aab3d6;margin-bottom:4px}
.site-foot .cols a:hover{color:#fff}
.site-foot .beian{border-top:1px solid #2a3152;padding-top:14px;color:#8b94b5}
.site-foot .beian a{color:#8b94b5;text-decoration:none}
.site-foot .beian a:hover{color:#fff}
.site-foot .beian .v{color:#6ee7a8}

/* 404 */
.notfound{text-align:center;padding:90px 0}
.notfound .code{font-size:90px;font-weight:800;color:#e6e9f0;line-height:1}
.notfound h1{font-size:24px;margin:10px 0}.notfound p{color:#7a8399;margin-bottom:22px}

/* 响应式 */
@media(max-width:900px){
  .nav{gap:14px}
  .nav .links{display:none;position:absolute;top:62px;left:0;right:0;background:#fff;border-bottom:1px solid var(--line);padding:12px 24px;flex-direction:column;gap:12px}
  .nav .links.open{display:flex}
  .nav .search{width:130px}
  .menu-btn{display:block;margin-left:auto}
  .hero-inner{flex-direction:column;align-items:flex-start;gap:20px}
  .hero-site .art{flex:0 0 auto;width:100%;max-width:300px}
  .content,.article-layout{flex-direction:column}
  .side,.art-side{width:100%;flex:auto}
  .post .thumb{width:104px;height:70px;flex-basis:104px}
  .article h1{font-size:22px}
}
@media(max-width:560px){
  .wrap{padding:0 16px}
  .nav .search{display:none}
  .hero-site h1{font-size:25px}
  .hero-site{padding:32px 0}
  .post .thumb{width:88px;height:64px;flex-basis:88px}
  .post h3{font-size:13.5px}
  .site-foot .cols{gap:26px}
}
