/* A narrow legend under the mast. Only the switch and the disc receive touches. */
#walk-hud {
  position: absolute;
  top: 100%;
  right: max(var(--pad), env(safe-area-inset-right));
  max-width: calc(100% - 2 * var(--pad));
  color: #f2e3c9;
  font: 12px/1.45 var(--sans);
  text-shadow: 0 1px 4px #102029;
  pointer-events: none;
  text-align: right;
}
#walk-hud, #walk-stick { transform: translateY(var(--sign-shift, 0px)); }
.walk-key-hint, .walk-touch-hint {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}
.walk-key-hint {
  padding: 4px 8px;
  background: #18232dbf;
  border-inline-end: 1px solid #cda674;
}
.walk-key-hint span { display: inline-flex; gap: 3px; }
.walk-key-hint i { width: 1px; height: .85em; background: var(--line); }
.walk-key-hint kbd {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 20px;
  border: 1px solid #dbc19a77;
  border-radius: 3px;
  color: #ffe6bb;
  font: 12px Georgia, serif;
}
.walk-key-hint kbd[data-down] { color: #281c16; background: #efca8d; text-shadow: none; }
.walk-touch-hint, #walk-stick { display: none; }
#walk-hud p:not(:empty) {
  width: fit-content;
  margin-inline-start: auto;
  padding: 3px 7px;
  background: #142028eb;
}
body:not([data-walk="lite"]) :is(#walk-hud, #walk-stick) { display: none; }

@media (pointer: coarse) {
  .walk-key-hint { display: none; }
  .walk-touch-hint { display: flex; gap: 8px; }
  .walk-touch-hint span { text-shadow: 0 1px 4px #07131b, 0 0 8px #07131b; }
  .walk-touch-hint button {
    min-height: 44px;
    padding: 0 11px;
    border: 1px solid #d4ae766b;
    border-radius: 3px;
    pointer-events: auto;
    background: #18232dde;
    color: #ffe5bd;
    font: 14px var(--serif);
  }
  .walk-touch-hint button[aria-pressed="true"] { color: #241b13; background: #f1d3a2; }
  #city:has(> #walk-stick:not([hidden])) {
    --stick-size: clamp(76px, 21vw, 96px);
    --stick-left: max(var(--pad), env(safe-area-inset-left));
  }
  #walk-stick:not([hidden]) {
    display: grid;
    place-items: center;
    position: absolute;
    left: var(--stick-left);
    bottom: max(84px, calc(68px + env(safe-area-inset-bottom)));
    width: var(--stick-size);
    aspect-ratio: 1;
    border: 1px solid #d8b783a3;
    border-radius: 50%;
    background: radial-gradient(circle, #17243155 46%, #d4ae7645 47%, transparent 49%), #15222b99;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
  }
  #walk-stick i {
    display: block;
    width: 37%;
    aspect-ratio: 1;
    border: 1px solid #ffe0aeaa;
    border-radius: 50%;
    background: #886648;
    transform: translate(var(--dx, 0px), var(--dy, 0px));
    pointer-events: none;
  }
  #walk-stick span {
    position: absolute;
    bottom: 3px;
    color: #ffedcf;
    font: 10px/1.2 var(--serif);
    letter-spacing: .12em;
    pointer-events: none;
  }
  #walk-stick[data-held] i { background: #c09866; }
  #city:has(> #walk-stick:not([hidden])) :is(.east-guide, .scene-copy) {
    left: calc(var(--stick-left) + var(--stick-size) + 14px);
  }
  /* Keep the named step buttons in the accessibility tree and reveal on keyboard focus. */
  #city:has(> #walk-stick:not([hidden])) .east-handles:not(:focus-within) button {
    position: absolute;
    width: 1px;
    height: 1px;
    min-width: 0;
    min-height: 0;
    padding: 0;
    border: 0;
    overflow: hidden;
    clip-path: inset(50%);
  }
}
@media (pointer: coarse) and (max-height: 550px) {
  #walk-stick:not([hidden]) { bottom: max(64px, calc(57px + env(safe-area-inset-bottom))); }
}
