/* Tree view (INVENTORY L9; SPEC.md §4.24), measured on Computer Management. Built by js/components/treeview.js. */
.w2k-tree {
  position: relative;
  overflow: hidden;   /* scrolled by its scroll area's viewport (Windows bars), inside the client edge */
  padding: var(--metric-client-edge);
  background: var(--sys-window);
  box-shadow: var(--edge-sunken);
  color: var(--sys-window-text);
  font: var(--font-ui);
  outline: none;
  user-select: none;
}
/* The content's inset inside the client edge (--metric-tree-inset): none in win2k, 2px in Graphite and side panes. */
.w2k-tree > .w2k-scrollarea__viewport { padding: var(--metric-tree-inset); }
.w2k-tree__rows { position: relative; min-width: max-content; }
.w2k-tree__row { position: relative; height: var(--metric-tree-row-height); white-space: pre; }
.w2k-tree__lines { position: absolute; left: 0; top: 0; overflow: visible; }
.w2k-tree__dots, .w2k-tree__boxframe { fill: var(--color-tree-lines, var(--sys-btn-shadow)); }   /* ButtonShadow; a theme may set its own */
.w2k-tree__box { fill: var(--sys-window); }
.w2k-tree__sign { fill: var(--sys-window-text); }
.w2k-tree__icon { position: absolute; top: 0; width: 16px; height: 16px; }
.w2k-tree__icon > img { display: block; width: 16px; height: 16px; }
.w2k-tree__label {
  position: absolute;
  top: 0;
  height: var(--metric-tree-row-height);
  padding: var(--metric-tree-text-top) var(--metric-tree-label-pad) 0;
  box-sizing: border-box;
}
.w2k-tree__row[aria-selected="true"] > .w2k-tree__label { background: var(--color-list-selection-unfocused); }
.w2k-tree:is(:focus, .is-focus) .w2k-tree__row[aria-selected="true"] > .w2k-tree__label { background: var(--color-row-hilight, var(--sys-hilight)); color: var(--color-row-hilight-text, var(--sys-hilight-text)); }
.w2k-tree:is(:focus, .is-focus) .w2k-tree__row[aria-selected="true"] > .w2k-tree__label::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--focus-rect-image);
  filter: invert(1);
  mix-blend-mode: difference;
}
html[data-cues="hidden"] .w2k-tree:not(.is-focus) .w2k-tree__label::after { display: none; }

/* Inside another frame (data-edge="none" — Phone Dialer's panes): no client edge of its own. */
.w2k-tree:where([data-edge="none"]) { box-shadow: none; padding: 0; }
/* A drop target while dragging (TVIS_DROPHILITED — Explorer's Folders bar): drawn selected. */
.w2k-tree__row[data-drophilite] > .w2k-tree__label { background: var(--color-row-hilight, var(--sys-hilight)); color: var(--color-row-hilight-text, var(--sys-hilight-text)); }
