/* sv3-notes-drawer-teleport.css — #6993 / #6998, visual treatment ported 1:1
   from DH #683 (SV3 Notes Focus Drawer, sv3d/sv3d.css nsd-* family) by #7018.
   Scoped entirely under .sv3-ndt so it can never repaint an SV2 pixel.

   TOKENS: the DH's .sv3 block copies the shipped v2s-live scope verbatim and
   says "change it there, not here". The shell already defines those variables;
   every var() below falls back to the DH's literal values so the section renders
   the design even where the host drawer predates a token. One deliberate
   difference from the pre-#7018 file: the primary Teleport verb is a LIME
   OUTLINE (DH .nsd-tpb.lime), never a filled lime slab — the fill out-shouted
   the selected row's rail and the DH resolves that fight. */

.sv3-ndt {
  --ndt-lime: var(--lime, #CCDE49);
  --ndt-lime-line: var(--lime-line, rgba(204, 222, 73, .36));
  --ndt-lime-sel: var(--lime-sel, rgba(204, 222, 73, .12));
  --ndt-line: var(--line, #43444C);
  --ndt-line-soft: var(--line-soft, #3A3B42);
  --ndt-line-strong: var(--line-strong, #53545E);
  --ndt-fg: var(--fg, #D6D4DE);
  --ndt-fg-strong: var(--fg-strong, #EEEAF4);
  --ndt-fg-mute: var(--fg-mute, #A19FAD);
  --ndt-fg-dim: var(--fg-dim, #6F6C7F);
  --ndt-fg-faint: var(--fg-faint, #4A4854);
  --ndt-bg-panel: var(--bg-panel, #34353C);
  --ndt-bg-sub: var(--bg-sub, #3B3C44);
  --ndt-bg-deep: var(--bg-deep, #212228);
  --ndt-bg-row: var(--bg-row, #2F3037);
  --ndt-bg-row-h: var(--bg-row-h, #3A3B43);
  --ndt-ok: var(--st-resolved, #7A9A86);
  --ndt-danger: var(--st-danger, #B46868);
  --ndt-mono: var(--mono, "JetBrains Mono", ui-monospace, Menlo, monospace);
  --ndt-ui: var(--ui, "Helvetica Neue", Helvetica, Arial, sans-serif);
  --ndt-ms: 170ms;

  border-top: 1px solid var(--ndt-line);
  padding: 8px 10px 9px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: var(--ndt-ui);
  font-size: 12px;
  color: var(--ndt-fg);
  background: var(--ndt-bg-panel);
}
@media (prefers-reduced-motion: reduce) { .sv3-ndt { --ndt-ms: 0ms; } }
.sv3-ndt * { box-sizing: border-box; }

/* DH .nsd-lab — the section label voice. */
.sv3-ndt-head {
  font-family: var(--ndt-mono);
  font-size: 8px;
  font-weight: 500;
  letter-spacing: .19em;
  text-transform: uppercase;
  color: var(--ndt-fg-dim);
}
.sv3-ndt-row { display: flex; flex-direction: column; gap: 5px; }

/* ══ THE TELEPORT VERBS — DH .nsd-tpb ══════════════════════════════════════
   Up is the 30px verb, down the 26px .sm sibling. ONE LIME PER SURFACE holds
   exactly as before (#6993 comment stands): with rows on screen the lime is the
   selected rail; otherwise the enabled primary wears the lime OUTLINE. */
.sv3-ndt-btn {
  appearance: none;
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid var(--ndt-line);
  border-radius: 3px;
  background: linear-gradient(180deg, #3A3B43, #31323A);
  color: var(--ndt-fg);
  font-family: var(--ndt-ui);
  font-size: 11.5px;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .03);
}
.sv3-ndt-btn:hover:not(:disabled) {
  background: linear-gradient(180deg, #42434C, #383942);
  color: var(--ndt-fg-strong);
  border-color: var(--ndt-line-strong);
}
.sv3-ndt-btn.primary {
  background: linear-gradient(180deg, #3A3B43, #31323A);
  border-color: var(--ndt-lime-line);
  color: var(--ndt-lime);
}
.sv3-ndt-btn.primary:hover:not(:disabled) {
  background: linear-gradient(180deg, rgba(204, 222, 73, .12), rgba(204, 222, 73, .04));
  border-color: var(--ndt-lime);
}
.sv3-ndt-btn:disabled {
  color: var(--ndt-fg-faint);
  border-color: var(--ndt-line-soft);
  background: transparent;
  cursor: not-allowed;
  box-shadow: none;
  opacity: 1; /* DH renders disabled by colour, not opacity */
}
.sv3-ndt-btn .ndt-ct { font-family: var(--ndt-mono); font-size: 10px; font-feature-settings: "tnum" 1; opacity: .85; }
.sv3-ndt-btn.busy { color: var(--ndt-fg-strong); border-color: var(--ndt-line-strong); }
.sv3-ndt-btn.ok { color: var(--ndt-ok); border-color: rgba(122, 154, 134, .42); background: rgba(122, 154, 134, .10); }
.sv3-ndt-btn i.ndt-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: rgba(204, 222, 73, .16); }
.sv3-ndt-btn.holding i.ndt-fill { width: 100%; transition: width 420ms linear; }

/* why-lines: DH .nsd-tpnote / .nsd-tperr voices. */
.sv3-ndt-why { font-size: 10.5px; line-height: 1.35; color: var(--ndt-fg-dim); text-wrap: pretty; }
.sv3-ndt-why.err { color: var(--ndt-danger); }

/* spinner — DH .nsd-spin, reserved for real events. */
.sv3-ndt .ndt-spin { animation: sv3-ndt-rot 1.1s linear infinite; display: inline-flex; }
@keyframes sv3-ndt-rot { to { transform: rotate(360deg); } }

/* ══ THE FILTER STRIP — DH .nsd-filter family ═════════════════════════════ */
.sv3-ndt-filter {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px 0;
  border-bottom: 1px solid var(--ndt-line-soft);
}
.sv3-ndt-fsel {
  appearance: none;
  height: 20px;
  padding: 0 6px;
  border: 1px solid var(--ndt-line);
  border-radius: 2px;
  background: var(--ndt-bg-deep);
  color: var(--ndt-fg-mute);
  font-family: var(--ndt-ui);
  font-size: 10.5px;
  cursor: pointer;
  flex-shrink: 0;
  max-width: 96px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sv3-ndt-fsel:hover, .sv3-ndt-ftog:hover { color: var(--ndt-fg-strong); border-color: var(--ndt-line-strong); }
.sv3-ndt-fin {
  flex: 1;
  min-width: 34px;
  height: 20px;
  padding: 0 6px;
  border: 1px solid var(--ndt-line);
  border-radius: 2px;
  background: var(--ndt-bg-deep);
  color: var(--ndt-fg-strong);
  font-family: var(--ndt-ui);
  font-size: 10.5px;
  outline: none;
}
.sv3-ndt-fin:focus { border-color: var(--ndt-lime-line); }
.sv3-ndt-ftog {
  appearance: none;
  height: 20px;
  padding: 0 6px;
  border: 1px solid var(--ndt-line);
  border-radius: 2px;
  background: transparent;
  color: var(--ndt-fg-dim);
  font-family: var(--ndt-mono);
  font-size: 8px;
  letter-spacing: .1em;
  text-transform: uppercase;
  cursor: pointer;
  flex-shrink: 0;
}
.sv3-ndt-ftog.on { color: var(--ndt-fg-strong); border-color: var(--ndt-line-strong); background: var(--ndt-bg-sub); }
.sv3-ndt-batch {
  appearance: none;
  flex-shrink: 0;
  background: transparent;
  border: 0;
  padding: 0 2px;
  color: var(--ndt-fg-dim);
  font-family: var(--ndt-mono);
  font-size: 8px;
  letter-spacing: .13em;
  text-transform: uppercase;
  cursor: pointer;
}
.sv3-ndt-batch:hover:not(:disabled) { color: var(--ndt-lime); }
.sv3-ndt-batch:disabled { color: var(--ndt-fg-faint); cursor: default; }

/* ══ THE DESIGNS LIST — DH .nsd-dsn row anatomy ═══════════════════════════
   34px rows: att chip · editor · when · DESIGN n · version(+ALT) · Take 1 ·
   repl · clips/lanes. NO SCROLL RECT (founder 2026-08-30 18:3xZ) — unchanged:
   no max-height, no overflow, a pager row instead. */
.sv3-ndt ul, .sv3-ndt ol { list-style: none; margin: 0; padding: 0; }
.sv3-ndt li { list-style: none; }
.sv3-ndt-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ndt-line-soft); }
.sv3-ndt-item {
  position: relative;
  display: flex;
  line-height: 1.2;
  gap: 7px;
  align-items: center;
  height: 34px;
  padding: 0 8px 0 10px;
  border-bottom: 1px solid var(--ndt-line-soft);
  cursor: pointer;
}
.sv3-ndt-item:hover { background: var(--ndt-bg-row-h); }
/* THE SELECTED ROW CARRIES THE SURFACE'S ONE LIME — DH: a 3px rail plus the
   lime-tinted row wash. */
.sv3-ndt-item[aria-selected="true"], .sv3-ndt-item.is-on {
  background: var(--ndt-bg-row);
  background-image: linear-gradient(var(--ndt-lime-sel), var(--ndt-lime-sel));
  box-shadow: none;
}
.sv3-ndt-item[aria-selected="true"]::before, .sv3-ndt-item.is-on::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--ndt-lime);
}
.sv3-ndt-item:focus-visible { outline: 2px solid var(--ndt-lime); outline-offset: -2px; }
.sv3-ndt-att {
  width: 16px; height: 16px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--ndt-ui);
  font-size: 7px;
  font-weight: 600;
  letter-spacing: .02em;
  color: rgba(0, 0, 0, .68);
}
.sv3-ndt-who {
  font-size: 11px;
  font-weight: 400;
  color: var(--ndt-fg-strong);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1 1 auto;
  min-width: 0;
}
.sv3-ndt-item.old .sv3-ndt-who { color: var(--ndt-fg-mute); }
.sv3-ndt-when { font-family: var(--ndt-mono); font-size: 8.5px; color: var(--ndt-fg-dim); flex-shrink: 0; }
.sv3-ndt-num { font-family: var(--ndt-mono); font-size: 8.5px; letter-spacing: .06em; color: var(--ndt-fg-mute); flex-shrink: 0; }
.sv3-ndt-item[aria-selected="true"] .sv3-ndt-num, .sv3-ndt-item.is-on .sv3-ndt-num { color: var(--ndt-lime); }
.sv3-ndt-take {
  font-family: var(--ndt-mono);
  font-size: 7.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ndt-lime);
  border: 1px solid var(--ndt-lime-line);
  border-radius: 2px;
  padding: 0 3px;
  flex-shrink: 0;
}
.sv3-ndt-rep { font-family: var(--ndt-mono); font-size: 7.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ndt-fg-faint); flex-shrink: 0; }
.sv3-ndt-clips { margin-left: 0; font-family: var(--ndt-mono); font-size: 8.5px; color: var(--ndt-fg-dim); flex-shrink: 0; font-variant-numeric: tabular-nums; }
.sv3-ndt-empty { padding: 12px 0; font-size: 11px; color: var(--ndt-fg-dim); }

/* ══ THE PAGER — a ROW of the list (unchanged ruling), DH .nsd-pgb voice. ══ */
.sv3-ndt-pager { border-top: 1px solid var(--ndt-line-soft); }
.sv3-ndt-pagebtn {
  appearance: none;
  width: 100%;
  height: 22px;
  padding: 0 10px;
  border: 0;
  background: transparent;
  color: var(--ndt-fg-mute);
  font-family: var(--ndt-mono);
  font-size: 8.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-align: left;
  cursor: pointer;
}
.sv3-ndt-pagebtn:hover { color: var(--ndt-lime); }
.sv3-ndt-pagebtn:focus-visible { outline: 2px solid var(--ndt-lime); outline-offset: -2px; }

/* ══ UPDATE vs ALT — DH .nsd-choice ═══════════════════════════════════════ */
.sv3-ndt-choice {
  display: flex;
  gap: 5px;
  margin-top: 2px;
  padding: 7px 8px;
  border: 1px solid var(--ndt-line);
  border-radius: 3px;
  background: var(--ndt-bg-sub);
}
.sv3-ndt-kind {
  appearance: none;
  flex: 1 1 0;
  height: 24px;
  padding: 0 8px;
  border: 1px solid var(--ndt-line);
  border-radius: 2px;
  background: var(--ndt-bg-row);
  color: var(--ndt-fg);
  font-family: var(--ndt-ui);
  font-size: 11px;
  cursor: pointer;
}
.sv3-ndt-kind:hover { color: var(--ndt-fg-strong); border-color: var(--ndt-line-strong); }
.sv3-ndt-kind.is-on { border-color: var(--ndt-line-strong); background: var(--ndt-bg-sub); color: var(--ndt-fg-strong); font-weight: 600; }
.sv3-ndt-kind:focus-visible { outline: 2px solid var(--ndt-lime); outline-offset: -2px; }

/* The host box for the SHIPPED pull control (#6840: no second opinion on
   .sv3-tp-* geometry here). Spacing only. */
.sv3-ndt-pull { margin-top: 6px; }

/* ══ NARROW COLUMN (<360px) — DH's 320-floor rules for this section ═══════ */
.sv3-ndt.narrow .sv3-ndt-clips { display: none; }
.sv3-ndt.narrow .sv3-ndt-rep { display: none; }
.sv3-ndt.narrow .sv3-ndt-filter { flex-wrap: wrap; row-gap: 5px; }
.sv3-ndt.narrow .sv3-ndt-fin { flex: 1 1 100%; order: 3; min-width: 0; }
.sv3-ndt.narrow .sv3-ndt-batch { margin-left: auto; }

/* ── MY LAYS (#7133/#7135) ─────────────────────────────────────────────── */
.sv3-ndt-quiet { background: none; border: 0; padding: 2px 4px; font-size: 10.5px;
  color: var(--fg-dim); cursor: pointer; text-decoration: underline;
  text-underline-offset: 2px; white-space: nowrap; }
.sv3-ndt-quiet:hover { color: var(--fg-strong); }
/* the destructive verb is OUTLINED red ink, never a red fill - it must read
   as the dangerous choice without shouting over the drawer */
.sv3-ndt-danger { border-color: var(--st-refused, #a04040); color: var(--st-refused, #a04040); }
.sv3-ndt-lays-confirm { background: var(--bg-sub); border: 1px solid var(--line-strong);
  border-radius: 4px; padding: 8px 10px; }

/* ══ #7154 · WHY THIS SECTION NEVER TRUNCATES ITS OWN SENTENCES ════════════
   WALK 48 measured `.sv3-ndt-why` at clientWidth 127 / scrollWidth 284 with
   `white-space:nowrap` and `text-overflow:CLIP` — a sentence cut mid-word with
   no ellipsis, no title and no way to read the rest. `.sv2-sync-why` was 97/522.
   The band's why-line had been built for a short status hint and was then asked
   to carry a failure sentence.

   The rule now: a why-line WRAPS. It is never nowrap and never clipped. When
   the cell is genuinely short, sv3v2.css collapses the why-lines of ENABLED
   controls behind the labelled `Why ›` affordance (the fit engine mounts it) —
   which is a pager, not a deletion — and a control that is DISABLED or that has
   just FAILED keeps its sentence at every level and every width, because a
   failure that is on screen but clipped is still a silent failure. */
.sv3-ndt-why { white-space: normal; overflow-wrap: anywhere; text-overflow: clip; min-width: 0; }
.sv3-ndt-row { min-width: 0; }
.sv3-ndt-btn { min-width: 0; }
/* the cell top-aligns: a short cell is short, never padded out. Walk 48 defect
   6 measured 66px of dead space under .sv3-ndt while the accordion starved. */
.sv3-ndt { justify-content: flex-start; }
