/* NetWeb · web/web.css — раскладка сайта поверх классов .nw-* из shared/tokens.css (их не перекрашиваем).
 * Здесь: высота окна, прокрутка панелей, кнопки вместо span из макета, слои (меню, ⌘K, диалоги, снэкбар),
 * экраны «Сегодня», «Города», «Ритмы», «Импорт», адаптив 1280 / 1024. Префикс w- — только сайт. */

html, body.w-body { height: 100%; margin: 0; }
body.w-body { background: var(--nw-card); overflow: hidden; }
.nw-desk { height: 100vh; height: 100dvh; }
.nw-desk a { color: inherit; text-decoration: none; }
.nw-desk :where(input, textarea, select) { font: inherit; color: inherit; }
.nw-desk ::selection { background: var(--nw-mark); }
.w-ready .nw-desk { opacity: 1; }

/* ------------------------------------------------------------------ верхняя панель */
.nw-topbar { position: relative; z-index: 12; }
.nw-brand { color: var(--nw-text); }
button.nw-dsearch { text-align: left; cursor: text; font-size: var(--nw-d-fs); }
button.nw-dsearch > span:not(.nw-kbd) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (hover: hover) { button.nw-dsearch:hover { box-shadow: inset 0 0 0 1px var(--nw-separator); } }
.w-me { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; }
.w-me .nw-avatar { margin: 0; }
@media (hover: hover) { .w-me:hover { background: var(--nw-fill); } }

/* ------------------------------------------------------------------ боковая панель */
.nw-side { overflow-y: auto; scrollbar-width: thin; padding-bottom: 20px; }
.nw-side button.nw-nav { width: 100%; text-align: left; }
.w-nav__label { overflow: hidden; text-overflow: ellipsis; }
.w-side__more { display: flex; flex-direction: column; gap: 1px; }
.w-side__link { font-weight: var(--nw-w-regular); color: var(--nw-text-2); }
@media (hover: hover) { .w-side__link:hover { color: var(--nw-text); text-decoration: underline; } }
.nw-trip-tile { color: var(--nw-text); text-align: left; }
.w-trip-tile__t { min-width: 0; }
.w-trip-tile__t b, .w-trip-tile__t small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (hover: hover) { .nw-trip-tile:hover { box-shadow: inset 0 0 0 1px var(--nw-ring-idle); } }
.w-side__phone { display: flex; align-items: center; gap: 8px; margin: 14px 8px 0; font-size: .8125rem; color: var(--nw-link-ink) !important; font-weight: var(--nw-w-medium); }

