/* ichakaev tasks — the same identity as the site, the subscription and english:
   dark ink, bone type, one signal colour (≤ 5% of the screen), Unbounded / Manrope / JetBrains Mono.
   Label colours are the only other hues, and they stay small: a square, a tint, a word. */
:root {
  --bg: #07080a;
  --surface: #0b0d10;
  --surface-2: #101318;
  --surface-3: #161a20;
  --surface-4: #1c2129;
  --line: rgba(236, 235, 230, .08);
  --line-2: rgba(236, 235, 230, .15);
  --line-3: rgba(236, 235, 230, .24);
  --text: #ecebe6;
  --text-2: #b6b8bd;
  --muted: #80868f;
  --signal: #c9f73a;
  --signal-rgb: 201, 247, 58;
  --alert: #ff5a4e;
  --alert-rgb: 255, 90, 78;
  --amber: #f0b44c;
  --sky: #7cb4ff;
  --violet: #b59cff;
  --display: "Unbounded", "Manrope", system-ui, sans-serif;
  --body: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  --radius: 18px;
  --gutter: 16px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --top-h: 60px;
  --list-w: 288px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  min-height: 100vh; min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font: 400 15px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.on-board { height: 100vh; height: 100dvh; overflow: hidden; display: flex; flex-direction: column; }
#app { display: contents; }
img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; text-align: inherit; }
b, strong { font-weight: 600; }
hr { border: 0; }
::selection { background: var(--signal); color: var(--bg); }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 2px; border-radius: 8px; }
.mono { font-family: var(--mono); letter-spacing: 0; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.hl { color: var(--signal); }
.ic { width: 18px; height: 18px; flex: none; }
[hidden] { display: none !important; }

.skip { position: fixed; top: 12px; left: 12px; z-index: 300; padding: 10px 16px; border-radius: 10px; background: var(--signal); color: var(--bg); font-weight: 600; transform: translateY(-160%); transition: transform .3s var(--ease); }
.skip:focus { transform: none; }
.loading { padding: 38vh 16px 0; text-align: center; color: var(--muted); font-size: 13px; }

.kicker { margin-bottom: 12px; font-size: 12px; letter-spacing: .06em; text-transform: lowercase; color: var(--muted); }
.kicker b { color: var(--signal); font-weight: 500; }
.display { font: 500 clamp(30px, 5.4vw, 50px)/1.04 var(--display); letter-spacing: -.045em; }
.lead { margin-top: 14px; max-width: 60ch; color: var(--text-2); font-size: clamp(15px, 1.6vw, 17px); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }

/* ------------------------------------------------------------------ buttons and fields */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 20px; border-radius: 999px;
  font: 600 14px/1 var(--body); white-space: nowrap;
  transition: transform .3s var(--ease), box-shadow .3s, border-color .2s, color .2s, background .2s, opacity .2s;
}
.btn .ic { width: 16px; height: 16px; }
.btn--primary { background: var(--signal); color: #090a0c; }
.btn--primary:hover { box-shadow: 0 10px 34px -10px rgba(var(--signal-rgb), .6); transform: translateY(-1px); }
.btn--ghost { border: 1px solid var(--line-2); color: var(--text); background: rgba(7, 8, 10, .35); }
.btn--ghost:hover { border-color: rgba(var(--signal-rgb), .55); color: var(--signal); }
.btn--ghost.is-active { border-color: rgba(var(--signal-rgb), .55); color: var(--signal); }
.btn--danger { border: 1px solid rgba(var(--alert-rgb), .45); color: var(--alert); }
.btn--danger:hover { background: rgba(var(--alert-rgb), .1); }
.btn--sm { min-height: 34px; padding: 0 14px; font-size: 13px; }
.btn--block { width: 100%; }
.btn:disabled { opacity: .4; cursor: default; box-shadow: none; transform: none; }
.btn .count { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--signal); color: var(--bg); font: 600 11px/1 var(--mono); }

.icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; color: var(--text-2); transition: color .2s, background .2s; flex: none; }
.icon-btn:hover { color: var(--text); background: var(--surface-4); }
.icon-btn--sm { width: 28px; height: 28px; border-radius: 8px; }
.icon-btn--sm .ic { width: 16px; height: 16px; }
.icon-btn.is-danger:hover { color: var(--alert); }

.link { color: var(--text-2); text-decoration: underline; text-decoration-color: var(--line-3); text-underline-offset: 3px; transition: color .2s; }
.link:hover { color: var(--signal); text-decoration-color: currentColor; }
.link.is-danger:hover { color: var(--alert); }

.field {
  display: block; width: 100%; min-height: 40px; padding: 9px 12px;
  border: 1px solid var(--line-2); border-radius: 10px; background: var(--bg);
  font-size: 14px; line-height: 1.45; resize: none; transition: border-color .2s, box-shadow .2s;
}
.field::placeholder { color: var(--muted); }
.field:focus { outline: none; border-color: rgba(var(--signal-rgb), .7); box-shadow: 0 0 0 3px rgba(var(--signal-rgb), .12); }
select.field { appearance: none; padding-right: 32px; background: var(--bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2380868f' stroke-width='2'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E") right 8px center / 18px no-repeat; }
input[type="date"].field { color-scheme: dark; }
.label { display: grid; gap: 6px; font-size: 12px; font-weight: 600; color: var(--text-2); }
.check { display: flex; align-items: center; gap: 10px; min-height: 34px; font-size: 14px; cursor: pointer; }
.check input[type="checkbox"], .check input[type="radio"] {
  appearance: none; flex: none; width: 18px; height: 18px; border: 1.5px solid var(--line-3); border-radius: 5px; background: var(--bg); cursor: pointer;
  display: grid; place-items: center; transition: background .15s, border-color .15s;
}
.check input[type="radio"] { border-radius: 50%; }
.check input:checked { background: var(--signal); border-color: var(--signal); }
.check input[type="checkbox"]:checked::after { content: ""; width: 9px; height: 5px; border: solid var(--bg); border-width: 0 0 2px 2px; transform: translateY(-1px) rotate(-45deg); }
.check input[type="radio"]:checked::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--bg); }
.check--inline { min-height: 0; }
.stack { display: grid; gap: 14px; }
.hint { font-size: 11px; color: var(--muted); }
.sep { height: 1px; margin: 8px 0; background: var(--line); }
.tag { padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 11px; color: var(--muted); }

/* ------------------------------------------------------------------ people */
.avatar {
  display: inline-grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%;
  background: var(--surface-4); border: 1px solid var(--line-2); color: var(--text);
  font: 600 11px/1 var(--mono); letter-spacing: 0; user-select: none;
}
.avatar--sm { width: 26px; height: 26px; font-size: 10px; }
.avatar--xs { width: 22px; height: 22px; font-size: 9px; }
.avatar--more { color: var(--muted); }

