/* ====================================================================================================================================
   FITMARK HELP: the Tutorial and the FAQ (stream F3, Nov 26 2026; app/js/quiz/help.js draws them from help-tutorial.js and help-faq.js).
   Loaded by quiz.html after fitmark.css. The layout is Tack's and Money's help page; the colors are Fitmark's own tokens
   (fitmark-tokens.css), so the accent follows the member's brand color. Every class starts with fm-help or fm-faq (and the menu's
   fm-menu__help), so nothing here reaches another page.
   ==================================================================================================================================== */
.fm-help { --fmh-ink: var(--f-ink, #160B2E); --fmh-ink-2: var(--f-ink-2, #463F5C); --fmh-muted: var(--f-ink-muted, #625B78);
  --fmh-line: var(--f-line, #E2DDEF); --fmh-card: var(--f-surface, #fff); --fmh-well: var(--f-surface-2, #F7F5FC);
  --fmh-accent: var(--f-accent-strong, #4A31B5); --fmh-solid: var(--f-accent, #5B3FD6); --fmh-solid-hi: var(--f-accent-strong, #4A31B5); --fmh-soft: var(--f-accent-soft, #EEEBFA);
  max-width: 980px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; color: var(--fmh-ink-2); font-size: 15px; line-height: 1.55; }
.fm-help > .fm-hpanel { margin: 0; background: var(--fmh-card); border: 1px solid var(--fmh-line); border-radius: var(--f-r, 14px); padding: 20px 22px; box-shadow: var(--f-shadow-1, none); min-width: 0; }
.fm-help__sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.fm-help__top { min-width: 0; }
.fm-help__h { margin: 0 0 4px; font-family: var(--f-font-display, inherit); font-size: 26px; line-height: 1.2; font-weight: 800; color: var(--fmh-ink); }
.fm-help__lede { margin: 0; max-width: 760px; color: var(--fmh-ink-2); }
.fm-help__note { margin: 0; color: var(--fmh-muted); font-size: 14px; }
.fm-help__fact { font-weight: 700; color: var(--fmh-ink); }
.fm-help__fact.is-short { white-space: nowrap; }
.fm-help__ui { font-weight: 700; color: var(--fmh-ink); }
.fm-help__link { color: var(--fmh-accent); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }
.fm-help__link:hover { color: var(--fmh-solid); }
.fm-help a:focus-visible, .fm-help summary:focus-visible, .fm-help button:focus-visible { outline: 2px solid var(--fmh-accent); outline-offset: 2px; border-radius: 6px; }

/* the list of steps */
.fm-help__index ol { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 4px 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fm-help__index a { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 4px 6px; border-radius: var(--f-r-sm, 10px); color: var(--fmh-ink-2); font-weight: 700; text-decoration: none; min-width: 0; }
.fm-help__index a > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.fm-help__index a:hover { background: var(--fmh-soft); color: var(--fmh-solid); }
.fm-help__num { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; background: var(--fmh-soft);
  color: var(--fmh-solid); font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; }
.fm-help__num-big { width: 40px; height: 40px; background: var(--fmh-solid); color: #fff; font-size: 16px; }

/* one step */
.fm-help__step { scroll-margin-top: 84px; }
.fm-help__head { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.fm-help__title { margin: 0; font-size: 19px; font-weight: 800; color: var(--fmh-ink); line-height: 1.3; min-width: 0; overflow-wrap: anywhere; }
.fm-help__steplede { margin: 0 0 12px; max-width: 760px; }
.fm-help__after { margin: 12px 0 0; max-width: 760px; }
.fm-help__do { margin: 0; padding: 0 0 0 1.4em; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; max-width: 780px; }
.fm-help__do > li { padding-left: 4px; min-width: 0; }
.fm-help__do > li::marker { color: var(--fmh-accent); font-weight: 800; }
.fm-help__do > li.fm-help__li-wide { list-style: none; margin-left: -1.4em; padding-left: 0; }
.fm-help__ul { margin: 6px 0 10px; padding-left: 1.3em; display: grid; gap: 6px; }
.fm-help__shots { display: grid; gap: 16px; margin: 16px 0; }
.fm-help__shots:empty { display: none; }
.fm-help__shot { margin: 0; border: 1px solid var(--fmh-line); border-radius: var(--f-r, 14px); overflow: hidden; background: var(--fmh-well); box-shadow: var(--f-shadow-1, none); }
.fm-help__shot img { display: block; width: 100%; height: auto; }
.fm-help__actions { margin: 14px 0 0; }
/* (a.<class>: Fitmark colors every link in the app, and a class alone loses to that rule; found in the page's own picture, where the
   button's words were violet on violet) */
.fm-help a.fm-help__go { display: inline-flex; align-items: center; gap: 0.28em; min-height: 44px; padding: 0 18px; border-radius: var(--f-r-pill, 999px); background: var(--fmh-solid); color: #fff; font-weight: 700; text-decoration: none; }
.fm-help a.fm-help__go:hover { background: var(--fmh-solid-hi); }
/* a name or a number inside the button wears the button's own color, never the dark ink of a fact in a sentence */
.fm-help__go .fm-help__fact, .fm-help__go .fm-help__ui { color: inherit; }

/* the plans table: columns on a wide screen, one block a row on a narrow one (no sideways scroll) */
.fm-help__tablewrap { margin: 6px 0 8px; max-width: 100%; }
.fm-help__table { width: 100%; border-collapse: collapse; font-size: 14px; }
.fm-help__table th, .fm-help__table td { padding: 9px 10px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--fmh-line); }
.fm-help__table thead th { color: var(--fmh-ink); font-weight: 800; border-bottom: 2px solid var(--fmh-line); }
.fm-help__table th[scope="row"] { font-weight: 700; color: var(--fmh-ink); }
.fm-help__minenote { display: block; margin-top: 2px; font-size: 12px; font-weight: 600; color: var(--fmh-accent); }
@media (max-width: 760px) {
  .fm-help__table, .fm-help__table tbody, .fm-help__table tr, .fm-help__table th, .fm-help__table td { display: block; width: auto; }
  .fm-help__table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .fm-help__table tr { padding: 10px 0; border-bottom: 1px solid var(--fmh-line); }
  .fm-help__table th[scope="row"] { padding: 0 0 4px; border: 0; }
  .fm-help__table td { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; border: 0; text-align: right; }
  .fm-help__table td::before { content: attr(data-level-name); flex: none; color: var(--fmh-muted); font-weight: 600; text-align: left; }
}

/* the FAQ */
.fm-faq__find { padding-bottom: 12px; }
.fm-faq__search { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 12px; border: 1px solid var(--f-line-strong, #A9A2BF); border-radius: var(--f-r-sm, 10px); background: var(--fmh-card); color: var(--fmh-muted); margin-bottom: 12px; }
.fm-faq__search:focus-within { border-color: var(--fmh-accent); box-shadow: 0 0 0 2px color-mix(in oklab, var(--fmh-accent) 35%, transparent); }
.fm-faq__search svg { width: 20px; height: 20px; flex: none; }
.fm-faq__search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; font-size: 16px; color: var(--fmh-ink); min-height: 44px; }
.fm-faq__clear { flex: none; border: 0; background: none; color: var(--fmh-accent); font: inherit; font-weight: 700; cursor: pointer; min-height: 40px; padding: 0 4px; }
.fm-faq__topics { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 4px; }
.fm-help a.fm-faq__topic { display: inline-flex; align-items: center; min-height: 36px; padding: 0 12px; border-radius: var(--f-r-pill, 999px); border: 1px solid var(--fmh-line); background: var(--fmh-well); color: var(--fmh-ink-2); font-size: 13.5px; font-weight: 700; text-decoration: none; }
.fm-help a.fm-faq__topic:hover { background: var(--fmh-soft); color: var(--fmh-solid); border-color: transparent; }
.fm-faq__say { margin-top: 8px; }
.fm-faq__say:empty { display: none; }
.fm-faq__group { scroll-margin-top: 84px; }
.fm-faq__group > .fm-help__title { margin-bottom: 6px; }
.fm-faq__item { border-top: 1px solid var(--fmh-line); scroll-margin-top: 84px; }
.fm-faq__item:first-of-type { border-top: 0; }
.fm-faq__q { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; min-height: 48px; padding: 12px 2px; cursor: pointer; list-style: none;
  font-weight: 700; color: var(--fmh-ink); }
.fm-faq__q > span { min-width: 0; overflow-wrap: anywhere; }
.fm-faq__q::-webkit-details-marker { display: none; }
.fm-faq__q::after { content: ''; flex: none; width: 9px; height: 9px; margin: 6px 4px 0 0; border-right: 2px solid var(--fmh-muted); border-bottom: 2px solid var(--fmh-muted); transform: rotate(45deg); transition: transform 160ms ease; }
.fm-faq__item[open] > .fm-faq__q::after { transform: rotate(225deg); margin-top: 10px; }
.fm-faq__q:hover { color: var(--fmh-accent); }
.fm-faq__a { padding: 0 2px 14px; max-width: 780px; }
.fm-faq__a p { margin: 0 0 8px; }
.fm-faq__a p:last-child { margin-bottom: 0; }
.fm-faq__none .fm-help__note { margin: 0; }

@media (max-width: 720px) {
  .fm-help { font-size: 15px; }
  .fm-help > .fm-hpanel { padding: 16px 14px; }
  .fm-help__h { font-size: 22px; }
  .fm-help__index ol { grid-template-columns: minmax(0, 1fr); }
  .fm-help__head { gap: 10px; }
  .fm-help__num-big { width: 34px; height: 34px; }
  .fm-help__title { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) { .fm-faq__q::after { transition: none; } }

/* the Help group at the bottom of Fitmark's own menu (app/js/quiz/core.js HELP) */
.fm-menu__help { display: grid; gap: 2px; margin-top: auto; padding-top: 10px; }
.fm-menu__label { display: block; padding: 6px 12px 4px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--f-side-ink-muted); }
@media (min-width: 961px) {
  html.rail-collapsed .fm-menu__label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
}
/* a way to the answer, from the place a member gets stuck (an empty list, a limit) */
.fm-helplink { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--f-accent-strong, #4A31B5); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }
.fm-helplink svg { width: 18px; height: 18px; flex: none; }
.fm-helplink:hover { color: var(--f-ink, #160B2E); }
.fm-helpline { margin: 8px 0; }
/* a menu item put away (no business yet: only Help shows) stays put away though the item is a flex row */
.fm-menu__item[hidden] { display: none; }
