/* ============================================================
   分类页样式
   由 category.php 内联 <style> 抽离而来（样式与程序分离）。
   动态主题色经由页面根元素的 inline style 注入 CSS 变量。
   ============================================================ */
  /* ===== 分类页（紧扣首页主题：蓝 #1b5bd5 / 橙 #f25d30 / 1200 居中 / 白卡片） ===== */
  .catpage-wrap { min-height: 100vh; display: flex; flex-direction: column; }
  .cw { width: 1200px; max-width: calc(100% - 24px); margin: 0 auto; }

  /* 头部：logo + 搜索 + 返回 */
  .cat-header { background: #fff; border-bottom: 1px solid #e6e6e6; }
  .cat-header .cw { display: flex; align-items: center; gap: 24px; padding: 16px 0; }
  .cat-logo { display: flex; align-items: center; gap: 8px; flex-shrink: 0; text-decoration: none; }
  .cat-logo .lg-mark { width: 34px; height: 34px; border-radius: 7px; background: #1b5bd5; display: flex; align-items: center; justify-content: center; }
  .cat-logo .lg-mark svg { width: 34px; height: 34px; }
  .cat-logo .lg-txt { display: flex; flex-direction: column; line-height: 1.25; }
  .cat-logo .lg-txt .t { font-size: 17px; font-weight: 700; color: #333; letter-spacing: .5px; }
  .cat-logo .lg-txt .u { font-size: 11px; color: #aaa; }
  .cat-logo img.lg-img { max-height: 46px; display: block; }

  .cat-search { flex: 1; max-width: 560px; }
  .cat-search form { display: flex; height: 40px; border: 2px solid #1b5bd5; border-radius: 8px; overflow: hidden; }
  .cat-search input { flex: 1; border: none; outline: none; padding: 0 14px; font-size: 14px; color: #333; min-width: 0; }
  .cat-search input::placeholder { color: #aaa; }
  .cat-search button { border: none; background: #1b5bd5; color: #fff; padding: 0 22px; font-size: 14px; letter-spacing: 2px; cursor: pointer; transition: background .15s; }
  .cat-search button:hover { background: #1749b0; }
  .cat-home-btn { margin-left: auto; flex-shrink: 0; display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: #555; text-decoration: none; padding: 7px 14px; border: 1px solid #e2e5ea; border-radius: 6px; transition: all .15s; }
  .cat-home-btn:hover { color: #1b5bd5; border-color: #1b5bd5; background: #f4f8ff; }

  /* 主体 */
  .cat-main { flex: 1; padding: 20px 0 40px; }

  /* 面包屑 */
  .cat-crumb { font-size: 13px; color: #999; padding: 4px 2px 14px; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
  .cat-crumb a { color: #888; text-decoration: none; }
  .cat-crumb a:hover { color: #1b5bd5; }
  .cat-crumb .sep { color: #ccc; }
  .cat-crumb .cur { color: #1b5bd5; font-weight: 600; }

  /* 分类头卡片 */
  .cat-hero { background: #fff; border-radius: 12px; box-shadow: 0 1px 3px rgba(0,0,0,.05); padding: 22px 24px; margin-bottom: 16px; }
  .cat-hero-top { display: flex; align-items: center; gap: 16px; }
  .cat-hero-ico { width: 56px; height: 56px; min-width: 56px; border-radius: 14px; background: linear-gradient(135deg, #1b5bd5, #1749b0); display: flex; align-items: center; justify-content: center; color: #fff; box-shadow: 0 4px 12px rgba(27,91,213,.28); }
  .cat-hero-meta h1 { margin: 0; font-size: 22px; font-weight: 700; color: #222; letter-spacing: .5px; }
  .cat-hero-meta .sub { margin-top: 5px; font-size: 13px; color: #999; }
  .cat-hero-meta .sub b { color: #f25d30; font-size: 15px; margin: 0 2px; }

  /* 同级分类切换 */
  .cat-sibs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px dashed #eef0f4; }
  .cat-sib { font-size: 13px; color: #666; text-decoration: none; padding: 5px 14px; border-radius: 16px; background: #f5f6f8; border: 1px solid #eceef1; transition: all .15s; white-space: nowrap; }
  .cat-sib:hover { color: #1b5bd5; border-color: #cddbf5; background: #f0f6ff; }
  .cat-sib.on { color: #fff; background: #1b5bd5; border-color: #1b5bd5; }

  /* 网址卡片网格 */
  .cu-panel { background: #fff; border-radius: 12px; box-shadow: 0 1px 3px rgba(0,0,0,.05); padding: 18px 20px 22px; }
  .cu-panel-head { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; color: #333; padding: 2px 2px 16px; }
  .cu-panel-head::before { content: ''; width: 3px; height: 15px; background: #1b5bd5; border-radius: 2px; }
  .cu-grid { display: grid; grid-template-columns: repeat(var(--cu-cols, 4), 1fr); gap: 12px; }
  .cu-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid #eef0f3; border-radius: 10px; background: #fff; text-decoration: none; transition: border-color .15s, box-shadow .15s, transform .15s; min-width: 0; }
  .cu-card:hover { border-color: #cddbf5; box-shadow: 0 6px 16px rgba(27,91,213,.12); transform: translateY(-2px); }
  .cu-ico { width: 40px; height: 40px; min-width: 40px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: #fff; overflow: hidden; position: relative; }
  .cu-ico.r { border-radius: 50%; }
  .cu-ico .site-favicon { width: 100%; height: 100%; object-fit: cover; }
  .cu-body { min-width: 0; flex: 1; overflow: hidden; }
  .cu-name { display: block; font-size: 14px; font-weight: 600; color: #333; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .15s; }
  .cu-card:hover .cu-name { color: #1b5bd5; }
  .cu-desc { display: block; font-size: 12px; color: #9aa0a8; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .cu-empty { text-align: center; color: #b0b4bb; font-size: 14px; padding: 50px 0; }
  .cu-empty .ce-ico { font-size: 40px; margin-bottom: 10px; }

  /* 分类不存在 */
  .cat-404 { background: #fff; border-radius: 12px; box-shadow: 0 1px 3px rgba(0,0,0,.05); text-align: center; padding: 70px 20px; }
  .cat-404 .big { font-size: 46px; margin-bottom: 12px; }
  .cat-404 h2 { margin: 0 0 8px; font-size: 20px; color: #333; }
  .cat-404 p { color: #999; font-size: 14px; margin: 0 0 22px; }
  .cat-404 a { display: inline-block; padding: 9px 24px; background: #1b5bd5; color: #fff; border-radius: 6px; text-decoration: none; font-size: 14px; }
  .cat-404 a:hover { background: #1749b0; }

  @media (max-width: 1024px) { .cu-grid { --cu-cols: 3; } }
  @media (max-width: 768px) {
    .cu-grid { --cu-cols: 2; }
    .cat-header .cw { flex-wrap: wrap; gap: 12px; }
    .cat-search { order: 3; max-width: 100%; flex-basis: 100%; }
    .cat-home-btn { margin-left: 0; }
  }
  @media (max-width: 480px) { .cu-grid { --cu-cols: 1; } }
