/* Deep links in search (⌘K palette, sidebar, phone sheet), the module breadcrumb and the «Next step» panel.
   Loaded once by the shell (assets/js/app.js, command palette section). Theme tokens from app.css; logical properties for RTL. */

/* ---------- ⌘K palette: «Module › Section» rows ---------- */
.pal-item .pal-l { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; text-align: start; }
.pal-item .pal-l > span { color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pal-item .pal-bc { font-size: 11px; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-item .pal-bc i { font-style: normal; opacity: .7; }
[dir="rtl"] .pal-item .pal-bc i { display: inline-block; transform: scaleX(-1); }
.pal-item.deep .ico { opacity: .85; }
.pal-item:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

/* ---------- sidebar / phone sheet: «Inside modules» rows ---------- */
.sb-item.sb-deep .sb-label { min-width: 0; }
.sb-item.sb-deep .sb-label > span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-item.sb-deep .sb-ic { opacity: .8; }
.mnav-rh.deep-rh { display: flex; justify-content: space-between; align-items: center; padding: 12px 6px 4px; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }
.mnav-row.mnav-deep .mnav-rt b { font-weight: 600; }

/* ---------- module breadcrumb (Category › Sub-category › Module) ---------- */
.mod-crumb { max-width: 1280px; margin: 0 auto; padding: 10px 20px 0; font-size: 12px; line-height: 1.4; color: var(--dim); }
.devtool > .mod-crumb { padding: 0 0 10px; margin: -8px 0 0; }
.mod-crumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 0; margin: 0; padding: 0; list-style: none; }
.mod-crumb li { display: inline-flex; align-items: center; min-width: 0; }
.mod-crumb li + li::before { content: '›'; padding-inline: 7px; opacity: .6; }
[dir="rtl"] .mod-crumb li + li::before { content: '‹'; }
.mod-crumb a { display: inline-flex; align-items: center; gap: 5px; min-height: 32px; color: var(--muted); text-decoration: none; border-radius: 8px; }
.mod-crumb a:hover { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.mod-crumb a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mod-crumb b { font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mod-crumb .mc-home { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
@media (max-width: 640px) { .mod-crumb { padding: 6px 16px 0; font-size: 11.5px; } .mod-crumb li.mc-sub { display: none; } }

/* ---------- «Next step» panel ---------- */
.nx { margin: 16px 0 4px; padding: 12px 14px 14px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--soft); }
@media (prefers-reduced-motion: no-preference) { .nx { animation: nx-in .28s ease-out both; } }
@keyframes nx-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.nx-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.nx-h b { font-size: 14px; color: var(--text); }
.nx-x { min-width: 32px; min-height: 32px; border-radius: 8px; color: var(--muted); background: none; border: 0; cursor: pointer; }
.nx-x:hover { background: var(--soft-2); color: var(--text); }
.nx-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); gap: 8px; }
.nx-step { --c: var(--accent); display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft-2); color: var(--text); text-decoration: none; min-width: 0; }
.nx-step:hover { border-color: color-mix(in srgb, var(--c) 55%, var(--line-2)); background: color-mix(in srgb, var(--c) 10%, var(--soft-2)); }
.nx-step:focus-visible { outline: 2px solid var(--c); outline-offset: 2px; }
.nx-ic { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; color: var(--c); background: color-mix(in srgb, var(--c) 16%, transparent); }
.nx-t { display: flex; flex-direction: column; min-width: 0; }
.nx-t b { font-size: 13.5px; font-weight: 600; line-height: 1.3; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.nx-t small { font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nx-file { font-style: normal; }
