/* The product tour (static/js/tour.js): a scrim, a spotlight cut out of it
 * with a shadow, and the step's card. Above every menu, panel and the
 * navigation skeleton. The shell's tokens, so dark mode follows. */

.tour { position: fixed; inset: 0; z-index: var(--z-tour); }
.tour-scrim { position: absolute; inset: 0; background: rgba(0, 0, 0, .45); transition: background-color 200ms linear; }
.tour.is-spot .tour-scrim { background: transparent; }
.tour-hole {
  position: absolute; display: none; pointer-events: none;
  border-radius: 10px;
  box-shadow: 0 0 0 2px var(--primary), 0 0 0 200vmax rgba(0, 0, 0, .45);
  transition: left 260ms var(--ease-out-cubic), top 260ms var(--ease-out-cubic), width 260ms var(--ease-out-cubic), height 260ms var(--ease-out-cubic);
}
.tour.is-spot .tour-hole { display: block; }

.tour-card {
  position: absolute; left: 50%; top: 50%; width: 360px;
  max-height: calc(100dvh / var(--zoom) - 24px); overflow: auto;
  display: flex; flex-direction: column;
  padding: 14px 16px 12px; border-radius: 12px;
  background: var(--card); color: var(--text); border: 1px solid var(--border);
  box-shadow: var(--menu-shadow), 0 12px 32px rgba(0, 0, 0, .18);
  outline: none;
  transition: left 260ms var(--ease-out-cubic), top 260ms var(--ease-out-cubic), opacity 160ms linear;
}
.tour.is-busy .tour-card { opacity: .7; }
.tour.is-entering .tour-card { opacity: 0; }

.tour-head { display: flex; align-items: center; justify-content: space-between; height: 24px; }
.tour-count { font-size: 11.5px; font-weight: 500; color: var(--muted); letter-spacing: .3px; }
.tour-x { display: grid; place-items: center; width: 28px; height: 28px; margin-right: -6px; border-radius: 6px; color: var(--text-2); }
.tour-x:hover { background: var(--hover); color: var(--text); }
.tour-bar { height: 3px; margin: 8px 0 12px; border-radius: 2px; background: var(--seg-bg); overflow: hidden; }
.tour-bar i { display: block; height: 100%; width: 0; background: var(--primary); border-radius: 2px; transition: width 260ms var(--ease-out-cubic); }
.tour-title { margin: 0 0 6px; font-size: 15px; font-weight: 600; line-height: 1.35; letter-spacing: .1px; }
.tour-body { margin: 0; font-size: 13px; line-height: 1.55; color: var(--text-2); }
.tour-foot { display: flex; justify-content: flex-end; gap: 6px; margin-top: 14px; }
.tour-foot .btn { height: 34px; }
.tour-card :focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

/* A screen the tour drew from the demo fixtures (app/ui/tour.py) says so
 * beside its title, and a write it refused says so in a toast. */
.tb-title-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tour-chip { flex: none; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; padding: 2px 8px; border-radius: 999px; background: color-mix(in srgb, var(--primary) 14%, transparent); color: var(--primary); }
.tour-toast {
  position: fixed; left: 50%; bottom: 24px; z-index: calc(var(--z-tour) + 1); transform: translateX(-50%);
  max-width: calc(100vw - 32px); padding: 10px 14px; border-radius: 8px;
  background: var(--text); color: var(--card); font-size: 13px; box-shadow: var(--menu-shadow);
}

/* Its step pulls the folded activity tab out, as a hover would. */
.tour-act .act-tab { max-width: 64px; padding-right: 14px; }
.tour-act .act-tab .act-handle { opacity: 0; }
.tour-act .act-tab .bell { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .tour-scrim, .tour-hole, .tour-card, .tour-bar i, .tour-act .act-tab { transition: none; }
}
