/* 远帆资讯 · 江苏产业与升学资料 2026-11-19（v2：单一 PDF 下载）
   独立板块样式，只作用于 #news，不覆盖其它路由视觉。
   新增资料：直接往 index.html 的 #news .news-grid 里追加一个 <article class="news-card">。 */
.news-section { background: var(--paper); }
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 32px;
}
.news-card {
  display: flex;
  flex-direction: column;
  min-height: 264px;
  padding: 22px 20px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  transition: border-color .18s ease, box-shadow .18s ease;
}
.news-card:hover { border-color: var(--line-strong); box-shadow: 0 10px 26px rgba(20, 23, 28, .06); }
.news-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.news-no { color: var(--cobalt); font: 600 12px/1 var(--mono); letter-spacing: .08em; }
.news-pages { color: var(--faint); font: 10.5px/1 var(--mono); white-space: nowrap; }
.news-card h3 {
  margin: 16px 0 0;
  font-size: 17px;
  font-weight: 560;
  line-height: 1.45;
  letter-spacing: -.01em;
}
.news-card > p { margin: 10px 0 0; color: var(--muted); font-size: 12.5px; line-height: 1.75; }
.news-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 18px;
  color: var(--faint);
  font: 10.5px/1.2 var(--mono);
}
.news-actions { display: flex; gap: 8px; margin-top: 12px; }
.news-dl {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 42px;
  border: 1px solid var(--cobalt);
  border-radius: 9px;
  background: var(--cobalt);
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}
.news-dl:hover, .news-dl:focus-visible { background: #12294f; border-color: #12294f; color: #fff; }

@media (max-width: 980px) {
  .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .news-card { min-height: 0; }
}
@media (max-width: 640px) {
  .news-gate-card { padding: 22px 18px; }
  .news-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 24px; }
  .news-card { padding: 18px 16px 16px; }
  .news-card h3 { font-size: 16px; }
}

/* 登录门：未登录只看得到引导，资料列表对已登录用户显示 */
.news-gate { margin-top: 32px; }
.news-gate-card {
  max-width: 560px;
  padding: 28px 26px;
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
  background: var(--paper);
}
.news-gate-card h3 { margin: 0; font-size: 19px; font-weight: 560; line-height: 1.4; letter-spacing: -.01em; }
.news-gate-card > p { margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.75; }
/* 站点外壳有 `body.yf-ui-prototype .route-content :is(button…)` 的通用按钮色，
   这里用 ID 前缀压过它，避免门内按钮变成米白底。 */
#news .news-gate-btn {
  margin-top: 18px;
  min-height: 44px;
  padding: 0 24px;
  border: 1px solid var(--cobalt);
  border-radius: 9px;
  background: var(--cobalt);
  color: #fff;
  font: 600 13px/1 var(--sans);
  cursor: pointer;
}
#news .news-gate-btn:hover, #news .news-gate-btn:focus-visible { background: #12294f; border-color: #12294f; color: #fff; }
.news-gate-note { color: var(--faint); font-size: 11.5px; }
.news-body { display: none; }
body[data-auth-state="authenticated"] .news-body { display: block; }
body[data-auth-state="authenticated"] .news-gate { display: none; }