/* ------------------------------------------------------------------ header */
.top {
  position: sticky; top: 0; z-index: 50; flex: none;
  display: flex; align-items: center; gap: 18px;
  height: var(--top-h); padding: 0 var(--gutter);
  background: rgba(7, 8, 10, .82); -webkit-backdrop-filter: blur(14px) saturate(140%); backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.top__logo img { width: auto; height: 17px; }
.top__back { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border-radius: 999px; color: var(--text-2); font-size: 13px; font-weight: 600; transition: color .2s, background .2s; }
.top__back:hover { color: var(--text); background: var(--surface-3); }
.top__back .ic { width: 16px; height: 16px; }
.top__right { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.save { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); transition: background .3s; }
.save[data-state="saved"] { background: rgba(var(--signal-rgb), .5); }
.save[data-state="saving"] { background: var(--signal); animation: blink 1s steps(1) infinite; }
.save[data-state="offline"] { background: var(--alert); }
@keyframes blink { 50% { opacity: .2; } }
.user { display: inline-flex; align-items: center; gap: 10px; height: 38px; padding: 0 12px 0 4px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 13px; font-weight: 600; transition: border-color .2s; }
.user:hover { border-color: var(--line-3); }
.user .avatar { width: 28px; height: 28px; }
.user__name { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ------------------------------------------------------------------ covers: the brand's backgrounds */
.cover--grid {
  background:
    radial-gradient(50rem 32rem at 92% -12%, rgba(var(--signal-rgb), .08), transparent 60%),
    linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 76px 76px,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 76px 76px,
    var(--bg);
}
.cover--packets {
  background:
    radial-gradient(40rem 30rem at 100% 55%, rgba(var(--signal-rgb), .07), transparent 62%),
    repeating-linear-gradient(180deg, transparent 0 18px, rgba(var(--signal-rgb), .06) 18px 19px, transparent 19px 38px, rgba(236, 235, 230, .045) 38px 39px),
    var(--bg);
}
.cover--reticle {
  background:
    radial-gradient(36rem 26rem at 8% 108%, rgba(var(--signal-rgb), .08), transparent 62%),
    radial-gradient(rgba(236, 235, 230, .13) 1px, transparent 1.4px) 0 0 / 22px 22px,
    var(--bg);
}
.cover--plain { background: linear-gradient(180deg, var(--surface-2), var(--bg) 60%); }

/* ------------------------------------------------------------------ login */
.login {
  min-height: 100vh; min-height: 100dvh; display: grid; place-content: center; gap: 28px; padding: 48px var(--gutter);
  background:
    radial-gradient(50rem 34rem at 85% -10%, rgba(var(--signal-rgb), .07), transparent 60%),
    linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 76px 76px,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 76px 76px,
    var(--bg);
}
.login__card { position: relative; width: min(560px, 100%); padding: clamp(24px, 5vw, 44px); border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(180deg, rgba(255, 255, 255, .03), rgba(255, 255, 255, .008)), var(--surface); }
.login__card::before, .login__card::after { content: ""; position: absolute; width: 22px; height: 22px; border-color: var(--signal); border-style: solid; }
.login__card::before { top: -1px; left: -1px; border-width: 2px 0 0 2px; border-top-left-radius: 24px; }
.login__card::after { bottom: -1px; right: -1px; border-width: 0 2px 2px 0; border-bottom-right-radius: 24px; }
.login__logo { height: 22px; width: auto; margin-bottom: 36px; }
.login__widget { min-height: 48px; margin-top: 28px; }
.login__error { margin-top: 18px; padding: 10px 14px; border-radius: 10px; border: 1px solid rgba(var(--alert-rgb), .4); color: var(--alert); font-size: 14px; }
.login__dev { margin-top: 28px; padding-top: 20px; border-top: 1px dashed var(--line-2); }
.login__points { display: flex; flex-wrap: wrap; gap: 10px 22px; justify-content: center; color: var(--muted); font-size: 12px; }
.login__points li { display: inline-flex; align-items: center; gap: 8px; }
.login__points i { width: 7px; height: 7px; background: var(--signal); }

/* ------------------------------------------------------------------ home */
.main, .modal { outline: none; }
.home { width: min(1160px, 100% - var(--gutter) * 2); margin: 0 auto; padding: 44px 0 80px; }
body:not(.on-board) .main { min-height: calc(100dvh - var(--top-h)); background: radial-gradient(60rem 40rem at 85% -10%, rgba(var(--signal-rgb), .05), transparent 60%), var(--bg); }
.page-head { margin-bottom: 40px; }
.home__section + .home__section { margin-top: 40px; }
.section-title { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; font: 500 15px/1.2 var(--display); letter-spacing: -.02em; color: var(--text-2); }
.section-title .ic { width: 18px; height: 18px; color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.tile {
  position: relative; display: flex; flex-direction: column; justify-content: space-between; gap: 22px;
  height: 128px; padding: 16px 18px; border-radius: 16px; border: 1px solid var(--line-2); overflow: hidden;
  transition: border-color .25s, transform .35s var(--ease), box-shadow .35s;
}
.tile:hover { border-color: rgba(var(--signal-rgb), .45); transform: translateY(-2px); box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .9); }
.tile__title { padding-right: 34px; font: 500 16px/1.2 var(--display); letter-spacing: -.03em; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tile__meta { font-size: 11px; color: var(--muted); }
.tile__star { position: absolute; top: 12px; right: 12px; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; color: var(--muted); opacity: 0; transition: opacity .2s, color .2s, background .2s; }
.tile:hover .tile__star, .tile__star:focus-visible, .tile__star.is-on { opacity: 1; }
.tile__star:hover { background: rgba(7, 8, 10, .6); color: var(--text); }
.tile__star.is-on { color: var(--signal); }
.tile__star.is-on .ic { fill: currentColor; }
.tile--new { width: 100%; flex-direction: row; justify-content: center; align-items: center; gap: 10px; border-style: dashed; background: rgba(255, 255, 255, .015); color: var(--text-2); font-weight: 600; font-size: 14px; }
.tile--new:hover { color: var(--signal); }

.empty { width: min(720px, 100% - var(--gutter) * 2); margin: 0 auto; padding: 14vh 0; }
.empty .actions { margin-top: 26px; }

/* ------------------------------------------------------------------ board */
.on-board .main { flex: 1; min-height: 0; display: flex; }
.board { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.board-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 14px var(--gutter) 10px; }
.board-bar__left, .board-bar__right { display: flex; align-items: center; gap: 8px; min-width: 0; }
.board-title { min-width: 0; font: 500 clamp(18px, 2.2vw, 22px)/1.2 var(--display); letter-spacing: -.04em; }
.board-title__btn { max-width: min(46vw, 560px); padding: 4px 8px; margin-left: -8px; border-radius: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; transition: background .2s; }
.board-title__btn:hover { background: rgba(236, 235, 230, .07); }
.inline-edit--board { width: min(46vw, 560px); font: 500 clamp(18px, 2.2vw, 22px)/1.2 var(--display); letter-spacing: -.04em; }
.star.is-on { color: var(--signal); }
.star.is-on .ic { fill: currentColor; }
.members { display: flex; align-items: center; padding: 2px 4px; margin: 0 2px; border-radius: 999px; }
.members .avatar { width: 30px; height: 30px; border: 2px solid var(--bg); }
.members .avatar + .avatar { margin-left: -8px; }
.members:hover .avatar { border-color: var(--surface-3); }
.search { display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(7, 8, 10, .5); color: var(--muted); transition: border-color .2s; }
.search:focus-within { border-color: rgba(var(--signal-rgb), .6); color: var(--text-2); }
.search .ic { width: 15px; height: 15px; }
.search input { width: 190px; border: 0; outline: 0; background: none; font-size: 13px; color: var(--text); }
.search input::placeholder { color: var(--muted); }
.search input::-webkit-search-cancel-button { filter: invert(.6); }
.filter-note { display: flex; align-items: center; gap: 14px; padding: 0 var(--gutter) 8px; font-size: 12px; color: var(--muted); }

.canvas {
  flex: 1; min-height: 0; display: flex; align-items: flex-start; gap: 12px;
  padding: 6px var(--gutter) 18px; overflow-x: auto; overflow-y: hidden;
  scrollbar-color: var(--line-3) transparent;
}
.canvas::-webkit-scrollbar { height: 10px; }
.canvas::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 999px; border: 3px solid transparent; background-clip: content-box; }

.list {
  flex: none; display: flex; flex-direction: column; width: var(--list-w); max-height: 100%;
  border: 1px solid var(--line); border-radius: 16px; background: rgba(11, 13, 16, .94);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.list__head { display: flex; align-items: flex-start; gap: 6px; padding: 10px 8px 6px 12px; cursor: grab; touch-action: manipulation; }
.list__title { flex: 1; min-width: 0; font: 500 13.5px/1.3 var(--display); letter-spacing: -.02em; }
.list__title button { width: 100%; padding: 4px 6px; margin: -4px -6px; border-radius: 6px; overflow-wrap: anywhere; cursor: inherit; }
.list__title button:hover { background: rgba(236, 235, 230, .05); }
.list__title .inline-edit { font: 500 13.5px/1.3 var(--display); letter-spacing: -.02em; }
.list__count { padding-top: 2px; font-size: 11px; color: var(--muted); }
.list__cards { flex: 0 1 auto; min-height: 6px; display: flex; flex-direction: column; gap: 8px; padding: 4px 8px 2px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.list__add { display: flex; align-items: center; gap: 8px; margin: 6px 8px 8px; padding: 9px 10px; border-radius: 10px; color: var(--muted); font-size: 13px; font-weight: 600; transition: color .2s, background .2s; }
.list__add:hover { color: var(--text); background: rgba(236, 235, 230, .06); }
.list__add .ic { width: 16px; height: 16px; }
.list--add { background: rgba(11, 13, 16, .55); border-style: dashed; border-color: var(--line-2); }
.list--add .list__add--big { margin: 4px; padding: 12px; }
.list--add .composer { padding: 8px; }

.composer { display: grid; gap: 8px; padding: 2px 8px 8px; }
.composer__text { min-height: 64px; background: var(--surface-2); }
.composer__actions { display: flex; align-items: center; gap: 6px; }
.inline-edit { display: block; width: 100%; padding: 4px 6px; margin: -4px -6px; border: 1px solid rgba(var(--signal-rgb), .7); border-radius: 6px; background: var(--bg); outline: 0; resize: none; box-shadow: 0 0 0 3px rgba(var(--signal-rgb), .12); }

/* ------------------------------------------------------------------ card on the board */
.card {
  position: relative; flex: none; display: grid; gap: 8px; padding: 10px 12px 11px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2);
  box-shadow: 0 1px 0 rgba(0, 0, 0, .4); cursor: pointer;
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; touch-action: manipulation;
  transition: border-color .15s, background .15s;
}
.card:hover { border-color: var(--line-3); background: var(--surface-3); }
.card:focus-visible { outline-offset: 1px; }
.card__title { font-size: 14px; font-weight: 500; line-height: 1.4; overflow-wrap: anywhere; }
.card__labels { display: flex; flex-wrap: wrap; gap: 4px; }
.card__badges { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; color: var(--muted); }
.badge { display: inline-flex; align-items: center; gap: 4px; height: 22px; font: 500 11.5px/1 var(--mono); letter-spacing: 0; }
.badge .ic { width: 14px; height: 14px; }
.badge.is-done { color: var(--signal); }
.card__people { display: flex; margin-left: auto; }
.card__people .avatar + .avatar { margin-left: -5px; }
.card__people .avatar { border-color: var(--surface-2); }
.due { padding: 0 7px; margin-left: -2px; border-radius: 6px; transition: filter .2s; }
.due:hover { filter: brightness(1.25); }
.due--overdue { background: rgba(var(--alert-rgb), .14); color: var(--alert); }
.due--today, .due--soon { background: rgba(240, 180, 76, .13); color: var(--amber); }
.due--done { background: rgba(var(--signal-rgb), .14); color: var(--signal); }
.due--later { color: var(--muted); }

/* labels: a tinted chip with the colour's square */
.lbl { --c: var(--muted); display: inline-flex; align-items: center; gap: 6px; max-width: 100%; height: 20px; padding: 0 8px 0 6px; border-radius: 6px; background: color-mix(in srgb, var(--c) 13%, transparent); color: color-mix(in srgb, var(--c) 80%, var(--text)); font: 500 11px/1 var(--mono); letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lbl::before { content: ""; flex: none; width: 7px; height: 7px; border-radius: 2px; background: var(--c); }
.lbl--big { height: 28px; padding: 0 11px 0 9px; font-size: 12px; border-radius: 8px; }
.lbl--wide { width: 100%; height: 30px; padding: 0 10px; font-size: 12px; border-radius: 8px; }
.lbl--signal { --c: var(--signal); }
.lbl--alert { --c: var(--alert); }
.lbl--amber { --c: var(--amber); }
.lbl--sky { --c: var(--sky); }
.lbl--violet { --c: var(--violet); }
.lbl--bone { --c: var(--text); }
.lbl--muted { --c: var(--muted); }

/* ------------------------------------------------------------------ drag and drop */
.is-dragging, .is-dragging * { cursor: grabbing !important; user-select: none; }
.is-placeholder { background: rgba(236, 235, 230, .03) !important; border: 1px dashed var(--line-3) !important; box-shadow: none !important; }
.is-placeholder > * { visibility: hidden; }
.list.is-placeholder { background: rgba(236, 235, 230, .025) !important; }
.drag-ghost {
  position: fixed; top: 0; left: 0; z-index: 400; margin: 0; pointer-events: none; overflow: hidden;
  border-color: rgba(var(--signal-rgb), .55) !important; background: var(--surface-3) !important;
  box-shadow: 0 24px 50px -12px rgba(0, 0, 0, .85), 0 0 0 1px rgba(var(--signal-rgb), .15);
}
.drag-ghost.list { background: var(--surface) !important; }

/* ------------------------------------------------------------------ popovers */
.pop {
  position: fixed; z-index: 500; max-height: calc(100vh - 24px); overflow: auto;
  border: 1px solid var(--line-2); border-radius: 14px; background: var(--surface-3);
  box-shadow: 0 24px 60px -12px rgba(0, 0, 0, .9);
  animation: pop-in .18s var(--ease);
}
@keyframes pop-in { from { opacity: 0; translate: 0 -4px; } }
.pop__head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 8px 8px 14px; border-bottom: 1px solid var(--line); background: var(--surface-3); font-size: 13px; font-weight: 600; color: var(--text-2); }
.pop__head span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pop__body { display: grid; gap: 6px; padding: 12px; }
.pop__text { color: var(--text-2); font-size: 13px; line-height: 1.5; }
.pop__label { margin-top: 4px; font-size: 11px; letter-spacing: .06em; text-transform: lowercase; color: var(--muted); }
.menu-item { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 38px; padding: 0 10px; border-radius: 8px; font-size: 14px; font-weight: 500; color: var(--text); transition: background .15s, color .15s; }
.menu-item:hover { background: var(--surface-4); }
.menu-item .ic { width: 17px; height: 17px; color: var(--muted); }
.menu-item.is-danger, .menu-item.is-danger .ic { color: var(--alert); }
.flip { display: inline-flex; } .flip .ic { transform: scaleX(-1); }
.swatches { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.swatch { height: 46px; border-radius: 10px; border: 1px solid var(--line-2); transition: border-color .2s, box-shadow .2s; }
.swatch.is-on { border-color: var(--signal); box-shadow: 0 0 0 2px rgba(var(--signal-rgb), .25); }
.cover-preview { display: flex; align-items: flex-end; height: 86px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line-2); font: 500 15px/1.2 var(--display); letter-spacing: -.03em; overflow: hidden; }
.cover-preview span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 3px; border-radius: 10px; background: var(--bg); margin-bottom: 6px; }
.seg button { height: 30px; border-radius: 8px; font-size: 12px; font-weight: 600; color: var(--muted); text-align: center; }
.seg button.is-on { background: var(--surface-4); color: var(--text); }
.arch { display: grid; gap: 4px; }
.arch li { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 8px; padding: 8px 10px; border-radius: 10px; background: var(--surface-2); }
.arch__title { font-size: 14px; font-weight: 500; text-align: left; overflow-wrap: anywhere; }
.arch__meta { grid-column: 1; font-size: 11px; color: var(--muted); }
.arch li > .btn, .arch__actions { grid-column: 2; grid-row: 1 / span 2; display: flex; align-items: center; gap: 4px; }
.people { display: grid; gap: 2px; }
.people li { display: flex; align-items: center; gap: 10px; min-height: 42px; }
.people__name { flex: 1; min-width: 0; font-size: 14px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.copy { display: flex; gap: 6px; }
.copy .field { min-height: 34px; padding: 6px 10px; font-size: 11.5px; }
.pick { display: grid; gap: 4px; }
.pick__row { display: flex; align-items: center; gap: 4px; }
.pick__item { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 4px 8px; border-radius: 8px; font-size: 14px; transition: background .15s; }
.pick__row .pick__item { padding: 0; }
.pick__item:hover { background: var(--surface-4); }
.pick__row .pick__item:hover { background: none; filter: brightness(1.2); }
.pick__item > span:not(.avatar):not(.lbl) { flex: 1; }
.pick__check { width: 16px; height: 16px; color: var(--signal); margin-left: auto; flex: none; }
.pick__row .pick__check { position: relative; margin-left: -28px; margin-right: 8px; color: var(--text); }
.colors { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.color { height: 30px; border-radius: 8px; background: color-mix(in srgb, var(--c) 22%, transparent); border: 1px solid color-mix(in srgb, var(--c) 40%, transparent); position: relative; }
.color::after { content: ""; position: absolute; inset: 9px; border-radius: 3px; background: var(--c); }
.color.is-on { box-shadow: 0 0 0 2px var(--surface-3), 0 0 0 4px var(--c); }
.label-preview { display: grid; place-items: center; padding: 14px; border-radius: 10px; background: var(--bg); }
.quick { display: flex; flex-wrap: wrap; gap: 6px; }

/* ------------------------------------------------------------------ the open card */
.modal {
  width: min(860px, 100% - 24px); max-height: calc(100dvh - 48px); margin: auto;
  padding: 0; border: 1px solid var(--line-2); border-radius: 20px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .025), transparent 140px), var(--surface); color: var(--text);
  box-shadow: 0 40px 100px -20px rgba(0, 0, 0, .9); overflow: auto; overscroll-behavior: contain;
}
.modal[open] { animation: modal-in .28s var(--ease); }
@keyframes modal-in { from { opacity: 0; translate: 0 10px; } }
.modal::backdrop { background: rgba(3, 4, 5, .72); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.modal__body { padding: 22px clamp(16px, 3vw, 28px) 28px; }
.modal__head { position: relative; padding-right: 40px; margin-bottom: 22px; }
.modal__title-row { display: flex; align-items: flex-start; gap: 12px; }
.modal__ic { width: 22px; height: 22px; margin-top: 6px; color: var(--muted); }
.modal__title { flex: 1; min-width: 0; padding: 2px 8px; margin: 0 -8px; border: 1px solid transparent; border-radius: 8px; background: none; font: 500 clamp(19px, 2.4vw, 23px)/1.3 var(--display); letter-spacing: -.035em; resize: none; overflow: hidden; outline: 0; }
.modal__title:hover { background: rgba(236, 235, 230, .04); }
.modal__title:focus { border-color: rgba(var(--signal-rgb), .7); background: var(--bg); }
.modal__where { margin: 4px 0 0 34px; font-size: 13px; color: var(--muted); }
.modal__close { position: absolute; top: -4px; right: -8px; }
.archived-note { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; padding: 8px 12px; border-radius: 10px; background: rgba(240, 180, 76, .1); color: var(--amber); font-size: 12px; }
.archived-note .ic { width: 16px; height: 16px; }
.modal__grid { display: grid; grid-template-columns: minmax(0, 1fr) 184px; gap: 28px; }
.modal__main { display: grid; gap: 26px; align-content: start; padding-left: 34px; }
.modal__side { display: grid; gap: 6px; align-content: start; }
.modal__side .pop__label:not(:first-child) { margin-top: 12px; }
.side-btn { display: flex; align-items: center; gap: 10px; min-height: 36px; padding: 0 12px; border-radius: 10px; background: var(--surface-3); font-size: 13px; font-weight: 600; color: var(--text-2); transition: background .15s, color .15s; }
.side-btn:hover { background: var(--surface-4); color: var(--text); }
.side-btn .ic { width: 16px; height: 16px; color: var(--muted); }
.side-btn.is-danger { color: var(--alert); background: rgba(var(--alert-rgb), .1); }
.side-btn.is-danger .ic { color: var(--alert); }
.modal__stamp { margin-top: 14px; font-size: 11px; color: var(--muted); }

.meta { display: flex; flex-wrap: wrap; gap: 18px 26px; }
.meta__block { display: grid; gap: 6px; }
.meta__row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.meta__add { background: var(--surface-3); }
.due-chip { display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 10px; border-radius: 8px; background: var(--surface-3); font: 500 13px/1 var(--body); }
.due-chip:hover { background: var(--surface-4); }
.due-chip__state { padding: 2px 6px; border-radius: 4px; font-size: 10.5px; text-transform: lowercase; }
.due-chip.due--overdue .due-chip__state { background: var(--alert); color: var(--bg); }
.due-chip.due--today .due-chip__state, .due-chip.due--soon .due-chip__state { background: var(--amber); color: var(--bg); }
.due-chip.due--done .due-chip__state { background: var(--signal); color: var(--bg); }
.due-chip.due--overdue, .due-chip.due--today, .due-chip.due--soon, .due-chip.due--done { color: var(--text); }

.block { display: grid; gap: 12px; }
.block__title { display: flex; align-items: center; gap: 10px; margin-left: -34px; font: 500 14px/1.2 var(--display); letter-spacing: -.02em; }
.block__title .ic { width: 22px; height: 22px; color: var(--muted); }
.block__title .btn { margin-left: auto; }
.desc { font-size: 14.5px; line-height: 1.65; color: var(--text-2); overflow-wrap: anywhere; cursor: text; }
.desc a, .comment__text a { color: var(--signal); text-decoration: underline; text-underline-offset: 3px; }
.desc-empty { width: 100%; min-height: 64px; padding: 12px 14px; border-radius: 12px; background: var(--surface-3); color: var(--muted); font-size: 14px; text-align: left; transition: background .15s; }
.desc-empty:hover { background: var(--surface-4); }
.desc-edit { display: grid; gap: 10px; }
.desc-edit .field { min-height: 120px; }

.progress { display: flex; align-items: center; gap: 12px; }
.progress__n { width: 34px; font-size: 11px; color: var(--muted); }
.progress__bar { flex: 1; height: 6px; border-radius: 999px; background: var(--surface-4); overflow: hidden; }
.progress__bar i { display: block; height: 100%; border-radius: inherit; background: var(--text-2); transition: width .4s var(--ease), background .3s; }
.progress__bar i.is-full { background: var(--signal); }
.checklist { display: grid; gap: 2px; margin-left: -34px; }
.checklist li { display: flex; align-items: center; gap: 4px; padding: 2px 4px 2px 6px; border-radius: 8px; transition: background .15s; }
.checklist li:hover { background: rgba(236, 235, 230, .035); }
.checklist .check { flex: 1; gap: 14px; }
.checklist__text { flex: 1; min-width: 0; padding: 6px 8px; border: 1px solid transparent; border-radius: 6px; background: none; font-size: 14px; outline: 0; }
.checklist__text:focus { border-color: rgba(var(--signal-rgb), .6); background: var(--bg); }
.checklist li.is-done .checklist__text:not(:focus) { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--line-3); }
.checklist__del { opacity: 0; }
.checklist li:hover .checklist__del, .checklist__del:focus-visible { opacity: 1; }
.checklist__add { display: flex; gap: 8px; }
.checklist__add .field { min-height: 34px; padding: 6px 10px; }

.comment-new { display: flex; gap: 12px; margin-left: -42px; }
.comment-new__box { flex: 1; display: grid; gap: 8px; }
.comment-new .field { min-height: 40px; }
.comments { display: grid; gap: 16px; margin-left: -42px; }
.comment { display: flex; gap: 12px; }
.comment__body { flex: 1; min-width: 0; }
.comment__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; font-size: 13px; }
.comment__head .mono { font-size: 11px; }
.comment__text { margin: 4px 0 2px; padding: 9px 12px; border-radius: 4px 12px 12px 12px; background: var(--surface-3); font-size: 14px; overflow-wrap: anywhere; }

/* ------------------------------------------------------------------ toast */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 600; display: flex; align-items: center; gap: 14px;
  max-width: min(520px, calc(100% - 32px)); padding: 12px 14px 12px 18px; border-radius: 12px;
  border: 1px solid var(--line-2); background: var(--surface-4); color: var(--text); font-size: 13px;
  box-shadow: 0 20px 50px -12px rgba(0, 0, 0, .9);
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none; transition: opacity .25s, transform .35s var(--ease);
}
.toast.is-on { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.toast.is-alert { border-color: rgba(var(--alert-rgb), .5); }
.toast__btn { flex: none; padding: 6px 10px; border-radius: 8px; color: var(--signal); font-weight: 600; }
.toast__btn:hover { background: rgba(var(--signal-rgb), .1); }

/* ------------------------------------------------------------------ v2: people, header */
.avatar { position: relative; overflow: hidden; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.avatar--lg { width: 48px; height: 48px; font-size: 15px; }
.avatar--empty { color: var(--muted); background: none; border-style: dashed; }
.avatar--empty .ic { width: 60%; height: 60%; }
.member { position: relative; display: inline-flex; border-radius: 50%; }
.member.is-online::after { content: ""; position: absolute; right: -1px; bottom: -1px; width: 9px; height: 9px; border-radius: 50%; background: var(--signal); border: 2px solid var(--bg); }
.members .member + .member, .members .member + .avatar { margin-left: -8px; }
.members .member .avatar { width: 30px; height: 30px; border: 2px solid var(--bg); }
.top__search { display: inline-flex; align-items: center; gap: 10px; height: 36px; min-width: 0; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); font-size: 13px; transition: border-color .2s, color .2s; }
.top__search:hover { border-color: var(--line-3); color: var(--text-2); }
.top__search .ic { width: 15px; height: 15px; }
kbd { padding: 2px 6px; border-radius: 5px; border: 1px solid var(--line-2); background: var(--surface-2); font-size: 10.5px; color: var(--muted); }
.bell { position: relative; }
.bell__n { position: absolute; top: 2px; right: 0; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 999px; background: var(--signal); color: var(--bg); font-size: 10px; font-weight: 600; line-height: 17px; text-align: center; }
.profile { display: flex; align-items: center; gap: 12px; }
.profile__name { font-weight: 600; font-size: 15px; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; padding: 10px 12px; border-radius: 10px; background: var(--bg); font-size: 12px; }
.facts dt { color: var(--muted); }
.copy-row { display: flex; }
.warn { padding: 8px 10px; border-radius: 8px; background: rgba(240, 180, 76, .1); color: var(--amber); }
.tag--icon { display: inline-flex; align-items: center; gap: 5px; }
.tag--icon .ic { width: 12px; height: 12px; }
.login__facts { display: grid; gap: 10px; margin-top: 22px; color: var(--text-2); }
.login__facts li { display: flex; gap: 10px; align-items: flex-start; }
.login__facts .ic { width: 16px; height: 16px; margin-top: 2px; color: var(--signal); }
.tiles--closed { margin-top: 14px; opacity: .7; }

/* notifications */
.note-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.notes { display: grid; gap: 2px; margin: 0 -6px; }
.note { display: flex; gap: 10px; width: 100%; padding: 9px 8px; border-radius: 10px; text-align: left; transition: background .15s; }
.note:hover { background: var(--surface-4); }
.notes li.is-new .note { background: rgba(var(--signal-rgb), .05); }
.notes li.is-new .note::after { content: ""; flex: none; width: 7px; height: 7px; margin-top: 7px; border-radius: 50%; background: var(--signal); }
.note__ic { display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--surface-4); color: var(--text-2); }
.note__ic .ic { width: 14px; height: 14px; }
.note__body { flex: 1; min-width: 0; display: grid; gap: 3px; }
.note__text { font-size: 13px; line-height: 1.45; }
.note__quote { display: block; margin-top: 3px; padding-left: 8px; border-left: 2px solid var(--line-3); color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.note__meta { font-size: 10.5px; color: var(--muted); }
.empty-note { display: grid; justify-items: center; gap: 8px; padding: 24px 8px; text-align: center; color: var(--muted); font-size: 13px; }
.empty-note .ic { width: 26px; height: 26px; }

/* search across boards */
.gs__results { display: grid; gap: 2px; max-height: 60vh; overflow: auto; }
.gs__item { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 40px; padding: 6px 8px; border-radius: 8px; text-align: left; font-size: 14px; transition: background .15s; }
.gs__item:hover, .gs__item:focus-visible { background: var(--surface-4); }
.gs__item > .ic { width: 16px; height: 16px; color: var(--muted); }
.gs__text { display: grid; min-width: 0; }
.gs__text > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gs__item .tag { margin-left: 6px; }
.gs__cover { flex: none; width: 26px; height: 18px; border-radius: 4px; border: 1px solid var(--line-2); }

/* keyboard */
.modal--small { width: min(520px, 100% - 24px); }
.block__title--flat { margin: 0; }
.keys { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin-bottom: 14px; font-size: 14px; }
.keys dt { text-align: right; }

/* ------------------------------------------------------------------ v2: board */
.banner { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 var(--gutter) 10px; padding: 10px 14px; border-radius: 12px; border: 1px solid rgba(240, 180, 76, .35); background: rgba(240, 180, 76, .08); color: var(--amber); font-size: 13px; }
.banner .ic { width: 16px; height: 16px; }
.banner .btn { margin-left: auto; }
.list { --lc: transparent; border-top: 3px solid var(--lc); }
.list--signal { --lc: var(--signal); } .list--alert { --lc: var(--alert); } .list--amber { --lc: var(--amber); } .list--sky { --lc: var(--sky); }
.list--violet { --lc: var(--violet); } .list--bone { --lc: var(--text); } .list--muted { --lc: var(--muted); }
.list--add { border-top-width: 1px; }
.list--collapsed { width: 46px; align-self: stretch; max-height: 100%; }
.list__expand { display: flex; flex-direction: column; align-items: center; gap: 12px; width: 100%; height: 100%; padding: 12px 0; border-radius: 14px; transition: background .15s; }
.list__expand:hover { background: rgba(236, 235, 230, .04); }
.list__vtitle { writing-mode: vertical-rl; font: 500 13px/1.2 var(--display); letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-height: 60vh; }
.card.is-done .card__title { color: var(--text-2); }
.card__cover { height: 30px; margin: -10px -12px 0; border-radius: 11px 11px 0 0; background: var(--c); }
.card__cover--img { height: auto; max-height: 160px; overflow: hidden; background: var(--surface-4); }
.card__cover--img img { width: 100%; max-height: 160px; object-fit: cover; }
.card.has-cover { padding-top: 10px; }
.card__edit { position: absolute; top: 6px; right: 6px; z-index: 1; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--surface-4); color: var(--text-2); opacity: 0; transition: opacity .15s, color .15s; }
.card:hover .card__edit, .card:focus-visible .card__edit, .card__edit:focus-visible { opacity: 1; }
.card__edit:hover { color: var(--text); }
.card__edit .ic { width: 15px; height: 15px; }
.card:not(.has-cover) .card__title { padding-right: 18px; }
.quick__title { min-height: 70px; font-weight: 500; }
.quick__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; margin-top: 6px; }
.quick__grid .menu-item { min-height: 34px; font-size: 13px; }
.invite { display: flex; gap: 6px; }
.invite .field:first-child { flex: 1; min-width: 0; min-height: 34px; padding: 6px 10px; font-size: 13px; }
.field--sm { width: auto; min-height: 34px; padding: 4px 28px 4px 8px; font-size: 12px; }
.people__handle { display: block; font-size: 11px; }
.people li .field--sm { flex: none; }
.acts { display: grid; gap: 12px; }
.act { display: flex; gap: 10px; }
.act__body { flex: 1; min-width: 0; font-size: 13px; line-height: 1.45; }
.act__body p { color: var(--text-2); }
.act__body p b { color: var(--text); font-weight: 600; }
.act__card { color: var(--text); font-weight: 600; text-decoration: none; }
.date-row { display: grid; grid-template-columns: 92px 1fr; align-items: center; gap: 8px; }
.date-pair { display: grid; grid-template-columns: 1fr 92px; gap: 6px; }
.date-row .field { min-height: 36px; padding: 6px 8px; }
.field:disabled { opacity: .4; }
input[type="time"].field { color-scheme: dark; }
.cover-pics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.cover-pic { height: 56px; border-radius: 8px; overflow: hidden; border: 2px solid transparent; background: var(--surface-4); }
.cover-pic img { width: 100%; height: 100%; object-fit: cover; }
.cover-pic.is-on { border-color: var(--signal); }
.color { --c: var(--muted); }

