/* My tasks (S1): only .kt-* classes; layout, chips, kanban and pills come from s1-kit.css. Hue = status only. */
.kt-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: calc(10px * var(--s1-scale, 1)) calc(14px * var(--s1-scale, 1)); padding: calc(12px * var(--s1-scale, 1)) calc(16px * var(--s1-scale, 1)); border-bottom: 1px solid var(--s1-line-soft); }
.kt-search { position: relative; display: inline-flex; align-items: center; flex: 0 1 240px; min-width: 170px; }
.kt-search .k-icon { position: absolute; left: 11px; color: var(--s1-mute); pointer-events: none; }
.kt-search input { width: 100%; height: 34px; padding: 0 calc(12px * var(--s1-scale, 1)) 0 32px; border: 1px solid var(--s1-control-line); border-radius: 10px; background: var(--s1-panel); font: inherit; font-size: var(--s1-fs-3); color: var(--s1-ink); }
.kt-select .k-select { height: 34px; padding: 0 28px 0 calc(12px * var(--s1-scale, 1)); max-width: 220px; }
.kt-body { padding: calc(16px * var(--s1-scale, 1)); min-width: 0; }
.kt-fchip--late .k-count { background: none; color: var(--s1-late); font-weight: 750; opacity: 1; }

/* the round check on cards and rows */
.kt-check { flex: none; display: inline-grid; place-items: center; width: 22px; height: 22px; margin-top: 1px; padding: 0; border: 1.5px solid var(--s1-checkbox); border-radius: 50%; background: var(--s1-panel); color: transparent; cursor: pointer; transition: background var(--s1-dur-2) var(--s1-ease), border-color var(--s1-dur-2) var(--s1-ease), color var(--s1-dur-2) var(--s1-ease); }
.kt-check .k-icon { width: 13px; height: 13px; }
.kt-check:hover:not(:disabled) { border-color: var(--s1-ink); color: var(--s1-ink-2); }
.kt-check.is-on { background: var(--s1-ink); border-color: var(--s1-ink); color: var(--s1-on-ink); }
.kt-check.is-part { border-style: dashed; }
.kt-check.is-part.is-on { border-style: solid; }
.kt-check:disabled { cursor: default; opacity: .55; }
.kt-check[aria-busy="true"] { animation: kt-pulse 900ms ease-in-out infinite; }
@keyframes kt-pulse { 50% { opacity: .35; } }

