#khLiveRoot #khModelHeat {
  position: fixed; z-index: 24; inset: auto max(24px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) auto;
  display: flex; flex-direction: column; align-items: flex-end; gap: 10px;
  max-width: calc(100vw - 32px); color: var(--fg); line-height: 1.5;
}
#khModelHeat .kh-heat-panel {
  order: -1; display: flex; flex-direction: column; width: min(396px, calc(100vw - 32px));
  max-height: min(530px, calc(100dvh - 105px)); overflow: hidden;
  border: 1px solid var(--line); border-radius: 20px;
  background: var(--panel); box-shadow: 0 14px 38px rgba(0,0,0,.21);
}
#khModelHeat .kh-heat-header {
  display: flex; flex: none; align-items: center; justify-content: space-between; gap: 14px;
  padding: 15px 16px 11px; border-bottom: 1px solid var(--line);
}
#khModelHeat .kh-heat-header h2 { margin: 0; font-size: 17px; font-weight: 750; line-height: 1.35; }
#khModelHeat p { margin: 0; }
#khModelHeat .kh-heat-header p, #khModelHeat .kh-heat-footer { color: var(--muted); font-size: 12px; }
#khModelHeat .kh-heat-header p { margin-top: 4px; }
body.khn#khLiveRoot#khLiveRoot#khLiveRoot #khModelHeat .kh-heat-refresh {
  flex: none; min-height: 36px; padding: 5px 10px; border: 1px solid var(--line) !important;
  border-radius: 10px; background: var(--panel-soft) !important; font-size: 12px !important; font-weight: 650 !important;
}
#khModelHeat .kh-heat-refresh[aria-disabled=true] { opacity: .65; }
#khModelHeat .kh-heat-content { min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; padding: 4px 12px 4px 16px; }
#khModelHeat .kh-heat-list { margin: 0; padding: 0; list-style: none; }
#khModelHeat .kh-heat-status { padding: 14px 0; color: var(--muted); font-size: 13px; }
#khModelHeat .kh-heat-status:empty { padding: 0; }
#khModelHeat .kh-heat-row {
  display: grid; grid-template-columns: 25px minmax(0, 1fr) auto; align-items: start;
  column-gap: 9px; padding: 9px 0; border-bottom: 1px solid var(--line);
}
#khModelHeat .kh-heat-row:last-child { border-bottom: 0; }
#khModelHeat .kh-heat-rank {
  display: grid; place-items: center; min-height: 24px; border-radius: 7px;
  background: var(--panel-soft); color: var(--muted); font-weight: 700; font-size: 12px;
}
#khModelHeat .kh-heat-top { background: var(--accent-soft); color: var(--fg); }
#khModelHeat .kh-heat-name { display: block; font-size: 13px; font-weight: 650; overflow-wrap: anywhere; }
#khModelHeat .kh-heat-kind, #khModelHeat .kh-heat-rate { display: block; font-size: 12px; color: var(--muted); }
#khModelHeat .kh-heat-metrics { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
#khModelHeat .kh-heat-average { display: block; font-size: 12px; font-weight: 750; }
#khModelHeat .kh-heat-footer { flex: none; border-top: 1px solid var(--line); padding: 10px 16px 12px; }
#khModelHeat .kh-heat-window, #khModelHeat .kh-heat-time { margin-top: 4px; font-variant-numeric: tabular-nums; }
body.khn#khLiveRoot#khLiveRoot#khLiveRoot #khModelHeat .kh-heat-toggle {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px;
  border: 1px solid var(--line) !important; border-radius: 99px; background: var(--panel) !important;
  color: var(--fg) !important; box-shadow: 0 4px 18px rgba(0,0,0,.18); font-size: 13px !important; font-weight: 750 !important;
}
#khModelHeat .kh-heat-toggle > svg:first-child { color: var(--accent); }
#khModelHeat .kh-heat-toggle[aria-expanded=true] .kh-heat-chevron { transform: rotate(180deg); }
#khModelHeat .kh-heat-content:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
#khModelHeat button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
@media (max-width: 820px) {
  #khLiveRoot #khModelHeat {
    position: static; max-width: 100%; margin: 32px 0 0;
  }
  #khModelHeat .kh-heat-panel { order: 0; width: min(396px, 100%); max-height: min(490px, calc(100dvh - 82px)); }
}


