/* REQ-126: the back-office tour. The colour tokens (:root) and shared components are in ../styles.css; this file never defines :root variables. */

/* ── REQ-82: the back-office tour (tourView.js) ──────────────────────
   The spotlight: a cut-out around the target, the rest dimmed in
   --spot-dim, a 2 px outline in the focus colour; it never takes a click.
   The explanation: a popover next to the target (max 320 px) on a
   desktop, a bottom sheet at 600 px and less. No transitions unless the
   viewer allows motion. */
.tour-spot { position: fixed; z-index: 70; pointer-events: none; border-radius: 10px; box-shadow: 0 0 0 200vmax var(--spot-dim); outline: 2px solid var(--accent); outline-offset: 0; }
.tour-spot.none { width: 0 !important; height: 0 !important; outline: none; }
.tour-spot[hidden] { display: none; }
.tour-pop { position: fixed; z-index: 71; box-sizing: border-box; width: min(320px, calc(100vw - 24px)); padding: 14px 16px 12px; border-radius: 14px; background: var(--panel); color: var(--ink); border: 1px solid var(--line); box-shadow: 0 14px 40px rgba(0, 0, 0, 0.28); font: 500 14.5px/1.45 var(--font-body); }
.tour-pop[hidden] { display: none; }
.tour-pop .tour-h { margin: 0 88px 6px 0; font: 800 17px/1.3 var(--font-display); outline: none; }
.tour-pop .tour-h:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.tour-pop .tour-count { display: block; margin-bottom: 2px; font: 600 12px/1.4 var(--font-mono); color: var(--mute); letter-spacing: .02em; }
.tour-pop .tour-title { display: block; }
.tour-pop .tour-text { margin: 0; color: var(--ink); }
.tour-btns { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.tour-btn { min-height: 44px; min-width: 44px; }
.tour-btn:disabled { opacity: .45; cursor: default; }
.tour-pop .tour-x { position: absolute; top: 6px; right: 6px; padding: 0 10px; font-size: 13px; }
.tour-pop.sheet { left: 0 !important; right: 0; bottom: 0; top: auto !important; width: auto; max-height: 55vh; overflow: auto; border-radius: 16px 16px 0 0; padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }
.tour-pop.tour-resume:not(.sheet), .tour-pop.tour-guide:not(.sheet) { left: 50%; top: 30%; transform: translateX(-50%); width: min(360px, calc(100vw - 24px)); }
/* REQ-82.2.4: the guide question's choices stack, each a full-width 44 px button with its words. */
.tour-guide-btns { flex-direction: column; align-items: stretch; }
.tour-guide-btns .tour-btn { width: 100%; text-align: left; white-space: normal; }
.tour-offer, .tour-toast { position: fixed; z-index: 45; left: 16px; bottom: 16px; max-width: min(420px, calc(100vw - 32px)); box-sizing: border-box; padding: 12px 14px; border-radius: 14px; background: var(--panel); color: var(--ink); border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22); font: 600 14px/1.4 var(--font-body); }
.tour-offer p { margin: 0; }
.tour-offer .tour-btns { margin-top: 10px; justify-content: flex-start; }
.tour-toast { display: flex; align-items: center; gap: 12px; z-index: 72; }
@media (max-width: 600px) {
  .tour-offer, .tour-toast { left: 12px; right: 12px; bottom: 12px; max-width: none; }
}
/* Only while a new step shows (.moving): following a scroll, a resize or a
   live update snaps, so the highlight never lags behind its target. */
@media (prefers-reduced-motion: no-preference) {
  .tour-spot.moving { transition: top .2s ease, left .2s ease, width .2s ease, height .2s ease; }
  .tour-pop.moving:not(.sheet) { transition: top .2s ease, left .2s ease; }
}
/* ── end of REQ-82: the back-office tour ── */
