/* Silos - styles. Design tokens first (light + dark share the same names), components below. IBM Plex Sans, The Farm 51 orange as the only accent. */
:root {
  /* surfaces: page < sidebar/cards < raised; hairlines instead of heavy borders */
  --bg: #f4f5f7; --surface: #ffffff; --surface-2: #f8f9fb; --surface-3: #eff1f5;
  --fg: #161b25; --muted: #5d6675; --faint: #687181; --line: #dfe3ea; --line-soft: #eaedf2; --ctl-line: #878f9b;
  --accent: #c24706; --accent-hover: #a63d05; --accent-soft: #fdece0; --accent-ink: #a8400a; --accent-fg: #ffffff;
  --ok: #1d7a4b; --ok-soft: #e1f2e9; --warn: #8f5f00; --warn-soft: #faefd5; --crit: #b3212b; --crit-soft: #fae4e5; --info: #2858ad; --info-soft: #e3ecf9;
  --chip: #edf0f4; --chip-on: #161b25; --chip-on-fg: #ffffff; --hover: rgba(22, 27, 37, .04); --wknd: rgba(22, 27, 37, .035);
  --st-todo: #646e80; --st-doing: #2858ad; --st-review: #7449bd; --st-done: #1d7a4b; --st-blocked: #b3212b;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .06);
  --shadow: 0 2px 4px rgba(16, 24, 40, .05), 0 12px 32px -4px rgba(16, 24, 40, .16);
  --ring: 0 0 0 3px color-mix(in srgb, var(--accent) 24%, transparent);
  --scrim: rgba(15, 20, 30, .42);
  --font-body: "Twemoji Country Flags", "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif; --font-mono: "Twemoji Country Flags", "IBM Plex Mono", ui-monospace, Consolas, monospace;
  --side-w: 15rem; --radius: 0.5rem; --radius-lg: 0.75rem; --ctl: 2rem; color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c1016; --surface: #141921; --surface-2: #10151c; --surface-3: #1a2029; --fg: #e8ebf1; --muted: #98a1b0; --faint: #8a94a3; --line: #262d38; --line-soft: #1e252f; --ctl-line: #626b7b;
    --accent: #f2803a; --accent-hover: #f6955a; --accent-soft: #2e1e14; --accent-ink: #f6a272; --accent-fg: #1b0e05;
    --ok: #5fc58f; --ok-soft: #14301f; --warn: #e5b653; --warn-soft: #34290f; --crit: #f27a81; --crit-soft: #381a1d; --info: #82aaee; --info-soft: #172740;
    --chip: #202733; --chip-on: #e8ebf1; --chip-on-fg: #0c1016; --hover: rgba(232, 235, 241, .05); --wknd: rgba(232, 235, 241, .03);
    --st-todo: #8f9aae; --st-doing: #82aaee; --st-review: #b79bf0; --st-done: #5fc58f; --st-blocked: #f27a81;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
    --shadow: 0 2px 4px rgba(0, 0, 0, .35), 0 16px 40px -4px rgba(0, 0, 0, .6);
    --scrim: rgba(3, 6, 10, .62); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0c1016; --surface: #141921; --surface-2: #10151c; --surface-3: #1a2029; --fg: #e8ebf1; --muted: #98a1b0; --faint: #8a94a3; --line: #262d38; --line-soft: #1e252f; --ctl-line: #626b7b;
  --accent: #f2803a; --accent-hover: #f6955a; --accent-soft: #2e1e14; --accent-ink: #f6a272; --accent-fg: #1b0e05;
  --ok: #5fc58f; --ok-soft: #14301f; --warn: #e5b653; --warn-soft: #34290f; --crit: #f27a81; --crit-soft: #381a1d; --info: #82aaee; --info-soft: #172740;
  --chip: #202733; --chip-on: #e8ebf1; --chip-on-fg: #0c1016; --hover: rgba(232, 235, 241, .05); --wknd: rgba(232, 235, 241, .03);
  --st-todo: #8f9aae; --st-doing: #82aaee; --st-review: #b79bf0; --st-done: #5fc58f; --st-blocked: #f27a81;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow: 0 2px 4px rgba(0, 0, 0, .35), 0 16px 40px -4px rgba(0, 0, 0, .6);
  --scrim: rgba(3, 6, 10, .62); color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 0.875rem/1.45 var(--font-body); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--info); }
