/* Context help for every live readout to the right of the calling-card emblem.
 * Real tooltip elements keep the explanatory copy available to keyboard and
 * assistive-technology users as well as pointer users. */
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target {
  position: relative;
  pointer-events: auto;
  cursor: help;
  transition:
    color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease,
    filter 140ms ease;
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:hover,
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-visible,
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-within {
  z-index: 40;
  color: #ffe5a2;
  background:
    linear-gradient(180deg, rgba(43, 32, 13, 0.96), rgba(5, 5, 4, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(242, 197, 91, 0.74),
    inset 0 0 18px rgba(222, 160, 47, 0.12),
    0 0 0 2px rgba(0, 0, 0, 0.72),
    0 8px 22px rgba(0, 0, 0, 0.42);
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-visible {
  outline: 2px solid rgba(255, 224, 143, 0.82);
  outline-offset: 2px;
}

.is-battle-presentation-mars-sand .battle-command-rail .enemy-turn-hud.hud-help-target {
  cursor: pointer;
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card {
  position: absolute;
  z-index: 80;
  right: auto;
  bottom: calc(100% + 18px);
  left: 50%;
  display: grid;
  gap: 10.5px;
  box-sizing: border-box;
  width: min(342px, calc(100vw - 48px));
  padding: 19.5px 22.5px 21px;
  border: 2px solid rgba(239, 192, 81, 0.82);
  border-radius: 3px;
  visibility: hidden;
  color: #e8d7aa;
  background:
    linear-gradient(135deg, rgba(239, 192, 81, 0.1), transparent 42%),
    linear-gradient(180deg, #17140c 0%, #050504 100%);
  box-shadow:
    inset 0 0 0 2px rgba(255, 230, 165, 0.08),
    inset 0 -27px 45px rgba(0, 0, 0, 0.3),
    0 0 0 4.5px rgba(3, 3, 2, 0.88),
    0 18px 42px rgba(0, 0, 0, 0.54),
    0 0 27px rgba(224, 166, 49, 0.12);
  font-family: var(--font-copy);
  font-size: 16.5px;
  font-weight: 400;
  line-height: 1.45;
  letter-spacing: 0.025em;
  text-align: left;
  text-shadow: none;
  text-transform: none;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10.5px);
  transition:
    opacity 140ms ease,
    transform 140ms ease,
    visibility 140ms ease;
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card::before {
  position: absolute;
  right: 24px;
  bottom: -8px;
  left: 24px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #e3b34e, transparent);
  box-shadow: 0 0 12px rgba(227, 179, 78, 0.46);
  content: "";
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card::after {
  position: absolute;
  bottom: -9px;
  left: 50%;
  width: 15px;
  height: 15px;
  border-right: 2px solid rgba(239, 192, 81, 0.82);
  border-bottom: 2px solid rgba(239, 192, 81, 0.82);
  background: #050504;
  content: "";
  transform: translateX(-50%) rotate(45deg);
}

.is-battle-presentation-mars-sand .battle-command-rail #hud-help-end-turn {
  margin-left: 15.5px;
}

.is-battle-presentation-mars-sand .battle-command-rail #hud-help-end-turn::after {
  left: calc(50% - 15.5px);
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card--right {
  right: 0;
  left: auto;
  transform: translate(0, 10.5px);
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card--right::after {
  right: 27px;
  left: auto;
  transform: rotate(45deg);
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:hover > .hud-hover-card,
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-visible > .hud-hover-card,
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-within > .hud-hover-card {
  visibility: visible;
  opacity: 1;
  transform: translate(-50%, 0);
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:hover > .hud-hover-card--right,
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-visible > .hud-hover-card--right,
.is-battle-presentation-mars-sand .battle-command-rail .hud-help-target:focus-within > .hud-hover-card--right {
  transform: translate(0, 0);
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card__kicker {
  color: #f2c55b;
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card__copy {
  color: rgba(241, 226, 187, 0.86);
}

@media (prefers-reduced-motion: reduce) {
  .is-battle-presentation-mars-sand .battle-command-rail .hud-help-target,
  .is-battle-presentation-mars-sand .battle-command-rail .hud-hover-card {
    transition: none;
  }
}