/* ------------------------------------------------------------------ v2: markdown */
.md { display: grid; gap: 8px; overflow-wrap: anywhere; }
.md h4, .md h5, .md h6 { font: 500 15px/1.3 var(--display); letter-spacing: -.02em; color: var(--text); }
.md h4 { font-size: 17px; }
.md ul, .md ol { display: grid; gap: 4px; padding-left: 20px; }
.md ul { list-style: disc; }
.md ol { list-style: decimal; }
.md li::marker { color: var(--muted); }
.md li.task { list-style: none; margin-left: -20px; display: flex; gap: 8px; align-items: baseline; }
.md li.task.is-done { color: var(--muted); text-decoration: line-through; }
.task__box { display: inline-grid; place-items: center; flex: none; width: 15px; height: 15px; border: 1.5px solid var(--line-3); border-radius: 4px; font-size: 10px; color: var(--bg); transform: translateY(2px); }
.md li.task.is-done .task__box { background: var(--signal); border-color: var(--signal); }
.md blockquote { padding-left: 12px; border-left: 2px solid var(--line-3); color: var(--muted); }
.md code { padding: 1px 5px; border-radius: 5px; background: var(--surface-4); font: 12.5px/1.5 var(--mono); }
.md pre { padding: 10px 12px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line); overflow: auto; }
.md pre code { padding: 0; background: none; }
.md hr { height: 1px; background: var(--line-2); }
.md a { color: var(--signal); text-decoration: underline; text-underline-offset: 3px; }
.mention { padding: 0 4px; border-radius: 5px; background: rgba(var(--signal-rgb), .14); color: var(--signal); font-weight: 600; }