code, .mono { font-family: var(--font-mono); font-size: 0.75rem; }
code { background: var(--chip); padding: 1px 0.3125rem; border-radius: 0.25rem; }
.muted { color: var(--muted); } .small { font-size: 0.75rem; } .nowrap { white-space: nowrap; } .ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.warn-text { color: var(--warn); font-size: 0.75rem; font-weight: 500; } .danger-text { color: var(--crit); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
::selection { background: var(--accent-soft); }
option { color: var(--fg); background: var(--surface); }

/* ---------- layout */
#app { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); height: 100vh; }
.main { display: flex; flex-direction: column; min-width: 0; height: 100vh; }
.view { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.page { flex: 1; overflow: auto; padding: 1.5rem 1.75rem 2.5rem; }
.page.narrow > * { max-width: 53.75rem; margin-left: auto; margin-right: auto; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1.125rem; }
.page-head h1 { font-size: 1.375rem; font-weight: 600; letter-spacing: -.01em; margin-bottom: 0.25rem; }

/* ---------- sidebar */
.sidebar { background: var(--surface); border-right: 1px solid var(--line); display: flex; flex-direction: column; height: 100vh; overflow: hidden; }
.brand { display: flex; align-items: center; gap: 0.625rem; padding: 1rem 1rem 0.75rem; font-weight: 600; font-size: 1.0625rem; letter-spacing: -.01em; }
.logo { width: 2.5rem; height: 2.5rem; border-radius: 0.625rem; background: #0e1116; display: grid; place-items: center; flex: none; padding: 0.3rem; box-shadow: 0 0 0 1px rgba(255, 255, 255, .08); }
.logo img { width: 100%; height: 100%; object-fit: contain; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; } .brand-text small { font-weight: 400; font-size: 0.72rem; color: var(--muted); letter-spacing: .02em; }
.proto { font-size: 0.625rem; font-weight: 500; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); border: 1px solid var(--line); padding: 1px 0.375rem; border-radius: 6.1875rem; margin-left: auto; }
.projects { flex: 1; overflow: auto; padding: 0.25rem 0.625rem 0.75rem; }
.side-label { font-size: 0.6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 0.625rem 0.5rem 0.375rem; }
.side-label.sub { margin-top: 0.5rem; }
.proj-row { display: flex; align-items: center; gap: 2px; border-radius: 0.5rem; padding-right: 2px; position: relative; }
.proj-row:hover { background: var(--hover); }
.proj-row.active { background: var(--accent-soft); }
.proj-row.archived { opacity: .6; }
.proj-name { flex: 1; min-width: 0; display: flex; align-items: center; gap: 0.5rem; padding: 0.4375rem 0.375rem; background: none; border: 0; text-align: left; border-radius: 0.5rem; }
.proj-row.all .proj-name { padding-left: 1.75rem; }
.proj-row.all .ico { display: none; }
.pn { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.proj-row .key { color: var(--muted); font-size: 0.6875rem; }
.count { font-size: 0.7188rem; color: var(--muted); background: var(--chip); padding: 0 0.4375rem; border-radius: 6.1875rem; min-width: 1.375rem; text-align: center; font-variant-numeric: tabular-nums; }
.proj-row.active .count { background: var(--surface); }
.chk { flex: none; width: 1.0625rem; height: 1.0625rem; margin-left: 0.375rem; border: 1.5px solid var(--line); border-radius: 0.3125rem; background: var(--surface); display: grid; place-items: center; color: var(--accent-fg); padding: 0; }
.chk svg { opacity: 0; }
.chk[aria-checked="true"] { background: var(--accent); border-color: var(--accent); }
.chk[aria-checked="true"] svg { opacity: 1; }
.gear { opacity: 0; } .proj-row:hover .gear, .gear:focus-visible { opacity: 1; }
.add-proj { margin-top: 0.5rem; width: 100%; justify-content: flex-start; color: var(--muted); }
.side-hint { font-size: 0.7188rem; color: var(--muted); padding: 0.375rem 0.5rem; }
.pdot { width: 0.5625rem; height: 0.5625rem; border-radius: 50%; flex: none; display: inline-block; }
.side-foot { border-top: 1px solid var(--line); padding: 0.625rem 0.75rem; display: flex; align-items: center; gap: 0.5rem; }
.me { flex: 1; display: flex; align-items: center; gap: 0.375rem; color: var(--muted); font-size: 0.7813rem; min-width: 0; }
.me select { flex: 1; min-width: 0; }

/* ---------- top bar */
.topbar { display: flex; align-items: center; gap: 1rem; padding: 0 1.25rem; height: 3.625rem; flex: none; background: var(--surface); border-bottom: 1px solid var(--line); }
.title { display: flex; align-items: baseline; gap: 0.625rem; min-width: 0; }
.title h1 { font-size: 1.0625rem; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.keytag { font-weight: 500; }
.tabs { display: flex; gap: 2px; margin-left: 0.5rem; }
.tab { display: inline-flex; align-items: center; gap: 0.4375rem; padding: 0.4375rem 0.75rem; border-radius: 0.5rem; color: var(--muted); text-decoration: none; font-weight: 500; }
.tab:hover { background: var(--hover); color: var(--fg); }
.tab[aria-current="page"] { background: var(--chip); color: var(--fg); }
/* the top bar only has room for so many labels: below these widths only the open tab keeps its label (the others have a tooltip), otherwise the search box and "+ Zadanie" were pushed off screen */
@media (max-width: 2000px) { .tabs.many .tab:not([aria-current="page"]) span { display: none; } .tabs.many .tab { padding: 0.4375rem 0.625rem; } }
@media (max-width: 1600px) { .tabs.mid .tab:not([aria-current="page"]) span { display: none; } .tabs.mid .tab { padding: 0.4375rem 0.625rem; } }
@media (max-width: 1300px) { .tabs.few .tab:not([aria-current="page"]) span { display: none; } .tabs.few .tab { padding: 0.4375rem 0.625rem; } }
/* movable navigation: tabs can live in the sidebar too; empty bars show a drop target while a tab is being dragged */
.tab[draggable="true"] { cursor: grab; }
.side-nav { display: flex; flex-direction: column; gap: 2px; padding: 0.25rem 0.625rem 0.5rem; border-bottom: 1px solid var(--line); }
.side-nav:empty { display: none; }
.side-nav .tab { padding: 0.4375rem 0.625rem; }
body.nav-dragging .side-nav:empty { display: block; min-height: 2.5rem; margin: 0.25rem 0.625rem 0.5rem; padding: 0; border: 1px dashed var(--line); border-radius: 0.5rem; }
body.nav-dragging .tabs { display: flex; min-width: 5rem; min-height: 2.25rem; border: 1px dashed var(--line); border-radius: 0.5rem; }
.nav-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; min-width: min(36rem, 80vw); }
.nav-col h3 { font-size: 0.75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 0.5rem; }
.nav-item { display: flex; align-items: center; gap: 0.375rem; padding: 0.25rem 0.5rem; margin-bottom: 0.375rem; border: 1px solid var(--line); border-radius: 0.5rem; }
.nav-item .nm { flex: 1; min-width: 0; font-weight: 500; }
.nav-item .icon-btn:disabled { opacity: .3; }
.drop-on { outline: 2px dashed var(--accent); outline-offset: -2px; }
.tabs:empty { display: none; }
/* manual order by drag & drop: a grip in the first column / timeline label, a line shows where the task will land */
.grip-h { position: absolute; left: 0.125rem; top: 50%; transform: translateY(-50%); color: var(--muted); cursor: grab; opacity: 0; font-size: 0.8rem; line-height: 1; letter-spacing: -0.2em; padding: 0.25rem 0.1rem; user-select: none; z-index: 5; }
tr.row:hover .grip-h, .tl-row.task:hover .grip-h, .grip-h:focus-visible { opacity: 1; }
td.c-key { position: relative; }
.row-dragging { opacity: 0.4; }
tr.drop-above > td { box-shadow: inset 0 2px 0 var(--accent); }
tr.drop-below > td { box-shadow: inset 0 -2px 0 var(--accent); }
.tl-row.drop-above { box-shadow: inset 0 2px 0 var(--accent); }
.tl-row.drop-below { box-shadow: inset 0 -2px 0 var(--accent); }
/* projects: "all projects" is a pinned zone, the list below shows 5 projects and then scrolls */
.proj-pinned { border: 1px solid var(--line); border-radius: 0.625rem; padding: 2px; margin-bottom: 0.5rem; }
.proj-scroll { max-height: var(--proj-h, calc(5 * 2.1438rem)); /* (one row is 2.1438rem; the handle under the list changes --proj-h) */ overflow-y: auto; scrollbar-width: thin; }
.proj-scroll .side-label.sub { position: sticky; top: 0; background: var(--surface); z-index: 1; }
@media (max-width: 1500px) { .search input { width: 9.375rem; } }
@media (max-width: 1200px) { .search input { width: 6.5rem; } }
.top-right { margin-left: auto; display: flex; align-items: center; gap: 0.625rem; }
.search { position: relative; display: flex; align-items: center; }
.search svg { position: absolute; left: 0.625rem; color: var(--muted); pointer-events: none; }
.search input { width: 13.75rem; height: 2.125rem; padding: 0 0.625rem 0 2rem; border: 1px solid var(--line); border-radius: 0.5rem; background: var(--surface-2); }
.search input:focus { background: var(--surface); }
.menu-btn { display: none; }

/* ---------- buttons and controls */
.btn { height: 2.125rem; padding: 0 0.8125rem; border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); font-weight: 500; display: inline-flex; align-items: center; justify-content: center; gap: 0.375rem; white-space: nowrap; transition: background .12s, border-color .12s; }
.btn:hover { background: var(--chip); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.btn.primary:hover { filter: brightness(1.07); background: var(--accent); }
.btn.danger { background: var(--crit); border-color: var(--crit); color: #fff; } .btn.danger:hover { background: var(--crit); filter: brightness(1.08); }
.btn.ghost { border-color: transparent; background: transparent; } .btn.ghost:hover { background: var(--chip); }
.btn.sm { height: 1.75rem; padding: 0 0.625rem; font-size: 0.7813rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.625rem 0; } .btn-row.center { justify-content: center; }
.icon-btn { width: 2rem; height: 2rem; display: inline-grid; place-items: center; border: 0; background: transparent; border-radius: 0.5rem; color: var(--muted); padding: 0; }
.icon-btn:hover { background: var(--chip); color: var(--fg); }
.icon-btn.sm { width: 1.625rem; height: 1.625rem; } .icon-btn.on { color: var(--accent); }
.hover-only { opacity: 0; } tr:hover .hover-only, .item:hover .hover-only, .item-link:hover .hover-only, .hover-only:focus-visible { opacity: 1; }
.input, select, .cell-input { border: 1px solid var(--line); border-radius: 0.375rem; background: var(--surface); }
.input { width: 100%; padding: 0.4375rem 0.625rem; border-radius: var(--radius); }
.input:focus, select:focus, .cell-input:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px var(--accent-soft); }
.input.invalid { border-color: var(--crit); box-shadow: 0 0 0 3px var(--crit-soft); }
textarea.input { resize: vertical; line-height: 1.5; }
select { padding: 0.3125rem 0.5rem; max-width: 100%; }
.sel { height: 1.875rem; font-size: 0.7813rem; }
.check { display: inline-flex; align-items: center; gap: 0.4375rem; font-size: 0.7813rem; color: var(--muted); cursor: pointer; }
.check input { accent-color: var(--accent); width: 0.9375rem; height: 0.9375rem; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.seg-btn { border: 0; background: transparent; padding: 0.375rem 0.75rem; display: inline-flex; align-items: center; gap: 0.375rem; border-right: 1px solid var(--line); color: var(--muted); font-weight: 500; }
.seg-btn:last-child { border-right: 0; }
.seg-btn[aria-pressed="true"] { background: var(--chip-on); color: var(--chip-on-fg); }
.seg.sm .seg-btn { padding: 3px 0.625rem; font-size: 0.7813rem; }
.chips { display: flex; flex-wrap: wrap; gap: 0.375rem; }
.chipf { height: 1.75rem; padding: 0 0.625rem; border-radius: 6.1875rem; border: 1px solid var(--line); background: var(--surface); font-size: 0.7813rem; display: inline-flex; align-items: center; gap: 0.375rem; white-space: nowrap; }
.chipf:hover { background: var(--chip); }
.chipf[aria-pressed="true"] { background: var(--chip-on); color: var(--chip-on-fg); border-color: var(--chip-on); }
.chipf[aria-pressed="true"] .count { background: rgba(255, 255, 255, .18); color: inherit; }
.dot { width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--c, currentColor); flex: none; display: inline-block; }
.field { display: flex; flex-direction: column; gap: 0.3125rem; margin-bottom: 0.75rem; min-width: 0; }
.field-label, .meta-field > span { font-size: 0.75rem; font-weight: 500; color: var(--muted); }
.hint { font-size: 0.75rem; color: var(--muted); } .form-error { color: var(--crit); font-size: 0.8125rem; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 0.875rem; }
.key-row { grid-template-columns: 1fr 10rem; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem; }
.swatches { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.swatches button { width: 1.625rem; height: 1.625rem; border-radius: 50%; border: 0; color: #fff; display: grid; place-items: center; padding: 0; }
.swatches button svg { opacity: 0; } .swatches button[aria-checked="true"] { outline: 2px solid var(--fg); outline-offset: 2px; } .swatches button[aria-checked="true"] svg { opacity: 1; }
.sw-custom { position: relative; width: 1.625rem; height: 1.625rem; border-radius: 50%; display: grid; place-items: center; color: #fff; cursor: pointer; overflow: hidden;
  background: conic-gradient(#d9560b, #e3b24f, #5cc48d, #2a9db0, #2a5db0, #7a4bc2, #c2417a, #d9560b); }
.sw-custom input { position: absolute; inset: -0.5rem; width: calc(100% + 1rem); height: calc(100% + 1rem); opacity: 0; cursor: pointer; padding: 0; border: 0; }
.sw-custom svg { opacity: 0; pointer-events: none; filter: drop-shadow(0 0 2px rgba(0, 0, 0, .6)); } .sw-custom[aria-checked="true"] svg { opacity: 1; }
.sw-custom[aria-checked="true"] { outline: 2px solid var(--fg); outline-offset: 2px; }
.sw-hex { width: 6.5rem; padding: 0.25rem 0.5rem; }
.avatar.photo { object-fit: cover; background: var(--chip); }
.color-input { width: 1.75rem; height: 1.75rem; padding: 0; border: 0; background: none; border-radius: 50%; cursor: pointer; }
.color-input::-webkit-color-swatch-wrapper { padding: 0; } .color-input::-webkit-color-swatch { border: 0; border-radius: 50%; }

/* ---------- filters */
.filterbar { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem 1rem; flex-wrap: wrap; padding: 0.625rem 1.25rem; background: var(--surface-2); border-bottom: 1px solid var(--line); flex: none; }
.filters, .tools { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.result-count { font-size: 0.7813rem; }

/* ---------- shared elements */
.avatar { display: inline-grid; place-items: center; border-radius: 50%; color: #fff; font-weight: 600; flex: none; line-height: 1; letter-spacing: .02em; }
.avatar.noone { background: transparent; border: 1.5px dashed var(--line); color: var(--muted); font-weight: 500; }
.who { display: inline-flex; align-items: center; gap: 0.375rem; position: relative; min-width: 0; }
.who select { position: absolute; inset: 0; width: 100%; opacity: 0; cursor: pointer; }
.who.named { width: 100%; } .who.named select { position: static; opacity: 1; border-color: transparent; background: transparent; flex: 1; min-width: 0; padding: 0.3125rem 2px; cursor: pointer; }
.who.named select:hover { border-color: var(--line); }
.keychip { display: inline-flex; align-items: center; gap: 0.3125rem; padding: 2px 0.5rem 2px 0.375rem; border-radius: 0.375rem; background: var(--chip); border: 0; color: var(--fg); white-space: nowrap; flex: none; }
.keychip:hover { background: var(--info-soft); color: var(--info); } .keychip.static { cursor: default; } .keychip.static:hover { background: var(--chip); color: var(--fg); }
.ti { display: inline-flex; }
.proj-tag { display: inline-flex; align-items: center; gap: 0.375rem; font-size: 0.75rem; color: var(--muted); font-weight: 500; }
.chip-link { background: none; border: 0; color: var(--info); font-family: var(--font-mono); font-size: 0.75rem; padding: 0; }
.st-todo { --c: var(--st-todo); } .st-doing { --c: var(--st-doing); } .st-review { --c: var(--st-review); } .st-done { --c: var(--st-done); } .st-blocked { --c: var(--st-blocked); }
.pill { --c: var(--st-todo); display: inline-flex; align-items: center; gap: 0.4375rem; padding: 2px 1.375rem 2px 0.5625rem; border-radius: 6.1875rem; position: relative; max-width: 100%;
  background: color-mix(in srgb, var(--c) 14%, transparent); color: color-mix(in srgb, var(--c) 82%, var(--fg)); font-weight: 500; font-size: 0.7813rem; }
.pill::after { content: ""; position: absolute; right: 0.5625rem; top: 50%; margin-top: -2px; border: 0.2188rem solid transparent; border-top-color: currentColor; border-bottom: 0; opacity: .7; pointer-events: none; }
.pill .dot { background: var(--c); }
.pill select { appearance: none; border: 0; background: transparent; color: inherit; font: inherit; padding: 3px 0; cursor: pointer; min-width: 0; text-overflow: ellipsis; box-shadow: none !important; }
.pill:focus-within { outline: 2px solid var(--accent); outline-offset: 1px; }
.pbars { display: inline-flex; align-items: flex-end; gap: 2px; height: 0.75rem; }
.pbars i { width: 3px; border-radius: 1px; background: color-mix(in srgb, var(--c) 28%, transparent); }
.pbars i:nth-child(1) { height: 0.25rem; } .pbars i:nth-child(2) { height: 0.375rem; } .pbars i:nth-child(3) { height: 0.5625rem; } .pbars i:nth-child(4) { height: 0.75rem; } .pbars i.on { background: var(--c); }
.progress { display: flex; align-items: center; gap: 0.5rem; min-width: 0; }
.track { flex: 1; height: 0.375rem; border-radius: 3px; background: var(--chip); overflow: hidden; min-width: 2.25rem; }
.track span { display: block; height: 100%; background: var(--accent); border-radius: 3px; transition: width .2s; } .track span.full { background: var(--ok); }
.progress .num { font-size: 0.75rem; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.segbar { display: flex; gap: 2px; height: 0.5rem; border-radius: 0.25rem; overflow: hidden; background: var(--chip); }
.segbar span { min-width: 3px; }
.circle { --c: var(--st-todo); width: 1.25rem; height: 1.25rem; border-radius: 50%; border: 2px solid var(--c); background: transparent; display: inline-grid; place-items: center; padding: 0; flex: none; color: #fff; transition: transform .1s; }
.circle:hover { transform: scale(1.12); }
.circle.st-doing { background: conic-gradient(var(--c) 0 50%, transparent 0); }
.circle.st-review { background: radial-gradient(var(--c) 0 32%, transparent 36%); }
.circle.st-done, .circle.st-blocked { background: var(--c); }
.empty { text-align: center; padding: 3.5rem 1.25rem; color: var(--muted); } .empty h3 { color: var(--fg); font-size: 1rem; margin-bottom: 0.375rem; } .empty p { max-width: 28.75rem; margin: 0 auto 0.875rem; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 0.75rem; padding: 1rem; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(18.125rem, 1fr)); gap: 0.875rem; }
.cl-card { text-align: left; display: flex; flex-direction: column; gap: 0.5rem; transition: border-color .12s, box-shadow .12s; }
.cl-card:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.cl-card h3 { font-size: 0.9375rem; } .card-top { display: flex; justify-content: space-between; } .card-foot { display: flex; justify-content: space-between; align-items: center; gap: 0.625rem; }
.card-foot .progress { flex: 1; }
.block { margin-bottom: 1rem; } .block h2 { font-size: 0.9375rem; margin-bottom: 0.75rem; display: flex; align-items: center; gap: 0.5rem; }
.rows { display: flex; flex-direction: column; gap: 0.375rem; margin-bottom: 0.625rem; }
.edit-row { display: grid; grid-template-columns: auto auto 1fr 12.5rem auto auto; gap: 0.625rem; align-items: center; }
.edit-row:has(> .color-input + .input) { grid-template-columns: auto 1fr auto auto; }
.danger-zone { margin-top: 1.125rem; padding-top: 0.875rem; border-top: 1px dashed var(--line); }
.add-input { background: transparent; border-style: dashed; margin-top: 0.5rem; }
.add-input:focus { background: var(--surface); }

/* ---------- table */
.tbl-wrap { flex: 1; overflow: auto; background: var(--surface); position: relative; }
.grid { border-collapse: separate; border-spacing: 0; table-layout: fixed; width: 100%; min-width: 107rem; }
.grid th { position: sticky; top: 0; z-index: 3; background: var(--surface-2); text-align: left; padding: 0; border-bottom: 1px solid var(--line); border-right: 1px solid var(--line-soft); height: 2.125rem; }
.th-btn { width: 100%; height: 100%; text-align: left; background: none; border: 0; padding: 0 0.625rem; font-size: 0.75rem; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 0.375rem; }
.th-btn:hover { color: var(--fg); background: var(--chip); } .sort-ind { color: var(--accent); }
.grid td { padding: 0 0.375rem; height: 2.5rem; border-bottom: 1px solid var(--line-soft); border-right: 1px solid var(--line-soft); vertical-align: middle; overflow: hidden; }
.grid td.c-key { padding-left: 0.625rem; }
.row:hover td { background: var(--hover); }
.row.st-done .cell-input.title, .row.st-done .cell-input.title { color: var(--muted); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--muted) 50%, transparent); }
.title-cell { display: flex; align-items: center; gap: 0.375rem; min-width: 0; }
.tree-l { width: 0.625rem; height: 0.75rem; border-left: 1.5px solid var(--line); border-bottom: 1.5px solid var(--line); border-bottom-left-radius: 0.25rem; flex: none; margin-top: -0.5rem; }
.parent-tag { font-family: var(--font-mono); font-size: 0.6875rem; color: var(--muted); background: var(--chip); padding: 1px 0.375rem; border-radius: 0.3125rem; white-space: nowrap; flex: none; }
.cell-input { width: 100%; min-width: 0; border-color: transparent; background: transparent; padding: 0.375rem 0.5rem; border-radius: 0.3125rem; text-overflow: ellipsis; }
.cell-input:hover { border-color: var(--line); } .cell-input:focus { background: var(--surface); }
.cell-input.title.feat { font-weight: 600; } .cell-input.date { font-size: 0.7813rem; font-variant-numeric: tabular-nums; padding: 0.3125rem 0.25rem; }
.cell-input.date.overdue { color: var(--crit); font-weight: 500; }
select.cell-select { width: 100%; border-color: transparent; background: transparent; padding: 0.375rem 0.25rem; cursor: pointer; } select.cell-select:hover { border-color: var(--line); }
select.cell-select.compact { width: auto; border-color: var(--line); background: var(--surface); }
.group-row td { background: var(--surface-2); height: 2.25rem; padding: 0 0.375rem; border-right: 0; overflow: visible; }
.group-row .group-btn { position: sticky; left: 0.5rem; }
.group-btn { display: inline-flex; align-items: center; gap: 0.5rem; background: none; border: 0; padding: 0.25rem 0.375rem; border-radius: 0.375rem; }
.group-btn:hover { background: var(--chip); }
.chev { display: inline-flex; transition: transform .12s; color: var(--muted); } .chev.open { transform: rotate(90deg); }
.quick-row td { background: var(--surface); border-right: 0; height: 2.75rem; }
.quickadd { display: flex; align-items: center; gap: 0.5rem; } .cell-input.quick { flex: 1; border-style: dashed; border-color: var(--line); }

/* ---------- timeline */
.tl-wrap { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; }
.tl { flex: 1; overflow: auto; background: var(--surface); position: relative; }
.tl-inner { position: relative; min-height: 100%; }
.tl-overlay { position: absolute; top: 0; bottom: 0; pointer-events: none; z-index: 1; background-repeat: repeat-x; }
.wknd { position: absolute; top: 0; bottom: 0; background: var(--wknd); }
.today-line { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--accent); opacity: .65; }
.ms-line { position: absolute; top: 0; bottom: 0; border-left: 2px dashed; margin-left: -1px; opacity: .5; }
.ms-line.done { opacity: .25; }
.tl-head { position: sticky; top: 0; z-index: 6; display: flex; height: 3.625rem; background: var(--surface); border-bottom: 1px solid var(--line); }
.tl-corner { position: sticky; left: 0; z-index: 7; width: 19.375rem; flex: none; background: var(--surface-2); border-right: 1px solid var(--line); display: flex; align-items: flex-end; justify-content: space-between; padding: 0 0.75rem 0.5rem; font-weight: 600; font-size: 0.75rem; color: var(--muted); }
.tl-scale { position: relative; flex: none; height: 3.625rem; }
.tl-months { position: relative; height: 1.75rem; border-bottom: 1px solid var(--line-soft); }
.tl-month { position: absolute; top: 0; bottom: 0; border-left: 1px solid var(--line); font-weight: 600; font-size: 0.75rem; text-transform: capitalize; white-space: nowrap; }
.tl-month span { position: sticky; left: 20.125rem; padding: 0 0.5rem; line-height: 1.75rem; display: inline-block; }
.tl-days { position: relative; height: 1.875rem; }
.tl-day { position: absolute; top: 0; bottom: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 0.6875rem; line-height: 1.15; color: var(--muted); border-left: 1px solid var(--line-soft); font-variant-numeric: tabular-nums; }
.tl-day b { font-weight: 500; color: var(--fg); } .tl-day i { font-style: normal; font-size: 0.5938rem; opacity: .7; text-transform: uppercase; }
.tl-day.we { background: var(--wknd); } .tl-day.we b { color: var(--muted); }
.tl-day.today b { background: var(--accent); color: var(--accent-fg); border-radius: 6.1875rem; padding: 0 0.3125rem; }
.tl-day.wk { justify-content: center; align-items: flex-start; padding-left: 0.3125rem; }
.today-tag { position: absolute; bottom: -1px; width: 0.75rem; height: 0.4375rem; margin-left: -0.375rem; background: var(--accent); clip-path: polygon(50% 0, 0 100%, 100% 100%); font-size: 0; z-index: 2; }
.tl-row { display: flex; height: 2.25rem; position: relative; }
.tl-label { position: sticky; left: 0; z-index: 4; width: 19.375rem; flex: none; background: var(--surface); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line-soft); display: flex; align-items: center; gap: 0.5rem; padding: 0 0.625rem; overflow: hidden; cursor: pointer; }
.tl-lane { position: relative; flex: none; z-index: 2; height: 2.25rem; border-bottom: 1px solid var(--line-soft); }
.tl-row.task:hover .tl-lane { background: var(--hover); } .tl-row.task:hover .tl-label { background: var(--surface-2); }
.tl-label-in { display: flex; align-items: center; gap: 0.5rem; min-width: 0; flex: 1; }
.tl-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .tl-title.st-done { color: var(--muted); text-decoration: line-through; }
.tl-row.group .tl-label, .tl-row.group .tl-lane { background: var(--surface-2); cursor: default; }
.ms-row .tl-label { cursor: default; gap: 0.4375rem; } .ms-ico { color: var(--accent); display: inline-flex; } .ms-row .icon-btn { margin-left: auto; }
.ms-row .tl-lane { background: color-mix(in srgb, var(--accent) 4%, transparent); }
.lane-hint { position: absolute; left: 0.625rem; top: 0.5625rem; font-size: 0.75rem; color: var(--muted); opacity: 0; pointer-events: none; white-space: nowrap; } .tl-lane:hover .lane-hint { opacity: .8; }
.bar { --c: var(--accent); position: absolute; top: 0.4375rem; height: 1.375rem; border-radius: 0.375rem; background: color-mix(in srgb, var(--c) 20%, var(--surface)); border: 1px solid var(--c); display: flex; align-items: center; overflow: hidden; cursor: grab; touch-action: none; user-select: none; z-index: 2; }
.bar:hover { filter: brightness(.97); box-shadow: 0 2px 0.5rem rgba(0, 0, 0, .15); }
.bar-fill { position: absolute; left: 0; top: 0; bottom: 0; background: color-mix(in srgb, var(--c) 48%, transparent); pointer-events: none; }
.bar-text { position: relative; padding: 0 0.5625rem; font-size: 0.75rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.grip { position: absolute; top: 0; bottom: 0; width: 0.5rem; cursor: ew-resize; z-index: 2; } .grip.l { left: 0; } .grip.r { right: 0; }
.bar:hover .grip { background: color-mix(in srgb, var(--c) 40%, transparent); }
.bar.type-feature { background: var(--c); color: #fff; } .bar.type-feature .bar-fill { background: rgba(0, 0, 0, .28); } .bar.type-feature .bar-text { color: #fff; }
.bar.type-bug { box-shadow: inset 0.25rem 0 0 var(--crit); }
.bar.st-done { opacity: .5; } .bar.st-blocked { border-style: dashed; border-color: var(--crit); }
.bar.dragging { cursor: grabbing; z-index: 8; box-shadow: var(--shadow); }
.ms-mark { --c: var(--accent); position: absolute; top: 0.25rem; height: 1.75rem; display: flex; align-items: center; gap: 0.25rem; cursor: grab; touch-action: none; user-select: none; z-index: 3; color: var(--c); }
.diamond { display: inline-flex; } .diamond svg { fill: var(--c); stroke: var(--surface); stroke-width: 2; }
.ms-name { font-size: 0.75rem; font-weight: 600; color: var(--fg); white-space: nowrap; background: color-mix(in srgb, var(--surface) 80%, transparent); padding: 0 0.25rem; border-radius: 0.25rem; }
.ms-name small { color: var(--muted); font-weight: 400; margin-left: 0.375rem; font-size: 0.6875rem; }
.ms-mark.done { opacity: .5; } .ms-mark.dragging { cursor: grabbing; }

.add-sub.always { opacity: 1; color: var(--accent); } .add-sub.always:hover { background: var(--accent-soft); }

/* ---------- people assignment in checklists */
.who-chips { align-items: center; } .chips-label { font-size: 0.8rem; color: var(--muted); margin-right: 0.25rem; }
.who-chips .chipf { height: 2rem; padding-left: 0.35rem; }
.item-ctl .who.named { width: 11rem; flex: none; }
.item-ctl .who.named select, .cl-group-head .grp-assign { border-color: var(--line); }
.item.compact .item-ctl .who.named { width: 10rem; }
.who.unassigned select { color: var(--muted); }
.cl-group-head .grp-assign { margin-left: auto; font-size: 0.78rem; max-width: 12rem; color: var(--muted); }

/* ---------- milestones */
.link-btn { display: inline-flex; align-items: center; gap: 0.3rem; background: none; border: 0; padding: 0.2rem 0; color: var(--info); font-size: 0.8rem; font-weight: 500; margin: -0.5rem 0 0.75rem; }
.link-btn:hover { text-decoration: underline; }
.ms-tasks { margin-top: 0.25rem; } .ms-list { max-height: 14rem; overflow: auto; }
.ms-done { margin-top: 0.35rem; }
.ms-range { position: absolute; top: calc(50% - 0.3rem); height: 0.6rem; border-radius: 99px; background: color-mix(in srgb, var(--c) 38%, transparent); border: 1px solid color-mix(in srgb, var(--c) 70%, transparent); cursor: pointer; z-index: 2; }
.ms-range:hover { background: color-mix(in srgb, var(--c) 55%, transparent); } .ms-range.done { opacity: .45; }
.ms-card { padding: 0.25rem 0.5rem; }
.ms-table { width: 100%; border-collapse: collapse; }
.ms-table th { text-align: left; font-size: 0.75rem; font-weight: 600; color: var(--muted); padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--line); }
.ms-table td { padding: 0.7rem 0.75rem; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.ms-table tr:last-child td { border-bottom: 0; } .ms-table tr.done { opacity: .6; }
.ms-name-btn { display: inline-flex; align-items: center; gap: 0.5rem; background: none; border: 0; padding: 0; text-align: left; }
.ms-name-btn:hover strong { text-decoration: underline; } .ms-dia svg { fill: currentColor; }
.ms-prog { min-width: 11rem; } .ms-actions { text-align: right; white-space: nowrap; } .ms-actions .btn + .btn { margin-left: 0.35rem; }
.ms-time { font-size: 0.85rem; color: var(--muted); } .ms-time.ok { color: var(--ok); font-weight: 500; } .ms-time.warn { color: var(--warn); font-weight: 500; } .ms-time.bad { color: var(--crit); font-weight: 500; }

/* ---------- avatars */
.avatar-btn { background: none; border: 0; padding: 0; border-radius: 50%; position: relative; display: inline-grid; }
.avatar-btn:hover::after { content: "✎"; position: absolute; inset: 0; display: grid; place-items: center; border-radius: 50%; background: rgba(0, 0, 0, .55); color: #fff; font-size: 0.8rem; }
.avatar-preview { display: grid; place-items: center; padding: 0.5rem 0 0.75rem; }
.me-head { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.25rem; } .me-head p { margin-bottom: 0.4rem; }
.center-text { text-align: center; }

/* ---------- holidays, weekends, interface size */
.hol-col { position: absolute; top: 0; bottom: 0; background: color-mix(in srgb, var(--crit) 11%, transparent); }
.tl-day.hol { background: var(--crit-soft); } .tl-day.hol b, .tl-day.hol i { color: var(--crit); font-weight: 600; opacity: 1; }
.legend { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.78rem; color: var(--muted); }
.dot.hol { background: var(--crit); }
.aa-btn { font-weight: 600; font-size: 0.8rem; }

/* ---------- dependencies */
.tl-deps { position: absolute; top: 0; z-index: 3; pointer-events: none; overflow: visible; }
.tl-deps .dep { fill: none; stroke: var(--muted); stroke-width: 1.5; stroke-linejoin: round; opacity: .75; pointer-events: stroke; }
.tl-deps .dep.met { opacity: .35; stroke-dasharray: 4 3; }
.tl-deps .dep.bad { stroke: var(--crit); stroke-width: 2; opacity: 1; }
.lock { display: inline-flex; color: var(--warn); flex: none; }
.dep-label { display: flex; align-items: center; gap: 0.375rem; font-size: 0.75rem; font-weight: 500; color: var(--muted); margin: 0.625rem 0 0.25rem; }
.dep-label:first-child { margin-top: 0; }
.dep-add { margin-top: 0.5rem; width: 100%; color: var(--muted); border-style: dashed; background: transparent; }
.viol { font-size: 0.6875rem; font-weight: 600; color: var(--crit); background: var(--crit-soft); padding: 1px 0.4375rem; border-radius: 6.1875rem; white-space: nowrap; }

/* ---------- login, account */
.auth-wrap { grid-column: 1 / -1; min-height: 100vh; display: grid; place-items: center; padding: 1.5rem 1rem; background: var(--bg); }
.auth-card { width: min(26.25rem, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 1rem; padding: 1.75rem 1.75rem 1.5rem; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.auth-card h1 { font-size: 1.25rem; margin-bottom: 0.375rem; letter-spacing: -.01em; } .auth-card > p { margin-bottom: 0.875rem; }
.auth-card .field:first-of-type { margin-top: 0.875rem; }
.auth-brand { display: flex; align-items: center; gap: 0.875rem; font-weight: 600; font-size: 1.25rem; margin-bottom: 1.25rem; }
.auth-brand .logo { width: 3.5rem; height: 3.5rem; border-radius: 0.875rem; padding: 0.45rem; }
.wide-btn { width: 100%; height: 2.5rem; margin-top: 0.5rem; }
.me-btn { flex: 1; min-width: 0; display: flex; align-items: center; gap: 0.5625rem; background: none; border: 0; border-radius: 0.5rem; padding: 0.3125rem 0.375rem; text-align: left; }
.me-btn:hover { background: var(--chip); }
.me-name { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; } .me-name strong { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .me-name small { color: var(--muted); font-size: 0.6875rem; }
.modal-sec { font-size: 0.75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 1.125rem 0 0.5rem; font-weight: 600; }
.token-row { display: flex; justify-content: space-between; align-items: center; gap: 0.625rem; padding: 0.5rem 0; border-bottom: 1px solid var(--line-soft); }
.token-add { margin-top: 0.625rem; gap: 0.5rem; } .token-add .input { flex: 1; }
.new-token { background: var(--warn-soft); border: 1px solid var(--warn); border-radius: 0.625rem; padding: 0.625rem 0.75rem; margin: 0.5rem 0; } .token-value { display: flex; gap: 0.5rem; align-items: center; margin-top: 0.375rem; } .token-value code { flex: 1; overflow-wrap: anywhere; background: var(--surface); padding: 0.375rem 0.5rem; }
.pw-row { display: flex; gap: 0.5rem; } .pw-row .input { flex: 1; }
.acct { display: inline-flex; align-items: center; gap: 0.3125rem; font-size: 0.75rem; color: var(--muted); white-space: nowrap; } .acct.admin { color: var(--accent); font-weight: 500; } .acct.none { opacity: .7; }
.acct-btn { padding: 0 0.375rem; }
.edit-row.people { grid-template-columns: auto auto 1fr 11.875rem auto auto auto; } .edit-row.depts { grid-template-columns: auto 1fr auto auto; }

/* ---------- task panel */
.drawer-wrap { position: fixed; inset: 0; z-index: 50; }
.scrim { position: absolute; inset: 0; background: rgba(10, 15, 25, .3); }
.drawer { position: absolute; right: 0; top: 0; bottom: 0; width: min(36.25rem, 100vw); background: var(--surface); box-shadow: var(--shadow); display: flex; flex-direction: column; }
.drawer-wrap.enter .drawer { animation: slide .2s ease-out; } .drawer-wrap.enter .scrim { animation: fade .2s ease-out; }
@keyframes slide { from { transform: translateX(2rem); opacity: .4; } } @keyframes fade { from { opacity: 0; } }
.drawer-head { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; padding: 0.625rem 0.875rem; border-bottom: 1px solid var(--line); flex: none; }
.drawer-actions { display: flex; gap: 0.375rem; flex-wrap: wrap; }
.drawer-body { flex: 1; overflow: auto; padding: 1.125rem 1.375rem 2.5rem; }
.drawer-chips { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem; flex-wrap: wrap; }
.drawer-title { width: 100%; font-size: 1.3125rem; font-weight: 600; line-height: 1.3; letter-spacing: -.01em; border: 1px solid transparent; border-radius: 0.5rem; padding: 0.25rem 0.5rem; margin: 0 -0.5rem 0.875rem; background: transparent; resize: none; field-sizing: content; }
.drawer-title:hover { border-color: var(--line); } .drawer-title:focus { border-color: var(--accent); outline: none; background: var(--surface); }
.props { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem 1rem; margin-bottom: 0.5rem; }
.prop { display: flex; flex-direction: column; gap: 0.25rem; min-width: 0; align-items: flex-start; } .prop > select, .prop > .input { width: 100%; }
.prop-label { font-size: 0.7188rem; font-weight: 500; color: var(--muted); }
.prop .who.named { border: 1px solid var(--line); border-radius: 0.375rem; padding: 0 0.375rem; background: var(--surface); }
.dsec { margin-top: 1.375rem; } .dsec-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.5rem; }
.dsec-head h3 { font-size: 0.75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600; }
.desc { min-height: 6.25rem; }
.sublist { display: flex; flex-direction: column; } .subrow { display: flex; align-items: center; gap: 0.625rem; padding: 0.375rem 2px; border-bottom: 1px solid var(--line-soft); }
.subtitle { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .subtitle.done { color: var(--muted); text-decoration: line-through; }
.log { list-style: none; margin: 0; padding: 0; font-size: 0.8125rem; display: flex; flex-direction: column; gap: 0.3125rem; }
.cl-block { border: 1px solid var(--line); border-radius: 0.625rem; padding: 0.625rem 0.75rem; margin-bottom: 0.75rem; }
.cl-block-head { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.25rem; } .cl-block-head .progress { flex: 1; }

/* ---------- checklists */
.item { border-bottom: 1px solid var(--line-soft); padding: 0.3125rem 2px; }
.item-main { display: flex; align-items: flex-start; gap: 0.625rem; }
.item-main > .circle { margin-top: 0.45rem; } .item-ctl { margin-top: 0.1rem; }
.item-text { flex: 1; min-width: 0; border: 1px solid transparent; background: transparent; border-radius: 0.375rem; padding: 0.375rem 0.5rem; resize: none; overflow: hidden; field-sizing: content; line-height: 1.4; font: inherit; color: inherit; }
.item-text:hover { border-color: var(--line); } .item-text:focus { outline: none; border-color: var(--accent); background: var(--surface); }
.item-text.done { color: var(--muted); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--muted) 50%, transparent); }
.item-ctl { display: flex; align-items: center; gap: 0.5rem; flex: none; }
.item-link { display: inline-flex; align-items: center; gap: 2px; }
.item-add-task { color: var(--muted); } .item:not(:hover) .item-add-task { opacity: .55; }
.item.compact .item-main { flex-wrap: wrap; row-gap: 2px; } .item.compact .item-text { flex: 1 1 calc(100% - 2.125rem); }
.item.compact .item-ctl { flex: 1 1 100%; padding-left: 1.875rem; justify-content: flex-start; flex-wrap: wrap; }
.item-note { display: block; width: calc(100% - 2rem); margin: 0.25rem 0 0.25rem 2rem; border: 1px solid var(--line); border-radius: 0.375rem; padding: 0.375rem 0.5rem; background: var(--surface-2); resize: vertical; }
.page.cl-detail { padding-inline: max(1.75rem, calc((100% - 80rem) / 2)); } /* content centered on wide screens, scrollbar at the edge */
.cl-top { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 0.625rem; } .cl-actions { display: flex; gap: 0.375rem; flex-wrap: wrap; }
.cl-title-row { display: flex; align-items: center; gap: 0.875rem; margin-bottom: 0.375rem; }
.cl-title { flex: 1; min-width: 0; font-size: 1.5rem; font-weight: 600; letter-spacing: -.01em; border: 1px solid transparent; border-radius: 0.5rem; padding: 0.25rem 0.5rem; margin-left: -0.5rem; background: transparent; }
.cl-title:hover { border-color: var(--line); } .cl-title:focus { outline: none; border-color: var(--accent); background: var(--surface); }
.cl-meta { display: flex; align-items: flex-end; gap: 0.75rem; margin-bottom: 0.875rem; flex-wrap: wrap; } .meta-field { display: flex; flex-direction: column; gap: 0.25rem; min-width: 17.5rem; }
.cl-summary { background: var(--surface); border: 1px solid var(--line); border-radius: 0.75rem; padding: 0.875rem 1rem; margin-bottom: 0.875rem; display: flex; flex-direction: column; gap: 0.625rem; }
.cl-summary-top { display: flex; justify-content: space-between; align-items: baseline; }
.cl-filters { display: flex; gap: 0.625rem; margin-bottom: 0.5rem; } .cl-filters .input { max-width: 20rem; }
.cl-groups { display: flex; flex-direction: column; gap: 1.125rem; background: var(--surface); border: 1px solid var(--line); border-radius: 0.75rem; padding: 0.5rem 1rem 1rem; }
.cl-group-head { display: flex; align-items: center; gap: 0.625rem; padding-top: 0.75rem; }
.group-name { font-weight: 600; font-size: 0.8438rem; width: auto; flex: 0 1 23.75rem; }
.cl-addgroup { margin-top: 0.625rem; max-width: 26.25rem; }

/* ---------- dialogs, menus, toasts */
dialog.modal { border: 0; padding: 0; border-radius: 0.875rem; width: min(32.5rem, calc(100vw - 1.75rem)); background: var(--surface); color: var(--fg); box-shadow: var(--shadow); max-height: 90vh; }
dialog.modal.wide { width: min(45rem, calc(100vw - 1.75rem)); }
dialog.modal::backdrop { background: rgba(10, 15, 25, .45); }
.modal-box { display: flex; flex-direction: column; max-height: 90vh; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 0.875rem 0.875rem 0.625rem 1.25rem; } .modal-head h2 { font-size: 1rem; }
.modal-body { padding: 0.25rem 1.25rem 0.5rem; overflow: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 0.5rem; padding: 0.75rem 1.25rem 1rem; border-top: 1px solid var(--line-soft); margin-top: 0.5rem; }
.confirm-text { padding: 0.25rem 0 0.5rem; line-height: 1.55; }
.menu { position: fixed; z-index: 100; min-width: 12.5rem; background: var(--surface); border: 1px solid var(--line); border-radius: 0.625rem; box-shadow: var(--shadow); padding: 0.25rem; }
.menu-item { display: flex; align-items: center; gap: 0.5625rem; width: 100%; text-align: left; border: 0; background: none; padding: 0.5rem 0.625rem; border-radius: 0.375rem; }
.menu-item:hover, .menu-item:focus-visible { background: var(--chip); outline: none; } .menu-item.danger { color: var(--crit); }
#toasts { position: fixed; bottom: 1.25rem; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 0.5rem; z-index: 200; align-items: center; pointer-events: none; }
.toast { background: var(--chip-on); color: var(--chip-on-fg); padding: 0.5625rem 1rem; border-radius: 0.625rem; box-shadow: var(--shadow); font-weight: 500; animation: fade .15s; max-width: min(35rem, 92vw); }
.toast.error { background: var(--crit); color: #fff; } .toast.out { opacity: 0; transition: opacity .35s; }

/* ---------- responsiveness */
@media (max-width: 1100px) { .search input { width: 9.375rem; } .tab span { display: none; } }
@media (max-width: 860px) {
  #app { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: fixed; left: 0; top: 0; z-index: 60; width: min(18.125rem, 86vw); transform: translateX(-102%); transition: transform .18s; box-shadow: var(--shadow); }
  body.side-open .sidebar { transform: none; }
  .menu-btn { display: inline-grid; } .title h1 { max-width: 38vw; }
  .search { display: none; } .topbar { padding: 0 0.75rem; gap: 0.5rem; } .filterbar { padding: 0.5rem 0.75rem; } .page { padding: 1rem 0.875rem 2rem; }
  .props, .grid2, .key-row { grid-template-columns: 1fr; } .edit-row, .edit-row:has(> .color-input + .input) { grid-template-columns: auto 1fr auto; } .edit-row select, .edit-row .muted { grid-column: 2 / -1; }
  .btn.primary span { display: none; } .btn.primary { padding: 0 0.625rem; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- person picker (replaces the native select for assignees) */
button.who { display: inline-flex; align-items: center; gap: 0.375rem; background: none; border: 1px solid transparent; border-radius: 0.375rem; padding: 0.2rem 0.35rem; color: inherit; font: inherit; text-align: left; min-width: 0; cursor: pointer; position: static; }
button.who:not(.named) { padding: 0; border: 0; border-radius: 50%; }
button.who.named { width: 100%; border-color: var(--line); background: var(--surface); }
.grid button.who.named { border-color: transparent; background: transparent; } .grid button.who.named:hover { border-color: var(--line); }
.who-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .who-chev { color: var(--muted); flex: none; }
.who.unassigned .who-name { color: var(--muted); }
.picker { position: fixed; z-index: 130; background: var(--surface); border: 1px solid var(--line); border-radius: 0.625rem; box-shadow: var(--shadow); padding: 0.4rem; display: flex; flex-direction: column; gap: 0.35rem; max-height: min(24rem, 70vh); }
.picker-list { overflow: auto; display: flex; flex-direction: column; }
.picker-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.4rem 0.5rem; border: 0; background: none; border-radius: 0.4rem; text-align: left; color: inherit; font: inherit; cursor: pointer; }
.picker-item.active { background: var(--chip); } .picker-item.current { font-weight: 600; }
.picker-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker-name em { font-style: normal; font-size: 0.7rem; margin-left: 0.4rem; color: var(--accent); background: var(--accent-soft); padding: 0 0.35rem; border-radius: 99px; }
.picker-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 0.4rem 0.5rem 0.15rem; }
.picker-sep { height: 1px; background: var(--line-soft); margin: 0.25rem 0; }

/* ---------- SQL: query box, bar above the table, help */
.filterwrap { flex: none; }
.filters.inactive { opacity: .4; pointer-events: none; }
.sqlbar { display: flex; align-items: flex-start; gap: 0.5rem; flex-wrap: wrap; padding: 0.5rem 1.25rem 0.6rem; background: var(--accent-soft); border-bottom: 1px solid var(--line); }
.sqlbar-label { font-weight: 700; font-size: 0.75rem; letter-spacing: .06em; color: var(--accent); padding-top: 0.55rem; }
.sqlbar .sql-box { flex: 1 1 28rem; min-width: 16rem; }
.sql-box { position: relative; }
.sql-input { width: 100%; resize: none; border: 1px solid var(--line); border-radius: var(--radius); padding: 0.5rem 0.65rem; background: var(--surface); line-height: 1.45; font-size: 0.82rem; overflow: hidden; }
.sql-input:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px var(--accent-soft); }
.sql-box.bad .sql-input { border-color: var(--crit); }
.sql-status { font-size: 0.78rem; margin-top: 0.25rem; display: flex; gap: 0.35rem; align-items: center; min-height: 1.1rem; }
.sql-status.err { color: var(--crit); } .sql-status.ok { color: var(--muted); }
.sql-pop { position: absolute; left: 0; top: 100%; z-index: 80; min-width: 16rem; max-width: 32rem; background: var(--surface); border: 1px solid var(--line); border-radius: 0.5rem; box-shadow: var(--shadow); padding: 0.25rem; max-height: 14rem; overflow: auto; }
.sql-item { display: flex; justify-content: space-between; gap: 1rem; padding: 0.3rem 0.5rem; border-radius: 0.35rem; cursor: pointer; align-items: baseline; }
.sql-item.active { background: var(--chip); } .sql-item small { color: var(--muted); font-size: 0.72rem; text-align: right; }
.sql-help-cols { display: grid; grid-template-columns: 1.2fr 1fr; gap: 1.5rem; }
.sql-help h4 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0.9rem 0 0.4rem; }
.sql-help p { line-height: 1.8; }
.sql-table td { padding: 0.15rem 0.6rem 0.15rem 0; vertical-align: top; font-size: 0.85rem; } .sql-table small { color: var(--muted); }
.sql-examples { display: grid; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); gap: 0.4rem; }
.sql-ex { display: flex; flex-direction: column; align-items: flex-start; gap: 0.15rem; text-align: left; border: 1px solid var(--line); background: var(--surface); border-radius: 0.5rem; padding: 0.45rem 0.65rem; color: inherit; font: inherit; cursor: pointer; }
.sql-ex:hover { border-color: var(--accent); } .sql-ex code { background: none; color: var(--muted); font-size: 0.74rem; padding: 0; white-space: normal; text-align: left; }
@media (max-width: 900px) { .sql-help-cols { grid-template-columns: 1fr; } }

/* ---------- filters page */
.flt-layout { display: grid; grid-template-columns: 19rem minmax(0, 1fr); gap: 1rem; align-items: start; }
.flt-list { padding: 0.75rem; display: flex; flex-direction: column; gap: 0.25rem; }
.flt-row { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; text-align: left; border: 0; background: none; border-radius: 0.5rem; padding: 0.5rem 0.6rem; color: inherit; font: inherit; cursor: pointer; }
.flt-row:hover { background: var(--hover); } .flt-row.active { background: var(--accent-soft); }
.flt-name { display: flex; flex-direction: column; min-width: 0; } .flt-name small { max-width: 11rem; font-family: var(--font-mono); font-size: 0.7rem; }
.flt-meta { display: flex; align-items: center; gap: 0.35rem; flex: none; } .flt-vis { color: var(--muted); display: inline-flex; }
.flt-editor { padding: 1rem; display: flex; flex-direction: column; gap: 0.75rem; min-width: 0; }
.flt-head { display: flex; gap: 0.75rem; align-items: center; flex-wrap: wrap; } .flt-name-in { flex: 1 1 14rem; font-weight: 600; }
.flt-actions { display: flex; gap: 0.4rem; align-items: center; flex-wrap: wrap; }
.dirty { font-size: 0.75rem; color: var(--warn); background: var(--warn-soft); padding: 0.1rem 0.5rem; border-radius: 99px; }
.flt-toolbar { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.flt-count { margin-bottom: 0.4rem; }
.flt-tbl { max-height: 22rem; border: 1px solid var(--line); border-radius: 0.5rem; flex: none; }
.plain-table { width: 100%; border-collapse: collapse; }
.plain-table th { text-align: left; font-size: 0.75rem; color: var(--muted); font-weight: 600; padding: 0.45rem 0.6rem; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--surface-2); }
.plain-table td { padding: 0.4rem 0.6rem; border-bottom: 1px solid var(--line-soft); }
.plain-table tr.clickable { cursor: pointer; } .plain-table tr.clickable:hover td { background: var(--hover); }
.flt-title { max-width: 26rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-pill { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.8rem; color: var(--c); white-space: nowrap; } .st-pill .dot { background: var(--c); }
.who-inline { display: inline-flex; align-items: center; gap: 0.4rem; white-space: nowrap; }
.overdue-text { color: var(--crit); font-weight: 500; }
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 0.4rem 0.75rem; margin: 0.4rem 0; }
.flt-help summary { cursor: pointer; font-weight: 600; padding: 0.4rem 0; }
.wide-btn { width: 100%; } .pad { padding: 0.75rem; }
@media (max-width: 1000px) { .flt-layout { grid-template-columns: 1fr; } }

/* ---------- dashboards */
.dash-head { align-items: flex-end; } .dash-title { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 0.25rem; } .dash-title h1 { margin: 0; }
.dash-sel { font-weight: 600; font-size: 0.95rem; height: 2.1rem; max-width: 20rem; } .dash-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.widgets { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.widget { background: var(--surface); border: 1px solid var(--line); border-radius: 0.75rem; padding: 0.9rem 1rem; min-width: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.span-1 { grid-column: span 1; } .span-2 { grid-column: span 2; } .span-3 { grid-column: span 3; } .span-4 { grid-column: span 4; }
.widget.editing { outline: 2px dashed var(--line); outline-offset: 2px; }
.wd-head { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; } .wd-head h3 { font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.wd-tools { display: flex; gap: 0.1rem; } .rot180 { transform: rotate(180deg); }
.wd-count { display: flex; flex-direction: column; align-items: flex-start; gap: 0.15rem; border: 0; background: none; padding: 0; text-align: left; color: inherit; cursor: pointer; max-width: 100%; }
.wd-count strong { font-size: 2.6rem; line-height: 1; color: var(--c); letter-spacing: -.02em; } .wd-count span { font-size: 0.72rem; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wd-list td { padding: 0.35rem 0.4rem; } .wd-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 0; width: 100%; }
.wd-bars { display: flex; flex-direction: column; gap: 0.35rem; }
.bar-row { display: grid; grid-template-columns: 9rem 1fr 2.2rem; align-items: center; gap: 0.5rem; border: 0; background: none; padding: 0.15rem 0; color: inherit; font: inherit; cursor: pointer; text-align: left; }
.bar-row:hover .bar-label { text-decoration: underline; }
.bar-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 0.85rem; } .bar-track { height: 0.7rem; background: var(--chip); border-radius: 99px; overflow: hidden; } .bar-track i { display: block; height: 100%; border-radius: 99px; }
.bar-row b { text-align: right; font-variant-numeric: tabular-nums; }
.wd-donut { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; } .donut { width: 9rem; height: 9rem; border-radius: 50%; display: grid; place-items: center; flex: none; }
.donut-hole { width: 6rem; height: 6rem; border-radius: 50%; background: var(--surface); display: flex; flex-direction: column; align-items: center; justify-content: center; } .donut-hole strong { font-size: 1.5rem; line-height: 1; } .donut-hole small { color: var(--muted); }
.legend-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.15rem; flex: 1; min-width: 8rem; }
.legend-btn { display: flex; align-items: center; gap: 0.5rem; width: 100%; border: 0; background: none; padding: 0.2rem 0; color: inherit; font: inherit; cursor: pointer; text-align: left; } .legend-btn span { flex: 1; }
.wd-ms { display: flex; flex-direction: column; gap: 0.25rem; }
.wd-ms-row { display: grid; grid-template-columns: auto minmax(8rem, 1.2fr) minmax(8rem, 1fr) 4.5rem; align-items: center; gap: 0.75rem; border: 0; background: none; padding: 0.4rem 0.25rem; border-radius: 0.4rem; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.wd-ms-row:hover { background: var(--hover); } .wd-ms-name { display: flex; flex-direction: column; min-width: 0; }
@media (max-width: 1100px) { .widgets { grid-template-columns: repeat(2, minmax(0, 1fr)); } .span-3, .span-4 { grid-column: span 2; } }
@media (max-width: 640px) { .widgets { grid-template-columns: 1fr; } .widget { grid-column: auto !important; } .bar-row { grid-template-columns: 6rem 1fr 2rem; } }

/* ---------- attachments */
.att { border: 2px dashed transparent; border-radius: 0.6rem; padding: 0.25rem; transition: border-color .12s, background .12s; }
.att.drag { border-color: var(--accent); background: var(--accent-soft); }
.att-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: 0.6rem; }
.att-card { position: relative; margin: 0; border: 1px solid var(--line); border-radius: 0.6rem; overflow: hidden; background: var(--surface-2); display: flex; flex-direction: column; }
.att-card .att-img { border: 0; padding: 0; background: none; display: block; cursor: zoom-in; }
.att-card img, .att-card video { width: 100%; height: 7rem; object-fit: cover; display: block; background: #000; } .att-card video { object-fit: contain; }
.att-card figcaption { padding: 0.35rem 0.5rem; display: flex; flex-direction: column; min-width: 0; } .att-name { font-size: 0.8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att-del { position: absolute; top: 0.25rem; right: 0.25rem; background: rgba(0, 0, 0, .55); color: #fff; } .att-del:hover { background: var(--crit); color: #fff; }
.att-add { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; margin-top: 0.6rem; }
#uploads { position: fixed; right: 1rem; bottom: 1rem; z-index: 300; display: flex; flex-direction: column; gap: 0.4rem; width: min(22rem, 90vw); }
.up-row { display: grid; grid-template-columns: 1fr 5rem 2.4rem; gap: 0.6rem; align-items: center; background: var(--chip-on); color: var(--chip-on-fg); padding: 0.5rem 0.75rem; border-radius: 0.6rem; box-shadow: var(--shadow); font-size: 0.82rem; }
.up-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .up-track { height: 0.4rem; background: rgba(128, 128, 128, .35); border-radius: 99px; overflow: hidden; }
.up-track i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .15s; } .up-pct { text-align: right; font-variant-numeric: tabular-nums; }
.up-row.ok .up-track i { background: #5cc48d; } .up-row.bad { background: var(--crit); color: #fff; }
.lightbox { border: 0; padding: 0; background: transparent; max-width: 96vw; max-height: 94vh; overflow: visible; } .lightbox::backdrop { background: rgba(0, 0, 0, .82); }
.lightbox img { max-width: 94vw; max-height: 86vh; display: block; border-radius: 0.5rem; margin: 0 auto; } .lb-cap { color: #fff; text-align: center; margin-top: 0.5rem; font-size: 0.85rem; } .lb-close { position: absolute; top: -2.2rem; right: 0; color: #fff; }
.pending { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.5rem; }
.pending-file { display: inline-flex; align-items: center; gap: 0.4rem; background: var(--chip); border-radius: 99px; padding: 0.15rem 0.3rem 0.15rem 0.6rem; font-size: 0.8rem; }
.bugit-row { display: flex; gap: 0.5rem; } .bugit-row .input { flex: 1; }

/* ---------- permissions UI in the account dialog */
.perm-list { display: flex; flex-direction: column; gap: 0.45rem; margin-bottom: 0.5rem; }
.perm { display: flex; gap: 0.6rem; align-items: flex-start; cursor: pointer; } .perm input { margin-top: 0.2rem; accent-color: var(--accent); width: 1rem; height: 1rem; flex: none; }
.perm span { display: flex; flex-direction: column; } .perm small { font-size: 0.78rem; }
.access-box .seg { margin-bottom: 0.4rem; } .proj-checks { max-height: 11rem; overflow: auto; }

/* ---------- read-only mode and missing permissions (the server enforces them too) */
body.no-createTasks .quick-row, body.no-createTasks .add-sub, body.no-createTasks .item-add-task, body.no-managePeople .team-add, body.no-manageChecklists .cl-detail .add-input, body.no-edit .dep-add,
body.no-edit .rw, body.no-edit .drawer .dsec-head .btn, body.no-edit .cl-actions .btn:not(:first-child), body.no-edit .grp-assign,
body.no-edit .page-head .btn.primary:not([data-ro-ok]), body.no-edit .ms-tasks .dep-add { display: none !important; }
body.no-edit .circle { pointer-events: none; } body.no-edit .bar { cursor: pointer; }
body.no-createProjects .add-proj { display: none !important; }


.dur { font-variant-numeric: tabular-nums; font-weight: 500; }


/* sign-in screens, sessions */
.link-btn { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; font-size: 0.8125rem; cursor: pointer; text-align: left; }
.link-btn:hover { text-decoration: underline; }
.auth-links { margin: 0.75rem 0 0.25rem; display: flex; justify-content: space-between; gap: 0.75rem; }
.form-ok { color: var(--ok, #1f7a4d); font-size: 0.8125rem; margin: 0.25rem 0 0; }
.auth-card .form-error { margin: 0.625rem 0 0; } .auth-card .wide-btn { margin-top: 0.875rem; }
.sessions { display: flex; flex-direction: column; gap: 0.125rem; }
.session-row { display: flex; justify-content: space-between; align-items: center; gap: 0.625rem; padding: 0.5rem 0; border-bottom: 1px solid var(--line-soft); }
.chip-now { margin-left: 0.5rem; font-size: 0.6875rem; padding: 0.0625rem 0.4375rem; border-radius: 99px; background: var(--accent-soft, rgba(217,86,11,.15)); color: var(--accent); font-weight: 500; }
.sessions .btn { align-self: flex-start; margin-top: 0.5rem; }

.mk-ok { color: var(--muted); } .mk-bad { color: var(--crit); }

/* comments */
.comments { display: flex; flex-direction: column; gap: 0.75rem; }
.comment { display: flex; gap: 0.625rem; align-items: flex-start; }
.comment-main { flex: 1; min-width: 0; }
.comment-head { display: flex; gap: 0.5rem; align-items: baseline; flex-wrap: wrap; }
.comment-actions { margin-left: auto; display: inline-flex; gap: 0.625rem; }
.comment-text { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 0.125rem; font-size: 0.875rem; line-height: 1.45; }
.mention { color: var(--accent); font-weight: 500; }
.comment-compose { display: flex; flex-direction: column; gap: 0.5rem; }
.mention-list { border: 1px solid var(--border, #3a3a3a); border-radius: 0.5rem; background: var(--surface-2, var(--surface, #1f1f1f)); padding: 0.25rem; display: flex; flex-direction: column; }
.mention-list[hidden] { display: none; }
.mention-opt { display: flex; align-items: center; gap: 0.5rem; padding: 0.375rem 0.5rem; border: 0; border-radius: 0.375rem; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.mention-opt .muted { margin-left: auto; }
.mention-none { padding: 0.375rem 0.5rem; }
.mention-opt:hover, .mention-opt.on { background: color-mix(in srgb, var(--accent) 22%, transparent); }
.comment-compose .btn-row { display: flex; gap: 0.5rem; align-items: center; }
/* workload view */
.wl-head { display: flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; margin-bottom: 0.75rem; }
.wl-legend { margin-left: auto; display: inline-flex; gap: 0.375rem; align-items: center; }
.wl-key { display: inline-block; min-width: 1.75rem; text-align: center; border-radius: 0.25rem; padding: 0 0.25rem; font-size: 0.75rem; color: #0e1116; }
.wl-grid { display: grid; grid-template-columns: 12rem repeat(12, minmax(3.5rem, 1fr)); overflow-x: auto; padding: 0.5rem; gap: 0.1875rem; align-items: stretch; }
.wl-corner, .wl-week { font-size: 0.75rem; color: var(--muted); padding: 0.25rem; white-space: nowrap; }
.wl-week.now { color: var(--accent); font-weight: 600; }
.wl-person { display: flex; gap: 0.5rem; align-items: center; background: none; border: 0; color: inherit; font: inherit; text-align: left; padding: 0.25rem; cursor: pointer; border-radius: 0.375rem; }
.wl-person:hover { background: var(--hover, rgba(127,127,127,.12)); }
.wl-person > span:not(.avatar) { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wl-cell { min-height: 2rem; border-radius: 0.375rem; display: grid; place-items: center; font-size: 0.8125rem; font-weight: 500; color: #0e1116; background: var(--line-soft); }
.wl-cell.lvl0 { color: var(--muted); } .wl-cell.off { background: repeating-linear-gradient(45deg, var(--line-soft), var(--line-soft) 4px, transparent 4px, transparent 8px); }
.lvl1 { background: #9fd8b4; } .lvl2 { background: #f1d97a; } .lvl3 { background: #f2a65a; } .lvl4 { background: #e06b6b; }
.wl-cell.lvl0:not(.off) { background: var(--line-soft); }
/* administration cards */
.audit-filter { display: flex; gap: 0.5rem; margin: 0.5rem 0; flex-wrap: wrap; }
.audit-filter .input { flex: 1; min-width: 12rem; }
.audit-table { display: flex; flex-direction: column; max-height: 24rem; overflow: auto; font-size: 0.8125rem; }
.audit-row { display: grid; grid-template-columns: 9.5rem 12rem 1fr; gap: 0.5rem; padding: 0.25rem 0; border-bottom: 1px solid var(--line-soft); align-items: baseline; }
.audit-row.warn strong { color: var(--crit); }
.audit-detail { overflow-wrap: anywhere; }
.storage-list { display: flex; flex-direction: column; gap: 0.375rem; margin-top: 0.5rem; }
.storage-row { display: grid; grid-template-columns: 4rem 1fr 10rem 11rem; gap: 0.5rem; align-items: center; }
/* (own class names: ".bar" / ".bar-fill" belong to the timeline and are absolutely positioned) */
.storage-row .st-track { height: 0.5rem; background: var(--line-soft); border-radius: 99px; overflow: hidden; display: block; }
.storage-row .st-fill { display: block; height: 100%; background: var(--accent); width: 0; }