/* the title is a button that opens the task editor */
.kt-title { all: unset; box-sizing: border-box; cursor: pointer; font: 650 var(--s1-fs-2)/1.4 var(--k-font-ui, inherit); color: var(--s1-ink); overflow-wrap: anywhere; }
.kt-title:hover { text-decoration: underline; text-underline-offset: 3px; }
.kt-title:focus-visible {   border-radius: 4px; }
.kt-title.is-busy { opacity: .6; }
.k-kcard-title.kt-title { flex: 1; min-width: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.k-kcard.is-focus, .kt-row.is-focus { box-shadow: 0 0 0 2px var(--s1-ink); }
.kt-block { display: flex; align-items: flex-start; gap: calc(6px * var(--s1-scale, 1)); font-size: var(--s1-text-small); line-height: 1.35; color: var(--s1-late); }
.kt-block .k-icon { flex: none; margin-top: 1px; }

/* list view */
.kt-view--list { display: grid; gap: calc(18px * var(--s1-scale, 1)); }
.kt-sec-h { display: flex; align-items: center; gap: calc(8px * var(--s1-scale, 1)); margin: 0 0 8px; font: 700 var(--s1-text-small) var(--k-font-ui, inherit); color: var(--s1-ink); }
.kt-sec-h .k-icon { color: var(--s1-ink-2); }
.kt-sec-h.k-tone-late, .kt-sec-h.k-tone-late .k-icon { color: var(--s1-late); }
.kt-sec-h.k-tone-soon, .kt-sec-h.k-tone-soon .k-icon { color: var(--s1-soon); }
.kt-list { list-style: none; margin: 0; padding: 0; display: grid; border: 1px solid var(--s1-line); border-radius: 12px; overflow: hidden; background: var(--s1-panel); }
.kt-row { --edge: var(--s1-panel); position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: calc(12px * var(--s1-scale, 1)); align-items: start; padding: calc(12px * var(--s1-scale, 1)) calc(14px * var(--s1-scale, 1)) calc(12px * var(--s1-scale, 1)) calc(16px * var(--s1-scale, 1)); border-top: 1px solid var(--s1-line-soft); }
.kt-row:first-child { border-top: 0; }
.kt-row--late { --edge: var(--s1-late); } .kt-row--soon { --edge: var(--s1-soon); }
.kt-row:hover { background: var(--s1-panel-head, #f7f8fa); }
.kt-row.is-done .kt-title { color: var(--s1-mute); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--s1-mute) 60%, transparent); }
.kt-main { display: grid; gap: calc(6px * var(--s1-scale, 1)); min-width: 0; }
.kt-meta { display: flex; flex-wrap: wrap; align-items: center; gap: calc(6px * var(--s1-scale, 1)) calc(8px * var(--s1-scale, 1)); min-width: 0; }
.kt-due-inline { display: none; }
.kt-side { display: flex; align-items: center; gap: calc(8px * var(--s1-scale, 1)); justify-content: flex-end; flex-wrap: wrap; }
.kt-status { display: inline-flex; align-items: center; gap: calc(6px * var(--s1-scale, 1)); padding: 5px calc(9px * var(--s1-scale, 1)); border: 1px solid var(--s1-line); border-radius: 999px; background: var(--s1-panel); font: 600 var(--s1-text-small) var(--k-font-ui, inherit); color: var(--s1-ink-2); cursor: pointer; white-space: nowrap; }
.kt-status:hover:not(:disabled) { border-color: var(--s1-ink); }
.kt-status:disabled { cursor: default; opacity: .7; }
.kt-status--doing { color: var(--s1-ink); } .kt-status--blocked { color: var(--s1-late); border-color: color-mix(in srgb, var(--s1-late) 32%, var(--s1-panel)); }

/* new task: project picker */
.kt-pick { display: grid; gap: 4px; max-height: 320px; overflow: auto; margin-top: 10px; }
.kt-pick-row { display: flex; align-items: center; gap: calc(10px * var(--s1-scale, 1)); width: 100%; padding: calc(8px * var(--s1-scale, 1)) calc(10px * var(--s1-scale, 1)); border: 0; border-radius: 9px; background: none; text-align: left; font: 600 var(--s1-fs-3) var(--k-font-ui, inherit); color: var(--s1-ink); cursor: pointer; }
.kt-pick-row > .k-icon { margin-left: auto; color: var(--s1-mute); }
.kt-pick-row:hover, .kt-pick-row:focus-visible { background: var(--s1-column, #f4f5f8);  }

/* read-only detail (preview) */
.kt-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: calc(12px * var(--s1-scale, 1)) calc(16px * var(--s1-scale, 1)); margin: 0 0 12px; }
.kt-facts dt { font-size: var(--s1-text-micro); font-weight: 650; letter-spacing: .04em; text-transform: uppercase; color: var(--s1-mute); }
.kt-facts dd { margin: 2px 0 0; font-size: var(--s1-fs-3); color: var(--s1-ink); }
.kt-h3 { margin: 12px 0 4px; font: 700 var(--s1-text-small) var(--k-font-ui, inherit); color: var(--s1-ink); }
.kt-notes { margin: 0 0 10px; white-space: pre-wrap; font-size: var(--s1-fs-3); line-height: 1.5; color: var(--s1-ink-2); }

@media (max-width: 640px) {
  .kt-toolbar { padding: 12px; } .kt-search { flex: 1 1 100%; } .kt-body { padding: 12px; }
  .kt-select, .kt-select .k-select { max-width: 100%; width: 100%; }
  .kt-row { grid-template-columns: auto minmax(0, 1fr); padding: 12px; }
  .kt-side { grid-column: 2; justify-content: flex-start; }
  .kt-facts { grid-template-columns: 1fr; }
}

/* the board is as tall as its longest column and the page scrolls: no scrollbar, no faded edge inside a column */
.kt-view--board .k-kcol { min-width: 0; }
.kt-view--board .k-kcol-body { grid-template-columns: minmax(0, 1fr); }
.kt-view--board .k-kcard { min-width: 0; }
.kt-view--board .k-kcard > div { min-width: 0; }
.kt-view--board .k-pchip { max-width: 100%; }
.kt-view--board .k-pchip .k-pn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kt-view--board .k-kcard-foot .k-avs { margin-left: auto; }

/* Calendar page (S1): chips above the Kit calendar; the calendar itself is styled by s1-kit.css */
.s1cal-bar { padding: calc(12px * var(--s1-scale, 1)) calc(16px * var(--s1-scale, 1)); border-bottom: 1px solid var(--s1-line-soft); }
.s1cal-host { padding: calc(16px * var(--s1-scale, 1)); min-width: 0; }

/* Calendar page layout (S1): sidebar (mini month, filters, project) | Today strip + grid | event detail */
.s1cal-layout { display: grid; grid-template-columns: 252px minmax(0, 1fr); gap: calc(16px * var(--s1-scale, 1)); align-items: start; min-width: 0; }
.s1cal-layout.has-detail { grid-template-columns: 252px minmax(0, 1fr) 320px; }
.s1cal-side { position: sticky; top: 12px; min-width: 0; }
.s1cal-main { display: grid; gap: calc(16px * var(--s1-scale, 1)); min-width: 0; }
.s1cal-detail-host { position: sticky; top: 12px; min-width: 0; }
.s1cal-detail-host[hidden] { display: none; }
.s1cal-side-panel { display: grid; gap: calc(16px * var(--s1-scale, 1)); padding: calc(14px * var(--s1-scale, 1)); }
.s1cal-week { display: none; align-items: center; gap: 4px; }
.s1cal-week-days { display: grid; flex: 1; grid-template-columns: repeat(7, 1fr); gap: 2px 2px; text-align: center; min-width: 0; }
.s1cal-wk-dow.is-today { color: var(--s1-ink); font-weight: 750; }
.s1cal-wk-dow { font: 600 var(--s1-text-micro) var(--s1-font-ui); color: var(--s1-mute); padding: 2px 0; }
.s1cal-mini-d { position: relative; aspect-ratio: 1; min-height: 30px; border: 0; border-radius: 8px; background: none; color: var(--s1-ink); font: 500 var(--s1-text-small) var(--s1-font-ui); cursor: pointer; }
.s1cal-mini-d:hover { background: var(--s1-column); }
.s1cal-mini-d.is-today { font-weight: 700; box-shadow: inset 0 0 0 1.5px var(--s1-ink); }
.s1cal-mini-d.is-sel { background: var(--s1-ink); color: var(--s1-on-ink); opacity: 1; }
.s1cal-mini-d.has-ev::after { content: ""; position: absolute; left: 50%; bottom: 4px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: currentColor; }
.s1cal-show { display: grid; gap: calc(8px * var(--s1-scale, 1)); }
.s1cal-chips { display: flex; flex-wrap: wrap; gap: calc(6px * var(--s1-scale, 1)); }
/* Quiet filter chips (direction B): a hairline pill, the kind's dot, and the ink only on the border and text when it is on. */
.s1cal-chip { --kc: var(--s1-mute); padding: 3px calc(10px * var(--s1-scale, 1)); font-weight: 600; font-size: var(--s1-text-micro); color: var(--s1-mute); }
.s1cal-chip[aria-pressed="true"] { background: var(--s1-panel); border-color: var(--s1-ink); color: var(--s1-ink); }
.s1cal-chip[aria-pressed="false"] .s1cal-dot { opacity: .45; }
.s1cal-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--kc, var(--s1-mute)); flex: none; }
.s1cal-proj { display: grid; gap: calc(6px * var(--s1-scale, 1)); }
.s1cal-today { padding: calc(12px * var(--s1-scale, 1)) calc(16px * var(--s1-scale, 1)); display: grid; gap: calc(8px * var(--s1-scale, 1)); }
.s1cal-today-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px calc(10px * var(--s1-scale, 1)); font: 650 var(--s1-fs-3) var(--s1-font-ui); color: var(--s1-ink); }
.s1cal-today-head > span { font-weight: 500; color: var(--s1-mute); font-size: var(--s1-text-small); }
.s1cal-today-late { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; color: var(--s1-late); font: 650 var(--s1-text-small) var(--s1-font-ui); }
.s1cal-today-list { display: flex; flex-wrap: wrap; gap: calc(6px * var(--s1-scale, 1)); }
.s1cal-today-item { display: inline-flex; align-items: center; gap: calc(7px * var(--s1-scale, 1)); max-width: 100%; padding: 5px calc(11px * var(--s1-scale, 1)); border: 1px solid var(--s1-line); border-radius: 8px; background: var(--s1-panel); color: var(--s1-ink); font: 550 var(--s1-text-small) var(--s1-font-ui); cursor: pointer; text-align: left; }
.s1cal-today-item > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.s1cal-today-item:hover { border-color: var(--s1-ink); }
.s1cal-today-item .s1cal-dot { display: none; }
.s1cal-today-item.is-late { border-color: var(--s1-late); color: var(--s1-late); }
.s1cal-today-item.is-late small { color: var(--s1-mute); font-weight: 500; }
.s1cal-today-more { align-self: center; color: var(--s1-mute); font: 600 var(--s1-text-small) var(--s1-font-ui); }
.s1cal-today-none { margin: 0; color: var(--s1-mute); font: 500 var(--s1-text-small) var(--s1-font-ui); }
.s1cal-d-body { display: grid; gap: calc(12px * var(--s1-scale, 1)); }
.s1cal-d-title { margin: 0; font: 650 var(--s1-fs-4)/1.3 var(--s1-font-display); color: var(--s1-ink); overflow-wrap: anywhere; }
.s1cal-d-when { display: flex; flex-wrap: wrap; align-items: center; gap: calc(6px * var(--s1-scale, 1)) calc(10px * var(--s1-scale, 1)); color: var(--s1-ink-2); font: 500 var(--s1-text-small) var(--s1-font-ui); }
.s1cal-d-row { display: grid; gap: 4px; min-width: 0; font: 500 var(--s1-fs-3) var(--s1-font-ui); color: var(--s1-ink-2); }
.s1cal-d-acts { display: flex; flex-wrap: wrap; gap: calc(8px * var(--s1-scale, 1)); padding-top: 4px; }
@media (max-width: 1180px) {
  .s1cal-layout.has-detail { grid-template-columns: 252px minmax(0, 1fr); }
  .s1cal-layout.has-detail .s1cal-detail-host { grid-column: 1 / -1; grid-row: 1; position: static; }
  .s1cal-layout.has-detail .s1cal-side { grid-row: 2; }
  .s1cal-layout.has-detail .s1cal-main { grid-row: 2; }
}
@media (max-width: 900px) {
  .s1cal-layout, .s1cal-layout.has-detail { grid-template-columns: minmax(0, 1fr); }
  .s1cal-layout .s1cal-side, .s1cal-layout.has-detail .s1cal-side { position: static; order: 0; grid-row: auto; }
  .s1cal-layout .s1cal-main, .s1cal-layout.has-detail .s1cal-main { order: 1; grid-row: auto; }
  .s1cal-layout .s1cal-detail-host, .s1cal-layout.has-detail .s1cal-detail-host { order: -1; position: static; grid-column: auto; grid-row: auto; }
  .s1cal-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
  .s1cal-chip { flex: none; }
  .s1cal-show > .k-label { display: none; }
  .s1cal-proj { grid-template-columns: auto minmax(0, 1fr); align-items: center; }
  .s1cal-week { display: flex; }
  .s1cal-side-panel { padding: 12px; gap: 12px; }
  .s1cal-today { padding: 10px 12px; }
  .s1cal-host { padding: 12px; }
}

