/* Доска задач AI Dev Control (ADR-0028). Общие классы — из стилей приложения
   (adp.css), раскладка доски — из дизайна (board.css). Палитра: синий #1D5BF5,
   голубой #22B8F5, серые холодные; Onest. Узкий экран — container query. */

/* --- общие классы приложения --- */
.vh {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.h1 {
  font-size: 24px;
  line-height: 30px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.h2 {
  font-size: 17px;
  line-height: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.t15 {
  font-size: 15px;
  line-height: 21px;
}
.c {
  font-size: 13px;
  line-height: 18px;
}
.m {
  color: #5d6576;
}
.w5 {
  font-weight: 500;
}
.w6 {
  font-weight: 600;
}
.cap {
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  color: #5d6576;
}
.ell {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tab {
  font-variant-numeric: tabular-nums;
}

.row {
  display: flex;
  align-items: center;
}
.col {
  display: flex;
  flex-direction: column;
}
.wrap {
  flex-wrap: wrap;
}
.g4 {
  gap: 4px;
}
.g6 {
  gap: 6px;
}
.g8 {
  gap: 8px;
}
.g12 {
  gap: 12px;
}
.g16 {
  gap: 16px;
}
.g20 {
  gap: 20px;
}
.grow {
  flex: 1 1 auto;
  min-width: 0;
}
.none {
  flex: none;
}
.between {
  justify-content: space-between;
}
.start {
  align-items: flex-start;
}

.i {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
  display: block;
}
.i.s {
  width: 18px;
  height: 18px;
}
.i.xs {
  width: 16px;
  height: 16px;
}
.i.l {
  width: 28px;
  height: 28px;
  stroke-width: 1.6;
}
.i .f {
  fill: currentColor;
  stroke: none;
}

.ib {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  padding: 0;
  color: #0e1526;
}
.ib.f {
  background: #f3f5f9;
}
.ib.w {
  background: #ffffff;
}
.ib.p {
  background: #1d5bf5;
  color: #ffffff;
}
.ib.k {
  background: #0e1526;
  color: #ffffff;
}

.sep {
  height: 1px;
  background: #e3e7ef;
  border: 0;
  margin: 0;
  flex: none;
}

.chips {
  display: flex;
  gap: 8px;
  overflow: hidden;
  flex: none;
}
.chip {
  height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 0;
  background: #f3f5f9;
  color: #0e1526;
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  flex: none;
}
.chip.on {
  background: #0e1526;
  color: #ffffff;
}
.chip.w {
  background: #ffffff;
}
.chip.lo {
  background: #e8f0ff;
  color: #1641b8;
}
.chip .n {
  color: #5d6576;
  font-variant-numeric: tabular-nums;
}
.chip.on .n {
  color: #a9b2c4;
}

.st {
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  flex: none;
  background: #ffffff;
  color: #5d6576;
}
.st.run {
  background: #e8f0ff;
  color: #1641b8;
}
.st.ok {
  background: #ddf3ec;
  color: #0a6b59;
}
.st.wait {
  background: #fff0d6;
  color: #7a4a00;
}
.st.err {
  background: #fbe9e5;
  color: #9e2614;
}
.st.f {
  background: #f3f5f9;
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
  flex: none;
  display: inline-block;
}
.dot.live {
  animation: adp-pulse 1.8s ease-out infinite;
}
@keyframes adp-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(29, 91, 245, 0.45);
  }
  70% {
    box-shadow: 0 0 0 7px rgba(29, 91, 245, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(29, 91, 245, 0);
  }
}

.btn {
  height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 0;
  font-size: 15px;
  line-height: 21px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  flex: none;
  background: #f3f5f9;
  color: #0e1526;
}
.btn.p {
  background: #1d5bf5;
  color: #ffffff;
}
.btn.k {
  background: #0e1526;
  color: #ffffff;
}
.btn.w {
  background: #ffffff;
}
.btn.t {
  background: transparent;
  color: #1d5bf5;
  padding: 0 12px;
}
.btn.r {
  background: #fbe9e5;
  color: #9e2614;
}
.btn.g {
  background: #ddf3ec;
  color: #0a6b59;
}
.btn.sm {
  height: 36px;
  padding: 0 14px;
  font-size: 13px;
  line-height: 18px;
  gap: 6px;
}
.btn.full {
  width: 100%;
}
.btn.fill {
  flex: 1 1 0;
}

.fld {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.lbl {
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  color: #5d6576;
}
.inp {
  height: 48px;
  width: 100%;
  border-radius: 14px;
  border: 1px solid transparent;
  background: #f3f5f9;
  padding: 0 14px;
  font-size: 15px;
  line-height: 21px;
  outline: none;
  display: block;
}
.inp::placeholder {
  color: #5d6576;
}
.inp.on {
  border-color: #1d5bf5;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(29, 91, 245, 0.12);
}
textarea.inp {
  height: auto;
  min-height: 104px;
  padding: 12px 14px;
  resize: none;
}
.search {
  height: 44px;
  flex: none;
  border-radius: 999px;
  background: #f3f5f9;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  color: #5d6576;
}
.search input {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  border: 0;
  background: transparent;
  outline: none;
  padding: 0;
  font-size: 15px;
  color: #0e1526;
}
.search input::placeholder {
  color: #5d6576;
}

.seg {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: #f3f5f9;
  flex: none;
}
.seg button {
  flex: 1 1 0;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  color: #5d6576;
  white-space: nowrap;
  padding: 0 8px;
}
.seg button.on {
  background: #ffffff;
  color: #0e1526;
  box-shadow: 0 1px 3px rgba(14, 21, 38, 0.12);
}

.sw {
  position: relative;
  width: 44px;
  height: 26px;
  border-radius: 999px;
  border: 0;
  padding: 0;
  background: #d3d9e4;
  flex: none;
}
.sw::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(14, 21, 38, 0.25);
}
.sw.on {
  background: #1d5bf5;
}
.sw.on::after {
  left: 21px;
}

.li {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 8px 0;
}
.li + .li {
  border-top: 1px solid #e3e7ef;
}
.av {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  line-height: 21px;
  font-weight: 600;
  flex: none;
  background: #ffffff;
  color: #0e1526;
}
.av.s {
  width: 32px;
  height: 32px;
  font-size: 13px;
  line-height: 18px;
}

/* --- доска --- */
.web {
  position: relative;
  height: 100vh;
  height: 100dvh;
  background: #ffffff;
  color: #0e1526;
  font-family: Onest, system-ui, sans-serif;
  font-size: 15px;
  line-height: 21px;
  -webkit-font-smoothing: antialiased;
  container-type: inline-size;
  overflow: hidden;
}
.web *,
.web *::before,
.web *::after {
  box-sizing: border-box;
}
.web p,
.web h1,
.web h2,
.web h3,
.web ul,
.web ol,
.web blockquote,
.web figure {
  margin: 0;
  padding: 0;
}
.web ul,
.web ol {
  list-style: none;
}
.web button,
.web input,
.web textarea,
.web select {
  font: inherit;
  color: inherit;
  margin: 0;
}
.web button {
  cursor: pointer;
}
.web a {
  color: inherit;
  text-decoration: none;
}

.k-app {
  display: flex;
  height: 100%;
}
.k-side {
  flex: none;
  width: 232px;
  border-right: 1px solid #e8ecf3;
  padding: 16px 12px 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.k-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 8px;
  margin-bottom: 10px;
  font-size: 15px;
  line-height: 21px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.k-logo {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(135deg, #1d5bf5, #22b8f5);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.k-grp {
  font-size: 12px;
  line-height: 16px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #5d6576;
  padding: 14px 10px 6px;
}
.k-proj {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  width: 100%;
  padding: 0 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  font-size: 14px;
  line-height: 20px;
  font-weight: 500;
  text-align: left;
  color: #0e1526;
}
.k-proj.on {
  background: #e8f0ff;
  color: #1641b8;
  font-weight: 600;
}
.k-proj .n {
  margin-left: auto;
  min-width: 22px;
  height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  background: #fff0d6;
  color: #7a4a00;
  font-size: 12px;
  line-height: 22px;
  font-weight: 600;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.k-sfoot {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
  background: #f3f5f9;
  font-size: 13px;
  line-height: 18px;
}

.k-main {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.k-top {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 14px 24px;
  border-bottom: 1px solid #e8ecf3;
}
.k-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1 1 auto;
}
.k-pick {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  font-size: 24px;
  line-height: 30px;
  font-weight: 600;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.k-pick .i {
  display: none;
}
/* Длинное название не наезжает на кнопки справа — обрезается многоточием. */
.k-title h1 {
  display: flex;
  min-width: 0;
}
.k-pick {
  min-width: 0;
  max-width: 100%;
}
.k-top .search {
  width: 280px;
}
.k-avs {
  display: flex;
  align-items: center;
}
.k-avs .av {
  width: 32px;
  height: 32px;
  font-size: 13px;
  line-height: 18px;
  box-shadow: 0 0 0 2px #ffffff;
}
.k-avs .av + .av {
  margin-left: -8px;
}
.k-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 24px 12px;
}
.k-head .chips {
  overflow-x: auto;
}
.k-hint {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  line-height: 18px;
  color: #5d6576;
}
.k-tabs {
  display: none;
}

.k-cols {
  flex: 1 1 auto;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 4px 24px 32px;
  overflow-x: auto;
}
.k-col {
  position: relative;
  flex: none;
  width: 252px;
  background: #f3f5f9;
  border-radius: 20px;
  padding: 12px 10px 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.k-col.in {
  background: #fff7e8;
  box-shadow: inset 0 0 0 1px #f0ddb4;
}
.k-col.over {
  box-shadow: inset 0 0 0 2px #1d5bf5;
}
.k-col.min {
  width: 52px;
  padding: 14px 0;
  align-items: center;
  gap: 10px;
  min-height: 280px;
}
.k-col.min h2 {
  writing-mode: vertical-rl;
  font-size: 14px;
  line-height: 20px;
  font-weight: 600;
  white-space: nowrap;
}
.k-ch {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 28px;
  padding: 0 6px;
}
.k-ch h2 {
  font-size: 15px;
  line-height: 21px;
  font-weight: 600;
}
.k-ch .n {
  font-size: 13px;
  line-height: 18px;
  color: #5d6576;
  font-variant-numeric: tabular-nums;
}
.k-lock {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0 2px;
  padding: 8px 10px;
  border-radius: 12px;
  background: #fff0d6;
  color: #7a4a00;
  font-size: 12px;
  line-height: 16px;
  font-weight: 500;
}

.k-card {
  position: relative;
  background: #ffffff;
  border-radius: 14px;
  padding: 10px 12px 12px;
  box-shadow:
    0 1px 2px rgba(14, 21, 38, 0.06),
    inset 0 0 0 1px #e8ecf3;
  display: flex;
  flex-direction: column;
  gap: 8px;
  cursor: grab;
}
.k-card:hover {
  box-shadow:
    0 4px 14px rgba(14, 21, 38, 0.1),
    inset 0 0 0 1px #d3d9e4;
}
.k-card.drag {
  opacity: 0.4;
}
.k-card h3 {
  font-size: 14px;
  line-height: 19px;
  font-weight: 600;
}
.k-card h3 a:hover {
  color: #1641b8;
}
.k-src {
  height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 16px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
}
.k-src .i {
  flex: none;
}
.k-src.wa {
  background: #ddf3ec;
  color: #0a6b59;
}
.k-src.app {
  background: #e8f0ff;
  color: #1641b8;
}
.k-src.gs {
  background: #fff0d6;
  color: #7a4a00;
}
.k-src.me {
  background: #0e1526;
  color: #ffffff;
}
.k-src.urg {
  background: #fde7e3;
  color: #9e2614;
}
.k-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 10px;
  font-size: 12px;
  line-height: 16px;
  color: #5d6576;
}
.k-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.k-cover {
  height: 92px;
  border-radius: 10px;
  background: linear-gradient(135deg, #e8f0ff, #dff5fd);
  display: flex;
  align-items: center;
  justify-content: center;
}
.k-run {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  line-height: 16px;
  color: #1641b8;
  font-weight: 500;
}
.k-prog {
  display: block;
  position: relative;
  height: 4px;
  border-radius: 999px;
  background: #e3e7ef;
  overflow: hidden;
}
.k-prog i {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #1d5bf5, #22b8f5);
}
.k-note {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  line-height: 16px;
  font-weight: 500;
  color: #7a4a00;
}
.k-acts {
  display: flex;
  gap: 6px;
}
.k-acts .btn {
  height: 32px;
  padding: 0 10px;
  font-size: 12px;
  line-height: 16px;
  gap: 4px;
}
.k-go {
  background: #e8f0ff !important;
  color: #0f2f99 !important;
}
.k-add {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 8px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  color: #5d6576;
  width: 100%;
}
.k-add:hover {
  background: rgba(14, 21, 38, 0.05);
  color: #0e1526;
}
.k-drop {
  height: 88px;
  border-radius: 14px;
  border: 2px dashed #1d5bf5;
  background: rgba(29, 91, 245, 0.06);
  color: #1641b8;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  flex: none;
}

.k-shot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 12px;
  background: #f3f5f9;
  font-size: 12px;
  line-height: 16px;
  color: #353d4e;
}
.k-thumb {
  width: 28px;
  height: 40px;
  border-radius: 6px;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #e3e7ef;
  flex: none;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 4px 3px;
}
.k-thumb i {
  display: block;
  height: 3px;
  border-radius: 2px;
  background: #e3e7ef;
}

.k-toast {
  position: absolute;
  z-index: 30;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  background: #0e1526;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  line-height: 20px;
  font-weight: 500;
  white-space: nowrap;
  box-shadow: 0 8px 24px rgba(14, 21, 38, 0.25);
}

.k-scrim {
  position: absolute;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  background: rgba(14, 21, 38, 0.38);
}
.k-layer {
  position: absolute;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 21;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 48px 24px;
  overflow: auto;
}
.k-modal {
  width: 100%;
  max-width: 880px;
  background: #ffffff;
  border-radius: 28px;
  box-shadow: 0 16px 48px rgba(14, 21, 38, 0.22);
  display: flex;
  flex-wrap: wrap;
  overflow: hidden;
}
.k-mmain {
  flex: 999 1 480px;
  min-width: 0;
  padding: 24px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.k-mside {
  flex: 1 1 240px;
  background: #f8f9fc;
  border-left: 1px solid #eef1f6;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.k-sel {
  height: 44px;
  width: 100%;
  border-radius: 14px;
  border: 0;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #e3e7ef;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  line-height: 20px;
  font-weight: 500;
  text-align: left;
}
.k-tl {
  display: flex;
  flex-direction: column;
}
.k-tl li {
  position: relative;
  display: flex;
  gap: 12px;
  padding: 0 0 14px;
}
.k-tl li::before {
  content: '';
  position: absolute;
  left: 13px;
  top: 28px;
  bottom: 2px;
  width: 2px;
  background: #e3e7ef;
}
.k-tl li:last-child::before {
  display: none;
}
.k-tl .ic {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  background: #f3f5f9;
  color: #5d6576;
}
.k-pop {
  position: absolute;
  z-index: 21;
  top: 68px;
  right: 24px;
  width: 460px;
  max-width: calc(100% - 32px);
  background: #ffffff;
  border-radius: 24px;
  box-shadow:
    0 16px 48px rgba(14, 21, 38, 0.22),
    0 0 0 1px #e8ecf3;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.k-link {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 0 6px 0 14px;
  border-radius: 14px;
  background: #f3f5f9;
  font-size: 14px;
  line-height: 20px;
}

@container (max-width:760px) {
  .k-side {
    display: none;
  }
  .k-top {
    padding: 10px 16px;
    gap: 8px;
  }
  .k-title {
    flex: 1 1 0;
  }
  .k-pick {
    font-size: 20px;
    line-height: 26px;
  }
  .k-pick .i {
    display: block;
  }
  .k-top .search {
    order: 5;
    width: 100%;
    flex: 1 1 100%;
  }
  .k-hide-n {
    display: none !important;
  }
  .k-head {
    padding: 10px 16px 4px;
  }
  .k-hint {
    display: none;
  }
  .k-tabs {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding: 4px 16px 10px;
  }
  .k-tabs a,
  .k-tabs button {
    border: 0;
    height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    background: #f3f5f9;
    font-size: 13px;
    line-height: 18px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    flex: none;
  }
  .k-tabs a.on,
  .k-tabs button.on {
    background: #0e1526;
    color: #ffffff;
  }
  .k-cols {
    scroll-snap-type: x mandatory;
    padding: 0 16px 24px;
    gap: 10px;
  }
  .k-col {
    width: calc(100cqw - 56px);
    scroll-snap-align: start;
  }
  .k-col.min {
    display: none;
  }
  .k-ghost {
    margin: 10px 16px 0;
    font-size: 13px;
    line-height: 18px;
  }
}

/* --- живая страница: то, чего в макете не было --- */
html,
body {
  margin: 0;
  height: 100%;
  background: #ffffff;
}
.web [hidden] {
  display: none !important;
}
.web :focus-visible {
  outline: 2px solid #1d5bf5;
  outline-offset: 2px;
}
.web .inp:focus {
  border-color: #1d5bf5;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(29, 91, 245, 0.12);
}
.web .btn:disabled {
  opacity: 0.5;
  cursor: default;
}
.k-side {
  overflow-y: auto;
}
.k-main {
  height: 100%;
  min-height: 0;
}
.k-cols {
  min-height: 0;
}
.k-col {
  max-height: 100%;
}
.k-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0 -6px;
  padding: 2px 6px 4px;
}
.k-col.min {
  border: 0;
  cursor: pointer;
  color: #0e1526;
}
.k-col.min:hover {
  background: #ebeef4;
}
.k-ch .ib:hover {
  background: rgba(14, 21, 38, 0.06);
}
.k-empty {
  padding: 18px 8px;
  text-align: center;
  font-size: 13px;
  line-height: 18px;
  color: #5d6576;
}
.k-card.busy {
  opacity: 0.55;
  pointer-events: none;
}
.k-card.static {
  cursor: default;
}
.k-card h3 button {
  all: unset;
  cursor: pointer;
  display: block;
  overflow-wrap: anywhere;
}
.k-card h3 button:hover {
  color: #1641b8;
}
.k-card h3 button:focus-visible {
  outline: 2px solid #1d5bf5;
  outline-offset: 2px;
  border-radius: 4px;
}
.k-prog i {
  width: 38%;
  animation: k-slide 1.6s ease-in-out infinite;
}
@keyframes k-slide {
  0% {
    left: -38%;
  }
  100% {
    left: 100%;
  }
}
.k-proj:hover:not(.on) {
  background: #f3f5f9;
}
.k-proj .grow {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.k-sfoot .ib {
  width: 32px;
  height: 32px;
  color: #5d6576;
}
.k-toast.err {
  background: #9e2614;
}
.k-toast {
  max-width: calc(100% - 32px);
  white-space: normal;
  height: auto;
  min-height: 44px;
  padding: 11px 18px;
}

.k-center {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: #f3f5f9;
}
.k-login {
  width: 100%;
  max-width: 400px;
  background: #ffffff;
  border-radius: 28px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: 0 16px 48px rgba(14, 21, 38, 0.1);
}
.k-err {
  font-size: 13px;
  line-height: 18px;
  font-weight: 500;
  color: #9e2614;
}

.k-modal h2.k-mt {
  font-size: 20px;
  line-height: 26px;
  font-weight: 600;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
.k-modal .k-text {
  font-size: 14px;
  line-height: 20px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.k-sel {
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  background: #ffffff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235D6576' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9.5l6 6 6-6'/%3E%3C/svg%3E")
    no-repeat right 12px center/16px;
}
.k-photos {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.k-photos button {
  width: 72px;
  height: 116px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  overflow: hidden;
  background: #f3f5f9;
  box-shadow: inset 0 0 0 1px #e3e7ef;
}
.k-photos img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.k-quote {
  padding: 10px 14px;
  border-radius: 14px;
  background: #f3f5f9;
  color: #353d4e;
  overflow-wrap: anywhere;
}
.k-result {
  padding: 12px 14px;
  border-radius: 14px;
  background: #f8f9fc;
  box-shadow: inset 0 0 0 1px #eef1f6;
  font-size: 13px;
  line-height: 19px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 320px;
  overflow: auto;
}
.k-tl .c {
  overflow-wrap: anywhere;
}
.k-send {
  border: 0;
  background: transparent;
  padding: 0;
  color: #1d5bf5;
  display: inline-flex;
}
.k-send:disabled {
  color: #a6aebe;
}
.k-reply {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border-radius: 16px;
  background: #ddf3ec;
}
.k-reply textarea.inp {
  background: #ffffff;
  min-height: 88px;
}
.k-light {
  position: absolute;
  inset: 0;
  z-index: 40;
  background: rgba(14, 21, 38, 0.86);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  cursor: zoom-out;
}
.k-light img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 12px;
  object-fit: contain;
}
.k-pick-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 60vh;
  overflow: auto;
  margin: 0 -8px;
}
.k-pop .seg button {
  min-width: 0;
}
.k-guests {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* --- доступ к доске (ADR-0029) --- */
.k-pop.k-share {
  width: 520px;
  max-height: calc(100% - 92px);
  overflow: auto;
}
.k-guest {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border-radius: 16px;
  box-shadow: inset 0 0 0 1px #e8ecf3;
}
.k-guest.off {
  background: #f7f8fb;
}
.k-guest .k-acc {
  width: auto;
  height: 36px;
  padding: 0 34px 0 12px;
  font-size: 13px;
}
.k-given {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  border-radius: 16px;
  background: #ddf3ec;
  color: #0a4a3e;
}
.k-cred {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 12px;
  margin: 0;
  font-size: 14px;
  line-height: 20px;
}
.k-cred dt {
  color: #3d6b60;
}
.k-cred dd {
  margin: 0;
  min-width: 0;
  font-weight: 600;
}
.mono {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  letter-spacing: 0.02em;
}
.k-newguest {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  background: #f3f5f9;
}
button.av {
  border: 0;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
}
button.av:focus-visible {
  outline: 2px solid #1d5bf5;
  outline-offset: 2px;
}
.k-head .chips,
.k-tabs {
  scrollbar-width: none;
}
.k-head .chips::-webkit-scrollbar,
.k-tabs::-webkit-scrollbar {
  display: none;
}
.k-file {
  display: none;
}
.k-shot img {
  width: 28px;
  height: 40px;
  border-radius: 6px;
  object-fit: cover;
  flex: none;
  box-shadow: inset 0 0 0 1px #e3e7ef;
}

/* --- MD-файл гостя (ADR-0031): имя видно всем, текст — только владельцу --- */
.k-shot .grow {
  min-width: 0;
}
.k-mdtile {
  position: relative;
  width: 30px;
  height: 38px;
  flex: none;
  border-radius: 6px 9px 6px 6px;
  background: linear-gradient(160deg, #e8f0ff, #d6e3ff);
  box-shadow: inset 0 0 0 1px #c9d8fb;
  color: #1641b8;
  font-size: 10px;
  line-height: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 6px;
}
.k-mdtile::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  border-style: solid;
  border-width: 0 9px 9px 0;
  border-color: transparent #ffffff #b8cbf7 transparent;
  border-radius: 0 0 0 3px;
}
.k-lockline {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  font-size: 12px;
  line-height: 16px;
  font-weight: 500;
  color: #1641b8;
}
.k-meta .k-doc {
  min-width: 0;
  max-width: 180px;
  color: #1641b8;
  font-weight: 500;
}
.k-meta .k-doc .ell {
  display: block;
  min-width: 0;
}
.k-mdhead {
  min-width: 0;
  gap: 2px;
}
.k-mdhead h3 {
  margin: 0;
  font-size: 15px;
  line-height: 20px;
}
.k-md {
  margin: 0;
  max-height: 360px;
  overflow: auto;
  padding: 14px 16px;
  border-radius: 14px;
  background: #f8f9fc;
  box-shadow: inset 0 0 0 1px #eef1f6;
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 12.5px;
  line-height: 19px;
  color: #232a3a;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* --- «Задача отправлена» --- */
.k-layer.mid > .k-modal {
  margin: auto 0;
}
.k-modal.k-alert {
  max-width: 440px;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: center;
  gap: 12px;
  padding: 32px 28px 24px;
  text-align: center;
  overflow: visible;
  animation: k-alert-in 0.34s cubic-bezier(0.2, 0.9, 0.3, 1.15) both;
}
.k-alert .h1 {
  margin: 4px 0 0;
}
.k-alert p {
  margin: 0;
}
.k-ok-mark {
  width: 76px;
  height: 76px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
  color: #ffffff;
  background: radial-gradient(circle at 30% 25%, #4fe0b5, #0f9e7e 72%);
  box-shadow:
    0 0 0 10px #e3f6ef,
    0 14px 30px rgba(15, 158, 126, 0.35);
}
.k-ok-mark .i {
  width: 40px;
  height: 40px;
  stroke-width: 2.6;
}
.k-ok-mark path {
  stroke-dasharray: 22;
  stroke-dashoffset: 22;
  animation: k-draw 0.42s 0.2s ease-out forwards;
}
.k-ok-card {
  width: 100%;
  margin-top: 6px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #f8f9fc;
  box-shadow: inset 0 0 0 1px #eef1f6;
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}
.k-ok-title {
  font-size: 15px;
  line-height: 21px;
  font-weight: 600;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
}
.k-steps {
  list-style: none;
  width: 100%;
  margin: 6px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}
.k-steps li {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  line-height: 16px;
  color: #5d6576;
}
.k-steps li::before {
  content: '';
  position: absolute;
  top: 13px;
  right: 50%;
  width: 100%;
  height: 2px;
  background: #e3e7ef;
}
.k-steps li:first-child::before {
  display: none;
}
.k-steps li.now::before {
  background: linear-gradient(90deg, #0f9e7e, #f5b544);
}
.k-steps i {
  position: relative;
  z-index: 1;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-style: normal;
  font-size: 12px;
  font-weight: 600;
  background: #f3f5f9;
  color: #5d6576;
  box-shadow: 0 0 0 4px #ffffff;
}
.k-steps .done {
  color: #0a6b59;
  font-weight: 500;
}
.k-steps .done i {
  background: #0f9e7e;
  color: #ffffff;
}
.k-steps .now {
  color: #7a4a00;
  font-weight: 500;
}
.k-steps .now i {
  background: #fff0d6;
  color: #7a4a00;
}
.k-steps .now i::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 999px;
  border: 2px solid #f5b544;
  animation: k-ring 1.8s ease-out infinite;
}
.k-ok-acts {
  width: 100%;
  margin-top: 10px;
}
@keyframes k-alert-in {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.96);
  }
}
@keyframes k-draw {
  to {
    stroke-dashoffset: 0;
  }
}
@keyframes k-ring {
  0% {
    opacity: 0.9;
    transform: scale(0.9);
  }
  100% {
    opacity: 0;
    transform: scale(1.35);
  }
}
/* --- Новая задача: окно по центру экрана (ADR-0031) --- */
.k-modal.k-new {
  position: relative;
  max-width: 560px;
  align-items: stretch;
  gap: 18px;
  padding: 26px 26px 22px;
  text-align: left;
}
.k-new-x {
  position: absolute;
  top: 14px;
  right: 14px;
}
.k-new-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-right: 40px;
}
.k-new-mark {
  width: 52px;
  height: 52px;
  flex: none;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: linear-gradient(145deg, #5b8dff, #1d5bf5 70%);
  box-shadow:
    0 0 0 6px #e8efff,
    0 10px 24px rgba(29, 91, 245, 0.32);
}
.k-new-mark .i {
  width: 26px;
  height: 26px;
  stroke-width: 2.4;
}
.k-new .h1 {
  margin: 0;
}
.k-new p.k-new-sub {
  font-size: 13px;
  line-height: 18px;
  color: #5d6576;
}
.k-new-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.k-new-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 16px 10px;
  border-radius: 18px;
  background: #f8f9fc;
  box-shadow: inset 0 0 0 1px #e3e7ef;
  cursor: text;
  transition:
    background 0.15s,
    box-shadow 0.15s;
}
.k-new-field:focus-within {
  background: #ffffff;
  box-shadow:
    inset 0 0 0 2px #1d5bf5,
    0 0 0 4px #e8efff;
}
/* Своё кольцо у поля — общее кольцо фокуса внутри него лишнее. */
.web .k-new-text:focus-visible,
.web .k-mdedit-text:focus-visible,
.web .k-mdname:focus-visible {
  outline: none;
}
.k-new-text {
  width: 100%;
  min-height: 116px;
  border: 0;
  outline: none;
  resize: none;
  padding: 0;
  font-size: 15px;
  line-height: 22px;
  color: #0e1526;
  background: transparent;
}
.k-new-hint,
.k-new-size,
.k-kbd {
  font-size: 12px;
  line-height: 16px;
  color: #8a92a3;
}
.k-new-pick {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.k-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1.5px dashed #c9d3e6;
  background: #ffffff;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.15s,
    background 0.15s,
    transform 0.15s;
}
.k-tile:hover:not(:disabled) {
  border-color: #1d5bf5;
  background: #f5f8ff;
}
.k-tile:active:not(:disabled) {
  transform: scale(0.98);
}
.k-tile:disabled {
  cursor: default;
  opacity: 0.55;
}
.k-tile-ic {
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e3f6ef;
  color: #0f9e7e;
}
.k-tile-tx {
  min-width: 0;
  gap: 2px;
}
.k-tile b {
  font-size: 14px;
  line-height: 18px;
  font-weight: 600;
  color: #0e1526;
}
.k-tile-sub {
  font-size: 12px;
  line-height: 16px;
  color: #5d6576;
}
.k-tile.md .k-tile-sub {
  color: #1641b8;
}
.k-new-pick {
  position: relative;
}
.k-choice {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 3;
  width: min(340px, 100%);
  padding: 6px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow:
    0 0 0 1px #e3e7ef,
    0 16px 40px rgba(14, 21, 38, 0.18);
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: k-alert-in 0.18s ease-out both;
}
.k-choice-i {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.k-choice-i:hover,
.k-choice-i:focus-visible {
  background: #f3f6ff;
}
.k-choice-ic {
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e8f0ff;
  color: #1641b8;
}
.k-choice-i b {
  font-size: 14px;
  line-height: 18px;
  font-weight: 600;
  color: #0e1526;
}
.k-choice-i .col span {
  font-size: 12px;
  line-height: 16px;
  color: #5d6576;
}
.k-mdedit {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
  background: #f5f8ff;
  box-shadow: inset 0 0 0 1px #d6e3ff;
}
.k-mdedit-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.k-mdedit-head b {
  font-size: 14px;
  line-height: 18px;
  font-weight: 600;
}
.k-mdname-row {
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #d6e3ff;
  cursor: text;
}
.k-mdname-row:focus-within,
.k-mdedit-text:focus {
  box-shadow:
    inset 0 0 0 2px #1d5bf5,
    0 0 0 3px #e8efff;
}
.k-mdname {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  font-size: 14px;
  color: #0e1526;
}
.k-mdext {
  font-size: 14px;
  color: #8a92a3;
}
.k-mdedit-text {
  width: 100%;
  min-height: 150px;
  max-height: 320px;
  padding: 12px;
  border: 0;
  border-radius: 12px;
  outline: none;
  resize: vertical;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #d6e3ff;
  color: #232a3a;
}
/* Общий шрифт страницы для полей сильнее одного класса — Markdown пишем моноширинным. */
.web .k-mdedit-text {
  font:
    12.5px/19px ui-monospace,
    'SF Mono',
    Menlo,
    Consolas,
    monospace;
}
.web .k-choice-i:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 2px #c9d8fb;
}
.k-new-size.over {
  color: #d93a3a;
  font-weight: 600;
}
.k-new-files {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.k-new-files .k-shot {
  padding: 8px 8px 8px 10px;
}
.k-new-files .ib {
  width: 32px;
  height: 32px;
  color: #5d6576;
}
.k-new .k-err {
  margin: 0;
}
.k-new-acts {
  display: flex;
  align-items: center;
  gap: 8px;
}
.k-drop {
  position: absolute;
  inset: 8px;
  z-index: 2;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 22px;
  border: 2px dashed #1d5bf5;
  background: rgba(245, 248, 255, 0.94);
  color: #1d5bf5;
  font-size: 15px;
  font-weight: 600;
  pointer-events: none;
}
.k-new.drag .k-drop {
  display: flex;
}
@container (max-width:760px) {
  .k-modal.k-new {
    gap: 16px;
    padding: 22px 18px 18px;
    border-radius: 24px;
  }
  .k-new-mark {
    width: 44px;
    height: 44px;
    border-radius: 14px;
  }
  .k-tile {
    padding: 10px 12px;
    gap: 10px;
  }
  .k-kbd,
  .k-new-acts .grow {
    display: none;
  }
  .k-new-acts .btn {
    flex: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .k-modal.k-alert,
  .k-steps .now i::after {
    animation: none;
  }
  .k-ok-mark path {
    animation: none;
    stroke-dashoffset: 0;
  }
}

@container (max-width:760px) {
  .k-layer {
    padding: 12px;
  }
  .k-mmain {
    padding: 20px 18px 22px;
  }
  .k-mside {
    border-left: 0;
    border-top: 1px solid #eef1f6;
    padding: 20px 18px;
  }
  .k-pop {
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    top: 60px;
  }
  .k-toast {
    bottom: 16px;
  }
}
