/* ==================================================================
   tour.css — «Як користуватися» (engine/tour.js): затемнення, рамка навколо цілі, рука й підказка.
   Підказка — великий спокійний текст на білому; один акцент — рамка кольору бренду. Без нескінченних пульсацій:
   рука двічі «натискає» й завмирає.
   ================================================================== */

/* кнопка «Як користуватися» і запрошення — на початку застосунку */
.tour-bar { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin: 0; }
/* запрошення під кнопками — з проміжком (раніше від'ємний відступ кнопок наїжджав на його рамку) */
.tour-bar + .tour-invite { margin-top: 10px; }
.tour-help {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 12px;
  font: 600 14px/1 var(--font-body); color: var(--brand);
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); cursor: pointer;
}
.tour-help svg { width: 20px; height: 20px; }
@media (hover: hover) { .tour-help:hover { border-color: var(--brand); background: var(--brand-soft); } }
.tour-help:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

.tour-invite {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; padding: 12px 14px;
  background: var(--surface); border: 1px solid var(--brand); border-radius: var(--radius);
}
.tour-invite-text { flex: 1 1 260px; margin: 0; font-size: 17px; line-height: 1.4; color: var(--ink); }

/* шар туру: на весь документ (координати документа — див. tour.js) */
.tour-layer { position: absolute; left: 0; top: 0; z-index: 2147483000; pointer-events: none; }
.tour-block { position: absolute; background: rgba(31, 27, 36, .55); pointer-events: auto; }
.tour-layer.is-nodim .tour-block { background: transparent; }
.tour-ring {
  position: absolute; border-radius: 8px; pointer-events: none;
  box-shadow: 0 0 0 3px var(--surface), 0 0 0 6px var(--brand);
}
.tour-layer.is-nodim .tour-ring { display: none; }
.tour-hand { position: absolute; width: 44px; height: 44px; pointer-events: none; }
.tour-hand svg { width: 44px; height: 44px; filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .35)); }
@media (prefers-reduced-motion: no-preference) {
  .tour-hand { animation: tour-tap 1.1s ease-in-out 2 both; }
  .tour-tip { animation: tour-in .2s ease-out both; }
}
@keyframes tour-tap { 0%, 100% { transform: translate(0, 0); } 45% { transform: translate(-4px, -8px); } 60% { transform: translate(0, 0) scale(.94); } }
@keyframes tour-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.tour-tip {
  position: absolute; pointer-events: auto; box-sizing: border-box;
  padding: 12px 14px 14px; background: var(--surface); color: var(--text);
  border: 2px solid var(--brand); border-radius: var(--radius);
  font-family: var(--font-body);
}
.tour-tip.is-nudge { animation: tour-nudge .3s ease-in-out; }
@keyframes tour-nudge { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.tour-tip-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.tour-tip-count { font-size: 14px; color: var(--muted); margin-right: auto; }
.tour-listen, .tour-close {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 10px;
  font: 600 14px/1 var(--font-body); color: var(--brand); background: var(--surface);
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm); cursor: pointer;
}
.tour-close { width: 40px; padding: 0; justify-content: center; }
.tour-listen svg, .tour-close svg { width: 20px; height: 20px; }
.tour-listen:focus-visible, .tour-close:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.tour-tip-title { margin: 0 0 2px; font: 700 15px/1.3 var(--font-body); color: var(--brand); }
.tour-tip-text { margin: 0; font-size: 19px; line-height: 1.45; color: var(--ink); }
.tour-tip-text b { color: var(--brand); }
.tour-tip-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.tour-tip.is-action .tour-tip-actions .lab-btn:last-child { font-weight: 500; color: var(--muted); }

@media (max-width: 420px) { .tour-tip-text { font-size: 18px; } .tour-listen span { display: none; } .tour-listen { width: 40px; padding: 0; justify-content: center; } }
@media print { .tour-layer, .tour-bar, .tour-invite { display: none !important; } }
@media (forced-colors: active) { .tour-ring { outline: 4px solid Highlight; } .tour-block { background: transparent; } }
