/* Ludoq — app shell: sidebar, top bar, command menu (⌘K), Ludoq AI copilot (⌘J).
   Loaded automatically by js/shell.js (pages don't need to link it). Uses tokens from styles.css only. */

html.has-shell body{background:var(--bg-canvas)}
.shell{--sbw:var(--sb-w);--cpw:0px;overflow-x:clip;display:grid;grid-template-columns:var(--sbw) minmax(0,1fr) var(--cpw);min-height:100vh;transition:grid-template-columns var(--dur-spring) var(--spring-soft)}
.shell.sb-mini{--sbw:var(--sb-w-mini)}
/* Nov 29: Ask Ludoq is a popover above the launcher (css/ludoq-panel.css), so the grid keeps no third column (--cpw stays 0) */
/* full-bleed pages (record, editor, board, reels): the page fills the viewport, no document scroll */
html.shell-full,html.shell-full body{height:100%;overflow:hidden}
.shell.full{height:100vh;min-height:0;flex:1 1 auto;width:100%}
.shell.full .sh-main{height:100vh;min-height:0}
.shell.full #page{flex:1 1 auto;min-height:0;display:flex;flex-direction:column;overflow:hidden;position:relative}

[data-theme="light"] .sb{--knock:var(--sb-active)}
/* ───────── sidebar ─────────
   Geometry: every leading glyph (workspace tile, emoji tiles, avatar centre) sits on x = 16–36px, in both the
   expanded column and the 52px rail, so collapsing only clips and fades labels — nothing jumps. */
.sb{--knock:var(--sb-active);--ctl-fill:var(--neutral-200);--ctl-fill-hover:var(--neutral-275);--ctl-ghost-hover:var(--neutral-200);--ctl-fill-2:var(--neutral-275);   /* surface ladder: the sidebar is one step darker, so its controls step once more */
  position:sticky;top:0;height:100vh;display:flex;flex-direction:column;min-width:0;background:var(--sidebar);border-right:1px solid var(--sb-line);z-index:var(--z-shell);overflow:hidden}
.sb .lbl,.sb .sb-ws b,.sb .sb-ws>.ic,.sb .who,.sb .sb-acct>.ic,.sb .sb-h-t>*,.sb .n,.sb .sb-empty{transition:opacity var(--dur) var(--ease)}