/* ------------------------------------------------------------------ v2: open card */
.modal__cover { position: relative; height: 96px; margin: -22px clamp(-28px, -3vw, -16px) 18px; background: var(--c); }
.modal__cover--img { height: 180px; background: var(--bg); display: grid; place-items: center; overflow: hidden; }
.modal__cover--img img { max-height: 180px; width: auto; max-width: 100%; object-fit: contain; }
.modal__cover-btn { position: absolute; right: 14px; bottom: 12px; background: rgba(7, 8, 10, .7); }
.modal.is-drop::after { content: "Отпустите — файл прикрепится к карточке"; position: fixed; inset: 10px; display: grid; place-items: center; border: 2px dashed var(--signal); border-radius: 18px; background: rgba(7, 8, 10, .82); color: var(--signal); font: 500 18px/1.3 var(--display); pointer-events: none; z-index: 5; }
.side-btn.is-on { color: var(--signal); background: rgba(var(--signal-rgb), .1); }
.side-btn.is-on .ic { color: var(--signal); }
.due-chip:disabled { cursor: default; }
.due-chip__bell { display: inline-flex; color: var(--muted); }
.due-chip__bell .ic { width: 14px; height: 14px; }
.draft-note { padding: 8px 12px; border-radius: 10px; background: rgba(240, 180, 76, .08); color: var(--amber); }
.block__tools { display: flex; gap: 6px; margin-left: auto; }
.block__title .btn { margin-left: auto; }
.block__tools .btn { margin-left: 0; }
.checklist__name { flex: 1; min-width: 0; padding: 4px 6px; margin-left: -6px; border: 1px solid transparent; border-radius: 6px; background: none; font: inherit; letter-spacing: inherit; outline: 0; }
.checklist__name:hover { background: rgba(236, 235, 230, .04); }
.checklist__name:focus { border-color: rgba(var(--signal-rgb), .6); background: var(--bg); }
.checklist__grip { width: 10px; color: var(--muted); font-size: 11px; letter-spacing: -2px; cursor: grab; opacity: 0; }
.checklist li:hover .checklist__grip { opacity: 1; }
.checklist li.is-moving { opacity: .4; }
.checklist li.is-over { box-shadow: inset 0 2px 0 var(--signal); }
.checklist__new { justify-self: start; }
.files { display: grid; gap: 8px; }
.file { display: flex; gap: 12px; align-items: flex-start; }
.file__thumb { display: grid; place-items: center; flex: none; width: 96px; height: 64px; border-radius: 8px; overflow: hidden; background: var(--surface-3); }
.file__thumb img { width: 100%; height: 100%; object-fit: cover; }
.file__ext { font-size: 12px; font-weight: 600; text-transform: uppercase; color: var(--text-2); }
.file__ext .ic { width: 20px; height: 20px; }
.file__body { flex: 1; min-width: 0; display: grid; gap: 3px; }
.file__name { font-size: 14px; font-weight: 600; text-align: left; overflow-wrap: anywhere; }
.file__name:hover { color: var(--signal); }
.file__actions { display: flex; flex-wrap: wrap; gap: 4px 12px; }
.file.is-uploading .progress__bar { height: 4px; }
.viewer { max-width: 96vw; max-height: 96vh; padding: 0; border: 0; background: transparent; color: var(--text); }
.viewer::backdrop { background: rgba(3, 4, 5, .9); }
.viewer__bar { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: 13px; }
.viewer__bar span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.viewer__img { max-width: 96vw; max-height: calc(96vh - 60px); border-radius: 8px; }
.comment__actions { display: flex; gap: 10px; }
.comment__edit { display: grid; gap: 8px; margin-top: 4px; }
.comment__text.md { gap: 6px; }
.comment-new__box { position: relative; }
.mentions { position: absolute; left: 0; top: 46px; z-index: 3; width: min(320px, 100%); padding: 4px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface-3); box-shadow: 0 16px 40px -12px rgba(0, 0, 0, .9); }
.mentions li button { display: flex; align-items: center; gap: 8px; width: 100%; padding: 6px 8px; border-radius: 6px; font-size: 13px; text-align: left; }
.mentions li.is-on button, .mentions li button:hover { background: var(--surface-4); }

