/* =============================================================================
   fh-manual.css v1.1.0 — In-app User Manual (Family Houses)
   Reader overlay, header call-to-action and per-app "How to use" links.
   v1.1.0: minimise / maximise, previous / next topic, reading options
           (text size via --gp-man-scale, line spacing, easy-read font, high contrast, dark).
   Article sizes are in em so the whole article scales from one font-size.
   ============================================================================= */

.gp-man-overlay, .gp-man-cta, .gp-man-apphelp, .gp-man-helpbtn {
  --gp-man-ink: #0f172a;
  --gp-man-text: #334155;
  --gp-man-muted: #64748b;
  --gp-man-line: #e2e8f0;
  --gp-man-soft: #f8fafc;
  --gp-man-brand: #6366f1;
  --gp-man-brand-2: #8b5cf6;
  --gp-man-pos: #059669;
  --gp-man-neg: #dc2626;
}

/* ── Header call-to-action (replaces the user name) ───────────────────── */
.gp-man-cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px 7px 10px; border-radius: 999px;
  background: linear-gradient(135deg, #eef2ff, #f5f3ff);
  border: 1px solid #c7d2fe; color: #4338ca !important;
  font-size: 13px; font-weight: 600; text-decoration: none !important; line-height: 1.2;
  cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s;
}
.gp-man-cta:hover { background: linear-gradient(135deg, #e0e7ff, #ede9fe); box-shadow: 0 4px 14px rgba(99,102,241,.22); transform: translateY(-1px); }
.gp-man-cta:focus-visible { outline: 2px solid var(--gp-man-brand); outline-offset: 2px; }
.gp-man-cta-ico {
  width: 22px; height: 22px; border-radius: 50%; display: inline-grid; place-items: center;
  background: linear-gradient(135deg, var(--gp-man-brand), var(--gp-man-brand-2)); color: #fff; font-size: 11px;
}
.gp-man-cta-arrow { transition: transform .15s; font-size: 11px; }
.gp-man-cta:hover .gp-man-cta-arrow { transform: translateX(3px); }
@media (prefers-reduced-motion: no-preference) {
  .gp-man-cta-ico { animation: gp-man-pulse 2.6s ease-in-out 3; }
}
@keyframes gp-man-pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(99,102,241,.45); } 50% { box-shadow: 0 0 0 6px rgba(99,102,241,0); } }

/* ── Per-app help strip (Split Expenses / Budget) ─────────────────────── */
.gp-man-apphelp {
  display: flex; align-items: center; justify-content: flex-end; gap: 6px; flex-wrap: wrap;
  font-size: 12px; color: var(--gp-man-muted); padding: 8px 14px 0;
}
.gp-man-apphelp a {
  color: var(--gp-man-brand) !important; font-weight: 600; text-decoration: none !important; cursor: pointer;
  display: inline-flex; align-items: center; gap: 5px;
}
.gp-man-apphelp a:hover { text-decoration: underline !important; }

/* Modal header "?" button */
.gp-fh-modal-wbtn.gp-man-helpbtn { color: var(--gp-man-brand); font-weight: 700; }

/* ── Overlay ──────────────────────────────────────────────────────────── */
html.gp-man-lock, html.gp-man-lock body { overflow: hidden !important; }
.gp-man-overlay {
  position: fixed; inset: 0; z-index: 100050;
  background: rgba(15,23,42,.6); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; padding: 24px;
  font-family: inherit;
}
.gp-man-overlay[hidden] { display: none; }
.gp-man-panel {
  width: 100%; max-width: 1180px; height: 100%; max-height: 920px;
  background: #fff; border-radius: 16px; overflow: hidden;
  display: flex; flex-direction: column; box-shadow: 0 30px 80px rgba(0,0,0,.35);
}
@media (prefers-reduced-motion: no-preference) {
  .gp-man-panel { animation: gp-man-in .22s ease-out; }
}
@keyframes gp-man-in { from { opacity: 0; transform: translateY(12px) scale(.985); } to { opacity: 1; transform: none; } }

