/* ═══════════════════════════════════════════════════════════════════════════
   ems-plan.css: My Plan on the right edge (assets/js/ems-plan.js) and the
   Dashboard's next-step card that opens it (tools/dashboard.js). Tyler 11-08:
   My Plan is a tab on the right, the Dashboard is where you start, and the
   plan is ONE guided track. Red is "your next step" (DESIGN.md rule 2).
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── the panel body ───────────────────────────────────────────────────────── */
.pl-body { padding-top: 14px; }
.pl-body > * { max-width: 760px; }

.pl-tabs { display: flex; gap: 4px; padding: 4px; margin-bottom: 18px; border-radius: 14px; background: #eef1f6; }
.pl-tab {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px;
  border: 0; border-radius: 11px; background: transparent; cursor: pointer;
  font: 600 14px/1 var(--ems-font-ui); color: var(--ems-mute);
  transition: background-color var(--ems-dur) var(--ems-ease), color var(--ems-dur) var(--ems-ease), box-shadow var(--ems-dur) var(--ems-ease);
}
.pl-tab:hover { color: var(--ems-navy-700); }
.pl-tab.is-on { background: #fff; color: var(--ems-navy-800); box-shadow: 0 1px 2px rgba(15, 23, 42, .08), 0 4px 12px -6px rgba(15, 23, 42, .18); }
.pl-tab b { min-width: 22px; padding: 3px 7px; border-radius: 99px; background: var(--ems-navy-50); color: var(--ems-navy-600); font: 700 11.5px/1 var(--ems-font-ui); }
.pl-tab:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(42, 56, 144, .3); }

/* My Plan's one mark (ems-plan.js ICON): the edge button, the band, the tab */
.pl-mark { display: inline-grid; place-items: center; flex: none; }
.pl-mark svg { width: 100%; height: 100%; display: block; }

/* summary: the % and what it is counting toward */
.pl-sum { padding: 18px 20px; margin-bottom: 18px; border-radius: 16px; background: #fff; border: 1px solid var(--ems-line); }
.pl-sum-m { display: flex; align-items: center; gap: 16px; }
.pl-sum-m > div:nth-child(2) { flex: 1; min-width: 0; }
.pl-sum-edit { flex: none; align-self: flex-start; }
.pl-sum-n { font: 800 38px/1 var(--ems-font-display); letter-spacing: -.03em; color: var(--ems-navy-700); font-variant-numeric: tabular-nums; }
.pl-sum-n small { font-size: 20px; margin-left: 1px; }
.pl-sum-m b { display: block; font: 700 15.5px/1.3 var(--ems-font-ui); color: var(--ems-ink); }
.pl-sum-m span { display: block; margin-top: 2px; font: 400 13.5px/1.4 var(--ems-font-body); color: var(--ems-mute); }
.pl-sum-bar { height: 8px; margin: 14px 0 0; border-radius: 99px; background: var(--ems-line); overflow: hidden; }
.pl-sum-bar > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--ems-good), var(--ems-navy-500)); transition: width .6s var(--ems-ease-out); }
.pl-link { background: none; border: 0; padding: 4px 6px; cursor: pointer; font: 600 13px/1.3 var(--ems-font-ui); color: var(--ems-navy-500); text-decoration: underline; text-underline-offset: 3px; }
.pl-link:hover { color: var(--ems-navy-800); }