/* ------------------------------------------------------------------ центр */
.nw-main { container-type: inline-size; container-name: main; }
.nw-main__head { flex: none; }
.w-head-sub { font-size: .8125rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.nw-filterbar { flex: none; overflow: hidden; }
.nw-filterbar > button { flex: none; }
.w-fchip-x { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; margin-right: -3px; color: inherit; opacity: .8; }
.w-fchip-x .nw-ic { width: 12px !important; height: 12px !important; }
@media (hover: hover) { .w-fchip-x:hover { background: color-mix(in srgb, var(--nw-accent) 18%, transparent); opacity: 1; } .nw-select:hover { background: var(--nw-fill); } .nw-fchip--add:hover { color: var(--nw-text); } }
.w-toggle { flex: 0 1 auto !important; min-width: 0; overflow: hidden; text-overflow: ellipsis; display: inline-block !important; line-height: 28px; }
.w-toggle .nw-ic { width: 14px; height: 14px; stroke-width: 2.4; vertical-align: -2px; margin-right: 4px; }
.w-toggle.is-on { color: var(--nw-text); }
.nw-seg-d > button { cursor: pointer; }
.w-scroll { flex: 1; min-height: 0; overflow: auto; padding-bottom: 110px; scrollbar-width: thin; outline: none; }
/* J/K и показ строки под меню (scrollIntoView «nearest») не прячут строку под липкую шапку таблицы, нижнюю строку
 * подсказок и панель «Выбрано N» — они лежат поверх прокрутки */
.w-scroll { scroll-padding-bottom: 48px; }
.w-scroll:has(thead) { scroll-padding-top: 40px; }
.nw-main:has(.nw-bulkbar) .w-scroll { scroll-padding-bottom: calc(var(--w-bar-bottom) + var(--w-bar-h) + 8px); }

/* Таблица: шапка липкая, кнопки сортировки, курсор ячейки, правка в ячейке */
.w-table { font-size: var(--nw-d-fs); }
.w-table thead th { position: sticky; top: 0; z-index: 3; background: var(--nw-card); }
.w-th { font: inherit; color: inherit; white-space: nowrap; }
@media (hover: hover) { button.w-th:hover { color: var(--nw-text); } }
.w-colpick { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 24px; height: 24px; border-radius: 6px; display: grid; place-items: center; color: var(--nw-text-2); }
.w-colpick .nw-ic { width: 16px; height: 16px; }
@media (hover: hover) { .w-colpick:hover { background: var(--nw-fill); color: var(--nw-text); } }
.w-table tbody tr[data-id] { cursor: default; outline: none; }
.w-table tbody tr[data-id]:focus-visible td { box-shadow: inset 0 2px 0 var(--nw-accent), inset 0 -2px 0 var(--nw-accent); }
.w-table tbody tr[data-id]:focus-visible td:first-child { box-shadow: inset 3px 0 0 var(--nw-accent), inset 0 2px 0 var(--nw-accent), inset 0 -2px 0 var(--nw-accent); }
.w-table td.is-cell { box-shadow: inset 0 0 0 2px var(--nw-accent); border-radius: 4px; }
.w-table td.is-editing { padding: 0 3px; overflow: visible; }
.w-cell-input { width: 100%; height: 30px; border: 0; border-radius: 6px; padding: 0 7px; background: var(--nw-d-raised); box-shadow: inset 0 0 0 2px var(--nw-accent); outline: none; }
.w-td-cb { cursor: pointer; }
.nw-cb { cursor: pointer; }
.w-cb-all { opacity: 0; transition: opacity var(--nw-dur-fast); }
.w-table thead:hover .w-cb-all, .w-cb-all.is-on, .w-cb-all:focus-visible { opacity: 1; }
.w-cb-dash { display: block; width: 8px; height: 2px; border-radius: 1px; background: currentColor; }   /* «выбрана часть» */
.nw-who small { flex: none; max-width: 60%; }
.nw-who small mark { padding: 0 1px; }
.nw-table tr.nw-group td .nw-ic { vertical-align: -3px; margin-right: 2px; color: var(--nw-text-2); }
.w-more { color: var(--nw-text-2); font-size: .8125rem; }
@media (hover: hover) { .w-more:hover { color: var(--nw-text); text-decoration: underline; } }
.w-empty-row td { height: auto; white-space: normal; }

/* Каналы в строке — кнопки того же вида, что квадратики макета */
.nw-chan > .w-chan { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--nw-separator); color: var(--nw-text-2); }
.nw-chan > .w-chan.is-preferred { background: var(--nw-accent-tint); box-shadow: none; color: var(--nw-accent-ink); }
@media (hover: hover) { .nw-chan > .w-chan:hover { box-shadow: inset 0 0 0 1.5px var(--nw-accent); } }

