/* =====================================================
   钢板销售员 · 信息发布站
   风格参考：金陵钢宝网 —— 红 #e11826 / 深藏青 #0d2135 / 浅灰 #f8f9fb
   ===================================================== */
:root {
  --red:   #e11826;
  --red-d: #c4121e;
  --navy:  #0d2135;
  --navy-2:#132c44;
  --bg:    #f8f9fb;
  --line:  #e8e8e8;
  --gray:  #6d797f;
  --gray-l:#909399;
  --green: #67c23a;
  --orange:#e6a23c;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", Arial, sans-serif;
  background: var(--bg);
  color: #303133;
  font-size: 15px;
  line-height: 1.6;
}
a { color: inherit; text-decoration: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ============ 公告条（红） ============ */
.notice-bar {
  background: linear-gradient(90deg, var(--red-d), var(--red));
  color: #fff;
  font-size: 13px;
}
.notice-bar.slim { background: var(--navy); }
.notice-inner {
  display: flex; align-items: center; gap: 10px;
  min-height: 36px; padding-top: 4px; padding-bottom: 4px;
  overflow: hidden;
}
.notice-tag {
  flex: none; background: #fff; color: var(--red);
  font-weight: 700; padding: 1px 8px; border-radius: 2px;
  letter-spacing: 2px;
}
.notice-bar.slim .notice-tag { color: var(--navy); }
.notice-list { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; }
.notice-item { color: #fff; opacity: .95; }
.notice-item:hover { opacity: 1; text-decoration: underline; }
.notice-sep { opacity: .45; }
.notice-date { flex: none; opacity: .85; font-size: 12px; }

/* ============ 主导航（深藏青） ============ */
.top-header { background: var(--navy); }
.header-inner {
  display: flex; align-items: center; gap: 24px;
  min-height: 60px; flex-wrap: wrap; padding-top: 6px; padding-bottom: 6px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 6px;
  background: var(--red); color: #fff;
  font-weight: 800; font-size: 17px; letter-spacing: 1px;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.25);
}
.logo-text { color: #fff; font-size: 19px; font-weight: 700; line-height: 1.15; display: flex; flex-direction: column; }
.logo-text small { font-size: 10px; letter-spacing: 3px; opacity: .55; font-weight: 400; }
.main-nav { display: flex; flex-wrap: wrap; gap: 2px; margin-left: auto; }
.main-nav a {
  color: rgba(255,255,255,.85); padding: 8px 14px; border-radius: 4px;
  font-size: 14.5px; transition: background .15s, color .15s;
}
.main-nav a:hover { color: #fff; background: rgba(255,255,255,.08); }
.main-nav a.on { color: #fff; background: var(--red); font-weight: 600; }
/* 汉堡按钮：桌面端隐藏，移动端显示 */
.nav-toggle { display: none; }

/* ============ 数据概览 ============ */
.stat-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
  margin: 18px 0 20px;
}
.stat-card {
  background: #fff; border-radius: 8px; border: 1px solid var(--line);
  padding: 14px 18px; display: flex; flex-direction: column;
}
.stat-card b { color: var(--red); font-size: 26px; line-height: 1.2; }
.stat-card span { color: var(--gray); font-size: 12.5px; margin-top: 2px; }

/* ============ 频道标题 ============ */
.cat-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  margin-bottom: 12px;
}
.cat-title { display: flex; align-items: baseline; gap: 10px; }
.cat-title i { width: 5px; height: 22px; background: var(--red); border-radius: 2px; align-self: center; }
.cat-title h1 { font-size: 22px; color: var(--navy); }
.cat-title em { font-style: normal; color: var(--gray-l); font-size: 12px; letter-spacing: 2px; text-transform: uppercase; }
.cat-count { color: var(--gray); font-size: 13px; }
.cat-count b { color: var(--red); }

/* ============ 信息列表卡 ============ */
.list-card {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  overflow: hidden;
}
.list-row {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 16px; border-bottom: 1px solid #f0f0f0;
  border-left: 3px solid transparent;
  transition: background .12s, border-color .12s;
}
.list-row:last-child { border-bottom: none; }
.list-row:hover { background: #fff5f5; border-left-color: var(--red); }
.row-no {
  flex: none; width: 24px; height: 24px; border-radius: 4px;
  background: #f0f2f5; color: var(--gray-l);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 12.5px; font-weight: 700;
}
.row-no.hot { background: var(--red); color: #fff; }
.row-main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 0; }
.row-main .row-title { flex: 1; min-width: 0; }

.row-title {
  color: #303133; font-size: 15px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  display: block;
}
.row-title:hover { color: var(--red); }
.row-meta { flex: none; display: flex; gap: 14px; color: var(--gray-l); font-size: 12.5px; }
.empty { padding: 48px 16px; text-align: center; color: var(--gray-l); }

/* ============ 分页 ============ */
.pager { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin: 18px 0 30px; }
.pager a, .pager .cur, .pager .dots {
  min-width: 34px; height: 34px; padding: 0 10px;
  display: inline-flex; align-items: center; justify-content: center;
  background: #fff; border: 1px solid var(--line); border-radius: 4px;
  font-size: 13.5px; color: #606266;
}
.pager a:hover { color: var(--red); border-color: var(--red); }
.pager .cur { background: var(--red); border-color: var(--red); color: #fff; font-weight: 600; }
.pager .dots { border: none; background: none; }

/* ============ 页脚 ============ */
.site-footer { background: var(--navy); color: rgba(255,255,255,.75); margin-top: 26px; }
.footer-inner { padding: 26px 16px 24px; }
.footer-brand { font-size: 17px; font-weight: 700; color: #fff; }
.footer-brand span { font-size: 10px; letter-spacing: 3px; opacity: .5; font-weight: 400; margin-left: 8px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 12px 0 10px; font-size: 13px; }
.footer-links a:hover { color: #fff; text-decoration: underline; }
.footer-copy { font-size: 12.5px; opacity: .55; }

/* ============ 登录页 ============ */
.login-body {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--navy) 0%, #1a3a5c 60%, #274b73 100%);
}
.login-box {
  width: 360px; max-width: calc(100vw - 32px);
  background: #fff; border-radius: 10px; padding: 34px 32px 26px;
  box-shadow: 0 18px 44px rgba(0,0,0,.28);
}
.login-head { text-align: center; margin-bottom: 20px; }
.login-head .logo-badge { width: 44px; height: 44px; font-size: 19px; }
.login-head h1 { font-size: 19px; color: var(--navy); margin-top: 10px; }
.login-head p { color: var(--gray-l); font-size: 12.5px; margin-top: 2px; }
.login-box label { display: block; color: var(--gray); font-size: 13px; margin-bottom: 14px; }
.login-box input {
  width: 100%; margin-top: 5px; height: 42px; padding: 0 12px;
  border: 1px solid #dcdfe6; border-radius: 5px; font-size: 14.5px; outline: none;
}
.login-box input:focus { border-color: var(--red); box-shadow: 0 0 0 2px rgba(225,24,38,.12); }
.btn-main {
  width: 100%; height: 44px; border: none; border-radius: 5px;
  background: var(--red); color: #fff; font-size: 15.5px; font-weight: 700;
  cursor: pointer; letter-spacing: 4px; transition: background .15s;
}
.btn-main:hover { background: var(--red-d); }
.login-back { display: block; text-align: center; margin-top: 14px; color: var(--gray-l); font-size: 13px; }
.login-back:hover { color: var(--red); }

/* ============ 提示条 ============ */
.alert { padding: 10px 14px; border-radius: 5px; font-size: 13.5px; margin-bottom: 14px; }
.alert.ok   { background: #f0f9eb; color: var(--green); border: 1px solid #e1f3d8; }
.alert.err  { background: #fef0f0; color: var(--red); border: 1px solid #fde2e2; }
.alert.warn { background: #fdf6ec; color: var(--orange); border: 1px solid #faecd8; }

/* ============ 附件类型小标签 ============ */
.att-tag {
  display: inline-block; font-style: normal; font-size: 11px;
  padding: 0 6px; margin-left: 4px; border-radius: 3px; vertical-align: 1px;
  white-space: nowrap;
}
.att-image { background: #ecf5ff; color: #409eff; }
.att-video { background: #f0f9eb; color: var(--green); }
.att-doc   { background: #fce6e6; color: var(--red); }
.att-sheet { background: #fdf6ec; color: var(--orange); }
.row-atts { display: block; margin-top: 2px; }

/* ============ 后台：每页条数切换 ============ */
.per-page {
  display: flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--gray); margin-bottom: 12px;
}
.per-page a {
  min-width: 30px; height: 26px; padding: 0 8px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 4px; background: #fff;
  color: #606266; font-size: 12.5px;
}
.per-page a:hover { border-color: var(--red); color: var(--red); }
.per-page a.on { background: var(--red); border-color: var(--red); color: #fff; font-weight: 600; }
.ar-detail-link { color: #409eff; margin-left: 4px; }
.ar-detail-link:hover { text-decoration: underline; }

/* ============ 后台：正文与上传控件 ============ */
.post-form textarea {
  width: 100%; margin-top: 5px; padding: 10px 12px;
  border: 1px solid #dcdfe6; border-radius: 5px; font-size: 14px;
  font-family: inherit; line-height: 1.7; resize: vertical; outline: none; background: #fff;
}
.post-form textarea:focus { border-color: var(--red); box-shadow: 0 0 0 2px rgba(225,24,38,.12); }
.file-input {
  height: auto !important; padding: 8px 10px !important; cursor: pointer;
}
.file-hint { display: block; margin-top: 6px; font-size: 12px; color: var(--gray-l); }

/* ============ 前台：详情页 ============ */
.detail-wrap { padding: 20px 16px 40px; }
.detail-card {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 26px 28px;
}
.detail-title { font-size: 22px; color: var(--navy); line-height: 1.45; }
.detail-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  margin: 12px 0 18px; padding-bottom: 14px; border-bottom: 1px solid #f0f0f0;
  color: var(--gray-l); font-size: 13px;
}
.detail-content {
  font-size: 15px; line-height: 1.9; color: #303133;
  margin-bottom: 8px; white-space: pre-wrap; word-break: break-word;
}
.detail-sec {
  font-size: 16px; color: var(--navy); margin: 22px 0 12px;
  padding-left: 10px; border-left: 4px solid var(--red); line-height: 1.3;
}
.detail-imgs { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.detail-imgs img {
  width: 100%; height: 190px; object-fit: cover; border-radius: 6px;
  border: 1px solid var(--line); display: block; transition: transform .15s;
}
.detail-imgs a:hover img { transform: scale(1.02); }
.detail-vids video {
  width: 100%; max-width: 760px; border-radius: 6px; background: #000; display: block;
}
.video-name { color: var(--gray-l); font-size: 12.5px; margin: 6px 0 12px; }
.detail-docs { display: flex; flex-direction: column; gap: 8px; }
.doc-item {
  display: flex; align-items: center; gap: 12px;
  border: 1px solid var(--line); border-radius: 6px; padding: 10px 14px;
  transition: border-color .15s, background .15s;
}
.doc-item:hover { border-color: var(--red); background: #fff5f5; }
.doc-ic {
  flex: none; width: 44px; height: 34px; border-radius: 4px;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-size: 11px; font-weight: 800; letter-spacing: 1px;
}
.ic-doc { background: #409eff; }
.ic-xls { background: var(--green); }
.doc-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #303133; font-size: 14px; }
.doc-size { flex: none; color: var(--gray-l); font-size: 12.5px; }
.doc-dl { flex: none; color: var(--red); font-size: 13px; font-weight: 600; }
.detail-link { color: #409eff; font-size: 14px; word-break: break-all; }
.detail-link:hover { text-decoration: underline; }

/* ============ 富文本正文样式 ============ */
.detail-content.rich { white-space: normal; }
.detail-content.rich img { max-width: 100%; height: auto; border-radius: 6px; margin: 8px 0; }
.detail-content.rich p { margin: 0 0 12px; }
.detail-content.rich h1, .detail-content.rich h2, .detail-content.rich h3 {
  color: var(--navy); margin: 18px 0 10px; line-height: 1.4;
}
.detail-content.rich h1 { font-size: 20px; }
.detail-content.rich h2 { font-size: 18px; }
.detail-content.rich h3 { font-size: 16px; }
.detail-content.rich ul, .detail-content.rich ol { padding-left: 24px; margin: 0 0 12px; }
.detail-content.rich blockquote {
  margin: 0 0 12px; padding: 8px 14px; border-left: 4px solid var(--red);
  background: #fff5f5; color: var(--gray);
}
.detail-content.rich table { border-collapse: collapse; width: 100%; margin: 0 0 12px; }
.detail-content.rich td, .detail-content.rich th {
  border: 1px solid var(--line); padding: 6px 10px; font-size: 14px;
}
.detail-content.rich th { background: #f8f9fb; color: var(--navy); }
.detail-content.rich a { color: #409eff; }
.detail-content.rich a:hover { text-decoration: underline; }

/* ============ 后台：编辑器 ============ */
.editor-box {
  margin: 5px 0 16px; border: 1px solid #dcdfe6; border-radius: 5px;
  overflow: hidden; background: #fff;
}
.editor-box:focus-within { border-color: var(--red); box-shadow: 0 0 0 2px rgba(225,24,38,.12); }
.editor-box #editor-toolbar {
  border-bottom: 1px solid var(--line); background: #fafcfe;
}
.editor-box #editor-toolbar .w-e-toolbar { background: #fafcfe !important; }
.editor-box #editor {
  height: 320px; overflow-y: auto;
}
.editor-box .w-e-text-container { background: #fff !important; }

/* ============ 详情页：本分类最近发布（4行2列） ============ */
.related-block { margin-top: 22px; }
.cat-more { color: var(--gray); font-size: 13px; }
.cat-more:hover { color: var(--red); }
.related-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px;
}
.related-card {
  display: flex; flex-direction: column; gap: 4px;
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 13px 16px; border-left: 3px solid transparent;
  transition: background .12s, border-color .12s;
}
.related-card:hover { background: #fff5f5; border-left-color: var(--red); }
.rc-title {
  color: #303133; font-size: 14.5px; font-weight: 600; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.related-card:hover .rc-title { color: var(--red); }
.rc-meta { color: var(--gray-l); font-size: 12.5px; }

@media (max-width: 768px) {
  .related-grid { grid-template-columns: 1fr; }
  .editor-box #editor { height: 260px; }
}

/* ============ 后台 ============ */
.admin-wrap { padding: 20px 16px 40px; }
.admin-card {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 20px 22px; margin-bottom: 18px;
}
.card-title { font-size: 16.5px; color: var(--navy); display: flex; align-items: center; gap: 9px; margin-bottom: 16px; }
.card-title i { width: 5px; height: 18px; background: var(--red); border-radius: 2px; }
.card-title em { font-style: normal; font-size: 12.5px; color: var(--gray-l); font-weight: 400; margin-left: 4px; }
.post-form label { display: block; color: var(--gray); font-size: 13px; margin-bottom: 12px; }
.post-form input, .post-form select {
  width: 100%; margin-top: 5px; height: 40px; padding: 0 12px;
  border: 1px solid #dcdfe6; border-radius: 5px; font-size: 14.5px; outline: none;
  background: #fff;
}
.post-form input:focus, .post-form select:focus { border-color: var(--red); box-shadow: 0 0 0 2px rgba(225,24,38,.12); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.form-grid label.full { grid-column: 1 / -1; }
.post-form .btn-main { width: auto; min-width: 160px; letter-spacing: 2px; margin-top: 4px; }
.admin-list { display: flex; flex-direction: column; }
.admin-row {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 4px; border-bottom: 1px solid #f0f0f0;
}
.admin-row:last-child { border-bottom: none; }
.ar-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.ar-cat {
  align-self: flex-start; background: #fce6e6; color: var(--red);
  font-size: 11.5px; padding: 1px 7px; border-radius: 3px; margin-bottom: 3px;
}
.ar-title { font-size: 14.5px; color: #303133; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ar-meta { font-size: 12px; color: var(--gray-l); }
.admin-row.demo .ar-title { opacity: .8; }
.ar-del { flex: none; }
.btn-del {
  height: 30px; padding: 0 14px; border: 1px solid #fde2e2; border-radius: 4px;
  background: #fff; color: var(--red); font-size: 13px; cursor: pointer;
  transition: all .15s;
}
.btn-del:hover { background: var(--red); border-color: var(--red); color: #fff; }
.admin-back { display: inline-block; color: var(--gray-l); font-size: 13.5px; }
.admin-back:hover { color: var(--red); }

/* ============ 移动端 ============ */
@media (max-width: 768px) {
  .header-inner { gap: 10px; }
  /* 移动端：导航默认收起，点汉堡展开为竖排列表 */
  .nav-toggle {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    margin-left: auto; width: 42px; height: 34px; padding: 0 9px;
    background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.2);
    border-radius: 6px; cursor: pointer;
  }
  .nav-toggle span {
    display: block; width: 100%; height: 2px; background: #fff;
    border-radius: 2px; transition: transform .2s ease, opacity .15s ease;
  }
  .nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .main-nav {
    display: none; width: 100%; margin-left: 0;
    flex-direction: column; flex-wrap: nowrap; gap: 0;
    padding: 6px 0 2px; border-top: 1px solid rgba(255,255,255,.1); margin-top: 4px;
  }
  .nav-open .main-nav { display: flex; }
  .main-nav a { padding: 11px 12px; font-size: 14px; border-radius: 6px; white-space: normal; }
  .stat-row { grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 12px; }
  .stat-card { padding: 10px 14px; }
  .stat-card b { font-size: 21px; }
  .cat-title h1 { font-size: 18px; }
  .list-row { padding: 11px 10px; gap: 8px; flex-wrap: wrap; }
  .row-title { white-space: normal; font-size: 14px; }
  .row-meta { width: 100%; padding-left: 32px; }
  .notice-list { gap: 6px; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-links { gap: 4px 14px; }
}

/* ============ 二级分类（钢厂维度） ============ */
/* 前台筛选栏 */
.sub-bar {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 10px 14px; margin-bottom: 14px;
}
.sub-bar-tag {
  font-size: 12.5px; color: var(--gray-l); margin-right: 4px;
  padding-left: 8px; border-left: 3px solid var(--red); line-height: 1.2;
}
.sub-chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 12px; border-radius: 999px; font-size: 13.5px;
  background: #f2f4f7; color: #444; border: 1px solid transparent;
  transition: all .15s;
}
.sub-chip b { font-size: 12px; color: var(--gray-l); font-weight: 600; }
.sub-chip:hover { color: var(--red); background: #fdf1f2; }
.sub-chip.on { background: var(--red); color: #fff; }
.sub-chip.on b { color: rgba(255,255,255,.85); }

/* 列表条目钢厂标签 */
.row-sub {
  flex-shrink: 0; font-size: 12px; color: var(--navy);
  background: #eef2f6; border-radius: 3px; padding: 1px 7px;
  margin-right: 8px; white-space: nowrap;
}

/* 后台 */
.ar-sub {
  display: inline-block; font-size: 12px; color: var(--navy);
  background: #eef2f6; border-radius: 3px; padding: 0 6px;
  margin-right: 6px; vertical-align: 1px;
}
.sub-label select { min-width: 180px; }
.sub-add-form { display: flex; gap: 10px; margin-bottom: 14px; }
.sub-add-form input[type="text"] {
  flex: 1; max-width: 360px; padding: 9px 12px; border: 1px solid #dcdfe6;
  border-radius: 5px; font-size: 14px; outline: none;
}
.sub-add-form input[type="text"]:focus { border-color: var(--red); }
.btn-sub-add { padding: 9px 22px; font-size: 14px; }
.sub-manage-list { display: flex; flex-wrap: wrap; gap: 8px; }
.sub-manage-list .sub-chip {
  font-size: 13.5px; padding: 5px 8px 5px 12px; background: #f2f4f7;
}
.sub-manage-list .sub-chip b {
  background: #fff; border-radius: 999px; padding: 0 7px;
}
.sub-manage-list .sub-chip form { display: inline; margin-left: 2px; }
.sub-manage-list .sub-chip button {
  border: none; background: transparent; color: var(--gray-l);
  font-size: 15px; cursor: pointer; padding: 0 4px; line-height: 1;
}
.sub-manage-list .sub-chip button:hover { color: var(--red); }
.sub-empty { font-size: 13.5px; color: var(--gray-l); }

@media (max-width: 720px) {
  .sub-bar { padding: 8px 10px; }
  .sub-add-form { flex-direction: column; }
  .sub-add-form input[type="text"] { max-width: none; }
}

/* ============ 企业名片 / 司机之家 ============ */
/* 导航额外频道（红色小圆点区分） */
.main-nav a.nav-extra::after {
  content: ''; display: inline-block; width: 5px; height: 5px;
  background: var(--red); border-radius: 50%; margin-left: 5px; vertical-align: 2px;
}
.main-nav a.nav-extra.on { background: var(--red); }
.main-nav a.nav-extra.on::after { background: #fff; }

/* 频道标题右侧发布按钮 */
.btn-publish {
  background: var(--red); color: #fff; font-size: 14px; font-weight: 600;
  padding: 9px 20px; border-radius: 5px; white-space: nowrap;
  box-shadow: 0 2px 8px rgba(225,24,38,.3); transition: all .15s;
}
.btn-publish:hover { background: var(--red-d); transform: translateY(-1px); }

/* 公开发布表单 */
.pub-form label { display: block; color: var(--gray); font-size: 13px; margin-bottom: 12px; }
.pub-form input {
  width: 100%; margin-top: 5px; height: 40px; padding: 0 12px;
  border: 1px solid #dcdfe6; border-radius: 5px; font-size: 14.5px; outline: none; background: #fff;
}
.pub-form input:focus { border-color: var(--red); box-shadow: 0 0 0 2px rgba(225,24,38,.12); }
.pub-form .btn-main { width: auto; min-width: 160px; letter-spacing: 2px; margin-top: 4px; }
.req { color: var(--red); margin-left: 3px; }
.addr-group { display: flex; gap: 8px; margin-top: 5px; }
.addr-group input { margin-top: 0 !important; }
.captcha-row { margin-top: 2px; }
.captcha-wrap { display: flex; align-items: center; gap: 10px; margin-top: 5px; }
.captcha-wrap input { flex: 1; min-width: 0; margin-top: 0 !important; letter-spacing: 3px; }
.captcha-img {
  height: 40px; width: 130px; object-fit: cover; border-radius: 5px; border: 1px solid var(--line);
  cursor: pointer; background: #fff; flex-shrink: 0; max-width: 46vw;
}
.pub-cancel { margin-left: 14px; color: var(--gray-l); font-size: 13.5px; }
.pub-cancel:hover { color: var(--red); }

/* 卡片墙（每行 4 张） */
.card-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
  margin-bottom: 20px;
}
.biz-card {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 16px 16px 12px; position: relative; overflow: hidden;
  transition: all .18s; display: flex; flex-direction: column;
}
.biz-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--red), var(--navy));
  transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.biz-card:hover { box-shadow: 0 6px 18px rgba(13,33,53,.12); transform: translateY(-2px); border-color: #d9dde3; }
.biz-card:hover::before { transform: scaleX(1); }
.bc-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); }
.bc-logo {
  width: 38px; height: 38px; flex-shrink: 0; border-radius: 7px;
  background: var(--navy); color: #fff; font-size: 19px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.bc-logo.truck { background: var(--red); }
.bc-company {
  font-size: 15.5px; font-weight: 700; color: var(--navy);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0;
}
.bc-row {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 13.5px; color: #4a5459; margin-bottom: 7px; line-height: 1.45;
}
.bc-ic {
  flex-shrink: 0; width: 17px; height: 17px; border-radius: 3px; margin-top: 1px;
  background: #eef2f6; color: var(--gray-l); font-size: 10.5px; font-style: normal;
  display: inline-flex; align-items: center; justify-content: center;
}
.bc-phone { color: var(--red); font-weight: 600; font-size: 14.5px; }
.bc-phone:hover { text-decoration: underline; }
.bc-brands span, .bc-route span {
  overflow: hidden; text-overflow: ellipsis; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.bc-route span { -webkit-line-clamp: 3; }
.bc-foot {
  margin-top: auto; padding-top: 8px; border-top: 1px dashed var(--line);
  font-size: 12px; color: var(--gray-l); text-align: right;
}

/* 后台名片/车辆管理列表 */
.btn-export {
  margin-left: auto; background: var(--navy); color: #fff;
  font-size: 13px; padding: 6px 14px; border-radius: 5px; white-space: nowrap;
}
.btn-export:hover { background: var(--navy-2); }
.pub-list { display: flex; flex-direction: column; }
.pub-row {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 4px; border-bottom: 1px solid #f0f1f3; font-size: 13.5px;
}
.pub-row:last-child { border-bottom: none; }
.pr-main { flex: 1; min-width: 0; color: #4a5459; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-main b { color: #303133; }
.pr-meta { color: var(--gray-l); font-size: 12.5px; flex-shrink: 0; }

@media (max-width: 1100px) { .card-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 860px)  { .card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .card-grid { grid-template-columns: 1fr; }
  .btn-publish { padding: 7px 14px; font-size: 13px; }
}

/* ============ 置顶 ============ */
/* 前台列表条目置顶标记 */
.row-pin {
  flex-shrink: 0; font-size: 12px; color: #fff;
  background: var(--red); border-radius: 3px; padding: 1px 7px;
  margin-right: 8px; white-space: nowrap; font-weight: 600;
}
/* 详情页 meta 置顶标记 */
.ar-pin {
  display: inline-block; background: var(--red); color: #fff;
  font-size: 12px; padding: 0 8px; border-radius: 3px; font-weight: 600;
}
/* 后台列表置顶标记 */
.admin-row .ar-pin { padding: 1px 7px; margin-bottom: 3px; align-self: flex-start; }
/* 后台置顶/取消按钮 */
.ar-pin-form { flex: none; margin-right: 8px; }
.btn-pin {
  height: 30px; padding: 0 14px; border: 1px solid #d9dde3; border-radius: 4px;
  background: #fff; color: var(--navy); font-size: 13px; cursor: pointer;
  transition: all .15s;
}
.btn-pin:hover { border-color: var(--navy); background: var(--navy); color: #fff; }
.btn-pin.on { border-color: var(--red); color: var(--red); background: #fce6e6; }
.btn-pin.on:hover { background: var(--red); border-color: var(--red); color: #fff; }

/* 名片/车辆管理列表的紧凑分页 */
.pager-mini { margin-top: 10px; padding-top: 10px; border-top: 1px dashed #e8eaee; }

/* 名片卡片置顶徽标 */
.bc-pin {
  flex-shrink: 0; align-self: flex-start; font-size: 11.5px; font-weight: 600;
  color: #fff; background: var(--red); border-radius: 3px; padding: 1px 7px;
}
/* 后台名片/车辆行的置顶按钮与标记垂直居中 */
.pub-row .ar-pin { align-self: center; }

/* ============ 详情页：面包屑 / 核心要点 / 常见问答（SEO·GEO） ============ */
.crumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  font-size: 12.5px; color: var(--gray-l); margin: 0 0 12px 2px;
}
.crumb a { color: var(--gray); }
.crumb a:hover { color: var(--red); }
.crumb span { color: #c8ccd4; }
.crumb em { font-style: normal; color: var(--gray-l); }

.seo-lead {
  background: #fbfcfe; border: 1px solid #e9eef6; border-left: 4px solid var(--red);
  border-radius: 6px; padding: 14px 18px 12px; margin: 0 0 20px;
}
.seo-lead-h {
  font-size: 13.5px; font-weight: 700; color: var(--navy);
  letter-spacing: .3px; margin-bottom: 8px;
}
.seo-lead ul { list-style: none; }
.seo-lead li {
  position: relative; padding-left: 16px; margin: 5px 0;
  font-size: 14px; line-height: 1.75; color: #3a4149;
}
.seo-lead li::before {
  content: ""; position: absolute; left: 2px; top: 9px;
  width: 5px; height: 5px; border-radius: 50%; background: var(--red);
}

.seo-faq { margin-top: 26px; padding-top: 4px; }
.seo-faq-list { border-top: 1px dashed #e8eaee; }
.seo-faq-list details { border-bottom: 1px dashed #e8eaee; }
.seo-faq-list summary {
  cursor: pointer; padding: 11px 2px 11px 22px; position: relative;
  font-size: 14.5px; color: var(--navy); font-weight: 600; list-style: none;
}
.seo-faq-list summary::-webkit-details-marker { display: none; }
.seo-faq-list summary::before {
  content: "Q"; position: absolute; left: 0; top: 11px;
  font-size: 12px; font-weight: 700; color: #fff; background: var(--red);
  width: 16px; height: 16px; line-height: 16px; text-align: center; border-radius: 3px;
}
.seo-faq-list summary::after {
  content: "+"; position: absolute; right: 4px; top: 9px;
  color: var(--gray-l); font-weight: 400; font-size: 16px;
}
.seo-faq-list details[open] summary::after { content: "−"; }
.seo-faq-a {
  padding: 2px 4px 14px 22px; font-size: 14px; line-height: 1.8; color: #4a5058;
}

/* ============ 后台：SEO 设置 ============ */
.pub-form textarea {
  width: 100%; margin-top: 5px; padding: 9px 12px; min-height: 62px;
  border: 1px solid #dcdfe6; border-radius: 5px; font-size: 14px; line-height: 1.7;
  font-family: inherit; outline: none; background: #fff; resize: vertical; color: #303133;
}
.pub-form textarea:focus { border-color: var(--red); box-shadow: 0 0 0 2px rgba(225,24,38,.12); }

.seo-box {
  border: 1px solid #e4e8ef; border-radius: 6px; background: #fafbfd;
  padding: 10px 14px; margin: 4px 0 14px;
}
.seo-box > summary {
  cursor: pointer; font-size: 13.5px; font-weight: 600; color: var(--navy); list-style: none;
}
.seo-box > summary::-webkit-details-marker { display: none; }
.seo-box > summary::before { content: "▸ "; color: var(--red); }
.seo-box[open] > summary::before { content: "▾ "; }
.seo-box > summary + label { margin-top: 12px; }

.btn-seo {
  flex-shrink: 0; font-size: 12px; color: var(--gray); border: 1px solid #dcdfe6;
  border-radius: 4px; padding: 4px 9px; line-height: 1; background: #fff;
}
.btn-seo:hover { color: var(--red); border-color: var(--red); background: #fff5f5; }

.seo-preview {
  border: 1px solid #eaeef4; border-radius: 6px; background: #fff;
  padding: 12px 14px; margin: 2px 0 14px; max-width: 640px;
}
.sp-title { font-size: 15px; color: #1a0dab; line-height: 1.5; }
.sp-desc { font-size: 13px; color: #4a5058; line-height: 1.7; margin: 3px 0; }
.sp-url { font-size: 12.5px; color: #0f9d58; word-break: break-all; }

/* ============ 关键词标签与聚合页 ============ */
.kw-tags, .kw-rel {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 18px 0 6px; padding: 12px 0; border-top: 1px dashed #eaedf2;
}
.kw-rel { border-top: none; border-bottom: 1px dashed #eaedf2; margin: 4px 0 22px; }
.kw-label {
  font-size: 12.5px; color: var(--gray-l); letter-spacing: .5px; flex-shrink: 0;
}
.kw-label::before { content: "#"; color: var(--red); margin-right: 3px; font-weight: 700; }
.kw {
  display: inline-block; font-size: 13px; color: #3b4a57;
  background: #f4f6fa; border: 1px solid #e4e9f0; border-radius: 14px;
  padding: 3px 12px; transition: all .15s;
}
.kw:hover { color: #fff; background: var(--red); border-color: var(--red); }

.row-cat {
  flex-shrink: 0; font-size: 12px; color: var(--red);
  background: #fff1f2; border: 1px solid #ffd9dc; border-radius: 3px;
  padding: 1px 7px; margin-right: 8px; white-space: nowrap;
}

.kw-cloud {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 14px 18px; margin-top: 18px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
}

/* ============ 后台：广告法合规检查 ============ */
.cmp-list { display: flex; flex-direction: column; gap: 6px; }
.cmp-row {
  display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap;
  padding: 8px 10px; border: 1px solid #f0f1f3; border-radius: 5px; background: #fbfcfd;
  font-size: 13px;
}
.cmp-t { flex: none; min-width: 240px; color: #303133; font-weight: 600; }
.cmp-w { flex: 1; display: flex; flex-wrap: wrap; gap: 6px; }
.cmp-tag {
  font-style: normal; font-size: 12px; border-radius: 3px; padding: 1px 7px;
  background: #f4f4f5; color: var(--gray);
}
.cmp-tag.bad  { background: #fef0f0; color: #c4121e; border: 1px solid #fbc4c4; }
.cmp-tag.warn { background: #fdf6ec; color: #b88230; border: 1px solid #f5dab1; }

/* =====================================================
   移动端加固（390–768px 手机视口实测适配）
   ===================================================== */

/* 富文本内容防溢出（任意终端生效）：表格横滚、代码换行、媒体不超宽 */
.detail-content.rich table {
  display: block; width: 100%; overflow-x: auto;
  border-collapse: collapse; margin: 10px 0; -webkit-overflow-scrolling: touch;
}
.detail-content.rich table td, .detail-content.rich table th {
  border: 1px solid #e5e7eb; padding: 6px 10px; font-size: 13.5px; white-space: nowrap;
}
.detail-content.rich pre {
  overflow-x: auto; white-space: pre; word-break: normal; tab-size: 4;
  background: #131a24; color: #e6edf3; border-radius: 8px;
  padding: 26px 14px 13px; font-size: 13px; margin: 14px 0; line-height: 1.65;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", "Courier New", monospace;
}
.detail-content.rich pre code {
  background: none; color: inherit; padding: 0; font-size: inherit; font-family: inherit;
  white-space: inherit;
}
/* 代码块语言标签（右上角小字） */
.detail-content.rich pre[class*="language-"] { position: relative; }
.detail-content.rich pre[class*="language-"]::before {
  position: absolute; top: 6px; right: 11px;
  font-size: 10.5px; letter-spacing: .5px; color: #7b8a9c;
  font-family: "Segoe UI", Arial, sans-serif; text-transform: uppercase;
}
.detail-content.rich pre.language-html::before  { content: "HTML"; }
.detail-content.rich pre.language-css::before   { content: "CSS"; }
.detail-content.rich pre.language-xml::before   { content: "XML"; }
.detail-content.rich pre.language-javascript::before { content: "JavaScript"; }
.detail-content.rich pre.language-typescript::before { content: "TypeScript"; }
.detail-content.rich pre.language-jsx::before   { content: "JSX"; }
.detail-content.rich pre.language-go::before    { content: "Go"; }
.detail-content.rich pre.language-php::before   { content: "PHP"; }
.detail-content.rich pre.language-c::before     { content: "C"; }
.detail-content.rich pre.language-cpp::before   { content: "C++"; }
.detail-content.rich pre.language-csharp::before { content: "C#"; }
.detail-content.rich pre.language-visual-basic::before { content: "VB"; }
.detail-content.rich pre.language-java::before  { content: "Java"; }
.detail-content.rich pre.language-python::before { content: "Python"; }
.detail-content.rich pre.language-sql::before   { content: "SQL"; }
.detail-content.rich pre.language-ruby::before  { content: "Ruby"; }
.detail-content.rich pre.language-swift::before { content: "Swift"; }
.detail-content.rich pre.language-bash::before  { content: "Bash"; }
.detail-content.rich pre.language-lua::before   { content: "Lua"; }
.detail-content.rich pre.language-groovy::before { content: "Groovy"; }
.detail-content.rich pre.language-markdown::before { content: "Markdown"; }
/* 正文中的行内代码 */
.detail-content.rich :not(pre) > code {
  background: #f2f4f7; color: #b8232f; border: 1px solid #e8ebef; border-radius: 4px;
  padding: 1px 5px; font-size: .92em; word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", "Courier New", monospace;
}
.detail-content.rich iframe, .detail-content.rich video, .detail-content.rich embed { max-width: 100%; }

@media (max-width: 768px) {
  /* 公告条：允许换行，日期/返回链接移到第二行；公告文字省略号 */
  .notice-inner { flex-wrap: wrap; row-gap: 1px; }
  .notice-list { min-width: 0; }
  .notice-bar .notice-item {
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
  }
  .notice-date { margin-left: auto; }

  /* 详情页 */
  .detail-card { padding: 18px 15px; }
  .detail-title { font-size: 19px; line-height: 1.5; }
  .detail-meta { gap: 8px; }
  .seo-lead { padding: 12px 13px 10px; margin-bottom: 16px; }
  .seo-lead li { font-size: 13.5px; }
  .kw-tags, .kw-rel { gap: 6px; }
  .kw { font-size: 12.5px; padding: 2px 10px; }
  .doc-item { flex-wrap: wrap; }
  .doc-name { flex: 1 1 100%; white-space: normal; }
}

@media (max-width: 640px) {
  /* 后台：管理列表行允许换行，按钮不挤压 */
  .admin-card { padding: 16px 13px; }
  .card-title { flex-wrap: wrap; row-gap: 6px; }
  .card-title em { margin-left: 0; flex-basis: 100%; }
  .admin-row { flex-wrap: wrap; row-gap: 6px; }
  .ar-main { flex: 1 1 100%; }
  .ar-title { white-space: normal; }
  .ar-title, .pr-main { white-space: normal; }
  .pub-row { flex-wrap: wrap; row-gap: 6px; }
  .pr-main { flex: 1 1 100%; }
  .cmp-row { flex-direction: column; gap: 5px; }
  .cmp-t { min-width: 0; }
  .pub-form input, .pub-form select, .pub-form textarea { font-size: 16px; }  /* 防 iOS 聚焦自动放大 */
  .btn-main { width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
  .login-box { max-width: calc(100vw - 24px); padding: 26px 20px 20px; }
}

/* ================= 后台管理：左右两栏布局 ================= */
.admin-shell { display: flex; gap: 18px; align-items: flex-start; padding-top: 16px; padding-bottom: 30px; }
.admin-main  { flex: 1; min-width: 0; }
.admin-side {
  width: 178px; flex-shrink: 0; background: #fff; border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 10px; position: sticky; top: 14px;
  display: flex; flex-direction: column; gap: 10px;
}
.as-brand { display: flex; align-items: center; gap: 8px; padding: 4px 6px 10px; border-bottom: 1px solid var(--line); }
.as-brand .logo-badge { width: 30px; height: 30px; font-size: 13px; }
.as-brand b { font-size: 15px; color: #1f2d3d; display: block; line-height: 1.2; }
.as-brand small { display: block; font-size: 11.5px; color: var(--gray-l); }
.as-nav { display: flex; flex-direction: column; gap: 2px; }
.as-nav a {
  display: block; padding: 9px 12px; border-radius: 7px; font-size: 13.5px;
  color: #4a5459; text-decoration: none; transition: all .15s; border-left: 3px solid transparent;
}
.as-nav a:hover { background: #f5f6fa; color: var(--red); }
.as-nav a.on { background: #fdf1f2; color: var(--red); border-left-color: var(--red); font-weight: 600; }
.as-foot { border-top: 1px solid var(--line); padding-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.as-foot a { font-size: 12.5px; color: var(--gray-l); text-decoration: none; padding: 2px 6px; }
.as-foot a:hover { color: var(--red); }
@media (max-width: 900px) {
  .admin-shell { flex-direction: column; }
  .admin-side { position: static; width: 100%; }
  .as-nav { flex-direction: row; flex-wrap: wrap; }
  .as-nav a { padding: 7px 10px; border-left: none; }
  .as-foot { flex-direction: row; gap: 14px; border-top: none; padding-top: 2px; }
}

/* 《广告法》禁用词管理 */
.banned-add-form { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.banned-add-form input[type="text"] {
  flex: 1; min-width: 150px; margin: 0 !important;
  padding: 9px 12px; border: 1px solid var(--line); border-radius: 7px; font-size: 13.5px;
}
.banned-add-form input[name="word"] { flex: 0 0 220px; }
.banned-list { display: flex; flex-wrap: wrap; gap: 8px; }
.banned-chip {
  display: inline-flex; align-items: center; gap: 6px; background: #fff;
  border: 1px solid var(--line); border-radius: 7px; padding: 6px 8px 6px 12px; font-size: 13px;
}
.banned-chip .bw-word { color: #c0392b; font-weight: 600; }
.banned-chip .bw-arrow { color: #b0b8bf; font-style: normal; }
.banned-chip .bw-repl { color: #27ae60; }
.banned-chip form { display: inline; }
.banned-chip button {
  border: none; background: #f0f2f5; color: #909399; width: 20px; height: 20px;
  border-radius: 50%; cursor: pointer; line-height: 1; font-size: 14px;
}
.banned-chip button:hover { background: var(--red); color: #fff; }

/* ================= 首页门户：轮播 + 分栏信息块 ================= */
.home-portal { padding-top: 16px; padding-bottom: 20px; }

/* 轮播组件（顶部 banner 3:1 / 图片新闻 12:5，按容器宽度自适应） */
.hg-slider {
  position: relative; overflow: hidden; background: var(--navy);
  border-radius: 10px; box-shadow: 0 3px 14px rgba(13,33,53,.12);
  min-width: 0; max-width: 100%;
}
.hg-slider.hero { aspect-ratio: 30 / 7; min-height: 130px; max-height: 295px; }
.hg-slider.news { aspect-ratio: 12 / 5; min-height: 200px; max-height: 360px; }
.hgs-slides, .hgs-slide { position: absolute; inset: 0; }
.hgs-slides { display: block; }
.hgs-slide {
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .6s ease; pointer-events: none;
}
.hgs-slide.on { opacity: 1; pointer-events: auto; }
.hgs-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hgs-cap {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 20px 12px;
  background: linear-gradient(transparent, rgba(13,33,53,.78));
  color: #fff; font-size: 15px; font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hgs-default {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  justify-content: center; color: #fff; text-align: center; padding: 0 24px;
}
.hgs-default b { display: block; font-size: 26px; letter-spacing: 2px; }
.hgs-default p { margin-top: 10px; font-size: 14px; opacity: .8; }
.hgs-btn {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 36px; height: 36px; border: none; border-radius: 50%;
  background: rgba(255,255,255,.22); color: #fff; font-size: 22px; line-height: 1;
  cursor: pointer; transition: background .15s;
}
.hgs-btn:hover { background: rgba(225,24,38,.85); }
.hgs-btn.prev { left: 12px; }
.hgs-btn.next { right: 12px; }
.hgs-dots {
  position: absolute; bottom: 10px; right: 16px; z-index: 3;
  display: flex; gap: 7px;
}
.hgs-dots i {
  width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.45);
  cursor: pointer; transition: all .2s;
}
.hgs-dots i.on { background: var(--red); width: 22px; border-radius: 5px; }
.hgs-tag {
  position: absolute; top: 12px; left: 12px; z-index: 3;
  background: var(--red); color: #fff; font-size: 12.5px; font-weight: 600;
  padding: 3px 12px; border-radius: 999px; letter-spacing: 1px;
}

/* 分栏行 */
.home-row {
  display: grid; grid-template-columns: 1.35fr 1fr; gap: 16px;
  align-items: stretch; margin-top: 16px;
}
.home-row.row-first { grid-template-columns: calc(62% - 220px) 1fr; margin-top: 16px; }

/* 信息面板 */
.news-panel {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 4px 16px 10px; display: flex; flex-direction: column; overflow: hidden;
}
.np-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 0 8px; border-bottom: 2px solid #f2f3f5; margin-bottom: 4px;
}
.np-tt { display: flex; align-items: center; gap: 9px; font-size: 16.5px; font-weight: 700; color: var(--navy); }
.np-tt i { width: 5px; height: 18px; background: var(--red); border-radius: 2px; }
.np-more { font-size: 12.5px; color: var(--gray-l); text-decoration: none; }
.np-more:hover { color: var(--red); }
.np-list { list-style: none; margin: 0; padding: 0; flex: 1; display: flex; flex-direction: column; }
.np-list li {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; border-bottom: 1px dashed #f0f0f0; min-width: 0;
}
.np-list li:last-child { border-bottom: none; }
.np-title {
  flex: 1; min-width: 0; color: #303133; font-size: 14.5px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none;
}
.np-title:hover { color: var(--red); }
.np-title::before { content: '·'; color: var(--red); font-weight: 800; margin-right: 6px; }
.np-date { flex: none; color: var(--gray-l); font-size: 12px; }
.np-tag {
  flex: none; font-size: 11.5px; color: var(--navy); background: #eef2f6;
  border-radius: 3px; padding: 1px 7px; white-space: nowrap;
}
.np-empty { justify-content: center; color: var(--gray-l); font-size: 13px; }
.hot-panel .np-title { font-weight: 600; }

/* 后台：轮播图管理列表 */
.banner-list { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.banner-item {
  display: flex; align-items: center; gap: 14px;
  border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px 10px 10px;
}
.banner-item img {
  width: 150px; height: 62px; object-fit: cover; border-radius: 5px;
  border: 1px solid var(--line); flex-shrink: 0; background: #f5f6fa;
}
.bi-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.bi-pos { font-size: 12.5px; }
.bi-pos.top  { color: var(--red); }
.bi-pos.news { color: var(--navy); }
.bi-title { font-size: 14px; color: #303133; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bi-link { font-size: 12px; color: var(--gray-l); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 首页门户响应式 */
@media (max-width: 860px) {
  .home-row, .home-row.row-first { grid-template-columns: 1fr; }
  .hg-slider.hero { aspect-ratio: 20 / 7; }
  .hg-slider.news { aspect-ratio: 16 / 9; }
  .hgs-default b { font-size: 20px; }
  .np-title { font-size: 14px; }
}

/* 后台：上传要求提示 */
.up-hint {
  margin: 0 0 4px; padding: 9px 12px; background: #f7f9fb; border: 1px dashed #dfe3e8;
  border-radius: 7px; font-size: 12.5px; line-height: 1.85; color: #6b7785;
}
.up-hint b { color: #2f3d4a; font-weight: 600; }

/* ================= 详情页右侧榜单（热搜榜 / 钢号榜 / 制造榜 + 点击排行） ================= */
.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 328px;
  gap: 20px;
  align-items: start;
}
.detail-main { min-width: 0; }
.detail-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }

.side-box {
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  overflow: hidden; box-shadow: 0 1px 3px rgba(13,33,53,.03);
}

/* Tab 条（百度热搜式） */
.rk-tabs { display: flex; background: #fafbfc; border-bottom: 1px solid #eef0f3; }
.rk-tab {
  flex: 1; min-width: 0; padding: 12px 2px 11px;
  border: 0; background: none; cursor: pointer;
  font-family: inherit; font-size: 14.5px; color: #66727c;
  position: relative; transition: color .15s, background .15s;
}
.rk-tab + .rk-tab::before {
  content: ""; position: absolute; left: 0; top: 13px; bottom: 13px; width: 1px; background: #eef0f3;
}
.rk-tab:hover { color: var(--red); background: #fff; }
.rk-tab.on { color: var(--navy); font-weight: 700; background: #fff; }
.rk-tab.on::after {
  content: ""; position: absolute; left: 50%; bottom: -1px; transform: translateX(-50%);
  width: 30px; height: 2px; border-radius: 2px; background: var(--red);
}
.rk-tab:focus-visible { outline: 2px solid rgba(225,24,38,.35); outline-offset: -3px; }

.rk-panes { padding: 12px 12px 13px; }
.rk-pane { display: none; }
.rk-pane.on { display: block; }
.rk-empty { padding: 14px 4px; text-align: center; color: var(--gray-l); font-size: 13px; }

/* 榜单条目：每行 3 个（窄屏自动 2 个） */
.rk-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px 6px; }
.rk-item {
  display: flex; align-items: center; gap: 4px; min-width: 0;
  padding: 6px 4px; border-radius: 5px;
  font-size: 12.8px; line-height: 1.35; color: #3f4b55;
  transition: background .12s, color .12s;
}
.rk-item:hover { background: #fdf1f2; color: var(--red); }
.rk-no {
  flex: none; width: 14px; text-align: center; font-size: 11px; font-weight: 700;
  color: #c2c9d0; font-family: "Segoe UI", Arial, sans-serif;
}
.rk-item.top .rk-no { color: var(--red); }
.rk-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 点击排行 TOP5 */
.side-head {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 14px 10px; border-bottom: 1px solid #f2f3f5;
  font-size: 15.5px; font-weight: 700; color: var(--navy);
}
.side-head i { width: 4px; height: 16px; border-radius: 2px; background: var(--red); }
.side-head em {
  margin-left: auto; font-style: normal; font-size: 11px; font-weight: 700;
  letter-spacing: .6px; color: var(--red); background: #fdf1f2; border-radius: 3px; padding: 1px 6px;
}
.ck-list { list-style: none; margin: 0; padding: 4px 12px 10px; }
.ck-list li { border-bottom: 1px dashed #f2f4f6; }
.ck-list li:last-child { border-bottom: 0; }
.ck-list a { display: flex; gap: 9px; padding: 9px 2px; }
.ck-no {
  flex: none; width: 17px; height: 17px; margin-top: 2px; border-radius: 3px;
  display: inline-flex; align-items: center; justify-content: center;
  background: #ccd3d9; color: #fff; font-size: 11px; font-weight: 700;
  font-family: "Segoe UI", Arial, sans-serif;
}
.ck-list li:nth-child(1) .ck-no { background: #e11826; }
.ck-list li:nth-child(2) .ck-no { background: #ef6a30; }
.ck-list li:nth-child(3) .ck-no { background: #f0a03c; }
.ck-body { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ck-t {
  font-size: 13.5px; line-height: 1.5; color: #303133;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.ck-list a:hover .ck-t { color: var(--red); }
.ck-m { font-size: 11.5px; color: var(--gray-l); }

@media (max-width: 980px) {
  .detail-layout { grid-template-columns: 1fr; }
  .detail-side { gap: 14px; }
  .rk-grid { grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); }
}

/* ================= 频道列表页：左侧信息列表 + 右侧榜单（与文章页同一套组件） ================= */
.cat-layout { margin-bottom: 24px; }
.cat-layout .detail-main .pager { margin-bottom: 18px; }
@media (min-width: 981px) {
  /* 列表较长，榜单随滚动吸附，方便随手点 */
  .cat-layout .detail-side { position: sticky; top: 14px; }
}

/* ================= 后台全屏宽（100% 显示，仅 admin.php 生效） ================= */
/* 后台页面 body 带 .admin-body，登录页是 .login-body，互不影响 */
.admin-body .container { max-width: none; width: 100%; }
.admin-body .container.admin-shell {
  padding-left: 20px; padding-right: 20px;
  box-sizing: border-box;
}
.admin-body .container.notice-inner { padding-left: 20px; padding-right: 20px; }

/* 超宽屏下让左栏略宽、内容区留白更舒展，同时表格不会挤成一条线 */
@media (min-width: 1560px) {
  .admin-body .admin-side { width: 196px; }
}
@media (max-width: 640px) {
  .admin-body .container.admin-shell,
  .admin-body .container.notice-inner { padding-left: 12px; padding-right: 12px; }
}
