/* Task detail view (page, board modal and focus view). Tokens come from finder.css (.fx, .tk). */

.tk {
  background: var(--fx-bg); border: 1px solid var(--fx-line); border-radius: 14px; box-shadow: var(--fx-shadow);
  padding: 20px 28px 28px; max-width: 860px; margin: 16px auto 0; font-size: 15px;
}
.tk a { color: inherit; text-decoration: none; }

.tk-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.tk-crumbs { display: flex; gap: 6px; align-items: center; min-width: 0; font-size: 13px; color: var(--fx-muted); }
.tk-crumbs span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tk-top__actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }

.tk-status { font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }
.tk-status--open { background: var(--fx-selected); color: var(--fx-accent); }
.tk-status--done { background: rgba(31, 157, 85, .14); color: #1f9d55; }

.tk-head { display: flex; align-items: flex-start; gap: 12px; }
.tk-check { padding-top: 6px; flex-shrink: 0; }
.tk-title { font-size: 26px; line-height: 1.3; font-weight: 650; margin: 0; word-break: break-word; }
.tk.is-done .tk-title { color: var(--fx-muted); text-decoration: line-through; text-decoration-thickness: 1.5px; }

.tk-banner {
  display: flex; align-items: center; gap: 8px; margin-top: 14px; padding: 10px 14px; border-radius: 10px;
  background: rgba(31, 157, 85, .1); color: #1f9d55; font-size: 14px;
}
.tk-banner b { font-weight: 600; }

/* Property list: label column + value column, collapses on phones */
.tk-props { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 14px 16px; margin: 22px 0 6px; padding: 18px 0; border-top: 1px solid var(--fx-line); border-bottom: 1px solid var(--fx-line); }
.tk-props dt { color: var(--fx-muted); font-size: 13px; padding-top: 5px; }
.tk-props dd { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-height: 30px; }
.tk-muted { color: var(--fx-muted); }

.tk-people { display: flex; flex-wrap: wrap; gap: 6px; }
.tk-person { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 3px; border-radius: 999px; background: var(--fx-hover); font-size: 13px; }
.tk-person:hover { background: var(--fx-selected); }
.tk .tk-avatar { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; display: block; }

.tk-chip { font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 6px; background: var(--fx-hover); color: var(--fx-muted); }
.tk-chip--overdue { background: rgba(217, 48, 37, .12); color: #d93025; }
.tk-chip--today { background: rgba(232, 113, 10, .14); color: #e8710a; }
.tk-chip--soon { background: var(--fx-selected); color: var(--fx-accent); }
.tk-chip--done { background: rgba(31, 157, 85, .12); color: #1f9d55; }

.tk-progress { display: flex; align-items: center; gap: 10px; width: 100%; }
.tk-progress__bar { flex: 1; max-width: 320px; height: 8px; border-radius: 999px; background: var(--fx-line); overflow: hidden; }
.tk-progress__bar span { display: block; height: 100%; background: var(--fx-accent); border-radius: inherit; transition: width .2s; }
.tk.is-done .tk-progress__bar span { background: #1f9d55; }
.tk-progress__value { font-size: 13px; font-weight: 600; min-width: 38px; }
.tk-steps { display: inline-flex; border: 1px solid var(--fx-line); border-radius: 8px; overflow: hidden; }
.tk-steps form { margin: 0; display: flex; }
.tk .tk-step {
  height: 30px; padding: 0 12px; border: 0; border-right: 1px solid var(--fx-line); background: transparent;
  font-size: 12px; font-weight: 500; color: var(--fx-muted); cursor: pointer; font-family: inherit; margin: 0;
}
.tk-steps form:last-child .tk-step { border-right: 0; }
.tk .tk-step:hover { background: var(--fx-hover); color: var(--fx-text); }
.tk .tk-step.is-active { background: var(--fx-selected); color: var(--fx-accent); font-weight: 600; }

.tk-section { margin-top: 22px; }
.tk-section__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.tk-section__head h2 { font-size: 14px; font-weight: 600; margin: 0; text-transform: uppercase; letter-spacing: .04em; color: var(--fx-muted); }
.tk-small { height: 30px; font-size: 13px; }
.tk-body { line-height: 1.65; word-break: break-word; }
.tk-body img { max-width: 100%; height: auto; border-radius: 8px; }
.tk-empty { display: block; padding: 14px 16px; border: 1px dashed var(--fx-line); border-radius: 10px; color: var(--fx-muted); }
.tk-empty:hover { border-color: var(--fx-accent); color: var(--fx-accent); }

.tk-timeline { list-style: none; margin: 0; padding: 0 0 0 4px; position: relative; }
.tk-timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: var(--fx-line); }
.tk-timeline li { position: relative; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; padding: 5px 0 5px 22px; font-size: 14px; list-style: none; }
.tk-dot { position: absolute; left: 0; top: 10px; width: 8px; height: 8px; margin-left: 3px; border-radius: 50%; background: var(--fx-accent); box-shadow: 0 0 0 3px var(--fx-bg); }
.tk-timeline time { font-size: 12px; }

/* Comments below the task on the full page */
.tk-comments { max-width: 860px; margin: 20px auto 0; }
.tk-comments__title { font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--fx-muted); margin: 0 0 10px; }
.tk-comments .box.boxbrand { border-radius: 12px; }
.tk-comments__add { display: block; padding: 12px 16px; border: 1px solid var(--fx-line); border-radius: 10px; color: var(--fx-muted); cursor: pointer; background: var(--fx-bg); }
.tk-comments__add:hover { border-color: var(--fx-accent); color: var(--fx-accent); }

/* Edit form / move picker shown in place of the task */
.tk-panel { background: var(--fx-bg); border: 1px solid var(--fx-line); border-radius: 14px; padding: 20px 24px; max-width: 860px; margin: 16px auto 0; }
.tk-panel__title { font-size: 18px; font-weight: 600; margin: 0 0 14px; }
.tk-move-block { border: 1px solid var(--fx-line); border-radius: 10px; padding: 12px 14px; margin-bottom: 12px; }
.tk-move-block h3 { font-size: 15px; font-weight: 600; margin: 0 0 8px; }
.tk-move-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 0; border-top: 1px solid var(--fx-line); }
.tk-move-row form { margin: 0; }

@media (max-width: 600px) {
  .tk, .tk-panel { padding: 16px; border-radius: 12px; }
  .tk-title { font-size: 22px; }
  .tk-props { grid-template-columns: 1fr; gap: 4px; }
  .tk-props dt { padding-top: 10px; }
  .tk-steps { width: 100%; }
  .tk-steps form { flex: 1; }
  .tk .tk-step { width: 100%; padding: 0; }
}

/* ---------- inline editing on the task page (assignees, due date, description) ---------- */
.tk-pill { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border: 1px solid var(--fx-line); border-radius: 999px; background: transparent; color: var(--fx-text); font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; list-style: none; }
.tk-pill:hover { background: var(--fx-hover); }
.tk-pill--empty { border-style: dashed; color: var(--fx-muted); }
.tk-pill--empty:hover { color: var(--fx-accent); border-color: var(--fx-accent); }
.tk-pop { position: relative; }
.tk-pop__list { min-width: 240px; max-height: 280px; overflow-y: auto; padding: 6px; margin: 0; left: 0; right: auto; }
.tk-pop__row { display: flex; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 8px; font-size: 14px; cursor: pointer; margin: 0; }
.tk-pop__row:hover { background: var(--fx-hover); }
.tk-pop__row input[type=checkbox] { position: static !important; opacity: 1 !important; pointer-events: auto !important; width: 16px; height: 16px; margin: 0; flex: none; }
.tk-due { position: relative; display: inline-flex; align-items: center; gap: 4px; margin: 0; }
.tk-date { position: absolute; left: 0; bottom: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; border: 0; padding: 0; }
.tk-x { width: 26px; height: 26px; border: 0; border-radius: 50%; background: transparent; color: var(--fx-muted); font-size: 12px; cursor: pointer; }
.tk-x:hover { background: var(--fx-hover); color: var(--fx-text); }
.tk-desc__form { display: none; margin: 0; }
.tk-desc.is-editing .tk-desc__form { display: block; }
.tk-desc.is-editing .tk-desc__view, .tk-desc.is-editing .tk-desc__edit { display: none; }
.tk-desc__form lexxy-editor { display: block; }
.tk-desc__actions { display: flex; gap: 8px; margin-top: 10px; }
button.tk-empty { width: 100%; text-align: left; background: transparent; font: inherit; cursor: pointer; }
