/* ============================================================================
   海纳智能体 · 设计系统覆盖层 v2 ——「NEON GRID / 霓虹网格」
   ----------------------------------------------------------------------------
   风格：科技感为底 + 赛博朋克点缀（深空蓝黑 · 青/品红霓虹 · HUD 细线 · 网格扫描）
   接入：<link rel="stylesheet" href="/static/css/design-system.css?v=20260914_1">
   回滚：删掉该行即可，零残留。
   原则：纯 CSS 叠加，不动任何页面结构/业务代码；同名选择器后加载自然覆盖。
   安全：角标/描边一律用「多层 background-image」实现，不新增 position 上下文，
         避免改变卡片内部 absolute 元素的定位参照（v1 踩过的坑）。
   ========================================================================== */

/* ══ 1. 设计 Token ═══════════════════════════════════════════════════════ */
:root {
  /* —— 霓虹主色 —— */
  --nx-cyan:      #00e5ff;   /* 主功能色：聚焦/激活/链接/主按钮 */
  --nx-cyan-dim:  #0aa8c4;
  --nx-magenta:   #ff2d9b;   /* 次强调：装饰线/告警点缀 */
  --nx-violet:    #7c5cff;   /* 渐变桥接 */
  --nx-lime:      #3ddc97;   /* 成功/在线 */
  --nx-amber:     #ffb020;   /* 警告 */
  --nx-red:       #ff4d6d;   /* 危险 */

  /* —— 表面 —— */
  --nx-bg-deep:   #060a14;
  --nx-surface:   rgba(10, 16, 32, .74);
  --nx-surface-2: rgba(7, 11, 24, .66);
  --nx-line:      rgba(0, 229, 255, .18);
  --nx-line-hi:   rgba(0, 229, 255, .45);

  /* —— 文本 —— */
  --nx-text:      #e8f1ff;
  --nx-text-dim:  #9fb3d1;
  --nx-text-mute: #6b81a5;

  /* —— 形状 / 动效 —— */
  --nx-r:         10px;
  --nx-r-sm:      6px;
  --nx-glow-c:    0 0 12px rgba(0, 229, 255, .35);
  --nx-glow-m:    0 0 12px rgba(255, 45, 155, .30);
  --nx-shadow:    0 10px 34px rgba(0, 0, 0, .50);
  --nx-ease:      cubic-bezier(.4, 0, .2, 1);

  /* 数字等宽字体（统计值 / 编号 / 时间） */
  --nx-num: "SF Mono", "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;

  /* 全局覆盖：让原样式表的 CSS 变量一起转向新色板 */
  --glass-bg: rgba(10, 16, 32, .74);
  --glass-border: rgba(0, 229, 255, .18);
  --glass-shadow: 0 10px 34px rgba(0, 0, 0, .50);
  --text-primary: #e8f1ff;
  --text-secondary: rgba(232, 241, 255, .74);
  --text-muted: rgba(159, 179, 209, .62);
  --radius-md: 10px;
  --transition: all .25s cubic-bezier(.4, 0, .2, 1);
}

/* ══ 2. 全局氛围：网格 + 扫描线 + 双霓虹光晕 + 缓慢扫描光束 ═══════════════ */
body { position: relative; }

/* 不覆盖 body 背景（各页自带深色渐变，覆盖会"洗灰"整页），只叠加氛围层 */
body::after {
  content: "";
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    /* ① 网格：40px 青色细线，极低透明 */
    repeating-linear-gradient(90deg,  rgba(0,229,255,.045) 0 1px, transparent 1px 40px),
    repeating-linear-gradient(0deg,   rgba(0,229,255,.045) 0 1px, transparent 1px 40px),
    /* ② CRT 扫描线：2px 周期暗纹 */
    repeating-linear-gradient(0deg,   rgba(0,0,0,.20) 0 1px, transparent 1px 3px),
    /* ③ 右上青光晕 */
    radial-gradient(1100px 560px at 86% -14%, rgba(0,229,255,.12), transparent 62%),
    /* ④ 左下品红光晕 */
    radial-gradient(900px 480px at -6% 108%, rgba(255,45,155,.09), transparent 60%);
}
/* 缓慢下移的扫描光束（赛博朋克标志动效，透明度极低不扰阅读） */
body > .nx-scan { display: none; }
body::before {
  content: "";
  position: fixed; left: 0; right: 0; top: 0; height: 180px; z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(0,229,255,.055), transparent);
  animation: nx-sweep 11s linear infinite;
}
@keyframes nx-sweep {
  0%   { transform: translateY(-200px); opacity: 0; }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { transform: translateY(100vh); opacity: 0; }
}

/* 页面真实内容压在氛围层之上 */
body > *:not(.nx-scan) { position: relative; z-index: 1; }
/* 顶栏/浮层本就自带高层级，确保不被氛围层压住 */
.top-bar, .policy-hub-header, .header, header, .modal, .business-panel,
.sidebar, aside, nav { z-index: 20; }

::selection { background: rgba(0, 229, 255, .32); color: #fff; }

/* ══ 3. 滚动条 ══════════════════════════════════════════════════════════ */
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-track { background: rgba(0, 0, 0, .28); }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(0,229,255,.42), rgba(124,92,255,.42));
  border-radius: 9px;
  border: 2px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, rgba(0,229,255,.72), rgba(124,92,255,.72)); background-clip: padding-box; }

/* ══ 3b. hidden 兜底：index 等页不引 policy-hub.css，.hidden 无样式会导致
          业务流面板永远关不掉、并把手机视口撑出 2 倍横滑（390→780，实测） */
.hidden { display: none !important; }