.gp-man-head {
  display: flex; align-items: center; gap: 12px; padding: 12px 18px;
  border-bottom: 1px solid var(--gp-man-line); background: var(--gp-man-soft);
}
.gp-man-head-title { flex: 1; min-width: 0; }
.gp-man-head-kicker { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--gp-man-brand); font-weight: 700; }
.gp-man-head h2 { margin: 2px 0 0; font-size: 17px; color: var(--gp-man-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gp-man-btn {
  min-width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--gp-man-line);
  background: #fff; color: var(--gp-man-muted); cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
  gap: 6px; flex-shrink: 0; padding: 0 9px; font: inherit; font-size: 16px; line-height: 1;
}
.gp-man-btn:hover:not(:disabled) { color: var(--gp-man-ink); border-color: #cbd5e1; background: #f8fafc; }
.gp-man-btn:focus-visible { outline: 2px solid var(--gp-man-brand); outline-offset: 2px; }
.gp-man-btn:disabled { opacity: .4; cursor: default; }
.gp-man-btn.active { background: #eef2ff; border-color: #c7d2fe; color: #4338ca; }
.gp-man-close:hover:not(:disabled) { color: #b91c1c; border-color: #fecaca; background: #fef2f2; }
.gp-man-navtoggle { display: none; }
.gp-man-head { position: relative; flex-wrap: nowrap; }
.gp-man-pager { display: flex; align-items: center; gap: 6px; }
.gp-man-step em { font-style: normal; font-size: 13px; font-weight: 600; }
.gp-man-step span { font-size: 20px; margin-top: -2px; }
.gp-man-pos { font-size: 12px; color: var(--gp-man-muted); min-width: 40px; text-align: center; font-variant-numeric: tabular-nums; }
.gp-man-wctl { display: flex; align-items: center; gap: 6px; padding-left: 10px; margin-left: 4px; border-left: 1px solid var(--gp-man-line); }
.gp-man-aa { font-weight: 700; font-family: Georgia, 'Times New Roman', serif; font-size: 17px; }
.gp-man-aa small { font-size: 12px; }
.gp-man-maxbtn { font-size: 15px; }

/* Reading options popover */
.gp-man-textpanel {
  position: absolute; top: calc(100% + 6px); right: 18px; z-index: 5; width: 340px; max-width: calc(100vw - 24px);
  background: #fff; border: 1px solid var(--gp-man-line); border-radius: 14px; box-shadow: 0 18px 50px rgba(15,23,42,.22);
  padding: 14px 16px 10px; color: var(--gp-man-text); font-size: 13px;
}
.gp-man-textpanel[hidden] { display: none; }
.gp-man-tp-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px dashed var(--gp-man-line); }
.gp-man-tp-row[hidden] { display: none; }
.gp-man-tp-label { font-weight: 700; color: var(--gp-man-ink); white-space: nowrap; }
.gp-man-tp-ctl { display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; }
.gp-man-opt {
  border: 1px solid var(--gp-man-line); background: #fff; color: var(--gp-man-text); border-radius: 8px;
  padding: 6px 10px; font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; line-height: 1.2;
}
.gp-man-opt:hover:not(:disabled) { border-color: #c7d2fe; }
.gp-man-opt:disabled { opacity: .4; cursor: default; }
.gp-man-opt.active { background: var(--gp-man-brand); border-color: var(--gp-man-brand); color: #fff; }
.gp-man-opt:focus-visible { outline: 2px solid var(--gp-man-brand); outline-offset: 2px; }
.gp-man-size-val { min-width: 58px; font-variant-numeric: tabular-nums; }
.gp-man-size-up { font-size: 15px; }
.gp-man-opt-easy { font-family: Verdana, Tahoma, 'Segoe UI', sans-serif; }
.gp-man-tp-foot { display: flex; justify-content: space-between; align-items: center; padding-top: 8px; font-size: 11.5px; color: var(--gp-man-muted); }
.gp-man-link { border: 0; background: none; color: var(--gp-man-brand); font: inherit; font-weight: 700; cursor: pointer; padding: 0; }
.gp-man-link:hover { text-decoration: underline; }

/* Previous / next at the end of each topic */
.gp-man-secnav { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 18px 0 4px; }
.gp-man-secnav a {
  display: block; padding: 10px 14px; border: 1px solid var(--gp-man-line); border-radius: 12px;
  text-decoration: none !important; color: var(--gp-man-text) !important; background: var(--gp-man-soft); font-weight: 400 !important;
}
.gp-man-secnav a:hover { border-color: #c7d2fe; background: #f5f7ff; }
.gp-man-secnav small { display: block; font-size: .78em; color: var(--gp-man-muted); font-weight: 600; }
.gp-man-secnav b { color: var(--gp-man-brand); font-size: .93em; }
.gp-man-secnav-next { text-align: right; grid-column: 2; }
.gp-man-sec--reading { background: #fffbeb; box-shadow: 0 0 0 10px #fffbeb; border-radius: 4px; }

.gp-man-body { flex: 1; min-height: 0; display: flex; }

/* Nav */
.gp-man-nav {
  width: 270px; flex-shrink: 0; overflow-y: auto; padding: 16px 12px 24px;
  border-right: 1px solid var(--gp-man-line); background: #fbfcfe;
}
.gp-man-nav-group + .gp-man-nav-group { margin-top: 18px; }
.gp-man-nav-label { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: #94a3b8; font-weight: 700; padding: 0 10px 6px; }
.gp-man-nav-guide, .gp-man-nav-sec {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 9px;
  color: var(--gp-man-text) !important; text-decoration: none !important; font-size: 13.5px; line-height: 1.3;
}
.gp-man-nav-guide:hover, .gp-man-nav-sec:hover { background: #f1f5f9; }
.gp-man-nav-guide.active { background: #eef2ff; color: #3730a3 !important; font-weight: 600; }
.gp-man-nav-guide.is-soon { color: #94a3b8 !important; cursor: default; }
.gp-man-nav-guide.is-soon:hover { background: transparent; }
.gp-man-nav-guide em { margin-left: auto; font-style: normal; font-size: 10px; background: #f1f5f9; color: #94a3b8; padding: 2px 7px; border-radius: 999px; }
.gp-man-nav-ico { width: 22px; text-align: center; font-size: 16px; }
.gp-man-nav-num {
  width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center;
  font-size: 11px; font-weight: 700; background: #f1f5f9; color: var(--gp-man-muted);
}
.gp-man-nav-sec.active { color: #3730a3 !important; font-weight: 600; background: #f5f7ff; }
.gp-man-nav-sec.active .gp-man-nav-num { background: var(--gp-man-brand); color: #fff; }

/* Article */
.gp-man-article {
  flex: 1; min-width: 0; overflow-y: auto; padding: 26px 40px 60px; scroll-behavior: smooth;
  color: var(--gp-man-text); font-size: calc(15px * var(--gp-man-scale, 1)); line-height: var(--gp-man-lh, 1.65); outline: none;
}
@media (prefers-reduced-motion: reduce) { .gp-man-article { scroll-behavior: auto; } }
.gp-man-article > * { max-width: 57em; }

.gp-man-hero {
  display: flex; gap: 18px; align-items: flex-start; padding: 22px 24px; border-radius: 14px; margin-bottom: 8px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--gp-man-accent) 12%, #fff), #fff 70%);
  border: 1px solid color-mix(in srgb, var(--gp-man-accent) 25%, #fff);
}
@supports not (background: color-mix(in srgb, red 10%, white)) {
  .gp-man-hero { background: linear-gradient(135deg, #eef2ff, #fff 70%); border-color: #e0e7ff; }
}
.gp-man-hero-ico { font-size: 2.65em; line-height: 1; }
.gp-man-hero h1 { margin: 0 0 6px; font-size: 1.73em; line-height: 1.2; color: var(--gp-man-ink); }
.gp-man-hero p { margin: 0; font-size: 1.03em; }
.gp-man-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.gp-man-chips span { font-size: .8em; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: #fff; border: 1px solid var(--gp-man-line); color: var(--gp-man-text); }

.gp-man-sec { padding-top: 26px; scroll-margin-top: 8px; }
.gp-man-sec + .gp-man-sec { border-top: 1px dashed var(--gp-man-line); margin-top: 18px; }
.gp-man-sec h2 { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font-size: 1.33em; color: var(--gp-man-ink); line-height: 1.3; }
.gp-man-sec-num {
  width: 1.5em; height: 1.5em; border-radius: 9px; flex-shrink: 0; display: grid; place-items: center; font-size: .7em;
  background: linear-gradient(135deg, var(--gp-man-brand), var(--gp-man-brand-2)); color: #fff;
}
.gp-man-sec h3 { margin: 18px 0 8px; font-size: 1.07em; color: var(--gp-man-ink); }
.gp-man-sec p { margin: 0 0 10px; }
.gp-man-list { margin: 0 0 12px; padding-left: 22px; }
.gp-man-list li { margin: 4px 0; }
.gp-man-article a[data-man-go] { color: var(--gp-man-brand); font-weight: 600; text-decoration: none; }
.gp-man-article a[data-man-go]:hover { text-decoration: underline; }

.gp-man-steps { counter-reset: s; list-style: none; padding: 0; margin: 0 0 14px; }
.gp-man-steps li { counter-increment: s; position: relative; padding: 6px 0 6px 2.5em; }
.gp-man-steps li::before {
  content: counter(s); position: absolute; left: 0; top: 6px; width: 2.15em; height: 2.15em; border-radius: 50%;
  display: grid; place-items: center; font-size: .8em; font-weight: 700; background: #eef2ff; color: #4338ca;
}

.gp-man-tablewrap { overflow-x: auto; margin: 6px 0 14px; border: 1px solid var(--gp-man-line); border-radius: 10px; }
.gp-man-table { width: 100%; border-collapse: collapse; font-size: .9em; }
.gp-man-table th { background: var(--gp-man-soft); text-align: left; font-weight: 700; color: var(--gp-man-ink); padding: 9px 12px; border-bottom: 1px solid var(--gp-man-line); white-space: nowrap; }
.gp-man-table td { padding: 8px 12px; border-bottom: 1px solid #f1f5f9; vertical-align: top; }
.gp-man-table tr:last-child td { border-bottom: 0; }
.gp-man-table tbody tr:hover td { background: #fcfdff; }
.gp-man-req { font-size: .8em; font-weight: 700; color: #b45309; background: #fef3c7; padding: 1px 7px; border-radius: 999px; white-space: nowrap; }
.gp-man-pos { color: var(--gp-man-pos); font-weight: 700; }
.gp-man-neg { color: var(--gp-man-neg); font-weight: 700; }
.gp-man-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; vertical-align: middle; }

.gp-man-callout { display: flex; gap: 10px; padding: 12px 14px; border-radius: 10px; margin: 12px 0; font-size: .93em; border: 1px solid; }
.gp-man-callout > b { white-space: nowrap; }
.gp-man-tip  { background: #f0fdf4; border-color: #bbf7d0; }
.gp-man-note { background: #eff6ff; border-color: #bfdbfe; }
.gp-man-warn { background: #fff7ed; border-color: #fed7aa; }

.gp-man-example { border: 1px solid #ddd6fe; background: #faf8ff; border-radius: 12px; padding: 14px 16px; margin: 14px 0; }
.gp-man-example-h { font-weight: 700; color: #5b21b6; margin-bottom: 6px; }
.gp-man-example p:last-child { margin-bottom: 0; }

.gp-man-benefits { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16em), 1fr)); gap: 10px; margin: 8px 0 12px; }
.gp-man-benefit { display: flex; gap: 10px; padding: 12px; border: 1px solid var(--gp-man-line); border-radius: 12px; background: #fff; }
.gp-man-benefit-ico { font-size: 1.47em; line-height: 1; }
.gp-man-benefit b { color: var(--gp-man-ink); font-size: .93em; }
.gp-man-benefit p { margin: 2px 0 0; font-size: .87em; color: var(--gp-man-muted); line-height: 1.45; }

.gp-man-faq dt { font-weight: 700; color: var(--gp-man-ink); margin-top: 12px; }
.gp-man-faq dd { margin: 4px 0 0; }

.gp-man-shot { margin: 14px 0 18px; border: 1px solid var(--gp-man-line); border-radius: 12px; overflow: hidden; background: var(--gp-man-soft); }
.gp-man-shot.is-missing { display: none; }
.gp-man-shot img { display: block; width: 100%; height: auto; cursor: zoom-in; background: #fff; }
.gp-man-shot figcaption { font-size: .83em; color: var(--gp-man-muted); padding: 8px 12px; border-top: 1px solid var(--gp-man-line); }

.gp-man-foot { margin-top: 30px; padding: 16px 18px; border-radius: 12px; background: var(--gp-man-soft); border: 1px solid var(--gp-man-line); font-size: .93em; }

/* Zoomed screenshot */
.gp-man-zoom {
  position: fixed; inset: 0; z-index: 100060; background: rgba(2,6,23,.88);
  display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; cursor: zoom-out;
}
.gp-man-zoom[hidden] { display: none; }
.gp-man-zoom img { max-width: 100%; max-height: calc(100% - 50px); border-radius: 8px; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.gp-man-zoom p { color: #e2e8f0; font-size: 13px; margin: 12px 0 0; text-align: center; }
.gp-man-zoom .gp-man-close { position: absolute; top: 16px; right: 16px; }

/* ── Maximised ── */
.gp-man--max { padding: 0; }
.gp-man--max .gp-man-panel { max-width: none; max-height: none; border-radius: 0; }
.gp-man--max .gp-man-article > * { max-width: 70em; }

/* ── Minimised: panel hidden, page usable, floating bar ── */
.gp-man--min { background: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; pointer-events: none; }
.gp-man--min .gp-man-panel { display: none; }
.gp-man-minibar {
  position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 100055; pointer-events: auto;
  display: flex; align-items: stretch; border-radius: 14px; overflow: hidden;
  background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff; box-shadow: 0 12px 32px rgba(79,70,229,.4);
}
.gp-man-minibar[hidden] { display: none; }
.gp-man-mini-restore, .gp-man-mini-close { border: 0; background: transparent; color: inherit; cursor: pointer; font: inherit; }
.gp-man-mini-restore { display: flex; align-items: center; gap: 10px; padding: 10px 14px; text-align: left; max-width: 280px; }
.gp-man-mini-restore small { display: block; font-size: 10.5px; opacity: .85; text-transform: uppercase; letter-spacing: .05em; }
.gp-man-mini-restore b { display: block; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gp-man-mini-ico { font-size: 20px; }
.gp-man-mini-up { font-size: 10px; opacity: .8; }
.gp-man-mini-close { padding: 0 14px; border-left: 1px solid rgba(255,255,255,.25); font-size: 14px; }
.gp-man-mini-restore:hover, .gp-man-mini-close:hover { background: rgba(255,255,255,.12); }
.gp-man-mini-restore:focus-visible, .gp-man-mini-close:focus-visible { outline: 2px solid #fff; outline-offset: -3px; }

/* ── Reading options ── */
.gp-man--lh-relaxed { --gp-man-lh: 1.9; }
.gp-man--lh-loose   { --gp-man-lh: 2.2; }
.gp-man--lh-relaxed .gp-man-list li, .gp-man--lh-loose .gp-man-list li { margin: 8px 0; }
.gp-man--font-easy .gp-man-article { font-family: Verdana, Tahoma, 'Segoe UI', sans-serif; letter-spacing: .02em; word-spacing: .08em; }

/* High contrast: black on white, strong borders, underlined links */
.gp-man--theme-contrast { --gp-man-text: #000; --gp-man-ink: #000; --gp-man-muted: #1f2937; --gp-man-line: #000; --gp-man-soft: #fff; --gp-man-brand: #1d1d9f; --gp-man-pos: #005c2e; --gp-man-neg: #a30000; }
.gp-man--theme-contrast .gp-man-article { background: #fff; }
.gp-man--theme-contrast .gp-man-article a { text-decoration: underline !important; }
.gp-man--theme-contrast .gp-man-hero, .gp-man--theme-contrast .gp-man-example, .gp-man--theme-contrast .gp-man-callout,
.gp-man--theme-contrast .gp-man-benefit, .gp-man--theme-contrast .gp-man-chips span { background: #fff !important; border: 2px solid #000 !important; }
.gp-man--theme-contrast .gp-man-table th { background: #000; color: #fff; }
.gp-man--theme-contrast .gp-man-table td { border-bottom: 1px solid #000; }
.gp-man--theme-contrast .gp-man-req { background: #000; color: #fff; }
.gp-man--theme-contrast .gp-man-example-h { color: #000; }
.gp-man--theme-contrast .gp-man-nav-guide.active, .gp-man--theme-contrast .gp-man-nav-sec.active { background: #000; color: #fff !important; }

/* Dark */
.gp-man--theme-dark { --gp-man-text: #cbd5e1; --gp-man-ink: #f1f5f9; --gp-man-muted: #94a3b8; --gp-man-line: #334155; --gp-man-soft: #1e293b; --gp-man-brand: #a5b4fc; --gp-man-pos: #4ade80; --gp-man-neg: #f87171; }
.gp-man--theme-dark .gp-man-panel, .gp-man--theme-dark .gp-man-article { background: #0f172a; }
.gp-man--theme-dark .gp-man-head, .gp-man--theme-dark .gp-man-nav { background: #111c33; }
.gp-man--theme-dark .gp-man-btn, .gp-man--theme-dark .gp-man-opt, .gp-man--theme-dark .gp-man-textpanel { background: #1e293b; color: var(--gp-man-text); }
.gp-man--theme-dark .gp-man-btn.active, .gp-man--theme-dark .gp-man-nav-guide.active, .gp-man--theme-dark .gp-man-nav-sec.active { background: #312e81; color: #e0e7ff !important; border-color: #4338ca; }
.gp-man--theme-dark .gp-man-opt.active { background: #6366f1; border-color: #6366f1; color: #fff; }
.gp-man--theme-dark .gp-man-nav-guide:hover, .gp-man--theme-dark .gp-man-nav-sec:hover { background: #1e293b; }
.gp-man--theme-dark .gp-man-nav-num, .gp-man--theme-dark .gp-man-nav-guide em { background: #1e293b; }
.gp-man--theme-dark .gp-man-hero { background: linear-gradient(135deg, #1e1b4b, #0f172a 70%); border-color: #3730a3; }
.gp-man--theme-dark .gp-man-chips span, .gp-man--theme-dark .gp-man-benefit { background: #1e293b; }
.gp-man--theme-dark .gp-man-table tbody tr:hover td { background: #172036; }
.gp-man--theme-dark .gp-man-table td { border-bottom-color: #1e293b; }
.gp-man--theme-dark .gp-man-tip  { background: #052e1c; border-color: #14532d; }
.gp-man--theme-dark .gp-man-note { background: #0b2545; border-color: #1e3a8a; }
.gp-man--theme-dark .gp-man-warn { background: #3b1d06; border-color: #7c2d12; }
.gp-man--theme-dark .gp-man-example { background: #1e1b4b; border-color: #3730a3; }
.gp-man--theme-dark .gp-man-example-h { color: #c4b5fd; }
.gp-man--theme-dark .gp-man-req { background: #422006; color: #fcd34d; }
.gp-man--theme-dark .gp-man-steps li::before { background: #312e81; color: #e0e7ff; }
.gp-man--theme-dark .gp-man-shot img { opacity: .92; }
.gp-man--theme-dark .gp-man-secnav a:hover { background: #172036; border-color: #4338ca; }
.gp-man--theme-dark .gp-man-sec--reading { background: #1f2a14; box-shadow: 0 0 0 10px #1f2a14; }

/* ── Video tutorials (v1.2.0) ─────────────────────────────────────────── */
.gp-man-hero--video { align-items: stretch; }
.gp-man-hero-main { flex: 1; min-width: 0; }
.gp-man-vidcta {
  display: inline-flex; align-items: center; gap: 12px; margin-top: 16px; padding: 8px 18px 8px 8px;
  border: 0; border-radius: 999px; cursor: pointer; font: inherit; text-align: left; color: #fff;
  background: linear-gradient(135deg, var(--gp-man-accent, var(--gp-man-brand)), color-mix(in srgb, var(--gp-man-accent, #6366f1) 70%, #0f172a));
  box-shadow: 0 8px 22px color-mix(in srgb, var(--gp-man-accent, #6366f1) 35%, transparent);
  transition: transform .15s, box-shadow .15s;
}
.gp-man-vidcta:hover { transform: translateY(-1px); box-shadow: 0 12px 28px color-mix(in srgb, var(--gp-man-accent, #6366f1) 45%, transparent); }
.gp-man-vidcta:focus-visible { outline: 3px solid color-mix(in srgb, var(--gp-man-accent, #6366f1) 45%, #fff); outline-offset: 2px; }
.gp-man-vidcta-play {
  width: 2.3em; height: 2.3em; border-radius: 50%; background: #fff; color: var(--gp-man-accent, var(--gp-man-brand));
  display: grid; place-items: center; font-size: .9em; padding-left: 3px; flex: none;
}
.gp-man-vidcta b { display: block; font-size: .95em; line-height: 1.2; }
.gp-man-vidcta small { display: block; font-size: .76em; opacity: .9; font-weight: 500; }

.gp-man-hero-thumb {
  position: relative; flex: none; align-self: center; width: 232px; aspect-ratio: 16 / 9; padding: 0; cursor: pointer;
  border-radius: 12px; overflow: hidden; border: 1px solid color-mix(in srgb, var(--gp-man-accent, #6366f1) 30%, #fff);
  background: linear-gradient(135deg, color-mix(in srgb, var(--gp-man-accent, #6366f1) 22%, #fff), #fff);
  box-shadow: 0 10px 26px rgba(15,23,42,.16); transition: transform .15s, box-shadow .15s;
}
.gp-man-hero-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.gp-man-hero-thumb:hover { transform: translateY(-2px); box-shadow: 0 16px 34px rgba(15,23,42,.22); }
.gp-man-hero-thumb:focus-visible { outline: 3px solid var(--gp-man-brand); outline-offset: 2px; }
.gp-man-thumb-play {
  position: absolute; left: 50%; top: 50%; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%;
  background: rgba(15,23,42,.72); color: #fff; display: grid; place-items: center; font-size: 19px; padding-left: 4px;
  box-shadow: 0 0 0 6px rgba(255,255,255,.35); transition: transform .15s, background .15s;
}
.gp-man-hero-thumb:hover .gp-man-thumb-play { transform: scale(1.08); background: var(--gp-man-accent, var(--gp-man-brand)); }
.gp-man-thumb-time {
  position: absolute; right: 8px; bottom: 8px; background: rgba(15,23,42,.8); color: #fff; font-size: 11.5px; font-weight: 700;
  padding: 2px 7px; border-radius: 6px; font-variant-numeric: tabular-nums;
}

.gp-man-sec-t { flex: 1; min-width: 0; }
.gp-man-secvid {
  flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; cursor: pointer;
  font: inherit; font-size: .58em; font-weight: 700; color: var(--gp-man-brand); background: #eef2ff; border: 1px solid #e0e7ff;
  transition: background .15s, color .15s;
}
.gp-man-secvid span { font-size: .85em; }
.gp-man-secvid em { font-style: normal; font-weight: 600; opacity: .75; font-variant-numeric: tabular-nums; }
.gp-man-secvid:hover { background: var(--gp-man-brand); color: #fff; border-color: var(--gp-man-brand); }
.gp-man-secvid:focus-visible { outline: 2px solid var(--gp-man-brand); outline-offset: 2px; }

/* Player */
.gp-man-vp {
  position: absolute; inset: 0; z-index: 30; display: flex; align-items: center; justify-content: center; padding: 24px;
  background: rgba(2,6,23,.78); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px);
}
.gp-man-vp[hidden] { display: none; }
.gp-man-vp-box {
  width: 100%; max-width: 1240px; max-height: 100%; display: flex; flex-direction: column; overflow: hidden;
  background: #0f172a; color: #e2e8f0; border-radius: 16px; box-shadow: 0 30px 90px rgba(0,0,0,.55);
}
@media (prefers-reduced-motion: no-preference) { .gp-man-vp-box { animation: gp-man-in .2s ease-out; } }
.gp-man-vp-head { display: flex; align-items: center; gap: 12px; padding: 12px 14px 12px 20px; border-bottom: 1px solid #1e293b; }
.gp-man-vp-titles { flex: 1; min-width: 0; }
.gp-man-vp-kicker { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #a5b4fc; }
.gp-man-vp-head h3 { margin: 2px 0 0; font-size: 16px; color: #f8fafc; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gp-man-vp-head .gp-man-btn { background: #1e293b; border-color: #334155; color: #cbd5e1; }
.gp-man-vp-head .gp-man-btn:hover { background: #334155; color: #fff; }
.gp-man-vp-body { display: flex; min-height: 0; }
.gp-man-vp-media { flex: 1; min-width: 0; position: relative; background: #000; aspect-ratio: 16 / 9; max-height: calc(100vh - 190px); }
.gp-man-vp-media video, .gp-man-vp-media iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; display: block; }
.gp-man-vp-media video[hidden] { display: none; }
.gp-man-vp-missing { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; padding: 20px; color: #cbd5e1; }
.gp-man-vp-missing[hidden] { display: none; }
.gp-man-vp-missing b { font-size: 17px; color: #fff; }
.gp-man-vp-side { width: 280px; flex: none; display: flex; flex-direction: column; border-left: 1px solid #1e293b; min-height: 0; }
.gp-man-vp-side-h { padding: 12px 16px 8px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #94a3b8; }
.gp-man-vp-chapters { list-style: none; margin: 0; padding: 0 8px 10px; overflow-y: auto; flex: 1; min-height: 0; }
.gp-man-vp-chapters button {
  width: 100%; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border: 0; border-radius: 10px; cursor: pointer;
  background: none; color: #cbd5e1; font: inherit; font-size: 13.5px; line-height: 1.3; text-align: left;
}
.gp-man-vp-chapters button:hover { background: #1e293b; color: #fff; }
.gp-man-vp-chapters button:focus-visible { outline: 2px solid #a5b4fc; outline-offset: -2px; }
.gp-man-vp-chapters button.active { background: #312e81; color: #fff; }
.gp-man-vp-n { width: 24px; height: 24px; border-radius: 7px; flex: none; display: grid; place-items: center; font-size: 11.5px; font-weight: 700; background: #1e293b; color: #cbd5e1; }
.gp-man-vp-chapters button.active .gp-man-vp-n { background: #6366f1; color: #fff; }
.gp-man-vp-ct { flex: 1; min-width: 0; }
.gp-man-vp-chapters time { font-size: 12px; color: #94a3b8; font-variant-numeric: tabular-nums; }
.gp-man-vp-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; border-top: 1px solid #1e293b; font-size: 13px; color: #94a3b8; }
.gp-man-vp-foot span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gp-man-vp-read { flex: none; border: 1px solid #334155; background: #1e293b; color: #e2e8f0; border-radius: 9px; padding: 7px 12px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.gp-man-vp-read:hover { background: #334155; color: #fff; }
.gp-man-vp-read:focus-visible { outline: 2px solid #a5b4fc; outline-offset: 2px; }

.gp-man--theme-dark .gp-man-secvid { background: #1e1b4b; border-color: #3730a3; color: #c7d2fe; }
.gp-man--theme-dark .gp-man-secvid:hover { background: #4338ca; color: #fff; }
.gp-man--theme-contrast .gp-man-secvid { background: #fff; border: 2px solid #000; color: #000; }
.gp-man--theme-contrast .gp-man-vidcta { background: #000; box-shadow: none; }
.gp-man--theme-contrast .gp-man-vidcta-play { color: #000; }
.gp-man--theme-contrast .gp-man-hero-thumb { border: 2px solid #000; }

/* Video language (v1.3.0) */
.gp-man-vidrow { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 16px; }
.gp-man-vidrow .gp-man-vidcta { margin-top: 0; }
.gp-man-vidalt {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px; cursor: pointer;
  font: inherit; font-size: .86em; font-weight: 700; color: var(--gp-man-accent, var(--gp-man-brand));
  background: #fff; border: 1px solid color-mix(in srgb, var(--gp-man-accent, #6366f1) 35%, #fff);
}
.gp-man-vidalt span { font-size: .8em; }
.gp-man-vidalt:hover { background: color-mix(in srgb, var(--gp-man-accent, #6366f1) 10%, #fff); }
.gp-man-vidalt:focus-visible { outline: 2px solid var(--gp-man-brand); outline-offset: 2px; }
.gp-man-vp-lang { display: inline-flex; padding: 3px; border-radius: 10px; background: #1e293b; border: 1px solid #334155; flex: none; }
.gp-man-vp-lang[hidden] { display: none; }
.gp-man-vp-lang button { border: 0; background: none; color: #cbd5e1; font: inherit; font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 7px; cursor: pointer; }
.gp-man-vp-lang button:hover { color: #fff; }
.gp-man-vp-lang button.active { background: #6366f1; color: #fff; }
.gp-man-vp-lang button:focus-visible { outline: 2px solid #a5b4fc; outline-offset: 1px; }
.gp-man--theme-dark .gp-man-vidalt { background: #1e293b; color: #c7d2fe; border-color: #3730a3; }
.gp-man--theme-contrast .gp-man-vidalt { background: #fff; color: #000; border: 2px solid #000; }

/* App screens: "Watch video" next to "Read how it works" */
.gp-man-apphelp a + a { margin-left: 4px; }

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .gp-man-overlay { padding: 0; }
  .gp-man-panel { max-height: none; border-radius: 0; }
  .gp-man-navtoggle { display: grid; }
  .gp-man-body { position: relative; }
  .gp-man-nav {
    position: absolute; inset: 0 auto 0 0; z-index: 2; width: min(300px, 86vw);
    transform: translateX(-102%); transition: transform .2s; box-shadow: 8px 0 30px rgba(0,0,0,.12);
  }
  .gp-man--nav-open .gp-man-nav { transform: none; }
  .gp-man-article { padding: 18px 16px 50px; font-size: calc(14.5px * var(--gp-man-scale, 1)); }
  .gp-man-hero { flex-direction: column; gap: 8px; padding: 16px; }
  .gp-man-hero h1 { font-size: 1.45em; }
  .gp-man-hero-thumb { display: none; }
  .gp-man-vp { padding: 0; align-items: stretch; }
  .gp-man-vp-box { border-radius: 0; max-width: none; }
  .gp-man-vp-body { flex-direction: column; flex: 1; }
  .gp-man-vp-media { flex: none; width: 100%; max-height: none; }
  .gp-man-vp-side { width: auto; border-left: 0; border-top: 1px solid #1e293b; flex: 1; }
  .gp-man-sec h2 { font-size: 1.17em; }
  .gp-man-callout { flex-direction: column; gap: 4px; }
  .gp-man-head { padding: 10px 12px; gap: 8px; }
  .gp-man-step em, .gp-man-pos, .gp-man-maxbtn { display: none; }
  .gp-man-wctl { padding-left: 6px; margin-left: 0; gap: 4px; }
  .gp-man-btn { min-width: 34px; height: 34px; padding: 0 7px; }
  .gp-man-textpanel { right: 8px; }
  .gp-man-head h2 { font-size: 15px; }
}
@media (max-width: 520px) {
  .gp-man-head-kicker { display: none; }
  .gp-man-pager { gap: 4px; }
  .gp-man-secnav { grid-template-columns: 1fr; }
  .gp-man-secnav-next { grid-column: 1; }
  .gp-man-secvid em { display: none; }
  .gp-man-vidcta { display: flex; width: 100%; }
  .gp-man-vp-lang button { padding: 6px 9px; }
  .gp-man-minibar { left: 12px; right: 12px; bottom: 12px; transform: none; }
  .gp-man-mini-restore { max-width: none; flex: 1; }
}
@media (max-width: 480px) {
  .gp-man-cta { font-size: 12px; padding: 6px 12px 6px 8px; }
  .gp-man-apphelp { justify-content: flex-start; padding: 8px 12px 0; }
}
