/* Nápověda otáčení (js/ui/orbitHint.js): oblouk kolem domu se zlatými šipkami, ruka táhne sem a tam, pod ní
   navy skleněný štítek. Polohu (--hx, --hy, --hw) počítá JS z volné plochy fotky, vodorovně ji tady drží
   bezpečné okraje displeje. Nebere vstupy. Cyklus ruky 3,4 s sedí na ukázkové pootočení domu (orbitHint.js). */
.ohint {
  --hx: 50%; --hy: 80%; --hw: 260px;
  position: absolute; z-index: 12; top: var(--hy);
  left: clamp(calc(var(--hw) / 2 + 12px + env(safe-area-inset-left, 0px)), var(--hx),
    calc(100% - var(--hw) / 2 - 12px - env(safe-area-inset-right, 0px)));
  transform: translate(-50%, -100%);
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  pointer-events: none; -webkit-user-select: none; user-select: none;
  opacity: 0; translate: 0 14px; transition: opacity .55s ease, translate .8s cubic-bezier(.22, .8, .2, 1);
}
.ohint.is-on { opacity: 1; translate: 0 0; }
.ohint.is-moved { transition: opacity .55s ease, translate .8s cubic-bezier(.22, .8, .2, 1), left .6s ease, top .6s ease; }
.ohint.is-off { opacity: 0; translate: 0 8px; transition-duration: .35s; }

.ohint__art { position: relative; width: 240px; height: 108px; }
.ohint__orbit {
  position: absolute; left: 0; top: 0; width: 240px; height: 64px; overflow: visible;
  filter: drop-shadow(0 2px 6px rgba(7, 25, 58, .35));
}
.ohint__sh { fill: none; stroke: rgba(7, 25, 58, .3); stroke-width: 5.5; stroke-linecap: round; stroke-linejoin: round; }
.ohint__arc { fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; }
.ohint__heads { fill: none; stroke: var(--gold); stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }

/* ruka: špička prstu (14,1; 1,5) leží na nejnižším bodě oblouku (120; 58), otáčí se kolem ní */
.ohint__hand {
  position: absolute; left: 105.9px; top: 56.5px; width: 36px; height: 44px; transform-origin: 14.1px 1.5px;
  filter: drop-shadow(0 4px 8px rgba(7, 25, 58, .4));
}
.ohint__hand svg { position: relative; display: block; width: 36px; height: 44px; }
.ohint__tap {
  position: absolute; left: 14.1px; top: 1.5px; width: 28px; height: 28px; margin: -14px 0 0 -14px; border-radius: 50%;
  background: rgba(221, 173, 10, .5); box-shadow: 0 0 0 2px rgba(255, 255, 255, .75); transform: scale(.5); opacity: .85;
}
.ohint.is-play .ohint__hand { animation: ohHand 3.4s cubic-bezier(.45, 0, .55, 1) .5s infinite both; }
.ohint.is-play .ohint__tap { animation: ohTap 3.4s ease-out .5s infinite both; }
@keyframes ohHand {
  0% { transform: translate(0, 5px) scale(1.04); }
  6% { transform: translate(0, 0) scale(.94); }
  22% { transform: translate(-56px, -5px) rotate(-8deg) scale(.94); }
  56% { transform: translate(56px, -5px) rotate(8deg) scale(.94); }
  74% { transform: translate(0, 0) rotate(0) scale(.94); }
  84%, 100% { transform: translate(0, 5px) scale(1.04); }
}
@keyframes ohTap {
  0% { transform: scale(.2); opacity: 0; }
  6% { transform: scale(.55); opacity: .95; }
  72% { transform: scale(.55); opacity: .8; }
  86% { transform: scale(1.35); opacity: 0; }
  100% { transform: scale(1.35); opacity: 0; }
}

.ohint__label {
  display: inline-flex; align-items: center; gap: 9px; margin: 0; padding: 8px 16px 8px 13px; border-radius: 99px;
  background: rgba(7, 25, 58, .74); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  box-shadow: 0 10px 26px -10px rgba(7, 25, 58, .55); color: #fff; font: 700 14px/1.25 var(--f-ui); white-space: nowrap;
}
.ohint__label b { font-size: 15px; line-height: 1; color: var(--gold); }

/* telefon a nízké okno: menší, ať fotka domu zůstane hlavní */
@media (max-width: 760px), (max-width: 1023px) and (orientation: portrait) {
  .ohint__art { zoom: .84; }
  .ohint__label { padding: 7px 14px 7px 11px; font-size: 13px; }
}
@media (min-width: 761px) and (max-height: 620px) {
  .ohint__art { zoom: .72; }
  .ohint__label { padding: 6px 13px 6px 10px; font-size: 12.5px; }
  .ohint__label b { font-size: 13.5px; }
}
/* menší varianta (velká by kryla maják A01.1 nebo štítek bytu): jeden navy pruh, kresba vlevo v něm */
.ohint--compact {
  flex-direction: row; gap: 0; padding: 3px 16px 3px 4px; border-radius: 99px;
  background: rgba(7, 25, 58, .74); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  box-shadow: 0 10px 26px -10px rgba(7, 25, 58, .55);
}
.ohint--compact .ohint__art { zoom: .5; margin: -6px 0 -2px; }
.ohint--compact .ohint__label { padding: 0; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.is-shot .ohint { display: none; }

/* nápověda otáčení: pilulka načítání se během ní schová (ui/orbitHint.js) */
.spin-loader.is-under-hint { opacity: 0; pointer-events: none; }
