/*! nbsensor 静态站移动端修补 v1 —— 2026-10-23
 * 作用：修掉原站模板在窄屏下的横向溢出（宽参数表把整页撑到 600px+，
 *       连带搜索框、正文都被挤出屏幕），并让搜索表单在手机上按比例收缩。
 * 只影响视觉，不改任何内容与链接；删掉本文件与页面里的 <link> 即完全回退。
 */
html, body { max-width: 100%; overflow-x: hidden; }

@media (max-width: 767.98px) {
  /* 1) 窄屏取消两栏 flex，改为上下堆叠（原来 .main 被内容撑破 414px 视口） */
  .wrap {
    display: block !important;
    padding: 12px 0 !important;
  }
  .wrap > .main,
  .main {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    flex: none !important;
  }

  /* 2) 宽表改为块级横向滚动，不再撑破整页 */
  .content,
  .main .content { max-width: 100%; }
  .content table,
  .main table,
  table.param-table {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }

  /* 3) 搜索表单：输入框可收缩，按钮不被挤出屏幕 */
  form.form-inline {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    align-items: stretch;
    width: 100%;
  }
  form.form-inline > input.form-control {
    flex: 1 1 auto;
    min-width: 0;
    width: auto !important;
    max-width: none;
  }
  form.form-inline > button,
  form.form-inline > .btn {
    flex: 0 0 auto;
    white-space: nowrap;
    width: auto !important;
    max-width: none;
  }

  /* 4) 长英文/URL 与图片不撑破容器 */
  .content, .main {
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  .content img, .main img { max-width: 100% !important; height: auto; }
}