/* Список (вид «Список») */
.w-list { display: flex; flex-direction: column; }
.w-li { display: flex; align-items: center; gap: 12px; padding: 8px 20px 8px 18px; border-bottom: 1px solid var(--nw-d-row-line); outline: none; position: relative; }
.w-li.is-active { background: color-mix(in srgb, var(--nw-hint) 9%, var(--nw-card)); box-shadow: inset 3px 0 0 var(--nw-accent); }
.w-li.is-selected { background: var(--nw-accent-tint); }
.w-li:focus-visible { box-shadow: inset 0 0 0 2px var(--nw-accent); }
.w-li .nw-avatar { margin: 4px; }
.w-li__body { flex: 1; min-width: 0; }
.w-li__l1 { display: flex; gap: 10px; align-items: baseline; justify-content: space-between; font-size: .9375rem; }
.w-li__l1 b { font-weight: var(--nw-w-semibold); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.w-li__l1 span { font-size: .8125rem; flex: none; }
.w-li__l2, .w-li__l3 { font-size: .84375rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.w-li__l2 b { font-weight: var(--nw-w-medium); }
.w-li__ch { width: 34px; height: 34px; }
.w-li__ch .nw-ic { width: 18px; height: 18px; }
.w-lgroup { padding: 8px 18px; background: var(--nw-d-group-bg); font-size: .8125rem; font-weight: var(--nw-w-semibold); border-bottom: 1px solid var(--nw-d-row-line); }
.w-lgroup span { color: var(--nw-text-2); font-weight: var(--nw-w-regular); margin-left: 6px; }
.w-lgroup .nw-ic { vertical-align: -3px; color: var(--nw-text-2); }
.w-more--list { padding: 8px 20px; text-align: left; }

/* Подсказки и панель «Выбрано N» */
.nw-hintbar { z-index: 4; }
.w-hint-all { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; color: inherit; font: inherit; }
@media (hover: hover) { .w-hint-all:hover { color: var(--nw-text); } }
/* Высота и отступ панели «Выбрано N» — общие с снэкбаром: пока панель на экране, снэкбар встаёт над ней (ниже, «слои») */
.nw-desk { --w-bar-bottom: 54px; --w-bar-h: 40px; }
.nw-bulkbar { bottom: var(--w-bar-bottom); min-height: var(--w-bar-h); box-sizing: border-box; max-width: calc(100% - 24px); overflow: hidden; gap: 2px; }
.nw-bulkbar .nw-btn { padding: 0 9px; }
.nw-bulkbar .w-ico .w-lbl { display: inline; }
/* не влезла (широкий системный шрифт) — прячем подсказки клавиш в панели: они есть в нижней строке */
.nw-bulkbar.is-tight .nw-btn .nw-kbd { display: none; }
.nw-bulkbar.is-tighter .w-ico .w-lbl { display: none; }
@container main (max-width: 760px) {
  .nw-bulkbar .w-ico .w-lbl { display: none; }
  .nw-hintbar > span:nth-child(5) { display: none; }
}
@container main (max-width: 640px) {
  .nw-bulkbar .w-lbl { display: none; }
  .nw-hintbar > span:nth-child(n+4) { display: none; }
  .nw-filterbar .w-toggle { display: none; }
}

.w-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 56px 20px; text-align: center; font-size: .9375rem; white-space: normal; }
.w-empty b { font-size: 1.125rem; }
.w-empty .nw-btn { margin-top: 6px; }

/* ------------------------------------------------------------------ карточка */
.nw-pane { overflow-y: auto; scrollbar-width: thin; outline: none; }
.w-crumbs { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.w-attempt { margin-bottom: 12px; }
.w-hero { display: flex; gap: 14px; align-items: center; }
.w-hero__name { margin: 0; font-size: 1.375rem; line-height: 1.6875rem; font-weight: var(--nw-w-bold); letter-spacing: -0.02em; }
.w-hero__name small { font-size: .8125rem; font-weight: var(--nw-w-regular); color: var(--nw-text-2); letter-spacing: 0; }
.w-hero__sub { font-size: .875rem; line-height: 1.3rem; }
.w-hero__sub b { color: var(--nw-text); font-weight: var(--nw-w-medium); }
.w-facts { margin-top: 12px; }
button.nw-fact { cursor: pointer; }
@media (hover: hover) { button.nw-fact:hover { box-shadow: inset 0 0 0 1px var(--nw-ring-idle); } }
.w-actions { display: flex; gap: 6px; margin-top: 14px; flex-wrap: wrap; align-items: center; }
.w-actions--2 { margin-top: 6px; }
.w-link-btn { font: inherit; font-size: .8125rem; cursor: pointer; padding: 0; }
.nw-dstatus__line .w-link-btn { color: var(--nw-accent-ink); font-weight: var(--nw-w-medium); }
.w-dsec-link { font-size: .75rem; color: var(--nw-accent-ink); }
.w-para { font-size: .84375rem; line-height: 1.25rem; }
.nw-pane .nw-dsec > span:first-child { white-space: nowrap; flex: none; }
.nw-pane .nw-dsec > span:last-child { text-align: right; }
.w-note { min-height: 36px; border-radius: 10px; box-shadow: inset 0 0 0 1px var(--nw-separator); display: flex; align-items: flex-start; gap: 8px; padding: 0 8px 0 12px; margin-top: 12px; }
.w-note:focus-within { box-shadow: inset 0 0 0 1.5px var(--nw-accent); }
.w-note__ic { display: grid; place-items: center; height: 36px; color: var(--nw-text-2); }
.w-note textarea { flex: 1; min-width: 0; border: 0; background: transparent; resize: none; outline: none; padding: 8px 0; line-height: 1.25rem; min-height: 36px; font-size: var(--nw-d-fs); }
.w-note textarea::placeholder { color: var(--nw-text-2); opacity: 1; }
.w-note__save { margin-top: 8px; cursor: pointer; }
.w-tl { grid-template-columns: 64px minmax(0,1fr) auto; column-gap: 6px; }
.w-tl > * { height: auto; min-height: 30px; padding: 5px 0; align-items: flex-start; line-height: 1.25rem; }
.w-tl > .w-tl__t { display: block; white-space: normal; }
.w-tl__t b { font-weight: var(--nw-w-semibold); }
.w-tl__del { opacity: 0; }
.w-tl > :hover .w-tl__del, .w-tl__del:focus-visible, .w-tl > span:hover + span .w-tl__del { opacity: 1; }
@media (hover: none) { .w-tl__del { opacity: 1; } }
.w-scores .nw-scores__blur { filter: blur(5px); opacity: .8; user-select: none; }
.w-scores.is-revealed .nw-scores__blur { filter: none; opacity: 1; user-select: auto; }
.w-dval { font: inherit; text-align: left; cursor: text; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; border-radius: 4px; }
.w-dval.is-empty { color: var(--nw-text-2); }
@media (hover: hover) { .w-dval:hover { text-decoration: underline; text-decoration-color: var(--nw-ring-idle); text-underline-offset: 3px; } }
.w-data .w-cell-input { height: 26px; }
.w-copy { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 6px; }
@media (hover: hover) { .w-copy:hover { background: var(--nw-fill); color: var(--nw-text); } }
.w-pane-foot { font-size: .75rem; margin: 18px 0 0; }
.w-pane-empty__in { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; min-height: 60vh; color: var(--nw-text-2); font-size: .875rem; padding: 0 24px; }
.w-pane-empty__in b { color: var(--nw-text); font-size: 1rem; }
.w-pane-empty__in .nw-kbd { vertical-align: 1px; }

/* ------------------------------------------------------------------ слои: меню, ⌘K, диалоги, снэкбар */
#w-layers { position: absolute; left: 0; top: 0; width: 0; height: 0; z-index: 80; }
.w-pop { position: fixed; z-index: 97; min-width: 220px; max-width: calc(100vw - 16px); max-height: min(70vh, 560px); overflow-y: auto; padding: 6px; border-radius: 12px;
  background: var(--nw-d-raised); box-shadow: 0 16px 48px light-dark(rgba(0,0,0,.18), rgba(0,0,0,.6)), inset 0 0 0 1px var(--nw-separator); font-size: var(--nw-d-fs); scrollbar-width: thin; }
.w-pop--tall { max-height: min(78vh, 640px); }
.w-pop__title { padding: 6px 10px 6px; font-size: .75rem; font-weight: var(--nw-w-semibold); color: var(--nw-text-2); }
.w-pop__head { padding: 10px 10px 3px; font-size: .71875rem; font-weight: var(--nw-w-semibold); color: var(--nw-text-2); }
.w-pop__sep { height: 1px; background: var(--nw-separator); margin: 5px 4px; }
.w-pop__foot { padding: 8px 10px 4px; margin-top: 4px; border-top: 1px solid var(--nw-separator); font-size: .75rem; color: var(--nw-text-2); line-height: 1.05rem; }
.w-pop__note { margin: 6px 10px 2px; font-size: .75rem; color: var(--nw-text-2); line-height: 1.05rem; }
.w-pop__row { display: flex; gap: 6px; padding: 6px 4px 2px; }
.w-mi { width: 100%; min-height: 34px; padding: 4px 10px; border-radius: 8px; display: flex; align-items: center; gap: 10px; text-align: left; outline: none; cursor: pointer; }
.w-mi .nw-ic { width: 17px; height: 17px; color: var(--nw-text-2); }
.w-mi.is-active, .w-mi:focus-visible { background: var(--nw-accent-tint); }
.w-mi.is-checked { font-weight: var(--nw-w-semibold); }
.w-mi:disabled { opacity: .45; cursor: default; }
.w-mi__check { width: 17px; display: grid; place-items: center; color: var(--nw-accent-ink); }
.w-mi__check .nw-ic { color: var(--nw-accent-ink); stroke-width: 2.6; width: 15px; height: 15px; }
.w-mi__label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.w-mi__label small { color: var(--nw-text-2); font-size: .78125rem; font-weight: var(--nw-w-regular); margin-left: 6px; }
.w-mi .nw-kbd { margin-left: auto; }
.w-mi--check input { width: 16px; height: 16px; accent-color: var(--nw-accent-fill); margin: 0; }
.w-pick__field { display: flex; align-items: center; gap: 8px; height: 36px; margin: 0 4px 6px; padding: 0 10px; border-radius: 9px; background: var(--nw-page); color: var(--nw-text-2); }
.w-pick__field .nw-ic { width: 17px; height: 17px; }
.w-pick__field input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; color: var(--nw-text); }
.w-pick__empty { padding: 10px; color: var(--nw-text-2); font-size: .8125rem; line-height: 1.15rem; }
.w-prompt { padding: 2px 4px 4px; }
.w-input { width: 100%; height: 36px; border: 0; border-radius: 9px; padding: 0 10px; background: var(--nw-page); outline: none; box-shadow: inset 0 0 0 1px var(--nw-separator); }
.w-input:focus { box-shadow: inset 0 0 0 1.5px var(--nw-accent); }
.w-prompt__row { display: flex; gap: 6px; margin-top: 8px; }

.w-scrim { position: fixed; z-index: 88; }
.w-dialog { position: fixed; z-index: 90; left: 50%; top: 96px; transform: translateX(-50%); max-width: calc(100vw - 32px); border-radius: 16px; overflow: hidden;
  background: var(--nw-d-raised); box-shadow: 0 24px 80px light-dark(rgba(0,0,0,.22), rgba(0,0,0,.7)), inset 0 0 0 1px var(--nw-separator); font-size: var(--nw-d-fs); }
.w-cmdk .nw-cmdk__input .nw-ic { flex: none; }
.w-cmdk__q { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; outline: none; font-size: 1.125rem; caret-color: var(--nw-accent); }
.w-cmdk__q::placeholder { color: var(--nw-text-2); opacity: 1; }
.w-cmdk__hint { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 45%; }
.w-cmdk__list { max-height: min(56vh, 560px); overflow-y: auto; padding-bottom: 4px; scrollbar-width: thin; }
.w-cmdk .nw-cmdk__item { cursor: pointer; }
.w-cmdk .nw-cmdk__item > span:not(.nw-cmdk__keys):not(.nw-cmdk__label) { overflow: hidden; text-overflow: ellipsis; flex: none; max-width: 60%; }
.w-cmdk .nw-cmdk__item > small { flex: 1; min-width: 0; }
.w-cmdk .nw-cmdk__item .nw-avatar { margin: 0; }
.w-cmdk .nw-cmdk__label { flex: none; margin-left: 8px; }
.w-cmdk .nw-cmdk__item .nw-cmdk__label + .nw-cmdk__keys { margin-left: 4px; }
.w-cmdk .nw-cmdk__item:not(:has(.nw-cmdk__label)) .nw-cmdk__keys { margin-left: auto; }
.w-cmdk .nw-cmdk__item:has(.nw-cmdk__label) .nw-cmdk__label { margin-left: auto; }
.w-cmdk .nw-cmdk__foot { margin-top: 0; }

.w-form { padding: 16px 20px 18px; }
.w-form__head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px; }
.w-form__head b { font-size: 1.0625rem; }
.w-form__head .nw-ibtn { margin-left: auto; align-self: center; }
.w-form__field { display: block; }
.w-form__line { width: 100%; border: 0; border-radius: 12px; padding: 11px 14px; font-size: 1rem; line-height: 1.4rem; background: var(--nw-page); box-shadow: inset 0 0 0 1px var(--nw-separator); outline: none; resize: none; }
.w-form__line:focus { box-shadow: inset 0 0 0 1.5px var(--nw-accent); }
.w-form__chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 6px; min-height: 30px; align-items: center; font-size: .8125rem; }
.w-recog.is-pending { background: var(--nw-fill); }
.w-recog.is-pending small { color: var(--nw-text-2); }
.w-form__note { margin: 6px 0 12px; font-size: .8125rem; line-height: 1.2rem; min-height: 1.2rem; }
.w-form__row { display: flex; align-items: center; gap: 8px; }
.w-form__hint { margin-left: auto; font-size: .75rem; }
.w-form .nw-btn:disabled { opacity: .5; cursor: default; }
.w-keys__list { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; align-items: center; }
.w-keys__list dt { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.w-keys__list dd { margin: 0; color: var(--nw-text); }

.w-snack { position: fixed; z-index: 95; left: 16px; right: auto; bottom: 16px; width: 400px; max-width: calc(100vw - 32px); transition: opacity 160ms linear, bottom 200ms var(--nw-ease); animation: w-up 200ms var(--nw-ease); }
.w-snack.is-leaving { opacity: 0; }
/* Панель «Выбрано N» на экране (люди, сегодня, города, ритмы, импорт) — снэкбар над ней, а не поверх «Выбрано N · Город C».
 * Меню (.w-pop) выше снэкбара по слою, так что поднятый снэкбар не закроет и меню от панели. */
.nw-desk:has(.nw-main .nw-bulkbar) .w-snack { bottom: calc(var(--w-bar-bottom) + var(--w-bar-h) + 10px); }
.w-snack__k { font-size: .75rem; opacity: .7; font-weight: var(--nw-w-regular); }
.w-toast { position: fixed; z-index: 96; left: 50%; top: 10px; transform: translateX(-50%); max-width: calc(100vw - 32px); padding: 8px 16px; border-radius: 999px; background: var(--nw-snack-bg); color: var(--nw-snack-text); font-size: .84375rem; box-shadow: var(--nw-shadow-float); animation: w-fade 160ms var(--nw-ease); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@keyframes w-up { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes w-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .w-snack, .w-toast { animation: none; } .w-snack { transition: opacity 160ms linear; } }

/* ------------------------------------------------------------------ «Сегодня» */
.w-today { padding: 0 20px 24px; max-width: 760px; }
.w-sec { margin: 18px 0 8px; }
.w-tcard { border-radius: 12px; box-shadow: inset 0 0 0 1px var(--nw-separator); padding: 10px 14px 10px 10px; margin-bottom: 8px; cursor: pointer; outline: none; }
.w-tcard.is-active { cursor: default; box-shadow: inset 3px 0 0 var(--nw-accent), inset 0 0 0 1px var(--nw-separator); background: color-mix(in srgb, var(--nw-hint) 5%, var(--nw-card)); }
.w-tcard:focus-visible { box-shadow: inset 0 0 0 2px var(--nw-accent); }
@media (hover: hover) { .w-tcard:not(.is-active):hover { background: color-mix(in srgb, var(--nw-hint) 7%, var(--nw-card)); } }
.w-tcard__head { display: flex; gap: 12px; align-items: flex-start; }
.w-tcard__body { flex: 1; min-width: 0; padding-top: 2px; }
.w-tcard__l1 { display: flex; gap: 10px; justify-content: space-between; align-items: baseline; }
.w-tcard__l1 b { font-size: .96875rem; font-weight: var(--nw-w-semibold); }
.w-tcard__l1 span { font-size: .8125rem; white-space: nowrap; }
.w-tcard__l2 { font-size: .84375rem; }
.w-tcard__l2 b { font-weight: var(--nw-w-medium); }
.w-tcard__l3 { font-size: .84375rem; margin-top: 2px; }
.w-draft { margin: 10px 0 2px 64px; }
.w-draft__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.w-draft__text { width: 100%; border: 0; border-radius: 10px; padding: 10px 12px; font-size: .90625rem; line-height: 1.35rem; background: var(--nw-page); box-shadow: inset 0 0 0 1px var(--nw-separator); outline: none; resize: vertical; min-height: 64px; }
.w-draft__text:focus { box-shadow: inset 0 0 0 1.5px var(--nw-accent); }
.w-draft .w-actions { margin-top: 10px; }
.w-banner { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--nw-separator); margin: 2px 0 4px; }
.w-banner > span:nth-child(2) { flex: 1; min-width: 0; }
.w-banner b { display: block; font-size: .90625rem; }
.w-banner small { display: block; font-size: .78125rem; color: var(--nw-text-2); }
.w-banner .nw-banner__icon { width: 34px; height: 34px; }
.w-banner > .nw-ic { color: var(--nw-text-3); }
@media (hover: hover) { .w-banner:hover { box-shadow: inset 0 0 0 1px var(--nw-ring-idle); } }
.w-footnote { font-size: .8125rem; line-height: 1.15rem; color: var(--nw-text-2); margin: 8px 2px 0; }
.w-done { display: flex; flex-wrap: wrap; gap: 6px; }
.w-done__p { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px 0 6px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--nw-separator); font-size: .84375rem; }
.w-done__p .nw-avatar { margin: 0; }
.w-done__ok { width: 20px; height: 20px; border-radius: 50%; background: var(--nw-accent-fill); color: #fff; display: grid; place-items: center; }
.w-done__ok .nw-ic { width: 13px; height: 13px; stroke-width: 2.6; }
.w-bday .nw-ic { vertical-align: -3px; color: var(--nw-accent-ink); }
.w-bdays { display: flex; flex-direction: column; }
.w-bday { display: flex; align-items: center; gap: 10px; min-height: 40px; font-size: .84375rem; border-bottom: 1px solid var(--nw-d-row-line); }
.w-bday .nw-avatar { margin: 0; }
.w-bday > span:not(.nw-avatar) { flex: 1; }
.w-empty--today { align-items: flex-start; text-align: left; padding: 28px 0 8px; }

/* ------------------------------------------------------------------ «Города» и «Ритмы» */
.w-trip { margin: 0 20px 14px; padding: 12px 14px 6px; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--nw-separator); }
.w-trip__head { display: flex; align-items: center; gap: 10px; }
.w-trip__head b { display: block; font-size: .9375rem; }
.w-trip__head small { display: block; font-size: .78125rem; }
.w-trip .nw-banner__icon { width: 34px; height: 34px; }
.w-trip .w-table td:first-child, .w-trip .w-table th:first-child { padding-left: 4px; }
.w-cities tbody tr { cursor: pointer; }
.w-city { display: inline-flex; align-items: center; gap: 6px; font-weight: var(--nw-w-semibold); }
.w-city .nw-ic { color: var(--nw-text-2); }
.w-bar { display: inline-block; width: 70px; height: 4px; border-radius: 2px; background: var(--nw-fill); position: relative; overflow: hidden; vertical-align: middle; }
.w-bar i { position: absolute; inset: 0 auto 0 0; border-radius: 2px; background: var(--nw-fill-2); }
.w-num { margin-left: 8px; font-variant-numeric: tabular-nums; }
.w-table--mini td { height: 38px; }
.w-select { height: 30px; border: 0; border-radius: 8px; padding: 0 8px; background: var(--nw-d-raised); box-shadow: inset 0 0 0 1px var(--nw-separator); outline: none; max-width: 100%; cursor: pointer; }
.w-select:focus-visible { box-shadow: inset 0 0 0 1.5px var(--nw-accent); }

