/* «Стратегия — план работ». Стиль — как у «ОС фабрики» и «Сейлса» (iOS 26 «жидкое стекло»): тема — css/theme.css.
   Экраны: список досок (#/) и доска (#/b/<id>) — бесконечный холст с плавающими стеклянными панелями. */

/* Шрифт, токены, обои и стекло — общая тема ОС и Сейлса: css/theme.css (копия os/web/css/theme.css, подключена первой). */
:root { --red-ios: #ff3b30; }
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.glass { background: var(--glass); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  border: 1px solid var(--glass-edge); box-shadow: var(--hl), var(--shadow); }
.muted { color: var(--label-2); }

.btn { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 12px; border: 0; cursor: pointer;
  font-weight: 600; color: #fff; background: linear-gradient(135deg, rgba(var(--tint-rgb), .82), rgba(var(--tint-rgb), 1));
  box-shadow: 0 6px 16px rgba(var(--tint-rgb), .28), inset 0 1px 0 rgba(255, 255, 255, .35); transition: transform .2s var(--spring-soft); }
.btn:active { transform: scale(.96); }
.btn.ghost { color: var(--label); background: var(--glass-pop); box-shadow: var(--hl), 0 1px 3px rgba(0, 0, 0, .06); }
.btn .ic { width: 18px; height: 18px; }

/* ───────────── список досок ───────────── */
.boards { max-width: 1180px; margin: 0 auto; padding: 28px 24px 60px; }
.top { display: flex; align-items: center; gap: 14px; margin-bottom: 26px; }
.logo { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #ffcf70, #f0742c); box-shadow: 0 6px 16px rgba(240, 116, 44, .3), inset 0 1px 0 rgba(255, 255, 255, .4); }
.logo .ic { width: 26px; height: 26px; }
.top h1 { margin: 0; font-size: 24px; font-weight: 750; letter-spacing: -.02em; }
.top .sub { font-size: 13px; }
.top .fill { flex: 1; }
.search { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px; border-radius: 12px; min-width: 220px; }
.search input { border: 0; background: transparent; outline: 0; width: 100%; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.card { position: relative; border-radius: 20px; padding: 0; cursor: pointer; overflow: hidden; transition: transform .25s var(--spring-soft), box-shadow .25s var(--ease); }
.card:hover { transform: translateY(-2px); box-shadow: var(--hl), var(--shadow-l); }
.card .prev { height: 130px; background: rgba(255, 255, 255, .55); border-bottom: 1px solid rgba(60, 60, 67, .08); position: relative; overflow: hidden;
  background-image: radial-gradient(rgba(60, 60, 67, .16) 1px, transparent 1px); background-size: 14px 14px; }
.card .prev i { position: absolute; border-radius: 3px; box-shadow: 0 1px 2px rgba(0, 0, 0, .12); }
.card .meta { padding: 12px 14px 14px; }
.card .t { font-weight: 650; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card .d { font-size: 12.5px; margin-top: 3px; }
.card .more { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 9px; border: 0; cursor: pointer; display: grid; place-items: center;
  background: var(--glass-pop); opacity: 0; transition: opacity .2s; }
.card:hover .more, .card .more:focus { opacity: 1; }
.card.new { display: grid; place-items: center; min-height: 196px; color: var(--tint); font-weight: 650; border: 2px dashed rgba(var(--tint-rgb), .35); background: rgba(255, 255, 255, .3); box-shadow: none; }
.card.new .ic { width: 28px; height: 28px; margin: 0 auto 6px; display: block; }
.empty { padding: 60px 0; text-align: center; }

.menu { position: fixed; z-index: 100; min-width: 180px; padding: 6px; border-radius: 14px; background: var(--glass-pop);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border: 1px solid var(--glass-edge); box-shadow: var(--hl), var(--shadow-l); }
.menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border: 0; border-radius: 9px; background: transparent; cursor: pointer; text-align: left; }
.menu button:hover { background: rgba(var(--tint-rgb), .1); }
.menu button.danger { color: var(--red-ios); }
.menu .ic { width: 17px; height: 17px; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 200; padding: 10px 16px; border-radius: 14px;
  background: rgba(28, 28, 30, .86); color: #fff; font-weight: 550; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }

/* ───────────── доска ───────────── */
.board { position: fixed; inset: 0; overflow: hidden; background: rgba(250, 249, 253, .78); touch-action: none; user-select: none; -webkit-user-select: none; }
.viewport { position: absolute; inset: 0; overflow: hidden; cursor: default; outline: none;
  background-image: radial-gradient(rgba(60, 60, 67, .22) calc(var(--z, 1) * 1.1px), transparent 0);
  background-size: calc(var(--z, 1) * 24px) calc(var(--z, 1) * 24px); background-position: var(--gx, 0) var(--gy, 0); }
.viewport.pan, .viewport.pan * { cursor: grab !important; }
.viewport.panning, .viewport.panning * { cursor: grabbing !important; }
.viewport.draw { cursor: crosshair; }
.world { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }
.links { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; z-index: 2000000000; }
.overlay { position: absolute; left: 0; top: 0; pointer-events: none; z-index: 2000000001; }
.links path, .links line { pointer-events: stroke; cursor: pointer; }

.it { position: absolute; left: 0; top: 0; }
.it .txt { width: 100%; height: 100%; padding: 14px; overflow: hidden; white-space: pre-wrap; word-break: break-word; outline: none; line-height: 1.3;
  display: flex; flex-direction: column; justify-content: var(--valign, center); text-align: var(--align, center); }
.it .txt:empty::before { content: attr(data-ph); color: rgba(60, 60, 67, .35); }
.it.editing .txt { user-select: text; -webkit-user-select: text; cursor: text; }
.it.sticky { box-shadow: 0 1px 1px rgba(0, 0, 0, .06), 0 8px 18px rgba(30, 20, 60, .12); border-radius: 3px; }
.it.text .txt { padding: 4px 6px; justify-content: flex-start; text-align: left; }
.it.shape svg.bg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.it.shape .txt { position: relative; }
.it.frame { border-radius: 4px; background: rgba(255, 255, 255, .75); border: 1px solid rgba(60, 60, 67, .18); }
.it.frame .ftitle { position: absolute; left: 0; bottom: 100%; margin-bottom: calc(6px / var(--z, 1)); font-size: calc(14px / var(--z, 1));
  font-weight: 650; color: var(--label-2); white-space: nowrap; outline: none; transform-origin: 0 100%; }
.it.frame.editing .ftitle { user-select: text; -webkit-user-select: text; color: var(--label); }
.it.pen { pointer-events: none; }

.sel-box { position: absolute; left: 0; top: 0; border: calc(1.5px / var(--z, 1)) solid var(--tint); pointer-events: none; }
.sel-box.multi { border-style: dashed; }
.hdl { position: absolute; width: calc(10px / var(--z, 1)); height: calc(10px / var(--z, 1)); margin: calc(-5px / var(--z, 1)) 0 0 calc(-5px / var(--z, 1));
  background: #fff; border: calc(1.5px / var(--z, 1)) solid var(--tint); border-radius: 50%; pointer-events: auto; }
.hdl.nw, .hdl.se { cursor: nwse-resize; } .hdl.ne, .hdl.sw { cursor: nesw-resize; }
.hdl.n, .hdl.s { cursor: ns-resize; } .hdl.e, .hdl.w { cursor: ew-resize; }
.hdl.end { background: var(--tint); cursor: move; }
.dot { position: absolute; width: calc(14px / var(--z, 1)); height: calc(14px / var(--z, 1)); margin: calc(-7px / var(--z, 1)) 0 0 calc(-7px / var(--z, 1));
  border-radius: 50%; background: rgba(var(--tint-rgb), .18); border: calc(1.5px / var(--z, 1)) solid var(--tint); cursor: crosshair; pointer-events: auto; }
.marquee { position: absolute; border: 1px solid rgba(var(--tint-rgb), .8); background: rgba(var(--tint-rgb), .08); pointer-events: none; }
.hover-ring { position: absolute; outline: calc(2px / var(--z, 1)) solid rgba(var(--tint-rgb), .55); pointer-events: none; border-radius: 4px; }

.bar { position: absolute; z-index: 10; display: flex; align-items: center; gap: 4px; padding: 6px; border-radius: 16px; }
.bar button, .bar .bt { width: 38px; height: 38px; border: 0; border-radius: 11px; background: transparent; cursor: pointer; display: grid; place-items: center; position: relative;
  transition: background .15s, transform .2s var(--spring-soft); }
.bar button:hover { background: rgba(var(--tint-rgb), .09); }
.bar button:active { transform: scale(.92); }
.bar button.on { background: rgba(var(--tint-rgb), .16); color: var(--tint); }
.bar button:disabled { opacity: .35; cursor: default; }
.bar .sep { width: 1px; height: 24px; background: var(--sep); margin: 0 3px; }
.bar.v { flex-direction: column; } .bar.v .sep { width: 24px; height: 1px; margin: 3px 0; }
.tb-head { left: 14px; top: 14px; gap: 8px; padding: 6px 12px 6px 6px; max-width: calc(100vw - 260px); }
.tb-head .title { font-weight: 650; font-size: 15px; outline: none; border-radius: 7px; padding: 4px 6px; min-width: 40px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: text; }
.tb-head .title:focus { background: rgba(255, 255, 255, .9); box-shadow: 0 0 0 2px rgba(var(--tint-rgb), .35); }
.save { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--label-2); white-space: nowrap; }
.save .ic { width: 15px; height: 15px; }
.save.err { color: var(--red-ios); }
.tb-tools { left: 14px; top: 50%; transform: translateY(-50%); }
.tb-undo { right: 14px; top: 14px; }
.tb-zoom { right: 84px; bottom: 14px; }   /* правый нижний угол — кнопка «Сообщить о проблеме» */
.tb-zoom .pct { width: 58px; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ctx { left: 0; top: 0; z-index: 12; flex-wrap: wrap; max-width: 92vw; }
.swatch { width: 24px !important; height: 24px !important; border-radius: 50% !important; border: 1px solid rgba(0, 0, 0, .12) !important; margin: 0 2px; }
.swatch.on { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--tint); }
.ctx .lbl { font-size: 12.5px; font-weight: 650; padding: 0 6px; width: auto; min-width: 30px; }
.tip { position: absolute; left: calc(100% + 10px); top: 50%; transform: translateY(-50%); white-space: nowrap; padding: 5px 9px; border-radius: 9px;
  font-size: 12px; font-weight: 600; color: #fff; background: rgba(28, 28, 30, .86); pointer-events: none; opacity: 0; transition: opacity .15s; }
.tb-tools button:hover .tip { opacity: 1; }
.tip kbd { font: inherit; opacity: .65; margin-left: 6px; }
.help { position: absolute; z-index: 20; right: 14px; top: 70px; width: 300px; padding: 14px 16px; border-radius: 18px; font-size: 13px; }
.help h3 { margin: 0 0 8px; font-size: 14px; }
.help div { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }
.help kbd { font: 600 12px/1 inherit; padding: 3px 6px; border-radius: 6px; background: var(--fill); white-space: nowrap; }
.loading { position: fixed; inset: 0; display: grid; place-items: center; color: var(--label-2); }

@media (max-width: 700px) {
  .tb-head { max-width: calc(100vw - 150px); }
  .tb-tools { top: auto; bottom: 14px; left: 50%; transform: translateX(-50%); flex-direction: row; }
  .tb-tools .sep { width: 1px; height: 24px; margin: 0 3px; }
  .tb-zoom { bottom: 76px; }
  .tip { display: none; }
}

/* ───────────── 03.11.2026: вход, разделы, окна, задачи, люди ───────────── */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login { width: min(400px, 100%); padding: 28px; border-radius: 24px; display: flex; flex-direction: column; gap: 12px; }
.login .logo { margin: 0 auto 4px; }
.login h1 { margin: 0; font-size: 22px; text-align: center; letter-spacing: -.02em; }
.login p { margin: 0 0 6px; text-align: center; }
.login .err { color: var(--red-ios); font-weight: 550; font-size: 13.5px; }
.btn.wide { width: 100%; justify-content: center; height: 44px; }
.os-link { text-align: center; font-size: 13.5px; color: var(--tint); text-decoration: none; margin-top: 4px; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 600; color: var(--label-2); }
.field input, .field select, .row-f select { height: 40px; padding: 0 12px; border-radius: 11px; border: 1px solid rgba(60, 60, 67, .16); background: rgba(255, 255, 255, .85);
  font-size: 15px; font-weight: 450; color: var(--label); outline: none; }
.field input:focus, .field select:focus { border-color: rgba(var(--tint-rgb), .6); box-shadow: 0 0 0 3px rgba(var(--tint-rgb), .15); }
.small { font-size: 12.5px; }
.lead { margin: -10px 0 18px; max-width: 760px; font-size: 13.5px; line-height: 1.45; }

.seg { display: inline-flex; gap: 2px; padding: 4px; border-radius: 13px; margin-left: 10px; }
.seg a, .seg button { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border: 0; border-radius: 9px; background: transparent;
  cursor: pointer; text-decoration: none; color: var(--label); font-weight: 600; font-size: 13.5px; }
.seg a:hover, .seg button:hover { background: rgba(var(--tint-rgb), .08); }
.seg .on { background: #fff; color: var(--tint); box-shadow: 0 1px 3px rgba(0, 0, 0, .1); }
.seg .ic { width: 17px; height: 17px; }
.seg.small { margin: 0; }
.me-chip { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px 0 5px; border-radius: 12px; cursor: pointer; font-weight: 600; font-size: 13.5px; max-width: 200px; }
.me-chip span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.av { flex: 0 0 auto; display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; color: #fff; font-size: 11px; font-weight: 700;
  letter-spacing: .02em; box-shadow: 0 0 0 2px rgba(255, 255, 255, .9); }
.av.more { background: #8e8e93; }
.chip { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 7px; border-radius: 6px; background: rgba(var(--tint-rgb), .1); color: var(--tint);
  font-size: 11.5px; font-weight: 650; margin-right: 6px; vertical-align: 1px; }
.chip .ic { width: 12px; height: 12px; }
.chip.ok { background: rgba(22, 150, 92, .12); color: #16965c; }
.menu hr { border: 0; height: 1px; background: var(--sep); margin: 5px 4px; }
.menu button.on { color: var(--tint); font-weight: 650; }
.menu .av { width: 22px; height: 22px; font-size: 10px; box-shadow: none; }
.menu .date-in { display: flex; align-items: center; gap: 8px; padding: 6px 10px; }
.menu .date-in input { flex: 1; height: 32px; border-radius: 8px; border: 1px solid rgba(60, 60, 67, .16); padding: 0 8px; background: #fff; }

.modal-bg { position: fixed; inset: 0; z-index: 150; display: grid; place-items: center; padding: 16px; background: rgba(20, 16, 40, .22);
  -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.modal { width: min(460px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: 22px; border-radius: 22px; display: flex; flex-direction: column; gap: 12px;
  background: var(--glass-pop); }
.modal.wide { width: min(720px, 100%); }
.modal h2 { margin: 0; font-size: 19px; display: flex; align-items: center; gap: 9px; letter-spacing: -.01em; }
.modal h2 .ic { color: var(--tint); }
.mbtns { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; }
.row-f { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-weight: 600; }
.plist { display: flex; flex-direction: column; gap: 2px; max-height: 320px; overflow: auto; border-top: 1px solid var(--sep); padding-top: 8px; }
.plist .prow { display: flex; align-items: center; gap: 10px; padding: 6px 2px; }
.plist .nm { flex: 1; font-weight: 550; }
.plist select { height: 32px; border-radius: 9px; border: 1px solid rgba(60, 60, 67, .16); background: #fff; padding: 0 8px; }
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.tpl { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 14px; border-radius: 14px; border: 1.5px solid rgba(60, 60, 67, .12);
  background: rgba(255, 255, 255, .7); cursor: pointer; text-align: left; transition: border-color .15s, background .15s; }
.tpl:hover { border-color: rgba(var(--tint-rgb), .35); }
.tpl.on { border-color: var(--tint); background: rgba(var(--tint-rgb), .07); }
.tpl .ic { color: var(--tint); width: 24px; height: 24px; margin-bottom: 4px; }
.tpl span { font-size: 12.5px; line-height: 1.35; }
.cred { margin: 0; padding: 12px 14px; border-radius: 12px; background: rgba(60, 60, 67, .07); font: 500 14px/1.5 ui-monospace, Consolas, monospace; white-space: pre-wrap; user-select: all; }

.task-tools { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.task-tools .fill { flex: 1; }
.tog { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; cursor: pointer; }
.tgroup { margin-bottom: 20px; }
.tgroup h3 { margin: 0 0 8px 4px; font-size: 15px; }
.tgroup.late h3 { color: var(--red-ios); }
.tlist { border-radius: 18px; overflow: hidden; }
.task-row { display: flex; align-items: center; gap: 12px; padding: 11px 14px; cursor: pointer; border-top: 1px solid rgba(60, 60, 67, .08); }
.task-row:first-child { border-top: 0; }
.task-row:hover { background: rgba(var(--tint-rgb), .05); }
.task-row .tt { flex: 1; min-width: 0; }
.task-row .tx { font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-row .tm { font-size: 12.5px; display: flex; align-items: center; gap: 4px; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-row .tm .ic { width: 13px; height: 13px; }
.task-row.done .tx { text-decoration: line-through; color: var(--label-2); }
.task-row .go { width: 16px; height: 16px; color: var(--label-2); }
.chk { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 50%; border: 2px solid rgba(60, 60, 67, .35); background: #fff; cursor: pointer; display: grid; place-items: center; padding: 0; }
.chk:hover { border-color: #16965c; }
.task-row.done .chk { background: #16965c; border-color: #16965c; color: #fff; }
.chk .ic { width: 15px; height: 15px; stroke-width: 3; }
.due { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 600; color: var(--label-2); white-space: nowrap; }
.due .ic { width: 14px; height: 14px; }
.due.late { color: var(--red-ios); }
.due.today { color: #c26e00; }

.ptable { border-radius: 18px; overflow: hidden; }
.ptable .prow { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-top: 1px solid rgba(60, 60, 67, .08); }
.ptable .prow:first-child { border-top: 0; }
.ptable .prow.off { opacity: .5; }
.ptable .pn { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ptable .pn span { font-size: 12.5px; }
.ptable .pc { min-width: 120px; }
.ptable .more { width: 32px; height: 32px; border: 0; border-radius: 9px; background: transparent; cursor: pointer; display: grid; place-items: center; }
.ptable .more:hover { background: rgba(var(--tint-rgb), .09); }

/* ───────────── доска: задачи, картинки, комментарии, курсоры ───────────── */
.it.task { background: #fff; border-radius: 10px; box-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 6px 16px rgba(30, 20, 60, .1); display: flex; flex-direction: column;
  padding: 12px 12px 11px 44px; overflow: hidden; }
.it.task .tk-strip { position: absolute; left: 0; top: 0; bottom: 0; width: 5px; }
.it.task .tk-done { position: absolute; left: 14px; top: 11px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid rgba(60, 60, 67, .4); background: #fff;
  cursor: pointer; padding: 0; display: grid; place-items: center; color: #fff; }
.it.task .tk-done:hover { border-color: #16965c; }
.it.task.done .tk-done { background: #16965c; border-color: #16965c; }
.it.task .tk-done .ic { width: 14px; height: 14px; stroke-width: 3; }
.it.task .txt { height: auto; padding: 1px 0 0; font-size: 15px; font-weight: 550; justify-content: flex-start; text-align: left; overflow: visible; min-height: 22px; line-height: 1.35; }
.it.task.done .txt { text-decoration: line-through; color: var(--label-2); }
.it.task .tk-foot { margin-top: auto; padding-top: 10px; display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 550; color: var(--label-2); min-width: 0; }
.it.task .tk-who { display: inline-flex; align-items: center; gap: 6px; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--label); }
.it.task .tk-who.none { color: var(--label-2); font-weight: 450; }
.it.task .tk-who .ic { width: 15px; height: 15px; }
.it.task .tk-who .av { width: 20px; height: 20px; font-size: 9px; box-shadow: none; }
.it.task .tk-due { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; padding: 2px 7px; border-radius: 6px; background: rgba(60, 60, 67, .07); white-space: nowrap; }
.it.task .tk-due .ic { width: 13px; height: 13px; }
.it.task .tk-due.late { background: rgba(255, 59, 48, .12); color: var(--red-ios); }
.it.task .tk-due.today { background: rgba(232, 116, 44, .14); color: #c26e00; }
.it.image img { display: block; width: 100%; height: 100%; object-fit: fill; pointer-events: none; border-radius: 2px; }
.it.comment { overflow: visible; }
.it.comment .pin { width: 32px; height: 32px; transform: scale(var(--pz, 1)); transform-origin: 0 0; border-radius: 50% 50% 50% 4px; background: var(--tint);
  box-shadow: 0 0 0 2px #fff, 0 4px 12px rgba(30, 20, 60, .3); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 12px; cursor: pointer; }
.it.comment .pin .ic { width: 16px; height: 16px; stroke-width: 3; }
.it.comment.resolved .pin { background: #16965c; opacity: .55; }
.it.flash { animation: flash 1.6s ease 2; }
@keyframes flash { 0%, 100% { outline: 0 solid transparent; } 40% { outline: calc(4px / var(--z, 1)) solid rgba(var(--tint-rgb), .55); outline-offset: calc(4px / var(--z, 1)); } }

.ctx .lbl.wide { display: inline-flex; gap: 5px; align-items: center; max-width: 170px; padding: 0 9px; }
.ctx .lbl.wide span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ctx .lbl.wide .ic { width: 16px; height: 16px; }
.ro-badge { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--label-2); white-space: nowrap; }
.ro-badge .ic { width: 15px; height: 15px; }
.peer-avs { display: inline-flex; padding-left: 4px; }
.peer-avs .av { width: 26px; height: 26px; margin-left: -6px; }
.peer-avs:empty { display: none; }
.tb-head .share { width: auto !important; display: inline-flex !important; gap: 6px; padding: 0 12px; font-weight: 600; font-size: 13px; color: var(--tint);
  background: rgba(var(--tint-rgb), .1) !important; }
.tb-head .share .ic { width: 16px; height: 16px; }

.peers { position: absolute; left: 0; top: 0; pointer-events: none; z-index: 2000000002; }
.cur { position: absolute; left: 0; top: 0; transition: transform .9s linear; }
.cur-in { transform: scale(var(--pz, 1)); transform-origin: 0 0; display: flex; align-items: flex-start; }
.cur-in span { margin: 14px 0 0 -2px; padding: 3px 8px; border-radius: 8px; color: #fff; font-size: 12px; font-weight: 650; white-space: nowrap; box-shadow: 0 2px 6px rgba(0, 0, 0, .18); }
.peer-edit { position: absolute; outline: calc(2px / var(--z, 1)) solid var(--pc); border-radius: 4px; }
.peer-edit span { position: absolute; left: 0; bottom: 100%; margin-bottom: calc(4px / var(--z, 1)); transform: scale(var(--pz, 1)); transform-origin: 0 100%; white-space: nowrap;
  padding: 2px 7px; border-radius: 6px; background: var(--pc); color: #fff; font-size: 11.5px; font-weight: 650; }

.cpop { position: absolute; z-index: 14; width: 320px; max-height: min(460px, calc(100vh - 100px)); display: flex; flex-direction: column; border-radius: 18px; padding: 10px;
  background: var(--glass-pop); user-select: text; -webkit-user-select: text; }
.cp-head { display: flex; align-items: center; gap: 6px; padding: 0 2px 8px 6px; }
.cp-head .fill { flex: 1; }
.cp-head button { width: 30px; height: 30px; border: 0; border-radius: 9px; background: transparent; cursor: pointer; display: grid; place-items: center; }
.cp-head button:hover { background: rgba(var(--tint-rgb), .09); }
.cp-head .ic { width: 17px; height: 17px; }
.cp-list { overflow: auto; display: flex; flex-direction: column; gap: 10px; padding: 0 4px 8px; }
.cp-msg { display: flex; gap: 9px; }
.cp-msg .av { width: 26px; height: 26px; box-shadow: none; }
.cp-who { display: flex; gap: 8px; align-items: baseline; font-size: 13px; }
.cp-who .muted { font-size: 11.5px; }
.cp-t { font-size: 14px; line-height: 1.4; white-space: pre-wrap; word-break: break-word; }
.cp-new { display: flex; gap: 6px; align-items: flex-end; border-top: 1px solid var(--sep); padding-top: 8px; }
.cp-new textarea { flex: 1; resize: none; border: 1px solid rgba(60, 60, 67, .16); border-radius: 11px; padding: 8px 10px; background: #fff; outline: none; font-size: 14px; max-height: 140px; }
.cp-new textarea:focus { border-color: rgba(var(--tint-rgb), .6); }
.cp-new button { width: 36px; height: 36px; border: 0; border-radius: 11px; cursor: pointer; display: grid; place-items: center; color: #fff; background: var(--tint); }
.cp-new .ic { width: 17px; height: 17px; }

@media (max-width: 700px) {
  .top { flex-wrap: wrap; }
  .seg { margin-left: 0; order: 5; }
  .seg a span, .btn span { display: none; }
  .ptable .pc { display: none; }
  .tb-head .share span, .ro-badge { display: none; }
}

/* ───────────── 03.11.2026: документы — редактор в духе Notion (панель справа, на весь экран, страница по ссылке) ───────────── */
.btn.small { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 10px; }
.ib { height: 34px; min-width: 34px; flex: 0 0 auto; border: 0; border-radius: 10px; background: transparent; cursor: pointer; display: inline-flex;
  align-items: center; justify-content: center; gap: 6px; color: var(--label); font-weight: 600; font-size: 13px; padding: 0 8px; }
.ib:hover { background: rgba(var(--tint-rgb), .09); }
.ib .ic { width: 18px; height: 18px; }
.ib.wide span { white-space: nowrap; }
.fill { flex: 1; }

.docpanel { position: absolute; z-index: 13; top: 10px; right: 10px; bottom: 10px; width: var(--dpw, 640px); max-width: calc(100vw - 20px);
  border-radius: 20px; background: #fff; box-shadow: 0 0 0 1px rgba(60, 60, 67, .12), 0 18px 48px rgba(30, 20, 60, .18);
  display: flex; user-select: text; -webkit-user-select: text; touch-action: auto; overflow: hidden; }
.docpanel.full { top: 0; right: 0; bottom: 0; left: 0; width: auto; max-width: none; border-radius: 0; z-index: 30; box-shadow: none; }
.docpanel .dp-grip { position: absolute; left: 0; top: 0; bottom: 0; width: 7px; cursor: ew-resize; z-index: 5; }
.docpanel .dp-grip:hover { background: linear-gradient(90deg, rgba(var(--tint-rgb), .25), transparent); }
.docpanel.full .dp-grip { display: none; }
.docpanel .dp-in { flex: 1; min-width: 0; display: flex; }
.board.with-docs .tb-undo, .board.with-docs .tb-zoom { right: calc(min(var(--dpw, 640px), 100vw - 20px) + 24px); }
.board.with-docs .tb-head { max-width: calc(100vw - min(var(--dpw, 640px), 100vw - 20px) - 230px); }
.loading-in { margin: auto; padding: 30px; text-align: center; }

.doc { flex: 1; min-width: 0; display: flex; flex-direction: column; height: 100%; background: #fff; }
.doc-head { display: flex; align-items: center; gap: 4px; padding: 8px 10px 8px 12px; min-height: 52px; }
.doc-ic { display: grid; place-items: center; width: 30px; height: 30px; color: var(--tint); }
.doc-ic .ic { width: 20px; height: 20px; }
.doc-crumb { font-size: 13.5px; font-weight: 550; color: var(--label-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40%; padding: 0 4px; }
.dl-h { font-size: 15px; }
.doc-avs { display: inline-flex; padding: 0 6px 0 10px; }
.doc-avs .av { width: 26px; height: 26px; margin-left: -6px; font-size: 10.5px; }
.doc-avs:empty { display: none; }
.doc-save { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--label-2); white-space: nowrap; padding: 0 6px; }
.doc-save .ic { width: 14px; height: 14px; }
.doc-save.err { color: var(--red-ios); }

/* страница документа */
.doc-scroll { position: relative; flex: 1; min-height: 0; overflow: auto; }
.doc-page { max-width: 760px; margin: 0 auto; padding: 18px 48px 30vh; }
.docpanel:not(.full) .doc-page { padding: 8px 36px 30vh; }
.doc .doc-title { display: block; width: 100%; border: 0; outline: none; resize: none; overflow: hidden; background: transparent; padding: 0; margin: 18px 0 16px;
  font: 750 40px/1.2 "InterVariable", "Segoe UI", sans-serif; letter-spacing: -.025em; color: #1c1c1e; }
.docpanel:not(.full) .doc .doc-title { font-size: 32px; margin-top: 10px; }
.docpanel:not(.full) .nt-content h1 { font-size: 24px; } .docpanel:not(.full) .nt-content h2 { font-size: 20px; } .docpanel:not(.full) .nt-content h3 { font-size: 17px; }
.doc .doc-title::placeholder { color: rgba(60, 60, 67, .25); }

.nt-content { outline: none; font: 400 16px/1.7 "InterVariable", "Segoe UI", sans-serif; color: #2b2b30; letter-spacing: -.003em; caret-color: var(--tint);
  overflow-wrap: break-word; min-height: 40vh; padding-bottom: 20px; }
.nt-content > * + * { margin-top: 4px; }
.nt-content p { margin: 0; padding: 2px 0; }
.nt-content h1, .nt-content h2, .nt-content h3 { color: #1c1c1e; letter-spacing: -.02em; line-height: 1.3; margin: 0; }
.nt-content h1 { font-size: 28px; font-weight: 750; padding-top: 26px; padding-bottom: 4px; }
.nt-content h2 { font-size: 23px; font-weight: 700; padding-top: 20px; padding-bottom: 2px; }
.nt-content h3 { font-size: 19px; font-weight: 650; padding-top: 14px; }
.nt-content > :first-child { padding-top: 0; }
.nt-content strong { font-weight: 650; color: #1c1c1e; }
.nt-content a { color: #0a6bdc; text-decoration: underline; text-decoration-color: rgba(10, 107, 220, .35); text-underline-offset: 2px; cursor: pointer; }
.nt-content code { font: .87em/1 ui-monospace, "Cascadia Mono", Consolas, monospace; background: rgba(135, 131, 120, .15); color: #c4314b; padding: .2em .4em; border-radius: 5px; }
.nt-content pre { background: #f7f6f3; border-radius: 10px; padding: 16px 18px; margin: 8px 0; overflow-x: auto; }
.nt-content pre code { background: none; color: #37352f; padding: 0; font-size: 13.5px; line-height: 1.6; }
.nt-content ul, .nt-content ol { padding-left: 1.6em; margin: 2px 0; }
.nt-content li { padding: 1px 0; }
.nt-content li > p { padding: 1px 0; }
.nt-content li::marker { color: #6b6b70; }
.nt-content ul ul { list-style-type: circle; } .nt-content ul ul ul { list-style-type: square; }
.nt-content ul[data-type="taskList"] { list-style: none; padding-left: 2px; }
.nt-content ul[data-type="taskList"] li { display: flex; align-items: flex-start; gap: 8px; }
.nt-content ul[data-type="taskList"] li > label { flex: 0 0 auto; margin-top: 5px; user-select: none; }
.nt-content ul[data-type="taskList"] li > div { flex: 1; min-width: 0; }
.nt-content ul[data-type="taskList"] input[type=checkbox] { width: 17px; height: 17px; margin: 0; accent-color: #16965c; cursor: pointer; }
.nt-content ul[data-type="taskList"] li[data-checked="true"] > div { color: #8e8e93; text-decoration: line-through; text-decoration-color: rgba(142, 142, 147, .6); }
.nt-content blockquote { margin: 6px 0; padding: 2px 0 2px 16px; border-left: 3px solid #1c1c1e; color: #3a3a3f; }
.nt-content hr { border: 0; border-top: 1px solid rgba(55, 53, 47, .16); margin: 18px 0; }
.nt-content img { display: block; max-width: 100%; height: auto; border-radius: 6px; margin: 8px 0; }
.nt-content img.ProseMirror-selectednode { outline: 2px solid var(--tint); outline-offset: 2px; }
.nt-content table { border-collapse: collapse; margin: 10px 0; width: 100%; table-layout: fixed; overflow: hidden; }
.nt-content th, .nt-content td { border: 1px solid rgba(55, 53, 47, .16); padding: 7px 10px; vertical-align: top; text-align: left; position: relative; min-width: 60px; }
.nt-content th { background: #f7f6f3; font-weight: 650; color: #37352f; }
.nt-content th p, .nt-content td p { padding: 0; }
.nt-content .selectedCell::after { content: ""; position: absolute; inset: 0; background: rgba(var(--tint-rgb), .12); pointer-events: none; }
.nt-content p.is-empty::before, .nt-content h1.is-empty::before, .nt-content h2.is-empty::before, .nt-content h3.is-empty::before {
  content: attr(data-placeholder); float: left; height: 0; pointer-events: none; color: rgba(55, 53, 47, .32); }
.doc.ro .nt-content p.is-empty::before { content: none; }
.nt-content ::selection { background: rgba(var(--tint-rgb), .2); }
.ProseMirror-gapcursor { display: none; pointer-events: none; position: absolute; }
.ProseMirror-gapcursor::after { content: ""; display: block; position: absolute; top: -2px; width: 20px; border-top: 1px solid #1c1c1e; animation: pmcur 1.1s steps(2, start) infinite; }
.ProseMirror-focused .ProseMirror-gapcursor { display: block; }
@keyframes pmcur { to { visibility: hidden; } }

/* курсоры коллег */
.rc { position: relative; display: inline-block; width: 0; height: 1.2em; vertical-align: text-bottom; border-left: 2px solid var(--c); margin: 0 -1px; pointer-events: none; }
.rc i { position: absolute; left: -2px; bottom: 100%; font: 650 10.5px/1.55 "InterVariable", sans-serif; font-style: normal; color: #fff; background: var(--c);
  padding: 0 5px; border-radius: 4px 4px 4px 0; white-space: nowrap; user-select: none; }

/* панель над выделением, меню «/», панель таблицы */
.bubble, .tbar, .slash { position: absolute; z-index: 20; background: #fff; border-radius: 12px; box-shadow: 0 0 0 1px rgba(15, 15, 15, .06), 0 6px 18px rgba(15, 15, 15, .14); }
.bubble { display: flex; align-items: center; gap: 1px; padding: 4px; }
.bubble button, .tbar button { height: 30px; min-width: 30px; border: 0; border-radius: 8px; background: transparent; cursor: pointer; display: grid; place-items: center; color: #37352f; padding: 0 6px; }
.bubble button:hover, .tbar button:hover { background: rgba(55, 53, 47, .08); }
.bubble button.on { color: var(--tint); background: rgba(var(--tint-rgb), .12); }
.bubble .ic { width: 16px; height: 16px; }
.bubble .sep { width: 1px; height: 18px; background: rgba(55, 53, 47, .14); margin: 0 3px; }
.bubble .bb-in { width: 240px; height: 30px; border: 0; outline: none; padding: 0 8px; font-size: 13.5px; background: transparent; }
.tbar { display: flex; gap: 2px; padding: 4px; }
.tbar button { font-size: 12.5px; font-weight: 550; display: inline-flex; padding: 0 9px; }
.tbar button.danger { color: var(--red-ios); }
.slash { width: 300px; max-height: 340px; overflow: auto; padding: 6px; }
.slash .sl-h { font-size: 11.5px; font-weight: 600; color: #8e8e93; padding: 6px 8px 4px; }
.slash button { display: flex; align-items: center; gap: 10px; width: 100%; border: 0; background: transparent; border-radius: 8px; padding: 6px 8px; cursor: pointer; text-align: left; }
.slash button.on, .slash button:hover { background: rgba(55, 53, 47, .08); }
.slash .sl-ic { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 8px; border: 1px solid rgba(55, 53, 47, .14); display: grid; place-items: center; background: #fff; color: #37352f; }
.slash .sl-ic .ic { width: 18px; height: 18px; }
.slash b { display: block; font-size: 14px; font-weight: 550; color: #1c1c1e; }
.slash .muted { font-size: 12px; }

/* список документов доски */
.dl-list { flex: 1; overflow: auto; padding: 8px; }
.dl-row { display: flex; align-items: center; gap: 12px; padding: 10px 10px; border-radius: 12px; cursor: pointer; outline: none; }
.dl-row:hover, .dl-row:focus { background: rgba(var(--tint-rgb), .07); }
.dl-row > .ic { color: var(--tint); }
.dl-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.dl-t b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dl-empty { padding: 40px 20px; text-align: center; }

/* окна: ссылка и история */
.share-modes { display: flex; flex-direction: column; gap: 6px; }
.share-modes .sm { display: grid; grid-template-columns: 20px 1fr; column-gap: 8px; align-items: center; padding: 10px 12px; border-radius: 12px;
  border: 1.5px solid rgba(60, 60, 67, .12); cursor: pointer; background: rgba(255, 255, 255, .7); }
.share-modes .sm:has(input:checked) { border-color: var(--tint); background: rgba(var(--tint-rgb), .06); }
.share-modes .sm span { grid-column: 2; }
.share-url { display: flex; gap: 8px; }
.share-url input { flex: 1; min-width: 0; height: 38px; padding: 0 10px; border-radius: 10px; border: 1px solid rgba(60, 60, 67, .16); background: #fff; font-size: 13px; }
.mbtns .fill { flex: 1; }
.hist { display: grid; grid-template-columns: 220px 1fr; gap: 12px; height: min(60vh, 520px); }
.hist-list { overflow: auto; display: flex; flex-direction: column; gap: 4px; }
.hist-list button { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 8px 10px; border: 0; border-radius: 10px; background: transparent; cursor: pointer; text-align: left; }
.hist-list button:hover { background: rgba(var(--tint-rgb), .07); }
.hist-list button.on { background: rgba(var(--tint-rgb), .13); }
.hist-view { overflow: auto; border: 1px solid var(--sep); border-radius: 12px; padding: 14px 18px; background: #fff; }

/* Markdown-просмотр (снимки в «Истории») — тем же шрифтом */
.md { font: 400 15px/1.65 "InterVariable", "Segoe UI", sans-serif; color: #2b2b30; overflow-wrap: break-word; }
.md > :first-child { margin-top: 0; }
.md h1, .md h2, .md h3, .md h4 { line-height: 1.25; letter-spacing: -.015em; margin: 1.2em 0 .4em; font-weight: 700; color: #1c1c1e; }
.md h1 { font-size: 1.7em; } .md h2 { font-size: 1.35em; } .md h3 { font-size: 1.15em; }
.md p { margin: 0 0 .7em; }
.md a { color: #0a6bdc; }
.md ul, .md ol { margin: 0 0 .7em; padding-left: 1.6em; }
.md li:has(> input[type=checkbox]) { list-style: none; margin-left: -1.4em; }
.md input[type=checkbox] { margin: 0 .5em 0 0; accent-color: #16965c; }
.md blockquote { margin: 0 0 .8em; padding: .1em 1em; border-left: 3px solid #1c1c1e; color: #3a3a3f; }
.md code { font: .87em ui-monospace, Consolas, monospace; background: rgba(135, 131, 120, .15); color: #c4314b; padding: .1em .35em; border-radius: 5px; }
.md pre { background: #f7f6f3; padding: 12px 14px; border-radius: 10px; overflow: auto; }
.md pre code { background: none; color: #37352f; padding: 0; }
.md table { border-collapse: collapse; margin: 0 0 1em; }
.md th, .md td { border: 1px solid rgba(55, 53, 47, .16); padding: 6px 10px; text-align: left; }
.md th { background: #f7f6f3; }
.md hr { border: 0; border-top: 1px solid rgba(55, 53, 47, .16); margin: 1.2em 0; }
.md img { max-width: 100%; border-radius: 6px; }

/* карточка документа на доске */
.it.doc { background: #fff; border-radius: 12px; box-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 6px 16px rgba(30, 20, 60, .1); border: 1px solid rgba(60, 60, 67, .1); cursor: pointer; height: auto; }
.it.doc.open { box-shadow: 0 0 0 2px var(--tint), 0 6px 16px rgba(30, 20, 60, .12); }
.it.doc .dk { display: flex; gap: 12px; align-items: center; height: 100%; padding: 12px 14px; }
.it.doc .dk-ic { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #8f7bff, #5b45e0); }
.it.doc .dk-ic .ic { width: 22px; height: 22px; }
.it.doc .dk-tx { min-width: 0; }
.it.doc .dk-t { font-weight: 700; font-size: 15px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.it.doc .dk-s { font-size: 11.5px; color: var(--label-2); margin-top: 3px; }
.tb-head .docs-b { color: var(--label); background: rgba(60, 60, 67, .06) !important; }

/* страница документа по ссылке */
body.pubdoc { overflow: hidden; background: #fff; }
.pub-wrap { position: fixed; inset: 0; display: flex; background: #fff; }
.pub-wrap .pub-edit { margin-right: 4px; }
@media (max-width: 700px) {
  .docpanel { top: 0; right: 0; bottom: 0; width: 100vw; max-width: none; border-radius: 0; }
  .doc-page, .docpanel:not(.full) .doc-page { padding: 6px 18px 30vh; }
  .doc .doc-title, .docpanel:not(.full) .doc .doc-title { font-size: 28px; }
  .doc-head .doc-save span, .ib.wide span, .doc-crumb { display: none; }
  .hist { grid-template-columns: 1fr; height: auto; }
  .tb-head .docs-b span { display: none; }
}

/* ───────────── 03.11.2026: связи, список задач, агент ───────────── */
.hover-ring { outline: calc(2.5px / var(--z, 1)) solid rgba(var(--tint-rgb), .85); background: rgba(var(--tint-rgb), .07); border-radius: 6px; }
.rel-ring { position: absolute; pointer-events: none; border-radius: 6px; outline: calc(2px / var(--z, 1)) dashed rgba(var(--tint-rgb), .7);
  outline-offset: calc(4px / var(--z, 1)); }
.rel-ring::after { content: attr(data-l); position: absolute; left: calc(-4px / var(--z, 1)); bottom: 100%; margin-bottom: calc(8px / var(--z, 1));
  font: 650 calc(11px / var(--z, 1))/1 Inter, system-ui, sans-serif; color: #fff; background: var(--tint); white-space: nowrap;
  padding: calc(3px / var(--z, 1)) calc(6px / var(--z, 1)); border-radius: calc(5px / var(--z, 1)); }
.links g.rel .ln { stroke: var(--tint); }
.it.task .tk-wait { display: inline-flex; align-items: center; gap: 3px; padding: 2px 7px; border-radius: 6px; white-space: nowrap; flex: 0 0 auto;
  background: rgba(232, 116, 44, .14); color: #c26e00; cursor: help; }
.it.task .tk-wait[hidden] { display: none; }
.it.task .tk-wait .ic { width: 13px; height: 13px; }
.it.task .tk-wait + .tk-due { margin-left: 0; }
.it.task .tk-who + .tk-wait { margin-left: auto; }
.it.task .tk-foot:has(.tk-wait:not([hidden])) .tk-who.none span { display: none; }
.tb-head .share.on { background: rgba(var(--tint-rgb), .2) !important; }
.tb-head .ag-b { color: #fff; background: linear-gradient(135deg, rgba(var(--tint-rgb), .8), rgba(var(--tint-rgb), 1)) !important; }
.tb-head .ag-b.on { box-shadow: 0 0 0 2px rgba(var(--tint-rgb), .3); }

.sidepanel { position: absolute; z-index: 13; top: 10px; right: 10px; bottom: 10px; width: var(--spw, 420px); max-width: calc(100vw - 20px);
  border-radius: 20px; background: #fff; box-shadow: 0 0 0 1px rgba(60, 60, 67, .12), 0 18px 48px rgba(30, 20, 60, .18);
  display: flex; user-select: text; -webkit-user-select: text; touch-action: auto; overflow: hidden; }
@media (min-width: 701px) { .sidepanel { bottom: 80px; } }   /* внизу справа — кнопка «Сообщить о проблеме» */
.sidepanel .dp-grip { position: absolute; left: 0; top: 0; bottom: 0; width: 7px; cursor: ew-resize; z-index: 5; }
.sidepanel .dp-grip:hover { background: linear-gradient(90deg, rgba(var(--tint-rgb), .25), transparent); }
.sidepanel .sp-in { flex: 1; min-width: 0; display: flex; }
.board.with-side .tb-undo, .board.with-side .tb-zoom { right: calc(min(var(--spw, 420px), 100vw - 20px) + 24px); }
.board.with-side .tb-head { max-width: calc(100vw - min(var(--spw, 420px), 100vw - 20px) - 230px); }
.sp { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sp-head { display: flex; align-items: center; gap: 8px; padding: 10px 10px 8px 16px; min-height: 52px; font-size: 15px; }
.sp-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: var(--tint); background: rgba(var(--tint-rgb), .1); }
.sp-ic .ic { width: 18px; height: 18px; }
.sp-ic.ag-ic { color: #fff; background: linear-gradient(135deg, #a58bff, #6a4ff0); }

/* список задач */
.tl-bar { display: flex; align-items: center; gap: 10px; padding: 0 16px 8px; flex-wrap: wrap; }
.tl-bar .seg { background: rgba(60, 60, 67, .06); }
.tl-bar .seg button { height: 28px; padding: 0 10px; font-size: 13px; font-weight: 600; }
.tl-bar .tog { margin-left: auto; font-size: 13px; color: var(--label-2); }
.tl-prog { height: 4px; margin: 2px 16px 0; border-radius: 2px; background: rgba(60, 60, 67, .1); overflow: hidden; }
.tl-prog i { display: block; height: 100%; background: #16965c; border-radius: 2px; transition: width .3s var(--ease); }
.tl-sum { padding: 6px 16px 4px; min-height: 22px; }
.tl-list { flex: 1; overflow: auto; padding: 0 8px 12px; }
.tl-group h4 { margin: 14px 8px 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--label-2); font-weight: 700; }
.tl-row { display: flex; gap: 10px; padding: 9px 8px; border-radius: 12px; cursor: pointer; }
.tl-row:hover { background: rgba(var(--tint-rgb), .05); }
.tl-row.on { background: rgba(var(--tint-rgb), .09); }
.tl-row .chk { width: 22px; height: 22px; margin-top: 1px; }
.tl-row.done .chk { background: #16965c; border-color: #16965c; color: #fff; }
.tl-row .chk:disabled { cursor: default; }
.tl-main { flex: 1; min-width: 0; }
.tl-tx { font-weight: 560; font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
.tl-row.done .tl-tx { text-decoration: line-through; color: var(--label-2); }
.tl-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.tl-meta button, .tl-wait { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 8px; border: 0; border-radius: 7px; font-size: 12.5px;
  font-weight: 600; background: rgba(60, 60, 67, .06); color: var(--label); cursor: pointer; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.tl-meta button:hover:not(:disabled) { background: rgba(var(--tint-rgb), .12); }
.tl-meta button:disabled { cursor: default; }
.tl-meta button.none { color: var(--label-2); font-weight: 500; }
.tl-meta .ic { width: 14px; height: 14px; }
.tl-meta .av { width: 18px; height: 18px; font-size: 8.5px; box-shadow: none; }
.tl-due.late { background: rgba(255, 59, 48, .12); color: var(--red-ios); }
.tl-due.today { background: rgba(232, 116, 44, .14); color: #c26e00; }
.tl-wait { background: rgba(232, 116, 44, .14); color: #c26e00; cursor: default; }
.tl-rel { display: flex; align-items: baseline; gap: 5px; margin-top: 5px; font-size: 12.5px; color: var(--label-2); line-height: 1.4; }
.tl-rel .ic { width: 13px; height: 13px; flex: 0 0 auto; align-self: center; }
.tl-rel > span { flex: 0 0 auto; }
.tl-rel > .tl-l { flex: 1 1 auto; min-width: 0; }
.tl-rel a { color: var(--label); text-decoration: none; border-bottom: 1px solid rgba(60, 60, 67, .2); cursor: pointer; overflow-wrap: anywhere; }
.tl-rel a:hover { color: var(--tint); border-color: var(--tint); }
.tl-rel a.open { color: #c26e00; border-color: rgba(232, 116, 44, .4); }
.tl-row.done .tl-rel a.open { color: var(--label); border-color: rgba(60, 60, 67, .2); }
.tl-rel a.done { text-decoration: line-through; }
.tl-empty { padding: 30px 16px; text-align: center; }
.tl-add { display: flex; align-items: center; gap: 8px; margin: 0 12px 12px; padding: 0 12px; height: 42px; border-radius: 12px; background: rgba(60, 60, 67, .06); }
.tl-add:focus-within { background: #fff; box-shadow: 0 0 0 2px rgba(var(--tint-rgb), .35); }
.tl-add .ic { width: 18px; height: 18px; color: var(--tint); }
.tl-add input { flex: 1; border: 0; outline: 0; background: transparent; font-size: 14px; }

/* агент */
.ag-list { flex: 1; overflow: auto; padding: 6px 14px 14px; display: flex; flex-direction: column; gap: 12px; }
.ag-intro { margin: auto 0; padding: 10px 6px; text-align: center; }
.ag-hi { width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 16px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #a58bff, #6a4ff0); box-shadow: 0 8px 20px rgba(106, 79, 240, .3); }
.ag-hi .ic { width: 28px; height: 28px; }
.ag-intro b { font-size: 16px; }
.ag-intro p { font-size: 13.5px; line-height: 1.5; margin: 8px 0 14px; }
.ag-ex { display: flex; flex-direction: column; gap: 6px; text-align: left; }
.ag-ex button { border: 1px solid rgba(60, 60, 67, .14); background: #fff; border-radius: 12px; padding: 9px 12px; font-size: 13px; line-height: 1.4; cursor: pointer; text-align: left; }
.ag-ex button:hover { border-color: rgba(var(--tint-rgb), .5); background: rgba(var(--tint-rgb), .04); }
.modal .ag-ex { margin: 10px 0 4px; }
.modal textarea { width: 100%; border: 1px solid rgba(60, 60, 67, .2); border-radius: 12px; padding: 10px 12px; resize: vertical; font-size: 14px; line-height: 1.45; outline: 0; }
.modal textarea:focus { border-color: rgba(var(--tint-rgb), .6); box-shadow: 0 0 0 3px rgba(var(--tint-rgb), .15); }
.ag-msg { max-width: 92%; }
.ag-msg.me { align-self: flex-end; }
.ag-msg .ag-b { padding: 10px 13px; border-radius: 16px; font-size: 14px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.ag-msg.me .ag-b { background: rgba(var(--tint-rgb), .12); border-bottom-right-radius: 5px; }
.ag-msg.bot .ag-b { background: rgba(60, 60, 67, .06); border-bottom-left-radius: 5px; }
.ag-msg.err .ag-b { background: rgba(255, 59, 48, .09); color: #b3261e; }
.ag-msg.undone .ag-b { color: var(--label-2); }
.ag-by { font-size: 11.5px; margin: 4px 6px 0; }
.ag-msg.me .ag-by { text-align: right; }
.ag-sum { display: flex; align-items: flex-start; gap: 6px; margin: 6px 4px 0; font-size: 12.5px; font-weight: 600; color: #16965c; }
.ag-sum .ic { width: 15px; height: 15px; stroke-width: 2.6; flex: 0 0 auto; margin-top: 1px; }
.ag-msg.undone .ag-sum { color: var(--label-2); text-decoration: line-through; }
.ag-acts { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin: 8px 2px 0; }
.btn.small { height: 30px; padding: 0 11px; font-size: 13px; border-radius: 10px; gap: 6px; }
.btn.small .ic { width: 15px; height: 15px; }
.ag-undone { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--label-2); }
.ag-undone .ic { width: 14px; height: 14px; }
.ag-msg.busy .ag-b { display: flex; align-items: center; gap: 8px; }
.ag-dots { display: inline-flex; gap: 3px; }
.ag-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--tint); animation: agdot 1.2s infinite ease-in-out; }
.ag-dots i:nth-child(2) { animation-delay: .15s; }
.ag-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes agdot { 0%, 80%, 100% { opacity: .25; transform: scale(.8); } 40% { opacity: 1; transform: scale(1); } }
.ag-form { display: flex; align-items: flex-end; gap: 8px; margin: 0 12px; padding: 8px 8px 8px 14px; border-radius: 16px; background: rgba(60, 60, 67, .06); }
.ag-form:focus-within { background: #fff; box-shadow: 0 0 0 2px rgba(var(--tint-rgb), .35); }
.ag-form textarea { flex: 1; border: 0; outline: 0; background: transparent; resize: none; font-size: 14px; line-height: 1.45; padding: 5px 0; max-height: 200px; }
.ag-send { width: 34px; height: 34px; flex: 0 0 auto; border: 0; border-radius: 50%; display: grid; place-items: center; cursor: pointer; color: #fff;
  background: linear-gradient(135deg, rgba(var(--tint-rgb), .8), rgba(var(--tint-rgb), 1)); }
.ag-send:disabled { opacity: .4; cursor: default; }
.ag-send .ic { width: 18px; height: 18px; stroke-width: 2.6; }
.ag-note { padding: 6px 16px 12px; text-align: center; }
.task-row .tw { display: flex; align-items: center; gap: 4px; margin-top: 3px; font-size: 12.5px; color: #c26e00; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-row .tw .ic { width: 13px; height: 13px; flex: 0 0 auto; }
@media (max-width: 700px) {
  .sidepanel { top: 0; right: 0; bottom: 0; width: 100vw; max-width: none; border-radius: 0; }
  .tb-head .share span { display: none; }
  #ai span { display: none; }
}

/* ───────────── 03.11.2026 (вечер): панель свойств — свёрнутые меню; копия по Alt; группы ───────────── */
.ctx .pick { width: auto; min-width: 38px; padding: 0 5px 0 8px; display: inline-flex; align-items: center; gap: 3px; }
.ctx .pick[data-pop="more"] { width: 38px; padding: 0; justify-content: center; }
.ctx .pick .chev { width: 13px; height: 13px; opacity: .45; transition: transform .2s; }
.ctx .pick.on .chev { transform: rotate(180deg); opacity: .8; }
.ctx .pick .ic:not(.chev) { width: 19px; height: 19px; }
.ctx .pick .pk-t { font-size: 13px; font-weight: 650; min-width: 14px; text-align: center; }
.dotc { display: block; width: 22px; height: 22px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .14); box-sizing: border-box; }
.dotc.ring { border-width: 4px; background: #fff; }
.ctx-pop { position: absolute; left: 0; top: 0; z-index: 13; display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 16px; }
.ctx-pop button { width: 36px; height: 36px; border: 0; border-radius: 10px; background: transparent; cursor: pointer; display: grid; place-items: center;
  color: var(--label); transition: background .15s, transform .2s var(--spring-soft); }
.ctx-pop button:hover { background: rgba(var(--tint-rgb), .09); }
.ctx-pop button:active { transform: scale(.92); }
.ctx-pop button.on { background: rgba(var(--tint-rgb), .16); color: var(--tint); }
.ctx-pop .lbl { width: auto; min-width: 40px; padding: 0 9px; font-size: 13px; font-weight: 650; }
.ctx-pop .pk-row { display: flex; align-items: center; gap: 4px; }
.ctx-pop .pk-row .sep { width: 1px; height: 24px; background: var(--sep); margin: 0 4px; }
.ctx-pop .pk-grid { display: grid; grid-template-columns: repeat(4, 30px); gap: 9px; padding: 3px; }
.ctx-pop .swatch { width: 30px !important; height: 30px !important; margin: 0; }
.pk-w { display: block; width: 24px; height: 2px; border-radius: 2px; background: currentColor; }
.pk-w.dash { background: repeating-linear-gradient(90deg, currentColor 0 6px, transparent 6px 10px); }
.ctx .pick .pk-w { width: 20px; }
.ctx-pop .pk-menu { display: flex; flex-direction: column; min-width: 220px; }
.ctx-pop .pk-menu button { width: 100%; height: 36px; display: flex; align-items: center; gap: 10px; padding: 0 10px; text-align: left; }
.ctx-pop .pk-menu .ic { width: 17px; height: 17px; }
.ctx-pop .pk-menu kbd { margin-left: auto; font-family: inherit; font-size: 11.5px; font-weight: 600; color: var(--label-2); }
.ctx-pop .pk-menu .danger { color: var(--red-ios); }
.viewport.copying, .viewport.copying * { cursor: copy !important; }

/* ───────────── 03.11.2026 (вечер): документы — сворачивание, картинки, ссылка ───────────── */
/* подсветка выделенного, пока вводят адрес ссылки (фокус в поле) */
.nt-content .fake-sel { background: rgba(var(--tint-rgb), .2); border-radius: 2px; }
/* свёрнутые заголовки: стрелка в поле слева, видна при наведении; свёрнутый — стрелка всегда, повёрнута */
.nt-content > h1, .nt-content > h2, .nt-content > h3 { position: relative; }
.fold-btn { position: absolute; left: -26px; bottom: 0; width: 22px; height: 1.3em; display: grid; place-items: center; border-radius: 6px; color: #8e8e93;
  cursor: pointer; opacity: 0; transition: opacity .15s, background .15s; user-select: none; }
.fold-btn .ic { width: 16px; height: 16px; transform: rotate(90deg); transition: transform .15s; }
.nt-content > :is(h1, h2, h3):hover .fold-btn, .fold-btn.on { opacity: 1; }
.fold-btn:hover { background: rgba(55, 53, 47, .08); color: #37352f; }
.fold-btn.on .ic { transform: none; }
.nt-content .fold-hide { display: none !important; }
/* сворачиваемый блок (Tiptap Details): стрелка, заголовок, скрытый текст */
.nt-content .nt-toggle { display: flex; gap: 2px; margin: 2px 0 2px -4px; }
.nt-content .nt-toggle > button { flex: 0 0 auto; width: 24px; height: 27px; margin-top: 1px; border: 0; border-radius: 6px; background: transparent; color: #37352f;
  cursor: pointer; display: grid; place-items: center; }
.nt-content .nt-toggle > button:hover { background: rgba(55, 53, 47, .08); }
.nt-content .nt-toggle > button .ic { width: 16px; height: 16px; transition: transform .15s; }
.nt-content .nt-toggle.is-open > button .ic { transform: rotate(90deg); }
.nt-content .nt-toggle > div { flex: 1; min-width: 0; }
.nt-content .nt-toggle summary { display: block; list-style: none; padding: 2px 0; font-weight: 550; cursor: text; }
.nt-content .nt-toggle summary::-webkit-details-marker { display: none; }
.nt-content .nt-toggle [data-type="detailsContent"] > * + * { margin-top: 4px; }
.nt-content summary.is-empty::before, .nt-content [data-type="detailsContent"] p.is-empty::before {
  content: attr(data-placeholder); float: left; height: 0; pointer-events: none; color: rgba(55, 53, 47, .32); }
.doc.ro .nt-content summary.is-empty::before { content: none; }
/* картинка: положение, ширина, ручки по краям */
.nt-content figure.nt-img { position: relative; display: block; width: fit-content; max-width: 100%; margin: 8px auto; clear: both; }
.nt-content figure.nt-img img { display: block; max-width: 100%; height: auto; margin: 0; border-radius: 6px; }
.nt-content figure.nt-img[style*="width"] img { width: 100%; }
.nt-content figure.nt-img[data-align="left"] { margin-left: 0; margin-right: auto; }
.nt-content figure.nt-img[data-align="right"] { margin-left: auto; margin-right: 0; }
.nt-content figure.nt-img[data-align="wrapl"] { float: left; clear: none; margin: 6px 20px 8px 0; }
.nt-content figure.nt-img[data-align="wrapr"] { float: right; clear: none; margin: 6px 0 8px 20px; }
.nt-content > :is(h1, h2, h3, hr, table, pre, blockquote) { clear: both; }
.nt-content::after { content: ""; display: block; clear: both; }
.nt-content figure.nt-img.sel img { outline: 2px solid var(--tint); outline-offset: 2px; }
.img-h { position: absolute; top: 50%; width: 7px; height: 46px; max-height: 40%; transform: translateY(-50%); border-radius: 5px; background: rgba(255, 255, 255, .95);
  border: 1px solid rgba(0, 0, 0, .28); box-shadow: 0 1px 4px rgba(0, 0, 0, .25); cursor: ew-resize; opacity: 0; transition: opacity .15s; touch-action: none; }
.img-h.l { left: 8px; } .img-h.r { right: 8px; }
.nt-img:hover .img-h, .nt-img.sel .img-h, .nt-img.sizing .img-h { opacity: 1; }
.nt-img.sizing::after { content: attr(data-pct); position: absolute; right: 8px; top: 8px; padding: 2px 7px; border-radius: 6px; font: 600 12px/1.5 "InterVariable", sans-serif;
  color: #fff; background: rgba(28, 28, 30, .78); pointer-events: none; }
/* панель картинки */
.ibar { position: absolute; z-index: 20; display: flex; align-items: center; gap: 1px; padding: 4px; background: #fff; border-radius: 12px;
  box-shadow: 0 0 0 1px rgba(15, 15, 15, .06), 0 6px 18px rgba(15, 15, 15, .14); }
.ibar button { height: 30px; min-width: 30px; border: 0; border-radius: 8px; background: transparent; cursor: pointer; display: grid; place-items: center; color: #37352f; padding: 0 6px; }
.ibar button:hover { background: rgba(55, 53, 47, .08); }
.ibar button.on { color: var(--tint); background: rgba(var(--tint-rgb), .12); }
.ibar button.pct { font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ibar button.danger { color: var(--red-ios); }
.ibar .ic { width: 16px; height: 16px; }
.ibar .sep { width: 1px; height: 18px; background: rgba(55, 53, 47, .14); margin: 0 3px; }
/* окно обрезки */
.crop-wrap { display: flex; justify-content: center; padding: 10px; margin: 8px 0 10px; border-radius: 12px; background: #2b2b30; overflow: hidden; }
.crop-stage { position: relative; line-height: 0; touch-action: none; user-select: none; }
.crop-stage img { display: block; max-width: 100%; max-height: 58vh; }
.crop-rect { position: absolute; box-shadow: 0 0 0 9999px rgba(0, 0, 0, .55); outline: 1.5px solid #fff; cursor: move;
  background-image: linear-gradient(rgba(255,255,255,.35) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.35) 1px, transparent 1px);
  background-size: 33.34% 33.34%; background-position: -1px -1px; }
.crop-rect i { position: absolute; width: 14px; height: 14px; margin: -7px 0 0 -7px; background: #fff; border-radius: 3px; box-shadow: 0 1px 3px rgba(0, 0, 0, .4); }
.crop-rect i[data-h="nw"] { left: 0; top: 0; cursor: nwse-resize; } .crop-rect i[data-h="ne"] { left: 100%; top: 0; cursor: nesw-resize; }
.crop-rect i[data-h="se"] { left: 100%; top: 100%; cursor: nwse-resize; } .crop-rect i[data-h="sw"] { left: 0; top: 100%; cursor: nesw-resize; }
.crop-rect i[data-h="n"] { left: 50%; top: 0; cursor: ns-resize; } .crop-rect i[data-h="s"] { left: 50%; top: 100%; cursor: ns-resize; }
.crop-rect i[data-h="e"] { left: 100%; top: 50%; cursor: ew-resize; } .crop-rect i[data-h="w"] { left: 0; top: 50%; cursor: ew-resize; }
.crop-ratios { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.crop-ratios .chip { height: 30px; padding: 0 11px; border: 0; cursor: pointer; font: inherit; font-size: 13px; font-weight: 600; background: rgba(60, 60, 67, .08); color: var(--label); }
.crop-ratios .chip.on { background: rgba(var(--tint-rgb), .16); color: var(--tint); }
@media (max-width: 700px) { .fold-btn { left: -20px; width: 18px; } }

/* ───────────── 03.11.2026 (ночь): задачи из «@» в документе, цвет карточки документа ───────────── */
.nt-content .nt-task { display: inline-flex; align-items: center; gap: 5px; padding: 0 7px 0 4px; margin: 0 1px; border-radius: 7px; vertical-align: baseline;
  background: rgba(var(--tint-rgb), .1); color: var(--tint); font-weight: 600; font-size: .92em; line-height: 1.6; cursor: pointer; white-space: nowrap; user-select: none; }
.nt-content .nt-task:hover { background: rgba(var(--tint-rgb), .17); }
.nt-content .nt-task .tk-c { width: 13px; height: 13px; border-radius: 50%; border: 1.6px solid currentColor; display: grid; place-items: center; flex: 0 0 auto; }
.nt-content .nt-task .tk-c .ic { width: 9px; height: 9px; stroke-width: 3.5; }
.nt-content .nt-task em { font-style: normal; font-weight: 550; font-size: .9em; opacity: .8; }
.nt-content .nt-task.done { background: rgba(22, 150, 92, .12); color: #16965c; }
.nt-content .nt-task.done .tk-c { background: #16965c; border-color: #16965c; color: #fff; }
.nt-content .nt-task.late em { color: var(--red-ios); opacity: 1; }
.nt-content .nt-task.gone { background: rgba(60, 60, 67, .07); color: #8e8e93; text-decoration: line-through; }
.nt-content .nt-task.ProseMirror-selectednode { outline: 2px solid var(--tint); outline-offset: 1px; }
.slash.people .av { flex: 0 0 auto; width: 30px; height: 30px; font-size: 11.5px; margin: 4px; box-shadow: none; }
/* цвет карточки документа на доске: значок и лёгкий фон */
.it.doc[style*="--dk"] { background: color-mix(in srgb, var(--dk) 7%, #fff); border-color: color-mix(in srgb, var(--dk) 28%, transparent); }
.it.doc[style*="--dk"] .dk-ic { background: linear-gradient(135deg, color-mix(in srgb, var(--dk) 60%, #fff), var(--dk)); }

/* ───────────── 03.11.2026 (ночь): агент — оркестратор и исполнители, агент в документах ───────────── */
.ag-step { display: flex; align-items: flex-start; gap: 6px; font-size: 12.5px; color: var(--label-2); line-height: 1.4; margin-bottom: 4px; }
.ag-step .ic { width: 13px; height: 13px; flex: 0 0 auto; margin-top: 2px; color: #16965c; stroke-width: 3; }
.ag-now { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ag-log { margin: 6px 4px 0; font-size: 12px; color: var(--label-2); }
.ag-log summary { cursor: pointer; font-weight: 600; }
.ag-log div { padding: 2px 0 2px 10px; border-left: 2px solid rgba(60, 60, 67, .12); margin-top: 3px; }
.doc-head .ib.ag { color: var(--tint); }
.doc-agent { padding: 10px 16px 12px; border-bottom: 1px solid rgba(55, 53, 47, .09); background: rgba(var(--tint-rgb), .045); }
.doc-agent .da-q { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.doc-agent .chip { height: 28px; padding: 0 10px; border: 0; border-radius: 8px; cursor: pointer; font: inherit; font-size: 13px; font-weight: 600;
  background: rgba(var(--tint-rgb), .12); color: var(--tint); }
.doc-agent .chip:hover { background: rgba(var(--tint-rgb), .2); }
.doc-agent .da-f { display: flex; gap: 8px; align-items: flex-end; }
.doc-agent textarea { flex: 1; resize: vertical; min-height: 40px; max-height: 160px; padding: 8px 10px; border-radius: 10px; border: 1px solid rgba(60, 60, 67, .16);
  font: inherit; font-size: 14px; background: #fff; outline: none; }
.doc-agent textarea:focus { border-color: rgba(var(--tint-rgb), .5); }
.doc-agent .da-run { font-size: 13.5px; }
.doc-agent .da-res { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; }
.doc-agent .da-res .da-t { flex: 1; min-width: 0; }
.doc-agent .da-res .da-ic { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: #16965c; color: #fff; }
.doc-agent .da-res.err .da-ic { background: var(--red-ios); }
.doc-agent .da-res .da-ic .ic { width: 14px; height: 14px; stroke-width: 3; }
.ad-types { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; margin: 10px 0 12px; }
.ad-t { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(60, 60, 67, .14); cursor: pointer; position: relative; }
.ad-t input { position: absolute; opacity: 0; pointer-events: none; }
.ad-t:has(input:checked) { border-color: var(--tint); background: rgba(var(--tint-rgb), .07); box-shadow: 0 0 0 1px var(--tint); }
.modal #ad-text { width: 100%; box-sizing: border-box; resize: vertical; padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(60, 60, 67, .16); font: inherit; font-size: 14px; outline: none; margin-bottom: 8px; }
.modal #ad-text:focus { border-color: rgba(var(--tint-rgb), .5); }
.dl-h + .fill + .ag-new, .doc-head .ag-new { color: var(--tint); }
.ag-msg.busy .ag-b { display: block; }                 /* шаги хода — столбиком, «сейчас» — строкой ниже */
.ag-msg.busy .ag-b, .ag-step, .ag-now { white-space: normal; }

/* ───────────── 03.11.2026 (ночь): «Список задач», люди, приглашения, «N дней после» ───────────── */
.it.stack { background: #fff; border-radius: 12px; box-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 6px 16px rgba(30, 20, 60, .1); border: 1px solid rgba(60, 60, 67, .1); overflow: hidden; }
.it.stack .sk-h { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 8px 0 12px; }
.it.stack .sk-ic { flex: 0 0 auto; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #8f7bff, #5b45e0); }
.it.stack .sk-ic .ic { width: 17px; height: 17px; }
.it.stack .sk-t { flex: 1; min-width: 0; font-weight: 650; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; outline: none; }
.it.stack.editing .sk-t { user-select: text; -webkit-user-select: text; white-space: normal; }
.it.stack .sk-n { font-size: 12.5px; font-weight: 650; color: var(--label-2); font-variant-numeric: tabular-nums; }
.it.stack .sk-tog { width: 30px; height: 30px; border: 0; border-radius: 8px; background: transparent; cursor: pointer; display: grid; place-items: center; color: var(--label-2); }
.it.stack .sk-tog:hover { background: rgba(var(--tint-rgb), .09); }
.it.stack .sk-tog .ic { width: 17px; height: 17px; transition: transform .15s; }
.it.stack.open .sk-tog .ic { transform: rotate(180deg); }
.it.stack .sk-list { padding: 0 6px 8px; border-top: 1px solid rgba(60, 60, 67, .08); }
.it.stack .sk-row { display: flex; align-items: flex-start; gap: 8px; min-height: 36px; padding: 9px 6px; border-radius: 8px; cursor: grab; font-size: 13px; line-height: 18px; }
.it.stack .sk-row:hover { background: rgba(var(--tint-rgb), .07); }
.it.stack .sk-row.flash { animation: flash 1.6s ease 2; }
.it.stack .sk-chk { flex: 0 0 auto; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(60, 60, 67, .4); background: #fff; cursor: pointer; display: grid; place-items: center; padding: 0; }
.it.stack .sk-row.done .sk-chk { background: #16965c; border-color: #16965c; color: #fff; }
.it.stack .sk-chk .ic { width: 11px; height: 11px; stroke-width: 3.5; }
.it.stack .sk-x { flex: 1; min-width: 0; white-space: normal; overflow-wrap: anywhere; font-weight: 550; }   /* длинный текст — на следующую строку */
.it.stack .sk-row.done .sk-x { text-decoration: line-through; color: var(--label-2); }
.it.stack .sk-d { flex: 0 0 auto; font-size: 11.5px; font-weight: 600; color: var(--label-2); padding: 1px 6px; border-radius: 6px; background: rgba(60, 60, 67, .07); display: inline-flex; gap: 3px; align-items: center; }
.it.stack .sk-d.late { background: rgba(255, 59, 48, .12); color: var(--red-ios); }
.it.stack .sk-d .ic, .it.stack .sk-w .ic { width: 12px; height: 12px; }
.it.stack .sk-w { color: #c26e00; display: inline-flex; }
.it.stack .av { width: 20px; height: 20px; font-size: 9px; box-shadow: none; flex: 0 0 auto; }
.sk-ghost { position: absolute; width: 280px; padding: 10px 14px; border-radius: 10px; background: #fff; font-size: 14px; font-weight: 550; pointer-events: none;
  box-shadow: 0 0 0 2px var(--tint), 0 12px 28px rgba(30, 20, 60, .2); opacity: .95; }
.it.task .tk-due.after { background: rgba(232, 116, 44, .1); color: #a85a14; }
.date-in.lead-in input { flex: 0 0 56px; width: 56px; }
.due.after { color: #a85a14; }
.tgroup.wait h3 { color: #a85a14; }
/* упоминание человека в документе */
.nt-content .nt-person { display: inline; padding: 0 4px; margin: 0 1px; border-radius: 6px; background: rgba(10, 122, 255, .09); color: #0a6bdc; font-weight: 600; cursor: pointer; white-space: nowrap; user-select: none; }
.nt-content .nt-person:hover { background: rgba(10, 122, 255, .16); }
.nt-content .nt-person.invited { background: transparent; box-shadow: inset 0 0 0 1px rgba(10, 122, 255, .35); }
.nt-content .nt-person.ProseMirror-selectednode { outline: 2px solid var(--tint); outline-offset: 1px; }
.slash.people .sl-h { margin-top: 4px; }
.doc-agent .da-more { margin-top: 10px; }
.doc-agent .da-hint { margin-top: 6px; }
.who-bar { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 14px; margin: 0 0 14px; flex-wrap: wrap; }
.ptable .pa { display: block; margin-top: 2px; }
.iv-done .share-url { margin: 8px 0; }
.it.stack .sk-d.after { background: rgba(232, 116, 44, .1); color: #a85a14; }
/* голосовой ввод (voice.js): микрофон у поля агента; запись — красная кнопка, кольцо дышит в такт голосу */
.mic { position: relative; width: 34px; height: 34px; flex: 0 0 auto; border: 0; border-radius: 50%; display: grid; place-items: center;
  cursor: pointer; color: var(--label-2); background: rgba(60, 60, 67, .08); transition: background .15s, color .15s; padding: 0; }
.mic:hover { background: rgba(var(--tint-rgb), .12); color: var(--tint); }
.mic .ic { width: 18px; height: 18px; position: relative; z-index: 1; }
.mic .mic-ring { position: absolute; inset: 0; border-radius: 50%; background: rgba(255, 59, 48, .28); transform: scale(1); opacity: 0; pointer-events: none;
  transition: transform .1s linear; }
.mic .mic-stop { display: none; width: 12px; height: 12px; border-radius: 3px; background: #fff; position: relative; z-index: 1; }
.mic .mic-t { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); font-size: 11.5px; font-weight: 650; color: #d70015;
  font-variant-numeric: tabular-nums; white-space: nowrap; pointer-events: none; }
.mic.on { background: #ff3b30; color: #fff; }
.mic.on .ic { display: none; }
.mic.on .mic-stop { display: block; }
.mic.on .mic-ring { opacity: 1; transform: scale(calc(1.15 + var(--lvl, 0) * .9)); animation: mic-pulse 1.4s ease-out infinite; }
.mic.wait { background: rgba(255, 59, 48, .14); color: #d70015; }
.mic.wait .ic { animation: mic-blink .8s ease-in-out infinite alternate; }
@keyframes mic-pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 59, 48, .35); } 100% { box-shadow: 0 0 0 10px rgba(255, 59, 48, 0); } }
@keyframes mic-blink { to { opacity: .35; } }
.vwrap { position: relative; }
.vwrap > textarea { padding-right: 52px !important; }
.mic.inset { position: absolute; right: 9px; bottom: 15px; }
.modal .field .vwrap .mic.inset { bottom: 9px; }
textarea.voice-on { caret-color: transparent; }
.ag-form:has(textarea.voice-on), .doc-agent .da-f:has(textarea.voice-on) textarea, .vwrap:has(textarea.voice-on) > textarea {
  box-shadow: 0 0 0 2px rgba(255, 59, 48, .35) !important; }
@media (prefers-reduced-motion: reduce) { .mic.on .mic-ring, .mic.wait .ic { animation: none; } }
/* строка списка в несколько строк: галочка, срок, часы и ответственный — по первой строке текста */
.it.stack .sk-chk { margin-top: 0; }
.it.stack .sk-d { margin-top: -1px; }
.it.stack .sk-w { margin-top: 3px; }
.it.stack .sk-row .av { margin-top: -1px; }
/* карточка сотрудника при наведении на исполнителя (whocard.js) */
.who-card { position: fixed; z-index: 1000; width: 330px; padding: 14px; border-radius: 14px; background: rgba(255, 255, 255, .97);
  box-shadow: 0 0 0 1px rgba(60, 60, 67, .1), 0 12px 32px rgba(30, 20, 60, .18); animation: wc-in .12s ease-out; }
@keyframes wc-in { from { opacity: 0; transform: translateY(-3px); } }
.who-card .wc-top { display: flex; gap: 12px; align-items: center; }
.who-card .av { width: 40px; height: 40px; font-size: 14px; flex: 0 0 auto; }
.who-card .wc-n { display: flex; flex-direction: column; min-width: 0; gap: 2px; }
.who-card .wc-n b { font-size: 14.5px; line-height: 1.3; }
.who-card .wc-n .muted { font-size: 13px; }
.who-card .wc-chip { margin-top: 10px; display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 6px;
  color: #0a6bdc; box-shadow: inset 0 0 0 1px rgba(10, 122, 255, .35); }
.who-card .wc-btns { display: flex; gap: 8px; margin-top: 12px; }
.who-card .wc-btns .btn { justify-content: center; white-space: nowrap; }
.who-card .wc-btns .btn:first-child { flex: 1; }
.it.task .tk-who:not(.none) { cursor: pointer; border-radius: 6px; }
.it.task .tk-who:not(.none):hover { background: rgba(var(--tint-rgb), .08); }
/* «Связано» под документом (doceditor.loadLinks) */
.doc-links { margin: 36px 0 24px; padding: 16px 18px; border-radius: 14px; background: rgba(60, 60, 67, .04); box-shadow: inset 0 0 0 1px rgba(60, 60, 67, .08); }
.doc-links .lk-t { display: flex; align-items: center; gap: 7px; font-weight: 700; font-size: 14px; margin-bottom: 10px; color: var(--label-2); }
.doc-links .lk-t .ic { width: 16px; height: 16px; }
.doc-links .dl-g { margin-top: 10px; }
.doc-links .lk-h { display: flex; align-items: center; gap: 10px; font-size: 12.5px; font-weight: 650; color: var(--label-2); margin-bottom: 6px; }
.doc-links .dl-bar { flex: 0 0 120px; height: 5px; border-radius: 3px; background: rgba(60, 60, 67, .12); overflow: hidden; }
.doc-links .dl-bar b { display: block; height: 100%; background: #16965c; border-radius: 3px; }
.doc-links button { display: flex; align-items: center; gap: 8px; width: 100%; border: 0; background: transparent; padding: 6px 8px; border-radius: 8px;
  cursor: pointer; font: inherit; font-size: 13.5px; text-align: left; color: var(--label); }
.doc-links button:hover { background: rgba(var(--tint-rgb), .08); }
.doc-links button span { flex: 1; min-width: 0; }
.doc-links button small { color: var(--label-2); font-size: 12px; white-space: nowrap; }
.doc-links .dl-doc .ic { width: 15px; height: 15px; color: var(--tint); }
.doc-links .dl-task i { flex: 0 0 auto; width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(60, 60, 67, .35); display: grid; place-items: center; }
.doc-links .dl-task.done i { background: #16965c; border-color: #16965c; color: #fff; }
.doc-links .dl-task.done span { text-decoration: line-through; color: var(--label-2); }
.doc-links .dl-task i .ic { width: 10px; height: 10px; stroke-width: 3.5; }
/* лента «Актуализация» (#/sync) */
.sync-state { margin: -6px 0 14px; }
.sync-run { padding: 14px 16px; border-radius: 16px; margin-bottom: 12px; display: flex; flex-direction: column; gap: 10px; }
.sync-run .sr-h { display: flex; align-items: center; gap: 10px; }
.sync-run .sr-ev { display: flex; flex-direction: column; gap: 3px; padding-left: 10px; border-left: 2px solid rgba(60, 60, 67, .14); }
.sync-run .sr-new div { display: flex; align-items: center; gap: 7px; font-size: 13.5px; color: #0a6bdc; }
.sync-run .sr-new .ic { width: 15px; height: 15px; }
.sync-run .sr-res { padding: 10px 12px; border-radius: 12px; background: rgba(255, 255, 255, .55); display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.sync-run .sr-res.undone { opacity: .55; }
.sync-run .sr-res .btn { align-self: flex-start; }
.sync-run .sr-b { display: flex; align-items: center; gap: 8px; }
.sync-run .sr-b a { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; color: var(--tint); text-decoration: none; }
.sync-run .sr-b .ic { width: 15px; height: 15px; }
/* новое в актуализации: счётчик на вкладке и всплывающее сообщение (app.syncWatch) */
.seg a[data-n] { position: relative; }
.seg a[data-n]::after { content: attr(data-n); position: absolute; top: -4px; right: -4px; min-width: 17px; height: 17px; padding: 0 5px; box-sizing: border-box;
  border-radius: 9px; background: #ff3b30; color: #fff; font-size: 11px; font-weight: 700; line-height: 17px; text-align: center; }
.toast.sync-toast { display: flex; gap: 8px; align-items: flex-start; max-width: 460px; cursor: pointer; text-align: left; }
.toast.sync-toast .ic { width: 16px; height: 16px; flex: 0 0 auto; margin-top: 2px; }
/* холст едет — панели без размытия (board.setView, класс moving): размытие под панелями пересчитывалось в каждом кадре */
.board.moving .bar.glass { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(255, 255, 255, .9); }
/* непрозрачные панели (документы, боковая, плашки редактора) — без размытия под ними: фон всё равно не виден */
.docpanel.glass, .sidepanel.glass, .doc .bubble, .doc .tbar, .doc .ibar, .doc .slash { -webkit-backdrop-filter: none; backdrop-filter: none; }
/* карточки на списке досок — без своего размытия на каждой (прокрутка списка размывала фон под каждой) */
.card.glass { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(255, 255, 255, .5); }
