/* Kanban por etiqueta no visual novo (app/kanban.js). Prefixo tzkn-. Só tokens do guia visual. */
.tzkn { display: flex; flex-direction: column; gap: var(--tz-s3); min-height: 0; }
.tzkn-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tzkn-head { display: flex; align-items: center; justify-content: space-between; gap: var(--tz-s3); }
.tzkn-head h2 { display: flex; align-items: center; gap: var(--tz-s2); margin: 0; font-size: var(--tz-t-2xl); font-weight: 600; color: var(--ink); }
.tzkn-help { display: inline-grid; place-items: center; width: 16px; height: 16px; border: 1.5px solid var(--muted); border-radius: 50%; color: var(--muted); font-size: 10px; font-weight: 600; font-style: normal; cursor: help; }
.tzkn-new { padding: 8px 14px; border: 0; border-radius: var(--tz-r-sm); background: var(--tz-primary); color: #fff; font: inherit; font-size: var(--tz-t-sm); font-weight: 600; cursor: pointer; }
.tzkn-new:hover { background: var(--tz-primary-hover); }

.tzkn-bar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--tz-s2); }
.tzkn-search { position: relative; flex: 1 1 260px; max-width: 420px; display: flex; align-items: center; }
.tzkn-search svg { position: absolute; left: 10px; color: var(--muted); pointer-events: none; }
.tzkn-search input { width: 100%; height: 34px; padding: 0 12px 0 32px; border: 1px solid var(--tz-outline-control); border-radius: var(--tz-r-sm); background: var(--surface); color: var(--ink); font: inherit; font-size: var(--tz-t-sm); }
.tzkn-select select { height: 34px; padding: 0 30px 0 12px; border: 1px solid var(--tz-outline-control); border-radius: var(--tz-r-sm); background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%236b7789' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 12px center; color: var(--ink); font: inherit; font-size: var(--tz-t-sm); font-weight: 500; appearance: none; -webkit-appearance: none; cursor: pointer; }
.tzkn-toggle { height: 34px; padding: 0 14px; border: 1px solid var(--tz-outline-container); border-radius: var(--tz-r-md); background: var(--surface); color: var(--ink); font: inherit; font-size: var(--tz-t-sm); font-weight: 500; cursor: pointer; }
.tzkn-toggle.on { border-color: var(--tz-primary); color: var(--tz-primary); background: var(--tz-primary-soft); }
.tzkn-count { margin-left: auto; color: var(--muted); font-size: var(--tz-t-xs); }
.tzkn input:focus-visible, .tzkn select:focus-visible, .tzkn button:focus-visible, .tzkn-card:focus-visible, .tzkn-menu button:focus-visible { outline: 2px solid var(--tz-primary); outline-offset: 2px; }

.tzkn-board { display: flex; align-items: flex-start; gap: var(--tz-s3); overflow-x: auto; padding-bottom: var(--tz-s3); }
.tzkn-col { flex: 0 0 288px; display: flex; flex-direction: column; max-height: calc(100vh - 230px); border: 1px solid var(--tz-outline-container); border-top: 3px solid var(--col); border-radius: var(--tz-r-md); background: var(--panel, var(--tz-n25)); }
.tzkn-col h3 { display: flex; align-items: center; gap: var(--tz-s2); margin: 0; padding: var(--tz-s3) var(--tz-s2) var(--tz-s2) var(--tz-s3); font-size: var(--tz-t-sm); font-weight: 600; color: var(--ink); }
.tzkn-dot { flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%; background: var(--col); }
.tzkn-col-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tzkn-col-count { padding: 0 7px; border-radius: var(--tz-r-pill); background: var(--line); color: var(--muted); font-size: var(--tz-t-xs); font-weight: 500; line-height: 18px; }
.tzkn-col-menu { display: grid; place-items: center; width: 26px; height: 26px; margin-left: auto; padding: 0; border: 0; border-radius: var(--tz-r-sm); background: transparent; color: var(--muted); cursor: pointer; }
.tzkn-col-menu:hover { background: var(--line); color: var(--ink); }
.tzkn-col-body { display: flex; flex-direction: column; gap: var(--tz-s2); min-height: 72px; padding: 0 var(--tz-s2) var(--tz-s2); overflow-y: auto; }
.tzkn-col.drop { border-color: var(--tz-primary); background: var(--tz-primary-soft); }
.tzkn-empty { margin: 0; padding: var(--tz-s4) var(--tz-s2); border: 1px dashed var(--line); border-radius: var(--tz-r-sm); color: var(--muted); font-size: var(--tz-t-xs); text-align: center; }
.tzkn-col.collapsed { flex-basis: 48px; }
.tzkn-col.collapsed h3 { flex-direction: column; padding: var(--tz-s3) 0; }
.tzkn-col.collapsed .tzkn-col-name { writing-mode: vertical-rl; transform: rotate(180deg); }
.tzkn-col.collapsed .tzkn-col-menu { margin: 0; order: -1; }
.tzkn-col.collapsed .tzkn-col-body { display: none; }

/* cartão: mesma anatomia da tela de Conversas (app/conversas-visual.css) */
.tzkn-card { --tone: var(--tz-n300); display: flex; flex-direction: column; gap: 6px; padding: var(--tz-s3); border: 1px solid var(--tz-outline-container); border-left: 4px solid var(--tone); border-radius: var(--tz-r-md); background: var(--surface); box-shadow: var(--tz-shadow-sm); color: var(--ink); cursor: pointer; }
.tzkn-card:hover { border-color: var(--tz-n300); border-left-color: var(--tone); }
.tzkn-card.ok { --tone: var(--tz-success); }
.tzkn-card.wait { --tone: var(--tz-warning-bar); }
.tzkn-card.late { --tone: var(--tz-danger); }
.tzkn-card.done { --tone: var(--tz-n300); opacity: .75; }
.tzkn-card.dragging { opacity: .45; }
.tzkn-card header { display: flex; align-items: center; gap: var(--tz-s2); min-width: 0; }
.tzkn-av { flex-shrink: 0; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; color: #fff; font-size: var(--tz-t-xs); font-weight: 600; }
.tzkn-card strong { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--tz-t-md); font-weight: 600; }
.tzkn-card time { flex-shrink: 0; color: var(--muted); font-size: var(--tz-t-xs); }
.tzkn-wait { flex-shrink: 0; display: inline-flex; align-items: center; gap: 3px; padding: 1px 7px; border-radius: var(--tz-r-pill); background: var(--tz-warning-soft); color: var(--tz-warning); font-size: var(--tz-t-xs); font-weight: 600; }
.tzkn-wait.late { background: var(--tz-danger-soft); color: var(--tz-danger); }
.tzkn-card p { margin: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; color: var(--muted); font-size: var(--tz-t-sm); line-height: 1.4; }
.tzkn-card footer { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.tzkn-owner { display: inline-flex; align-items: center; gap: 5px; color: var(--ink); font-size: var(--tz-t-xs); font-weight: 500; }
.tzkn-owner i { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--tz-primary-soft); color: var(--tz-primary-ink); font-size: 10px; font-style: normal; font-weight: 600; }
.tzkn-pill { padding: 1px 8px; border-radius: var(--tz-r-pill); background: var(--tz-n100); color: var(--tz-n600); font-size: var(--tz-t-xs); font-weight: 500; }
.tzkn-pill.queue { background: var(--tz-warning-soft); color: var(--tz-warning); }
.tzkn-sector { color: var(--muted); font-size: var(--tz-t-xs); }
.tzkn-sector::before { content: '·'; margin-right: 6px; }
.tzkn-tag { padding: 1px 8px; border-radius: var(--tz-r-pill); background: color-mix(in srgb, var(--tag) 14%, transparent); color: color-mix(in srgb, var(--tag) 75%, #000); font-size: var(--tz-t-xs); font-weight: 500; }
.tzkn-unread { margin-left: auto; display: grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: var(--tz-r-pill); background: var(--tz-primary); color: #fff; font-size: var(--tz-t-xs); font-weight: 600; }

.tzkn-menu { position: fixed; z-index: 1300; min-width: 200px; padding: 4px; border: 1px solid var(--tz-outline-container); border-radius: var(--tz-r-md); background: var(--surface); box-shadow: var(--tz-shadow-lg); }
.tzkn-menu button { display: block; width: 100%; padding: 8px 10px; border: 0; border-radius: 6px; background: transparent; color: var(--ink); font: inherit; font-size: var(--tz-t-sm); text-align: left; cursor: pointer; }
.tzkn-menu button:hover:not([disabled]) { background: var(--tz-primary-soft); }
.tzkn-menu button[disabled] { color: var(--muted); opacity: .5; cursor: default; }

/* tema Escuro */
body[data-theme="graphite"] .tzkn-col { background: var(--panel); }
body[data-theme="graphite"] .tzkn-tag { color: color-mix(in srgb, var(--tag) 50%, #fff); background: color-mix(in srgb, var(--tag) 25%, transparent); }
body[data-theme="graphite"] .tzkn-pill { background: #3a4559; color: #d4dce9; }
body[data-theme="graphite"] .tzkn-wait, body[data-theme="graphite"] .tzkn-pill.queue { background: #55431f; color: #fde68a; }
body[data-theme="graphite"] .tzkn-wait.late { background: #4c1d1d; color: #fecaca; }
body[data-theme="graphite"] .tzkn-owner i { background: #1f3b63; color: #cfe2ff; }
body[data-theme="graphite"] .tzkn-new { color: #0b1b33; }

/* celular: uma coluna por vez, arrastando para o lado */
@media (max-width: 760px) {
  .tzkn-head h2 { font-size: var(--tz-t-xl); }
  .tzkn-search { flex-basis: 100%; max-width: none; }
  .tzkn-count { display: none; }
  .tzkn-board { scroll-snap-type: x mandatory; scroll-padding-inline: 12px; margin: 0 -12px; padding: 0 12px var(--tz-s3); }
  .tzkn-col { flex-basis: calc(100vw - 48px); max-height: none; scroll-snap-align: start; }
}