.pl-alldone { display: flex; gap: 14px; align-items: center; padding: 16px 18px; margin-bottom: 16px; border-radius: 16px; background: #ecfdf3; color: #14532d; }
.pl-alldone > span { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--ems-good); color: #fff; flex: none; }
.pl-alldone p { margin: 2px 0 0; font-size: 14px; }

/* ── the track: one column, dots joined by a line ─────────────────────────── */
.pl-steps { position: relative; list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pl-step { position: relative; display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 14px; align-items: start; animation: pl-in .42s var(--ems-ease-out) both; animation-delay: calc(var(--d, 0) * 45ms); }
@keyframes pl-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.pl-step:not(:last-child)::before { /* the line down to the next dot */
  content: ""; position: absolute; left: 18px; top: 40px; bottom: -12px; width: 2px; border-radius: 2px; background: var(--ems-line);
}
.pl-step.is-done:not(:last-child)::before { background: var(--ems-good); }
.pl-dot {
  position: relative; z-index: 1; display: grid; place-items: center; width: 38px; height: 38px; margin-top: 6px; border-radius: 50%;
  background: #fff; border: 2px solid var(--ems-line-2); color: var(--ems-mute-2); font: 700 15px/1 var(--ems-font-display);
}
.pl-step.is-done .pl-dot { background: var(--ems-good); border-color: var(--ems-good); color: #fff; }
.pl-step.is-now .pl-dot { margin-top: 18px; background: var(--ems-navy-500); border-color: var(--ems-navy-500); color: #fff; box-shadow: 0 0 0 6px rgba(42, 56, 144, .14); }
.pl-step.is-skipped .pl-dot { border-style: dashed; }

/* a quiet row (done, later, skipped) */
.pl-row {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; text-align: left; cursor: pointer;
  border: 1px solid var(--ems-line); border-radius: 14px; background: #fff;
  transition: border-color var(--ems-dur) var(--ems-ease), box-shadow var(--ems-dur) var(--ems-ease), transform var(--ems-dur) var(--ems-ease);
}
.pl-row:hover { border-color: var(--ems-navy-200, #c7cdf0); box-shadow: 0 6px 18px -10px rgba(14, 21, 71, .35); transform: translateY(-1px); }
.pl-row:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(42, 56, 144, .3); }
.pl-row-ic { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--ems-navy-50); color: var(--ems-navy-600); }
.pl-row-m { flex: 1; min-width: 0; }
.pl-row-m b { display: block; font: 700 15px/1.3 var(--ems-font-ui); color: var(--ems-ink); }
.pl-row-m small { display: block; margin-top: 2px; font: 400 13px/1.45 var(--ems-font-body); color: var(--ems-mute); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-row-go { flex: none; font: 600 13px/1 var(--ems-font-ui); color: var(--ems-navy-500); opacity: .7; }
.pl-row:hover .pl-row-go { opacity: 1; }
.pl-step.is-done .pl-row { background: #fbfcfd; }
.pl-step.is-done .pl-row-m b { color: var(--ems-ink-2); }
.pl-step.is-done .pl-row-m small { color: var(--ems-good); font-weight: 600; }
.pl-step.is-done .pl-row-ic { background: #ecfdf3; color: var(--ems-good); }
.pl-step.is-later .pl-row { opacity: .92; }
/* started (pressed Start, not done yet) and in progress (EMS US is matching a mentor) */
.pl-step.is-started .pl-dot, .pl-step.is-progress .pl-dot { border-color: var(--ems-navy-500); color: var(--ems-navy-500); }
.pl-step.is-progress .pl-dot { border-style: dotted; }
.pl-state { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 99px; background: #fff4e0; color: #8a5300; font: 700 11px/1.4 var(--ems-font-ui); font-style: normal; vertical-align: 1px; }
.pl-row-col { min-width: 0; }
.pl-row-acts { display: flex; gap: 10px; margin: 6px 0 0 6px; }
.pl-mini { display: inline-flex; align-items: center; gap: 5px; min-height: 30px; padding: 4px 12px; border: 1px solid var(--ems-line); border-radius: 99px; background: #fff; color: var(--ems-navy-600); cursor: pointer; font: 600 12.5px/1 var(--ems-font-ui); }
.pl-mini:hover { border-color: var(--ems-navy-500); background: var(--ems-navy-50); }

/* the ONE lit step */
.pl-now {
  position: relative; overflow: hidden; isolation: isolate; padding: 20px 22px; border-radius: 18px; color: #fff;
  background: radial-gradient(600px 220px at 105% -30%, rgba(255, 255, 255, .16), transparent 62%), linear-gradient(118deg, var(--ems-navy-800), var(--ems-navy-500));
  box-shadow: var(--ems-raise);
}
.pl-now::after { content: ""; position: absolute; inset: auto 0 0 0; height: 3px; z-index: -1; background: linear-gradient(90deg, var(--ems-red-500), rgba(190, 30, 45, 0)); }
.pl-now-top { display: flex; align-items: center; gap: 14px; }
.pl-now-ic { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 13px; background: rgba(255, 255, 255, .13); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.pl-now-k { margin: 0 0 3px; display: flex; align-items: center; gap: 8px; font: 700 11.5px/1.2 var(--ems-font-ui); letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .78); }
.pl-next { padding: 3px 8px; border-radius: 99px; background: var(--ems-red-500); color: #fff; letter-spacing: .06em; }
.pl-now h3 { margin: 0; font: 800 21px/1.25 var(--ems-font-display); letter-spacing: -.015em; color: #fff; }
.pl-now-why { margin: 12px 0 0; font: 400 14.5px/1.55 var(--ems-font-body); color: rgba(255, 255, 255, .86); }
.pl-now .pl-because { margin-top: 12px; background: rgba(255, 255, 255, .14); color: #fff; }
.pl-now-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 16px; }
.pl-go {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 20px; border: 0; border-radius: var(--ems-r-md);
  background: #fff; color: var(--ems-navy-700); cursor: pointer; font: 600 15px/1.2 var(--ems-font-ui);
  box-shadow: 0 1px 2px rgba(14, 21, 71, .25), 0 10px 22px -10px rgba(0, 0, 0, .45);
  transition: transform var(--ems-dur) var(--ems-ease), background-color var(--ems-dur) var(--ems-ease);
}
.pl-go:hover { background: var(--ems-navy-50); transform: translateY(-1px); }
.pl-go:focus-visible { outline: none; box-shadow: 0 0 0 4px rgba(255, 255, 255, .45); }
.pl-skip { background: none; border: 0; padding: 4px 0; cursor: pointer; font: 600 13.5px/1.3 var(--ems-font-ui); color: rgba(255, 255, 255, .8); text-decoration: underline; text-underline-offset: 3px; }
.pl-skip:hover { color: #fff; }

/* The mentor beside the steps (never a step). */
.pl-beside { display: flex; align-items: center; gap: 12px; margin: 16px 0 0; padding: 12px 14px; border: 1px dashed var(--ems-line, #e3e7ef); border-radius: 14px; background: var(--ems-canvas, #f7f8fc); }
.pl-beside-ic { flex: none; width: 36px; height: 36px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--ems-gold-100, #fdf3d8); color: var(--ems-gold-700, #8a6200); font: 700 13px/1 var(--ems-font-ui); }
.pl-beside-ic img { width: 100%; height: 100%; object-fit: cover; }
.pl-beside.is-mentor .pl-beside-ic { background: var(--ems-navy-50, #eef1f9); color: var(--ems-navy-800, #1b2466); }
.pl-beside-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pl-beside-t small { font: 700 10.5px/1.2 var(--ems-font-ui); letter-spacing: .06em; text-transform: uppercase; color: var(--ems-mute); }
.pl-beside-t b { font: 700 14px/1.3 var(--ems-font-ui); color: var(--ems-ink, #0f172a); }
.pl-beside-t span { font: 400 12.5px/1.45 var(--ems-font-body); color: var(--ems-ink-2, #334155); }
.pl-foot-note { margin: 16px 0 0 52px; font: 400 13px/1.5 var(--ems-font-body); color: var(--ems-mute); }

/* ── Picked for you: Resources' rows, sized for the panel ─────────────────── */
.pl-res-lede { margin: 0 0 14px; font: 400 14px/1.5 var(--ems-font-body); color: var(--ems-mute); }
.pl-rg .rg-row { grid-template-columns: 176px minmax(0, 1fr) auto; gap: 18px; padding: 12px 16px 12px 12px; }
.pl-rg .rg-shot { aspect-ratio: 16 / 10; }
.pl-rg .rg-row-t { font-size: 16.5px; }
.pl-rg .rg-row-d { font-size: 14px; }
.pl-hub { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: auto; opacity: 1; }
.pl-hub small { font: 700 11px/1 var(--ems-font-ui); letter-spacing: .08em; text-transform: uppercase; }

/* why a step / a program is on THEIR plan: the goal it serves, or the answer */
.pl-why-tag { display: inline-block; margin: 6px 0 0; padding: 3px 10px; border-radius: 99px; background: var(--ems-navy-50); color: var(--ems-navy-700); font: 600 12px/1.45 var(--ems-font-ui); font-style: normal; }
.pl-why-tag.is-dark { margin-top: 12px; background: rgba(255, 255, 255, .14); color: #fff; }
.pl-row-m .pl-why-tag { margin-top: 7px; }
/* the answer of theirs that recommends a program, in place of its blurb */
.pl-rec-why { display: block; margin-top: 4px; font: 400 14px/1.5 var(--ems-font-body); color: var(--ems-ink-2); }
/* their own fact on the lit step: "Your last day: Jul 3, 2027 · about 8 months away" */
.pl-me { margin: 12px 0 0; padding: 10px 14px; border-radius: 12px; background: rgba(255, 255, 255, .1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); font: 600 14px/1.45 var(--ems-font-ui); color: #fff; }

/* a person wears a face: the mentor they were matched with */
.pl-face { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; overflow: hidden; background: var(--ems-navy-600); color: #fff; font: 700 14px/1 var(--ems-font-display); box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--ems-line); }
.pl-face img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pl-face.is-lg { width: 52px; height: 52px; font-size: 17px; box-shadow: 0 0 0 2px rgba(255, 255, 255, .7); }
.pl-row.has-face .pl-row-m b { color: var(--ems-ink); }
.pl-step.is-done .pl-row.has-face .pl-row-m small { color: var(--ems-ink-2); font-weight: 600; }

/* the dashboard's next step wears the mentor's face when it is theirs */
.ems-m-next-ic.is-face { overflow: hidden; border-radius: 50%; padding: 0; font: 700 16px/1 var(--ems-font-display); }
.ems-m-next-ic.is-face img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Settings -> Help & privacy: Your data (moved off the Dashboard) */
.set-data { margin-top: 18px; }
.set-data-t { margin: 8px 0 14px; font: 400 14.5px/1.55 var(--ems-font-body); color: var(--ems-mute); }
.set-data-acts { display: flex; flex-wrap: wrap; gap: 10px; }
.set-data-acts button { display: inline-flex; align-items: center; gap: 8px; }
.set-data-del { color: var(--ems-red-500); }

/* ── the Dashboard's next-step card ───────────────────────────────────────── */
.ems-m-next-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 14px; }
.ems-m-next-acts .ems-m-next-quiet { margin-top: 0; }
.ems-m-where .ems-because { margin-top: 8px; background: rgba(255, 255, 255, .14); color: #fff; }
/* the mentor request in flight: the hero has moved on, and says EMS US is on it */
.ems-m-next-note { display: flex; align-items: center; gap: 8px; margin: 10px 0 0; font: 600 13.5px/1.4 var(--ems-font-ui); color: rgba(255, 255, 255, .9); }
.ems-m-next-note svg { flex: none; opacity: .85; }
.ems-m-next-meter.is-door {
  align-self: stretch; display: flex; flex-direction: column; justify-content: center; padding: 14px 16px; margin: -6px -8px -6px 0;
  border: 0; border-radius: 16px; background: rgba(255, 255, 255, .08); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
  color: inherit; cursor: pointer; font: inherit; text-align: right;
  transition: background-color var(--ems-dur) var(--ems-ease);
}
.ems-m-next-meter.is-door:hover { background: rgba(255, 255, 255, .15); }
.ems-m-next-meter.is-door:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(255, 255, 255, .5); }
.ems-m-next-meter-go { margin-top: 10px; font: 600 13px/1 var(--ems-font-ui); color: #fff; opacity: .85; }

@media (max-width: 760px) {
  .pl-tab { gap: 6px; font-size: 13.5px; white-space: nowrap; }
    .pl-rg .rg-row { grid-template-columns: minmax(0, 1fr); }
  .pl-foot-note { margin-left: 0; }
  .ems-m-next-meter.is-door { margin: 0; text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  .pl-step { animation: none; }
  .pl-row, .pl-go { transition: none; }
}

/* ── Tools for this step (EMSPlan.helpsHtml, journey.js HELPERS) ─────────────
   The tools that help with a step, beside it: on the lit step here, on the
   Dashboard's next step (.is-dash) and in the step strip inside a tool
   (.is-strip, on white). Small and quiet: the step's own Start stays the one
   loud thing. */
.pl-helps { margin: 16px 0 0; padding-top: 14px; border-top: 1px solid var(--ems-line); }
.pl-helps.is-dark { border-top-color: rgba(255, 255, 255, .18); }
.pl-helps-k { margin: 0 0 8px; font: 700 11px/1.3 var(--ems-font-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ems-mute); }
.pl-helps.is-dark .pl-helps-k { color: rgba(255, 255, 255, .72); }
.pl-helps-l { display: flex; flex-wrap: wrap; gap: 8px; }
.pl-help { display: inline-flex; align-items: center; gap: 10px; min-height: 0; max-width: 100%; padding: 8px 12px 8px 8px; border: 0; border-radius: 12px; cursor: pointer; text-align: left;
  background: var(--ems-soft); color: var(--ems-navy-800); box-shadow: none; transition: background var(--ems-dur-fast), transform var(--ems-dur-fast); }
.pl-help:hover, .pl-help:focus-visible { background: var(--ems-navy-50); outline: none; }
.pl-help:active { transform: translateY(1px); }
.pl-helps.is-dark .pl-help { background: rgba(255, 255, 255, .1); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
.pl-helps.is-dark .pl-help:hover, .pl-helps.is-dark .pl-help:focus-visible { background: rgba(255, 255, 255, .2); }
.pl-help-ic { flex: none; width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: var(--ems-surface); color: var(--ems-navy-500); }
.pl-helps.is-dark .pl-help-ic { background: rgba(255, 255, 255, .16); color: #fff; }
.pl-help-t { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.pl-help-t b { font: 600 13.5px/1.25 var(--ems-font-ui); }
.pl-help-t small { font: 400 12px/1.3 var(--ems-font-ui); color: var(--ems-mute); }
.pl-helps.is-dark .pl-help-t small { color: rgba(255, 255, 255, .74); }
.pl-helps.is-dash { margin-top: 14px; padding-top: 12px; }
/* In the step strip: one line under the strip's own text. */
.gst-return:has(.pl-helps) { flex-wrap: wrap; }
.pl-helps.is-strip { flex: 1 1 100%; margin: 4px 0 0 38px; padding-top: 10px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.pl-helps.is-strip .pl-helps-k { margin: 0 4px 0 0; }
.pl-helps.is-strip .pl-help { padding: 5px 10px 5px 6px; }
.pl-helps.is-strip .pl-help-ic { width: 24px; height: 24px; border-radius: 7px; }
.pl-helps.is-strip .pl-help-t small { display: none; }
@media (max-width: 640px) { .pl-helps.is-strip { margin-left: 0; } .pl-help { flex: 1 1 100%; } }

/* ── The Dashboard's next step, slim (11-09) ──────────────────────────────────
   Tyler: "way too tall ... all it is is what's your next step". One row (the
   step + Start), then every step of the plan as a track, so done and left
   read at a glance. NAVY, not white (Tyler 11-09: "it's a header ... separate
   from the actual page"): it is the guide for the starting phase and goes
   away when the plan is done. Why/helper tools live in My Plan. */
.ems-ns { position: relative; overflow: hidden; isolation: isolate; margin: 0 0 22px; padding: 16px 20px 12px; border-radius: var(--ems-r-xl); color: #fff;
  background: radial-gradient(700px 240px at 105% -30%, rgba(255, 255, 255, .14), transparent 62%), linear-gradient(118deg, var(--ems-navy-800) 0%, var(--ems-navy-500) 100%);
  box-shadow: var(--ems-raise); }
.ems-ns::after { content: ""; position: absolute; inset: auto 0 0 0; height: 3px; z-index: -1; background: linear-gradient(90deg, var(--ems-red-500), rgba(190, 30, 45, 0)); }
.ns-row { display: flex; align-items: center; gap: 14px; }
.ns-ic { flex: none; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: rgba(255, 255, 255, .13); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); color: #fff; }
.ns-ic.is-face { overflow: hidden; border-radius: 50%; font: 700 15px/1 var(--ems-font-display); }
.ns-ic.is-face img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ns-body { flex: 1; min-width: 0; }
.ns-k { margin: 0 0 2px; font: 700 11px/1.2 var(--ems-font-ui); letter-spacing: .09em; text-transform: uppercase; color: var(--ems-red-200); }
.ns-k span { color: rgba(255, 255, 255, .72); letter-spacing: .04em; }
#view .ems-ns .ns-t-h, .ns-t-h { margin: 0; font: 700 19px/1.3 var(--ems-font-display); letter-spacing: -.01em; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ns-s { margin: 2px 0 0; font: 400 13.5px/1.4 var(--ems-font-body); color: rgba(255, 255, 255, .8); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ns-acts { flex: none; display: flex; align-items: center; gap: 16px; }
.ns-quiet { background: none; border: 0; padding: 4px 0; min-height: 0; box-shadow: none; cursor: pointer; font: 600 13px/1.2 var(--ems-font-ui); color: rgba(255, 255, 255, .78); }
.ns-quiet:hover, .ns-quiet:focus-visible { color: #fff; text-decoration: underline; text-underline-offset: 3px; outline: none; }
#view .ems-ns .ns-go, .ems-ns .ns-go { white-space: nowrap; background: #fff; color: var(--ems-navy-700); border: 0;
  box-shadow: 0 1px 2px rgba(14, 21, 71, .25), 0 10px 22px -10px rgba(0, 0, 0, .45); }
#view .ems-ns .ns-go:hover, .ems-ns .ns-go:hover { background: var(--ems-navy-50); color: var(--ems-navy-800); }
.ems-ns .ns-go:focus-visible { outline: none; box-shadow: 0 0 0 4px rgba(255, 255, 255, .45); }
/* Lit once after they skip the tour (11-16): two soft rings, then still. */
.ems-ns.is-pulse { animation: ns-pulse 1.6s var(--ems-ease-out) .5s 2; }
@keyframes ns-pulse { 0% { box-shadow: var(--ems-raise), 0 0 0 0 rgba(190, 30, 45, .55); } 70% { box-shadow: var(--ems-raise), 0 0 0 14px rgba(190, 30, 45, 0); } 100% { box-shadow: var(--ems-raise), 0 0 0 0 rgba(190, 30, 45, 0); } }
@media (prefers-reduced-motion: reduce) { .ems-ns.is-pulse { animation: none; outline: 3px solid var(--ems-red-500); outline-offset: 3px; } }
/* Later (11-16): the same step, folded to one line until they open it or it is done. */
.ems-ns.is-later { padding: 9px 14px 9px 12px; margin-bottom: 16px; }
.ems-ns.is-later .ns-ic { width: 30px; height: 30px; border-radius: 9px; }
.ems-ns.is-later .ns-body { display: flex; align-items: baseline; gap: 10px; }
.ems-ns.is-later .ns-k { margin: 0; flex: none; }
#view .ems-ns.is-later .ns-t-h, .ems-ns.is-later .ns-t-h { font-size: 15px; }
.ems-ns.is-later .ns-s, .ems-ns.is-later .ns-foot { display: none; }
.ems-ns.is-later .ns-go { min-height: 34px; padding: 0 14px; font-size: 13.5px; }
.ems-ns.is-done::after { display: none; }
.ems-ns.is-done .ns-ic { background: #fff; color: var(--ems-good); }
.ems-ns.is-done .ns-k { color: rgba(255, 255, 255, .8); }

.ns-foot { display: flex; align-items: center; gap: 12px; margin-top: 12px; padding-top: 10px; border-top: 1px solid rgba(255, 255, 255, .16); }
.ns-track { flex: 1; min-width: 0; display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.ns-t { flex: 1 1 0; min-width: 0; }
.ns-t button { width: 100%; min-height: 0; display: flex; align-items: center; gap: 7px; padding: 5px 8px 5px 5px; border: 0; border-radius: var(--ems-r-pill);
  background: none; box-shadow: none; cursor: pointer; text-align: left; font: 500 12.5px/1.2 var(--ems-font-ui); color: rgba(255, 255, 255, .7);
  transition: background-color var(--ems-dur-fast) var(--ems-ease); }
.ns-t button:hover, .ns-t button:focus-visible { background: rgba(255, 255, 255, .1); outline: none; }
.ns-dot { flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .14); color: rgba(255, 255, 255, .85); font: 700 11px/1 var(--ems-font-ui); }
.ns-dot .ic, .ns-dot svg { width: 12px; height: 12px; }
.ns-tl { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ns-t.is-done .ns-dot { background: var(--ems-good); color: #fff; }
.ns-t.is-done .ns-tl { color: rgba(255, 255, 255, .88); }
.ns-t.is-now button { background: rgba(255, 255, 255, .13); }
.ns-t.is-now .ns-dot { background: var(--ems-red-500); color: #fff; }
.ns-t.is-now .ns-tl { color: #fff; font-weight: 700; }
.ns-t.is-progress .ns-dot { background: var(--ems-gold-400); color: var(--ems-navy-900); }
.ns-t.is-started .ns-dot { box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .7); background: none; color: #fff; }
.ns-t.is-skipped .ns-tl { text-decoration: line-through; text-decoration-color: rgba(255, 255, 255, .4); }
.ns-plan { flex: none; min-height: 0; padding: 5px 4px; border: 0; background: none; box-shadow: none; cursor: pointer; white-space: nowrap; font: 600 12.5px/1.2 var(--ems-font-ui); color: rgba(255, 255, 255, .85); }
.ns-plan b { color: #fff; }
/* The mentor, beside the steps (never a step): a quiet pill that opens the Mentor tab. */
.ns-mentor { flex: none; max-width: 280px; min-height: 0; display: inline-flex; align-items: center; gap: 7px; padding: 3px 11px 3px 3px;
  border: 1px solid rgba(255, 255, 255, .24); border-radius: var(--ems-r-pill); background: rgba(255, 255, 255, .06); box-shadow: none; cursor: pointer;
  white-space: nowrap; font: 600 12.5px/1.2 var(--ems-font-ui); color: rgba(255, 255, 255, .92); transition: background-color var(--ems-dur-fast) var(--ems-ease); }
.ns-mentor:hover, .ns-mentor:focus-visible { background: rgba(255, 255, 255, .14); outline: none; }
.ns-m-ic { flex: none; width: 22px; height: 22px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--ems-gold-400); color: var(--ems-navy-900); font: 700 10px/1 var(--ems-font-ui); }
.ns-m-ic img { width: 100%; height: 100%; object-fit: cover; }
.ns-m-ic .ic, .ns-m-ic svg { width: 13px; height: 13px; }
.ns-mentor.is-mentor .ns-m-ic { background: #fff; color: var(--ems-navy-800); }
.ns-m-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.ns-m-n { flex: none; min-width: 18px; height: 18px; padding: 0 5px; box-sizing: border-box; border-radius: 9px; display: grid; place-items: center; background: var(--ems-red-500); color: #fff; font: 700 10.5px/1 var(--ems-font-ui); }
.ns-plan:hover, .ns-plan:focus-visible { color: #fff; text-decoration: underline; text-underline-offset: 3px; outline: none; }
/* Narrower card (a container query: the card, not the window, decides): the
   current step keeps its name, the others are their dot; narrower still, the
   title above already names it, so every step is a dot. Hover = the name. */
.ems-ns { container-type: inline-size; }
@container (max-width: 1200px) {
  .ns-t:not(.is-now) { flex: none; }
  .ns-t:not(.is-now) .ns-tl { display: none; }
  .ns-t:not(.is-now) button { padding: 5px; }
  .ns-t.is-now { flex: 0 1 auto; }
  .ns-track { gap: 2px; }
}
@container (max-width: 560px) {
  .ns-t.is-now .ns-tl { display: none; }
  .ns-t.is-now { flex: none; }
  .ns-plan-go { display: none; }
  .ns-t.is-now button { padding: 5px; }
  .ns-m-t { display: none; }
  .ns-mentor { padding: 3px; }
}
@media (max-width: 760px) {
  .ems-ns { padding: 14px 14px 10px; border-radius: 18px; }
  .ns-row { flex-wrap: wrap; }
  .ns-acts { flex: 1 1 100%; justify-content: flex-end; }
  #view .ems-ns .ns-t-h, .ns-t-h { white-space: normal; }
  .ns-s { white-space: normal; }
  .ems-ns.is-later .ns-row { flex-wrap: nowrap; }
  .ems-ns.is-later .ns-acts { flex: none; gap: 10px; }
  .ems-ns.is-later .ns-k { display: none; }
  #view .ems-ns.is-later .ns-t-h, .ems-ns.is-later .ns-t-h { white-space: nowrap; }
}

/* ── The guide (11-15): the same navy card, never a white strip ─────────────
   Tyler: "This blue area is the max that we're going to get." After Start /
   Continue the card's headline is the one thing to do; on a tool page it sits
   above the page (#gstReturn), on the Dashboard the card itself turns
   (ems-guided.js paintReturn). */
.ems-ns.is-guide { animation: gst-arrive .45s var(--ems-ease-out) 1; }
#gstReturn.ems-ns { margin: 0 0 18px; }
.ems-ns.is-guide .ns-k span { text-transform: none; letter-spacing: .01em; }
.ems-ns.is-guide .gst-do { white-space: normal; }
.ems-ns.is-guide .ns-s { white-space: normal; }
.ns-ic.gst-n { font: 700 17px/1 var(--ems-font-display); }
.ems-ns .gst-return-go { min-height: 40px; }
.ems-ns .pl-helps.is-strip { margin: 10px 0 0 56px; padding-top: 10px; }
@media (max-width: 760px) { .ems-ns .pl-helps.is-strip { margin-left: 0; } }

/* the page's own choices, in the card: quiet outlined buttons beside the main one */
.ems-ns .ns-ghost { min-height: 40px; padding: 0 14px; border-radius: var(--ems-r-md); border: 0; cursor: pointer; white-space: nowrap;
  background: rgba(255, 255, 255, .1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28); color: #fff; font: 600 13.5px/1 var(--ems-font-ui); }
.ems-ns .ns-ghost:hover, .ems-ns .ns-ghost:focus-visible { background: rgba(255, 255, 255, .2); outline: none; }
.ems-ns.is-guide .ns-acts { gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.ems-ns.is-guide .ns-s { max-width: 72ch; }
/* ── the guided tour (ems-tour.js): a pop-up pinned to the real control ───
   It lives inside #view, so it scrolls WITH the thing it points at. Navy, like
   the guide card; the control it talks about wears a steady ring. */
.gtour { position: absolute; z-index: 40; width: min(340px, calc(100% - 16px)); padding: 16px 16px 12px; border-radius: 14px;
  background: var(--ems-navy-800); color: #fff; box-shadow: 0 18px 40px -14px rgba(14, 21, 71, .6); animation: gst-arrive .3s var(--ems-ease-out) 1; }
.gtour::before { content: ""; position: absolute; top: -6px; left: calc(var(--gtour-x, 50%) - 7px); width: 14px; height: 14px; background: inherit; transform: rotate(45deg); border-radius: 3px; }
.gtour.is-above::before { top: auto; bottom: -6px; }
.gtour-x { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; min-height: 0; padding: 0; display: grid; place-items: center; border: 0; border-radius: 8px;
  background: none; box-shadow: none; color: rgba(255, 255, 255, .75); cursor: pointer; }
.gtour-x:hover, .gtour-x:focus-visible { background: rgba(255, 255, 255, .14); color: #fff; outline: none; }
.gtour-k { margin: 0 34px 4px 0; font: 700 10.5px/1.3 var(--ems-font-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ems-red-200); }
#view .gtour-t, .gtour-t { margin: 0 34px 6px 0; font: 700 16px/1.3 var(--ems-font-display); color: #fff; }
.gtour-p { margin: 0; font: 400 13.5px/1.45 var(--ems-font-body); color: rgba(255, 255, 255, .86); }
.gtour-f { display: flex; align-items: center; gap: 8px; margin-top: 14px; }
.gtour-dots { flex: 1; display: flex; gap: 5px; }
.gtour-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, .3); }
.gtour-dots i.is-on { background: #fff; width: 16px; border-radius: 3px; }
.gtour-back, .gtour-next { min-height: 34px; padding: 0 14px; border: 0; border-radius: 9px; cursor: pointer; font: 700 13px/1 var(--ems-font-ui); box-shadow: none; }
.gtour-back { background: none; color: rgba(255, 255, 255, .85); }
.gtour-off { order: -1; margin-right: auto; padding: 0; min-height: 0; border: 0; background: none; box-shadow: none; cursor: pointer; font: 600 12px/1.2 var(--ems-font-ui); color: rgba(255, 255, 255, .65); text-decoration: underline; text-underline-offset: 2px; }
.gtour-off:hover, .gtour-off:focus-visible { color: #fff; outline: none; }
.gtour-back:hover { color: #fff; text-decoration: underline; }
.gtour-next { background: #fff; color: var(--ems-navy-800); }
.gtour-next:hover, .gtour-next:focus-visible { background: var(--ems-navy-50); outline: none; }
.gtour-on { outline: 3px solid var(--ems-red-500); outline-offset: 4px; border-radius: 12px; transition: outline-color .2s; }
@media (prefers-reduced-motion: reduce) { .gtour { animation: none; } }
/* a step on the track says its name and where it stands, styled (no browser tooltip) */
.ns-t button { position: relative; }
.ns-t button[data-tip]::after { content: attr(data-tip); position: absolute; left: 0; bottom: calc(100% + 6px); z-index: 3; white-space: nowrap; pointer-events: none;
  padding: 6px 10px; border-radius: 8px; background: #fff; color: var(--ems-navy-800); font: 600 12.5px/1.2 var(--ems-font-ui);
  box-shadow: 0 6px 18px -6px rgba(14, 21, 71, .45); opacity: 0; transform: translateY(3px); transition: opacity .15s, transform .15s; }
.ns-t button[data-tip]:hover::after, .ns-t button[data-tip]:focus-visible::after { opacity: 1; transform: none; }
.ns-t.is-now button[data-tip]::after { display: none; }
@media (prefers-reduced-motion: reduce) { .ems-ns.is-guide { animation: none !important; } }

/* ── The sidebar: a tool you have saved work in wears a small tick ──────────
   ems-guided.js markNav, from EMSToolHome.savedFor (the same history the
   tool's own page lists). Not a favourite to manage: the work is the proof. */
#nav a .nav-done { margin-left: auto; flex: none; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .16); color: #fff; }
#nav a .nav-done svg { width: 11px; height: 11px; }
#nav a.active .nav-done { background: var(--ems-good); }
#nav a.is-guide-next .nav-done { display: none; }