.s1cal-week-tools { display: none; justify-content: space-between; gap: calc(8px * var(--s1-scale, 1)); }
/* Phone: the week strip is the one date navigator, the schedule below it is the agenda, and the filters wait behind one button. */
@media (max-width: 640px) {
  .s1cal .k-cal-bar { display: none; }
  .s1cal-week-tools { display: flex; }
  .s1cal-side-panel:not(.is-open) { display: none; }
  .s1cal-mini-d { min-height: 36px; }
}

/* Calendar: Add chooser (Kit.modal body) */
.s1cal-pick-intro { margin: 0 0 12px; color: var(--s1-ink-2); font: var(--s1-text-small)/1.5 var(--s1-font-ui); }
.s1cal-picks { display: grid; gap: calc(6px * var(--s1-scale, 1)); max-height: min(52dvh, 420px); overflow: auto; }
.s1cal-pick { display: flex; align-items: center; gap: calc(12px * var(--s1-scale, 1)); width: 100%; min-height: 56px; padding: calc(10px * var(--s1-scale, 1)) calc(12px * var(--s1-scale, 1)); border: 1px solid var(--s1-line); border-radius: var(--s1-radius-control); background: var(--s1-panel); color: var(--s1-ink); text-align: left; cursor: pointer; font: inherit; }
.s1cal-pick:hover { background: var(--s1-panel-head); border-color: var(--s1-checkbox); }
.s1cal-pick-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.s1cal-pick-text strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 650 var(--s1-text-base) var(--s1-font-ui); }
.s1cal-pick-text small { color: var(--s1-mute); font: var(--s1-text-small) var(--s1-font-ui); }
.s1cal-pick-ico { display: inline-grid; place-items: center; width: 32px; height: 32px; flex: none; border: 1px solid var(--s1-line); border-radius: var(--s1-radius-control); background: var(--s1-panel-head); }