/* ------------------------------------------------------------------ v3: views, card details */
.views { display: inline-flex; gap: 2px; padding: 3px; margin-left: 4px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(7, 8, 10, .5); }
.views button { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 999px; color: var(--muted); font-size: 12.5px; font-weight: 600; transition: color .15s, background .15s; }
.views button:hover { color: var(--text); }
.views button.is-on { background: var(--surface-4); color: var(--text); }
.views .ic { width: 15px; height: 15px; }
.list__eye { display: inline-flex; padding-top: 3px; color: var(--muted); }
.list__eye .ic { width: 13px; height: 13px; }
.list__count.is-over { color: var(--alert); font-weight: 600; }
.card__labels button.lbl { cursor: pointer; }
.card__labels.is-short { gap: 4px; }
.card__labels.is-short .lbl { width: 36px; height: 7px; padding: 0; border-radius: 4px; background: var(--c); }
.card__labels.is-short .lbl::before { display: none; }
.card__row { display: flex; align-items: flex-start; gap: 6px; }
.card__row .card__title { flex: 1; min-width: 0; }
.card__done { display: none; place-items: center; flex: none; width: 18px; height: 18px; margin-top: 1px; border-radius: 50%; border: 1.5px solid var(--line-3); color: transparent; transition: background .15s, border-color .15s, color .15s; }
.card__done .ic { width: 11px; height: 11px; stroke-width: 2.6; }
.card:hover .card__done, .card:focus-visible .card__done, .card__done.is-on { display: inline-grid; }
.card__done:hover { border-color: var(--signal); color: var(--signal); }
.card__done.is-on { background: var(--signal); border-color: var(--signal); color: var(--bg); }
.card.is-done .card__title { text-decoration: line-through; text-decoration-color: var(--line-3); }
.card.is-template { border-style: dashed; }
.badge--tpl { padding: 0 6px; border-radius: 5px; background: var(--surface-4); color: var(--text-2); }
.composer__tpl { margin-left: auto; }
.tile--import { height: 54px; margin-top: 0; }
.tiles > li:has(.tile--import) { align-self: start; }

