/* ===== News Portal 前端样式（[news_portal] 短代码 / News Portal 页面模板）===== */
.news-portal {
	--np-ink: #111827;
	--np-muted: #6b7280;
	--np-line: #e5e7eb;
	--np-accent: #2563eb;
	--np-accent-soft: #eff6ff;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--np-ink);
	max-width: 1200px;
	margin: 0 auto;
}
.news-portal a { text-decoration: none; color: inherit; }
.news-portal img { display: block; }

/* ---- 头条 ---- */
.news-portal-hero {
	display: grid;
	grid-template-columns: 1.35fr 1fr;
	gap: 0;
	margin-bottom: 24px;
	border: 1px solid var(--np-line);
	border-radius: 14px;
	overflow: hidden;
	background: #fff;
}
.news-portal-hero .np-media { min-height: 300px; background: #eef2f7; }
.news-portal-hero .np-media img { width: 100%; height: 100%; object-fit: cover; }
.news-portal-hero .np-media.no-img {
	display: flex; align-items: center; justify-content: center;
	background: linear-gradient(135deg, #dbeafe, #e0e7ff);
	color: #94a3b8; font-size: 14px; letter-spacing: .05em;
}
.news-portal-hero .np-body { padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.news-portal-hero .np-title { font-size: 26px; line-height: 1.3; font-weight: 700; margin: 0; }
.news-portal-hero .np-title a:hover { color: var(--np-accent); }
.news-portal-hero .np-excerpt { font-size: 15px; line-height: 1.6; color: var(--np-muted); margin: 0; }

/* ---- 网格 ---- */
.news-portal-grid {
	display: grid;
	gap: 18px;
	grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}
.news-portal-cols-2 .news-portal-grid { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); }
.news-portal-cols-4 .news-portal-grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }

/* ---- 卡片 ---- */
.np-card {
	background: #fff;
	border: 1px solid var(--np-line);
	border-radius: 12px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: box-shadow .15s ease, transform .15s ease;
}
.np-card:hover { box-shadow: 0 12px 28px rgba(17, 24, 39, .10); transform: translateY(-2px); }
.np-thumb { aspect-ratio: 16 / 9; background: #eef2f7; overflow: hidden; }
.np-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.np-card:hover .np-thumb img { transform: scale(1.04); }
.np-thumb.no-img {
	display: flex; align-items: center; justify-content: center;
	background: linear-gradient(135deg, #dbeafe, #e0e7ff);
	color: #94a3b8; font-size: 12px;
}
.np-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.np-title { font-size: 15.5px; line-height: 1.4; font-weight: 600; margin: 0; }
.np-card:hover .np-title a { color: var(--np-accent); }
.np-excerpt { font-size: 13px; line-height: 1.55; color: var(--np-muted); margin: 0; flex: 1; }

/* ---- 元信息 ---- */
.np-meta { font-size: 12px; color: var(--np-muted); display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.np-source { padding-left: 10px; border-left: 1px solid var(--np-line); }

/* ---- 分类标签 ---- */
.np-chip {
	display: inline-block;
	align-self: flex-start;
	background: var(--np-accent-soft);
	color: var(--np-accent);
	font-size: 11px;
	font-weight: 700;
	padding: 3px 9px;
	border-radius: 999px;
	text-transform: uppercase;
	letter-spacing: .04em;
}

.news-portal-empty { color: var(--np-muted); font-style: italic; }

/* ---- 页面模板容器 ---- */
.news-portal-page { padding: 40px 20px; background: #f6f8fb; }

/* ---- 响应式 ---- */
@media (max-width: 768px) {
	.news-portal-hero { grid-template-columns: 1fr; }
	.news-portal-hero .np-media { min-height: 200px; }
	.news-portal-hero .np-title { font-size: 20px; }
}