/* personal tasks: quick add (private to me) */
.kt-quickadd { display: flex; flex-wrap: wrap; align-items: center; gap: calc(8px * var(--s1-scale, 1)) calc(10px * var(--s1-scale, 1)); padding: calc(12px * var(--s1-scale, 1)) calc(16px * var(--s1-scale, 1)); border-bottom: 1px solid var(--s1-line-soft); background: var(--s1-panel-head); }
.kt-qa-own { display: inline-flex; align-items: center; gap: calc(6px * var(--s1-scale, 1)); font-size: var(--s1-text-small); color: var(--s1-ink-2, var(--s1-mute)); cursor: pointer; }
.kt-qa-own svg { color: var(--s1-mute); }
.kt-chips { flex: 1 1 100%; }
.kt-qa-title { flex: 1 1 260px; min-width: 0; height: 34px; padding: 0 calc(12px * var(--s1-scale, 1)); border: 1px solid var(--s1-control-line); border-radius: 10px; background: var(--s1-panel); font: inherit; font-size: var(--s1-fs-3); color: var(--s1-ink); }
@media (max-width: 720px) { .kt-quickadd { padding: 12px; } .kt-qa-title { flex: 1 1 100%; } }
/* One search box and a Filter button; the rest opens beneath. */
.kt-filterbtn { flex: none; }
.kt-filterbox { flex: 1 1 100%; display: flex; flex-wrap: wrap; align-items: center; gap: calc(10px * var(--s1-scale, 1)) calc(14px * var(--s1-scale, 1)); padding-top: 4px; }
.kt-filterbox[data-folded] { display: none; } /* not [hidden]: s1-base forces that to display:none at every width */

