/* Task Brain — приложение: общие стили каркаса. ОБЩИЙ ФАЙЛ (docs/PARTS.md): части пишут свои стили в
   tasks/tasks.css (классы t-…) и more/more.css (классы m-…), этот файл не правят.
   Цвета, шрифты и тёмная тема — только из /shared/tokens.css.
   Телефон в первую очередь (390 px); с 900 px — боковая колонка слева и панель задачи справа. */

:root { --badge: #e5484d; }
html { scroll-padding-top: 72px; }
html.no-scroll { overflow: hidden; }
body { min-height: 100dvh; overflow-x: hidden; }
#app { min-height: 100dvh; }

/* ───────── типографика и утилиты ───────── */
.h1 { font-size: 30px; letter-spacing: -.02em; }
.h2 { font-size: 24px; letter-spacing: -.015em; }
.h3 { font-size: 19px; }
.h4 { font-size: 16px; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.sm { font-size: var(--fs-sm); }
.xs { font-size: var(--fs-xs); }
.block { display: block; }
.ell { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.grow { flex: 1 1 auto; min-width: 0; }
.min0 { min-width: 0; }
.row { display: flex; align-items: center; }
.wrap { flex-wrap: wrap; }
.gap4 { gap: 4px; } .gap8 { gap: 8px; } .gap12 { gap: 12px; }
.center { text-align: center; justify-content: center; }
.center-col { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; text-align: center; }
.stack { display: flex; flex-direction: column; gap: 10px; margin: 14px 0; }
.ok-t { color: var(--ok); }
.danger-t { color: var(--danger); }
.accent-t { color: var(--accent-ink); }
.err { color: var(--danger); font-size: 14px; }
.link { color: var(--primary); background: none; border: 0; padding: 0; font-weight: 600; cursor: pointer; min-height: 32px; }
.link:disabled { color: var(--muted); cursor: default; }
.hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.d-only { display: none !important; }
.m-only { display: flex; }
@media (min-width: 900px) { .d-only { display: flex !important; } .m-only { display: none !important; } }
kbd { font: 600 11px/1 var(--font); padding: 3px 6px; border-radius: 6px; border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--muted); }

.skip { position: absolute; left: -999px; top: 8px; z-index: 1000; background: var(--surface); padding: 10px 14px; border-radius: 10px; box-shadow: var(--sh-2); }
.skip:focus { left: 12px; }

/* ───────── раскладка: телефон ───────── */
.main { padding-bottom: calc(var(--tab-h) + 20px + env(safe-area-inset-bottom)); outline: none; min-width: 0; }
.app.bare .main { padding-bottom: 0; }
.pad { padding-inline: 16px; }
.narrow { max-width: 760px; }
.route { animation: page-in .22s var(--ease) both; }
.in-up { animation: bm-fade-up var(--bm-slow, .42s) var(--bm-ease-out, var(--ease)) var(--d, 0ms) both; }
@keyframes page-in { from { opacity: 0; } }

/* ───────── раскладка: ПК — боковая колонка + содержимое + панель задачи ───────── */
.side { display: none; }
@media (min-width: 900px) {
  .app { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); min-height: 100dvh; }
  .app.bare { display: block; }
  .app.with-panel { grid-template-columns: var(--side-w) minmax(0, 1fr) var(--panel-w); }
  .main { padding-bottom: 48px; }
  .pad { padding-inline: 32px; }
  .side { display: flex; flex-direction: column; position: sticky; top: 0; height: 100dvh; overflow: hidden; background: var(--surface); border-right: 1px solid var(--line); }
}
@media (min-width: 900px) and (max-width: 1240px) { .app.with-panel { grid-template-columns: var(--side-w) minmax(0, 1fr) 380px; } }

.side-top { display: flex; align-items: center; gap: 8px; padding: 16px 14px 8px 18px; }
.side-top .logo { flex: 1; min-width: 0; }
.side-add { margin: 6px 12px 4px; justify-content: flex-start; gap: 10px; }
.side-add kbd { margin-left: auto; }
.side-scroll { flex: 1; overflow-y: auto; padding: 4px 8px 12px; scrollbar-width: thin; }
.side-h { display: flex; align-items: center; gap: 4px; margin: 16px 6px 4px 10px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.side-h .grow { min-width: 0; }
.side-h .icon-btn { width: 30px; height: 30px; }
.nav-i { display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 6px 10px; border-radius: 10px; color: var(--ink-2); font-size: 14.5px; font-weight: 550; text-decoration: none !important; border: 0; background: none; width: 100%; text-align: left; }
.nav-i:hover { background: var(--surface-2); }
.nav-i.on { background: var(--primary-soft); color: var(--primary-soft-ink); font-weight: 650; }
.nav-i .n { margin-left: auto; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.nav-i .n.over { color: var(--danger); font-weight: 700; }
.nav-i.on .n { color: inherit; }
.nav-i .ic { color: var(--muted); }
.nav-i.on .ic, .nav-i .licon .ic { color: inherit; }
.nav-sun .ic { color: var(--accent) !important; }
.nav-fold { font-weight: 650; color: var(--ink); }
.nav-fold .chev { transition: transform var(--t) var(--ease); color: var(--faint); }
.nav-fold.closed .chev { transform: rotate(-90deg); }
.nav-sub { padding-left: 14px; }
.side-foot { border-top: 1px solid var(--line); padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.side-me { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 10px; color: var(--ink); text-decoration: none !important; min-width: 0; }
.side-me:hover { background: var(--surface-2); }

/* панель задачи: ПК — колонка справа; телефон — во весь экран поверх */
.panel { position: fixed; inset: 0; z-index: 120; background: var(--surface); display: flex; flex-direction: column; overflow: hidden; animation: panel-up .28s var(--bm-ease-out, var(--ease)); }
@keyframes panel-up { from { transform: translateY(24px); opacity: 0; } }
@media (min-width: 900px) {
  .panel { position: sticky; top: 0; height: 100dvh; inset: auto; z-index: 5; border-left: 1px solid var(--line); animation: panel-in .24s var(--ease); box-shadow: -12px 0 30px -24px rgba(20,22,41,.3); }
  @keyframes panel-in { from { transform: translateX(16px); opacity: 0; } }
}

/* заголовок страницы */
.topbar { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 4px; min-height: 56px;
  padding: calc(4px + env(safe-area-inset-top)) 8px 4px; background: color-mix(in oklab, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.tb-title { flex: 1; min-width: 0; padding-inline: 4px; }
.tb-title h1 { display: flex; align-items: center; gap: 10px; font-size: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-title p { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-gap { width: 8px; flex: none; }
.tb-gap + .tb-title h1 { font-size: 26px; letter-spacing: -.02em; }
.tb-act { display: flex; gap: 2px; align-items: center; }
@media (min-width: 900px) {
  .topbar { padding: 22px 24px 8px 32px; background: color-mix(in oklab, var(--bg) 90%, transparent); }
  .tb-title h1, .tb-gap + .tb-title h1 { font-size: 28px; letter-spacing: -.02em; }
  .tb-gap { display: none; }
}

.offline { position: sticky; top: 0; z-index: 60; display: flex; gap: 8px; align-items: center; justify-content: center; padding: 6px 12px; background: var(--ink); color: var(--bg); font-size: 13px; }

/* ───────── кнопки ───────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 13px;
  border: 1px solid transparent; font-weight: 650; font-size: 15px; line-height: 1.1; text-decoration: none !important; white-space: nowrap;
  cursor: pointer; transition: background var(--t) var(--ease), box-shadow var(--t) var(--ease), transform var(--t-fast) var(--ease); }
.btn > span { overflow: hidden; text-overflow: ellipsis; }
/* .btn-icm — на узком экране (до 420 px) только значок; подпись для чтения с экрана — в aria-label кнопки */
@media (max-width: 420px) { .btn-icm > span:not(.ic):not(.spin) { display: none; } .btn-icm { padding: 0 10px; } }
.btn-primary { background: var(--primary); color: var(--on-primary); box-shadow: 0 8px 18px -10px color-mix(in oklab, var(--primary) 80%, transparent); }
.btn-primary:hover { background: var(--primary-hover); }
.btn-soft { background: var(--primary-soft); color: var(--primary-soft-ink); }
.btn-soft:hover { background: color-mix(in oklab, var(--primary-soft) 80%, var(--brand) 12%); }
.btn-ghost { background: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-outline { background: var(--surface); border-color: var(--line-strong); color: var(--ink); }
.btn-outline:hover { background: var(--surface-2); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-ghost-danger { background: transparent; color: var(--danger); border-color: var(--line); }
.btn-ghost-danger:hover { background: var(--danger-soft); }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
.btn-lg { min-height: 52px; padding: 0 22px; font-size: 16px; border-radius: 15px; }
.btn-block { width: 100%; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; box-shadow: none; }
.btn.is-loading > span:not(.spin) { opacity: .8; }
.spin { display: inline-block; width: 18px; height: 18px; border: 2.5px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: tb-spin .7s linear infinite; flex: none; }
@keyframes tb-spin { to { transform: rotate(360deg); } }
.row-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }

.icon-btn { position: relative; display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; border: 0; background: transparent; color: var(--ink-2); flex: none; text-decoration: none !important; transition: background var(--t) var(--ease); }
.icon-btn:hover { background: var(--surface-2); }
.icon-btn.on, .icon-btn[aria-pressed="true"] { color: var(--primary); background: var(--primary-soft); }
.badge { position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--badge); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; line-height: 1; }
.badge.dot { min-width: 0; width: 10px; height: 10px; padding: 0; top: 2px; right: 6px; border: 2px solid var(--surface); }

/* ───────── кружок «выполнить» ───────── */
.tcheck { --c: var(--line-strong); position: relative; display: inline-grid; place-items: center; width: var(--sz, 22px); height: var(--sz, 22px); flex: none;
  border-radius: 50%; border: 2px solid var(--c); background: transparent; padding: 0; cursor: pointer; transition: background var(--t-fast), border-color var(--t-fast), transform var(--t-fast) var(--ease); }
.tcheck::before { content: ''; position: absolute; inset: -11px; }   /* место для пальца ≥ 44 px */
.tcheck.p1 { --c: var(--p1); } .tcheck.p2 { --c: var(--p2); } .tcheck.p3 { --c: var(--p3); background: color-mix(in oklab, var(--p3) 10%, transparent); }
.tcheck svg { width: 70%; height: 70%; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 16; stroke-dashoffset: 16; transition: stroke-dashoffset .25s var(--ease); }
.tcheck:hover svg { stroke: var(--c); stroke-dashoffset: 0; opacity: .5; }
.tcheck.on { background: var(--c); border-color: var(--c); }
.tcheck:not([class*=" p"]).on { --c: var(--ok); }
.tcheck.on svg { stroke: #fff; stroke-dashoffset: 0; opacity: 1; }
.tcheck:active { transform: scale(.88); }
.tcheck:disabled { cursor: default; opacity: .6; }
.licon { display: inline-flex; flex: none; }
.cdot { display: inline-block; border-radius: 50%; flex: none; }

/* ───────── скелетоны и картинки ───────── */
.sk { display: block; border-radius: 10px; background: linear-gradient(100deg, var(--surface-2) 40%, var(--surface-3) 50%, var(--surface-2) 60%) 0 0 / 200% 100%; animation: tb-shimmer 1.3s linear infinite; }
@keyframes tb-shimmer { to { background-position: -200% 0; } }
.img { position: relative; overflow: hidden; background: var(--surface-2); }
.img img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .35s var(--ease); }
.img.ok img { opacity: 1; }
.img.ph { display: grid; place-items: center; color: var(--faint); }
.ava { border-radius: 50%; object-fit: cover; flex: none; background: var(--surface-2); }
.ava-ph { display: inline-grid; place-items: center; font-weight: 700; color: hsl(var(--h) 45% 30%); background: hsl(var(--h) 60% 90%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ava-ph { color: hsl(var(--h) 60% 80%); background: hsl(var(--h) 30% 22%); } }
:root[data-theme="dark"] .ava-ph { color: hsl(var(--h) 60% 80%); background: hsl(var(--h) 30% 22%); }

/* ───────── чипы и метки ───────── */
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line-strong);
  background: var(--surface); font-size: 14px; font-weight: 550; color: var(--ink-2); white-space: nowrap; flex: none; text-decoration: none !important; }
.chip:hover { border-color: var(--faint); }
.chip.on { background: var(--primary-soft); color: var(--primary-soft-ink); border-color: transparent; }
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 650; background: var(--surface-2); color: var(--ink-2); white-space: nowrap; }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.warn { background: var(--warn-soft); color: var(--warn); }
.tag.danger { background: var(--danger-soft); color: var(--danger); }
.tag.info { background: var(--info-soft); color: var(--info); }
.tag.accent { background: var(--accent-soft); color: var(--accent-ink); }
.tag.brand { background: var(--primary-soft); color: var(--primary-soft-ink); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-inline: -16px; padding: 2px 16px; }
.chips.scroll::-webkit-scrollbar { display: none; }

/* ───────── формы ───────── */
.form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 0; }
.field-l { font-size: 13px; font-weight: 650; color: var(--ink-2); }
.field-h { font-size: 12px; color: var(--muted); }
.field-err { font-size: 13px; color: var(--danger); }
.input { width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 13px; border: 1px solid var(--line-strong); background: var(--surface); font-size: 16px; color: var(--ink); transition: border-color var(--t), box-shadow var(--t); }
.input::placeholder { color: var(--faint); }
.input:focus { outline: none; border-color: var(--brand); box-shadow: var(--ring); }
textarea.input { resize: vertical; min-height: 72px; line-height: 1.45; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
.has-err .input { border-color: var(--danger); }
.checkline { display: flex; gap: 10px; align-items: center; font-size: 14px; min-height: 44px; cursor: pointer; }
.checkline input { width: 20px; height: 20px; accent-color: var(--primary); margin: 0; flex: none; }
.seg { display: inline-flex; background: var(--surface-2); border-radius: 12px; padding: 3px; gap: 2px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg-i { min-height: 36px; padding: 0 14px; border: 0; background: transparent; border-radius: 9px; font-weight: 650; color: var(--muted); white-space: nowrap; font-size: 14px; }
.seg-i.on { background: var(--surface); color: var(--ink); box-shadow: var(--sh-1); }
.seg-n { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--primary); color: var(--on-primary); font-size: 11px; margin-left: 4px; }
.switch { position: relative; width: 50px; height: 30px; border-radius: 999px; border: 0; background: var(--surface-3); flex: none; transition: background var(--t); }
.switch i { position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform var(--t) var(--ease); }
.switch.on { background: var(--primary); }
.switch.on i { transform: translateX(20px); }
.switch:disabled { opacity: .5; }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 13px; background: var(--info-soft); color: var(--ink); font-size: 14px; margin: 10px 0; }
.notice > .ic { margin-top: 1px; }
.notice.warn { background: var(--warn-soft); }
.notice.err { background: var(--danger-soft); }
.notice.ok { background: var(--ok-soft); }

/* ───────── листы ───────── */
.sheet-wrap { position: fixed; inset: 0; z-index: 200; display: flex; align-items: flex-end; justify-content: center; }
.sheet-bg { position: absolute; inset: 0; background: rgba(14, 16, 30, .5); animation: tb-fade .2s var(--ease); }
.sheet { position: relative; width: 100%; max-height: 92dvh; background: var(--surface); border-radius: 22px 22px 0 0; display: flex; flex-direction: column;
  box-shadow: var(--sh-3); animation: tb-up .32s var(--bm-ease-out, var(--ease)); padding-bottom: env(safe-area-inset-bottom); outline: none; }
.sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: var(--line-strong); margin: 8px auto 0; flex: none; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 8px 2px 20px; }
.sheet-head h2 { font-size: 19px; }
.sheet-x { position: absolute; top: 8px; right: 8px; z-index: 2; }
.sheet-body { padding: 8px 20px 20px; overflow: auto; display: flex; flex-direction: column; gap: 12px; overscroll-behavior: contain; }
.sheet-foot { padding: 12px 20px; border-top: 1px solid var(--line); }
@keyframes tb-fade { from { opacity: 0; } }
@keyframes tb-up { from { transform: translateY(40px); opacity: 0; } }
@media (min-width: 700px) {
  .sheet-wrap { align-items: center; padding: 24px; }
  .sheet { max-width: 480px; border-radius: 22px; max-height: 86vh; animation-name: tb-pop; }
  .sheet.wide { max-width: 860px; }
  .sheet-grip { display: none; }
  .sheet-head { padding-top: 14px; }
}
@media (max-width: 699px) { .sheet.full { height: 92dvh; } }
@keyframes tb-pop { from { transform: scale(.96) translateY(8px); opacity: 0; } }

.list { display: flex; flex-direction: column; }
.row-i { display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 10px 4px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; width: 100%; color: var(--ink); text-decoration: none !important; font-size: 15px; }
.row-i:last-child { border-bottom: 0; }
.row-i.on { color: var(--primary); font-weight: 650; }

/* ───────── нижнее меню телефона ───────── */
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; display: grid; grid-template-columns: repeat(5, 1fr);
  padding: 4px 4px env(safe-area-inset-bottom); background: color-mix(in oklab, var(--surface) 92%, transparent);
  backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
.tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px; color: var(--muted); font-size: 11px; font-weight: 600; text-decoration: none !important; border-radius: 14px; border: 0; background: none; }
.tab-ic { position: relative; display: grid; place-items: center; width: 52px; height: 30px; border-radius: 15px; transition: background var(--t) var(--ease); }
.tab.on { color: var(--primary); }
.tab.on .tab-ic { background: var(--primary-soft); }
.tab:active .tab-ic { transform: scale(.92); }
.tab-ic .badge { top: -3px; right: 4px; }
.tab-add { color: var(--primary); }
.tab-plus { display: grid; place-items: center; width: 52px; height: 30px; border-radius: 15px; background: var(--primary); color: var(--on-primary); box-shadow: 0 6px 14px -6px var(--primary); }
@media (min-width: 900px) { .tabbar { display: none; } }

/* знак и название */
.logo { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 800; font-size: 18px; letter-spacing: -.02em; text-decoration: none !important; flex: none; }
.mark-tile { fill: var(--brand); }
:root[data-theme="dark"] .mark-tile { fill: #5b5ef0; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .mark-tile { fill: #5b5ef0; } }

/* состояние синхронизации */
.syncdot { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.syncdot.err { color: var(--danger); }
.syncdot.busy .ic { animation: tb-spin 1s linear infinite; }

/* ───────── разделы, карточки-блоки, меню ───────── */
.page { min-height: 40vh; }
.sec { margin-top: 24px; }
.sec-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.sec-h h2 { font-size: 17px; letter-spacing: -.01em; }
.sec-sub { color: var(--muted); font-size: 13px; margin-top: 2px; }
.sec-more { display: inline-flex; align-items: center; gap: 2px; min-height: 36px; font-weight: 650; font-size: 14px; white-space: nowrap; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 16px; margin: 12px 0; display: flex; flex-direction: column; gap: 12px; }
.menu { background: var(--surface); border-radius: 18px; border: 1px solid var(--line); overflow: hidden; margin-top: 10px; }
.menu-i { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 10px 16px; border: 0; border-bottom: 1px solid var(--line); background: transparent; width: 100%; text-align: left; color: var(--ink); text-decoration: none !important; font-size: 15px; }
.menu-i:last-child { border-bottom: 0; }
button.menu-i:hover, a.menu-i:hover { background: color-mix(in oklab, var(--surface-2) 60%, transparent); }
.menu-i > .ic:last-child { color: var(--faint); }
.menu-ic { width: 34px; height: 34px; border-radius: 10px; background: var(--surface-2); display: grid; place-items: center; color: var(--ink-2); flex: none; }
.menu-ic.brand { background: var(--primary-soft); color: var(--primary-soft-ink); }
.menu-i .grow { min-width: 0; flex: 1 1 0; }
.menu-h { font-size: 13px; color: var(--muted); margin: 24px 6px 0; font-weight: 700; }

/* ───────── вход ───────── */
.login { min-height: 100dvh; display: flex; flex-direction: column; }
.login-in { padding: 24px 16px 40px; max-width: 460px; margin: 0 auto; width: 100%; }
.login-pitch { text-align: center; margin: 8px 0 18px; color: var(--muted); }
.or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
.or::before, .or::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.demo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.demo-grid .btn { min-width: 0; padding: 0 10px; font-size: 14px; }

/* ───────── пусто, ошибки, заглушки ───────── */
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 44px 16px; }
.empty-ic { width: 72px; height: 72px; border-radius: 22px; background: var(--primary-soft); color: var(--primary-soft-ink); display: grid; place-items: center; margin-bottom: 6px; }
.empty h3 { font-size: 19px; }
.empty p { color: var(--muted); max-width: 360px; }
.empty-act { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.nf-mark { display: block; animation: bm-float 4s ease-in-out infinite; }
.stub { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 36px 16px; margin: 16px 0; background: var(--surface); border: 1px dashed var(--line-strong); border-radius: 22px; }
.stub p { max-width: 460px; }
.stub code { font-size: 12.5px; background: var(--surface-2); padding: 2px 6px; border-radius: 6px; }
.stub-hero { border-style: solid; border-color: var(--line); padding: 44px 16px; background:
  radial-gradient(90% 70% at 100% 0%, color-mix(in oklab, var(--brand) 16%, transparent), transparent 60%),
  radial-gradient(70% 60% at 0% 0%, color-mix(in oklab, var(--accent) 18%, transparent), transparent 60%), var(--surface); }

/* ───────── тосты Brain Motion — в стиле Task Brain ───────── */
.bm-toasts { bottom: calc(var(--tab-h) + 24px + env(safe-area-inset-bottom)); width: max-content; max-width: calc(100vw - 32px); }
.bm-toast { font: 600 14px/1.35 var(--font); background: var(--ink); color: var(--bg); border-radius: 13px; text-align: center; pointer-events: auto; display: flex; align-items: center; gap: 4px; }
.bm-toast-act { margin: -6px -8px -6px 10px; min-height: 36px; padding: 0 10px; border: 0; border-radius: 9px; background: none; color: var(--accent); font: 750 14px var(--font); }
.bm-toast-act:hover { background: color-mix(in oklab, var(--bg) 14%, transparent); }
@media (min-width: 900px) { .bm-toasts { bottom: 28px; } }
.app.bare ~ .bm-toasts { bottom: 24px; }