/* table view */
.table-wrap { flex: 1; min-height: 0; margin: 0 var(--gutter) 18px; overflow: auto; border: 1px solid var(--line); border-radius: 14px; background: rgba(11, 13, 16, .94); }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { position: sticky; top: 0; z-index: 1; background: var(--surface-2); border-bottom: 1px solid var(--line-2); text-align: left; white-space: nowrap; }
.tbl th button { width: 100%; padding: 10px 12px; color: var(--muted); font: 500 11px/1 var(--mono); letter-spacing: .04em; text-transform: lowercase; text-align: left; }
.tbl th button:hover { color: var(--text); }
.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tbody tr { cursor: pointer; transition: background .12s; }
.tbl tbody tr:hover, .tbl tbody tr:focus-visible { background: var(--surface-3); outline: none; }
.tbl tr.is-done .tbl__title { color: var(--text-2); }
.tbl__title { min-width: 220px; font-weight: 500; }
.tbl__title .tag { margin-left: 8px; }
.tbl__ok { display: inline-grid; place-items: center; width: 16px; height: 16px; margin-right: 8px; border-radius: 50%; background: var(--signal); color: var(--bg); vertical-align: -3px; }
.tbl__ok .ic { width: 10px; height: 10px; stroke-width: 2.6; }
.tbl__list { display: inline-block; padding: 2px 8px; border-radius: 6px; border-left: 3px solid var(--lc, var(--line-3)); background: var(--surface-3); white-space: nowrap; font-size: 12.5px; }
.tbl__labels { display: flex; flex-wrap: wrap; gap: 4px; }
.empty-view { padding: 40px 16px; text-align: center; color: var(--muted); }