/* Phone: one way to add (the New task button), one controls row (search + Filter); the add row and the Board/List head fold away. */
@media (max-width: 640px) {
  [data-s1-tasks] .kt-quickadd, [data-s1-tasks] .k-panel-head { display: none; }
  .kt-toolbar .kt-search { flex: 1 1 0; min-width: 0; }
  .kt-toolbar .kt-filterbtn { flex: none; }
}

/* ---- r18: the list is one page of hairline rows, not a boxed panel of tinted pills ---- */
html .kt-list { border: 0; border-radius: 0; background: none; overflow: visible; }
html .kt-row { margin: 0 -10px; padding: calc(12px * var(--s1-scale, 1)) calc(10px * var(--s1-scale, 1)); background: none; }
html .kt-row:hover { background: var(--s1-column, var(--well)); }
html .kt-sec-h { margin-bottom: 2px; }
html .kt-sec-h .k-count { background: none; border: 0; min-width: 0; padding: 0; color: var(--s1-mute); font-weight: 650; }
html .kt-sec-h.k-tone-late .k-count { color: var(--s1-late); }
/* dates, priority and key-date read as text with their own icon, not as outlined pills */
html .kt-row :is(.k-pill, .k-due) { background: none; border: 0; padding: 0; border-radius: 0; min-height: 0; }
html .kt-row .k-pill--plain { color: var(--s1-mute); font-weight: 550; }
html .kt-side .k-pill { color: var(--tone, var(--s1-ink-2)); font-weight: 650; }
html .kt-status { border: 0; background: none; padding: 5px calc(6px * var(--s1-scale, 1)); }
html .kt-status:hover:not(:disabled) { background: var(--s1-column, var(--well)); }
html .kt-status--blocked { border: 0; }
@media (max-width: 640px) { html .kt-row { margin: 0 -12px; padding: 12px; } }

