/* ============================================
   公考真题库 · 移动端适配样式（独立文件）
   平板/手机断点：≤860px 平板布局，≤480px 手机布局
   ============================================ */

/* ---------- 平板及以下（≤860px） ---------- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { max-width: 420px; margin: 0 auto; }
  .hero { padding: 48px 0; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); row-gap: 26px; }
  .steps { grid-template-columns: 1fr; }

  /* 折叠式导航菜单 */
  .menu-btn { display: block; }
  .nav {
    position: fixed; top: 64px; right: 0; left: 0;
    flex-direction: column; gap: 0;
    background: var(--card); border-bottom: 1px solid var(--border);
    max-height: 0; overflow: hidden; transition: max-height .35s ease;
  }
  .nav.open { max-height: 300px; box-shadow: 0 16px 30px rgba(15, 23, 42, .08); }
  .nav a { padding: 14px 24px; border-top: 1px solid var(--bg); }

  /* 平板：缩小 logo 标题，避免拥挤 */
  .logo { font-size: 17px; }

  /* 真题下载分类 tab（含一/二/三级行）：单行横向滑动，不再折行 */
  .pdf-tabs { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding-bottom: 4px; margin-bottom: 12px; }
  .pdf-tabs::-webkit-scrollbar { display: none; }
  .pdf-tab { flex: 0 0 auto; white-space: nowrap; }
  /* 报名地址分类 tab：同样单行横向滑动 */
  .gov-tabs { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding-bottom: 4px; margin-bottom: 14px; }
  .gov-tabs::-webkit-scrollbar { display: none; }
  .gov-tab { flex: 0 0 auto; white-space: nowrap; }
  /* 卡片内容高度自适应，避免留白 */
  .cat-card p, .cat-years { min-height: 0; }
}

/* ---------- 手机（≤480px，百度移动端收录适配） ---------- */
@media (max-width: 480px) {
  .side-grid { grid-template-columns: 1fr; }
  body { font-size: 15px; }

  /* 手机：整体组件缩小，避免拥挤 */
  .logo { font-size: 16px; }
  .logo svg { width: 20px; height: 20px; }
  .section-title { font-size: 24px; }
  .section-desc { font-size: 14px; margin: 8px 0 28px; }
  .stat b { font-size: 28px; }

  .hero { padding: 40px 0; }
  .hero h1 { font-size: 30px; }
  .hero-sub { font-size: 15px; color: var(--hero-sub-mobile, var(--text)); }
  .hero-actions .btn { width: 100%; justify-content: center; text-align: center; }
  .section { padding: 48px 0; }
  .links-sub { margin: 30px 0 14px; font-size: 17px; }

  /* 真题下载卡片：单列大卡 + 触控友好的下载按钮 */
  .cat-grid { grid-template-columns: 1fr; gap: 14px; }
  .cat-card { padding: 18px 16px; border-radius: 14px; }
  .cat-card h3 { font-size: 17px; }
  .cat-card p { font-size: 13px; }
  .cat-tag { top: 15px; right: 14px; font-size: 11px; padding: 1px 8px; }
  .btn-download { width: 100%; min-height: 44px; font-size: 15px; }

  /* 报名地址与笔试时间：两列紧凑卡片，文字适配小屏 */
  .gov-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .gov-card { padding: 12px 10px; border-radius: 10px; gap: 1px; }
  .gov-card b { font-size: 14px; }
  .gov-card span { font-size: 11px; line-height: 1.45; }
  .gov-card .gov-time { font-size: 11px; line-height: 1.5; margin-top: 3px; }
  .gov-note { font-size: 12px; margin-top: 14px; line-height: 1.6; }

  .footer-inner { flex-direction: column; text-align: center; }
}
