/* hx-style-29.css — 锁电量通知：按实际条数显示 + 底部提示贴底（终版）
   2026-11-12
   用户要求：该显示多少显示多少，可以拖动
   根因：.chart-item 实际是 display:block，不是 flex
        → 面板的 flex:1 与底部提示的 margin-top:auto 全部失效
   修复：用 :has() 只把「含锁电量面板」的那张卡改成 flex column，不影响水电用量趋势卡
*/

/* 只对锁电量卡启用 flex 纵向布局 */
.charts-grid .chart-item:has(.hx-dn-panel) {
  display: flex !important;
  flex-direction: column !important;
  box-sizing: border-box !important;
}

/* 面板撑满卡片剩余高度，底部提示才能贴底 */
.charts-grid .chart-item:has(.hx-dn-panel) .hx-dn-panel {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
  margin-top: 0 !important;
}

/* 列表：高度跟条数走，最多 7 行（259px），超过才滚动 */
.charts-grid .chart-item:has(.hx-dn-panel) .hx-dn-list {
  flex: 0 1 auto !important;
  max-height: 259px !important;
  min-height: 0 !important;
  height: auto !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  scrollbar-width: thin;
}

/* 汇总条：不参与伸缩 */
.charts-grid .chart-item:has(.hx-dn-panel) .hx-dn-sum {
  flex: 0 0 auto !important;
  padding: 5px 8px !important;
  font-size: 11.5px !important;
  line-height: 16px !important;
}

/* 底部阈值提示：贴卡片最底下 */
.charts-grid .chart-item:has(.hx-dn-panel) .hx-dn-foot {
  flex: 0 0 auto !important;
  margin-top: auto !important;
  padding: 4px 2px 0 !important;
  font-size: 10.5px !important;
  line-height: 14px !important;
  border-top: 1px dashed #eef0f3 !important;
}
