/* ============================================================
   模板：论坛（独立模板 · 经典 BBS）
   布局：深蓝导航 + 板块快捷条 + 公告条 / 板块表格 + 话题表格 + 右侧栏
   ============================================================ */
body.theme-forum {
  --p: #1d4ed8;
  --p-dark: #1e3a8a;
  --p-light: #dbeafe;
  --ink: #1e293b;
  --muted: #64748b;
  --line: #d7e0ec;
  --bg: #eff3f8;
  --card: #ffffff;
  --radius: 8px;
}

body.theme-forum .ft-wrap { max-width: 1160px; margin: 0 auto; padding: 0 18px; }

/* ---------- 深蓝导航 ---------- */
body.theme-forum .ft-header { position: sticky; top: 0; z-index: 30; box-shadow: 0 2px 12px rgba(15, 23, 42, 0.18); }
body.theme-forum .ft-bar {
  background: #1e3a8a; display: flex; align-items: center; gap: 16px;
  padding: 0 0 0 4px; height: 54px;
}
body.theme-forum .ft-logo {
  display: flex; align-items: center; gap: 9px; color: #fff;
  font-size: 19px; font-weight: 700; text-decoration: none; letter-spacing: 1px;
}
body.theme-forum .ft-logo img { width: 30px; height: 30px; border-radius: 6px; }
body.theme-forum .ft-logo em {
  font-style: normal; font-size: 11px; background: #f59e0b; color: #1e3a8a;
  padding: 2px 8px; border-radius: 3px; letter-spacing: 3px;
}
body.theme-forum .ft-nav { display: flex; gap: 2px; }
body.theme-forum .ft-nav a { color: #bfdbfe; text-decoration: none; font-size: 13.5px; padding: 6px 10px; border-radius: 6px; }
body.theme-forum .ft-nav a:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }
body.theme-forum .ft-search { display: flex; margin-left: auto; }
body.theme-forum .ft-search input {
  background: rgba(255, 255, 255, 0.15); border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff; padding: 6px 12px; border-radius: 6px 0 0 6px; width: 170px; font-size: 13px;
}
body.theme-forum .ft-search input::placeholder { color: #bfdbfe; }
body.theme-forum .ft-search input:focus { outline: none; background: #fff; color: #1e293b; }
body.theme-forum .ft-search button {
  border: none; background: #f59e0b; color: #1e3a8a; font-weight: 700;
  padding: 0 12px; border-radius: 0 6px 6px 0; cursor: pointer;
}
body.theme-forum .ft-admin { color: #fbbf24; text-decoration: none; font-size: 13px; white-space: nowrap; }
body.theme-forum .ft-login {
  background: #fff; color: #1e3a8a; border: none; font-weight: 700; font-size: 13px;
  padding: 7px 14px; border-radius: 6px; cursor: pointer; white-space: nowrap;
}
body.theme-forum .ft-login:hover { background: #fde68a; }
body.theme-forum #p-user-chip b { color: #fff; }
body.theme-forum #p-user-chip .p-logout { color: #bfdbfe; }

/* ---------- 板块快捷条 + 公告 ---------- */
body.theme-forum .ft-catbar { background: #1e40af; display: flex; gap: 2px; overflow-x: auto; }
body.theme-forum .ft-catbar a {
  color: #dbeafe; font-size: 12.5px; text-decoration: none; padding: 8px 12px; white-space: nowrap;
}
body.theme-forum .ft-catbar a:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
body.theme-forum .ft-notice {
  background: #fef3c7; border-bottom: 1px solid #fde68a;
  display: flex; align-items: center; gap: 10px; padding: 7px 18px; font-size: 13px;
}
body.theme-forum .ft-notice-tag {
  background: #e11d48; color: #fff; font-size: 11px; font-weight: 700;
  padding: 2px 8px; border-radius: 3px; flex-shrink: 0;
}
body.theme-forum .ft-notice a { color: #92400e; text-decoration: none; }
body.theme-forum .ft-notice a:hover { text-decoration: underline; }

body.theme-forum .ft-main { background: var(--bg); padding: 20px 0 50px; min-height: 60vh; }
body.theme-forum .ft-crumb { color: var(--muted); font-size: 13px; margin-bottom: 14px; }
body.theme-forum .ft-crumb a { color: #1d4ed8; text-decoration: none; }

/* ---------- 双栏 ---------- */
body.theme-forum .ft-cols { display: grid; grid-template-columns: 1fr 290px; gap: 16px; }
body.theme-forum .ft-section-head {
  display: flex; justify-content: space-between; align-items: center;
  margin: 4px 0 10px;
}
body.theme-forum .ft-section-head h2 { font-size: 17px; color: var(--ink); }
body.theme-forum .ft-more { color: #1d4ed8; text-decoration: none; font-size: 13px; }

/* ---------- 板块表格 ---------- */
body.theme-forum .ft-board-table, body.theme-forum .ft-thread-table {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; margin-bottom: 18px;
}
body.theme-forum .ft-table-head {
  display: grid; grid-template-columns: 1fr 70px 70px 150px;
  background: #1e3a8a; color: #fff; font-size: 12.5px;
  padding: 8px 16px; gap: 8px;
}
body.theme-forum .ft-thread-table .ft-table-head { grid-template-columns: 1fr 90px 90px 100px; }
body.theme-forum .ft-board-row {
  display: grid; grid-template-columns: 1fr 70px 70px 150px;
  gap: 8px; padding: 13px 16px; border-bottom: 1px solid #e8eef6;
  text-decoration: none; align-items: center; transition: background .12s;
}
body.theme-forum .ft-board-row:hover { background: #eff6ff; }
body.theme-forum .ft-board-cell { display: flex; gap: 12px; align-items: center; min-width: 0; }
body.theme-forum .ft-board-icon {
  width: 42px; height: 42px; border-radius: 8px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 22px;
}
body.theme-forum .ft-board-cell b { display: block; color: var(--ink); font-size: 14.5px; }
body.theme-forum .ft-board-cell em { font-style: normal; color: #94a3b8; font-size: 12px; }
body.theme-forum .ft-num { text-align: center; color: #1d4ed8; font-weight: 700; font-size: 14px; }
body.theme-forum .ft-last { color: var(--muted); font-size: 12.5px; overflow: hidden; white-space: nowrap; }
body.theme-forum .ft-last em { font-style: normal; color: #cbd5e1; }

/* ---------- 话题表格 ---------- */
body.theme-forum .ft-thread-row {
  display: grid; grid-template-columns: 1fr 90px 90px 100px;
  gap: 8px; padding: 11px 16px; border-bottom: 1px solid #e8eef6;
  text-decoration: none; align-items: center; transition: background .12s;
}
body.theme-forum .ft-thread-row:hover { background: #eff6ff; }
body.theme-forum .ft-thread-cell { display: flex; gap: 10px; align-items: center; min-width: 0; }
body.theme-forum .ft-ava { width: 34px; height: 34px; font-size: 13px; flex-shrink: 0; }
body.theme-forum .ft-thread-info b { color: var(--ink); font-size: 14px; font-weight: 500; display: block; }
body.theme-forum .ft-thread-row:hover .ft-thread-info b { color: #1d4ed8; }
body.theme-forum .ft-pin {
  font-style: normal; background: #e11d48; color: #fff; font-size: 10px;
  padding: 1px 6px; border-radius: 3px; margin-right: 6px; font-weight: 700;
}
body.theme-forum .ft-thread-info i {
  font-style: normal; color: #fff; font-size: 10.5px; padding: 1px 7px;
  border-radius: 3px; margin-top: 3px; display: inline-block;
}
body.theme-forum .ft-author { color: var(--muted); font-size: 12.5px; }
body.theme-forum .ft-counts { color: #94a3b8; font-size: 12.5px; text-align: center; }
body.theme-forum .ft-counts b { color: #1e3a8a; }
body.theme-forum .ft-act { color: #94a3b8; font-size: 12px; }
body.theme-forum .ft-empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* ---------- 右侧栏 ---------- */
body.theme-forum .ft-box {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 16px; margin-bottom: 14px;
}
body.theme-forum .ft-box h3 { font-size: 14.5px; color: var(--ink); margin-bottom: 10px; border-bottom: 2px solid #dbeafe; padding-bottom: 7px; }
body.theme-forum .ft-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
body.theme-forum .ft-stat {
  background: #eff6ff; border-radius: 6px; text-align: center; padding: 10px 4px;
}
body.theme-forum .ft-stat b { display: block; font-size: 20px; color: #1e3a8a; font-weight: 800; }
body.theme-forum .ft-stat span { font-size: 11.5px; color: #64748b; }
body.theme-forum .ft-hot-item { display: flex; gap: 9px; padding: 6px 0; text-decoration: none; }
body.theme-forum .ft-hot-item b { display: block; color: var(--ink); font-size: 13px; font-weight: 500; line-height: 1.45; }
body.theme-forum .ft-hot-item:hover b { color: #1d4ed8; }
body.theme-forum .ft-hot-item em { font-style: normal; color: #94a3b8; font-size: 11px; }
body.theme-forum .ft-rank {
  width: 18px; height: 18px; background: #e2e8f0; color: #64748b; border-radius: 3px;
  font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; margin-top: 2px;
}
body.theme-forum .ft-rank.top { background: #e11d48; color: #fff; }
body.theme-forum .ft-user { display: flex; align-items: center; gap: 10px; padding: 6px 0; }
body.theme-forum .ft-user b { display: block; color: var(--ink); font-size: 13px; }
body.theme-forum .ft-user em { font-style: normal; color: #94a3b8; font-size: 11.5px; }

/* ---------- 页脚 ---------- */
body.theme-forum .ft-footer {
  background: #172554; color: #93c5fd; padding: 20px 0;
  display: flex; flex-direction: column; gap: 4px; font-size: 13px;
}
body.theme-forum .ft-footer .ft-wrap { display: flex; justify-content: space-between; align-items: center; }
body.theme-forum .ft-footer a { color: #bfdbfe; text-decoration: none; margin-left: 14px; }
body.theme-forum .ft-footer a:hover { color: #fff; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  body.theme-forum .ft-cols { grid-template-columns: 1fr; }
  body.theme-forum .ft-board-row { grid-template-columns: 1fr 60px 60px; }
  body.theme-forum .ft-board-row .ft-last { display: none; }
  body.theme-forum .ft-table-head { grid-template-columns: 1fr 60px 60px; }
  body.theme-forum .ft-table-head span:last-child { display: none; }
  body.theme-forum .ft-thread-row { grid-template-columns: 1fr 70px; }
  body.theme-forum .ft-thread-row .ft-author, body.theme-forum .ft-thread-row .ft-act { display: none; }
  body.theme-forum .ft-thread-table .ft-table-head { grid-template-columns: 1fr 70px; }
  body.theme-forum .ft-thread-table .ft-table-head span:nth-child(2), body.theme-forum .ft-thread-table .ft-table-head span:last-child { display: none; }
  body.theme-forum .ft-search { display: none; }
}
