/* =========================================================
   新闻资讯：列表页（/news/、分类、搜索）和文章详情页
   由新闻区块的 block.json 引用，只在新闻页面加载。标题区沿用产品中心的 .pl-hero（shop.css）。
   ========================================================= */

/* ---------- 标题区（在 .pl-hero 基础上调整） ---------- */
.nh .pl-hero-in{min-height:calc(3.9 * var(--r));padding-bottom:calc(.46 * var(--r))}
.nh-orb{width:calc(4.4 * var(--r));right:calc(-.4 * var(--r));margin-top:calc(-2.2 * var(--r))}
.nh-search{max-width:calc(5 * var(--r))}

/* ---------- 分类导航（吸顶） ---------- */
.nt{position:sticky;top:var(--hd-h);z-index:60;background:rgba(255,255,255,.96);-webkit-backdrop-filter:saturate(1.4) blur(10px);backdrop-filter:saturate(1.4) blur(10px);border-bottom:1px solid #e6eaf0}
.nt-in{display:flex;align-items:center;height:max(56px,calc(.68 * var(--r)))}
.nt-links{display:flex;height:100%}
.nt-links a{position:relative;display:flex;align-items:center;height:100%;padding:0 calc(.26 * var(--r));font-size:max(15px,calc(.17 * var(--r)));color:#4a4f57;white-space:nowrap;transition:color .3s}
.nt-links a:first-child{padding-left:0}
.nt-links a::after{content:"";position:absolute;left:calc(.26 * var(--r));right:calc(.26 * var(--r));bottom:-1px;height:calc(.03 * var(--r));border-radius:2px;background:linear-gradient(90deg,var(--blue-2),var(--blue-deep));transform:scaleX(0);transition:transform .45s var(--ease)}
.nt-links a:first-child::after{left:0}
.nt-links a:hover{color:var(--blue-2)}
.nt-links a:hover::after{transform:scaleX(.35)}
.nt-links a.on{color:var(--blue-deep);font-weight:600}
.nt-links a.on::after{transform:none}

/* ---------- 列表 ---------- */
.nl{padding:calc(.6 * var(--r)) 0 calc(1 * var(--r));background:radial-gradient(45% 30% at 100% 0,rgba(214,232,255,.55),transparent 70%),linear-gradient(#f5f8fd,#fff 520px)}

/* 分类小标签：每个分类一种颜色 */
.n-meta{position:relative;z-index:2;display:flex;align-items:center;gap:calc(.12 * var(--r));font-size:max(12px,calc(.13 * var(--r)));color:var(--muted)}
.n-meta time{font-family:var(--f-num);letter-spacing:.02em}
.n-chip{--c:var(--blue);--bg:#e8f1fc;display:inline-flex;align-items:center;height:max(18px,calc(.24 * var(--r)));padding:0 calc(.1 * var(--r));border-radius:6px;font-size:max(12px,calc(.12 * var(--r)));font-weight:500;line-height:1;color:var(--c);background:var(--bg);transition:background .3s,color .3s}
.n-chip:hover{background:var(--c);color:#fff}
.n-chip.is-industry-news{--c:#0d8073;--bg:#e2f4f1}
.n-chip.is-technology{--c:#5847c8;--bg:#eeebfb}
.n-chip.is-team{--c:#c0640f;--bg:#fdf0e1}
.n-chip.is-events{--c:#c22f50;--bg:#fde9ee}
.n-noimg{display:grid;place-items:center;width:100%;height:100%;color:#b9c6d8;background:linear-gradient(135deg,#eef3fa,#e3ebf6)}
.n-noimg svg{width:max(42px,calc(.56 * var(--r)))}

/* 头条 */
.nf{position:relative;display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);margin-bottom:calc(.5 * var(--r));border-radius:calc(.18 * var(--r));overflow:hidden;background:#fff;box-shadow:0 20px 50px rgba(15,37,87,.08);transition:box-shadow .6s,transform .6s var(--ease)}
.nf:hover{transform:translateY(-4px);box-shadow:0 30px 70px rgba(15,37,87,.14)}
.nf-img{position:relative;aspect-ratio:1.75;height:100%;overflow:hidden;background:#e9eef6}
.nf-img img{width:100%;height:100%;object-fit:cover;transition:transform 1.4s var(--ease)}
.nf:hover .nf-img img{transform:scale(1.05)}
.nf-badge{position:absolute;left:calc(.24 * var(--r));top:calc(.24 * var(--r));padding:calc(.05 * var(--r)) calc(.14 * var(--r));border-radius:99px;font-size:max(12px,calc(.12 * var(--r)));font-weight:600;letter-spacing:.1em;color:#fff;background:rgba(15,37,87,.62);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}
.nf-body{display:flex;flex-direction:column;padding:calc(.46 * var(--r)) calc(.5 * var(--r)) calc(.36 * var(--r))}
.nf-title{margin-top:calc(.2 * var(--r));font-size:max(21px,calc(.3 * var(--r)));line-height:1.5;font-weight:700;color:var(--ink)}
.nf-title a{transition:color .3s}
.nf-title a::after{content:"";position:absolute;inset:0;z-index:1}
.nf:hover .nf-title a{color:var(--blue)}
.nf-excerpt{margin-top:calc(.18 * var(--r));font-size:max(14px,calc(.16 * var(--r)));line-height:1.9;color:#5f6670;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.nf-foot{display:flex;align-items:center;gap:calc(.16 * var(--r));margin-top:auto;padding-top:calc(.3 * var(--r));font-size:max(12px,calc(.13 * var(--r)));color:var(--muted)}
.nf-views{display:inline-flex;align-items:center;gap:calc(.06 * var(--r))}
.nf-views svg{width:calc(.15 * var(--r))}
.nf-more{display:inline-flex;align-items:center;gap:calc(.04 * var(--r));margin-left:auto;font-size:max(13px,calc(.14 * var(--r)));font-weight:600;color:var(--blue)}
.nf-more svg{width:calc(.14 * var(--r));transition:transform .4s var(--ease)}
.nf:hover .nf-more svg{transform:translateX(4px)}

/* 卡片 */
.ng{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:calc(.36 * var(--r)) calc(.3 * var(--r))}
.ncd{position:relative;display:flex;flex-direction:column;border:1px solid #edf1f6;border-radius:calc(.14 * var(--r));overflow:hidden;background:#fff;box-shadow:0 10px 30px rgba(15,37,87,.05);transition:transform .5s var(--ease),box-shadow .5s,border-color .5s}
.ncd:hover{transform:translateY(-6px);border-color:#dbe6f4;box-shadow:0 24px 50px rgba(15,37,87,.12)}
.ncd-img{aspect-ratio:1.75;overflow:hidden;background:#eef2f8}
.ncd-img img{width:100%;height:100%;object-fit:cover;transition:transform 1.1s var(--ease)}
.ncd:hover .ncd-img img{transform:scale(1.06)}
.ncd-body{flex:1;display:flex;flex-direction:column;padding:calc(.24 * var(--r)) calc(.26 * var(--r)) calc(.2 * var(--r))}
.ncd-title{margin-top:calc(.14 * var(--r));min-height:3.1em;font-size:max(16px,calc(.19 * var(--r)));line-height:1.55;font-weight:600;color:var(--ink);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.ncd-title a{transition:color .3s}
.ncd-title a::after{content:"";position:absolute;inset:0;z-index:1}
.ncd:hover .ncd-title a{color:var(--blue)}
.ncd-excerpt{margin-top:calc(.1 * var(--r));min-height:3.6em;font-size:max(13px,calc(.145 * var(--r)));line-height:1.8;color:#7a818c;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.ncd-foot{display:flex;align-items:center;gap:calc(.12 * var(--r));margin-top:auto;padding-top:calc(.16 * var(--r));font-size:max(12px,calc(.12 * var(--r)));color:#a2a9b4}
.ncd-foot span:first-child:not(.ncd-go){display:inline-flex;align-items:center;gap:calc(.05 * var(--r));font-family:var(--f-num)}
.ncd-foot svg{width:calc(.14 * var(--r))}
.ncd-go{display:grid;place-items:center;width:max(22px,calc(.3 * var(--r)));height:max(22px,calc(.3 * var(--r)));margin-left:auto;border-radius:50%;color:var(--blue);background:#f0f5fc;transition:background .4s,color .4s,transform .4s var(--ease)}
.ncd-go svg{width:calc(.14 * var(--r))}
.ncd:hover .ncd-go{color:#fff;background:var(--blue);transform:translateX(3px)}

/* 空状态、分页 */
.n-empty{display:flex;flex-direction:column;align-items:center;gap:calc(.16 * var(--r));padding:calc(.8 * var(--r)) 0;text-align:center;color:var(--muted)}
.n-empty svg{width:max(42px,calc(.56 * var(--r)));color:#c3cfdf}
.npg{display:flex;flex-wrap:wrap;justify-content:center;gap:calc(.08 * var(--r));margin-top:calc(.6 * var(--r))}
.npg .page-numbers{display:grid;place-items:center;min-width:max(32px,calc(.42 * var(--r)));height:max(32px,calc(.42 * var(--r)));padding:0 calc(.12 * var(--r));border:1px solid #e3e8f0;border-radius:12px;font-family:var(--f-num);font-size:max(14px,calc(.15 * var(--r)));color:#4a4f57;background:#fff;transition:border-color .3s,color .3s,box-shadow .3s}
.npg a.page-numbers:hover{border-color:var(--blue-2);color:var(--blue-2);box-shadow:0 8px 20px rgba(23,100,189,.12)}
.npg .current{border-color:transparent;color:#fff;background:linear-gradient(135deg,var(--blue-2),var(--blue-deep));box-shadow:0 8px 20px rgba(23,100,189,.28)}
.npg .dots{border:0;background:none}
.npg svg{width:calc(.16 * var(--r))}

/* =========================================================
   文章详情
   ========================================================= */
.ah{position:relative;overflow:hidden;padding:calc(.46 * var(--r)) 0 calc(.44 * var(--r));background:linear-gradient(180deg,#edf4fe,#f6f9fe 70%,#fff)}
.ah-bg{position:absolute;inset:0;background:url(../img/news-bg.webp) 70% 30%/cover no-repeat;opacity:.4;-webkit-mask:linear-gradient(90deg,transparent,#000 60%);mask:linear-gradient(90deg,transparent,#000 60%)}
.ah-in{position:relative}
.ah-crumbs ol,.aa ol{list-style:none}
.ah-crumbs ol{display:flex;flex-wrap:wrap;gap:calc(.04 * var(--r)) calc(.08 * var(--r));font-size:max(12px,calc(.13 * var(--r)));color:#8a919c}
.ah-crumbs li+li::before{content:"/";margin-right:calc(.08 * var(--r));color:#c5cad2}
.ah-crumbs a{transition:color .3s}
.ah-crumbs a:hover{color:var(--blue)}
.ah .n-chip{margin-top:calc(.34 * var(--r))}
.ah-title{max-width:calc(9.4 * var(--r));margin-top:calc(.16 * var(--r));font-size:max(26px,calc(.42 * var(--r)));line-height:1.42;font-weight:300;letter-spacing:.01em;color:var(--ink)}
.ah-meta{display:flex;flex-wrap:wrap;gap:calc(.08 * var(--r)) max(21px,calc(.28 * var(--r)));margin-top:calc(.26 * var(--r));font-size:max(13px,calc(.14 * var(--r)));color:#7a818c}
.ah-meta li{display:inline-flex;align-items:center;gap:calc(.06 * var(--r))}
.ah-meta svg{width:calc(.15 * var(--r));color:#9fb0c8}
.ah-meta time{font-family:var(--f-num)}

.ar-layout{display:grid;grid-template-columns:minmax(0,1fr) calc(3.2 * var(--r));gap:calc(.7 * var(--r));align-items:start;padding:calc(.5 * var(--r)) 0 calc(.7 * var(--r))}

/* 正文排版 */
.ar-body{min-width:0;font-size:max(16px,calc(.18 * var(--r)));line-height:1.95;color:#30353d;overflow-wrap:break-word}
.ar-body>*+*{margin-top:1.05em}
.ar-body p{text-align:justify}
.ar-body h2,.ar-body h3{scroll-margin-top:calc(var(--hd-h) + 24px)}
.ar-body h2{position:relative;margin-top:1.9em;padding-left:.8em;font-size:1.28em;line-height:1.5;font-weight:700;color:var(--ink)}
.ar-body h2::before{content:"";position:absolute;left:0;top:.3em;bottom:.3em;width:calc(.04 * var(--r));border-radius:2px;background:linear-gradient(var(--blue-2),var(--blue-deep))}
.ar-body h3{margin-top:1.6em;font-size:1.08em;line-height:1.6;font-weight:700;color:var(--blue-deep)}
.ar-body h2+*,.ar-body h3+*{margin-top:.6em}
.ar-body strong{font-weight:700;color:var(--ink)}
.ar-body a{color:var(--blue);text-decoration:underline;text-decoration-color:rgba(23,100,189,.35);text-underline-offset:3px;transition:text-decoration-color .3s}
.ar-body a:hover{text-decoration-color:currentColor}
.ar-body ul,.ar-body ol{padding-left:1.4em}
.ar-body ul{list-style:disc}
.ar-body ol{list-style:decimal}
.ar-body li+li{margin-top:.35em}
.ar-body li::marker{color:var(--blue-2)}
.ar-body .wp-block-image{margin-top:1.5em;margin-bottom:1.5em}
.ar-body .wp-block-image+.wp-block-image{margin-top:.8em}
.ar-body img{height:auto;margin:0 auto;border-radius:10px}
.ar-body img.is-zoomable{cursor:zoom-in}
.ar-body figcaption{margin-top:.6em;font-size:max(12px,calc(.13 * var(--r)));color:var(--muted);text-align:center}
.ar-body .wp-block-table{overflow-x:auto}
.ar-body table{width:100%;border-collapse:collapse;font-size:.9em;line-height:1.7}
.ar-body td,.ar-body th{padding:.6em .8em;border:1px solid #e1e6ee;text-align:left;vertical-align:top}
.ar-body tr:nth-child(odd){background:#f7f9fc}
.ar-body blockquote{padding:.9em 1.2em;border-left:4px solid #cfe0f6;border-radius:0 10px 10px 0;background:#f5f9ff;color:#4a5562}
/* 转载文章的「文章来源」「作者」行 */
.ar-body .ar-source{font-size:max(12px,calc(.13 * var(--r)));line-height:1.7;color:#98a0ab;text-align:left}
.ar-body .ar-source+.ar-source{margin-top:.15em}

/* 侧栏 */
.aa{position:sticky;top:calc(var(--hd-h) + 24px)}
.aa-in{display:flex;flex-direction:column;gap:calc(.16 * var(--r))}
.aa-card{padding:max(15px,calc(.2 * var(--r))) max(16px,calc(.22 * var(--r)));border:1px solid #edf1f6;border-radius:14px;background:#fff;box-shadow:0 10px 30px rgba(15,37,87,.05)}
.aa-h{display:flex;align-items:center;gap:calc(.08 * var(--r));font-size:max(14px,calc(.15 * var(--r)));font-weight:700;color:var(--ink)}
.aa-h::before{content:"";width:calc(.04 * var(--r));height:calc(.14 * var(--r));border-radius:2px;background:linear-gradient(var(--blue-2),var(--blue-deep))}
.aa-toc ol{max-height:calc(100vh - var(--hd-h) - 300px);margin-top:calc(.12 * var(--r));overflow:auto;scrollbar-width:thin}
.aa-toc a{display:block;padding:calc(.06 * var(--r)) 0 calc(.06 * var(--r)) calc(.12 * var(--r));border-left:2px solid #e8edf4;font-size:max(13px,calc(.14 * var(--r)));line-height:1.5;color:#5f6670;transition:color .3s,border-color .3s}
.aa-toc .lv3 a{padding-left:max(18px,calc(.24 * var(--r)));font-size:max(12px,calc(.13 * var(--r)));color:#8a919c}
.aa-toc a:hover{color:var(--blue-2)}
.aa-toc a.on{border-color:var(--blue-2);color:var(--blue);font-weight:600}
.aa-share{display:flex;align-items:center;justify-content:space-between;padding:calc(.14 * var(--r)) calc(.18 * var(--r)) calc(.14 * var(--r)) max(16px,calc(.22 * var(--r)));font-size:max(13px,calc(.14 * var(--r)));color:#5f6670}
.aa-copy{display:inline-flex;align-items:center;gap:calc(.06 * var(--r));height:max(26px,calc(.34 * var(--r)));padding:0 calc(.14 * var(--r));border-radius:99px;font-size:max(12px,calc(.13 * var(--r)));color:var(--blue);background:#f0f5fc;transition:background .3s,color .3s}
.aa-copy b{font-weight:600}
.aa-copy svg{width:calc(.15 * var(--r))}
.aa-copy:hover{color:#fff;background:var(--blue)}
.aa-copy.is-done{color:#178a52;background:#e5f6ed}
.aa-latest ol{margin-top:calc(.06 * var(--r))}
.aa-latest li+li{border-top:1px dashed #e6ebf2}
.aa-latest a{display:block;padding:calc(.11 * var(--r)) 0}
.aa-latest b{font-size:max(13px,calc(.14 * var(--r)));font-weight:500;line-height:1.6;color:#30353d;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;transition:color .3s}
.aa-latest time{display:block;margin-top:calc(.04 * var(--r));font-family:var(--f-num);font-size:max(12px,calc(.12 * var(--r)));color:#a2a9b4}
.aa-latest a:hover b{color:var(--blue)}
.aa-qr{display:flex;align-items:center;gap:calc(.14 * var(--r))}
.aa-qr img{flex:none;width:max(66px,calc(.88 * var(--r)));height:max(66px,calc(.88 * var(--r)));border-radius:8px}
.aa-qr p{margin-top:calc(.06 * var(--r));font-size:max(12px,calc(.12 * var(--r)));line-height:1.6;color:#8a919c}

/* 底部：上一篇 / 下一篇、相关文章 */
.af{padding:0 0 calc(1 * var(--r));background:linear-gradient(#fff,#f5f8fc)}
.af-pn{display:grid;grid-template-columns:1fr 1fr;gap:calc(.24 * var(--r));padding-top:calc(.4 * var(--r));border-top:1px solid #e8edf4}
.af-pn-item{display:flex;flex-direction:column;gap:calc(.08 * var(--r));padding:calc(.24 * var(--r)) calc(.28 * var(--r));border:1px solid #edf1f6;border-radius:14px;background:#f6f9fd;transition:background .4s,border-color .4s,box-shadow .4s}
.af-pn-item.is-next{align-items:flex-end;text-align:right}
.af-pn-item small{display:inline-flex;align-items:center;gap:calc(.04 * var(--r));font-size:max(12px,calc(.13 * var(--r)));color:var(--muted)}
.af-pn-item.is-next small{flex-direction:row-reverse}
.af-pn-item small svg{width:calc(.14 * var(--r))}
.af-pn-item b{font-size:max(15px,calc(.17 * var(--r)));font-weight:600;line-height:1.55;color:var(--ink);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;transition:color .3s}
a.af-pn-item:hover{border-color:#cfe0f6;background:#fff;box-shadow:0 14px 34px rgba(15,37,87,.08)}
a.af-pn-item:hover b{color:var(--blue)}
.af-pn-item.is-none b{font-weight:400;color:#a2a9b4}
.af-rel{margin-top:calc(.8 * var(--r))}
.af-rel-h{display:flex;align-items:flex-end;justify-content:space-between;gap:calc(.16 * var(--r));margin-bottom:calc(.3 * var(--r))}
.af-rel-h h2{font-size:max(22px,calc(.3 * var(--r)));font-weight:700;color:var(--ink)}
.af-rel-h a{display:inline-flex;align-items:center;gap:calc(.04 * var(--r));font-size:max(13px,calc(.14 * var(--r)));color:var(--blue)}
.af-rel-h a svg{width:calc(.14 * var(--r));transition:transform .4s var(--ease)}
.af-rel-h a:hover svg{transform:translateX(3px)}

/* 图片放大 */
.n-lb{max-width:none;max-height:none;width:100vw;height:100vh;margin:0;padding:0;border:0;background:rgba(10,20,40,.86);cursor:zoom-out}
.n-lb::backdrop{background:transparent}
.n-lb[open]{display:grid;place-items:center}
.n-lb img{max-width:92vw;max-height:90vh;border-radius:8px;box-shadow:0 30px 80px rgba(0,0,0,.4)}

/* =========================================================
   手机
   ========================================================= */
@media (max-width:899px){
  .nh .pl-hero-in{min-height:0}
  .nt-in{width:100%;max-width:none;height:50px;padding:0 16px;overflow-x:auto;scrollbar-width:none}
  .nt-in::-webkit-scrollbar{display:none}
  .nt-links a{padding:0 14px;font-size:15px}
  .nt-links a::after{left:14px;right:14px}

  .nl{padding:20px 0 48px}
  .nf{grid-template-columns:1fr;margin-bottom:20px;border-radius:16px}
  .nf-badge{left:14px;top:14px}
  .nf-body{padding:18px 18px 16px}
  .nf-title{margin-top:12px;font-size:19px}
  .nf-excerpt{margin-top:8px;-webkit-line-clamp:2}
  .nf-foot{padding-top:14px}

  /* 手机上卡片改成左图右文 */
  .ng{grid-template-columns:1fr;gap:12px}
  .ncd{display:grid;grid-template-columns:116px minmax(0,1fr);border-radius:12px}
  .ncd:hover{transform:none}
  .ncd-img{aspect-ratio:auto;height:100%;min-height:100px}
  .ncd-body{padding:12px 14px}
  .ncd-title{min-height:0;margin-top:8px;font-size:15px}
  .ncd-excerpt,.ncd-foot{display:none}
  .npg{margin-top:28px}
  .npg .page-numbers{min-width:38px;height:38px;border-radius:10px}

  .ah{padding:20px 0 22px}
  .ah .n-chip{margin-top:18px}
  .ah-title{margin-top:10px;font-size:23px}
  .ah-meta{gap:6px 16px;margin-top:14px;font-size:13px}
  .ar-layout{grid-template-columns:1fr;gap:28px;padding:24px 0 36px}
  .ar-body{font-size:16px;line-height:1.9}
  .ar-body p{text-align:left} /* 手机上两端对齐遇到英文单词会拉出大空隙 */
  .ar-body .wp-block-image{margin-left:-4px;margin-right:-4px}
  .aa{position:static}
  .aa-toc{display:none!important}
  .af-pn{grid-template-columns:1fr;gap:10px;padding-top:24px}
  .af-pn-item{padding:14px 16px}
  .af-pn-item.is-next{align-items:flex-start;text-align:left}
  .af-pn-item.is-next small{flex-direction:row}
  .af-rel{margin-top:36px}
  .af-rel-h h2{font-size:20px}
}