/* ---- r18 Calendar: week as day rows (pattern 17, no cramped cells), month grid on hairlines, neutral kinds, no boxes ---- */
.s1cal { --s1cal-kc: var(--s1-ink-2); }
.s1cal [class*="k-cal-k--"], .s1cal .s1cal-chip { --kc: var(--s1-ink-2); }
.s1cal .is-late.k-cal-ev, .s1cal .is-late.k-cal-card, .s1cal .k-cal-dots i.is-late { --kc: var(--s1-late); }
.s1cal .k-cal-wk { grid-template-columns: minmax(0, 1fr); border: 0; border-radius: 0; box-shadow: none; background: none; overflow: visible; }
.s1cal .k-cal-wkday { flex-direction: row; min-height: 0; border-right: 0; border-top: 1px solid var(--s1-line-soft); background: none; box-shadow: none; }
.s1cal .k-cal-wkday:first-child { border-top: 0; }
.s1cal .k-cal-wkday > header { flex: 0 0 132px; justify-content: flex-start; align-items: flex-start; padding: calc(12px * var(--s1-scale, 1)) 0; border: 0; background: none; }
.s1cal .k-cal-wkday .k-cal-wkhead { padding: 0; }
.s1cal .k-cal-wkday .k-cal-wkadd { opacity: 0; }
.s1cal .k-cal-wkday:hover .k-cal-wkadd, .s1cal .k-cal-wkday:focus-within .k-cal-wkadd { opacity: 1; }
.s1cal .k-cal-wkday.is-today .k-cal-wkhead b { background: var(--s1-ink); color: var(--s1-on-ink); }
.s1cal .k-cal-wkbody { flex: 1 1 auto; min-width: 0; padding: calc(8px * var(--s1-scale, 1)) 0; }
.s1cal .k-cal-wkbody .k-cal-none { text-align: left; padding: calc(8px * var(--s1-scale, 1)) 0; }
.s1cal .k-cal-card { background: color-mix(in srgb, var(--kc) 7%, var(--s1-panel)); }
.s1cal .k-cal-grid { border: 0; border-top: 1px solid var(--s1-line); border-radius: 0; box-shadow: none; background: none; overflow: visible; }
.s1cal .k-cal-dow { background: none; }
.s1cal .k-cal-dow span { border-right-color: transparent; }
.s1cal .k-cal-cell { background: none; border-right-color: var(--s1-line-soft); }
.s1cal .k-cal-cell:hover { background: var(--s1-column); }
.s1cal .k-cal-cell.is-wknd, .s1cal .k-cal-cell.is-out { background: none; }
.s1cal .k-cal-cell.is-out { color: var(--s1-mute); }
.s1cal .k-cal-cell.is-today { box-shadow: none; }
.s1cal .k-cal-cell.is-today .k-cal-num time { color: var(--s1-on-ink); }
.s1cal .k-cal-week + .k-cal-week { border-top-color: var(--s1-line-soft); }
.s1cal .k-cal-ev { background: color-mix(in srgb, var(--kc) 9%, var(--s1-panel)); }
.s1cal-today-item { border: 0; background: var(--s1-column); }
.s1cal-today-item:hover { background: var(--s1-panel-head); }
.s1cal-chip[aria-pressed="true"] { background: var(--s1-column); border-color: transparent; }
.s1cal-chip[aria-pressed="false"] { border-style: dashed; }
.s1cal-mini-d.is-sel { color: var(--s1-on-ink); }
@media (max-width: 760px) { .s1cal .k-cal-wkday { flex-direction: column; } .s1cal .k-cal-wkday > header { flex: none; padding: 10px 0 0; } }
.s1cal .k-panel:not(.s1cal-detail) { border: 0; border-radius: 0; box-shadow: none; background: none; }
.s1cal .k-cal-ag { border: 0; border-radius: 0; box-shadow: none; background: none; overflow: visible; }
.s1cal .k-cal-agday.is-today { background: none; }

