/* ==========================================================================
   Guide card + board tour (v11, 2026-10-08)
   --------------------------------------------------------------------------
   .fr-guide-*  The ONE card used by the tour, tips (coach marks) and Show me
                how. Same type, buttons, progress and caret everywhere, so the
                three read as one feature. Owner-approved mock:
                claude.ai/artifact/Y9giWxjwt4ViV8iRqtAE5o.
   .ft-*        The tour's spotlight on the live board (js/ui/feature-tour.js).

   The v10 slideshow (chooser, 16 topic slides, screenshots, 17 diagrams) and
   its ~5,000 lines of styles were removed with it.
   ========================================================================== */

/* ── The card ─────────────────────────────────────────────────────────── */
.fr-guide-card {
  --guide-ink: var(--slate-800, #1e293b);
  --guide-ink-2: var(--slate-600, #475569);
  --guide-muted: var(--slate-500, #64748b);
  --guide-line: var(--slate-200, #e2e8f0);
  --guide-soft: var(--slate-50, #f8fafc);
  --guide-surface: #ffffff;
  position: fixed;
  box-sizing: border-box;
  width: 320px;
  max-width: calc(100vw - 24px);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--guide-surface);
  color: var(--guide-ink);
  border-radius: 18px;
  box-shadow: 0 28px 56px -14px rgba(15, 23, 42, 0.45), 0 0 0 1px rgba(15, 23, 42, 0.06);
  font-family: var(--font-sans, 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif);
  text-align: left;
  overflow-wrap: anywhere;
}

.fr-guide-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.fr-guide-kicker {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--primary-700, #0f766e);
  min-width: 0;
}

.fr-guide-x {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 9px;
  border: 1px solid var(--guide-line);
  background: var(--guide-surface);
  color: var(--guide-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  cursor: pointer;
}
.fr-guide-x:hover { color: var(--guide-ink); background: var(--guide-soft); }

.fr-guide-progress {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 4px;
}
.fr-guide-progress span {
  height: 4px;
  border-radius: 2px;
  background: var(--guide-line);
  transition: background-color 0.3s ease;
}
.fr-guide-progress span.is-done { background: var(--primary-300, #5eead4); }
.fr-guide-progress span.is-now { background: var(--primary-600, #0d9488); }

.fr-guide-title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--guide-ink);
}
.fr-guide-title--lg { font-size: 22px; font-weight: 800; letter-spacing: -0.015em; }

.fr-guide-body {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--guide-ink-2);
}

/* Samples: small live readings of the board, in a soft well. */
.fr-guide-sample {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 10px;
  border-radius: 12px;
  background: var(--guide-soft);
  min-width: 0;
}

.fr-guide-sample--tiles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 10px 6px;
}
.fr-guide-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 600;
  color: var(--guide-ink-2);
  text-align: center;
  min-width: 0;
}
.fr-guide-tile i { font-size: 16px !important; }

.fr-guide-sample--menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 10px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--slate-700, #334155);
}
.fr-guide-menu-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.fr-guide-menu-row i { width: 16px; text-align: center; color: var(--primary-600, #0d9488); }

/* Footer, buttons, links */
.fr-guide-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 2px;
}
.fr-guide-actions { display: inline-flex; gap: 8px; align-items: center; }
.fr-guide-actions--start { justify-content: flex-start; flex-wrap: wrap; }

.fr-guide-btn {
  height: 40px;
  padding: 0 16px;
  border-radius: 12px;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: 600 14px var(--font-sans, 'Inter', -apple-system, sans-serif);
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.15s ease, transform 0.15s ease;
}
.fr-guide-btn:active { transform: translateY(1px); }
.fr-guide-btn i { font-size: 12px; }
.fr-guide-btn--primary {
  background: var(--primary-500, #14b8a6);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(20, 184, 166, 0.35);
}
.fr-guide-btn--primary:hover { background: var(--primary-600, #0d9488); }
.fr-guide-btn--secondary {
  background: var(--slate-100, #f1f5f9);
  color: var(--slate-700, #334155);
  border: 1px solid var(--guide-line);
}
.fr-guide-btn--secondary:hover { background: var(--guide-line); }
.fr-guide-btn--secondary i { color: var(--primary-600, #0d9488); }
.fr-guide-btn--icon { width: 44px; padding: 0; }
.fr-guide-btn--icon i { color: var(--slate-700, #334155); }
.fr-guide-btn--wide { width: 100%; height: 46px; font-size: 15px; }
.fr-guide-btn:disabled { opacity: 0.45; cursor: default; }
.fr-guide-btn:focus-visible,
.fr-guide-x:focus-visible,
.fr-guide-link:focus-visible {
  outline: 2px solid var(--primary-500, #14b8a6);
  outline-offset: 2px;
}

.fr-guide-link {
  border: 0;
  background: none;
  padding: 4px 2px;
  font: 500 14px var(--font-sans, 'Inter', -apple-system, sans-serif);
  color: var(--guide-muted);
  cursor: pointer;
}
.fr-guide-link:hover { color: var(--primary-700, #0f766e); }
.fr-guide-link--strong { font-weight: 600; color: var(--primary-700, #0f766e); }

.fr-guide-badge {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--primary-700, #0f766e);
  background: var(--primary-100, #ccfbf1);
  border-radius: 999px;
  padding: 2px 8px;
  white-space: nowrap;
}

.fr-guide-caret {
  position: absolute;
  width: 14px;
  height: 14px;
  background: var(--guide-surface);
  transform: rotate(45deg);
  border-radius: 3px;
  display: none;
}
.fr-guide-card[data-placement="right"] .fr-guide-caret { display: block; left: -7px; }
.fr-guide-card[data-placement="left"] .fr-guide-caret { display: block; right: -7px; }
.fr-guide-card[data-placement="bottom"] .fr-guide-caret { display: block; top: -7px; }
.fr-guide-card[data-placement="top"] .fr-guide-caret { display: block; bottom: -7px; }

/* Welcome and finish cards */
.fr-guide-hero { display: flex; flex-direction: column; gap: 16px; }
.fr-guide-hero--done { align-items: center; text-align: center; }
.fr-guide-mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--primary-100, #ccfbf1), var(--primary-50, #f0fdfa));
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.fr-guide-keys { margin: 0; font-size: 12.5px; color: var(--guide-muted); display: flex; gap: 6px; align-items: center; }
.fr-guide-keys kbd {
  border: 1px solid var(--guide-line);
  border-bottom-width: 2px;
  border-radius: 6px;
  padding: 0 6px;
  font: 600 12px var(--font-sans, 'Inter', sans-serif);
  color: var(--guide-ink-2);
  background: var(--guide-soft);
}
.fr-guide-aside {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--slate-100, #f1f5f9);
  font-size: 13.5px;
  color: var(--guide-muted);
}
.fr-guide-aside > i { color: var(--primary-600, #0d9488); }
.fr-guide-check {
  width: 64px;
  height: 64px;
  border-radius: 32px;
  background: var(--primary-100, #ccfbf1);
  color: var(--primary-700, #0f766e);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  box-shadow: 0 0 0 8px var(--primary-50, #f0fdfa);
}
.fr-guide-stack { display: flex; flex-direction: column; gap: 10px; width: 100%; }

/* ── The tour on the board ────────────────────────────────────────────── */
.ft-root { position: fixed; inset: 0; pointer-events: none; }
.ft-shield { position: fixed; inset: 0; pointer-events: auto; background: transparent; }

.ft-hole {
  position: fixed;
  border-radius: 14px;
  box-shadow: 0 0 0 200vmax rgba(15, 23, 42, 0);
  pointer-events: none;
  transition:
    left 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    top 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    width 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    height 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.3s ease;
}
.ft-root.is-open .ft-hole { box-shadow: 0 0 0 200vmax rgba(15, 23, 42, 0.62); }

.ft-ring {
  position: absolute;
  inset: -3px;
  border-radius: 17px;
  border: 2px solid var(--primary-400, #2dd4bf);
  box-shadow: 0 0 0 6px rgba(45, 212, 191, 0.22), 0 0 28px rgba(45, 212, 191, 0.45);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.ft-ring::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 22px;
  border: 2px solid rgba(45, 212, 191, 0.55);
  animation: ft-pulse 2.4s ease-out infinite;
}
.ft-hole.has-ring .ft-ring { opacity: 1; }

@keyframes ft-pulse {
  0% { opacity: 0.9; transform: scale(0.98); }
  70% { opacity: 0; transform: scale(1.06); }
  100% { opacity: 0; }
}

.ft-card {
  pointer-events: auto;
  opacity: 0;
  transform: translateY(6px);
  transition:
    left 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    top 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.25s ease,
    transform 0.25s ease;
}
.ft-root.is-open .ft-card { opacity: 1; transform: none; }
.ft-card[data-view="intro"],
.ft-card[data-view="done"] { width: 400px; padding: 26px 26px 22px; }
/* A stop with an annotated picture: Show me how's width, so the two match. */
.ft-card.has-figure { width: 380px; }
.fr-guide-figure { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

/* Phones: the card is a bottom sheet; the page scrolls the stop clear of it. */
@media (max-width: 640px) {
  .fr-guide-card.is-sheet {
    left: 10px !important;
    right: 10px;
    top: auto !important;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    width: auto;
    max-width: none;
    max-height: calc(100dvh - 90px);
    overflow-y: auto;
    padding: 14px 18px 14px;
    border-radius: 22px;
    box-shadow: 0 -10px 40px -10px rgba(15, 23, 42, 0.45), 0 0 0 1px rgba(15, 23, 42, 0.06);
    transform: none;
  }
  .fr-guide-card.is-sheet[data-placement="sheet-top"] {
    top: calc(10px + env(safe-area-inset-top, 0px)) !important;
    bottom: auto;
  }
  .fr-guide-card.is-sheet .fr-guide-caret { display: none; }
  .fr-guide-card.is-sheet .fr-guide-btn { height: 44px; font-size: 15px; }
  /* Touch keeps style.css's 44px tap floor on every button here. */
  .fr-guide-card.is-sheet .fr-guide-x { width: 44px; height: 44px; border-radius: 12px; }
  .fr-guide-card.is-sheet .fr-guide-title { font-size: 18px; }
  .fr-guide-card.is-sheet .fr-guide-title--lg { font-size: 21px; }
  .fr-guide-card.is-sheet .fr-guide-body { font-size: 15px; }
  .fr-guide-card.is-sheet .fr-guide-keys { display: none; }
  /* A stop with a picture: the sheet stops at two thirds of the screen so
     the control it points at stays in view; the words and picture scroll
     and Next stays pinned to the bottom. */
  .ft-card.is-sheet.has-figure { max-height: min(calc(100dvh - 90px), 64dvh); }
  .ft-card.is-sheet.has-figure .fr-guide-foot {
    position: sticky;
    bottom: -14px;
    z-index: 2;
    margin: 0 -18px -14px;
    padding: 10px 18px 14px;
    background: var(--guide-surface);
    box-shadow: 0 -12px 14px -12px rgba(15, 23, 42, 0.22);
  }
  .ft-card.is-sheet[data-view="intro"],
  .ft-card.is-sheet[data-view="done"] { width: auto; padding: 18px 20px 16px; }
}

/* Dark mode */
body.dark-mode .fr-guide-card {
  --guide-ink: var(--slate-100, #f1f5f9);
  --guide-ink-2: var(--slate-300, #cbd5e1);
  --guide-muted: var(--slate-400, #94a3b8);
  --guide-line: var(--slate-700, #334155);
  --guide-soft: var(--slate-900, #0f172a);
  --guide-surface: var(--slate-800, #1e293b);
  box-shadow: 0 28px 56px -14px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(148, 163, 184, 0.16);
}
body.dark-mode .fr-guide-btn--secondary { background: var(--slate-700, #334155); color: var(--slate-100, #f1f5f9); }
body.dark-mode .fr-guide-btn--icon i,
body.dark-mode .fr-guide-sample--menu { color: var(--slate-200, #e2e8f0); }
body.dark-mode .fr-guide-kicker,
body.dark-mode .fr-guide-link--strong { color: var(--primary-300, #5eead4); }
body.dark-mode .fr-guide-badge { background: rgba(45, 212, 191, 0.16); color: var(--primary-300, #5eead4); }

@media (prefers-reduced-motion: reduce) {
  .ft-hole, .ft-card, .ft-ring, .fr-guide-progress span { transition: none; }
  .ft-ring::after { animation: none; }
}

/* ── Annotated samples (Show me how, 2026-10-08) ─────────────────────────
   Real board parts (js/ui/board-specimens.js) with numbered markers and a
   matching numbered legend. The parts are painted by the board's own CSS;
   only the frame, the markers and the legend are styled here. */
.practice-spotlight-card.has-sample { width: 380px; }
.practice-card-sample { min-width: 0; }
.bs-annot { margin: 0; }
.bs-annot-pic {
  position: relative;
  isolation: isolate; /* the callouts stack above the board parts inside */
  padding: 10px;
  border-radius: 12px;
  background: var(--guide-soft);
}
/* Lanes for the numbers: above (and below) the picture, never on it. */
.bs-annot-pic.has-top { padding-top: 34px; }
.bs-annot-pic.has-bottom { padding-bottom: 34px; }
.bs-annot-pic.has-right { padding-right: 34px; }
.bs-guide {
  position: absolute;
  z-index: 999;
  width: 1.5px;
  margin-left: -0.75px;
  background: var(--primary-600, #0d9488);
  pointer-events: none;
}
.bs-guide:not([data-placed]) { display: none; }
.bs-guide[data-dir="h"] { height: 1.5px; margin-left: 0; margin-top: -0.75px; }
.bs-mark {
  position: absolute;
  z-index: 1000;
  width: 18px;
  height: 18px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--primary-600, #0d9488);
  color: #ffffff;
  font: 700 10.5px/18px var(--font-sans, 'Inter', sans-serif);
  text-align: center;
  box-shadow: 0 0 0 2px #ffffff;
  pointer-events: none;
}
/* Measured onto its part by BoardSpecimens.placeMarks(); hidden until then. */
.bs-mark[data-anchor]:not([data-placed]) { visibility: hidden; }
.bs-mark--key {
  position: static;
  z-index: auto; /* a flex item keeps z-index even when static: it would paint over the sheet's pinned footer */
  flex: 0 0 18px;
  transform: none;
  box-shadow: none;
}
.bs-annot-key {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  gap: 5px;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--guide-ink-2);
}
.bs-annot-key li { display: flex; align-items: flex-start; gap: 8px; }
.bs-annot-key b { color: var(--guide-ink); }
/* Small parts are shown larger so each callout lands on a readable word. */
.bs-annot--pill .bs-annot-pic { display: inline-block; padding-left: 14px; padding-right: 14px; }
.bs-annot--pill .hc-spec-pill { zoom: 1.4; }
.bs-annot--teambar .bs-clone > * { zoom: 1.25; }
/* The row sample keeps Help's 64px track: the board sets the cell height. */
.bs-pilllist {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
  font-size: 12.5px;
  line-height: 1.3;
  color: var(--guide-ink-2);
}
.bs-pilllist li { display: grid; grid-template-columns: 132px minmax(0, 1fr); align-items: center; gap: 8px; }
.bs-pilllist .hc-spec-pill { justify-self: start; }
.bs-keyhead {
  margin: 0 0 6px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--guide-muted);
}
.bs-keylist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 5px;
  font-size: 12.5px;
  color: var(--guide-ink-2);
}
.bs-keylist li { display: flex; align-items: center; gap: 8px; }
.bs-swatch { flex: 0 0 16px; width: 16px; height: 12px; border-radius: 3px; }
.bs-edgetag { flex: 0 0 auto; padding: 2px 5px; border-radius: 4px; font-size: 10px; font-weight: 700; line-height: 1.1; }
.bs-clone { display: flex; justify-content: center; min-width: 0; overflow: hidden; }
/* A row as the board draws it (figures.row): the board's own row classes,
   framed like a board card. Focus view hides every .timezone-row on the
   page; the picture keeps its own. */
.bs-rowcard {
  padding: 4px 8px 6px;
  border-radius: 14px;
  background: var(--surface-primary, #ffffff);
  box-shadow: 0 2px 12px rgba(20, 184, 166, 0.12);
}
body[data-focus-mode] .bs-rowcard .timezone-row { display: flex !important; }
.bs-rowcard .timezone-row { margin-bottom: 4px; }
.bs-rowcard .city-offset { white-space: nowrap; }
.bs-rowcard .timeline-row { display: block; width: 100%; }
/* The scanner crossing four rows (figures.scan), in the board's segment
   colours (.tz-seg-*), with each row's time tags under it. */
.bs-scanrows { position: relative; display: grid; gap: 2px; }
/* The board sizes its cells from --timeline-row-height (!important). */
.bs-scanrow { --timeline-row-height: 38px; }
.bs-scanrow .hc-spec-track { height: 38px; }
.bs-scanseg { position: absolute; top: 0; bottom: 0; z-index: 3; }
.bs-scantags { position: relative; height: 19px; }
.bs-scantags > span { position: absolute; top: 3px; transform: translateX(-50%); }
.bs-scanband {
  position: absolute;
  top: -4px;
  bottom: -2px;
  z-index: 4;
  box-sizing: border-box;
  border: 2px solid var(--primary-500, #14b8a6);
  border-radius: 8px;
  background: rgba(34, 197, 94, 0.06);
  pointer-events: none;
}
.bs-keylist--inline { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 2px; }
.bs-swatch.tz-hour-segment { position: static; display: inline-block; }
.bs-annot--scan + .bs-keyhead { margin-top: 10px; }
/* The Find Times answer card (figures.answer), in its own classes. */
.bs-annot--answer .vm-bt-best { margin: 0; padding: 14px; gap: 12px; }
/* The card's own phone layout (find-a-time-results.css), so the faces sit
   side by side in a card's width. */
.bs-annot--answer .vm-bt-best-main strong { font-size: 24px; }
.bs-annot--answer .vm-bt-faces { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.bs-annot--answer .vm-bt-face { flex-direction: column; gap: 4px; padding: 8px 2px; text-align: center; }
.bs-annot--answer .vm-bt-face-txt { align-items: center; max-width: 100%; }
/* Help's phone pane leaves the card about 250px: keep the time on one line. */
@media (max-width: 640px) {
  .bs-annot--answer .vm-bt-best-top { gap: 10px; }
  .bs-annot--answer .vm-bt-best-main strong { font-size: 20px; }
}
.bs-annot--answer .vm-bt-go { pointer-events: none; }
/* Each mode's colour scale, from the Mode menu's own details. */
.bs-modescale { display: block; margin-top: 5px; max-width: 320px; }
.bs-modescale .vm-picker-info-key-row,
.bs-modescale .vm-picker-info-scale-labelled { margin: 0; }
/* "deep sleep" is a few pixels wider than its fifth of the scale. */
.bs-modescale .vm-picker-scale-labels > span { overflow: visible; text-overflow: clip; }
/* Two pictures in a row of rows (Help's visibility key). */
.bs-rows { display: grid; gap: 8px; }
/* The status bar: its live counts, each with its own icon and colour. */
.bs-statbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 6px 12px;
  padding: 7px 10px;
  border-radius: 10px;
  background: var(--guide-surface);
  box-shadow: inset 0 0 0 1px var(--guide-line);
}
.bs-statside { display: inline-flex; align-items: center; gap: 9px; }
.bs-stat { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; white-space: nowrap; }
.bs-stat i { font-size: 11.5px; }
.bs-stat b { font-weight: 700; font-variant-numeric: tabular-nums; }
.bs-annot--statbar .bs-annot-key { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 12px; }
.bs-modelist { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.bs-modelist li { display: flex; align-items: flex-start; gap: 10px; }
.bs-modelist i { flex: 0 0 18px; margin-top: 2px; text-align: center; color: var(--primary-600, #0d9488); }
.bs-modelist b { display: block; font-size: 13px; color: var(--guide-ink); }
.bs-modelist small { display: block; font-size: 12px; line-height: 1.35; color: var(--guide-muted); }
body.dark-mode .bs-mark { box-shadow: 0 0 0 2px var(--slate-800, #1e293b); }
body.dark-mode .bs-modelist i { color: var(--primary-300, #5eead4); }
/* Phones: the card is a bottom sheet; keep the pictures compact. */
@media (max-width: 600px) {
  .practice-spotlight-card.has-sample { width: auto; }
  /* Reading steps: the picture first, the words under it. */
  .practice-spotlight-card.is-reading .practice-card-sample { order: -1; }
  .bs-pilllist li { grid-template-columns: 118px minmax(0, 1fr); }
}
