/* ===================== 前台基础样式（默认模板） ===================== */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
    font-size: 16px; line-height: 1.7; color: #333; background: #f7f8fa;
}
a { color: #2563eb; text-decoration: none; }
a:hover { color: #1d4ed8; text-decoration: underline; }
.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* 页头 */
.site-header { background: #fff; border-bottom: 1px solid #e5e7eb; position: sticky; top: 0; z-index: 10; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 62px; }
.logo { font-size: 20px; font-weight: 700; color: #111827; }
.logo:hover { text-decoration: none; color: #2563eb; }
.main-nav { display: flex; gap: 24px; }
.main-nav a { color: #4b5563; font-size: 15px; }
.main-nav a:hover, .main-nav a.active { color: #2563eb; text-decoration: none; font-weight: 600; }

/* 主体 */
main.container { padding-top: 28px; padding-bottom: 40px; min-height: 60vh; }
.hero { background: linear-gradient(135deg, #2563eb, #1e40af); color: #fff; border-radius: 12px; padding: 36px 32px; margin-bottom: 28px; }
.hero h1 { font-size: 26px; margin-bottom: 10px; }
.hero p { color: #dbeafe; font-size: 15px; }
.section { margin-bottom: 32px; }
.section-title { font-size: 20px; color: #111827; margin-bottom: 16px; padding-left: 12px; border-left: 4px solid #2563eb; }
.page-title { font-size: 24px; color: #111827; margin-bottom: 18px; }
.breadcrumb { font-size: 13px; color: #9ca3af; margin-bottom: 16px; }
.breadcrumb a { color: #6b7280; }
.breadcrumb span { color: #374151; }

/* 栏目卡片 */
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cat-card { display: block; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 20px; transition: box-shadow .2s; }
.cat-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.08); text-decoration: none; }
.cat-card h3 { color: #111827; font-size: 17px; margin-bottom: 6px; }
.cat-card p { color: #6b7280; font-size: 14px; }

/* 文章列表 */
.article-list { list-style: none; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 6px 20px; }
.article-item { display: flex; align-items: baseline; gap: 16px; padding: 13px 0; border-bottom: 1px dashed #eef0f3; }
.article-item:last-child { border-bottom: none; }
.article-item a { color: #1f2937; font-size: 16px; }
.article-item a:hover { color: #2563eb; }
.article-date { color: #9ca3af; font-size: 13px; flex-shrink: 0; width: 92px; }
.article-excerpt { color: #6b7280; font-size: 14px; margin-top: 4px; }
.empty-tip { color: #9ca3af; padding: 24px 0; }

/* 文章详情 */
.article-detail { background: #fff; border: 1px solid #e5e7eb; border-radius: 12px; padding: 32px; }
.article-title { font-size: 26px; color: #111827; margin-bottom: 12px; }
.article-meta { color: #9ca3af; font-size: 13px; display: flex; gap: 18px; padding-bottom: 16px; border-bottom: 1px solid #eef0f3; margin-bottom: 20px; }
.article-content { font-size: 16px; }
.article-content h2 { font-size: 21px; color: #111827; margin: 26px 0 12px; }
.article-content h3 { font-size: 18px; color: #1f2937; margin: 20px 0 10px; }
.article-content p { margin-bottom: 14px; }
.article-content ul, .article-content ol { margin: 0 0 14px 22px; }
.article-content img { max-width: 100%; height: auto; border-radius: 8px; }

/* 分页（前台） */
.pagination { list-style: none; display: flex; gap: 8px; margin-top: 24px; justify-content: center; }
.pagination li a, .pagination li span { display: inline-block; padding: 6px 12px; background: #fff; border: 1px solid #e5e7eb; border-radius: 6px; color: #374151; font-size: 14px; }
.pagination li.active span { background: #2563eb; border-color: #2563eb; color: #fff; }
.pagination li a:hover { border-color: #2563eb; color: #2563eb; text-decoration: none; }

/* 页脚 */
.site-footer { background: #111827; color: #9ca3af; padding: 24px 0; text-align: center; font-size: 14px; }
.site-footer a { color: #9ca3af; }
.site-footer a:hover { color: #fff; }

/* 响应式 */
@media (max-width: 768px) {
    .header-inner { flex-direction: column; height: auto; padding: 12px 0; gap: 10px; }
    .cat-grid { grid-template-columns: 1fr; }
    .article-item { flex-direction: column; gap: 4px; }
    .article-date { width: auto; }
}