/* ══ 4. 卡片 / 面板：HUD 玻璃 + 霓虹顶线 + 右上切角标 ═══════════════════ */
.ph-card,
.card,
.stat-card,
.kpi-card,
.chart-card,
.chart-box,
.chart-container,
.panel,
.modal-card,
.match-card,
.cluster-card,
.hot-concern-card,
.generated-item,
.pm-card,
[class*="panel"]:not(.messages-panel):not(.business-panel) {
  background-color: var(--nx-surface) !important;
  background-image:
    /* 顶部霓虹细线（青→品红渐变，两端淡出） */
    linear-gradient(90deg, transparent, rgba(0,229,255,.85) 22%, rgba(255,45,155,.75) 78%, transparent),
    /* 右上 L 形角标 */
    linear-gradient(rgba(0,229,255,.55), rgba(0,229,255,.55)),
    linear-gradient(rgba(0,229,255,.55), rgba(0,229,255,.55)),
    /* 本体渐变 */
    linear-gradient(158deg, rgba(13,20,40,.90), rgba(6,10,22,.78)) !important;
  background-size: 100% 2px, 12px 2px, 2px 12px, 100% 100% !important;
  background-position: 0 0, right 0 top 0, right 0 top 0, 0 0 !important;
  background-repeat: no-repeat !important;
  border: 1px solid var(--nx-line) !important;
  border-radius: var(--nx-r) !important;
  box-shadow: var(--nx-shadow), inset 0 1px 0 rgba(255,255,255,.05) !important;
  transition: transform .25s var(--nx-ease), box-shadow .25s var(--nx-ease),
              border-color .25s var(--nx-ease);
}
@media (hover: hover) {
  .ph-card:hover, .card:hover, .stat-card:hover, .kpi-card:hover,
  .chart-card:hover, .chart-box:hover, .chart-container:hover,
  .match-card:hover, .cluster-card:hover {
    border-color: var(--nx-line-hi) !important;
    box-shadow: var(--nx-shadow), 0 0 22px rgba(0,229,255,.14),
                inset 0 1px 0 rgba(255,255,255,.07) !important;
  }
}

/* ══ 5. 顶栏 / 页头：加深 + 青色渐变分隔线 ══════════════════════════════ */
.top-bar, .policy-hub-header, header, .header {
  border-bottom: 1px solid transparent !important;
  border-image: linear-gradient(90deg,
    rgba(0,229,255,.55), rgba(124,92,255,.28), rgba(255,45,155,.18), transparent 72%) 1 !important;
  background: linear-gradient(180deg, rgba(6,10,20,.92), rgba(6,10,20,.62)) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* 圆形返回键 / 图标块：霓虹描边 */
.policy-hub-back, .policy-hub-icon {
  border: 1px solid var(--nx-line) !important;
  background: rgba(0, 229, 255, .08) !important;
  box-shadow: inset 0 0 12px rgba(0,229,255,.10);
}
.policy-hub-back:hover {
  background: rgba(0, 229, 255, .20) !important;
  box-shadow: var(--nx-glow-c);
}
.policy-hub-icon {
  background: linear-gradient(135deg, rgba(0,229,255,.22), rgba(255,45,155,.18)) !important;
}

/* ══ 6. 标题：发光 + HUD 竖条 ═══════════════════════════════════════════ */
h1, h2, h3, .policy-hub-title h1, .ph-card-title, .module-entry-title {
  color: #f2f7ff !important;
  letter-spacing: .3px;
  text-shadow: 0 0 18px rgba(0, 229, 255, .18);
}
.ph-card-title {
  font-weight: 600 !important;
}
.ph-card-title::before {
  content: "";
  width: 3px; height: 14px; flex: 0 0 3px;
  margin-right: -3px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--nx-cyan), var(--nx-violet));
  box-shadow: 0 0 8px rgba(0, 229, 255, .55);
}
/* 副标题 / 描述 */
.policy-hub-title p, .sub, .desc-line, .stat-label, .kpi-label {
  color: var(--nx-text-mute) !important;
  letter-spacing: .4px;
}

/* ══ 7. 统计 / KPI 数字：等宽 + 霓虹渐变 + 发光 ═════════════════════════ */
.stat-card .value, .stat-value, .stat-card .num, .kpi-value,
.stat .value, .stat .num, .stat-card .stat-value {
  font-family: var(--nx-num) !important;
  font-weight: 700 !important;
  letter-spacing: -1px;
  background: linear-gradient(135deg, #eafcff 0%, var(--nx-cyan) 40%, var(--nx-violet) 95%) !important;
  /* 注意：background 简写带 !important 会把 clip 重置为 border-box，必须同样 !important 压回 */
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  filter: drop-shadow(0 0 10px rgba(0, 229, 255, .35));
}
.kpi-value { filter: drop-shadow(0 0 12px rgba(0, 229, 255, .40)); }
.stat-card .unit, .unit, .stat-label { color: var(--nx-text-mute) !important; }

/* ══ 8. 按钮：主=暗青紫渐变+外发光，次=霓虹描边 ═════════════════════════ */
button, .btn, .ph-btn, .pm-btn, [class*="btn-"] {
  transition: transform .18s var(--nx-ease), box-shadow .18s var(--nx-ease),
              filter .18s var(--nx-ease), background .18s var(--nx-ease);
}
@media (hover: hover) {
  button:hover, .btn:hover, .ph-btn:hover, .pm-btn:hover { transform: translateY(-1px); }
  button:active, .btn:active, .ph-btn:active, .pm-btn:active { transform: translateY(0); }
}
button:focus-visible, .btn:focus-visible, .ph-btn:focus-visible,
input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(0, 229, 255, .55), 0 0 14px rgba(0, 229, 255, .30) !important;
}

