/* Task Helper — the grouped plans list drawn by shared/plan-tree.js (PLANSGROUP): the form's Plans list AND the main Map's Plans panel. Copyright Rapid Surveys Pty Ltd.
 * Colours: the form page's --thf-* when it has them, else the app's tokens, else the fallbacks (light). Selectors are class + element so they win over the page's bare button / input rules. */
.plt-list { list-style: none; margin: 0; padding: 0; }
.plt-list, .plt-list * { box-sizing: border-box; }
.plt-list { --plt-line: var(--thf-line, var(--line, #d6dbe2)); --plt-muted: var(--thf-muted, var(--muted, #5c6878)); --plt-gold: #9E8C5B; --plt-gold-fill: rgba(158, 140, 91, .18); }
/* PLTIDY (Gary 2026-11-12: "more definition"): a drawing set is a CARD with its pages inside, a guide line joins the pages to it; a lone plan is a plain row with a hairline under it */
.plt-file { border-bottom: 1px solid var(--plt-line); }
.plt-file:last-child { border-bottom: 0; }
.plt-list .plt-file.plt-multi { margin: 0 0 8px; padding: 2px 6px 6px; border: 1px solid var(--plt-line); border-radius: 10px; background: var(--thf-box, var(--hover, #f7f9fc)); }
.plt-list .plt-head { margin: 10px 0 4px; padding: 0 2px; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--plt-muted); }
.plt-list .plt-head:first-child { margin-top: 2px; }
.plt-pages { list-style: none; margin: 0 0 2px 18px; padding: 0; border-left: 2px solid var(--plt-line); }
.plt-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0 6px; min-height: 44px; padding: 2px 0; min-width: 0; }
.plt-page { padding: 2px 0 2px 8px; }   /* a page row: beside the guide line, ONE line (eye · Page N · name … · Go to · ↑↓), its slider under */
.plt-list .plt-row.plt-off { opacity: .55; }   /* hidden (eye off): greyed */
.plt-list .plt-row.plt-off .plt-label { color: var(--plt-muted); }
.plt-list .plt-exp { flex: none; width: 28px; height: 36px; padding: 0; margin: 0; border: 0; background: transparent; color: var(--thf-muted, var(--muted, #5c6878)); font: inherit; font-size: 16px; line-height: 1; cursor: pointer; transition: transform .15s; }
.plt-list button.plt-exp[data-open="true"] { transform: rotate(90deg); }
.plt-list .plt-exp-none { display: inline-block; cursor: default; }
.plt-page .plt-exp-none { display: none; }
.plt-list .plt-check { flex: 1 1 0; min-width: 0; display: flex; align-items: center; gap: 10px; min-height: 44px; margin: 0; cursor: pointer; }
.plt-list .plt-check input { width: 22px; height: 22px; margin: 0; flex: none; }
.plt-list .plt-label { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }   /* ONE line, cut with … (the full name is the tooltip) */
.plt-list .plt-pn { font-weight: 700; }
.plt-list .plt-count { flex: none; margin-left: 2px; padding: 1px 8px; border: 1px solid var(--plt-line); border-radius: 999px; background: var(--thf-card, var(--card, #fff)); color: var(--plt-muted); font-size: 11px; font-weight: 600; white-space: nowrap; }   /* the "3 pages" chip */
.plt-list button.plt-eye { flex: none; width: 36px; height: 36px; padding: 0; margin: 0; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 8px; background: transparent; color: var(--thf-ink, var(--ink, #1c2430)); cursor: pointer; }
.plt-list button.plt-eye[aria-pressed="false"] { color: var(--thf-muted, var(--muted, #5c6878)); }
.plt-list .plt-some button.plt-eye, .plt-list .plt-some .plt-eye { opacity: .7; }
.plt-list button.plt-eye svg { width: 20px; height: 20px; fill: currentColor; }
.plt-list button.plt-name { flex: 1 1 0; min-width: 0; width: auto; display: flex; align-items: center; gap: 4px; margin: 0; padding: 6px 8px; border: 0; border-radius: 6px; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.plt-list span.plt-name { flex: 1 1 0; min-width: 0; padding: 6px 8px; }
.plt-list button.plt-name:hover { background: var(--hover, var(--thf-box, #f7f9fc)); }
.plt-list button.plt-name .plt-label { flex: 0 1 auto; }
.plt-list .plt-check .plt-label { flex: 0 1 auto; }
.plt-list button.plt-go { flex: none; width: auto; min-height: 36px; min-width: 52px; margin: 0; padding: 0 10px; border: 1px solid var(--thf-line, var(--line, #d6dbe2)); border-radius: 8px; background: var(--thf-card, var(--card, #fff)); color: inherit; font: inherit; font-size: 13px; cursor: pointer; }
.plt-list button.plt-go svg { display: none; width: 22px; height: 22px; fill: currentColor; }
.plt-list button.plt-go:disabled { opacity: .5; cursor: not-allowed; }
.plt-list input.plt-op { flex: 1 1 auto; min-width: 60px; height: 14px; margin: 0; accent-color: var(--thf-accent, var(--accent, #2f6df6)); }
/* PLTIDY: the see-through slider — a thin one, its label before and its % after, on its own line under the row */
.plt-list .plt-opw { flex: 1 1 100%; display: flex; align-items: center; gap: 8px; min-height: 22px; margin: 0 0 2px 0; padding-left: 62px; font-size: 11px; color: var(--plt-muted); }
.plt-list .plt-page .plt-opw { padding-left: 38px; }
.plt-list .plt-opt { flex: none; }
.plt-list .plt-pct { flex: none; min-width: 34px; text-align: right; font-variant-numeric: tabular-nums; }
.plt-list input.plt-op { -webkit-appearance: none; appearance: none; background: transparent; border: 0; padding: 0; box-shadow: none; border-radius: 0; width: auto; }
/* PLTIDY: inside a set's card Go to is the small target icon (the name needs the room); a lone plan keeps the words */
.plt-list .plt-multi button.plt-go { min-width: 36px; width: 36px; padding: 0; display: inline-flex; align-items: center; justify-content: center; }
.plt-list .plt-multi button.plt-go svg { display: block; width: 20px; height: 20px; }
.plt-list .plt-multi button.plt-go .plt-gotxt { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.plt-list input.plt-op::-webkit-slider-runnable-track { height: 3px; border-radius: 2px; background: var(--plt-line); }
.plt-list input.plt-op::-moz-range-track { height: 3px; border-radius: 2px; background: var(--plt-line); }
.plt-list input.plt-op::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; margin-top: -5.5px; border-radius: 50%; border: 0; background: var(--thf-accent, var(--accent, #2f6df6)); }
.plt-list input.plt-op::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; border: 0; background: var(--thf-accent, var(--accent, #2f6df6)); }
/* PLTIDY: the selected row — a gold bar on the left + a soft gold fill (was a thin blue line) */
.plt-list .plt-sel { background: var(--plt-gold-fill); box-shadow: inset 4px 0 0 var(--plt-gold); border-radius: 6px; }
.plt-list button.plt-name[aria-pressed="true"] { font-weight: 700; }
.plt-list button:focus-visible, .plt-list input:focus-visible { outline: 2px solid var(--thf-accent, var(--accent, #2f6df6)); outline-offset: 2px; }
/* SETORDER: ↑ / ↓ on a drawing of a set */
.plt-list .plt-list .plt-mvs { flex: none; display: inline-flex; flex-direction: column; gap: 2px; }   /* PLTIDY: ↑ over ↓ as one small pair */
.plt-list button.plt-mv { flex: none; width: 30px; height: 20px; margin: 0; padding: 0; border: 1px solid var(--plt-line); border-radius: 6px; background: var(--thf-card, var(--card, #fff)); color: inherit; font: inherit; font-size: 13px; line-height: 1; cursor: pointer; }
.plt-list button.plt-mv:disabled { opacity: .35; cursor: not-allowed; }
/* PHONE: a compact row — ▸ · eye · name (wraps between words) · a 44px target button for Go to on the SAME line; the see-through slider sits under */
@media (max-width: 767px) { .plt-list button.plt-go { min-height: 44px; min-width: 44px; width: 44px; padding: 0; display: inline-flex; align-items: center; justify-content: center; } .plt-list button.plt-go svg { display: block; } .plt-list button.plt-go .plt-gotxt { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } .plt-list .plt-row { gap: 0 2px; flex-wrap: wrap; } .plt-list button.plt-name, .plt-list .plt-check, .plt-list span.plt-name { flex: 1 1 0; } .plt-page { padding-left: 2px; } .plt-list button.plt-eye, .plt-list .plt-exp { width: 44px; height: 44px; } .plt-list .plt-multi button.plt-go { width: 44px; min-width: 44px; } .plt-list button.plt-name, .plt-list span.plt-name, .plt-list .plt-check { min-height: 44px; } .plt-list .plt-exp { width: 32px; } .plt-list input.plt-op { height: 28px; } .plt-list input.plt-op::-webkit-slider-thumb { width: 20px; height: 20px; margin-top: -8.5px; } .plt-list input.plt-op::-moz-range-thumb { width: 20px; height: 20px; } .plt-list .plt-mvs { flex-direction: row; gap: 0; } .plt-list button.plt-mv { width: 44px; height: 44px; font-size: 18px; } .plt-list .plt-opw { padding-left: 80px; } .plt-list .plt-page .plt-opw { padding-left: 48px; } }
.plt-list button.plt-flag, .tho-panel .plt-list button.plt-flag { flex: 0 0 auto; width: auto; display: inline-flex; align-items: center; margin: 0 2px 0 44px; min-height: 28px; padding: 0 8px; border: 1px solid var(--thf-line, var(--line, #d6dbe2)); border-radius: 999px; background: transparent; color: var(--thf-muted, var(--muted, #5c6878)); font: inherit; font-size: 11px; font-weight: 600; white-space: nowrap; cursor: pointer; }
.plt-list button.plt-flag:hover, .plt-list button.plt-flag:focus-visible { color: inherit; border-color: currentColor; }
@media (max-width: 767px) { .plt-list button.plt-flag, .tho-panel .plt-list button.plt-flag { min-height: 44px; padding: 0 10px; } }
/* PLANRENAME: the in-place name box (double-click a name) */
.plt-list input.plt-rename { flex: 1 1 110px; min-width: 0; width: auto; margin: 0; padding: 5px 8px; font: inherit; font-size: 14px; border-radius: 6px; box-sizing: border-box; }
@media (max-width: 767px) { .plt-list input.plt-rename { min-height: 44px; } }
/* PLTIDY: a SET's own name may take two lines (the page rows below stay one line) */
.plt-list .plt-multi > .plt-row .plt-label { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; white-space: normal; overflow-wrap: anywhere; }
/* PLTIDY (Gary pl-names=1): on a phone a page name may wrap onto 2 lines (then …); a computer keeps one line */
@media (max-width: 700px) { .plt-list .plt-page .plt-label { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; white-space: normal; overflow-wrap: anywhere; } }