/* ---- r18 Board: columns are a heading on a rule and the cards are plain rows, not boxes inside boxes ---- */
.kt-view--board .k-kanban { gap: calc(28px * var(--s1-scale, 1)); }
.kt-view--board .k-kcol { padding: 0; background: none; border: 0; border-radius: 0; min-height: 0; }
.kt-view--board .k-kcol.is-over { background: var(--s1-column); box-shadow: none; }
.kt-view--board .k-kcol-head { padding: 0 0 calc(10px * var(--s1-scale, 1)); border-bottom: 2px solid var(--s1-line-soft); margin-bottom: 2px; }
.kt-view--board .k-kcol-body { gap: 0; }
.kt-view--board .k-kcard { padding: calc(12px * var(--s1-scale, 1)) 0; border: 0; border-top: 1px solid var(--s1-line-soft); border-radius: 0; box-shadow: none; background: none; }
.kt-view--board .k-kcol-body > .k-kcard:first-child { border-top: 0; }
.kt-view--board .k-kcard--soon, .kt-view--board .k-kcard--wait { background: none; }
.kt-view--board .k-kcard--late { margin: 0 -8px; padding-inline: calc(8px * var(--s1-scale, 1)); background: color-mix(in srgb, var(--edge) 7%, var(--s1-panel)); }
.kt-view--board .k-kcard:hover { box-shadow: none; background: var(--s1-column); }
.kt-view--board .k-kcard-title { -webkit-line-clamp: 3; }
.kt-view--board .k-pchip { padding-left: 0; border: 0; background: none; }
.kt-view--board .k-empty { padding: calc(10px * var(--s1-scale, 1)) 0; border: 0; background: none; color: var(--s1-mute); font-size: var(--s1-text-small); }

/* r19 tasks pass: one primary button (New task); Add is an outline button; the project is plain text, no letter badge; the Personal box ticks visibly in dark and its label has room. */
.kt-quickadd .k-btn { background: var(--s1-panel); color: var(--s1-ink); border: 1px solid var(--s1-line); }
.kt-quickadd .k-btn:hover { border-color: var(--s1-ink); background: var(--s1-panel-head, var(--s1-panel)); }
.kt-meta .k-pchip { padding: 0; border: 0; background: none; font-weight: 500; color: var(--s1-ink-2); }
.kt-meta .k-pchip:hover { background: none; text-decoration: underline; text-underline-offset: 3px; }
.kt-meta .k-pchip .k-pm { display: none; }
.kt-meta .k-pchip .k-pn { max-width: 260px; }
.kt-qa-own { gap: calc(8px * var(--s1-scale, 1)); }
.kt-qa-own > span { display: inline-flex; align-items: center; gap: calc(6px * var(--s1-scale, 1)); line-height: 1; }
.kt-qa-own svg { flex: none; }
.kt-qa-own .k-check:checked::after { border-color: var(--s1-on-ink); }
.kt-fchip--late .k-count { color: var(--s1-late); }

/* r19 calendar: agenda and week lists are hairline rows, not a tinted box per event. */
html .s1cal .k-cal-card { background: none; border-radius: 0; padding: calc(8px * var(--s1-scale, 1)) 0; border-top: 1px solid var(--s1-line-soft); }
html .s1cal .k-cal-agbody > .k-cal-card:first-child, html .s1cal .k-cal-wkbody > .k-cal-card:first-child { border-top: 0; }
html .s1cal .k-cal-card-i { color: var(--s1-mute); }
html .s1cal .k-cal-card.is-late .k-cal-card-i { color: var(--s1-late); }
html .s1cal .k-cal-agbody, html .s1cal .k-cal-wkbody { gap: 0; }
html .s1cal .k-cal-agday { padding-inline: 0; }
html .s1cal .k-cal-agday.is-today { background: none; }
html .s1cal .k-cal-agnum { font-size: var(--s1-fs-4); }
/* blocked is not late: amber, red stays for dates that have passed */
.kt-block { color: var(--s1-soon); }
.kt-status--blocked { color: var(--s1-soon); border-color: color-mix(in srgb, var(--s1-soon) 32%, var(--s1-panel)); }

/* ---- tasks and requests ui fix-up: lateness is a small mark, never a wash ---- */
.kt-view--board .k-kcard--late { margin: 0; padding-inline: 0; background: none; }
.kt-view--board .k-kcol-body { overflow: visible; background: none; }
.kt-view--board .k-kcol-body > .k-kcard { gap: 4px; }
/* due and late read as a short coloured text with its icon: grey by default, amber this week, red when late; no pill fill */
.kt-view--board .k-kcard .k-pill { background: none; border: 0; padding: 0; min-height: 0; border-radius: 0; }
.kt-view--board .k-kcard .k-pill--plain { color: var(--s1-mute); font-weight: 550; }
/* board card: title row, then one quiet line (project), then the date left and the avatar right; everything under the title lines up with the title */
.kt-view--board .k-kcard > :not(.k-kcard-top) { margin-left: 30px; min-width: 0; }
.kt-view--board .k-kcard-top { align-items: center; }
.kt-view--board .k-kcard .k-pchip { color: var(--s1-mute); font-size: var(--s1-text-small); }
.kt-view--board .k-kcard .k-pchip .k-pm { display: none; }
.kt-view--board .k-kcard-foot { min-height: 24px; }
.kt-view--board .k-kcard-foot .k-avs { margin-left: auto; }