/* 主按钮：暗青→紫渐变，白字，青色外发光（耐看、不刺眼） */
.btn-primary, .ph-btn-primary, button[class*="primary"], .submit-btn {
  background: linear-gradient(120deg, #0aa2c0 0%, #1f4fd8 52%, #6d28d9 100%) !important;
  color: #fff !important;
  border: 1px solid rgba(0, 229, 255, .38) !important;
  box-shadow: 0 4px 18px rgba(0, 160, 210, .28), inset 0 1px 0 rgba(255,255,255,.14) !important;
  font-weight: 600;
  letter-spacing: .4px;
}
@media (hover: hover) {
  .btn-primary:hover, .ph-btn-primary:hover, button[class*="primary"]:hover, .submit-btn:hover {
    box-shadow: 0 6px 26px rgba(0, 229, 255, .40), inset 0 1px 0 rgba(255,255,255,.2) !important;
    filter: brightness(1.12);
  }
}

/* 次级按钮：霓虹描边 */
.ph-btn-secondary, .btn-secondary, .btn, .ph-btn, .pm-btn {
  border: 1px solid var(--nx-line) !important;
  background: rgba(9, 15, 30, .72) !important;
  color: #cfe6f5 !important;
}
@media (hover: hover) {
  .ph-btn-secondary:hover, .btn-secondary:hover, .btn:hover, .ph-btn:hover, .pm-btn:hover {
    border-color: var(--nx-line-hi) !important;
    background: rgba(0, 229, 255, .12) !important;
    color: #eafcff !important;
    box-shadow: 0 0 16px rgba(0, 229, 255, .22);
  }
}
/* 成功按钮 */
.ph-btn-success { background: linear-gradient(120deg, #12a06a, #3ddc97) !important; border: 1px solid rgba(61,220,151,.45) !important; }

/* ══ 9. 表格：青色表头 + 行悬浮微光 ═════════════════════════════════════ */
table { border-collapse: separate !important; border-spacing: 0; }
th {
  background: linear-gradient(180deg, rgba(0,229,255,.16), rgba(0,229,255,.05)) !important;
  color: #9fe8ff !important;
  font-weight: 600 !important;
  letter-spacing: .5px;
  border-bottom: 1px solid rgba(0, 229, 255, .30) !important;
  white-space: nowrap;
}
td { border-bottom: 1px solid rgba(255, 255, 255, .05); }
tbody tr { transition: background .15s var(--nx-ease); }
tbody tr:nth-child(even) td { background: rgba(255, 255, 255, .018); }
@media (hover: hover) {
  tbody tr:hover td { background: rgba(0, 229, 255, .08) !important; }
}

/* ══ 10. 表单控件：深色 + 霓虹聚焦 ══════════════════════════════════════ */
input, select, textarea, .ph-input, .ph-select, .ph-textarea,
.form-input, .form-control {
  background: rgba(4, 8, 18, .62) !important;
  border: 1px solid rgba(0, 229, 255, .18) !important;
  color: var(--nx-text) !important;
  border-radius: var(--nx-r-sm) !important;
  transition: border-color .18s var(--nx-ease), box-shadow .18s var(--nx-ease);
}
input::placeholder, textarea::placeholder, .ph-input::placeholder, .ph-textarea::placeholder {
  color: rgba(159, 179, 209, .45) !important;
}
input:focus, select:focus, textarea:focus,
.ph-input:focus, .ph-select:focus, .ph-textarea:focus {
  border-color: var(--nx-cyan) !important;
  background: rgba(0, 229, 255, .07) !important;
  box-shadow: 0 0 0 2px rgba(0, 229, 255, .22), 0 0 16px rgba(0, 229, 255, .18) !important;
}
select option { background: #0a1020; color: #e8f1ff; }
label, .ph-form-row label, .form-group label, .uss-label {
  color: var(--nx-text-dim) !important;
  letter-spacing: .4px;
}

/* ══ 11. 徽章 / 标签：霓虹胶囊 ══════════════════════════════════════════ */
.badge, [class*="badge-"], .tag, .status-tag, .chip {
  border-radius: 999px !important;
  border: 1px solid rgba(0, 229, 255, .30) !important;
  background: rgba(0, 229, 255, .10) !important;
  color: #8ee9ff !important;
  letter-spacing: .5px;
  font-weight: 600;
  padding: 2px 10px !important;
}
.badge-success, [class*="badge-success"], .tag.outcome-已享受 {
  border-color: rgba(61,220,151,.45) !important;
  background: rgba(61,220,151,.12) !important; color: #7bf0bd !important;
}
[class*="badge-danger"], [class*="badge-error"], .tag.outcome-不符合条件 {
  border-color: rgba(255,77,109,.45) !important;
  background: rgba(255,77,109,.12) !important; color: #ff92a6 !important;
}
[class*="badge-warning"], .tag.outcome-咨询中 {
  border-color: rgba(255,176,32,.45) !important;
  background: rgba(255,176,32,.12) !important; color: #ffd28a !important;
}
/* 匹配分 / 状态色块 */
.match-score.high { background: rgba(61,220,151,.14) !important; color: #3ddc97 !important; border: 1px solid rgba(61,220,151,.35); }
.match-score.mid  { background: rgba(255,176,32,.14) !important; color: #ffb020 !important; border: 1px solid rgba(255,176,32,.35); }
.match-score.low  { background: rgba(255,77,109,.14) !important; color: #ff4d6d !important; border: 1px solid rgba(255,77,109,.35); }

/* ══ 12. 进度条 / 条形图：青紫渐变 + 末端发光 ═══════════════════════════ */
.bar-chart-fill, .progress-fill, [class*="progress-bar"] > * {
  background: linear-gradient(90deg, var(--nx-cyan), var(--nx-violet)) !important;
  box-shadow: 0 0 12px rgba(0, 229, 255, .45);
}
.bar-chart-track, .progress-track {
  background: rgba(0, 0, 0, .40) !important;
  border: 1px solid rgba(0, 229, 255, .12);
}

/* ══ 13. 链接 / 导航 / Tab ═══════════════════════════════════════════════ */
a { color: #7ddcff; transition: color .18s var(--nx-ease), text-shadow .18s var(--nx-ease); }
a:hover { color: #b8f2ff; text-shadow: 0 0 10px rgba(0, 229, 255, .55); }
.external-link, .match-source, .generated-item a { color: #7ddcff !important; }

.nav-link, .tab, [class*="tab-"] { transition: color .2s var(--nx-ease), background .2s var(--nx-ease); }
.nav-link.active, .tab.active, [class*="tab-"].active {
  position: relative;
  color: #b8f2ff !important;
  background: rgba(0, 229, 255, .10) !important;
  text-shadow: 0 0 10px rgba(0, 229, 255, .40);
}
.nav-link.active::after, .tab.active::after, [class*="tab-"].active::after {
  content: ""; position: absolute; left: 10%; right: 10%; bottom: -1px; height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--nx-cyan), var(--nx-magenta));
  box-shadow: 0 0 10px rgba(0, 229, 255, .7);
}

/* ══ 14. 模块入口卡（首页）：霓虹边框 + 悬浮抬升 ═════════════════════════ */
.module-entry {
  border: 1px solid var(--nx-line) !important;
  background: linear-gradient(158deg, rgba(13,20,40,.86), rgba(6,10,22,.72)) !important;
  border-radius: var(--nx-r) !important;
  transition: transform .25s var(--nx-ease), box-shadow .25s var(--nx-ease),
              border-color .25s var(--nx-ease);
}
@media (hover: hover) {
  .module-entry:hover {
    transform: translateY(-3px);
    border-color: var(--nx-line-hi) !important;
    box-shadow: 0 14px 38px rgba(0, 0, 0, .55), 0 0 24px rgba(0, 229, 255, .18) !important;
  }
}
.module-entry-icon {
  background: linear-gradient(135deg, rgba(0,229,255,.22), rgba(255,45,155,.16)) !important;
  border: 1px solid rgba(0, 229, 255, .28) !important;
}
.module-entry-title { color: #f2f7ff !important; }
.module-entry-desc, .module-entry-text { color: var(--nx-text-mute) !important; }
.module-entry-arrow { color: var(--nx-cyan) !important; }

/* ══ 15. 弹窗 / 浮层 ════════════════════════════════════════════════════ */
.modal.active .modal-card, .modal[style*="display: flex"] .modal-card {
  animation: nx-pop .22s var(--nx-ease);
  background: linear-gradient(158deg, rgba(14,22,44,.97), rgba(6,10,22,.95)) !important;
  border: 1px solid var(--nx-line-hi) !important;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .7), 0 0 30px rgba(0, 229, 255, .16) !important;
}
@keyframes nx-pop {
  from { opacity: 0; transform: translateY(10px) scale(.97); }
  to   { opacity: 1; transform: none; }
}
.modal::before, .modal-backdrop { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.business-panel, .side-panel, .drawer {
  background: linear-gradient(180deg, rgba(8,13,28,.97), rgba(5,8,18,.97)) !important;
  border-left: 1px solid var(--nx-line) !important;
  box-shadow: -18px 0 50px rgba(0, 0, 0, .6);
}

/* ══ 16. 空状态 / 加载 ══════════════════════════════════════════════════ */
.empty-tip, .uss-empty, .match-empty {
  color: var(--nx-text-mute) !important;
  border: 1px dashed rgba(0, 229, 255, .18) !important;
  border-radius: var(--nx-r-sm);
  background: rgba(0, 0, 0, .18);
}
.loading::before {
  border-color: rgba(0, 229, 255, .18) !important;
  border-top-color: var(--nx-cyan) !important;
  box-shadow: 0 0 10px rgba(0, 229, 255, .35);
}
.loading { color: var(--nx-text-dim) !important; }

/* ══ 17. 分割线 / 区块细节 ══════════════════════════════════════════════ */
hr, .divider { border: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(0,229,255,.28), transparent); }
.match-card-detail, .case-detail {
  border-top: 1px dashed rgba(0, 229, 255, .20) !important;
  background: rgba(0, 0, 0, .28) !important;
}

/* ══ 18. 动效降级 ═══════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  body::before { display: none; }
}

/* ══ 18b. 登录页（login.css 独立类名体系，需单独覆盖）══════════════════ */
.login-page {
  background-image:
    radial-gradient(1000px 520px at 85% -10%, rgba(0,229,255,.10), transparent 60%),
    radial-gradient(800px 460px at -8% 108%, rgba(255,45,155,.08), transparent 60%),
    repeating-linear-gradient(90deg, rgba(0,229,255,.04) 0 1px, transparent 1px 40px),
    repeating-linear-gradient(0deg, rgba(0,229,255,.04) 0 1px, transparent 1px 40px),
    linear-gradient(135deg, #0a0f1e 0%, #101a36 55%, #0a1226 100%) !important;
}
.login-card {
  background-color: transparent !important;
  background-image:
    linear-gradient(90deg, transparent, rgba(0,229,255,.85) 25%, rgba(255,45,155,.7) 75%, transparent),
    linear-gradient(158deg, rgba(13,20,40,.94), rgba(6,10,22,.90)) !important;
  background-size: 100% 2px, 100% 100% !important;
  background-position: 0 0, 0 0 !important;
  background-repeat: no-repeat !important;
  border: 1px solid var(--nx-line) !important;
  border-radius: 16px !important;
  box-shadow: var(--nx-shadow), 0 0 44px rgba(0,229,255,.10), inset 0 1px 0 rgba(255,255,255,.06) !important;
}
.login-title { text-shadow: 0 0 26px rgba(0,229,255,.35) !important; letter-spacing: 1px; }
.login-logo {
  border: 1px solid var(--nx-line) !important;
  box-shadow: 0 0 24px rgba(0,229,255,.28), inset 0 0 14px rgba(0,229,255,.12) !important;
}
.login-input {
  background: rgba(4, 8, 18, .60) !important;
  border: 1px solid rgba(0, 229, 255, .18) !important;
  color: var(--nx-text) !important;
}
.login-input:focus {
  border-color: var(--nx-cyan) !important;
  background: rgba(0, 229, 255, .06) !important;
  box-shadow: 0 0 0 2px rgba(0, 229, 255, .24), 0 0 18px rgba(0, 229, 255, .18) !important;
}
.login-btn {
  background: linear-gradient(120deg, #0aa2c0 0%, #1f4fd8 52%, #6d28d9 100%) !important;
  border: 1px solid rgba(0, 229, 255, .40) !important;
  box-shadow: 0 4px 22px rgba(0, 160, 210, .35), inset 0 1px 0 rgba(255,255,255,.15) !important;
  letter-spacing: 2px;
}
@media (hover: hover) {
  .login-btn:hover { box-shadow: 0 6px 30px rgba(0, 229, 255, .45), inset 0 1px 0 rgba(255,255,255,.2) !important; filter: brightness(1.1); }
}

/* ══ 19. 手机端：降低氛围层开销，保留已完成的适配 ═══════════════════════ */
@media (max-width: 600px) {
  body::before { display: none; }               /* 关闭扫描光束动画，省电 */
  .ph-card, .card, .stat-card, .kpi-card, .chart-box {
    border-radius: 8px !important;
    box-shadow: 0 6px 20px rgba(0, 0, 0, .45) !important;
  }
}

/* ============================================================================
   ══ 20. 移动端布局修复（2026-09-13 实测定位的 4 类堆叠根因，勿删）══════════
   ① 固定多列 grid 无断点（park-management .pm-grid 3 列 → 每列 118px 文字竖排）
   ② flex 行不换行（inbox 标签被压 14px、call-history 标题被压 62px）
   ③ 横滑表格无 min-width / td 换行（policy-hub 列 69px、activity-processor 3 行竖排）
   ④ 输入框 <16px 触发 iOS 聚焦缩放、常用触控目标 <36px
   ========================================================================== */
@media (max-width: 600px) {
  /* 20.1 固定多列网格窄屏降级 */
  .pm-grid { grid-template-columns: 1fr !important; gap: 12px; }
  .pm-main { padding: 14px !important; }
  .pm-card { padding: 16px !important; }

  /* 20.2 flex 标签行：允许换行、禁止压缩 */
  .inbox-item-meta { flex-wrap: wrap; row-gap: 4px; }
  .inbox-item-meta > * { white-space: nowrap; }

  /* 20.3 页头：允许换行，标题不收缩 */
  .call-history-header { flex-wrap: wrap; row-gap: 8px; padding: 12px 16px !important; }
  .call-history-header-title { white-space: nowrap; font-size: 19px !important; }
  .call-history-header-actions { flex-wrap: wrap; row-gap: 8px; }

  /* 20.4 横滑表格修复 */
  .policy-hub-grid > * { min-width: 0; }
  .case-table { min-width: 780px; }
  .case-table-wrap { -webkit-overflow-scrolling: touch; }
  [style*="overflow-x"] > table td { white-space: nowrap; }
  .table-scroll td { white-space: nowrap; }

  /* 20.5 输入框 16px —— 防 iOS 聚焦自动放大 */
  input, select, textarea { font-size: 16px !important; }

  /* 20.6 常用触控目标 ≥42px */
  .btn, .inbox-filter, .pm-btn, .tab, [class*="filter-btn"], [class*="tab-btn"] {
    min-height: 42px;
  }

  /* 20.7 投诉画像居民卡 */
  .complaint-resident-item { flex-wrap: wrap; }
  .complaint-resident-count { order: 3; margin-left: 64px; }
  .complaint-resident-info { flex: 1 1 auto; min-width: 0; }

  /* 20.8 弹窗贴边保护 */
  .modal-card, .access-card { max-width: calc(100vw - 24px) !important; }
}

/* ============================================================================
   ══ 21. 智能体动感增强层配套样式（配合 js/agent-motion.js）════════════════
   ① 顶部 AI 处理进度条  ② 鼠标跟随光斑  ③ 卡片入场  ④ 按钮涟漪  ⑤ 悬浮脉冲
   全部尊重 prefers-reduced-motion：脚本在该偏好下直接不启动，这里再兜底关掉
   ========================================================================== */

/* ① 顶部 AI 处理进度条 */
.nx-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 9999;
  pointer-events: none; overflow: hidden; opacity: 0;
  transition: opacity .25s var(--nx-ease);
  background: rgba(0, 0, 0, .35);
}
.nx-progress.on { opacity: 1; }
.nx-progress > i {
  display: block; height: 100%; width: 32%;
  background: linear-gradient(90deg, transparent, var(--nx-cyan) 35%, var(--nx-magenta) 70%, transparent);
  box-shadow: 0 0 14px rgba(0, 229, 255, .85);
  animation: nx-prog 1.1s ease-in-out infinite;
}
.nx-progress > i.done {
  width: 100%; animation: none;
  transition: width .28s var(--nx-ease), opacity .3s var(--nx-ease) .18s;
  opacity: 0;
}
@keyframes nx-prog {
  0%   { transform: translateX(-110%); }
  100% { transform: translateX(420%); }
}

/* ② 鼠标跟随光斑（仅桌面精确指针；screen 混合只提亮、不压暗文字）
      外层 .nx-spot-wrap 为 fixed+overflow:hidden，隔离布局、杜绝撑宽文档 */
.nx-spot-wrap {
  position: fixed; inset: 0; z-index: 9998;
  pointer-events: none; overflow: hidden;
}
.nx-spotlight {
  position: absolute; top: 0; left: 0; width: 600px; height: 600px;
  pointer-events: none; mix-blend-mode: screen;
  opacity: 0; transition: opacity .4s var(--nx-ease);
  transform: translate3d(-9999px, -9999px, 0);
  background: radial-gradient(circle closest-side,
    rgba(0, 229, 255, .10), rgba(124, 92, 255, .05) 45%, transparent 72%);
}
.nx-spotlight.on { opacity: 1; }

/* ③ 卡片入场 */
@keyframes nx-rise {
  from { opacity: 0; transform: translateY(14px) scale(.985); }
  to   { opacity: 1; transform: none; }
}
.nx-rise { animation: nx-rise .55s var(--nx-ease) both; }

/* ④ 按钮涟漪（脚本注入 <span class="nx-ripple">） */
button, .btn, .ph-btn, .pm-btn, .login-btn, .submit-btn {
  position: relative; overflow: hidden;
}
.nx-ripple {
  position: absolute; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(0, 229, 255, .50), rgba(0, 229, 255, 0) 70%);
  transform: scale(0); opacity: .9;
  animation: nx-ripple .62s ease-out forwards;
}
@keyframes nx-ripple { to { transform: scale(1); opacity: 0; } }

/* ⑤ 悬浮球呼吸脉冲 */
.business-fab { position: relative; }
.business-fab::before {
  content: ""; position: absolute; inset: -6px; border-radius: 50%;
  border: 1px solid rgba(0, 229, 255, .55); pointer-events: none;
  animation: nx-ping 2.8s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes nx-ping {
  0%   { transform: scale(.86); opacity: .75; }
  70%  { transform: scale(1.28); opacity: 0; }
  100% { transform: scale(1.28); opacity: 0; }
}

/* 兜底：系统开启"减少动态效果"时全部静默 */
@media (prefers-reduced-motion: reduce) {
  .nx-progress, .nx-spotlight { display: none !important; }
  .business-fab::before { animation: none; display: none; }
  .nx-rise { animation: none !important; }
}

/* ============================================================================
   ══ 22. 智能体 3D 形象 · 待机/忙碌双态动效（配合 agent-motion.js ⓻）════════
   待机：偶尔歪头好奇（错峰循环，大部分时间静止）
   忙碌：加速摇摆 + 提亮 + 旋转霓虹光环 + 底部流光 + 卡片角标三点
   ========================================================================== */

/* 基础：3D 形象图填充容器（含聊天头部 42px 小图） */
.agent-avatar-img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center top;
  display: block;
}

/* ── 待机：歪头好奇（6.5s 循环，仅前 78% 时间静止，错峰启动）── */
@keyframes nx-idle-tilt {
  0%, 76%   { transform: translateY(0) rotate(0deg); }
  81%       { transform: translateY(-2px) rotate(3.2deg); }
  87%       { transform: translateY(-1px) rotate(-2.2deg); }
  93%, 100% { transform: translateY(0) rotate(0deg); }
}
.agent-card .agent-avatar .agent-avatar-img {
  animation: nx-idle-tilt 6.5s ease-in-out infinite;
  will-change: transform;
}
.agent-card:nth-of-type(2) .agent-avatar .agent-avatar-img { animation-delay: 2.2s; }
.agent-card:nth-of-type(3) .agent-avatar .agent-avatar-img { animation-delay: 4.3s; }

/* ── 忙碌：卖力摇摆 + 提亮 ── */
@keyframes nx-busy-wiggle {
  0%   { transform: rotate(-2.6deg) translateY(0); }
  25%  { transform: rotate(0deg) translateY(-3px); }
  50%  { transform: rotate(2.6deg) translateY(0); }
  75%  { transform: rotate(0deg) translateY(-3px); }
  100% { transform: rotate(-2.6deg) translateY(0); }
}
.agent-avatar.is-busy .agent-avatar-img,
.chat-agent-avatar.is-busy .agent-avatar-img {
  animation: nx-busy-wiggle .62s ease-in-out infinite !important;
  filter: brightness(1.14) saturate(1.06);
}

/* ── 忙碌：容器内旋转霓虹光环（inset 0，不越界）── */
@keyframes nx-busy-ring { to { transform: rotate(360deg); } }
.agent-avatar.is-busy::before,
.chat-agent-avatar.is-busy::before {
  content: "";
  position: absolute; inset: 0; z-index: 3;
  border-radius: inherit; padding: 2px;
  background: conic-gradient(from 0deg,
    transparent 0%, transparent 38%,
    var(--nx-cyan, #00e5ff) 50%, var(--nx-magenta, #ff2d9b) 62%,
    transparent 72%, transparent 100%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
          mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
          mask-composite: exclude;
  animation: nx-busy-ring 1.1s linear infinite;
  pointer-events: none;
}

/* ── 忙碌：底部流光扫过 ── */
@keyframes nx-busy-scan { 0% { transform: translateX(-110%); } 100% { transform: translateX(280%); } }
.agent-avatar.is-busy::after,
.chat-agent-avatar.is-busy::after {
  content: "";
  position: absolute; left: 0; bottom: 0; height: 3px; width: 45%;
  z-index: 3; pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--nx-cyan, #00e5ff) 40%, var(--nx-magenta, #ff2d9b) 70%, transparent);
  animation: nx-busy-scan 1.15s ease-in-out infinite;
}

/* ── 忙碌：卡片右上角三点工作角标（JS 注入 .nx-busy-badge）── */
.nx-busy-badge {
  position: absolute; top: 10px; right: 10px; z-index: 4;
  display: flex; gap: 3px; align-items: center;
  padding: 5px 7px; border-radius: 20px;
  background: rgba(6, 10, 20, .74);
  border: 1px solid rgba(0, 229, 255, .4);
  box-shadow: 0 0 10px rgba(0, 229, 255, .18);
  pointer-events: none;
}
.nx-busy-badge i {
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--nx-cyan, #00e5ff);
  animation: nx-dot .9s ease-in-out infinite;
}
.nx-busy-badge i:nth-child(2) { animation-delay: .15s; background: #7df0ff; }
.nx-busy-badge i:nth-child(3) { animation-delay: .3s;  background: var(--nx-magenta, #ff2d9b); }
@keyframes nx-dot {
  0%, 100% { transform: translateY(0);    opacity: .45; }
  50%      { transform: translateY(-4px); opacity: 1; }
}

/* 兜底：系统"减少动态效果"时保留状态指示但全部静默 */
@media (prefers-reduced-motion: reduce) {
  .agent-card .agent-avatar .agent-avatar-img,
  .agent-avatar.is-busy .agent-avatar-img,
  .chat-agent-avatar.is-busy .agent-avatar-img { animation: none !important; }
  .agent-avatar.is-busy::before,
  .chat-agent-avatar.is-busy::before { animation: none !important; }
  .agent-avatar.is-busy::after,
  .chat-agent-avatar.is-busy::after,
  .nx-busy-badge i { animation: none !important; }
}

/* ============================================================================
   ══ 23. 立体深度层 v3（该立体的立体，不该立体的保持平面）══════════════════
   配方：每个"实体"都由四层光构成——
         ① 顶棱高光（受光面）② 底棱暗边（背光面）③ 接触影（贴地）④ 环境影（景深）
   ── 该立体（是有体量的"物件"）──────────────────────────────────────────
        · 卡片 / 面板：立体板材，多层景深
        · 按钮：键帽厚度 + 按压下沉
        · KPI 统计数字：挤出式厚度
        · 模块入口卡：图标底座浮雕凸起 + 悬浮微倾
        · 智能体 3D 形象：凹槽 + 落地投影（让它"站住"而不是贴片）
        · 弹窗：强景深 + 边缘光环
        · 进度条：体积感（顶部高光 + 底部暗边）
   ── 不该立体（是"内容"，立体化只会干扰阅读）────────────────────────────
        · 表格 / 表格行：保持平面，只做行悬浮微光
        · 输入框 / 文本域：保持平面，只有聚焦光晕（键帽厚度会让表单变花）
        · 正文 / 链接 / 徽章 / Tab / 顶栏：保持平面
   ========================================================================== */

/* ── 23.1 卡片 / 面板：立体板材（四层光）── */
.ph-card,
.card,
.stat-card,
.kpi-card,
.chart-card,
.chart-box,
.chart-container,
.panel,
.modal-card,
.match-card,
.cluster-card,
.pm-card {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .07),   /* ① 顶棱高光 */
    inset 0 -1px 0 rgba(0, 0, 0, .38),        /* ② 底棱暗边 */
    0 2px 4px rgba(0, 0, 0, .40),             /* ③ 接触影 */
    0 12px 28px -8px rgba(0, 0, 0, .60),      /* ④ 近景环境影 */
    0 30px 64px -24px rgba(0, 0, 0, .52) !important;
}
@media (hover: hover) and (min-width: 601px) {
  .ph-card:hover, .card:hover, .stat-card:hover, .kpi-card:hover,
  .chart-card:hover, .chart-box:hover, .chart-container:hover,
  .match-card:hover, .cluster-card:hover {
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .10),
      inset 0 -1px 0 rgba(0, 0, 0, .38),
      0 6px 12px rgba(0, 0, 0, .42),
      0 20px 44px -10px rgba(0, 0, 0, .66),
      0 44px 90px -28px rgba(0, 0, 0, .58),
      0 0 26px rgba(0, 229, 255, .14) !important;
  }
}

/* ── 23.2 小型独立卡：悬浮时轻微 3D 微倾（幅度极小，避免 created containing
       block 影响内部绝对定位元素，故仅作用于叶子型卡片 + 仅桌面精确指针）── */
@media (hover: hover) and (min-width: 601px) {
  .module-entry,
  .agent-card,
  .stat-card {
    transform: perspective(900px) translateY(0) rotateX(0deg) rotateY(0deg);
    transition: transform .28s var(--nx-ease), box-shadow .28s var(--nx-ease),
                border-color .28s var(--nx-ease);
  }
  .module-entry:hover {
    transform: perspective(900px) translateY(-5px) rotateX(1.6deg) rotateY(-1.1deg);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .10),
      inset 0 -1px 0 rgba(0, 0, 0, .40),
      0 8px 14px rgba(0, 0, 0, .44),
      0 22px 46px -12px rgba(0, 0, 0, .68),
      0 0 30px rgba(0, 229, 255, .18) !important;
  }
  .agent-card:hover,
  .stat-card:hover {
    transform: perspective(900px) translateY(-4px) rotateX(1.3deg) rotateY(-.9deg);
  }
}

/* ── 23.3 按钮：键帽厚度（底边实色 = 厚度，顶面高光 = 受光）── */
.btn-primary, .ph-btn-primary, button[class*="primary"], .submit-btn,
.login-btn {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .30),   /* ① 顶面高光 */
    inset 0 -1px 0 rgba(0, 0, 0, .30),        /* ② 底棱暗边 */
    0 2px 0 rgba(3, 8, 18, .58),              /* ③ 键帽厚度（实色底边）*/
    0 6px 18px rgba(0, 160, 210, .34) !important;
}
.btn-primary:active, .ph-btn-primary:active,
button[class*="primary"]:active, .submit-btn:active, .login-btn:active {
  transform: translateY(2px) !important;     /* 按压：下沉一个厚度的高度 */
  box-shadow:
    inset 0 2px 5px rgba(0, 0, 0, .45),
    0 0 0 rgba(3, 8, 18, .58),                /* 厚度被压掉 */
    0 2px 8px rgba(0, 160, 210, .26) !important;
}
/* 次级按钮：同样给厚度，但更薄、无光晕 */
.ph-btn-secondary, .btn-secondary, .btn, .ph-btn, .pm-btn {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .07),
    inset 0 -1px 0 rgba(0, 0, 0, .32),
    0 2px 0 rgba(3, 8, 18, .48),
    0 4px 12px rgba(0, 0, 0, .34) !important;
}
.ph-btn-secondary:active, .btn-secondary:active,
.btn:active, .ph-btn:active, .pm-btn:active {
  transform: translateY(2px) !important;
  box-shadow:
    inset 0 2px 4px rgba(0, 0, 0, .42),
    0 0 0 rgba(3, 8, 18, .48),
    0 1px 5px rgba(0, 0, 0, .30) !important;
}
.ph-btn-success {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .28),
    inset 0 -1px 0 rgba(0, 0, 0, .28),
    0 2px 0 rgba(3, 8, 18, .52),
    0 5px 16px rgba(61, 220, 151, .28) !important;
}

/* ── 23.4 KPI / 统计数字：挤出式厚度（drop-shadow 可作用于渐变裁字）── */
.stat-card .value, .stat-value, .stat-card .num, .kpi-value,
.stat .value, .stat .num {
  filter:
    drop-shadow(0 1px 0 rgba(3, 8, 18, .85))
    drop-shadow(0 2px 1px rgba(3, 8, 18, .55))
    drop-shadow(0 0 12px rgba(0, 229, 255, .32)) !important;
}

/* ── 23.5 模块入口：图标底座浮雕凸起（内高光 + 内暗边 = 圆盘的厚度）── */
.module-entry-icon {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .20),   /* 凸面受光 */
    inset 0 -3px 6px rgba(0, 0, 0, .34),      /* 底部凹进 */
    0 3px 7px rgba(0, 0, 0, .42),             /* 底座投影 */
    0 0 16px rgba(0, 229, 255, .16) !important;
}
.module-entry {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .07),
    inset 0 -1px 0 rgba(0, 0, 0, .38),
    0 2px 4px rgba(0, 0, 0, .40),
    0 12px 28px -8px rgba(0, 0, 0, .58),
    0 28px 60px -24px rgba(0, 0, 0, .50) !important;
}

/* ── 23.6 智能体 3D 形象：凹槽 + 落地投影（让它"站"在卡片里）── */
.agent-avatar,
.chat-agent-avatar {
  box-shadow:
    inset 0 -12px 20px -12px rgba(0, 0, 0, .62),   /* 底部内暗 = 站立阴影 */
    inset 0 1px 0 rgba(255, 255, 255, .10),        /* 上沿受光 */
    inset 0 0 0 1px rgba(0, 229, 255, .14),        /* 内壁霓虹描边 */
    0 8px 20px -8px rgba(0, 0, 0, .58),
    0 0 22px rgba(0, 229, 255, .10) !important;
}
.agent-card .agent-avatar-img,
.chat-agent-avatar .agent-avatar-img {
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .48)) !important;
}
/* 忙碌态已有 brightness/saturate，这里叠加落地投影（写在后面覆盖）*/
.agent-avatar.is-busy .agent-avatar-img,
.chat-agent-avatar.is-busy .agent-avatar-img {
  filter: brightness(1.14) saturate(1.06)
          drop-shadow(0 6px 12px rgba(0, 0, 0, .52)) !important;
}

/* ── 23.7 弹窗：强景深 + 边缘光环 ── */
.modal.active .modal-card,
.modal[style*="display: flex"] .modal-card {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .10),
    inset 0 -1px 0 rgba(0, 0, 0, .42),
    0 6px 14px rgba(0, 0, 0, .48),
    0 30px 70px -14px rgba(0, 0, 0, .78),
    0 60px 130px -40px rgba(0, 0, 0, .62),
    0 0 46px rgba(0, 229, 255, .16) !important;
}

/* ── 23.8 进度条 / 条形：体积感（顶部高光 + 底部暗边）── */
.bar-chart-fill, .progress-fill, [class*="progress-bar"] > * {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .38),
    inset 0 -1px 0 rgba(0, 0, 0, .28),
    0 0 14px rgba(0, 229, 255, .45) !important;
}

/* ── 23.9 明确保持平面的部分（防止后续被通用规则误伤，写在这里作为约定）──
   表格、输入框、链接、徽章、下拉、正文 —— 一律不加厚度与倾斜： */
table, thead, tbody, tr, th, td,
input, select, textarea, .ph-input, .ph-select, .ph-textarea,
.form-input, .form-control,
a, .badge, .tag, .chip, .status-tag,
.nav-link, .tab, .top-bar, .policy-hub-header, header, .header {
  box-shadow: none;
  transform: none;
}
/* 例外：输入框聚焦时的霓虹光晕仍需保留（平面 + 发光，不是立体）*/
input:focus, select:focus, textarea:focus,
.ph-input:focus, .ph-select:focus, .ph-textarea:focus {
  box-shadow: 0 0 0 2px rgba(0, 229, 255, .22), 0 0 16px rgba(0, 229, 255, .18) !important;
}
/* 徽章是"贴纸"，只留极薄一层内高光，保持贴附感 */
.badge, [class*="badge-"], .tag, .status-tag, .chip {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .10) !important;
}

