#hero-status-hud {
  position: fixed; left: 50%; bottom: 188px; transform: translateX(-50%);
  width: 350px; display: flex; justify-content: center; align-items: flex-end; gap: 5px;
  pointer-events: none; user-select: none; z-index: 26;
  color: #f5edda; font: 11px/1.25 "Microsoft YaHei", system-ui, sans-serif;
}
#hero-status-hud[hidden], #hero-status-hud [hidden] { display: none !important; }
.status-effects-debuffs { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px; width: 100%; }
.status-effects-buffs { display: flex; flex-direction: column; gap: 4px; width: 218px; }
.status-effect {
  --status-color: #d6b978; display: flex; align-items: center; gap: 7px; box-sizing: border-box;
  width: 100%; min-width: 0; min-height: 38px; padding: 5px 8px;
  border-radius: 6px; background: rgba(18, 27, 31, .88); box-shadow: 0 2px 7px #0005;
}
.status-effect[data-kind="debuff"] { --status-color: #e591ab; width: calc(33.333% - 4px); min-height: 32px; padding: 4px 5px; gap: 5px; box-shadow: inset 2px 0 #b5728f, 0 2px 7px #0005; }
.status-effect[data-kind="debuff"] .status-effect-icon { width: 22px; height: 22px; flex-basis: 22px; }
.status-effect[data-kind="debuff"] .status-effect-detail { display: none; }
.status-effect-icon { width: 26px; height: 26px; flex: 0 0 26px; object-fit: cover; border-radius: 4px; }
.status-effect-content { flex: 1; min-width: 0; }
.status-effect-line { display: flex; align-items: center; justify-content: space-between; gap: 5px; }
.status-effect-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.status-effect-time { font-variant-numeric: tabular-nums; white-space: nowrap; flex: 0 0 auto; }
.status-effect-stacks, .status-effect-compact-time { display: none; }
.status-effect[data-timer-mode="next-stack"] .status-effect-line { flex-wrap: wrap; gap: 2px 5px; }
.status-effect[data-timer-mode="next-stack"] .status-effect-name { flex: 0 0 auto; }
.status-effect[data-timer-mode="next-stack"] .status-effect-time { flex: 0 1 auto; min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; font-weight: 600; }
.status-effect-track { height: 3px; margin-top: 5px; overflow: hidden; border-radius: 2px; background: #82929436; }
.status-effect-fill { width: 100%; height: 100%; background: var(--status-color); transform-origin: left center; }
.status-effect-detail { display: block; margin-top: 3px; color: #c2c9c3; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.status-effect.ending { --status-color: #f0b16c; }
.status-effect.ending .status-effect-time { color: #ffdba5; }
.status-effect.ending .status-effect-icon { filter: brightness(1.12); }
.status-effects-overflow { color: #e4d6b9; font-size: 10px; text-shadow: 0 1px 3px #000; }
#hero-status-hud .status-effects-debuffs, #hero-status-hud .status-effects-buffs { flex: 0 0 auto; flex-flow: row nowrap; gap: 3px; width: auto; }
#hero-status-hud .status-effect {
  position: relative; flex: 0 0 36px; flex-direction: column; gap: 1px; width: 36px; min-height: 42px;
  padding: 2px; background: rgba(18, 27, 31, .5); border-radius: 4px; box-shadow: none;
}
#hero-status-hud .status-effect[data-kind="debuff"] { box-shadow: inset 0 -2px #b5728f; }
#hero-status-hud .status-effect-icon { width: 24px; height: 24px; flex-basis: 24px; }
#hero-status-hud .status-effect-content { display: none; }
#hero-status-hud .status-effect-compact-time { display: block; font-size: 10px; line-height: 12px; white-space: nowrap; font-variant-numeric: tabular-nums; }
#hero-status-hud .status-effect-stacks { position: absolute; top: 0; right: 0; display: block; padding: 0 2px; border-radius: 2px; background: #10202be6; color: #f8e9bd; font: bold 9px/12px system-ui, sans-serif; }
#hero-status-hud .status-effect.ending .status-effect-compact-time { color: #ffdba5; }
#hero-status-hud .status-effects-overflow { flex: 0 0 auto; align-self: center; min-width: 20px; text-align: center; }
#hero-status-details { grid-column: 1 / -1; margin: 8px 0; color: #f5edda; font: 11px/1.4 "Microsoft YaHei", system-ui, sans-serif; }
#hero-status-details[hidden] { display: none !important; }
#hero-status-details > summary { padding: 5px 0; color: #d6b978; cursor: pointer; }
#hero-status-panel { display: flex; flex-direction: column; gap: 5px; margin-top: 5px; }
#hero-status-panel[hidden], #hero-status-panel [hidden] { display: none !important; }
#hero-status-panel .status-effects-debuffs, #hero-status-panel .status-effects-buffs { flex-direction: column; width: 100%; gap: 4px; }
#hero-status-panel .status-effect { width: 100%; }
#hero-status-panel .status-effect[data-kind="debuff"] .status-effect-detail { display: block; }
body.mobile-layout #hero-status-hud {
  bottom: calc(var(--mobile-edge-bottom) + 10px); width: min(350px, calc(100vw - 400px));
}
body.mobile-layout.mobile-panel-open #hero-status-hud { visibility: hidden; }
@media (max-width: 760px) and (orientation: landscape) {
  body.mobile-layout #hero-status-hud { width: min(350px, calc(100vw - 340px)); }
}
@media (max-width: 680px) and (orientation: landscape) {
  body.mobile-layout #hero-status-hud { width: min(320px, calc(100vw - 376px)); gap: 4px; }
  body.mobile-layout .status-effects-debuffs { gap: 4px; }
  body.mobile-layout .status-effect[data-kind="debuff"] { width: calc(33.333% - 3px); padding: 4px; gap: 3px; }
  body.mobile-layout .status-effect[data-kind="debuff"] .status-effect-icon { width: 20px; height: 20px; flex-basis: 20px; }
  body.mobile-layout #hero-status-hud .status-effect { flex-basis: 32px; width: 32px; min-height: 38px; }
  body.mobile-layout #hero-status-hud .status-effect-icon { width: 22px; height: 22px; flex-basis: 22px; }
}
@media (max-width: 620px) and (orientation: landscape) {
  body.mobile-layout .status-effect[data-kind="debuff"] { width: calc(50% - 2px); }
}
@media (prefers-reduced-motion: no-preference) {
  .status-effect { animation: status-effect-appear .16s ease-out; }
  @keyframes status-effect-appear { from { opacity: 0; } to { opacity: 1; } }
}