/* Calendar, desktop: the filters sit on one line above the grid, so the grid and the entries get the full width; an entry shows its whole title (two lines at most) and its project. */
.k-cal-ev-p { display: none; }
@media (min-width: 901px) {
  .s1cal-layout, .s1cal-layout.has-detail { grid-template-columns: minmax(0, 1fr); }
  .s1cal-layout.has-detail { grid-template-columns: minmax(0, 1fr) 320px; }
  .s1cal-layout .s1cal-side { position: static; grid-column: 1; }
  .s1cal-layout .s1cal-main { grid-column: 1; }
  .s1cal-layout.has-detail .s1cal-detail-host { grid-column: 2; grid-row: 1 / span 2; }
  .s1cal-side-panel { display: flex; flex-wrap: wrap; align-items: center; gap: 8px calc(20px * var(--s1-scale, 1)); padding: 8px calc(14px * var(--s1-scale, 1)); }
  .s1cal-show { display: flex; align-items: center; gap: calc(10px * var(--s1-scale, 1)); }
  .s1cal-proj { display: flex; align-items: center; gap: 8px; }
  .s1cal { --kc-lane: 46px; }
  .s1cal .k-cal-ev { height: auto; min-height: 22px; max-height: calc(var(--kc-lane) - 3px); align-items: flex-start; padding-top: 3px; padding-bottom: 3px; line-height: 1.2; }
  .s1cal .k-cal-ev-t { white-space: normal; display: block; overflow: hidden; }
  .s1cal .k-cal-ev-n { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }
  .s1cal .k-cal-ev-p { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; color: var(--s1-mute); }
}
/* Today and the schedule are one panel: the day's items sit above the grid, divided by a hairline. */
.s1cal-today { border-bottom: 1px solid var(--s1-line); }
/* Project names are never clipped: a long one wraps inside the row and in the project picker. */
.kt-meta .k-pchip .k-pn { max-width: none; white-space: normal; overflow-wrap: anywhere; }
.kt-pick button, .kt-pick a { white-space: normal; overflow-wrap: anywhere; text-align: left; }
.kt-filterbox > .k-label { align-self: center; color: var(--s1-mute); font-size: var(--s1-text-small); }
.kt-pick-row { white-space: normal; overflow-wrap: anywhere; } .kt-pick-row > span { min-width: 0; }
.kt-pick-row > .k-trunc { white-space: normal; overflow: visible; text-overflow: clip; }
/* Calendar, one left edge and readable entries (round 3): the page takes the header's gutter like the other pages; the filter line, the
 * schedule and the month title sit on that edge, not indented inside invisible panels. The kit calendar sets its own 25px lane on .k-cal,
 * which beat the 46px two-line lane set on the page and cut every entry's second line in half: the lane is set on .k-cal itself. */
.k-page.s1cal { --s1-gutter: var(--gut, 28px); }
.s1cal-sched { border: 0; background: none; box-shadow: none; }
.s1cal-sched .s1cal-host, .s1cal-sched .s1cal-today { padding-inline: 0; }
.s1cal-today[hidden] { display: none; }
@media (min-width: 901px) {
  .s1cal .k-cal { --kc-lane: 50px; }
  .s1cal .k-cal-ev { max-height: 47px; }
  .s1cal-side-panel { padding-inline: 0; border: 0; background: none; box-shadow: none; }
}
/* An empty Today strip and an empty "could not load" slot take no room (display:grid beat [hidden], leaving a gap above the month). */
.s1cal-today[hidden], .s1cal [data-s1cal-degraded]:empty { display: none; }
.s1cal .s1cal-sched .s1cal-host { padding-top: 0; }
@media (min-width: 901px) { .s1cal .s1cal-layout { row-gap: 8px; } }