/* ============================================================================
   ══ 24. 手机端收尾（立体降级 + 触控达标 + 固定宽修复）════════════════════
   原则：手机上不追求"悬浮微倾"（没有 hover），但保留静态立体（厚度/高光），
         同时收敛阴影半径以省电；交互元素一律 ≥42px 触控。
   ========================================================================== */
@media (max-width: 600px) {
  /* 24.1 关闭悬浮微倾与大范围阴影（省电 + 触屏无 hover）*/
  .module-entry, .agent-card, .stat-card { transform: none !important; }
  .module-entry:active, .agent-card:active, .stat-card:active { transform: scale(.985) !important; }
  .ph-card, .card, .stat-card, .kpi-card, .chart-card, .chart-box,
  .match-card, .pm-card, .module-entry {
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .06),
      inset 0 -1px 0 rgba(0, 0, 0, .34),
      0 2px 4px rgba(0, 0, 0, .38),
      0 8px 18px -8px rgba(0, 0, 0, .52) !important;
  }

  /* 24.2 news 页：1080px 固定宽在 390 视口被裁掉右侧内容（实测 121 处溢出）*/
  .news-main {
    width: 100% !important;
    max-width: 100% !important;
    flex: 1 1 100% !important;
    box-sizing: border-box;
  }
  .news-toolbar { flex-wrap: wrap !important; row-gap: 8px; }
  .news-search { flex: 1 1 100% !important; min-width: 0 !important; }
  .news-filter { min-width: 0 !important; flex: 1 1 120px !important; }
  .news-refresh, .news-top { flex: 0 0 auto !important; }

  /* 24.3 触控目标 ≥42px：按钮、图标按钮、下拉、工具条控件 */
  button, .btn, .ph-btn, .pm-btn, .header-btn, .icon-btn,
  .policy-hub-back, .voice-btn, .search-toggle, .news-refresh, .news-top,
  .back-btn, [role="button"] {
    min-height: 42px;
    min-width: 42px;
  }
  /* 宽度过窄的补到 42（如 🎤 语音键实测 11×44、🗑 删除键 36×42）*/
  .voice-btn, .header-btn, .policy-hub-back, .icon-btn, .back-btn,
  .btn-sm, .btn-icon {
    min-width: 42px;
    padding-left: 8px; padding-right: 8px;
  }
  /* 下拉、搜索框、各类输入框：高度不足会误触
     （实测 40px 的访客输入框 / 月卡输入框差 2px，统一兜到 42）*/
  input, select, textarea,
  .search-toggle, .news-filter, .news-search,
  .form-input, .form-control, .ph-input, .ph-select,
  .visitor-input {
    min-height: 42px;
  }
  /* 内联 flex 行允许换行 —— 只在放不下时才换，宽屏不受影响。
     （实测 activity-processor 的「日期 + 文字 + 输入框」挤在 390 宽里，
       把输入框压到 26px / 39px）*/
  div[style*="display:flex"], div[style*="display: flex"] { flex-wrap: wrap !important; }
  /* 输入框保底 160px，配合上面的换行，放不下就整行独占 */
  .form-input, .form-control, .ph-input, .visitor-input {
    flex: 1 1 160px !important;
    min-width: 0;
  }
  /* 可点击容器（非 button 标签的 Tab / 示例词 / 卡片）同样给足热区 */
  div[onclick], span[onclick], li[onclick],
  .uss-tab, [class*="-tab"]:not([class*="table"]) {
    min-height: 42px;
  }

  /* 24.3b 内联固定多列 grid 窄屏降为单列
     （实测：activity-processor 的 grid-template-columns:1fr 1fr 在 390 宽下
       把输入框压到 26px、label 压成竖排换行）*/
  [style*="grid-template-columns"] { grid-template-columns: 1fr !important; }
  [style*="grid-template-columns"] > * { min-width: 0; }
  .form-group { min-width: 0; }
  .form-group > * { min-width: 0; }

  /* 24.4 复选框 / 单选：视觉放大到 22px（不撑爆布局），热区随之扩大 */
  input[type="checkbox"], input[type="radio"] {
    width: 22px; height: 22px; min-width: 22px; min-height: 22px;
  }
}
