/* BearDocs v9.2 — Mobile category CTA cleanup.
   The category jump links were duplicated on mobile because old desktop/mobile
   visibility rules were overwritten by later section-link styles. */

@media (max-width: 639px) {
  /* 移动端：同一模块只保留一个“浏览分类”入口 */
  .bd-home-featured .bd-desktop-directory-link,
  .bd-home-latest .bd-desktop-directory-link {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  .bd-home-featured .bd-mobile-directory-link,
  .bd-home-latest .bd-mobile-directory-link {
    visibility: visible !important;
    pointer-events: auto !important;
    cursor: pointer !important;
  }

  /* 推荐阅读头部：左侧标题，右侧唯一按钮 */
  .bd-home-featured .bd-section-head {
    position: relative !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 16px !important;
    min-height: 74px !important;
    background: #fff !important;
    border-bottom: 1px solid #edf1f6 !important;
  }

  .bd-home-featured .bd-section-title-row {
    display: grid !important;
    grid-template-columns: 42px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 12px !important;
    min-width: 0 !important;
  }

  .bd-home-featured .bd-section-title-row > div {
    display: block !important;
    min-width: 0 !important;
  }

  .bd-home-featured .bd-section-link.bd-mobile-directory-link {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    position: relative !important;
    z-index: 5 !important;
    width: auto !important;
    min-width: 78px !important;
    height: 34px !important;
    padding: 0 12px !important;
    margin: 0 !important;
    border-radius: 999px !important;
    background: #f6f9fd !important;
    color: #1677ff !important;
    border: 1px solid #e6eef8 !important;
    box-shadow: none !important;
    font-size: 12px !important;
    font-weight: 650 !important;
    line-height: 1 !important;
    text-decoration: none !important;
    transform: none !important;
  }

  .bd-home-featured .bd-section-link.bd-mobile-directory-link i {
    margin-left: 2px !important;
    font-size: 14px !important;
    line-height: 1 !important;
    transform: none !important;
  }

  .bd-home-featured .bd-section-link.bd-mobile-directory-link:active,
  .bd-home-latest .bd-latest-footer-link.bd-mobile-directory-link:active {
    background: #eef5ff !important;
  }

  /* 最新发布底部：只保留一个轻量入口，不再左右两个并列 */
  .bd-home-latest .bd-latest-footer-link.bd-mobile-directory-link {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 4px !important;
    width: 100% !important;
    min-height: 42px !important;
    padding: 0 16px !important;
    margin: 0 !important;
    border-top: 1px solid #edf1f6 !important;
    background: #fff !important;
    color: #64748b !important;
    font-size: 12px !important;
    font-weight: 650 !important;
    text-decoration: none !important;
    pointer-events: auto !important;
  }

  .bd-home-latest .bd-latest-footer-link.bd-mobile-directory-link i {
    color: #94a3b8 !important;
    transform: none !important;
  }
}

@media (min-width: 640px) {
  .bd-mobile-directory-link {
    display: none !important;
  }
}