/* ------------------------------------------------------------------ «Импорт» */
.w-banner-imp { margin: 0 20px 10px; padding: 10px 14px; border-radius: 12px; background: var(--nw-page); display: flex; gap: 10px; align-items: center; font-size: .84375rem; line-height: 1.25rem; flex: none; }
.w-banner-imp .nw-ic { color: var(--nw-text-2); }
.w-tag-attn { background: var(--nw-accent-tint) !important; color: var(--nw-accent-ink) !important; }
.w-tag-skip { opacity: .7; }
.w-row-skip td:not(:first-child) { color: var(--nw-text-2); text-decoration: line-through; text-decoration-color: var(--nw-ring-idle); }
.w-row-skip .nw-tag { text-decoration: none; }
.w-imp-start { padding: 4px 20px 20px; max-width: 760px; }
.w-imp-sample { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--nw-separator); margin-bottom: 14px; }
.w-imp-sample > .nw-ic { color: var(--nw-accent-ink); }
.w-imp-sample > div { flex: 1; min-width: 0; }
.w-imp-sample b { display: block; font-size: .9375rem; }
.w-imp-sample span { display: block; font-size: .8125rem; line-height: 1.15rem; margin-top: 2px; }
.w-drop { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 26px 20px; border-radius: 14px; border: 1.5px dashed var(--nw-separator); text-align: center; font-size: .875rem; }
.w-drop.is-over { border-color: var(--nw-accent); background: var(--nw-accent-tint); }
.w-drop__ic { color: var(--nw-text-2); }
.w-drop b { font-size: 1rem; }
.w-drop__paste { width: 100%; max-width: 560px; margin-top: 6px; border: 0; border-radius: 10px; padding: 10px 12px; background: var(--nw-page); box-shadow: inset 0 0 0 1px var(--nw-separator); outline: none; resize: vertical; font-size: .8125rem; }
.w-drop__paste:focus { box-shadow: inset 0 0 0 1.5px var(--nw-accent); }
.w-drop__row { display: flex; gap: 8px; margin-top: 4px; }
.w-drop__row .nw-btn { position: relative; cursor: pointer; }
.w-file { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.w-imp-next { display: flex; gap: 12px; align-items: center; padding: 16px 20px; font-size: .8125rem; }
.w-imp-rh { padding: 4px 20px 8px; font-size: .84375rem; line-height: 1.25rem; }
.w-lead { font-size: .9375rem; font-weight: var(--nw-w-semibold); margin: 0 0 4px; }
.w-imp-done { display: flex; gap: 12px; align-items: center; padding: 6px 20px 16px; }
.w-imp-done > div { flex: 1; }
.w-imp-done b { display: block; font-size: .9375rem; }
.w-imp-done span.nw-t2 { display: block; font-size: .8125rem; }
.w-imp-tips { font-size: .84375rem; line-height: 1.3rem; color: var(--nw-text-2); }
.w-imp-tips p { margin: 0 0 10px; }
.w-kbtn { cursor: pointer; align-self: center; }
.w-decide > *, .w-raw > * { min-height: 30px; height: auto; }
.w-decide, .w-raw { column-gap: 10px; }
.w-raw-more { display: block; margin-top: 6px; font-size: .78125rem; }
.nw-main__head h2 { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.w-banner-imp .w-link-btn { font-size: inherit; margin-left: 4px; }
.w-raw > span:nth-child(3n+2) { display: block; line-height: 30px; overflow: hidden; text-overflow: ellipsis; }
.w-dup { margin-top: 14px; }
.w-dup .nw-pill { flex: none; }
.w-table tr[data-row] { cursor: default; outline: none; }
.w-table tr[data-row]:focus-visible td { box-shadow: inset 0 2px 0 var(--nw-accent), inset 0 -2px 0 var(--nw-accent); }

/* ------------------------------------------------------------------ адаптив: 1024–1279 боковая иконками, карточка поверх */
.w-mobile-note { display: none; }
@media (max-width: 1279px) {
  .nw-desk__body { grid-template-columns: 64px minmax(0,1fr); position: relative; }
  .nw-side { padding: 12px 8px; align-items: stretch; }
  .nw-side .nw-nav { justify-content: center; padding: 0; height: 36px; }
  .nw-side .nw-nav .nw-ic { width: 19px; height: 19px; }
  .w-nav__label, .nw-side .nw-nav__count, .nw-side .nw-nav__bar, .w-trip-tile__t, .w-side__more { display: none; }
  .nw-trip-tile { justify-content: center; padding: 8px 0; margin: 8px 0; }
  .w-side__phone { justify-content: center; margin: 10px 0 0; height: 36px; border-radius: 8px; }
  .w-side__phone .nw-ic { width: 19px; height: 19px; }
  .nw-main { border-right: 0; }
  .nw-pane { position: absolute; z-index: 20; top: 0; right: 0; bottom: 0; width: 400px; box-shadow: -14px 0 40px light-dark(rgba(0,0,0,.14), rgba(0,0,0,.55)), inset 1px 0 0 var(--nw-separator);
    transform: translateX(104%); visibility: hidden; transition: transform var(--nw-dur-push) var(--nw-ease-ios), visibility 0s linear var(--nw-dur-push); }
  .w-pane-open .nw-pane { transform: none; visibility: visible; transition: transform var(--nw-dur-push) var(--nw-ease-ios); }
  .nw-brand { width: auto; }
  .nw-topbar .nw-btn--ghost .w-lbl { display: none; }
}
@media (max-width: 1023px) {
  .nw-desk { grid-template-rows: var(--nw-d-top-h) auto minmax(0,1fr); }
  .nw-desk__body { grid-template-columns: minmax(0,1fr); grid-row: 3; }
  .nw-side { display: none; }
  .nw-pane { width: min(100%, 440px); }
  .nw-topbar .nw-btn--primary .w-lbl { display: none; }
  .w-mobile-note { display: block; grid-row: 2; padding: 8px 16px; font-size: .8125rem; background: var(--nw-page); border-bottom: 1px solid var(--nw-separator); color: var(--nw-text-2); }
  .w-mobile-note a { color: var(--nw-link-ink) !important; font-weight: var(--nw-w-semibold); }
}

/* Поля со своей подсветкой фокуса — без второй рамки (в ⌘K только каретка, как на доске) */
.nw-desk :is(.w-cmdk__q, .w-form__line, .w-input, .w-pick__field input, .w-cell-input, .w-note textarea, .w-draft__text, .w-drop__paste):focus-visible { outline: none; }
