/* Help page (2026-11-17). The page shell (rail, sections, cards, code, notes, reading tables) is
   `Documentation/css/data_api.css`, shared with Downloads and the API; this file holds only what is Help's own:
   the task cards, the worked-example rows, the terms table, and the live example card (an `api-ep` card).
   Neutrals are the Bootstrap theme variables (they follow light and dark); spacing, radius and type are the
   `--dcv-*` scale of `discanvis-theme.css`. No colour of its own. */
#help-page-root .dcv-doc-main h3 { margin: var(--dcv-s4) 0 var(--dcv-s1); font-size: var(--dcv-fs-value); font-weight: 700; }
#help-page-root .dcv-doc-prose ul { padding-left: 1.15rem; }
#help-page-root .dcv-doc-prose li { margin-bottom: var(--dcv-s1); }
#help-page-root .help-link-list a { word-break: break-word; }
#help-page-root .help-terms td:first-child { width: 14rem; }

.help-task-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: var(--dcv-s3); margin-bottom: var(--dcv-s4); }
.help-task-card {
    display: block; height: 100%; padding: var(--dcv-s3) var(--dcv-s4);
    border: 1px solid var(--bs-border-color); border-radius: .75rem; background: var(--bs-body-bg);
    color: inherit; text-decoration: none; transition: border-color .15s;
}
.help-task-card:hover { border-color: rgba(var(--bs-primary-rgb), .45); color: inherit; }
.help-task-card .material-symbols-outlined { color: var(--bs-primary); font-size: 1.35rem; }
.help-example-row {
    display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--dcv-s1) var(--dcv-s3);
    padding: var(--dcv-s2) 0; border-bottom: 1px solid var(--bs-border-color);
}
.help-example-row:last-child { border-bottom: 0; }

/* Live examples (`js/help_live.js`, registry `discanvis_server/help_live.py`): the API page's endpoint card,
   with a figure in place of the response. */
.help-live-list { display: flex; flex-direction: column; margin-block: var(--dcv-s4); }
.help-live-title { margin: 0; font-size: var(--dcv-fs-body); }
.help-live-steps { list-style: none; display: flex; flex-wrap: wrap; gap: var(--dcv-s2); margin: 0; padding: 0; }
#help-page-root .help-live-steps li { margin: 0; }
.help-live-step {
    display: inline-flex; align-items: center; gap: var(--dcv-s2);
    padding: var(--dcv-s1) var(--dcv-s3) var(--dcv-s1) var(--dcv-s1); border: 1px solid var(--bs-border-color);
    border-radius: var(--dcv-radius-pill); font-size: var(--dcv-fs-label); font-weight: 600; text-decoration: none;
    color: var(--bs-body-color); background: var(--bs-body-bg);
}
.help-live-step .api-step-n { width: 1.5rem; height: 1.5rem; font-size: var(--dcv-fs-label); }
.help-live-step:hover { border-color: rgba(var(--bs-primary-rgb), .45); color: var(--bs-body-color); }
.help-live-step.is-current { border-color: var(--bs-primary); background: var(--bs-tertiary-bg); }
.help-live.is-own .help-live-steps { display: none; }

.help-live-stage { position: relative; }
.help-live-stage:not(:has(.help-live-frame)) {
    display: flex; flex-wrap: wrap; align-items: center; gap: var(--dcv-s3);
    min-height: 5rem; padding: var(--dcv-s4); border: 1px dashed var(--bs-border-color);
    border-radius: var(--dcv-radius); background: var(--bs-tertiary-bg); font-size: var(--dcv-fs-body);
}
.help-live-stage .help-live-note { color: var(--bs-secondary-color); }
.help-live:not(.is-script) .help-live-show { display: none; }
.help-live-frame {
    display: block; width: 100%; border: 1px solid var(--bs-border-color); border-radius: var(--dcv-radius);
    background: var(--bs-body-bg);
}
.help-live-status {
    position: absolute; top: var(--dcv-s2); right: var(--dcv-s2); z-index: 2;
    padding: var(--dcv-s1) var(--dcv-s3); border: 1px solid var(--bs-border-color); border-radius: var(--dcv-radius-pill);
    background: var(--bs-body-bg); color: var(--bs-secondary-color); font-size: var(--dcv-fs-label);
}
.help-live-stage.is-loading .help-live-frame { opacity: .55; }
.help-live-unloaded, .help-live-fail { display: flex; flex-wrap: wrap; align-items: center; gap: var(--dcv-s2); width: 100%; }

.help-live-foot { display: flex; flex-wrap: wrap; align-items: center; gap: var(--dcv-s2) var(--dcv-s4); font-size: var(--dcv-fs-body); }
.help-live-own { display: flex; flex-wrap: wrap; align-items: center; gap: var(--dcv-s2); margin-left: auto; }
.help-live-own label { font-size: var(--dcv-fs-label); font-weight: 600; color: var(--bs-secondary-color); }
.help-live-own input { width: 11rem; }
.help-live-own-error, .help-live-own-note { font-size: var(--dcv-fs-label); color: var(--bs-secondary-color); }
.help-live-back { font-size: var(--dcv-fs-label); }
.help-live:not(.is-own) .help-live-back, .help-live:not(.is-own) .help-live-own-note { display: none; }
.help-live.is-own .help-live-extra { display: none; }
@media (max-width: 575.98px) {
    .help-live-own { margin-left: 0; }
    .help-live-own input { width: 100%; }
}