/* calendar view */
.calendar { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 10px; padding: 0 var(--gutter) 18px; overflow: auto; }
.cal-head { display: flex; align-items: center; gap: 8px; }
.cal-title { min-width: 170px; text-align: center; font: 500 17px/1.2 var(--display); letter-spacing: -.03em; }
.cal-head .hint { margin-left: auto; }
.cal-body { display: grid; grid-template-columns: 1fr 220px; gap: 12px; align-items: start; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.cal-dow { padding: 2px 6px; font-size: 11px; color: var(--muted); }
.cal-day { display: flex; flex-direction: column; gap: 3px; min-height: 104px; padding: 6px; border-radius: 10px; border: 1px solid var(--line); background: rgba(11, 13, 16, .9); transition: border-color .15s, background .15s; }
.cal-day.is-out { opacity: .45; }
.cal-day.is-today { border-color: rgba(var(--signal-rgb), .55); }
.cal-day.is-today .cal-num { color: var(--signal); }
.cal-day.is-over { border-color: var(--signal); background: rgba(var(--signal-rgb), .06); }
.cal-num { font-size: 11px; color: var(--muted); }
.cal-card { display: block; width: 100%; padding: 3px 6px; border-radius: 6px; background: var(--surface-3); border-left: 3px solid var(--line-3); font-size: 12px; line-height: 1.3; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.cal-card:hover { background: var(--surface-4); }
.cal-card .mono { color: var(--muted); font-size: 10.5px; }
.cal-card.due--overdue { border-left-color: var(--alert); }
.cal-card.due--soon { border-left-color: var(--amber); }
.cal-card.due--done, .cal-card.is-done { border-left-color: var(--signal); color: var(--text-2); text-decoration: line-through; text-decoration-color: var(--line-3); }
.cal-card[draggable="true"] { cursor: grab; }
.cal-more { font-size: 10.5px; color: var(--muted); }
.cal-side { display: grid; gap: 4px; padding: 10px; border-radius: 12px; border: 1px dashed var(--line-2); background: rgba(11, 13, 16, .7); max-height: 70vh; overflow: auto; }
.cal-card--free { white-space: normal; }

/* checklist items, reactions */
.item-due { flex: none; padding: 2px 7px; border-radius: 6px; background: var(--surface-3); font: 500 11px/1.4 var(--mono); color: var(--text-2); }
.item-due.is-late { background: rgba(var(--alert-rgb), .14); color: var(--alert); }
.item-who { flex: none; display: inline-flex; border-radius: 50%; }
.reactions { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0 2px; }
.reaction { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 8px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface-2); font-size: 13px; transition: border-color .15s, background .15s; }
.reaction .mono { font-size: 11px; color: var(--text-2); }
.reaction.is-on { border-color: rgba(var(--signal-rgb), .55); background: rgba(var(--signal-rgb), .08); }
.reaction--add { color: var(--muted); font-size: 12px; opacity: 0; }
.comment:hover .reaction--add, .reaction--add:focus-visible, .reactions:has(.reaction:not(.reaction--add)) .reaction--add { opacity: 1; }
.emoji-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.emoji { height: 40px; border-radius: 10px; font-size: 20px; text-align: center; transition: background .15s; }
.emoji:hover { background: var(--surface-4); }
.keys + .pop__label { margin-top: 10px; }

@media (max-width: 980px) { .hide-md { display: none; } .cal-body { grid-template-columns: 1fr; } }
.agenda { display: grid; gap: 14px; }
.agenda__day { display: grid; gap: 4px; }
.agenda__date { font-size: 11px; color: var(--muted); text-transform: lowercase; }
.agenda__day.is-today .agenda__date { color: var(--signal); }
.agenda .cal-card { padding: 8px 10px; font-size: 14px; white-space: normal; }
@media (max-width: 640px) {
  .board-bar__left { flex-wrap: wrap; row-gap: 8px; }
  .board-title { flex-basis: 100%; }
  .board-title__btn { max-width: 100%; }
}
@media (hover: none) { .card__done, .reaction--add { display: inline-grid; opacity: 1; } }

/* ------------------------------------------------------------------ small screens */
@media (max-width: 760px) {
  .modal__grid { grid-template-columns: 1fr; gap: 22px; }
  .modal__side { grid-row: 1; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .modal__side .pop__label, .modal__stamp { display: none; }
  .modal__main { padding-left: 0; }
  .block__title, .checklist { margin-left: 0; }
  .comment-new, .comments { margin-left: 0; }
  .modal__where { margin-left: 0; }
  .modal__ic { display: none; }
  .modal__cover { margin-left: -16px; margin-right: -16px; }
}
@media (max-width: 640px) {
  :root { --list-w: min(84vw, 320px); --top-h: 56px; }
  .hide-sm { display: none; }
  .user__name { display: none; }
  .user { padding: 0 4px; }
  .board-bar { padding-top: 10px; }
  .board-bar__right { width: 100%; }
  .search { flex: 1; }
  .search input { width: 100%; }
  .board-title__btn { max-width: 52vw; }
  .canvas { scroll-snap-type: x proximity; scroll-padding: 0 var(--gutter); }
  .list { scroll-snap-align: start; }
  .modal { width: 100%; max-height: 100dvh; height: 100dvh; max-width: none; border-radius: 0; border: 0; }
  .tiles { grid-template-columns: 1fr 1fr; gap: 10px; }
  .tile { height: 112px; padding: 14px; }
  .tile__title { font-size: 14px; }
  .tile__star { opacity: 1; }
  .top { gap: 10px; }
  .top__search { width: 36px; padding: 0; justify-content: center; }
  .invite { flex-wrap: wrap; }
  .invite .field:first-child { flex-basis: 100%; }
  .card__edit { opacity: 1; }
}
@media (hover: none) { .checklist__del, .tile__star, .card__edit, .checklist__grip { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
.login__tg { margin-top: 4px; }
.login__tg .ic { width: 20px; height: 20px; }
.login__status { min-height: 20px; margin-top: 10px; color: var(--text-2); }
.comment-new__actions { flex-wrap: wrap; row-gap: 4px; }
.comment-new__actions .btn:disabled { opacity: .35; }
.guide-chip { display: inline-flex; align-items: center; gap: 10px; margin-top: 18px; height: 40px; padding: 0 16px 0 12px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(7,8,10,.5); font-size: 14px; font-weight: 700; color: var(--text); transition: border-color .2s, color .2s; }
.guide-chip:hover { border-color: rgba(var(--signal-rgb), .6); color: var(--signal); }
.guide-chip .ic { width: 18px; height: 18px; color: var(--signal); }
.login__guide { display: inline-flex; align-items: center; gap: 10px; margin-top: 16px; color: var(--text-2); font-size: 14px; font-weight: 600; }
.login__guide:hover { color: var(--signal); }
.login__guide .ic { width: 18px; height: 18px; color: var(--signal); }
a.menu-item { color: var(--text); }

/* ------------------------------------------------------------------ hints over the screen (tour.js) */
.tour { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: transparent; overflow: hidden; color: var(--text); }
.tour::backdrop { background: transparent; }
.tour__hole {
  position: fixed; border-radius: 14px; pointer-events: auto;
  box-shadow: 0 0 0 2px rgba(var(--signal-rgb), .9), 0 0 0 9999px rgba(3, 4, 5, .74);
  transition: left .5s var(--ease), top .5s var(--ease), width .5s var(--ease), height .5s var(--ease);
}
.tour__hole::after { content: ""; position: absolute; inset: -2px; border-radius: inherit; box-shadow: 0 0 0 0 rgba(var(--signal-rgb), .5); animation: tour-pulse 1.8s var(--ease) infinite; }
@keyframes tour-pulse { 70%, 100% { box-shadow: 0 0 0 14px rgba(var(--signal-rgb), 0); } }
.tour__tip {
  position: fixed; padding: 18px 18px 14px; border: 1px solid var(--line-2); border-radius: 16px;
  background: linear-gradient(180deg, rgba(var(--signal-rgb), .06), transparent 90px), var(--surface-3);
  box-shadow: 0 30px 80px -16px rgba(0, 0, 0, .95);
  transition: left .5s var(--ease), top .5s var(--ease);
}
.tour__tip.is-in { animation: tour-in .45s var(--ease); }
@keyframes tour-in { from { opacity: 0; translate: 0 8px; } }
.tour__n { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.tour__n b { color: var(--signal); font-weight: 500; }
.tour__title { font: 700 18px/1.25 var(--display); letter-spacing: -.01em; margin-bottom: 8px; }
.tour__text { font-size: 15px; line-height: 1.5; color: var(--text-2); }
.tour__video { display: inline-flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 14px; font-weight: 700; color: var(--signal); }
.tour__video .ic { width: 18px; height: 18px; }
.tour__video .mono { font-weight: 400; }
.tour__video:hover span:first-of-type { text-decoration: underline; text-underline-offset: 3px; }
.tour__nav { display: flex; align-items: center; gap: 8px; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.tour__space { flex: 1; }
.guide-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.guide-row .guide-chip { margin-top: 0; }
@media (prefers-reduced-motion: reduce) { .tour__hole::after { animation: none; } }
.modal__tour { display: block; margin-top: 6px; font-size: 12px; }