/* header: workspace switcher + hover tools (collapse, create) */
.sb-top{position:relative;display:flex;align-items:center;height:var(--tb-h);padding:0 8px;flex:none}
.sb-ws{flex:1;min-width:0;display:flex;align-items:center;gap:8px;height:32px;padding:0 8px;margin-right:56px;border-radius:var(--r-btn);text-align:left;transition:background var(--dur-fast) var(--ease)}
.sb-ws:hover,.sb-ws[aria-expanded="true"]{background:var(--row-hover)}
.sb-ws:focus-visible{outline:none;box-shadow:inset 0 0 0 1.5px var(--accent)}
.ws-tile{width:20px;height:20px;border-radius:5px;display:grid;place-items:center;flex:none;background:var(--inv-bg);color:#fff;font:600 12px/1 var(--sans);box-shadow:inset 0 0 0 1px rgba(255,255,255,.14);background-size:cover;background-position:center}
.sb-ws b{font:600 13px/1.1 var(--sans);letter-spacing:-.006em;color:var(--text-1);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb-ws>.ic{color:var(--text-3);flex:none}
.sb-top-tools{position:absolute;right:8px;top:50%;transform:translateY(-50%);display:flex;gap:2px;opacity:0;transition:opacity var(--dur) var(--ease)}
.sb:hover .sb-top-tools,.sb-top-tools:focus-within{opacity:1}
.sb-top-tools .ib{color:var(--text-3)}
.sb-top-tools .ib:hover{color:var(--text-1)}

.sb-scroll{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden;padding:2px 8px 12px;scrollbar-width:none}
.sb-scroll::-webkit-scrollbar{display:none}
.sb-nav{display:flex;flex-direction:column;gap:2px}
/* selection (Premium pass §8.3): no gliding indicator — the current row is filled in place (see "Sidebar selection" below) */
.sb-scroll{position:relative}
/* more rows below the Record footer: the last 24px fade, so the cut is a hint, not a hidden row */
.sb-scroll.more-below{-webkit-mask-image:linear-gradient(to bottom,currentColor calc(100% - 24px),transparent);mask-image:linear-gradient(to bottom,currentColor calc(100% - 24px),transparent)}   /* ds-allow: L8 — an alpha mask for the scroll edge, not a colour gradient */
.sb-quick{margin-bottom:10px}

/* rows */
.sb-link{position:relative;display:flex;align-items:center;gap:8px;width:100%;height:var(--row-h);padding:0 8px;border-radius:var(--r-btn);color:var(--text-1);font:400 13px/1 var(--sans);letter-spacing:0;white-space:nowrap;text-align:left;transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.sb-link:hover{background:var(--row-hover);color:var(--text-1)}
.sb .glyph:not(.emo){color:var(--text-1)}
.sb-link.sb-search>.glyph,.sb-link.sb-more>.glyph{color:var(--text-2)}
.sb-link[aria-current="page"]>.glyph:not(.emo),.sb-link[aria-current="page"]>.ic{color:var(--sb-active-ic)}
.sb-link.rec-link .ic .rec{fill:var(--rec)}
.sb .sb-link.rec-link>.glyph:not(.emo),.sb .sb-link.rec-link>.ic{color:var(--rec)}
.sb-link:active{background:var(--row-active)}
.sb-link[aria-current="page"]{background:var(--sb-active);box-shadow:var(--sb-active-shadow);color:var(--text-1)}
.sb-link:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1);box-shadow:none}
.sb-link>.ic{color:var(--text-1);width:18px;height:18px}
.sb .glyph .ic{width:18px;height:18px}
.sb .glyph.emo{font-size:16px}
.sb-link .glyph{margin-left:-1px}

.sb-link.rec-link[aria-current="page"] .ic .rec,.sb-link.rec-link:hover .ic .rec{fill:var(--rec)}
.sb-link[aria-current="page"]{font-weight:500}
.sb-link .lbl{flex:1;overflow:hidden;text-overflow:ellipsis;min-width:0}
.sb-link .kbd-row{opacity:0;transition:opacity var(--dur-fast) var(--ease)}
.sb-link:hover .kbd-row,.sb-link:focus-visible .kbd-row{opacity:1}
.sb-link .n{margin-left:auto;font:500 12px/1 var(--sans);color:var(--text-3)}
.sb-link .n.hot{min-width:18px;height:18px;padding:0 5px;border-radius:var(--r-full);display:inline-grid;place-items:center;background:var(--fg-default);color:#fff;font:600 12px/1 var(--sans);font-variant-numeric:tabular-nums}
.sb-link .glyph{transition:transform var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}

/* sections: label toggles open/closed (animated), hover reveals the chevron and the + */
.sb-sec{margin-top:14px}
.sb-h{position:relative;display:flex;align-items:center;height:26px;margin-bottom:1px}
.sb-h-t{flex:1;min-width:0;display:flex;align-items:center;gap:4px;height:24px;padding:0 8px;border-radius:6px;font:600 12px/1 var(--sans);color:var(--text-2);text-align:left;transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.sb-h-t:hover{color:var(--text-2);background:var(--row-hover)}
.sb-h-t:focus-visible{outline:none;box-shadow:inset 0 0 0 1.5px var(--accent)}
.sb-h-t .ic{opacity:0;transition:opacity var(--dur-fast) var(--ease),transform var(--dur-spring-fast) var(--spring-snappy)}
.sb-h:hover .sb-h-t .ic,.sb-h-t:focus-visible .ic,.sb-sec.closed .sb-h-t .ic{opacity:1}
.sb-sec.closed .sb-h-t .ic{transform:rotate(-90deg)}
.sb-h-add{position:absolute;right:2px;top:1px;color:var(--text-3);opacity:0;transition:opacity var(--dur-fast) var(--ease)}
.sb-h:hover .sb-h-add,.sb-h-add:focus-visible{opacity:1}
.sb-sec-body{display:grid;grid-template-rows:1fr;transition:grid-template-rows var(--dur-spring) var(--spring-soft),opacity .22s var(--ease-out-quint)}
.sb-sec-body>.sb-nav{min-height:0;overflow:hidden}
.sb-sec.closed .sb-sec-body{grid-template-rows:0fr;opacity:0}
.sb-empty{padding:6px 8px 4px;font-size:12px;line-height:1.45;color:var(--text-4)}

/* items with a hover action (favourites, spaces) + drag-to-reorder */
.sb-item{position:relative;border-radius:var(--r-btn)}
.sb-act{position:absolute;right:3px;top:3px;width:22px;height:22px;display:grid;place-items:center;border-radius:5px;color:var(--text-3);opacity:0;transition:opacity var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}
.sb-item:hover .sb-act,.sb-act:focus-visible,.sb-act[aria-expanded="true"]{opacity:1}
.sb-act:hover,.sb-act[aria-expanded="true"]{background:var(--row-active);color:var(--text-1)}
.sb-act:focus-visible{outline:none;box-shadow:inset 0 0 0 1.5px var(--accent)}
.sb-item:hover .sb-link,.sb-item:focus-within .sb-link{padding-right:30px}
.sb-item[draggable="true"] .sb-link{cursor:pointer}
.sb-item.dragging{opacity:.4}
.sb-item.drop-before::before,.sb-item.drop-after::after{content:"";position:absolute;left:8px;right:8px;height:2px;border-radius:1px;background:var(--accent);pointer-events:none;z-index:1}
.sb-item.drop-before::before{top:-1.5px}
.sb-item.drop-after::after{bottom:-1.5px}

/* footer: usage card, settings, account */
.sb-foot{flex:none;padding:6px 8px 8px;display:flex;flex-direction:column;gap:2px;border-top:1px solid var(--sb-line);background:var(--sidebar)}
.sb-acct{display:flex;align-items:center;gap:8px;height:40px;padding:0 6px;border-radius:var(--r-btn);text-align:left;width:100%;transition:background var(--dur-fast) var(--ease)}
.sb-acct:hover,.sb-acct[aria-expanded="true"]{background:var(--row-hover)}
.sb-acct:focus-visible{outline:none;box-shadow:inset 0 0 0 1.5px var(--accent)}
.sb-acct .who{min-width:0;flex:1;display:flex;flex-direction:column;gap:3px}
.sb-acct b{font:500 13px/1.1 var(--sans);color:var(--text-1);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb-acct small{font-size:12px;line-height:1.1;color:var(--text-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb-acct>.ic{color:var(--text-3)}

/* collapsed rail: same positions, labels fade, section labels become hairlines */
.sb-mini .sb .lbl,.sb-mini .sb .sb-ws b,.sb-mini .sb .sb-ws>.ic,.sb-mini .sb .who,.sb-mini .sb .sb-acct>.ic,.sb-mini .sb .sb-h-t>*,.sb-mini .sb .n:not(.hot),.sb-mini .sb .sb-empty,.sb-mini .sb .sb-link .kbd-row{opacity:0;pointer-events:none}
.sb-mini .sb-ws{margin-right:0}
.sb-mini .sb-top-tools,.sb-mini .sb-h-add,.sb-mini .sb-act{opacity:0!important;pointer-events:none}
.sb-mini .sb-h-t{pointer-events:none;color:transparent;font-size:0}
.sb-mini .sb-h::after{content:"";position:absolute;left:12px;right:12px;top:50%;height:1px;background:var(--line)}
.sb-mini .sb-sec.closed .sb-sec-body{grid-template-rows:0fr;opacity:0}
.sb-mini .sb-empty{display:none}
.sb-mini .sb-item .sb-link{padding-right:8px}
.sb-mini .sb-link .n.hot{position:absolute;left:32px;top:3px;min-width:0;width:8px;height:8px;padding:0;font-size:0;box-shadow:0 0 0 2px var(--sidebar)}
.sb-expand{display:none}
.sb-mini .sb-expand{display:inline-flex}

/* floating sidebar tooltip (js) */
.sb-tip{position:fixed;z-index:var(--z-toast);display:flex;align-items:center;gap:8px;max-width:280px;padding:5px 8px;border-radius:6px;background:var(--tip-bg);color:var(--tip-text);box-shadow:inset 0 0 0 1px var(--tip-line),0 6px 18px -6px rgba(0,0,0,.45);font:500 12px/1.2 var(--sans);white-space:nowrap;pointer-events:none;opacity:0;transform:translateY(-2px);transition:opacity var(--dur-fast) var(--ease),transform var(--dur-fast) var(--ease)}
.sb-tip.right{transform:translateX(-3px)}
.sb-tip.show{opacity:1;transform:none}
.sb-tip span:first-child{overflow:hidden;text-overflow:ellipsis}
/* with a one-line description (Projects, Collections — Loom lessons §12): two lines, beside the row */
.sb-tip.desc{max-width:260px;padding:var(--space-8) var(--space-12);white-space:normal}
.sb-tip-2{display:flex;flex-direction:column;gap:2px;min-width:0}
.sb-tip-2 b{display:flex;align-items:center;justify-content:space-between;gap:var(--space-12);font:600 var(--fs-12)/16px var(--font-sans)}
.sb-tip-2 small{font:400 var(--fs-12)/16px var(--font-sans);color:var(--tip-text);opacity:.78}

/* ───────── main column + top bar ───────── */
.sh-main{min-width:0;display:flex;flex-direction:column;min-height:100vh}
.tb{position:sticky;top:0;z-index:var(--z-sticky);height:var(--tb-h);flex:none;display:flex;align-items:center;gap:8px;padding:0 12px 0 12px;background:var(--bg);border-bottom:1px solid var(--line)}
.tb-menu{display:none}
.crumbs{display:flex;align-items:center;gap:2px;min-width:0;font:500 13px/1 var(--sans);color:var(--text-2);margin-left:2px}
.crumbs .ic,.crumbs .glyph .ic{width:16px;height:16px}
.crumbs .glyph{width:18px;height:18px;color:inherit}
.crumbs>a,.crumbs>span:not(.sep){display:inline-flex;align-items:center;gap:6px;height:28px;padding:0 8px;border-radius:var(--r-btn);white-space:nowrap;min-width:0;max-width:280px;transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.crumbs .crumb-t{overflow:hidden;text-overflow:ellipsis;min-width:0}
.crumbs a:hover{background:var(--row-hover);color:var(--text-1)}
.crumbs a:focus-visible{outline:none;box-shadow:inset 0 0 0 1.5px var(--accent)}
.crumbs [aria-current="page"]{color:var(--text-1);font-weight:500}
.crumbs .sep{display:inline-flex;color:var(--text-4);padding:0;flex:none}
.tb-actions{margin-left:auto;display:flex;align-items:center;gap:6px;min-width:0}
.tb-actions:empty{display:none}
.tb-pres{display:inline-flex;align-items:center;margin-right:4px}.tb-pres:empty{display:none}.tb .pres{--pres-ring:var(--bg)}
.tb-fixed{display:flex;align-items:center;gap:6px;margin-left:auto}
/* history: Back / Forward (Premium pass §8.1) — two chromeless 28px chevrons, a 16px hairline, then the breadcrumb */
.tb-hist{display:flex;align-items:center;gap:var(--space-2);flex:none}
.tb-hist::after{content:"";width:1px;height:16px;margin-left:var(--space-12);background:var(--border-subtle)}
.tb-nav{width:var(--h-28);height:var(--h-28);color:var(--icon-muted)}
.tb-nav:hover{background:var(--bg-hover);color:var(--icon-default)}
.tb-nav:active{background:var(--bg-pressed)}
.tb-nav[disabled]{color:var(--icon-disabled);background:transparent}
.tb-hist+.crumbs{margin-left:var(--space-4)}
/* search pill (opens the palette) */
.tb-search{display:inline-flex;align-items:center;gap:8px;height:30px;width:200px;padding:0 6px 0 10px;border-radius:var(--r-btn);background:var(--input-bg);box-shadow:inset 0 0 0 1px var(--input-line);color:var(--text-3);font:400 13px/1 var(--sans);transition:box-shadow var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.tb-search:hover{color:var(--text-2);box-shadow:inset 0 0 0 1px var(--line-3)}
.tb-search:focus-visible{outline:none;box-shadow:inset 0 0 0 1px var(--accent),var(--focus)}
.tb-search .txt{flex:1;text-align:left}
/* account avatar */
.tb-av{width:30px;height:30px;display:inline-grid;place-items:center;border-radius:50%;flex:none;transition:box-shadow var(--dur-fast) var(--ease)}
.tb-av:hover,.tb-av[aria-expanded="true"]{box-shadow:0 0 0 2px var(--line-2)}
.tb-av:focus-visible{outline:none;box-shadow:var(--focus)}
.tb-av .av{background-size:cover;background-position:center}
.tb .tb-bell{width:30px;height:30px}
@media (max-width:1180px){.tb-search{width:auto}.tb-search .txt,.tb-search .kbd-row{display:none}}
.tb-actions:not(:empty)+.tb-fixed{margin-left:4px;padding-left:8px;border-left:1px solid var(--line)}
.tb-ai{display:inline-flex;align-items:center;gap:6px;height:30px;padding:0 6px 0 10px;border-radius:var(--r-btn);color:var(--text-2);font:500 13px/1 var(--sans);background:var(--btn-2);transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease),box-shadow var(--dur-fast) var(--ease)}
.tb-ai:hover{background:var(--btn-2-hover);color:var(--text-1)}
.tb-ai[aria-pressed="true"]{background:var(--row-hover);color:var(--text-1)}
.tb-ai:focus-visible{outline:none;box-shadow:var(--focus)}
.tb-ai .ic{color:var(--text-1)}
.tb-ai .kbd-row{margin-left:2px}
#page{flex:1 1 auto;min-width:0;position:relative}
#page:focus{outline:none}

/* page layout helpers for page builders (.page-head lives in styles.css) */
.page-wrap{max-width:var(--page-max);margin:0 auto;padding:var(--page-top) var(--page-x) var(--space-64)}   /* Premium pass §4: Home + wide list pages share one cap */
.page-wrap.narrow{max-width:880px}

/* ───────── scrim (mobile drawer, overlay copilot) ───────── */
.sh-scrim{position:fixed;inset:0;z-index:calc(var(--z-panel) - 1);background:var(--overlay);opacity:0;pointer-events:none;transition:opacity var(--dur) var(--ease)}
.sh-scrim.show{opacity:1;pointer-events:auto}

/* ───────── copilot ───────── */
/* the Ask Ludoq popover (founder order Nov 29): anchored above the launcher; js/shell.js placePopover() sets --lq-pop-r/-b */
.cp{position:fixed;right:var(--lq-pop-r,var(--space-24));bottom:var(--lq-pop-b,var(--space-24));width:min(400px,calc(100vw - var(--space-32)));height:min(600px,70vh,calc(100vh - var(--lq-pop-b,var(--space-24)) - var(--space-16)));   /* ds-allow: L4 — anchored above the launcher; js/shell.js placePopover() sets the px */
  display:flex;flex-direction:column;background:var(--bg-surface);border-radius:var(--radius-dialog);box-shadow:inset 0 0 0 1px var(--border-subtle),var(--shadow-overlay);z-index:var(--z-popover);overflow:hidden;
  visibility:hidden;opacity:0;transform:translateY(8px) scale(.92);transform-origin:100% 100%;
  transition:opacity var(--dur-fast) var(--ease-exit),transform var(--dur-fast) var(--ease-exit),visibility 0s var(--dur-fast)}
.shell.cp-open .cp{visibility:visible;opacity:1;transform:none;transition:opacity var(--dur-slow) var(--ease-out-quint),transform var(--dur-slow) var(--ease-out-quint),visibility 0s}
.cp-head{height:var(--tb-h);flex:none;display:flex;align-items:center;gap:8px;padding:0 8px 0 14px;border-bottom:1px solid var(--line)}
.cp-head .title{display:flex;align-items:center;gap:8px}
.cp-head .title{font:600 13px/1 var(--sans);color:var(--text-1)}
.cp-mark{display:inline-grid;place-items:center;width:20px;height:20px;color:var(--icon-default)}
.cp-ctx{margin-left:2px}
.cp-head .spacer{flex:1}
.cp-body{flex:1;min-height:0;overflow-y:auto;padding:16px 14px 8px;display:flex;flex-direction:column;gap:14px;scrollbar-width:thin;scrollbar-color:var(--line-2) transparent}
.cp-hello{padding:12px 2px 4px}
.cp-hello h3{font:600 17px/1.3 var(--sans);letter-spacing:-.01em;color:var(--text-1)}
.cp-hello p{margin-top:6px;font-size:13px;line-height:1.5;color:var(--text-2)}
.cp-sugs{display:flex;flex-direction:column;gap:2px}
.cp-sugs .menu-h{padding-left:2px}
.cp-sug{display:flex;align-items:center;gap:10px;min-height:32px;padding:6px 8px;border-radius:var(--r-btn);text-align:left;font-size:13px;color:var(--text-2);transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.cp-sug:hover,.cp-sug:focus-visible{background:var(--row-hover);color:var(--text-1);outline:none}
.cp-sug .ic{color:var(--text-3)}
.cp-msg{font-size:13px;line-height:1.55;color:var(--text-1);animation:fade-up var(--dur-slow) var(--ease) both}
.cp-msg.user{align-self:flex-end;max-width:88%;padding:8px 12px;border-radius:10px 10px 3px 10px;background:var(--surface-3);white-space:pre-wrap;word-break:break-word}
.cp-msg.ai{display:flex;flex-direction:column;gap:10px}
.cp-msg.ai>p{color:var(--text-2)}
.cp-think{display:flex;align-items:center;gap:8px;font-size:13px;color:var(--text-3)}
.cp-think i{width:5px;height:5px;border-radius:50%;background:var(--text-3);animation:pulse 1s var(--ease) infinite}
.cp-think i:nth-child(2){animation-delay:.15s}
.cp-think i:nth-child(3){animation-delay:.3s}
.cp-chips{display:flex;flex-wrap:wrap;gap:6px}
.cp-chips button{height:26px;padding:0 10px;border-radius:var(--r-full);background:var(--surface-2);box-shadow:var(--ring);font-size:13px;color:var(--text-2)}
.cp-chips button:hover{color:var(--text-1);background:var(--surface-3)}
/* plan card */
.plan{border-radius:var(--r-card);background:var(--surface);box-shadow:var(--ring);overflow:hidden}
.plan-h{display:flex;align-items:center;gap:8px;padding:10px 12px 0}
.plan-h .badge{margin-left:auto}
.plan-sum{padding:8px 12px 4px;font:500 14px/1.45 var(--sans);color:var(--text-1)}
.plan-steps{list-style:none;padding:4px 12px 12px;display:flex;flex-direction:column;gap:6px;counter-reset:st}
.plan-steps li{display:flex;gap:10px;font-size:13px;line-height:1.45;color:var(--text-2)}
.plan-steps .n{width:18px;height:18px;border-radius:50%;flex:none;display:grid;place-items:center;background:var(--surface-3);color:var(--text-3);font:600 12px/1 var(--sans);transition:background var(--dur) var(--ease),color var(--dur) var(--ease)}
.plan-steps li.done .n{background:var(--fg-default);color:#fff}
.plan-steps li small{display:block;color:var(--text-3);font-size:12px}
.plan-foot{display:flex;align-items:center;gap:6px;padding:10px 12px;border-top:1px solid var(--line);background:var(--surface-2)}
.plan-foot .meta{margin-left:auto;font-size:12px}
.plan.applied .plan-foot,.plan.discarded .plan-foot{background:transparent}
.plan-state{display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:500;color:var(--text-2)}
.plan.applied .plan-state .ic{color:var(--pos)}
.plan.discarded{opacity:.6}
.plan.discarded .plan-steps{display:none}
.cp-input{flex:none;padding:10px 12px 12px;border-top:1px solid var(--line)}
.cp-box{display:flex;flex-direction:column;gap:6px;padding:8px 8px 8px 10px;border-radius:var(--r-card);background:var(--surface);box-shadow:var(--ring);transition:box-shadow var(--dur-fast) var(--ease)}
.cp-box:focus-within{box-shadow:inset 0 0 0 1px var(--accent),0 0 0 3px var(--accent-weak)}
.cp-box textarea{border:0;outline:0;background:transparent;resize:none;font-size:13px;line-height:1.5;min-height:40px;max-height:160px;color:var(--text-1)}
.cp-box textarea::placeholder{color:var(--text-4)}
.cp-row{display:flex;align-items:center;gap:8px}
.cp-row .meta{font-size:12px}
.cp-row .btn{margin-left:auto}

/* ───────── command menu ───────── */
.cmdk-wrap{position:fixed;inset:0;z-index:var(--z-palette);display:flex;justify-content:center;align-items:flex-start;padding:12vh 16px 16px}
.cmdk-bg{position:absolute;inset:0;background:var(--overlay);opacity:0;transition:opacity .2s var(--ease-out-quint)}
.cmdk{position:relative;width:100%;max-width:640px;max-height:min(560px,76vh);display:flex;flex-direction:column;background:var(--elevated);border-radius:var(--r-modal);box-shadow:var(--shadow-lg);overflow:hidden;opacity:0;transform:translateY(-8px) scale(.97);transform-origin:50% 0;transition:opacity .16s var(--ease-out-quint),transform var(--dur-spring-fast) var(--spring-snappy)}
.cmdk-wrap.show .cmdk-bg{opacity:1}
.cmdk-wrap.show .cmdk{opacity:1;transform:none}
/* the palette's search box is the standard .search-field (full width) */
.cmdk-in{flex:none;padding:12px 12px 4px}
.cmdk-list{flex:1;min-height:0;overflow-y:auto;padding:6px;scrollbar-width:thin;scrollbar-color:var(--line-2) transparent}
.cmdk-g{padding:12px 10px 6px;font:500 12px/1 var(--sans);color:var(--text-3)}
.cmdk-g:first-child{padding-top:6px}
.cmdk-i{display:flex;align-items:center;gap:10px;width:100%;height:36px;padding:0 10px;border-radius:var(--r-btn);text-align:left;font-size:13px;color:var(--text-1);cursor:pointer}
.cmdk-i>.ic,.cmdk-i>.glyph{color:var(--text-3)}
.cmdk-i[aria-selected="true"]>.glyph{color:var(--text-1)}
.cmdk-i .lbl{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cmdk-i .sub{color:var(--text-3);font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}
.cmdk-i .end{margin-left:auto;display:flex;align-items:center;gap:6px;flex:none;color:var(--text-3);font-size:12px}
.cmdk-i[aria-selected="true"]{background:var(--row-active)}
.cmdk-i .cmdk-open{display:inline-flex;align-items:center;gap:4px;opacity:0}
.cmdk-i[aria-selected="true"] .cmdk-open{opacity:1}
.cmdk-i[aria-selected="true"]>.ic{color:var(--text-1)}
.cmdk-i .icon-tile{--sz:20px}
.cmdk-i mark{background:transparent;color:var(--text-1);font-weight:600;padding:0}
.cmdk-empty{display:flex;flex-direction:column;align-items:center;gap:6px;padding:36px 16px;text-align:center;color:var(--text-3);font-size:13px}
.cmdk-empty .etile{margin-bottom:6px}
.cmdk-empty b{font:600 13px/1.3 var(--sans);color:var(--text-1)}
.cmdk-foot{display:flex;align-items:center;gap:14px;height:36px;padding:0 14px;border-top:1px solid var(--line);font-size:12px;color:var(--text-3);flex:none;background:var(--surface-2)}
.cmdk-foot span{display:inline-flex;align-items:center;gap:5px}
.cmdk-foot .spacer{flex:1}

/* account popover */
.acct-pop{width:260px}
.acct-pop .acct-h{display:flex;align-items:center;gap:10px;padding:14px 12px 10px}
.acct-pop .acct-h b{display:block;font:600 13px/1.2 var(--sans)}
.acct-pop .acct-h small{display:block;font-size:12px;color:var(--text-3);margin-top:2px}
.acct-pop .acct-theme{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:4px 8px 8px 12px;font-size:13px;color:var(--text-2)}
.acct-pop .seg button{padding:0 8px}

/* project dialog */
.spd-type{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}
.spd-t{position:relative;display:flex;flex-direction:column;align-items:flex-start;gap:8px;padding:10px 12px;border-radius:var(--r-card);background:var(--surface);box-shadow:inset 0 0 0 1px var(--line);cursor:pointer;transition:box-shadow var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}
.spd-t:hover{background:var(--row-hover)}
.spd-t input{position:absolute;opacity:0;pointer-events:none}
.spd-t b{font:500 13px/1 var(--sans);color:var(--text-1)}
.spd-ti{display:grid;place-items:center;width:28px;height:28px;border-radius:var(--r-btn);background:var(--surface-3);color:var(--text-2)}
.spd-t:has(input:checked){box-shadow:inset 0 0 0 1.5px var(--fg-default);background:var(--accent-weak)}
.spd-t:has(input:checked) .spd-ti{background:var(--fg-default);color:var(--on-accent)}
.spd-t:has(input:focus-visible){box-shadow:inset 0 0 0 1.5px var(--accent),var(--focus)}
.space-colors{display:flex;flex-wrap:wrap;gap:6px}
.space-colors button{width:28px;height:28px;border-radius:6px;display:grid;place-items:center;background:var(--tag-bg);color:var(--tag-text);box-shadow:inset 0 0 0 1px var(--line)}
.space-colors button[aria-pressed="true"]{box-shadow:0 0 0 2px var(--elevated),0 0 0 4px var(--fg-default)}
.space-emoji{display:flex;flex-wrap:wrap;gap:4px}
.space-emoji button{width:32px;height:32px;border-radius:6px;font:17px/1 var(--emoji)}
.space-emoji button:hover{background:var(--row-hover)}
.space-emoji button[aria-pressed="true"]{background:var(--accent-weak);box-shadow:inset 0 0 0 1px var(--accent-line)}

/* ───────── responsive ───────── */
@media (max-width:1279px){
}
@media (max-width:760px){
  .shell,.shell.sb-mini{--sbw:0px;grid-template-columns:minmax(0,1fr)}
  .sb{position:fixed;left:0;top:0;bottom:0;width:min(300px,86vw);height:auto;transform:translateX(-100%);visibility:hidden;transition:transform var(--dur-spring) var(--spring-soft),visibility 0s var(--dur-spring);box-shadow:var(--shadow-lg)}
  .sb{z-index:var(--z-panel)}   /* above the scrim (z-panel − 1), so the open drawer is not dimmed and takes clicks */
  .shell.sb-open .sb{transform:none;visibility:visible;transition:transform var(--dur-spring) var(--spring-soft),visibility 0s}   /* closed drawer: off-screen AND out of the tab order */
  .sb-collapse,.sb-expand{display:none!important}
  .tb{padding:0 8px}
  .tb-menu{display:inline-flex}
  .tb-ai .txt,.tb-ai .kbd-row{display:none}
  .tb-hist{display:none}
  .tb-hist+.crumbs{border-left:0;padding-left:0}
  .crumbs a:not(:last-of-type),.crumbs .sep{display:none}
  .page-wrap{padding:16px 16px 48px}
  .cmdk-wrap{padding:8px}
}

/* ───────── notifications bell (top bar) ───────── */
.tb-bell{position:relative;color:var(--text-2)}
.tb-bell:hover,.tb-bell[aria-expanded="true"]{color:var(--text-1)}
.tb-bell-i{display:grid;place-items:center;transform-origin:50% 15%}
.tb-bell.has-new .tb-bell-i{animation:bell-nudge 1.1s var(--spring-bounce) 1 .6s}
.tb-badge{position:absolute;top:0;right:-2px;min-width:18px;height:18px;padding:0 5px;border-radius:var(--r-full);background:var(--sys-red);color:#fff;font:600 12px/18px var(--sans);text-align:center;font-variant-numeric:tabular-nums;box-shadow:0 0 0 2px var(--bg);pointer-events:none}
@keyframes bell-nudge{0%,100%{transform:rotate(0)}20%{transform:rotate(14deg)}40%{transform:rotate(-10deg)}60%{transform:rotate(6deg)}80%{transform:rotate(-3deg)}}

/* notification popover */
.pop.notif-wrap{padding:0;min-width:0}
.notif-pop{width:400px;max-width:calc(100vw - 16px);display:flex;flex-direction:column;max-height:min(600px,calc(100vh - 80px))}
.np-h{display:flex;align-items:center;gap:6px;height:44px;padding:0 8px 0 14px;flex:none}
.np-h b{font:600 13px/1 var(--sans);color:var(--text-1)}
.np-n{font:500 12px/1 var(--sans);color:var(--accent-text);background:var(--accent-weak);padding:3px 6px;border-radius:var(--r-full)}
.np-h .spacer{flex:1}
.np-tabs{margin:0 10px 6px;flex:none}
.np-tabs button{height:22px;font-size:12px}
.np-c{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 4px;border-radius:var(--r-full);background:var(--surface-3);font:600 12px/1 var(--sans);color:var(--text-2)}
.np-list{flex:1;min-height:0;overflow:auto;padding:2px 6px 6px}
.np-row{position:relative;display:flex;gap:10px;align-items:flex-start;padding:10px 26px 10px 8px;border-radius:8px;cursor:pointer;outline:none;transition:background var(--dur-fast) var(--ease)}
.np-row:hover,.np-row:focus-visible{background:var(--row-hover)}
.np-row:focus-visible{box-shadow:inset 0 0 0 1.5px var(--accent)}
.np-av{position:relative;flex:none;margin-top:1px}
.np-type{position:absolute;right:-4px;bottom:-3px;width:16px;height:16px;border-radius:50%;display:grid;place-items:center;color:var(--fg-default);box-shadow:0 0 0 2px var(--elevated)}
.np-type[class*="tone-"]{background:var(--neutral-200)}   /* direction B: one neutral badge for every kind (no green/purple/blue/teal) */
.tone-blue{background:var(--sys-blue)} .tone-gray{background:var(--sys-gray)} .tone-purple{background:var(--sys-purple)} .tone-green{background:var(--sys-green)}
.tone-teal{background:var(--sys-teal)} .tone-orange{background:var(--sys-orange)} .tone-indigo{background:var(--sys-indigo)} .tone-red{background:var(--sys-red)} .tone-pink{background:var(--sys-pink)} .tone-yellow{background:var(--sys-yellow)}
.np-body{min-width:0;flex:1;display:flex;flex-direction:column;gap:3px}
.np-line{font-size:13px;line-height:1.35;color:var(--text-2)}
.np-line b{font-weight:600;color:var(--text-1)}
.np-row:not(.unread) .np-line b{font-weight:500}
.np-text{font-size:13px;line-height:1.4;color:var(--text-2);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.np-meta{font-size:12px;color:var(--text-3);display:flex;align-items:center;gap:4px}
.np-meta .due{color:var(--warn)}
.np-dot{position:absolute;right:10px;top:16px;width:8px;height:8px;border-radius:50%;background:var(--fg-default)}
.np-acts{position:absolute;right:6px;top:6px;display:flex;gap:2px;opacity:0;transition:opacity var(--dur-fast) var(--ease);background:var(--elevated);border-radius:6px;box-shadow:var(--shadow-xs)}
.np-row:hover .np-acts,.np-row:focus-within .np-acts{opacity:1}
.np-row:hover .np-dot,.np-row:focus-within .np-dot{opacity:0}
.np-empty{display:flex;flex-direction:column;align-items:center;gap:6px;padding:40px 16px;text-align:center;font-size:13px;color:var(--text-3)}
.np-empty .ic{color:var(--pos-dot);margin-bottom:4px}
.np-empty b{font:600 13px/1.3 var(--sans);color:var(--text-1)}
.np-f{padding:8px 10px 10px;border-top:1px solid var(--line-2);flex:none}
.np-f .btn{justify-content:center}
.np-f .kbd-row{margin-left:6px}

/* ───────── mentions ───────── */
.mention{display:inline;padding:0 3px;margin:0 -1px;border-radius:4px;background:var(--accent-weak);color:var(--accent-text);font:inherit;font-weight:500;cursor:pointer}
.mention:hover{text-decoration:underline;text-underline-offset:2px}
.mention.me{background:var(--tag-yellow-bg);color:var(--tag-yellow-text)} /* ds-allow: L17 tag orange/yellow pair, founder-approved mockup 01 (10 tag colours) */
.mention-pop{position:fixed;z-index:var(--z-toast);width:260px;padding:5px;border-radius:var(--r-card);background:var(--elevated);box-shadow:var(--shadow);animation:pop-in var(--dur-spring-fast) var(--spring-snappy) both}
.mention-h{padding:6px 8px 4px;font:500 12px/1 var(--sans);color:var(--text-3)}
.mention-i{display:flex;align-items:center;gap:8px;height:32px;padding:0 8px;border-radius:6px;cursor:pointer;font-size:13px}
.mention-i .n{color:var(--text-1);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.mention-i .r{margin-left:auto;font-size:12px;color:var(--text-3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:45%}
.mention-i[aria-selected="true"]{background:var(--menu-hover);color:var(--text-1)}
.mention-i[aria-selected="true"] .n,.mention-i[aria-selected="true"] .r{color:#fff}
.mention-f{padding:6px 8px 3px;margin-top:3px;border-top:1px solid var(--line-2);font-size:12px;color:var(--text-3)}
@keyframes pop-in{from{opacity:0;transform:scale(.96) translateY(-2px)}to{opacity:1;transform:none}}

/* ───────── avatars with presence + stacks ───────── */
.tav{position:relative;display:inline-grid;flex:none;width:var(--sz);height:var(--sz);border-radius:50%;padding:0}
button.tav{cursor:pointer}
button.tav:focus-visible{outline:none;box-shadow:var(--focus)}
.tav.guest .av{box-shadow:inset 0 0 0 1.5px var(--elevated),0 0 0 1px var(--line-3)}
.pres-dot{position:absolute;right:-1px;bottom:-1px;width:calc(var(--sz) * .32);height:calc(var(--sz) * .32);min-width:8px;min-height:8px;border-radius:50%;background:var(--sys-gray-2);box-shadow:0 0 0 2px var(--pres-ring,var(--bg))}
.pres-dot.on{background:var(--success-fg)}
.pres{display:inline-flex;align-items:center;padding-left:4px}
.pres>.tav{margin-left:-6px;transition:transform var(--dur-spring-fast) var(--spring-snappy);animation:pres-in var(--dur-spring) var(--spring-soft) both}
.pres>.tav .av{box-shadow:0 0 0 2px var(--pres-ring,var(--bg))}
.pres>.tav:hover{transform:translateY(-2px);z-index:1}
.pres-more{margin-left:-6px;height:var(--sz);min-width:var(--sz);padding:0 6px;border-radius:var(--r-full);background:var(--surface-3);color:var(--text-2);font:600 12px/1 var(--sans);box-shadow:0 0 0 2px var(--pres-ring,var(--bg))}
.pres-more:hover{color:var(--text-1);background:var(--surface-4)}
@keyframes pres-in{from{opacity:0;transform:scale(.6)}to{opacity:1;transform:none}}

/* ───────── member card ───────── */
.pop.mcard-pop{min-width:0}
.mcard{width:300px;padding:16px 14px 12px;--pres-ring:var(--elevated)}
.mcard-h{display:flex;align-items:center;gap:12px}
.mcard-who{min-width:0;display:flex;flex-direction:column;gap:3px}
.mcard-who b{font:600 15px/1.2 var(--sans);color:var(--text-1)}
.mcard-who b .muted{font-weight:400;color:var(--text-3)}
.mcard-who span{font-size:13px;color:var(--text-2)}
.mcard-meta{display:flex;flex-direction:column;gap:8px;margin:14px 0 12px;padding-top:12px;border-top:1px solid var(--line-2)}
.mcard-meta>div{display:flex;gap:10px;align-items:flex-start;font-size:13px;color:var(--text-1)}
.mcard-meta dt{color:var(--text-3);flex:none;padding-top:1px}
.mcard-meta dd{display:flex;flex-wrap:wrap;align-items:center;gap:6px;min-width:0}
.mcard-meta .on{color:var(--pos)}
.mcard-sp .tag{height:20px}
.mono-ish{word-break:break-all}
.mcard-acts{display:flex;gap:6px;align-items:center}
.mcard-acts .ib{margin-left:auto}
.role-pill{display:inline-flex;align-items:center;height:20px;padding:0 7px;border-radius:var(--r-xs);font:500 12px/1 var(--sans);background:var(--surface-3);color:var(--text-2)}
.role-pill.r-owner{background:var(--tag-yellow-bg);color:var(--tag-yellow-text)} /* ds-allow: L17 tag orange/yellow pair, founder-approved mockup 01 (10 tag colours) */
.role-pill.r-admin{background:var(--tag-purple-bg);color:var(--tag-purple-text)}
.role-pill.r-creator{background:var(--bg-muted);color:var(--fg-default)}
.role-pill.r-viewer{background:var(--tag-green-bg);color:var(--tag-green-text)}
.role-pill.r-guest{background:var(--tag-brown-bg);color:var(--tag-brown-text)}

/* ───────── chip input (invite, request) ───────── */
.chip-input{display:flex;flex-wrap:wrap;align-items:center;gap:4px;min-height:var(--field-h,36px);padding:6px 8px;border:1px solid var(--input-line);border-radius:10px;background:var(--surface);cursor:text;transition:border-color var(--dur-fast) var(--ease),box-shadow var(--dur-fast) var(--ease)}
.chip-input:hover{border-color:var(--hair-3)}
.chip-input:focus-within{border-color:var(--accent);box-shadow:var(--field-ring)}
.ci-chips{display:contents}
.ci-chip{display:inline-flex;align-items:center;gap:5px;height:22px;padding:0 3px 0 7px;border-radius:var(--r-full);background:var(--surface-3);font-size:13px;color:var(--text-1);animation:pop-in .3s var(--spring-snappy) both}
.ci-chip .tav{margin-left:-4px}
.ci-chip.bad{background:var(--neg-weak);color:var(--neg)}
.ci-chip.dup{background:var(--warn-weak);color:var(--warn)}
.ci-chip button{width:16px;height:16px;display:grid;place-items:center;border-radius:50%;color:inherit;opacity:.7}
.ci-chip button:hover{opacity:1;background:var(--surface-4)}
.ci-in{flex:1;min-width:160px;height:22px;border:0;outline:0;background:transparent;font-size:14px;color:var(--text-1)}
.ci-in::placeholder{color:var(--ph)}

/* invite sheet */
.invite{display:flex;flex-direction:column;gap:16px}
.role-pick{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.rp{display:flex;flex-direction:column;gap:3px;padding:10px 12px;border-radius:var(--r-card);text-align:left;background:var(--surface);box-shadow:inset 0 0 0 1px var(--line-2);transition:box-shadow var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}
.rp:hover{background:var(--row-hover)}
.rp b{display:flex;align-items:center;gap:6px;font:600 13px/1.2 var(--sans);color:var(--text-1)}
.rp small{font-size:12px;line-height:1.35;color:var(--text-2)}
.rp .free{font:600 12px/1 var(--sans);padding:3px 5px;border-radius:4px;background:var(--pos-weak);color:var(--pos)}
.rp[aria-checked="true"]{box-shadow:inset 0 0 0 2px var(--fg-default);background:var(--accent-weak)}
.rp:focus-visible{outline:none;box-shadow:inset 0 0 0 2px var(--accent),var(--focus)}
.sp-pick{display:flex;flex-wrap:wrap;gap:6px}
.sp-tog{display:inline-flex;align-items:center;gap:6px;height:28px;padding:0 10px 0 6px;border-radius:var(--r-full);background:var(--surface);box-shadow:inset 0 0 0 1px var(--line-2);font-size:13px;color:var(--text-1)}
.sp-tog .tick{display:none;color:var(--accent-text)}
.sp-tog[aria-pressed="true"]{background:var(--accent-weak);box-shadow:inset 0 0 0 1px var(--accent-line)}
.sp-tog[aria-pressed="true"] .tick{display:inline-block}
.sp-tog:focus-visible{outline:none;box-shadow:var(--focus)}
.inv-note{display:flex;gap:6px;align-items:flex-start;font-size:13px;line-height:1.45;color:var(--text-2);margin:-4px 0}
.inv-note .ic{margin-top:1px;color:var(--text-3)}
.inv-note.warn .ic{color:var(--warn-dot)}
.inv-note:has(.ic):not(.warn) .ic{color:var(--pos-dot)}
.inv-link{border-radius:var(--r-card);background:var(--surface-2);padding:10px 12px;display:flex;flex-direction:column;gap:10px}
.inv-link-h{display:flex;align-items:center;gap:10px}
.inv-link-h>div{flex:1;min-width:0}
.inv-link-h b{display:block;font:600 13px/1.2 var(--sans)}
.inv-link-h small{display:block;font-size:12px;color:var(--text-2);margin-top:2px}
.link-btn{color:var(--accent-text);font-weight:500;text-decoration:underline;text-decoration-color:var(--accent-line);text-underline-offset:2px}
.inv-link-b{display:flex;gap:6px;align-items:center}
.inv-link-b .input{flex:1;min-width:0}
.inv-dom{display:inline-flex;align-items:center;gap:5px}
.inv-dom:hover{color:var(--text-1)}

/* request form */
.reqf{display:flex;flex-direction:column;gap:14px}
.reqf-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.reqf-opt{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:10px 12px;border-radius:var(--r-card);background:var(--surface-2);cursor:pointer}
.reqf-opt b{display:block;font:500 13px/1.3 var(--sans)}
.reqf-opt small{display:block;font-size:12px;color:var(--text-2);margin-top:2px}
.reqf-done{display:flex;flex-direction:column;align-items:center;gap:14px;text-align:center;font-size:13px;line-height:1.55;color:var(--text-2)}
.reqf-done b{color:var(--text-1)}
.reqf-done .linkbox{display:flex;gap:8px;width:100%}
.reqf-done .linkbox .input{flex:1}
.reqf-done .modal-foot{width:100%}

/* space dialog */
.spd{display:flex;flex-direction:column;gap:16px}
.spd-top{display:flex;gap:14px;align-items:flex-start}
.spd-icon{cursor:pointer;margin-top:22px;transition:transform var(--dur-spring-fast) var(--spring-snappy)}
.spd-icon:hover{transform:scale(1.05)}
.spd-icon:focus-visible{outline:none;box-shadow:var(--focus)}
.spd-name{flex:1;min-width:0;display:flex;flex-direction:column;gap:10px}
.spd-look{display:flex;flex-direction:column;gap:10px;padding:12px;border-radius:var(--r-card);background:var(--surface-2)}
.spd-priv{border:0;display:flex;flex-direction:column;gap:6px}
.spd-priv legend{font:500 13px/1.2 var(--sans);color:var(--text-2);margin-bottom:8px}
.spd-opt{display:flex;gap:10px;align-items:flex-start;padding:9px 10px;border-radius:var(--r-card);box-shadow:inset 0 0 0 1px var(--line-2);cursor:pointer;transition:box-shadow var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}
.spd-opt:has(:checked){box-shadow:inset 0 0 0 2px var(--fg-default);background:var(--accent-weak)}
.spd-opt .radio{margin-top:2px}
.spd-oi{color:var(--text-2);margin-top:1px}
.spd-opt b{display:block;font:500 13px/1.3 var(--sans);color:var(--text-1)}
.spd-opt small{display:block;font-size:12px;line-height:1.4;color:var(--text-2);margin-top:1px}
.spd-row{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:13px;color:var(--text-1)}
.spd-row .select{width:auto;min-width:130px}
.spd-people{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2px;max-height:184px;overflow:auto;padding:4px;border-radius:var(--r-card);box-shadow:inset 0 0 0 1px var(--line-2)}
.spd-p{display:flex;align-items:center;gap:8px;height:32px;padding:0 8px;border-radius:6px;font-size:13px;cursor:pointer;min-width:0}
.spd-p:hover{background:var(--row-hover)}
.spd-p span{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.spd-p small{font-size:12px;color:var(--text-3)}
.sb-more .glyph{color:var(--text-3)!important}
.sb-more .lbl{color:var(--text-3)}
@media (max-width:760px){.notif-pop{width:calc(100vw - 16px)}.role-pick,.reqf-grid,.spd-people{grid-template-columns:1fr}}

/* ───────── HUB RESTRUCTURE (Nov 22): New button · Today · Ask · Projects (expandable) · Collections · Inbox ───────── */
.sb-primary{gap:1px}
.sb-proj .sb-link{padding-right:30px}
.sb-tg{opacity:1;color:var(--text-3)}
.sb-tg .ic{transition:transform var(--dur-spring-fast) var(--spring-snappy)}
.sb-tg[aria-expanded="false"] .ic{transform:rotate(-90deg)}
.sb-sub{margin:0 0 2px}
.sb-sub .sb-nav{padding-left:12px;position:relative}
.sb-sub .sb-nav::before{content:"";position:absolute;left:17px;top:4px;bottom:4px;width:1px;background:var(--line)}
.sb-ws{margin-right:32px}
.sb-allproj .lbl,.sb-addproj .lbl{color:var(--text-2)}
.sb-allproj>.glyph,.sb-addproj>.glyph{color:var(--text-3)}
.sb-addproj{text-align:left}
.sb-mini .sb-sub .sb-nav{padding-left:0}
.sb-mini .sb-sub .sb-nav::before{display:none}
.sb-mini .sb-addproj,.sb-mini .sb-allproj{display:none}

/* which-project picker (New without a current project) */
.pp{display:flex;flex-direction:column;gap:12px}
.pp-sub{display:flex;align-items:center;gap:8px;margin:0;color:var(--text-2);font-size:13px}
.pp-list{display:flex;flex-direction:column;gap:2px;max-height:320px;overflow:auto;margin:0 -8px;padding:2px 8px}
.pp-row{display:flex;align-items:center;gap:10px;width:100%;min-height:44px;padding:6px 8px;border-radius:var(--r-btn);text-align:left;color:var(--text-1);transition:background var(--dur-fast) var(--ease)}
.pp-row:hover,.pp-row:focus-visible{background:var(--row-hover);outline:none}
.pp-row:focus-visible{box-shadow:inset 0 0 0 1.5px var(--accent)}
.pp-row>.ic{color:var(--text-3);margin-left:auto}
.pp-t{display:flex;flex-direction:column;gap:3px;min-width:0}
.pp-t b{font:500 13px/1.2 var(--sans)}
.pp-t small{font-size:12px;color:var(--text-3)}
/* projects toggle: the arrow is always there (full sidebar) */
.shell:not(.sb-mini) .sb-proj .sb-tg{opacity:1!important;pointer-events:auto}
.sb-proj .sb-tg[aria-expanded]{background:transparent;color:var(--text-3)}   /* a section toggle, not a pressed menu button */
.sb-proj .sb-tg:hover{background:var(--row-active);color:var(--text-1)}
.sb-more-proj{display:block;padding:4px 10px 4px 38px;font:500 12px/1.4 var(--sans);color:var(--text-3);text-decoration:none;border-radius:6px}
.sb-more-proj:hover{color:var(--text-1);background:var(--row-hover)}
.sb-mini .sb-more-proj{display:none}

/* one page, two views */
.pg-view{margin-right:6px}
.pg-view button{gap:5px}
.pg-view .ic,.pg-view svg{width:13px;height:13px}
.pg-view .busy,.pg-view button.busy{opacity:.6;pointer-events:none}
.pj-vsub{margin-left:8px;align-self:center}
.pp-th{width:64px;height:36px;border-radius:5px;object-fit:cover;flex:none;background:var(--thumb)}
.sb-item>.sb-act{z-index:2}
/* top bar never overlaps: page buttons keep their size, the breadcrumb gives way */
.tb .crumbs{flex:1 1 0;min-width:0;overflow:hidden}
.tb-actions{flex:0 1 auto;margin-left:0}
.tb-fixed{flex:none}
@media (max-width:1180px){
  .tb-actions .hide-sm,.tb-actions .bk-avs{display:none}
}
@media (max-width:760px){
  /* phone: page buttons become icon buttons, the less used ones move into their "more" menu */
  .tb-actions{overflow-x:auto;scrollbar-width:none;gap:4px}
  .tb-actions::-webkit-scrollbar{display:none}
  .tb-actions .btn{font-size:0;gap:0;padding:0;width:30px;flex:none}
  .tb-actions .btn .ic,.tb-actions .btn svg{width:16px;height:16px;margin:0}
  .tb-actions .seg button{font-size:0;gap:0;padding:0 7px}
  .tb-actions .tb-pres,.tb-actions .av-stack,.tb-search{display:none}
  .tb-actions:not(:empty)+.tb-fixed{padding-left:4px;margin-left:2px}
  .tb-fixed{gap:2px}
}

/* ───────── phone: bottom tab bar + create sheet ───────── */
.tabbar{display:none}
@media (max-width:760px){
  .tabbar{position:fixed;left:0;right:0;bottom:0;z-index:calc(var(--z-sticky) + 2);display:grid;grid-template-columns:repeat(5,1fr);align-items:center;height:calc(58px + env(safe-area-inset-bottom));padding:0 6px env(safe-area-inset-bottom);background:var(--sidebar);border-top:1px solid var(--line)}
  .tb-tab{position:relative;display:flex;flex-direction:column;align-items:center;gap:3px;padding:6px 0;color:var(--text-3);font:500 12px/1 var(--sans);text-decoration:none}
  .tb-tab[aria-current="page"]{color:var(--text-1)}
  .tb-tab[aria-current="page"] .ic{color:var(--fg-default)}
  .tb-tab-n{position:absolute;top:0;left:calc(50% + 6px);min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:var(--inv-bg);color:var(--inv-fg);font:600 12px/18px var(--sans);text-align:center;font-style:normal;box-shadow:0 0 0 2px var(--sidebar)}
  /* ink, never blue: + leads to New and Record, and the page keeps its own one blue primary */
  .tb-plus{justify-self:center;width:48px;height:48px;border-radius:16px;display:grid;place-items:center;background:var(--inv-bg);color:var(--fg-on-accent);box-shadow:var(--shadow-md)}
  .tb-plus:active{transform:scale(.95)}
  .has-tabbar .sh-main{padding-bottom:calc(64px + env(safe-area-inset-bottom))}
  .has-tabbar .toast-stack{bottom:calc(72px + env(safe-area-inset-bottom))}
  .phone-sheet{align-items:flex-end;padding:0}
  .phone-sheet .modal{max-width:none;width:100%;border-radius:20px 20px 0 0;max-height:86vh;padding-bottom:env(safe-area-inset-bottom)}
  .modal-wrap.sheet .modal{max-width:100%}
}
.pns{display:flex;flex-direction:column;gap:12px}
.pns-rec{display:flex;align-items:center;gap:14px;padding:16px;border-radius:14px;background:var(--rec);color:#fff;text-decoration:none}
.pns-rec b{display:block;font:600 17px/1.2 var(--sans)}
.pns-rec small{font-size:13px;opacity:.85}
.pns-rec>span:nth-child(2){flex:1}
.pns-dot{width:22px;height:22px;border-radius:50%;box-shadow:inset 0 0 0 3px #fff;display:grid;place-items:center}
.pns-dot::after{content:"";width:10px;height:10px;border-radius:50%;background:#fff}
.pns-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.pns-t{display:flex;flex-direction:column;align-items:center;gap:8px;padding:14px 6px;border-radius:12px;background:var(--surface-2);color:var(--text-1);text-decoration:none;text-align:center}
.pns-t b{font:500 13px/1.25 var(--sans)}
@media (max-width:760px){.tb-actions .tb-new,.tb-actions [data-act="new"]{display:none}}
/* phone: every dialog is a bottom sheet (like a native app) */
@media (max-width:760px){
  .modal-wrap:not(.sheet){align-items:flex-end!important;padding:0!important}
  .modal-wrap:not(.sheet) .modal{max-width:none!important;width:100%;border-radius:20px 20px 0 0;max-height:90vh;transform:translateY(24px);padding-bottom:env(safe-area-inset-bottom)}
  .modal-wrap.show:not(.sheet) .modal{transform:none}
  .modal-wrap:not(.sheet) .modal-head::before{content:"";position:absolute;left:50%;top:6px;width:36px;height:4px;margin-left:-18px;border-radius:2px;background:var(--line-3)}
  .modal-wrap:not(.sheet) .modal-head{position:relative;padding-top:18px}
  .modal-foot{flex-wrap:wrap}
  .ag{grid-template-columns:1fr;height:auto}
}
/* FINAL SHELL (Nov 22): New is the one blue create button; search sits beside it at the same height */
.tb .tb-ai{width:30px;height:30px;padding:0;color:var(--text-2);background:transparent}
.tb .tb-ai .ic{color:inherit}
.tb .tb-ai:hover,.tb .tb-ai[aria-pressed="true"]{background:var(--row-hover);color:var(--text-1)}
@media (min-width:761px){.tb-av{display:none}}
.tb-actions:not(:empty)+.tb-fixed{border-left:0;padding-left:0}
.rqc{display:flex;flex-direction:column;gap:8px}
.rqc-o{display:flex;align-items:center;gap:12px;padding:12px;border-radius:var(--r-card);background:var(--surface-2);text-align:left;color:var(--text-1);box-shadow:var(--btn-2-shadow)}
.rqc-o:hover{background:var(--surface-3)}
.rqc-o>span:nth-child(2){flex:1;display:flex;flex-direction:column;gap:3px}
.rqc-o b{font:600 14px/1.3 var(--sans)}
.rqc-o small{font-size:13px;line-height:1.45;color:var(--text-2)}
.sb-fav{margin-top:14px}
.sb-fav-h{padding:0 18px 4px;font:500 12px/1.6 var(--sans);color:var(--text-3)}
.sb-mini .sb-fav-h{display:none}
.cp-sub{margin-left:8px;font:400 12px/1 var(--sans);color:var(--text-3)}.cp-sub a{color:var(--text-2);text-decoration:underline;text-underline-offset:2px}
/* Ludoq logo in the sidebar (open: mark + name + workspace; closed: the mark alone) */
.sb-mark{display:grid;place-items:center;width:30px;height:30px;flex:none;margin-left:-4px}
.sb-brand{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px;line-height:1}
.sb-brand b{font:700 15px/1 'Sora','Inter',system-ui,sans-serif!important;letter-spacing:-.045em!important;color:var(--text-1)}
.sb-brand small{font:500 12px/1.1 var(--sans);color:var(--text-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb-ws{height:40px}
.sb-mini .sb-brand{opacity:0;pointer-events:none}
.sb-mini .sb-ws{padding:0;justify-content:center}
.sb-mini .sb-mark{margin:0}

/* ── Sidebar v3 (Nov 23, founder): the landing mock's look — neutral grey selection, ink text, grey line icons,
   a quiet white New button; logo centred when the sidebar is closed. ── */
/* sidebar selection (founder, Nov 24: restored): a soft grey filled pill, ink text, no shadow — the white raised pill is only for .seg/tabs */

.sb-link .glyph:not(.emo) { color: var(--text-2); }
.sb-link .glyph .ic { stroke-width: 1.9; }
/* closed: the mark sits exactly on the rail's centre line */
.sb-mini .sb-top { padding: 0; justify-content: center; }
.sb-mini .sb-ws { flex: 0 0 auto; width: 40px; height: 40px; margin: 0 auto; padding: 0; display: grid; place-items: center; }
.sb-mini .sb-ws > .ic, .sb-mini .sb-brand { display: none; }
.sb-mini .sb-mark { margin: 0; }

/* ── v8 (Nov 23) · one size system for the whole app ──
   row 32 · icon 16–18 · label 13 · controls (New, search, buttons) 32 · small tool buttons 28 */
:root { --ctl-h: 32px; --ctl-r: 8px; }
/* two groups: where you go · what you made */
.sb-work { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.sb-link > .glyph .ic { width: 17px; height: 17px; }
/* New: plain plus, no colour — the logo stays the only black mark up there */

/* Upgrade (Free / Creator): sidebar footer button → "Checkout opens on ludoq.app" sheet */
.cko{display:flex;flex-direction:column;gap:12px}
.cko-lead{display:flex;gap:8px;align-items:flex-start;font-size:13px;line-height:1.45;color:var(--text-2)}
.cko-lead>.ic{flex:none;margin-top:2px;color:var(--fg-default)}
.cko-plans{display:grid;gap:8px}
.cko-plan{display:grid;grid-template-columns:1fr auto;gap:2px 10px;align-items:baseline;padding:10px 12px;border-radius:var(--r-card);background:var(--surface-2);box-shadow:var(--ring);text-align:left;color:var(--text-1)}
.cko-plan b{font:600 14px/1.3 var(--sans)}
.cko-plan>span{font:600 14px/1 var(--sans)}
.cko-plan>span small{font-weight:400;font-size:12px;color:var(--text-3)}
.cko-plan>small{grid-column:1/-1;font-size:12px;color:var(--text-3)}
.cko-plan:hover{background:var(--surface-3)}
.cko-plan[aria-checked="true"]{box-shadow:inset 0 0 0 1.5px var(--fg-default);background:var(--accent-weak)}
.cko-sum{display:flex;flex-direction:column;gap:6px;margin:0;padding:10px 12px;border-radius:var(--r-card);background:var(--surface-2)}
.cko-sum>div{display:flex;justify-content:space-between;gap:12px;font-size:13px}
.cko-sum dt{color:var(--text-2)} .cko-sum dd{margin:0;font-weight:600;color:var(--text-1)}
/* copilot → full Ludoq AI hand-off */
.cp-handoff{margin:8px 0 10px}

/* ───────── One Ludoq AI (Nov 23): context chip, shared cards, trust tags, activity — panel, full screen, Settings, Studio, Watch ───────── */
.cp-ctxrow{display:flex;flex-wrap:wrap;gap:6px}
.cp-ctxrow[hidden]{display:none}
.ai-ctx{display:inline-flex;align-items:center;gap:5px;max-width:100%;height:22px;padding:0 3px 0 7px;border-radius:var(--r-full);background:var(--bg-muted);color:var(--fg-muted-on-fill);font:500 12px/1 var(--sans)}
.ai-ctx>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ai-ctx button{display:grid;place-items:center;width:16px;height:16px;border-radius:50%;color:inherit;opacity:.75}
.ai-ctx button:hover,.ai-ctx button:focus-visible{opacity:1;background:var(--accent-line);outline:none}
.ai-ctx.off{padding:0 8px 0 6px;background:transparent;color:var(--text-3);box-shadow:inset 0 0 0 1px var(--line-2)}
.ai-ctx.off:hover{color:var(--text-1)}
.ai-ctx-tag{display:flex;align-items:center;gap:4px;margin-bottom:4px;font:500 12px/1.2 var(--sans);color:var(--text-3)}
.cp-msg.old{animation:none}
.cp-more{display:inline-flex;align-items:center;gap:6px;align-self:center;font-size:12px;color:var(--text-3)}
.cp-more:hover{color:var(--text-1)}

.aic{display:flex;flex-direction:column;gap:8px;min-width:0;font-size:13px;line-height:1.5;color:var(--text-1)}
.aic.plan,.aic.pplan,.aic.ans,.aic.mem{border-radius:var(--r-card);background:var(--surface);box-shadow:var(--ring);padding:10px 12px}
.aic.discarded{opacity:.65}
.aic-h{display:flex;align-items:center;flex-wrap:wrap;gap:6px 8px;min-width:0}
.aic-h .badge{margin-left:auto}
.aic-h .meta{font-size:12px}
.aic-eye{display:inline-flex;align-items:center;gap:5px;font:600 12px/1 var(--sans);color:var(--text-2)}
.aic.text .aic-eye,.aic.studio .aic-eye{color:var(--text-3)}
.aic-sum{color:var(--text-1)}
.aic.text .aic-sum,.aic.studio .aic-sum{color:var(--text-2)}
.aic.fail .aic-sum{color:var(--text-2)}
.aic-sum a:not(.tchip),.ai-links a,.aic-meta a{color:var(--text-1);text-decoration:underline;text-decoration-color:var(--line-2);text-underline-offset:3px}
.aic-meta{font-size:12px;color:var(--text-3)}
.ai-src{display:inline-flex;align-items:center;gap:4px;min-width:0;max-width:100%;font-size:12px;color:var(--text-2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ai-src:hover{color:var(--text-1)}
.aic-foot{display:flex;align-items:center;flex-wrap:wrap;gap:6px;padding-top:8px;border-top:1px solid var(--line)}
.aic-foot .meta{margin-left:auto;font-size:12px;color:var(--text-3)}
.aic.ans .aic-foot,.aic.mem .aic-foot{border-top:0;padding-top:0}
.aic-phone{display:flex;align-items:flex-start;gap:6px;font-size:12px;line-height:1.4;color:var(--text-3)}
.aic-phone .ic{flex:none;margin-top:1px}
.ai-state{display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:500;color:var(--text-2)}
.ai-state.ok .ic{color:var(--pos)}
.ai-state.bad{color:var(--neg)}
.ai-trust{display:inline-flex;align-items:center;gap:4px;height:18px;padding:0 6px;border-radius:var(--r-full);background:var(--surface-3);color:var(--text-2);font:500 12px/1 var(--sans);white-space:nowrap}
.ai-trust.t-send{background:var(--accent-weak);color:var(--accent-text)}
.ai-trust.t-credits{background:var(--surface-3);color:var(--text-2)}
.ai-steps{list-style:none;display:flex;flex-direction:column;gap:10px;margin:2px 0 0;padding:0}
.ai-steps.simple{gap:6px}
.ai-step{display:flex;gap:10px;min-width:0}
.ai-step .n{width:18px;height:18px;margin-top:1px;border-radius:50%;flex:none;display:grid;place-items:center;background:var(--surface-3);color:var(--text-3);font:600 12px/1 var(--sans);transition:background var(--dur) var(--ease),color var(--dur) var(--ease)}
.ai-step.s-done .n{background:var(--fg-default);color:var(--on-accent)}
.ai-step.s-blocked .n,.ai-step.s-failed .n{background:var(--neg-weak);color:var(--neg)}
.ai-step.s-skipped,.ai-step.s-undone{opacity:.6}
.ai-sb{flex:1;min-width:0;display:flex;flex-direction:column;gap:5px}
.ai-steps.simple .ai-sb{gap:1px;font-size:13px;color:var(--text-2)}
.ai-sb>small{font-size:12px;line-height:1.45;color:var(--text-3)}
.ai-sl{display:flex;align-items:flex-start;flex-wrap:wrap;gap:4px 8px}
.ai-sl b{font-weight:600;font-size:13px;line-height:1.4}
.ai-items{list-style:none;display:flex;flex-direction:column;gap:4px;margin:0;padding:0}
.ai-items li{display:flex;align-items:center;gap:6px;min-width:0;font-size:13px;color:var(--text-2)}
.ai-items li>span:nth-child(2){flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ai-ref{flex:none;font:600 12px/1 var(--mono, ui-monospace, SFMono-Regular, Menlo, monospace);color:var(--text-3)}
.ai-mem-src{flex:none;height:18px;padding:0 6px;border-radius:4px;background:var(--surface-3);color:var(--text-3);font:500 12px/18px var(--sans)}
.aic .tchip{display:inline-flex;align-items:center;gap:3px;height:20px;padding:0 6px;border-radius:5px;background:var(--accent-weak);color:var(--accent-text);font:500 12px/1 var(--sans);text-decoration:none;vertical-align:1px;font-variant-numeric:tabular-nums;flex:none}
.ai-bul{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:2px;font-size:13px;color:var(--text-2)}
.ai-p{font-size:13px;color:var(--text-2)}
.ai-moments{display:grid;grid-template-columns:auto 1fr;align-items:center;gap:4px 8px}
.ai-mt{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:13px;color:var(--text-2)}
.ai-links{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:3px;font-size:13px}
.ai-links a{display:inline-flex;align-items:center;gap:6px}
.ai-res{display:flex;align-items:flex-start;gap:6px;font-size:13px;line-height:1.45;color:var(--text-2)}
.ai-res>span{flex:1;min-width:0}
.ai-res>a{flex:none}
.ai-res>.ic{flex:none;margin-top:2px;color:var(--pos)}
.ai-res.bad>.ic{color:var(--neg)}
.ai-res a{color:var(--accent-text);font-weight:500}
.ai-acts{display:flex;align-items:center;gap:6px}
.ai-pvw{display:flex;flex-direction:column;gap:6px}
.ai-pv-t{display:inline-flex;align-items:center;gap:4px;align-self:flex-start;font:500 12px/1.2 var(--sans);color:var(--text-2)}
.ai-pv-t:hover,.ai-pv-t:focus-visible{color:var(--text-1);outline:none}
.ai-pv{border-radius:8px;background:#EEEEEC;padding:8px;max-height:300px;overflow:auto;scrollbar-width:thin}
.ai-pv-in{width:600px}
.ai-pv-in>*{max-width:none}
.ai-pv-more{margin:8px 2px 0;font:12px/1.4 -apple-system,"Segoe UI",sans-serif;color:#57575A}
.ai-pv-big{display:inline-flex;align-items:center;gap:4px;align-self:flex-start;font-size:12px;color:var(--text-3)}
.ai-pv-big:hover{color:var(--text-1)}
.ai-remembered{display:inline-flex;align-items:center;gap:5px;align-self:flex-start;height:20px;padding:0 8px;border-radius:var(--r-full);background:var(--pos-weak);color:var(--pos);font:600 12px/1 var(--sans)}
.aic.mem.gone .ai-remembered{background:var(--surface-3);color:var(--text-3)}
.linkish{color:var(--text-1);text-decoration:underline;text-decoration-color:var(--line-2);text-underline-offset:3px;font-size:inherit}
.ai-act{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.ai-act-row{display:flex;align-items:center;gap:10px;min-height:44px;padding:8px 12px;border-top:1px solid var(--line)}
.ai-act-row:first-child{border-top:0}
.ai-act-row.undone .ai-act-t b{color:var(--text-3);text-decoration:line-through;text-decoration-color:var(--line-3, var(--line-2))}
.ai-act-ic{width:24px;height:24px;flex:none;display:grid;place-items:center;border-radius:6px;background:var(--surface-3);color:var(--text-2)}
.ai-act-ic.k-send{background:var(--accent-weak);color:var(--accent-text)}
.ai-act-ic.k-credits{background:var(--surface-3);color:var(--text-2)}
.ai-act-t{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.ai-act-t b{font-weight:500;font-size:13px;line-height:1.35;color:var(--text-1)}
.ai-act-t small{font-size:12px;color:var(--text-3)}
.ai-act-na{flex:none;font-size:12px;color:var(--text-4, var(--text-3))}
.ai-act-empty{padding:14px 12px;font-size:13px;color:var(--text-3)}
.ai-act-modal{display:flex;flex-direction:column;gap:10px}
.ai-act-modal .ai-act{max-height:56vh;overflow:auto;border-radius:var(--r-card);box-shadow:var(--ring)}
.ai-act-lead{font-size:13px;color:var(--text-2)}
.ai-act-foot{display:flex;justify-content:flex-end}
/* Watch › Ask tab: same agent */
.ai-continue-row{display:flex;align-items:center;gap:8px;padding:6px 2px 0}
.ai-continue-l{display:inline-flex;align-items:center;gap:5px;font:500 12px/1 var(--sans);color:var(--text-3)}
.ai-continue{display:inline-flex;align-items:center;gap:4px;margin-left:auto;font:500 12px/1 var(--sans);color:var(--accent-text)}
.ai-continue:hover{text-decoration:underline;text-underline-offset:3px}
.ai-continue:focus-visible{outline:none;box-shadow:var(--focus);border-radius:4px}

.cko-plan>small.cko-launch{color:var(--accent-text);font-weight:500}
.cko-seats{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 12px;border-radius:var(--r-card);background:var(--surface-2);font-size:13px;color:var(--text-1)}
.cko-seats > span{font-weight:600}
.cko-seats small{display:block;margin-top:2px;font-size:12px;font-weight:400;color:var(--text-3)}

/* ── Sidebar, Nov 24 (founder): logo row · workspace row (no switcher) · search field · no New button ── */
.sb-logo{margin-right:40px}
.sb-wsbox{flex:none;display:flex;flex-direction:column;gap:8px;padding:0 8px 12px}
.sb-wsrow{display:flex;align-items:center;gap:8px;height:32px;padding:0 8px;border-radius:8px;text-align:left;color:var(--text-1);transition:background var(--dur-fast) var(--ease)}
.sb-wsrow:hover,.sb-wsrow[aria-expanded="true"]{background:var(--row-hover)}
.sb-wsrow:focus-visible{outline:2px solid var(--btn-ring);outline-offset:-2px}
.sb-wsav{flex:none;width:20px;height:20px;border-radius:6px;display:grid;place-items:center;background:var(--inv-bg) center/cover no-repeat;color:#fff;font:600 12px/1 var(--sans)}
.sb-wsname{flex:1;min-width:0;font:550 13px/1.2 var(--sans);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb-wsplan{flex:none;font:500 12px/1 var(--sans);color:var(--text-2);padding:3px 6px;border-radius:6px;background:rgba(43,42,39,.06)}
/* sidebar search = the standard .search-field (styles.css), full width on the grey sidebar; it opens ⌘K */
.sb-mini .sb-wsbox{align-items:center;padding:0 8px 10px}
.sb-mini .sb-wsrow{width:40px;padding:0;justify-content:center}
.sb-mini .sb-search{flex:none;width:40px;min-width:0;padding:0}
.sb-mini .sb-search>.ic:first-child{left:11px}
.sb-mini .sb-wsname,.sb-mini .sb-wsplan,.sb-mini .sb-search .sf-ph,.sb-mini .sb-search .sf-key{display:none}
/* account menu: plan badge, sub-pages, Send feedback */
.acct-pop{width:272px}
.acct-pop .acct-h>div{flex:1;min-width:0}
.acct-pop .acct-h small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.acct-plan{flex:none;font:500 12px/1 var(--sans);color:var(--accent-text);background:var(--accent-weak);padding:4px 8px;border-radius:6px}
.acct-pop .menu-item .menu-hint .ic{color:var(--text-3)}
.acct-back{font-weight:600}
.acct-back>.ic{color:var(--text-3)}
.fb-dlg{display:flex;flex-direction:column;gap:12px}
.fb-dlg textarea{min-height:112px}
.fb-shot{display:flex;align-items:center;gap:8px;font-size:13px;color:var(--text-1);cursor:pointer}
.fb-note{margin:0;font-size:12px;line-height:16px;color:var(--text-3)}

/* ───────── Premium pass (Nov 25) — sidebar ─────────
   §8.3 selection: the current row is filled in place (no travelling pill); a click presses instantly; when the current
   row changes without a page load the new fill fades in (160 ms) while the old one fades out (120 ms). */
.sb-link[aria-current="page"]{background:var(--sb-active);box-shadow:none;color:var(--fg-default);font-weight:var(--fw-medium)}
.sb-link[aria-current="page"]>.glyph:not(.emo),.sb-link[aria-current="page"]>.ic{color:var(--sb-active-ic)}
.sb-link[aria-current="page"]:hover{background:var(--sb-active)}
.sb-link:active{background:var(--bg-pressed);transition-duration:var(--dur-instant)}
.sb-link.sb-in{animation:sbFillIn var(--dur) var(--ease) both}
.sb-link.sb-out{animation:sbFillOut var(--dur-fast) var(--ease-exit) both}
@keyframes sbFillIn{from{background-color:transparent}}
@keyframes sbFillOut{from{background-color:var(--sb-active)}to{background-color:transparent}}
@media (prefers-reduced-motion:reduce){.sb-link.sb-in,.sb-link.sb-out{animation:none}}
html.reduce-motion .sb-link.sb-in,html.reduce-motion .sb-link.sb-out{animation:none}

/* logo: 24px compact mark open, 20px on the rail (§8.4) */
.sb-mark{width:var(--h-28);height:var(--h-28);margin-left:calc(-1 * var(--space-2))}
.sb-mini .sb-mark .sl-logo{width:20px;height:20px}

/* workspace row + Invite (§12) */
.sb-wsline{display:flex;align-items:center;gap:var(--space-2)}
.sb-wsline .sb-wsrow{flex:1;min-width:0}
.sb-invite{color:var(--icon-muted)}
.sb-invite:hover{color:var(--icon-default)}
.sb-mini .sb-invite{display:none}
.sb-mini .sb-wsline{justify-content:center}

/* Starred (§8.2): projects + collections, one collapsible group under the rows */
.sb-star{margin-top:var(--space-16)}
.sb-star .sb-h-t{font:var(--type-caption-strong);color:var(--fg-muted)}
.sb-star .sb-h-t>span{flex:none}
.sb-viewall{color:var(--fg-muted)}
.sb-viewall .glyph{color:var(--icon-muted)}

/* Record (§12): pinned above the account row — white + red dot, a split chevron for the other kinds; never blue */
.sb-rec{display:flex;align-items:stretch;margin:var(--space-2) 0 var(--space-6)}
.sb-rec>.btn{height:var(--h-36)}   /* ds-allow: L13 — §12 sets the sidebar Record at 36 */
.sb-rec-main{flex:1;min-width:0;justify-content:flex-start;padding:0 var(--space-12);border-radius:var(--radius-control) 0 0 var(--radius-control)}   /* ds-allow: L13 — split button half */
.sb-rec-more{width:var(--h-36);padding:0;border-radius:0 var(--radius-control) var(--radius-control) 0;margin-left:var(--space-0);color:var(--icon-muted)}   /* ds-allow: L13 — split button half */
.sb-rec-more{translate:-1px 0}   /* the two hairlines overlap into one seam */
.sb-rec-more:hover{color:var(--icon-default)}
.sb-mini .sb-rec{justify-content:center}
.sb-mini .sb-rec-main{flex:none;width:var(--h-40);height:var(--h-40);padding:0;justify-content:center;border-radius:var(--radius-control)}   /* ds-allow: L13 — rail: the red-dot icon button */
.sb-mini .sb-rec-main .lbl{display:none}
.sb-mini .sb-rec-more{display:none}


/* account menu: trial status (Loom lessons REMOVE 1 — it left the sidebar footer) */
.acct-trial{display:grid;grid-template-columns:1fr 48px;align-items:center;gap:var(--space-4) var(--space-12);margin:0 var(--space-4) var(--space-6);padding:var(--space-8);border-radius:var(--radius-item);text-decoration:none;color:var(--fg-default);transition:background var(--dur-fast) var(--ease)}
.acct-trial:hover{background:var(--bg-row-hover);color:var(--fg-default)}
.acct-trial:focus-visible{outline:2px solid var(--focus-color);outline-offset:-2px}
.acct-trial-t{font:500 var(--fs-13)/20px var(--font-sans)}
.acct-trial-t b{font-weight:600}
.acct-trial .meter{width:48px;height:4px}
.acct-trial small{grid-column:1/-1;font:400 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
/* ink Record split (ORDER Nov 26 early): a hairline seam between Record and ▾ */
.sb-rec-more.solid{translate:none;border-left:1px solid var(--inv-line)}
.sb-rec-more.solid:hover{color:var(--inv-fg)}

/* Loom lessons §3.5: no trial or upgrade element on the watch page (trial status lives in the account menu and Plans & billing) */
body:has(#watch) .sb-upgrade,body:has(#watch) .sb-usage{display:none}
/* same on the full-screen work pages: the Studio editor and whiteboards */
.shell:is([data-page="editor"],[data-page="board"]) :is(.sb-upgrade,.sb-usage){display:none}

/* ───────── Notion lessons (Nov 26) — sidebar sections, More pane, Customize mode ─────────
   §1.2 conditional rows/sections grow in (height + fade on --spring-soft, then a one-time --bg-selected wash);
   §1.3 one ••• menu per section + the More pane; §1.5 Customize mode lives in the sidebar itself. Reduced motion: instant. */
.sb-grp{margin-top:var(--space-16)}
.sb-grp .sb-h-t{font:var(--type-caption-strong);color:var(--fg-muted)}
.sb-grp .sb-h-t>span{flex:none}
.sb-grp .sb-h-t{padding-right:var(--space-32)}
.sb-h-more{position:absolute;right:var(--space-2);top:var(--space-2);color:var(--icon-muted);opacity:0;transition:opacity var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}
.sb-h:hover .sb-h-more,.sb-h-more:focus-visible,.sb-h-more[aria-expanded="true"]{opacity:1}
.sb-h-more:hover,.sb-h-more[aria-expanded="true"]{color:var(--icon-default);background:var(--bg-pressed)}
@media (hover:none){.sb-h-more{opacity:1}}
.sb-mini .sb-h-more{display:none}
.sb-more-row{color:var(--fg-muted)}
.sb-more-row .glyph{display:inline-grid;place-items:center;width:18px;height:18px;color:var(--icon-muted)}
.sb-more-row .n{color:var(--fg-muted-on-fill)}
.sb-more-row[aria-expanded="true"]{background:var(--bg-hover)}

/* appear (a row or section that shows up without a reload) */
@keyframes sbRowIn{from{height:0;opacity:0}to{height:var(--row-h);opacity:1}}
@keyframes sbBodyIn{from{grid-template-rows:0fr;opacity:0}to{grid-template-rows:1fr;opacity:1}}
@keyframes sbHeadIn{from{opacity:0;height:0}to{opacity:1;height:26px}}
@keyframes sbWash{from{background-color:var(--bg-selected)}to{background-color:transparent}}
.sb-link.sb-appear{overflow:hidden;animation:sbRowIn var(--dur-spring) var(--spring-soft) both,sbWash calc(var(--dur-spring) * 2) var(--ease) var(--dur-spring) both}
.sb-sec.sb-appear>.sb-h{animation:sbHeadIn var(--dur-spring) var(--spring-soft) both;overflow:hidden}
.sb-sec.sb-appear>.sb-sec-body{animation:sbBodyIn var(--dur-spring) var(--spring-soft) both}
.sb-sec.sb-appear .sb-link:not([aria-current]){animation:sbWash calc(var(--dur-spring) * 2) var(--ease) var(--dur-spring) both}
.sb-sec.sb-leaving{transition:height var(--dur-slow) var(--ease-exit),opacity var(--dur-slow) var(--ease-exit),margin var(--dur-slow) var(--ease-exit);opacity:0;margin-top:0}
@media (prefers-reduced-motion:reduce){.sb-appear,.sb-appear>*,.sb-appear .sb-link{animation:none!important}.sb-sec.sb-leaving{transition:none}}
html.reduce-motion .sb-appear,html.reduce-motion .sb-appear>*,html.reduce-motion .sb-appear .sb-link{animation:none!important}
html.reduce-motion .sb-sec.sb-leaving{transition:none}

/* the shared section menu: "Show ›" / "Sort ›" open a second page in the same popover */
.sec-menu{width:240px}
.sec-menu .menu-item .menu-chev{width:14px;height:14px;margin-left:var(--space-2);color:var(--icon-muted)}
.sec-menu .menu-item[aria-haspopup] .menu-hint{margin-left:auto}

/* More pane — every starred item, anchored to the sidebar's right edge */
.more-pane{position:fixed;z-index:var(--z-palette);display:flex;flex-direction:column;gap:var(--space-8);max-height:min(480px,calc(100vh - 16px));padding:var(--space-12) var(--space-8) var(--space-8);border-radius:var(--radius-card);background:var(--bg-surface);box-shadow:var(--shadow-lg);
  opacity:0;transform:scale(.98);transform-origin:left top;transition:opacity var(--dur) var(--ease-out-quint),transform var(--dur-spring) var(--spring-soft)}
.more-pane.show{opacity:1;transform:none}
.more-pane.out{opacity:0;transform:scale(.98);transition:opacity var(--dur) var(--ease-exit),transform var(--dur) var(--ease-exit)}
.mp-h{display:flex;align-items:center;gap:var(--space-8);padding:0 var(--space-4)}
.mp-t{flex:1;min-width:0;font:600 var(--fs-13)/20px var(--font-sans);color:var(--fg-default)}
.mp-sort{width:auto;flex:none}
.mp-search{flex:none;margin:0 var(--space-4);width:auto}
.mp-list{flex:1 1 auto;min-height:0;overflow:auto;display:flex;flex-direction:column;gap:var(--space-2);padding:var(--space-2) 0}
.mp-row{position:relative;display:flex;align-items:center;border-radius:var(--radius-item)}
.mp-row:hover{background:var(--bg-hover)}
.mp-a{flex:1;min-width:0;display:flex;align-items:center;gap:var(--space-8);height:var(--row-h);padding:0 var(--space-8);border-radius:var(--radius-item);color:var(--fg-default);text-decoration:none;font:400 var(--fs-13)/20px var(--font-sans)}
.mp-a:focus-visible{outline:2px solid var(--focus-color);outline-offset:-2px}
.mp-n{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.mp-k{flex:none;margin-left:auto;font:400 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
.mp-star{flex:none;margin-right:var(--space-4);color:var(--icon-accent);opacity:0;transition:opacity var(--dur-fast) var(--ease)}
.mp-row:hover .mp-star,.mp-star:focus-visible{opacity:1}
.mp-row:hover .mp-k,.mp-row:focus-within .mp-k{margin-right:0}
@media (hover:none){.mp-star{opacity:1}}
.mp-empty{margin:0;padding:var(--space-12) var(--space-8);font:400 var(--fs-13)/20px var(--font-sans);color:var(--fg-muted)}
.mp-all{display:flex;align-items:center;gap:var(--space-4);height:var(--row-h);padding:0 var(--space-8);margin-top:var(--space-2);border-top:1px solid var(--border-subtle);font:500 var(--fs-13)/20px var(--font-sans);color:var(--fg-muted);text-decoration:none}
.mp-all:hover{color:var(--fg-default)}
.mp-all:focus-visible{outline:2px solid var(--focus-color);outline-offset:-2px;border-radius:var(--radius-item)}
@media (prefers-reduced-motion:reduce){.more-pane,.more-pane.out{transition:none}}
html.reduce-motion .more-pane,html.reduce-motion .more-pane.out{transition:none}

/* Customize sidebar — only Meetings, Collections and Starred switch off; rows never move; Done is the one blue */
.sb.cz-enter .sb-wsbox,.sb.cz-enter .sb-scroll,.sb.cz-enter .sb-foot{animation:czFade var(--dur) var(--ease) both}
@keyframes czFade{from{opacity:0}}
.cz-head{display:flex;flex-direction:column;gap:var(--space-2);min-height:var(--field-h);justify-content:center;padding:0 var(--space-8)}
.cz-head b{font:600 var(--fs-13)/20px var(--font-sans);color:var(--fg-default)}
.cz-head small{font:400 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
.sb-link.cz-row,.sb-link.cz-item{cursor:default}
.sb-link.cz-row:hover,.sb-link.cz-item:hover{background:transparent}
.sb-link.cz-row .switch{margin-left:auto}
.cz-off>.glyph,.cz-off>.lbl,.sb-sec.cz-off .sb-sec-body,.sb-sec.cz-off .cz-h-t{opacity:.5}
.cz-lock{margin-left:auto;display:inline-grid;place-items:center;width:24px;height:24px;color:var(--icon-muted)}
.cz-lock .ic{width:14px;height:14px}
.sb-h.cz-h{gap:var(--space-4);padding:0 var(--space-8)}
.cz-h-t{flex:1;min-width:0;font:var(--type-caption-strong);color:var(--fg-muted)}
.cz-h .switch,.cz-h .cz-lock{margin-left:auto}
.ib.cz-grip{flex:none;display:inline-grid;place-items:center;width:20px;height:24px;margin-left:calc(-1 * var(--space-4));border-radius:var(--radius-mark);color:var(--icon-muted);cursor:grab;transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease),transform var(--dur-spring-fast) var(--spring-snappy)}
.ib.cz-grip:hover{background:var(--bg-hover);color:var(--icon-default)}
.ib.cz-grip:focus-visible{outline:2px solid var(--focus-color);outline-offset:-2px}
.ib.cz-grip.lifted{background:var(--bg-selected);color:var(--icon-accent);transform:scale(1.08)}
.sb-link.cz-item{gap:var(--space-4)}
.sb-link.cz-item .glyph{margin-left:var(--space-2)}
.sb .dragging{opacity:.4}
.sb .drop-before,.sb .drop-after{position:relative}
.sb .drop-before::before,.sb .drop-after::after{content:"";position:absolute;left:var(--space-8);right:var(--space-8);height:2px;border-radius:1px;background:var(--accent);pointer-events:none;z-index:1}
.sb .drop-before::before{top:-1.5px}
.sb .drop-after::after{bottom:-1.5px}
.cz-sorted{margin:0;padding:var(--space-2) var(--space-8) var(--space-4);font:400 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
.cz-sorted .cz-change{display:inline-flex;height:20px;padding:0 var(--space-4);margin-left:var(--space-2);font:500 var(--fs-12)/16px var(--font-sans);color:var(--fg-default);vertical-align:baseline}
.cz-foot{display:flex;align-items:center;gap:var(--space-8);padding:var(--space-4) 0 var(--space-2)}
.cz-foot .btn.quiet{flex:none}
.cz-foot .btn.block{flex:1;width:auto}
@media (prefers-reduced-motion:reduce){.sb.cz-enter .sb-wsbox,.sb.cz-enter .sb-scroll,.sb.cz-enter .sb-foot{animation:none}.cz-grip{transition:none}}
html.reduce-motion .sb.cz-enter .sb-wsbox,html.reduce-motion .sb.cz-enter .sb-scroll,html.reduce-motion .sb.cz-enter .sb-foot{animation:none}

/* ⌘K: "Ask Ludoq: …" leads with the audio-lines mark in ink (calm spec §1) */
.cmdk-i .cmdk-ask-ic{display:inline-grid;place-items:center;width:20px;height:20px;flex:none;color:var(--fg-default)}
.cmdk-i.cmdk-ask .lbl{font-weight:500}

/* ?demo=start-with — the empty-state preview the dev toggle drops on top of a page */
.sw-demo{margin:var(--space-24) var(--space-32) 0;border:1px dashed var(--border-subtle);border-radius:var(--radius-card);padding:var(--space-32) var(--space-24)}
.sb.cz .switch:checked{background:var(--accent)}
.sb-link.cz-item:not(:has(.cz-grip)){gap:var(--space-8)}
.sb-link.cz-item:not(:has(.cz-grip)) .glyph{margin-left:-1px}

/* ───────── Spaces (Spaces decisions, Nov 26) — sidebar section, New space dialog, space popovers ─────────
   §2.3 a space row is 32: twisty slot 18 (emoji at rest, chevron on hover / focus / open, 90° on --spring-snappy) · name ·
   hover + and ⋯ (always visible on touch). Project rows are 30, indented 16 past the space label. One filled row (§2.4).
   §2.7 expand: rows below glide (flipSnap), children rise 6px with an 18ms stagger; collapse: animateOut then the gap closes.
   Reduced motion: everything is instant. */
.sb-spaces .sb-h-plus{right:var(--space-32);top:var(--space-2);color:var(--icon-muted)}
.sb-spaces .sb-h-plus:hover{color:var(--icon-default);background:var(--bg-pressed)}
@media (hover:none){.sb-spaces .sb-h-plus{opacity:1}}
.sb-mini .sb-spaces .sb-h-plus{display:none}
.sb-tree{gap:var(--space-2)}
.sb-srow,.sb-crow{position:relative;border-radius:var(--radius-item)}
.sb-link.sb-space{padding-right:var(--space-8)}
.sb-tslot{flex:none;width:19px;height:18px}
.sb-twisty{position:absolute;left:var(--space-6);top:var(--space-6);translate:1px 0;width:20px;height:20px;display:grid;place-items:center;border-radius:var(--radius-mark);color:var(--icon-muted);transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.sb-twisty[aria-expanded]{background:transparent}   /* open is shown by the chevron, not a fill */
.sb-twisty:hover{background:var(--bg-pressed);color:var(--icon-default)}
.sb-twisty:focus-visible{outline:2px solid var(--focus-color);outline-offset:-2px}
.sb-twisty>span{grid-area:1/1;display:grid;place-items:center;transition:opacity var(--dur-fast) var(--ease),transform var(--dur-spring-fast) var(--spring-snappy)}
.tw-emo{opacity:1}
.tw-chev{opacity:0}
.tw-chev .ic{width:14px;height:14px}
/* Spaces final §3.1: the emoji always shows at rest (open or not); the chevron replaces it only on hover / focus */
.sb-srow:is(:hover,:focus-within,.is-hover) .tw-emo{opacity:0}
.sb-srow:is(:hover,:focus-within,.is-hover) .tw-chev{opacity:1}
.sb-srow.open .tw-chev{transform:rotate(90deg)}
/* hover actions: + and ⋯ on spaces, ⋯ on projects */
.sb-sacts{position:absolute;right:var(--space-2);top:0;bottom:0;display:flex;align-items:center;gap:0;opacity:0;pointer-events:none;transition:opacity var(--dur-fast) var(--ease)}
.sb-srow:is(:hover,:focus-within,.is-hover) .sb-sacts,.sb-crow:is(:hover,:focus-within,.is-hover) .sb-sacts,.sb-sacts:has([aria-expanded="true"]){opacity:1;pointer-events:auto}
.sb-sact{width:24px;height:24px;border-radius:var(--radius-mark);color:var(--icon-muted)}
.sb-sact:hover,.sb-sact[aria-expanded="true"]{background:var(--bg-pressed);color:var(--icon-default)}
.sb-sact .ic{width:16px;height:16px}
.sb-srow:is(:hover,:focus-within,.is-hover) .sb-space{padding-right:var(--space-48)}
.sb-srow:is(:hover,:focus-within,.is-hover):has(.sb-sact+.sb-sact) .sb-space{padding-right:var(--space-64)}
.sb-crow:is(:hover,:focus-within,.is-hover) .sb-child{padding-right:var(--space-32)}
.sb-srow.is-hover .sb-space,.sb-crow.is-hover .sb-child{background:var(--bg-row-hover)}
@media (hover:none){.sb-sacts{opacity:1;pointer-events:auto}.sb-srow .sb-space{padding-right:var(--space-64)}.sb-crow .sb-child{padding-right:var(--space-32)}}
/* project rows under a space */
.sb-kids{display:flex;flex-direction:column;gap:var(--space-2)}
.sb-link.sb-child{height:30px;padding-left:var(--space-32)}
.sb-link.sb-child .glyph{width:16px;height:16px;font-size:var(--fs-14)}
.sb-link.sb-child .lbl{font:400 var(--fs-13)/18px var(--font-sans)}
.sb-priv{flex:none;display:inline-grid;place-items:center;color:var(--icon-muted)}
.sb-priv .ic{width:12px;height:12px}
.sb-link.sb-kmore{color:var(--fg-muted)}
.sb-link.sb-kmore .glyph{display:inline-grid;place-items:center;color:var(--icon-muted)}
.sb-kempty{margin:0;height:30px;display:flex;align-items:center;padding-left:var(--space-32);font:400 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
.sb-link.sb-space.cz-item .cz-lock{margin-left:auto}
/* rail: sections show their rows as icons only; the tree's children, actions and twisty step aside */
.sb-mini .sb-kids,.sb-mini .sb-sacts{display:none}
.sb-mini .sb-twisty{pointer-events:none}
.sb-mini .sb-srow .tw-emo{opacity:1}
.sb-mini .sb-srow .tw-chev{opacity:0}
/* phone drawer: 44px tap targets (DS §1.4.4) */
@media (max-width:760px){
  .sb-link.sb-space,.sb-link.sb-child,.sb-spaces .sb-more-row{height:44px}
  .sb-twisty{top:var(--space-12)}
  .sb-sact{width:36px;height:36px}
  .sb-sacts{opacity:1;pointer-events:auto}
  .sb-srow .sb-space{padding-right:var(--space-48)}
  .sb-crow .sb-sacts{display:none}.sb-crow .sb-child{padding-right:var(--space-8)}   /* touch: a project row is a plain link (its menu is on the project page) */
  .sb-srow .sb-sact[data-act="sp-new-proj"]{display:none}   /* touch: + lives on the Spaces header; a space row keeps ⋯ (it has "New project in …") */
}
@media (hover:none){.sb-crow .sb-sacts{display:none}.sb-crow .sb-child{padding-right:var(--space-8)}.sb-srow .sb-sact[data-act="sp-new-proj"]{display:none}.sb-srow .sb-space{padding-right:var(--space-48)}}
@media (prefers-reduced-motion:reduce){.sb-twisty>span,.sb-sacts{transition:none}}
html.reduce-motion .sb-twisty>span,html.reduce-motion .sb-sacts{transition:none}

/* access tag (sidebar tooltips, Browse rows, headers): icon + label, neutral */
.sp-acc .ic{width:12px;height:12px}

/* New space dialog (§5.2) — 560 wide, fits 1440×900 with a template picked, no inner scroll */
.spx{display:flex;flex-direction:column;gap:var(--space-16)}
.spx-l{display:block;font:var(--type-label-sm);color:var(--fg-default);margin-bottom:var(--space-6)}
.spx-chips{display:flex;flex-wrap:wrap;gap:var(--space-6)}
.spx-chip{height:28px;cursor:pointer;transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease),box-shadow var(--dur-fast) var(--ease)}
.spx-chip:hover{background:var(--bg-hover)}
.spx-chip[aria-checked="true"]{background:var(--bg-selected);color:var(--fg-default);box-shadow:inset 0 0 0 1px var(--accent-line-soft)}
.spx-chip:focus-visible{outline:2px solid var(--focus-color);outline-offset:1px}
.spx-chip-e{font:var(--fs-13)/1 var(--font-emoji)}
.spx-help{margin:var(--space-6) 0 0;min-height:16px;font:var(--type-caption);color:var(--fg-muted);transition:opacity var(--dur) var(--ease)}
.spx-help.out{opacity:0}
.spx-id{display:grid;grid-template-columns:48px minmax(0,1fr) minmax(0,1.3fr);gap:var(--space-12);align-items:start}
.spx-icon{width:48px;height:48px;margin-top:var(--space-24);border-radius:var(--radius-control);cursor:pointer;transition:transform var(--dur-spring-fast) var(--spring-snappy)}
.spx-icon:hover{transform:scale(1.04)}
.spx-icon:focus-visible{outline:2px solid var(--focus-color);outline-offset:2px}
.spx-err{margin:0}
.spx-access{border:0;margin:0;padding:0;display:flex;flex-direction:column;gap:var(--space-2)}
.spx-acc{display:grid;grid-template-columns:18px 16px 64px minmax(0,1fr);align-items:center;gap:var(--space-8);min-height:var(--h-32);padding:var(--space-4) var(--space-8);border-radius:var(--radius-item);cursor:pointer;transition:background var(--dur-fast) var(--ease)}
.spx-acc:hover{background:var(--bg-hover)}
.spx-acc:has(:checked){background:var(--bg-selected)}
.spx-acc.is-disabled{opacity:.5;cursor:not-allowed}
.spx-acc-ic{display:inline-grid;place-items:center;color:var(--icon-muted)}
.spx-acc:has(:checked) .spx-acc-ic{color:var(--fg-default)}
.spx-acc b{font:var(--type-label-sm);color:var(--fg-default)}
.spx-acc small{font:var(--type-caption);color:var(--fg-muted);min-width:0}
.spx-people{position:relative}
.spx-pbox{display:flex;flex-wrap:wrap;align-items:center;gap:var(--space-4);min-height:var(--h-36);padding:var(--space-2) var(--space-8);border:1px solid var(--border-field);border-radius:var(--radius-control);background:var(--bg-surface);cursor:text;transition:border-color var(--dur-fast) var(--ease),box-shadow var(--dur-fast) var(--ease)}
.spx-pbox:focus-within{border-color:var(--border-accent);box-shadow:var(--focus-halo)}
.spx-pchips{display:contents}
.spx-pc-chip{gap:var(--space-4);padding-left:var(--space-2)}
.spx-pc-chip .av{flex:none}
.spx-pin{flex:1;min-width:160px;height:28px;border:0;background:transparent;font:var(--type-body-sm);color:var(--fg-default)}
.spx-pin:focus{outline:none;border-color:var(--border-accent)}   /* the box around it carries the focus ring */
.spx-pin::placeholder{color:var(--fg-placeholder)}
.spx-plist{display:flex;flex-direction:column;max-width:calc(100vw - 32px);padding:var(--space-4)}
.spx-opt[aria-selected="true"]{background:var(--bg-hover)}
.spx-none{margin:0;padding:var(--space-8);font:var(--type-body-sm);color:var(--fg-muted)}
.spx-sugg{display:flex;flex-wrap:wrap;align-items:center;gap:var(--space-6);margin:var(--space-6) 0 0;font:var(--type-caption);color:var(--fg-muted)}
.spx-sg{cursor:pointer;gap:var(--space-4);padding-left:var(--space-2)}
.spx-sg:hover{background:var(--bg-hover)}
.spx-phint{margin:var(--space-6) 0 0;font:var(--type-caption);color:var(--fg-muted)}
.spx-pgrid{display:grid;grid-template-columns:1fr 1fr;gap:var(--space-2) var(--space-12)}
.spx-p{display:flex;align-items:center;gap:var(--space-8);height:var(--h-32);padding:0 var(--space-4);border-radius:var(--radius-item);cursor:pointer;font:var(--type-body-sm);color:var(--fg-default)}
.spx-p:hover{background:var(--bg-hover)}
.spx-p-e{font:var(--fs-15)/1 var(--font-emoji)}
.spx-p-n{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.spx-need{display:flex;align-items:center;gap:var(--space-8);margin:var(--space-8) 0 0;padding:var(--space-6) var(--space-8);border-radius:var(--radius-item);background:var(--bg-subtle);font:var(--type-caption);color:var(--fg-muted)}
.spx-need>span{flex:1;min-width:0}
.spx-need .ic{flex:none;color:var(--icon-muted)}
.spx .modal-foot{padding-top:var(--space-4)}
@media (max-width:760px){.spx-id{grid-template-columns:48px minmax(0,1fr)}.spx-desc{grid-column:1/-1}.spx-acc{grid-template-columns:18px 16px minmax(0,1fr)}.spx-acc small{grid-column:3}.spx-pgrid{grid-template-columns:1fr}}

/* emoji + colour picker for a space */
.sp-look{display:flex;flex-direction:column;gap:var(--space-10);width:288px;padding:var(--space-12)}
.sp-look .space-emoji button:hover{background:var(--bg-hover)}
.sp-look .space-emoji button[aria-pressed="true"]{background:var(--bg-selected)}

/* access popover (§6.2), Add people (§6.5), Move to space (§7.3) */
.sp-accpop{display:flex;flex-direction:column;gap:var(--space-2);width:320px;padding:var(--space-4)}
.sp-accrow{height:auto;align-items:flex-start;padding:var(--space-8);white-space:normal}
.sp-accrow>.ic{margin-top:var(--space-2);flex:none}
.sp-accrow-t{flex:1;min-width:0;display:flex;flex-direction:column;gap:var(--space-2);text-align:left}
.sp-accrow-t b{font:var(--type-label-sm);color:var(--fg-default)}
.sp-accrow-t small{font:var(--type-caption);color:var(--fg-muted)}
.sp-add{display:flex;flex-direction:column;gap:var(--space-8);width:320px;padding:var(--space-8)}
.sp-add-list{display:flex;flex-direction:column;max-height:264px;overflow:auto;margin:0 calc(-1 * var(--space-4))}
.sp-add-row{display:flex;align-items:center;gap:var(--space-8);min-height:var(--h-40);padding:var(--space-4) var(--space-8);border-radius:var(--radius-item);cursor:pointer}
.sp-add-row:hover{background:var(--bg-hover)}
.sp-add-row[aria-selected="true"]{background:var(--bg-selected)}
.sp-add-t{flex:1;min-width:0;display:flex;flex-direction:column}
.sp-add-t b{font:var(--type-label-sm);color:var(--fg-default);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sp-add-t small{font:var(--type-caption);color:var(--fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sp-add-none{margin:0;padding:var(--space-12) var(--space-8);font:var(--type-body-sm);color:var(--fg-muted)}
.sp-add-foot{display:flex;align-items:center;gap:var(--space-8);padding-top:var(--space-8);border-top:1px solid var(--border-subtle)}
.sp-move{display:flex;flex-direction:column;gap:var(--space-8);width:300px;padding:var(--space-8)}
.sp-move-t{padding:0 var(--space-4);font:var(--type-title-sm);color:var(--fg-default);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sp-move-list{max-height:280px;overflow:auto;padding:0;box-shadow:none;background:transparent}
.sp-confirm-b{margin:0;font:var(--type-body);color:var(--fg-muted)}

/* invite sheet: Everyone at {ws} is a fixed chip */
.sp-tog.sp-fixed{color:var(--fg-muted);cursor:default}
.sp-tog.sp-fixed .ic{width:12px;height:12px;color:var(--icon-muted)}
/* popovers opened from inside a dialog (people matches, the icon picker) sit above it */
.spx-plist-pop,.sp-look-pop{z-index:var(--z-palette)}   /* modal 500 < this 520 < toast 600 */

/* ───────── Spaces IA v2 (Nov 26) — Spaces / Projects header row, helper rows, rail slot, "Where should it go?", tip ─────────
   §2.2 the structure header is a real 32px nav row: the only section with a rule above it (12 above, 8 below — the Inbox |
   My Library rule), layers / projects 16 in --icon-default, "Spaces" 600 14/20 ink. The link is stretched over the row, so the
   whole row hovers, presses and takes the one selected fill; the twisty, + (at rest) and ⋯ come later in the DOM and
   are positioned, so they paint above the stretched link without a z-index.
   Levels read header 600/14 › space 500/13 › project 400/13. Reduced motion: the twisty turns instantly. */
.sb-sec.sb-struct{margin-top:var(--space-12);padding-top:var(--space-8);border-top:1px solid var(--border-subtle)}
.sb-h.sb-h-nav{height:var(--row-h);margin-bottom:var(--space-2);border-radius:var(--radius-item);transition:background var(--dur-fast) var(--ease)}
.sb-h-nav:hover{background:var(--bg-row-hover)}
.sb-h-nav:has(>.sb-h-link:active){background:var(--bg-pressed);transition:none}
.sb-h-nav:has(>.sb-h-link[aria-current="page"]){background:var(--sb-active);box-shadow:none}
.sb-link.sb-h-link{position:static;flex:0 1 auto;width:auto;min-width:0;height:100%;padding:0 var(--space-4) 0 var(--space-8);background:transparent;box-shadow:none;color:var(--fg-default)}
.sb-link.sb-h-link:hover,.sb-link.sb-h-link:active,.sb-link.sb-h-link[aria-current="page"]{background:transparent;box-shadow:none}
.sb-link.sb-h-link::after{content:"";position:absolute;inset:0;border-radius:var(--radius-item)}
.sb-link.sb-h-link:focus-visible{outline:var(--focus-width) solid transparent}   /* the ring is drawn on the whole row (forced colors keep the outline) */
.sb-link.sb-h-link:focus-visible::after{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
.sb-link.sb-h-link .lbl{flex:0 1 auto;font:var(--type-title-sm);color:var(--fg-default)}
.sb .sb-link.sb-h-link>.glyph:not(.emo){color:var(--icon-default)}
.sb-h-twisty{position:relative;flex:none;width:20px;height:20px;display:grid;place-items:center;border-radius:var(--radius-mark);color:var(--icon-muted);opacity:0;transition:opacity var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.sb-h-twisty .ic{width:12px;height:12px;transition:transform var(--dur-spring-fast) var(--spring-snappy)}
.sb-h-nav:hover .sb-h-twisty,.sb-h-nav:focus-within .sb-h-twisty,.sb-sec.closed .sb-h-twisty{opacity:1}
.sb-sec.closed .sb-h-twisty .ic{transform:rotate(-90deg)}
.sb-h-twisty[aria-expanded]{background:transparent}   /* open / closed is shown by the chevron, not a fill */
.sb-h-twisty:hover,.sb-h-twisty[aria-expanded]:hover{background:var(--bg-pressed);color:var(--icon-default)}
.sb-h-twisty:focus-visible{outline:2px solid var(--focus-color);outline-offset:-2px}
.sb-h-acts{position:relative;flex:none;margin-left:auto;display:flex;align-items:center;padding-right:var(--space-2)}
.sb-h-nav .sb-h-plus,.sb-h-nav .sb-h-more{position:static;width:24px;height:24px;border-radius:var(--radius-mark);color:var(--icon-muted)}
.sb-h-nav .sb-h-plus{opacity:1}
.sb-h-nav .sb-h-plus:hover,.sb-h-nav .sb-h-more:hover,.sb-h-nav .sb-h-more[aria-expanded="true"]{color:var(--icon-default);background:var(--bg-pressed)}
.sb-h-nav .sb-h-more{opacity:0}
.sb-h-nav:hover .sb-h-more,.sb-h-nav:focus-within .sb-h-more,.sb-h-nav .sb-h-more[aria-expanded="true"]{opacity:1}
@media (hover:none){.sb-h-nav .sb-h-more,.sb-h-twisty{opacity:1}}
/* space rows one weight up (500), project rows stay 400 */
.sb-link.sb-space .lbl{font:var(--type-label-sm);color:var(--fg-default)}
/* helper rows (§2.3): "Add a team space" · "New project" — muted label, plus 16 in --icon-muted */
.sb-link.sb-add{color:var(--fg-muted)}
.sb-link.sb-add .glyph{display:inline-grid;place-items:center;width:18px;height:18px;color:var(--icon-muted)}
.sb-link.sb-add:hover{color:var(--fg-default)}
.sb-link.sb-add:hover .glyph{color:var(--icon-default)}
.sb-link.sb-child.sb-add .glyph{width:16px;height:16px}
/* rail: the structure gets one icon button where the Projects row used to be; sections keep their hairline */
.sb-rail-slot{display:none}
.sb-mini .sb-rail-slot{display:block}
.sb-mini .sb-sec.sb-struct{border-top:0;padding-top:0}
.sb-mini .sb-h.sb-h-nav{height:26px;background:transparent;box-shadow:none}
.sb-mini .sb-h-nav>*{display:none}
.sb-mini .sb-add{display:none}
/* phone drawer: 44px tap targets, actions always visible */
@media (max-width:760px){
  .sb-h.sb-h-nav,.sb-link.sb-add,.sb-spaces .sb-link.sb-child.sb-add,.sb-projects .sb-more-row{height:44px}
  .sb-h-nav .sb-h-more,.sb-h-twisty{opacity:1}
  .sb-h-nav .sb-h-plus,.sb-h-nav .sb-h-more{width:36px;height:36px}
}
@media (prefers-reduced-motion:reduce){.sb-h-twisty .ic,.sb-h-nav{transition:none}}
html.reduce-motion .sb-h-twisty .ic,html.reduce-motion .sb-h-nav{transition:none}

/* "Where should it go?" (§6.4): My Library first (selected, Enter accepts), then projects under space headings */
.pp-where{gap:var(--space-8)}
.pp-where [role="option"][aria-selected="true"]{background:var(--bg-selected)}
.pp-where [role="option"][aria-selected="true"]:focus-visible{background:var(--bg-selected)}
.pp-search{flex:none;width:auto}
.pp-grp{display:flex;flex-direction:column;gap:var(--space-2)}
.pp-grp+.pp-grp{margin-top:var(--space-8)}
.pp-h{display:flex;align-items:center;gap:var(--space-6);margin:0;padding:var(--space-4) var(--space-8) var(--space-2);font:600 var(--fs-13)/20px var(--font-sans);color:var(--fg-default)}
.pp-h .glyph{width:16px;height:16px}
.pp-none{margin:0;padding:var(--space-12) var(--space-8);font:400 var(--fs-13)/20px var(--font-sans);color:var(--fg-muted)}

/* one-time tip (§11.4): a .pop beside the Spaces / Projects header; rises 6px on --spring-soft, leaves with a 160ms fade */
@keyframes ia2In{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
.pop.ia2-tip{position:fixed;width:320px;max-width:calc(100vw - 16px);padding:var(--space-16);display:flex;flex-direction:column;gap:var(--space-4);opacity:1;transform:none;animation:ia2In var(--dur-spring) var(--spring-soft) both}
.pop.ia2-tip.out{opacity:0;transform:none;animation:none;transition:opacity var(--dur) var(--ease-exit)}
.ia2-t{font:var(--type-title-sm);color:var(--fg-default)}
.ia2-b{margin:0;font:var(--type-body-sm);color:var(--fg-muted)}
.ia2-f{display:flex;justify-content:flex-end;margin-top:var(--space-8)}
@media (prefers-reduced-motion:reduce){.pop.ia2-tip,.pop.ia2-tip.out{animation:none;transition:none}}
html.reduce-motion .pop.ia2-tip,html.reduce-motion .pop.ia2-tip.out{animation:none;transition:none}

/* Spaces IA v2 §2.5 / SD §2: sections don't render in the rail — only the Spaces (Pro: Projects) entry in .sb-rail-slot */
.sb-mini .sb-sec{display:none}

/* ───────── Spaces final decisions (Nov 26) — account row, Pinned / Starred under Spaces, Customize lock, tip ─────────
   The bin left the account row on Nov 26 (Notion-style sidebar: Trash lives per place). */
.sb-acctrow{display:flex;align-items:center;gap:var(--space-4);min-width:0}
.sb-acctrow>.sb-acct{flex:1;min-width:0;width:auto}
/* §3.1 Pinned and Starred sit under the Spaces tree: 16 above each instead of a rule (only Spaces has the rule) */
.sb-sec.sb-pinned,.sb-sec.sb-starred{margin-top:var(--space-16)}
/* §3.3 Customize: the Spaces header has no grip — "Always first" lock only */
.sb-h.cz-h.cz-h-locked{padding-left:var(--space-8)}
/* §11.4 the Business tip sits beside the sidebar, level with the bin (Record ▾ stays clear); a small arrow points at the bin */
.pop.ia2-tip.ia2-tip-side{transform-origin:left bottom}
.pop.ia2-tip.ia2-tip-side::before{content:"";position:absolute;left:-5px;top:calc(var(--tip-y, 50%) - 4px);width:8px;height:8px;background:var(--elevated);border-left:1px solid var(--sb-line);border-bottom:1px solid var(--sb-line);transform:rotate(45deg)}   /* ds-allow: L4 — the arrow's half-size offsets */

/* ───────── Notion-style sidebar (founder, Nov 26 — applied from the approved mock) ─────────
   Top row: [macOS lights, desktop app only] · Ludoq logo · ◧ close · … · Inbox with its count (the only icon on the right).
   Workspace row N Northwind ⌄ · plan · ✎ New. A Notion "Search" row (⌘K on hover), quick rows, light-grey 12px section labels
   (fg-muted on the sidebar = 4.8:1) that fold their section, ••• and + on hover. Record ▾ + account row (name · Settings · Help).
   Closed (◧ / ⌘\): the column springs to 0 and the sidebar becomes a floating peek panel (hover ◧ or the left edge).
   Rows 30 / 500 14/20 in a soft ink; icons neutral-650; the current row is the one grey fill (no blue). Reduced motion: instant. */
.sb{--nsb-ink:color-mix(in srgb,var(--fg-default) 78%,var(--bg-sidebar));--nsb-icon:var(--sb-icon);--nsb-label:var(--fg-muted);background:var(--bg-sidebar);border-right-color:var(--border-subtle)}
:root[data-theme="dark"] .sb{--nsb-icon:var(--icon-muted)}

/* top row — same height as the title bar */
.sb .sb-top{display:flex;align-items:center;gap:var(--space-2);height:var(--tb-h);padding:0 var(--space-10) 0 var(--space-12)}
.sb-lights{display:inline-flex;gap:var(--space-8);margin:0 var(--space-12) 0 var(--space-4);flex:none}
.sb-lights i{width:12px;height:12px;border-radius:50%;box-shadow:inset 0 0 0 .5px rgba(0,0,0,.14)}   /* ds-allow: L1 · ds-allow: L3 · ds-allow: L5b — macOS window chrome, not brand colour */
.sb-lights .l-r{background:#FF5F57}.sb-lights .l-y{background:#FEBC2E}.sb-lights .l-g{background:#28C840}   /* ds-allow: L1 · ds-allow: L17 — macOS traffic lights (desktop app only), not brand colour */
.sb .sb-top .sb-logo{flex:none;margin:0;height:28px;padding:0 var(--space-6) 0 var(--space-4);gap:var(--space-6);border-radius:var(--radius-chip)}
.sb .sb-top .sb-logo:hover{background:var(--bg-row-hover)}
.sb .sb-top .sb-mark{width:20px;height:20px;margin:0;display:grid;place-items:center}
.sb .sb-top .sb-mark .sl-logo{width:20px;height:20px}
.sb .sb-top .sb-brand b{font:600 var(--fs-14)/20px var(--font-sans);letter-spacing:-.01em;color:var(--fg-default)}
.sb-flex{flex:1}
.ib.sb-ib{position:relative;flex:none;width:28px;height:28px;padding:0;display:inline-grid;place-items:center;border-radius:var(--radius-chip);color:var(--nsb-icon);background:transparent;transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.ib.sb-ib .ic{width:18px;height:18px}
.ib.sb-ib:hover,.ib.sb-ib[aria-expanded="true"]{background:var(--bg-row-hover);color:var(--icon-default)}
.ib.sb-ib:active{background:var(--bg-pressed);transition:none}
.ib.sb-ib[aria-current="page"]{background:var(--sb-active);color:var(--icon-default)}
.ib.sb-ib:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
.sb-badge{position:absolute;top:-1px;right:-7px;min-width:18px;height:16px;padding:0 var(--space-4);border-radius:var(--radius-full);background:var(--inv-bg);color:var(--inv-fg);font:600 var(--fs-12)/16px var(--font-sans);text-align:center;box-shadow:0 0 0 2px var(--bg-sidebar);pointer-events:none}   /* counts are ink: blue is Apply's (Ludoq positioning) */   /* ds-allow: L4 · ds-allow: L5b — the count bubble overhangs the icon and knocks out its ring, like Notion */
.sb-badge[hidden]{display:none}

/* workspace row: N Northwind ⌄ · Business · ✎ */
.sb .sb-wsbox{gap:0;padding:var(--space-2) var(--space-10) var(--space-6) var(--space-8)}
.sb .sb-wsline{gap:var(--space-4)}
.sb .sb-wsline .sb-wsrow{flex:0 1 auto;min-width:0;height:32px;padding:0 var(--space-6);gap:var(--space-8);border-radius:var(--radius-chip)}
.sb .sb-wsrow:hover,.sb .sb-wsrow[aria-expanded="true"]{background:var(--bg-row-hover)}
.sb .sb-wsav{width:22px;height:22px;border-radius:var(--radius-chip)}
.sb .sb-wsname{flex:0 1 auto;font:600 var(--fs-14)/20px var(--font-sans);color:var(--fg-default)}
.sb-wschev{flex:none;color:var(--nsb-icon)}
.sb .sb-wsplan{flex:none;margin-right:auto;padding:0 0 0 var(--space-2);background:none;font:500 var(--fs-12)/16px var(--font-sans);color:var(--nsb-label);white-space:nowrap}

/* rows */
.sb .sb-scroll{padding:0 var(--space-8) var(--space-12)}
.sb .sb-nav.sb-primary{gap:1px;padding-bottom:0}   /* ds-allow: L4 — Notion's 1px row gap. No bottom pad (founder Nov 27): Spaces sits at the same 31px step as the rows above it; each section label gets the one 14px gap from its own margin */
.sb .sb-nav{gap:1px}   /* ds-allow: L4 — Notion's 1px row gap */
.sb .sb-link{height:30px;gap:var(--space-8);padding:0 var(--space-8);border-radius:var(--radius-chip);font:500 var(--fs-14)/20px var(--font-sans);color:var(--nsb-ink)}
.sb .sb-link .lbl{font:inherit;color:inherit}
.sb .sb-link:hover{background:var(--ctl-ghost-hover);color:var(--nsb-ink)}
.sb .sb-link:active{background:var(--bg-pressed)}
.sb .sb-link[aria-current="page"],.sb .sb-link[aria-current="page"]:hover{background:var(--sb-active);color:var(--fg-default);font-weight:500}
.sb .sb-link>.glyph{flex:none;width:20px;height:20px;display:grid;place-items:center;margin:0}
.sb .glyph:not(.emo),.sb .sb-link.sb-search>.glyph{color:var(--nsb-icon)}
.sb .sb-link[aria-current="page"]>.glyph:not(.emo){color:var(--fg-default)}
.sb .glyph .ic{width:18px;height:18px}
.sb .glyph.emo{font:var(--fs-15)/1 var(--font-emoji)}
.sb .sb-k{margin-left:auto;font:500 var(--fs-12)/16px var(--font-sans);color:var(--nsb-label);opacity:0;transition:opacity var(--dur-fast) var(--ease)}
.sb .sb-search:hover .sb-k,.sb .sb-search:focus-visible .sb-k{opacity:1}
/* spaces tree at the row size */
.sb .sb-link.sb-space .lbl,.sb .sb-link.sb-child .lbl{font:500 var(--fs-14)/20px var(--font-sans);color:inherit}
.sb .sb-link.sb-child{height:30px;padding-left:30px}   /* ds-allow: L4 — mock child indent */
.sb .sb-link.sb-child .glyph{width:20px;height:20px;font-size:var(--fs-15)}
.sb .sb-tslot{width:20px;height:20px}
.sb .sb-twisty{top:5px;left:var(--space-8);translate:none}   /* ds-allow: L4 — centres the 20px twisty on the 30px row */
.sb .sb-kempty{height:28px;padding-left:38px}   /* ds-allow: L4 — lines up with the child labels */
.sb .sb-srow:is(:hover,.is-hover)>.sb-space,.sb .sb-crow:is(:hover,.is-hover)>.sb-child{background:var(--bg-row-hover)}
.sb .sb-srow>.sb-space[aria-current="page"],.sb .sb-crow>.sb-child[aria-current="page"]{background:var(--sb-active)}
.sb .sb-sact:hover,.sb .sb-sact[aria-expanded="true"]{background:var(--bg-pressed)}

/* section labels — Spaces / Pinned / Starred */
.sb .sb-sec,.sb .sb-sec.sb-struct,.sb .sb-sec.sb-grp,.sb .sb-sec.sb-pinned,.sb .sb-sec.sb-starred{margin-top:var(--space-14);padding-top:0;border-top:0}
.sb .sb-h.sb-h-lab{position:relative;height:28px;margin:0;padding:0;border-radius:var(--radius-chip)}
.sb .sb-h-lab .sb-h-t{flex:1;height:28px;padding:0 var(--space-64) 0 var(--space-8);gap:var(--space-4);background:none;border-radius:var(--radius-chip);font:500 var(--fs-12)/28px var(--font-sans);letter-spacing:.01em;color:var(--nsb-label);transition:color var(--dur-fast) var(--ease)}
.sb .sb-h-lab .sb-h-t:hover,.sb .sb-h-lab:hover .sb-h-t,.sb .sb-h-lab.is-on .sb-h-t{background:none;color:var(--fg-default)}
.sb .sb-h-lab .sb-h-t:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1);box-shadow:none}
.sb .sb-h-lab .sb-h-t .ic,.sb .sb-h-lab:hover .sb-h-t .ic{width:12px;height:12px;opacity:0}
.sb .sb-sec.closed .sb-h-lab .sb-h-t .ic{opacity:1;transform:rotate(-90deg)}
.sb .sb-h-lab .sb-h-acts{position:absolute;right:var(--space-4);top:var(--space-2);margin:0;padding:0;display:flex;align-items:center;gap:0;opacity:0;transition:opacity var(--dur-fast) var(--ease)}
.sb .sb-h-lab:is(:hover,:focus-within,.is-hover) .sb-h-acts,.sb .sb-h-lab .sb-h-acts:has([aria-expanded="true"]){opacity:1}
.sb .sb-h-lab .sb-h-more,.sb .sb-h-lab .sb-h-plus{position:static;width:24px;height:24px;opacity:1;border-radius:var(--radius-mark);color:var(--nsb-icon);background:transparent}
.sb .sb-h-lab .sb-h-more:hover,.sb .sb-h-lab .sb-h-plus:hover,.sb .sb-h-lab .sb-h-more[aria-expanded="true"]{background:var(--bg-pressed);color:var(--icon-default)}
@media (hover:none){.sb .sb-h-lab .sb-h-acts{opacity:1}}

/* bottom: Record ▾ + account row */
.sb .sb-foot{gap:0;padding:var(--space-8) var(--space-10) var(--space-10);border-top:0;background:var(--bg-sidebar)}
.sb .sb-rec{margin:var(--space-2) 0 var(--space-8)}
.sb .sb-acctrow{gap:var(--space-2)}
.sb .sb-acctrow>.sb-acct{height:32px;padding:0 var(--space-6);gap:var(--space-8);border-radius:var(--radius-chip)}
.sb .sb-acct:hover,.sb .sb-acct[aria-expanded="true"]{background:var(--bg-row-hover)}
.sb .sb-acct .who{flex-direction:row;align-items:center}
.sb .sb-acct b{font:500 var(--fs-14)/20px var(--font-sans);color:var(--nsb-ink)}
.sb .sb-acct[data-trial] .av{box-shadow:0 0 0 2px var(--bg-sidebar),0 0 0 3.5px var(--accent-line-soft, var(--accent))}   /* ds-allow: L5b — the quiet trial ring on the avatar */

/* closed: full hide + peek panel (desktop widths; the phone keeps its drawer) */
.sb-peekbar,.sb-edge,.tb-sbctl{display:none}
.tb-sbctl .sb-expand{display:inline-flex}
.tb-sbctl .sb-lights{margin:0 var(--space-12) 0 var(--space-4)}
@media (min-width:761px){
  .shell>.sb{grid-column:1;grid-row:1}
  .shell>.sh-main{grid-column:2;grid-row:1}
  .shell>.cp{grid-column:3;grid-row:1}
  .shell.sb-hidden{--sbw:0px}
  .shell.sb-hidden .tb-sbctl{display:flex;align-items:center;gap:var(--space-2);margin-right:var(--space-4)}
  .shell.sb-hidden>.sb-edge{display:block;position:fixed;left:0;top:var(--tb-h);bottom:0;width:10px;z-index:calc(var(--z-shell) + 1)}   /* ds-allow: L4 — the hover strip */
  .shell.sb-hidden>.sb{position:fixed;left:var(--space-8);top:calc(var(--tb-h) + var(--space-6));bottom:var(--space-8);width:var(--sb-w);height:auto;z-index:calc(var(--z-sticky) + 3);border:0;border-radius:var(--radius-card);box-shadow:var(--shadow-lg);background:var(--bg-surface);
    transform:translateX(calc(-100% - 24px));opacity:0;visibility:hidden;pointer-events:none;transition:transform var(--dur-spring) var(--spring-soft),opacity var(--dur) var(--ease),visibility 0s var(--dur-spring)}
  .shell.sb-hidden.sb-peek>.sb{transform:none;opacity:1;visibility:visible;pointer-events:auto;transition:transform var(--dur-spring-fast) var(--spring-snappy),opacity var(--dur-fast) var(--ease),visibility 0s}
  .shell.sb-hidden>.sb .sb-top{display:none}
  .shell.sb-hidden>.sb .sb-peekbar{display:block;position:absolute;right:var(--space-10);top:var(--space-10);z-index:1}   /* ds-allow: L6 — above the workspace row inside the panel */
  .shell.sb-hidden>.sb .sb-wsbox{padding-top:var(--space-10);padding-right:44px}   /* ds-allow: L4 — room for » */
  .shell.sb-hidden>.sb .sb-wsplan{display:none}
  .shell.sb-hidden>.sb .sb-wsrow{margin-right:auto}
  .shell.sb-hidden>.sb .sb-foot{background:var(--bg-surface)}
  .shell.sb-hidden>.sb .sb-badge{box-shadow:0 0 0 2px var(--bg-surface)}   /* ds-allow: L5b — knock-out ring */
  .shell.sb-hidden .tb{padding-left:var(--space-12)}
  .sb.sb-dock{animation:sbDock var(--dur-spring) var(--spring-soft)}
}
@keyframes sbDock{from{transform:translateX(-24px);opacity:.4}to{transform:none;opacity:1}}
@media (max-width:760px){
  .sb-lights{display:none}
  .sb .sb-link,.sb .sb-link.sb-child,.sb .sb-link.sb-space{height:44px}
  .sb .sb-twisty{top:var(--space-12)}
  .ib.sb-ib{width:44px;height:44px}   /* ds-allow: L13 — phone drawer tap target (DS §1.4.4) */
  .sb .sb-h-lab .sb-h-more,.sb .sb-h-lab .sb-h-plus{width:36px;height:36px}
  .sb .sb-h.sb-h-lab{height:40px}
  .sb .sb-h-lab .sb-h-t{height:40px;line-height:40px}
  .sb .sb-h-lab .sb-h-acts{top:var(--space-2)}
}
@media (prefers-reduced-motion:reduce){
  .shell.sb-hidden>.sb,.shell.sb-hidden.sb-peek>.sb{transition:none!important}
  .sb.sb-dock{animation:none}
  .sb .sb-k,.sb .sb-h-lab .sb-h-acts,.ib.sb-ib{transition:none}
}
html.reduce-motion .shell.sb-hidden>.sb,html.reduce-motion .shell.sb-hidden.sb-peek>.sb{transition:none!important}
html.reduce-motion .sb.sb-dock{animation:none}

/* ───────── Founder edits, Nov 27 ─────────
   1 · Spaces is a MAIN row (same size / weight / icon treatment as Home, My Library, Meetings): the row opens the Spaces
       directory; ⌄ folds the list (rotates −90° on --spring-snappy); + is visible at rest (28px, "New space"); ⋯ (Show / Sort /
       Customize) appears on hover. Under it, only spaces — indented one step, emoji · name · ⋯ on hover. No projects.
   4 · Inbox lives in the title bar, right side, on every page (icon + count bubble).
   5 · The logo stays when the sidebar is closed: lights · logo · ◧ in the title bar (mark only on narrow windows and phones).
   6 · Record a video: a filled Ludoq-blue split button (Loom's spirit) — white ring-dot glyph, white label, a divided ▾ segment. */
.sb .sb-sec.sb-spaces-main{margin-top:1px}   /* ds-allow: L4 — joins the main rows (Notion's 1px row gap) */
.sb-sprow{position:relative}
.sb .sb-sprow>.sb-sp-main{padding-right:88px}   /* ds-allow: L4 — room for ⋯ ⌄ + */
.sb-sp-acts{position:absolute;right:var(--space-2);top:1px;display:flex;align-items:center;gap:0}   /* ds-allow: L4 — centres the 28px buttons on the 30px row */
.sb-sp-acts .ib.sb-ib .ic{width:16px;height:16px}
.sb-sp-acts .ib.sb-sp-add .ic{width:18px;height:18px}
.sb-sp-acts .sb-sp-opt{opacity:0;pointer-events:none;transition:opacity var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}
.sb-sprow:is(:hover,:focus-within) .sb-sp-opt,.sb-sp-acts .sb-sp-opt[aria-expanded="true"]{opacity:1;pointer-events:auto}
.sb-sp-disc .ic{transition:transform var(--dur-spring-fast) var(--spring-snappy)}
.sb-sp-acts .ib.sb-sp-disc[aria-expanded]{background:transparent}   /* open / closed is shown by the chevron, not a fill */
.sb-sp-acts .ib.sb-sp-disc[aria-expanded]:hover{background:var(--bg-row-hover)}
.sb-sec.closed .sb-sp-disc .ic{transform:rotate(-90deg)}
.sb-sp-acts .sb-sp-add{color:var(--icon-default)}
.sb .sb-sprow>.sb-sp-main[aria-current="page"]~.sb-sp-acts .ib.sb-ib:hover,.sb .sb-sprow>.sb-sp-main[aria-current="page"]~.sb-sp-acts .ib.sb-sp-disc[aria-expanded]:hover{background:var(--bg-pressed)}
@media (hover:none){.sb-sp-acts .sb-sp-opt{opacity:1;pointer-events:auto}}
/* the spaces under it: one indent step, emoji at 18 */
.sb .sb-spaces-main .sb-tree{padding-top:1px}   /* ds-allow: L4 — Notion's 1px row gap */
.sb .sb-spaces-main .sb-srow>.sb-space,.sb .sb-spaces-main .sb-more-row{padding-left:var(--space-24)}
.sb .sb-spaces-main .sb-srow>.sb-space>.glyph{width:20px;height:20px}
.sb .sb-spaces-main .sb-srow:is(:hover,:focus-within,.is-hover) .sb-space{padding-right:var(--space-32)}
.sb .sb-spaces-main .sb-sacts{right:var(--space-4)}
.sb.cz .sb-spaces-main .sb-tree .cz-item{padding-left:var(--space-16)}
@media (max-width:760px){
  .sb .sb-sprow>.sb-sp-main{padding-right:124px}   /* ds-allow: L4 — room for three 36px buttons */
  .sb-sp-acts{top:var(--space-4)}
  .sb-sp-acts .ib.sb-ib{width:36px;height:36px}   /* ds-allow: L13 — phone drawer tap target (DS §1.4.4) */
  .sb .sb-spaces-main .sb-srow:is(:hover,:focus-within,.is-hover) .sb-space,.sb .sb-spaces-main .sb-srow .sb-space{padding-right:var(--space-48)}
}

/* Inbox in the title bar */
.tb .tb-inbox{position:relative;flex:none;width:var(--h-32);height:var(--h-32);display:inline-grid;place-items:center;border-radius:var(--radius-chip);color:var(--icon-muted);transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.tb .tb-inbox .ic{width:18px;height:18px}
.tb .tb-inbox:hover{background:var(--bg-hover);color:var(--icon-default)}
.tb .tb-inbox:active{background:var(--bg-pressed);transition:none}
.tb .tb-inbox[aria-current="page"]{background:var(--bg-pressed);color:var(--icon-default)}
.tb .tb-inbox:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
.tb .tb-inbox .sb-badge{top:-1px;right:-5px;box-shadow:0 0 0 2px var(--bg-canvas)}   /* ds-allow: L4 · ds-allow: L5b — the count bubble overhangs the icon and knocks out its ring */
.tb .tb-actions:not(:empty)+.tb-fixed{margin-left:var(--space-8)}
.tb .tb-fixed{gap:var(--space-6);padding-right:var(--space-4)}

/* the logo in the title bar while the sidebar is closed (and on phones, after ☰) */
.tb-logo{display:inline-flex;align-items:center;gap:var(--space-6);flex:none;height:28px;padding:0 var(--space-6) 0 var(--space-4);border-radius:var(--radius-chip);color:var(--fg-default);text-decoration:none;transition:background var(--dur-fast) var(--ease)}
.tb-logo:hover{background:var(--bg-hover)}
.tb-logo:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
.tb-logo-mark,.tb-mlogo{display:grid;place-items:center;width:20px;height:20px;flex:none}
.tb-logo-mark .sl-logo,.tb-mlogo .sl-logo{width:20px;height:20px}
.tb-logo-word{font:600 var(--fs-14)/20px var(--font-sans);letter-spacing:-.01em;color:var(--fg-default)}
.tb-mlogo{display:none}
@media (max-width:900px){.tb-logo-word{display:none}.tb-logo{padding:0 var(--space-4)}}
@media (max-width:760px){
  .tb-mlogo{display:grid;width:28px;height:28px;border-radius:var(--radius-chip);margin-left:calc(var(--space-4) * -1)}
  .tb-mlogo:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
}

/* Record a video — the sidebar's one filled blue (supersedes "Record never blue" for this button only) */
.sb .sb-rec.sb-recx{position:relative;display:flex;align-items:stretch;height:var(--h-36);margin:var(--space-2) 0 var(--space-8);border-radius:var(--radius-control);background:var(--accent);
  box-shadow:var(--btn-primary-shadow),0 2px 8px -3px color-mix(in srgb,var(--accent) 70%,transparent);transition:transform var(--dur-spring-fast) var(--spring-snappy),box-shadow var(--dur-fast) var(--ease)}   /* ds-allow: L5b — a soft blue lift under the one filled button */
.sb .sb-recx:has(:is(.sb-recx-go,.sb-recx-opt):active){transform:scale(.98);transition-duration:var(--dur-fast)}
.sb .sb-recx .sb-recx-go{flex:1;min-width:0;display:flex;align-items:center;justify-content:flex-start;gap:var(--space-10);height:auto;padding:0 var(--space-12);border-radius:var(--radius-control) 0 0 var(--radius-control);background:transparent;color:var(--fg-on-accent);font:600 var(--fs-14)/20px var(--font-sans);text-decoration:none;transition:background var(--dur-fast) var(--ease)}
.sb .sb-recx .sb-recx-go .lbl{color:inherit;font:inherit;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb .sb-recx .sb-recx-opt{position:relative;flex:none;width:var(--h-36);height:auto;padding:0;margin:0;translate:none;display:grid;place-items:center;border-radius:0 var(--radius-control) var(--radius-control) 0;background:transparent;color:color-mix(in srgb,var(--fg-on-accent) 86%,transparent);transition:background var(--dur-fast) var(--ease),color var(--dur-fast) var(--ease)}
.sb .sb-recx .sb-recx-opt::before{content:"";position:absolute;left:0;top:var(--space-8);bottom:var(--space-8);width:1px;background:color-mix(in srgb,var(--fg-on-accent) 30%,transparent)}   /* ds-allow: L4 — the split seam */
.sb .sb-recx .sb-recx-opt .ic{width:16px;height:16px;transition:transform var(--dur-spring-fast) var(--spring-snappy)}
.sb .sb-recx .sb-recx-opt[aria-expanded="true"] .ic{transform:rotate(180deg)}
.sb .sb-recx .sb-recx-go:hover,.sb .sb-recx .sb-recx-opt:hover,.sb .sb-recx .sb-recx-opt[aria-expanded="true"]{background:var(--accent-hover);color:var(--fg-on-accent)}
.sb .sb-recx .sb-recx-go:active,.sb .sb-recx .sb-recx-opt:active{background:var(--accent-pressed,var(--accent-hover))}
.sb .sb-recx .sb-recx-go:focus-visible,.sb .sb-recx .sb-recx-opt:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:var(--focus-offset)}
.sb-recx-mark{position:relative;flex:none;width:16px;height:16px;box-sizing:border-box;border-radius:var(--radius-full);border:1.75px solid var(--fg-on-accent);display:grid;place-items:center}   /* ds-allow: L4 — the record ring */
.sb-recx-mark::after{content:"";width:6px;height:6px;border-radius:var(--radius-full);background:var(--fg-on-accent);transition:transform var(--dur-spring-fast) var(--spring-snappy)}   /* ds-allow: L4 — the record dot */
.sb-recx-go:hover .sb-recx-mark::after{transform:scale(1.25)}
.shell.sb-hidden>.sb .sb-recx{background:var(--accent)}
@media (prefers-reduced-motion:reduce){.sb .sb-rec.sb-recx,.sb-recx-mark::after,.sb .sb-recx .sb-recx-opt .ic,.sb-sp-disc .ic{transition:none}.sb .sb-recx:has(:active){transform:none}}
html.reduce-motion .sb .sb-rec.sb-recx,html.reduce-motion .sb-recx-mark::after,html.reduce-motion .sb .sb-recx .sb-recx-opt .ic,html.reduce-motion .sb-sp-disc .ic{transition:none}
html.reduce-motion .sb .sb-recx:has(:active){transform:none}
.sb .sb-sprow:hover>.sb-sp-main:not([aria-current="page"]){background:var(--bg-row-hover)}

/* Nov 27: phones show Inbox in the bottom tab bar — hide the title-bar copy there so it appears once */
@media (max-width:760px){.has-tabbar .tb .tb-inbox{display:none}}   /* the tab bar shows only ≤760px; .has-tabbar is set at every width */

/* Nov 27 · signed-out visitor on a shared link (?as=visitor on watch / board, js/shell.js isPublicViewer): a minimal public
   header — logo · Log in · Sign up free — and no workspace sidebar, history, crumbs, Inbox or account */
html.pub-view .shell{--sbw:0px;--cpw:0px}
html.pub-view .shell>.sb,html.pub-view .sb-edge,html.pub-view .sh-scrim,html.pub-view .shell>.cp,html.pub-view .tb-menu,html.pub-view .tb-mlogo,html.pub-view .tb-hist,html.pub-view .tb-back,html.pub-view .crumbs,html.pub-view .tb-actions,html.pub-view .tb-fixed,html.pub-view .tb-sbctl .sb-expand,html.pub-view .tb-sbctl .sb-lights{display:none!important}
html.pub-view .shell>.sh-main{grid-column:1/-1}
html.pub-view .tb{padding:0 var(--space-16)}
html.pub-view .tb-sbctl{display:flex;align-items:center}
html.pub-view .tb-logo-word{display:inline}
.tb-pub{display:flex;align-items:center;gap:var(--space-8);margin-left:auto;flex:none}
/* Contact support (Circleback lessons, Nov 29): the stated reply time first */
.sup-lead{display:flex;align-items:flex-start;gap:var(--space-8);margin:0;padding:var(--space-10) var(--space-12);border-radius:var(--radius-item);background:var(--bg-subtle);font:var(--type-body-sm);color:var(--fg-default)}
.sup-lead .ic{flex:none;margin-top:var(--space-2);color:var(--icon-muted)}
.sup-lead b{font-weight:500}
.sup-dlg .fb-shot{align-items:flex-start}

/* ───────── Calm spec §2 (Nov 28) ─────────
   Header row = Ludoq mark · workspace ⌄ · … · ◧ collapse at the far right (Loom). Under it, Search drawn as a field
   (32px, 1px border, radius 8, magnifier · "Search" · ⌘K) with ✎ New beside it. Rows 32 / 14px, outline icons, grey fill. */
.sb .sb-top{gap:var(--space-2);padding:0 var(--space-10) 0 var(--space-10)}
.sb .sb-top .sb-logo{display:grid;place-items:center;width:28px;height:28px;padding:0;margin:0;border-radius:var(--radius-chip)}
.sb .sb-top .sb-wsrow{flex:0 1 auto;min-width:0;display:flex;align-items:center;gap:var(--space-4);height:28px;padding:0 var(--space-6);border-radius:var(--radius-chip);color:var(--fg-default)}
.sb .sb-top .sb-wsrow:hover,.sb .sb-top .sb-wsrow[aria-expanded="true"]{background:var(--bg-row-hover)}
.sb .sb-top .sb-wsname{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:600 var(--fs-14)/20px var(--font-sans);color:var(--fg-default)}
.sb .sb-top .sb-toggle{margin-left:auto}
.sb .sb-top .sb-dockbtn{display:none}
.sb-peekbar{display:none!important}
.sb .sb-wsbox{padding:0 var(--space-10) var(--space-8) var(--space-8)}
.sb .sb-wsline{display:flex;align-items:center;gap:var(--space-4)}
.sb .sb-search{flex:1;min-width:0;display:flex;align-items:center;gap:var(--space-8);height:32px;padding:0 var(--space-8) 0 var(--space-10);border:1px solid transparent;border-radius:8px;background:var(--ctl-fill);color:var(--fg-muted);font:400 var(--fs-14)/20px var(--font-sans);text-align:left;cursor:text;transition:border-color var(--dur-fast) var(--ease),background var(--dur-fast) var(--ease)}   /* ds-allow: L4 — the spec's 8px field radius */
.sb .sb-search>.ic{flex:none;width:16px;height:16px;color:var(--nsb-icon)}
.sb .sb-search-ph{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sb .sb-search .sb-k{opacity:1;margin-left:auto;font:500 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
.sb .sb-search:hover{background:var(--ctl-fill-hover)}
.sb .sb-search:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:var(--focus-offset)}
.sb .sb-link{height:32px}
.sb .sb-link.sb-child{height:32px}
.sb .sb-twisty{top:6px}   /* ds-allow: L4 — centres the 20px twisty on the 32px row */
/* closed sidebar, floating peek: the same header, » "Keep sidebar open" in the collapse spot */
@media (min-width:761px){
  .shell.sb-hidden>.sb .sb-top{display:flex}
  .shell.sb-hidden>.sb .sb-top .sb-toggle{display:none}
  .shell.sb-hidden>.sb .sb-top .sb-dockbtn{display:inline-grid;margin-left:auto}
  .shell.sb-hidden>.sb .sb-top .sb-lights{display:none}
  .shell.sb-hidden>.sb .sb-wsbox{padding-top:0;padding-right:var(--space-10)}
}
@media (max-width:760px){
  .sb .sb-top .sb-wsrow{height:44px}
  .sb .sb-search{height:44px}
  .sb .sb-link,.sb .sb-link.sb-child{height:44px}
  .sb .sb-twisty{top:var(--space-12)}
}

/* calm spec §0 / §8: full-screen tools (whiteboard…) lead the title bar with ← back, then the breadcrumb */
.tb .tb-back{flex:none;width:var(--h-32,32px);height:var(--h-32,32px);display:inline-grid;place-items:center;margin-right:var(--space-4);border-radius:var(--radius-chip);color:var(--icon-default)}
.tb .tb-back:hover{background:var(--bg-hover)}
.tb .tb-back:active{background:var(--bg-pressed)}
.tb .tb-back:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
@media (max-width:760px){.tb .tb-back{width:44px;height:44px;margin-right:0}}   /* ds-allow: L13 — phone tap target */

/* ── Peek, redesigned (founder, Nov 28: "the collapsed sidebar hover peek looks bad"). The peek IS the open sidebar:
   full height from the very top, flush left, the same width, background, rows and header (» "Keep sidebar open" sits
   where ◧ was). It slides in on a spring over the page with one hairline edge and a soft shadow to the right — no
   floating card, no rounded corners, nothing clipped under the title bar. ── */
@media (min-width:761px){
  .shell.sb-hidden>.sb{left:0;top:0;bottom:0;height:100%;width:var(--sb-w);border-radius:0;border:0;border-right:1px solid var(--border-subtle);
    background:var(--bg-sidebar);box-shadow:8px 0 24px -12px rgba(43,42,39,.18),2px 0 6px -4px rgba(43,42,39,.08);   /* ds-allow: L5 — one-sided edge shadow of the peek */
    z-index:calc(var(--z-sticky) + 10);transform:translateX(-101%);opacity:1;   /* above the title bar (100), below menus (--z-pop 120) */
    transition:transform var(--dur-spring) var(--spring-soft),visibility 0s var(--dur-spring)}
  .shell.sb-hidden.sb-peek>.sb{transform:none;transition:transform var(--dur-spring-fast) var(--spring-snappy),visibility 0s}
  .shell.sb-hidden>.sb .sb-top{display:flex;height:var(--tb-h)}
  .shell.sb-hidden>.sb .sb-foot{background:var(--bg-sidebar)}
  .shell.sb-hidden>.sb .sb-badge{box-shadow:0 0 0 2px var(--bg-sidebar)}   /* ds-allow: L5b — knock-out ring */
  .shell.sb-hidden>.sb-edge{top:0}
}

/* ───────── Sidebar top (founder decision, Nov 28 · option A) ─────────
   Row 1: Ludoq mark + "Ludoq" wordmark · … · ◧ collapse at the far right. Row 2: a compact workspace row
   "N Northwind · Business ⌄" (the switcher). Row 3: Search field + ✎ New. Bottom: avatar · name · email (personal). No
   Record button — New ▾ is on every page. */
.sb .sb-top .sb-logo{width:auto;display:inline-flex;align-items:center;gap:var(--space-6);padding:0 var(--space-6) 0 var(--space-4)}
.sb-word{font:600 var(--fs-15,15px)/20px var(--font-sans);letter-spacing:-.01em;color:var(--fg-default)}
.sb .sb-wsbox>.sb-wsrow{display:flex;align-items:center;gap:var(--space-6);width:100%;height:32px;margin:0 0 var(--space-6);padding:0 var(--space-6);border-radius:var(--radius-chip);color:var(--fg-default);text-align:left}
.sb .sb-wsbox>.sb-wsrow:hover,.sb .sb-wsbox>.sb-wsrow[aria-expanded="true"]{background:var(--bg-row-hover)}
.sb .sb-wsbox>.sb-wsrow:focus-visible{outline:var(--focus-width) solid var(--focus-color);outline-offset:calc(var(--focus-offset) * -1)}
.sb-wsav{flex:none;width:20px;height:20px;display:grid;place-items:center;border-radius:5px;background:var(--fg-default);color:var(--bg-surface);font:600 11px/1 var(--font-sans)}   /* ds-allow: L4 — the workspace initial tile */
.sb .sb-wsbox>.sb-wsrow .sb-wsname{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:500 var(--fs-14)/20px var(--font-sans);color:var(--fg-default)}
.sb .sb-wsplan{flex:none;font:400 var(--fs-13)/20px var(--font-sans);color:var(--fg-muted);white-space:nowrap}
.sb .sb-wsbox>.sb-wsrow .sb-wschev{flex:none;margin-left:auto;color:var(--nsb-icon)}
.sb .sb-acct .who{flex-direction:column;align-items:flex-start;gap:0;min-width:0}
.sb .sb-acctrow>.sb-acct{height:40px}
.sb .sb-acct-em{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font:400 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
@media (max-width:760px){.sb .sb-wsbox>.sb-wsrow{height:44px}.sb .sb-acctrow>.sb-acct{height:48px}}
/* drop a file anywhere (founder decision, Nov 28 eve) — one calm overlay, no motion beyond a fade */
.gdrop{position:fixed;inset:0;z-index:calc(var(--z-pop, 120) + 5);display:grid;place-items:center;background:color-mix(in srgb,var(--bg-surface) 70%,transparent);opacity:0;transition:opacity var(--dur-fast) var(--ease);pointer-events:none}
.gdrop.on{opacity:1}
.gdrop-c{display:flex;flex-direction:column;align-items:center;gap:var(--space-6);padding:var(--space-24) var(--space-32);border:1.5px dashed var(--border-strong);border-radius:var(--radius-card);background:var(--bg-surface);box-shadow:var(--shadow-md);color:var(--fg-default)}
.gdrop-c b{font:600 var(--fs-15,15px)/20px var(--font-sans)}
.gdrop-c small{font:var(--type-caption);color:var(--fg-muted)}
.pl-form{display:flex;flex-direction:column;gap:var(--space-8)}
.pl-l{font:var(--type-label);color:var(--fg-default)}
.pl-h{margin:0;font:var(--type-caption);color:var(--fg-muted)}
.pl-h.is-err{color:var(--danger-fg, var(--fg-default))}
.pl-a{justify-content:flex-end;margin-top:var(--space-8)}
@media (prefers-reduced-motion:reduce){.gdrop{transition:none}}

/* ═══════════ Loved pass (Nov 28 night) — small shared pieces ═══════════ */
/* account menu: the plain promise + the plan chip opens Plans & billing */
.acct-promise{margin:6px 10px 6px;font-size:12px;line-height:1.4;color:var(--ink-40)}
a.acct-plan{text-decoration:none}
a.acct-plan:hover{color:var(--text-1)}
/* What's new */
.wn{display:flex;flex-direction:column;gap:20px}
.wn-sec .eye{margin:0 0 8px}
.wn-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}
.wn-list li{display:flex;flex-direction:column;gap:2px;font-size:13px}.wn-list li span{color:var(--ink-64)}
.wn-lead{margin:0 0 10px;font-size:13px;color:var(--ink-64)}
.wn-days{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.wn-day{display:grid;grid-template-columns:56px 96px 1fr;gap:8px;padding:8px 0;border-top:1px solid var(--hair);font-size:13px}
.wn-n{color:var(--ink-40)}.wn-t{color:var(--ink-40)}
.wn-foot{margin:0;font-size:12px;color:var(--ink-40)}
/* public page dialog, rename speaker, jump to time */
.pub-dlg,.rs-form,.jt-form{display:flex;flex-direction:column;gap:12px}
.pub-r{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 0;border-top:1px solid var(--hair)}
.pub-r b{display:block;font-size:13px;font-weight:600}.pub-r small{display:block;font-size:12px;color:var(--ink-64)}
/* shortcuts sheet foot link */
.sc-more{align-self:center;font-size:12px}
/* video page: locked paid stat + whole-video call to action */
.stat-lock{text-decoration:none;color:inherit}.stat-lock b{display:inline-flex;align-items:center;gap:4px;font-size:13px;color:var(--ink-40)}
.pl-cta{position:absolute;top:12px;right:12px;z-index:3}

/* Nov 28: the account avatar at the foot of the sidebar is ink, not the user's blue — one solid blue per view (calm spec) */
.sb-acct .av{background-color:var(--ink-100);color:var(--bg-canvas)}   /* ink avatar: dark on light, light on dark */

/* Dashboard close §D1 (Nov 28): phone + sheet = the desktop New menu's items and labels, as rows under group headings */
.pns.pns-list{gap:0}
.pns-h{margin:var(--space-12) 0 var(--space-4);padding:0 var(--space-4);font:600 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
.pns-h:first-child{margin-top:0}
.pns-r{display:flex;align-items:center;gap:var(--space-12);width:100%;min-height:48px;padding:0 var(--space-8);border:0;border-radius:10px;background:none;color:var(--fg-default);font:500 var(--fs-16)/22px var(--font-sans);text-align:left;cursor:pointer}
.pns-r>.ic,.pns-r>.glyph{flex:none;color:var(--fg-muted)}
.pns-r>span{flex:1;min-width:0}
.pns-r:hover,.pns-r:focus-visible{background:var(--bg-hover,var(--surface-2))}
.pns-r:disabled{opacity:.5}
.pns-hint{flex:none;font:500 var(--fs-12)/16px var(--font-sans);color:var(--fg-muted)}
/* Upload or paste a link: one dialog, the upload row first, then the link, then the Plans v2 rule */
.pl-up{display:flex;align-items:center;gap:var(--space-12);width:100%;padding:var(--space-12);border:1px solid var(--border-subtle);border-radius:12px;background:var(--bg-surface);color:var(--fg-default);text-align:left;cursor:pointer;transition:border-color var(--dur-micro,120ms) var(--ease)}
.pl-up:hover{border-color:var(--border-strong)}
.pl-up>span{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.pl-up b{font:600 var(--fs-14)/20px var(--font-sans)}
.pl-up small{font:var(--type-caption);color:var(--fg-muted)}
.pl-up>.ic:first-child{color:var(--fg-muted)}
.pl-or{display:flex;align-items:center;gap:var(--space-8);margin:var(--space-4) 0;color:var(--fg-muted);font:var(--type-caption)}
.pl-or::before,.pl-or::after{content:"";flex:1;height:1px;background:var(--border-subtle)}
.pl-rule{display:flex;align-items:flex-start;gap:var(--space-6);margin:0;font:var(--type-caption);color:var(--fg-muted)}
.pl-rule .ic{flex:none;margin-top:2px}
/* ⌘K on a source (Notion-level decision 13, mockup 13): "On 'Acme kickoff'" chip in the field, Run / Run & open, Browse all recipes */
.cmdk-in .search-field .cmdk-ctx{flex:none;margin-left:auto;max-width:220px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:var(--space-2) var(--space-8);border-radius:var(--radius-chip);background:var(--bg-muted);color:var(--fg-muted);font:var(--type-caption)}
.cmdk-foot .cmdk-browse{display:inline-flex;align-items:center;gap:var(--space-2);color:var(--fg-muted);text-decoration:none}
.cmdk-foot .cmdk-browse:hover{color:var(--fg-default)}
.cmdk-foot .cmdk-browse .ic{width:12px;height:12px}
.cmdk{background:var(--layer-popover)}
