/* 门户首页样式（仅 front-page.php 使用） */
.fp-home { margin: 0; background: #f5f5f5; color: #333; font-family: "Microsoft YaHei", "PingFang SC", sans-serif; font-size: 14px; }
.fp-home a { text-decoration: none; color: #333; }
.fp-home a:hover { color: #d48806; }
.fp-home ul { margin: 0; padding: 0; list-style: none; }
.fp-home img { max-width: 100%; display: block; }
.fp-wrap { max-width: 1200px; margin: 0 auto; padding: 0 12px; }

/* 顶部 */
.fp-topbar { background: #f7f7f7; border-bottom: 1px solid #e8e8e8; color: #999; font-size: 12px; }
.fp-topbar .fp-wrap { display: flex; justify-content: space-between; padding-top: 5px; padding-bottom: 5px; }
.fp-brandbar { background: #fff; }
.fp-brandbar .fp-wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; }
.fp-logo a { font-size: 36px; font-weight: 700; color: #d48806; letter-spacing: 5px; font-family: "SimHei", "Microsoft YaHei", sans-serif; }
.fp-logo span { margin-left: 12px; color: #aaa; font-size: 13px; letter-spacing: 1px; }
.fp-search { display: flex; }
.fp-search input { width: 220px; padding: 8px 10px; border: 1px solid #ddd; font-size: 13px; border-radius: 3px 0 0 3px; outline: none; }
.fp-search input:focus { border-color: #d48806; }
.fp-search button { padding: 8px 18px; border: 0; background: #d48806; color: #fff; cursor: pointer; font-size: 13px; border-radius: 0 3px 3px 0; }
.fp-search button:hover { background: #b96e00; }

/* 导航 */
.fp-mainnav { background: #e69a00; }
.fp-mainnav ul { display: flex; flex-wrap: wrap; }
.fp-mainnav a { display: block; color: #fff; padding: 12px 22px; font-size: 15px; }
.fp-mainnav a:hover, .fp-mainnav a.cur { background: #c98200; color: #fff; }
.fp-subnav { background: #f2f2f2; border-bottom: 1px solid #e5e5e5; font-size: 12px; color: #888; }
.fp-subnav .fp-wrap { padding-top: 7px; padding-bottom: 7px; }
.fp-subnav a { color: #777; margin-right: 16px; }
.fp-subnav a:hover { color: #d48806; }
.fp-subnav .lab { margin-right: 4px; }
.fp-subnav .sep { margin-right: 16px; color: #ddd; }

/* 三栏布局 */
.fp-main { padding-top: 14px; }
.fp-grid { display: grid; grid-template-columns: 200px 1fr 300px; gap: 14px; align-items: start; }
.fp-left, .fp-right { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.fp-panel { background: #fff; border: 1px solid #ececec; padding: 12px 14px; }
.fp-ptitle { margin: 0 0 10px; padding-bottom: 8px; border-bottom: 2px solid #e69a00; font-size: 16px; color: #d48806; display: flex; justify-content: space-between; align-items: baseline; }
.fp-ptitle a { color: #d48806; }
.fp-ptitle .more { font-size: 12px; color: #aaa; font-weight: 400; }
.fp-ptitle .more:hover { color: #d48806; }

/* 列表 */
.fp-list li { padding: 7px 0; border-bottom: 1px dashed #eee; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; }
.fp-list li:last-child { border-bottom: 0; }
.fp-list li a { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fp-list li a::before { content: "·"; color: #e69a00; margin-right: 6px; font-weight: 700; }
.fp-list li.hl a { color: #d48806; font-weight: 700; }
.fp-list .empty, .empty { color: #bbb; }

/* 头条 */
.fp-headline { border-bottom: 1px solid #f0f0f0; margin-bottom: 8px; padding-bottom: 12px; }
.fp-headline h1 { margin: 0 0 8px; font-size: 23px; line-height: 1.5; }
.fp-headline h1 a { color: #1a4b8c; }
.fp-headline h1 a:hover { color: #d48806; }
.fp-headline p { margin: 0; color: #888; font-size: 13px; line-height: 1.8; }
.fp-center-list { columns: 1; }

/* 轮播 */
.fp-slider-panel { padding: 0; overflow: hidden; }
.fp-slider { position: relative; height: 210px; }
.fp-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .6s; pointer-events: none; }
.fp-slide.on { opacity: 1; pointer-events: auto; }
.fp-slide img { width: 100%; height: 100%; object-fit: cover; }
.fp-slide .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px 10px; background: rgba(0,0,0,.55); color: #fff; font-size: 13px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fp-dots { position: absolute; right: 10px; bottom: 34px; display: flex; gap: 5px; }
.fp-dots button { width: 10px; height: 10px; border-radius: 50%; border: 0; background: rgba(255,255,255,.55); cursor: pointer; padding: 0; }
.fp-dots button.on { background: #e69a00; }

/* 图片频道 */
.fp-channel { margin-top: 14px; }
.fp-channel-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.fp-channel-item img { width: 100%; height: 150px; object-fit: cover; }
.fp-channel-item span { display: block; padding-top: 6px; font-size: 13px; color: #666; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.fp-channel-item:hover span { color: #d48806; }

/* 底部三栏 */
.fp-bottom { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 14px; margin-bottom: 16px; }

/* 页脚 */
.fp-footer { background: #fff; border-top: 1px solid #ececec; color: #999; font-size: 12px; padding: 16px 0; text-align: center; }
.fp-footer a { color: #999; }
.fp-footer a:hover { color: #d48806; }
.fp-footer-links { margin-left: 12px; }

/* 响应式 */
@media (max-width: 1000px) {
    .fp-grid { grid-template-columns: 1fr; }
    .fp-channel-grid { grid-template-columns: repeat(2, 1fr); }
    .fp-bottom { grid-template-columns: 1fr; }
    .fp-logo a { font-size: 26px; letter-spacing: 2px; }
    .fp-logo span { display: none; }
    .fp-search input { width: 130px; }
    .fp-mainnav a { padding: 10px 14px; font-size: 14px; }
    .fp-slider { height: 200px; }
}


/* 首页兼容修正：避免网格撑宽，并隐藏公共页脚在首页的重复模块 */
.fp-home * { box-sizing: border-box; }
.fp-home > .latest-posts,
.fp-home > .latest-posts + div { display: none !important; }
.fp-grid { grid-template-columns: 200px minmax(0, 1fr) 300px; }
.fp-grid > *, .fp-bottom > *, .fp-channel-item { min-width: 0; }
.fp-channel-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.fp-bottom { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1000px) {
    .fp-grid { grid-template-columns: minmax(0, 1fr); }
    .fp-channel-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .fp-bottom { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 480px) {
    .fp-brandbar .fp-wrap { gap: 8px; }
    .fp-logo a { font-size: 24px; }
    .fp-search input { width: 100px; }
    .fp-mainnav a { padding: 10px 12px; }
}
