.run-hud {
  position: fixed;
  top: max(8px, env(safe-area-inset-top));
  left: 8px;
  right: 6px;
  z-index: 100012;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 7px;
  pointer-events: none;
  font-family: Inter, ui-rounded, "Arial Rounded MT Bold", system-ui, sans-serif;
  font-variant-numeric: tabular-nums;
  opacity: 0;
  visibility: hidden;
  transition: opacity .28s ease;
}

body.vx-ready .run-hud {
  opacity: 1;
  visibility: visible;
}

.run-hud-card {
  min-width: 0;
  min-height: 58px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 7px 10px 8px;
  overflow: hidden;
  border: 0;
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(37,18,50,.94), rgba(24,13,30,.91));
  box-shadow: none;
  backdrop-filter: blur(7px);
}

.run-hud-card small {
  color: #fff;
  font-size: clamp(8px, 2.7vw, 11px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: .15em;
  text-transform: uppercase;
  white-space: nowrap;
}

.run-hud-card strong {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  font-size: clamp(16px, 5vw, 25px);
  font-weight: 1000;
  line-height: 1;
  letter-spacing: -.035em;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 2px 0 rgba(0,0,0,.25);
}

.run-hud-meta strong { color: #2dff70; }
.run-hud-total strong { color: #ffd535; }

@media (max-width: 380px) {
  .run-hud { left: 6px; right: 6px; gap: 4px; }
  .run-hud-card { min-height: 53px; padding: 7px 8px; border-radius: 14px; }
  .run-hud-card strong { font-size: clamp(14px, 4.7vw, 19px); }
}

@media (max-width: 330px) {
  .run-hud { left: 5px; right: 5px; }
  .run-hud-card { padding-inline: 6px; }
  .run-hud-card small { letter-spacing: .08em; }
}

@media (max-height: 500px) {
  .run-hud { top: max(5px, env(safe-area-inset-top)); }
  .run-hud-card { min-height: 48px; padding-block: 5px 6px; }
  .run-hud-card strong { margin-top: 3px; }
}
