/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

:root {
  color-scheme: dark;
  --canvas: #101216;
  --shell: #16191e;
  --surface: #1d2127;
  --raised: #252a31;
  --soft: #191c21;
  --text: #f1f3f5;
  --muted: #9ba2ad;
  --line: #30353e;
  --line-strong: #424954;
  --blue: #6f9cf3;
  --blue-soft: #1c2a44;
  --violet: #a18aef;
  --violet-soft: #2b2444;
  --green: #67c59c;
  --green-soft: #19372d;
  --orange: #f2a05a;
  --red: #ef7474;
  --shadow: 0 22px 55px rgba(0, 0, 0, .38);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.45;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; color: var(--text); background: var(--canvas); }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 8px; font-size: 24px; line-height: 1.2; font-weight: 600; letter-spacing: -.025em; }
h2 { margin-bottom: 10px; font-size: 15px; font-weight: 600; }
strong { font-weight: 600; }
form { margin: 0; }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); }
.text-link { color: var(--muted); text-decoration: none; }
.text-link:hover { color: var(--text); }
.text-button { padding: 0; color: var(--muted); background: transparent; border: 0; cursor: pointer; }
.text-button:hover { color: var(--text); }
.text-button.danger, .danger { color: var(--red); }

.button { display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 7px 12px; color: var(--text); text-decoration: none; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 8px; cursor: pointer; font-weight: 600; }
.button:hover { border-color: #59616e; }
.button:disabled { opacity: .45; cursor: not-allowed; }
.button.primary { color: #17191d; background: var(--text); border-color: var(--text); }
.button.quiet { background: transparent; }
.button.block { width: 100%; }
.icon-button { display: grid; place-items: center; width: 34px; height: 34px; padding: 0; color: var(--muted); background: transparent; border: 1px solid var(--line); border-radius: 7px; cursor: pointer; font-size: 18px; }
.icon-button:hover { color: var(--text); border-color: var(--line-strong); }
.icon-action { display: inline-grid; place-items: center; min-width: 24px; min-height: 24px; padding: 0; color: var(--muted); background: transparent; border: 0; cursor: pointer; }

.brand-lockup { display: flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; }
.brand-lockup > div { display: grid; }
.brand-lockup strong { letter-spacing: -.01em; }
.brand-lockup span:not(.brand-mark) { color: var(--muted); }
.brand-lockup.compact > div { display: flex; gap: 9px; align-items: baseline; white-space: nowrap; }
.brand-mark { display: block; width: 32px; height: 32px; object-fit: cover; background: #000; border: 1px solid var(--line-strong); border-radius: 8px; }
.brand-wordmark { display: block; width: 126px; height: auto; max-height: 40px; object-fit: contain; }

.flash-stack { position: fixed; z-index: 100; top: 14px; left: 50%; display: grid; gap: 8px; width: min(460px, calc(100% - 28px)); transform: translateX(-50%); pointer-events: none; }
.flash { padding: 10px 13px; color: var(--text); background: var(--raised); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow); animation: flash-away .25s ease 4.5s forwards; }
.flash.alert { border-color: rgba(239, 116, 116, .65); }
@keyframes flash-away { to { opacity: 0; transform: translateY(-7px); } }

.auth-shell { display: grid; place-items: center; min-height: 100vh; padding: 24px; background: radial-gradient(circle at 50% 20%, #202631 0, var(--canvas) 48%); }
.auth-card { width: min(420px, 100%); padding: 28px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 13px; box-shadow: var(--shadow); }
.auth-card .brand-lockup { margin-bottom: 42px; }
.auth-copy { margin-bottom: 24px; }
.auth-copy p { color: var(--muted); }

.stack-form { display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field > span, .field legend { color: var(--muted); font-size: 12px; font-weight: 600; }
.field small { color: var(--muted); font-size: 11px; }
.field input, .field textarea, .field select, .filters input, .filters select, .inline-add input, .comment-form textarea, .tag-form input, .tag-form select { width: 100%; min-height: 40px; padding: 8px 10px; color: var(--text); background: var(--soft); border: 1px solid var(--line); border-radius: 8px; outline: none; }
.field textarea, .comment-form textarea { resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus, .filters input:focus, .filters select:focus, .inline-add input:focus, .comment-form textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(111, 156, 243, .13); }
.form-errors { padding: 10px; color: #ffd7d7; background: rgba(206, 69, 69, .13); border: 1px solid rgba(239, 116, 116, .4); border-radius: 8px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-actions { display: flex; align-items: center; gap: 9px; margin-top: 4px; }

.app-window { min-height: 100vh; background: var(--shell); }
.board-chrome { position: sticky; z-index: 20; top: 0; background: rgba(29, 33, 39, .96); backdrop-filter: blur(14px); }
.topbar { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 18px; min-height: 64px; padding: 10px 18px; border-bottom: 1px solid var(--line); }
.view-switch { justify-self: center; display: inline-flex; padding: 3px; background: var(--soft); border: 1px solid var(--line); border-radius: 9px; }
.view-tab { min-width: 92px; padding: 7px 14px; color: var(--muted); text-align: center; text-decoration: none; border-radius: 6px; }
.view-tab.active { color: var(--text); background: var(--raised); box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.top-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.account-menu { position: relative; }
.account-menu summary { display: flex; align-items: center; gap: 8px; list-style: none; cursor: pointer; }
.account-menu summary::-webkit-details-marker { display: none; }
.account-name { max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-popover { position: absolute; z-index: 30; top: 43px; right: 0; display: grid; min-width: 205px; padding: 7px; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 9px; box-shadow: var(--shadow); }
.account-popover a, .account-popover .text-button { display: block; width: 100%; padding: 8px 9px; color: var(--text); text-align: left; text-decoration: none; border-radius: 6px; }
.account-popover a:hover, .account-popover .text-button:hover { background: rgba(255, 255, 255, .05); }

.saved-view-bar { position: relative; display: flex; align-items: center; gap: 9px; min-height: 45px; padding: 6px 18px; overflow: visible; background: #191c21; border-bottom: 1px solid var(--line); }
.saved-view-label { flex: 0 0 auto; color: var(--muted); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; }
.saved-view-links { display: flex; align-items: center; gap: 5px; min-width: 0; overflow-x: auto; scrollbar-width: thin; }
.saved-view-chip { display: inline-flex; align-items: center; flex: 0 0 auto; min-height: 30px; background: var(--soft); border: 1px solid var(--line); border-radius: 7px; }
.saved-view-chip.active { background: var(--raised); border-color: var(--blue); box-shadow: 0 0 0 2px rgba(111, 156, 243, .1); }
.saved-view-chip > a { padding: 5px 4px 5px 9px; text-decoration: none; }
.saved-view-delete { padding: 4px 7px 4px 4px; color: var(--muted); background: transparent; border: 0; cursor: pointer; }
.saved-view-delete:hover { color: var(--red); }
.save-view-menu { position: static; flex: 0 0 auto; }
.save-view-menu > summary { padding: 6px 9px; color: var(--muted); cursor: pointer; list-style: none; border: 1px dashed var(--line-strong); border-radius: 7px; font-size: 11px; }
.save-view-menu > summary::-webkit-details-marker { display: none; }
.save-view-form { position: absolute; z-index: 38; top: calc(100% + 6px); left: 18px; display: grid; grid-template-columns: minmax(180px, 1fr) auto; gap: 7px; width: min(290px, calc(100vw - 36px)); padding: 9px; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 9px; box-shadow: var(--shadow); }
.save-view-form input[type="text"] { width: 100%; min-height: 36px; padding: 7px 9px; color: var(--text); background: var(--soft); border: 1px solid var(--line); border-radius: 7px; outline: none; }
.save-view-form input[type="text"]:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(111, 156, 243, .13); }

.controlbar { display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 9px 18px; background: var(--shell); border-bottom: 1px solid var(--line); }
.filters { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-width: 0; }
.filters input, .filters select { min-height: 36px; padding-block: 6px; }
.filters .search-field input { width: min(230px, 28vw); }
.filters select { width: auto; }
.filter-scope { padding-right: 2px; color: var(--muted); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; }
.filter-menu { position: relative; flex: 0 0 auto; }
.filter-menu > summary { min-height: 36px; padding: 7px 28px 7px 10px; color: var(--text); background: var(--soft); border: 1px solid var(--line); border-radius: 8px; cursor: pointer; list-style: none; white-space: nowrap; }
.filter-menu > summary::-webkit-details-marker { display: none; }
.filter-menu > summary::after { position: absolute; top: 11px; right: 10px; content: "⌄"; color: var(--muted); font-size: 11px; }
.filter-menu[open] > summary { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(111, 156, 243, .13); }
.filter-popover { position: absolute; z-index: 35; top: 42px; left: 0; display: grid; gap: 4px; min-width: 220px; max-height: 320px; padding: 8px; overflow-y: auto; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 9px; box-shadow: var(--shadow); }
.filter-popover > strong { padding: 4px 6px; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.filter-option { display: flex; align-items: center; gap: 8px; min-height: 38px; padding: 5px 6px; border-radius: 6px; cursor: pointer; }
.filter-option:hover { background: rgba(255, 255, 255, .05); }
.filters .filter-option input { width: auto; min-height: 0; margin: 0; accent-color: var(--blue); }
.filter-empty { padding: 8px 6px; color: var(--muted); font-size: 11px; }
.filter-help { max-width: 220px; padding: 3px 6px; color: var(--muted); line-height: 1.35; }
.status-option { display: inline-flex; align-items: center; }
.status-option .status-dot { margin-right: 7px; }

.avatar { display: inline-grid; place-items: center; flex: 0 0 auto; width: 31px; height: 31px; color: var(--identity-ink, #f0f2f5); background: var(--identity-color, #3e4a5b); border: 2px solid var(--shell); border-radius: 50%; font-size: 10px; font-weight: 700; }
.avatar.small { width: 26px; height: 26px; font-size: 9px; }
.avatar.draggable { cursor: grab; }
.avatar-stack { display: flex; align-items: center; }
.avatar-stack .avatar + .avatar { margin-left: -6px; }

.board-main { padding: 16px 18px 22px; }
.board-workspace { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 11px; align-items: start; }
.board-workspace.without-workspace-rail { grid-template-columns: 1fr; }
.workspace-main { grid-column: 1; grid-row: 1; min-width: 0; }
.kanban { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 11px; }
.kanban-column, .person-column { min-width: 0; padding: 10px; background: var(--soft); border-radius: 10px; }
.column-heading { display: flex; align-items: center; justify-content: space-between; min-height: 30px; margin-bottom: 8px; padding: 0 2px; color: var(--muted); }
.column-heading > span:first-child { display: flex; align-items: center; gap: 7px; color: var(--text); font-weight: 600; }
.status-dot, .priority-dot { display: inline-block; width: 8px; height: 8px; margin-right: 7px; background: #7d8591; border-radius: 50%; }
[data-status="in_progress"] > .column-heading .status-dot, .status-dot[data-status="in_progress"], .task-card[data-status="in_progress"] .status-label .status-dot { background: var(--blue); }
[data-status="review"] > .column-heading .status-dot, .status-dot[data-status="review"], .task-card[data-status="review"] .status-label .status-dot { background: var(--violet); }
[data-status="done"] > .column-heading .status-dot, .status-dot[data-status="done"], .task-card[data-status="done"] .status-label .status-dot { background: var(--green); }
.priority-dot[data-priority="high"] { background: var(--orange); }
.priority-dot[data-priority="urgent"] { background: var(--red); }
.task-stack { display: grid; align-content: start; gap: 8px; min-width: 0; min-height: 470px; }
.task-stack.drag-over { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 8px; }
.empty-drop, .empty-state { display: grid; place-items: center; min-height: 90px; padding: 12px; color: var(--muted); text-align: center; border: 1px dashed var(--line-strong); border-radius: 8px; }
.task-stack:has(.task-card) > .empty-drop { display: none; }

.task-card { position: relative; width: 100%; min-width: 0; max-width: 100%; padding: 11px; background: var(--raised); border: 1px solid var(--line); border-left: 3px solid var(--line-strong); border-radius: 8px; box-shadow: 0 1px 2px rgba(0, 0, 0, .18); }
.task-card[draggable="true"] { cursor: grab; }
.task-card.dragging { opacity: .45; }
.task-card[data-priority="normal"] { border-left-color: #536c91; }
.task-card[data-priority="high"] { border-left-color: var(--orange); }
.task-card[data-priority="urgent"] { border-left-color: var(--red); }
.task-card[data-archived="true"] { background: #20242a; border-style: dashed; border-left-color: var(--line-strong); }
.task-card.has-status-band { padding-bottom: 38px; }
.task-card:has(.task-quick-menu[open]) { z-index: 16; }
.task-status-band { position: absolute; z-index: 1; right: 0; bottom: 0; left: 0; display: flex; align-items: center; justify-content: flex-end; height: 28px; padding: 0 10px; color: #d8dee7; background: linear-gradient(90deg, rgba(125, 133, 145, .06), rgba(125, 133, 145, .32)); border-top: 1px solid rgba(125, 133, 145, .3); border-radius: 0 0 7px 7px; text-transform: uppercase; letter-spacing: .12em; font-size: 9px; font-weight: 700; }
.task-card[data-status="in_progress"] .task-status-band { color: #c6d7ff; background: linear-gradient(90deg, rgba(112, 156, 255, .06), rgba(112, 156, 255, .33)); border-top-color: rgba(112, 156, 255, .34); }
.task-card[data-status="review"] .task-status-band { color: #dfd4ff; background: linear-gradient(90deg, rgba(165, 139, 255, .06), rgba(165, 139, 255, .34)); border-top-color: rgba(165, 139, 255, .34); }
.task-card[data-status="done"] .task-status-band { color: #b8ead6; background: linear-gradient(90deg, rgba(105, 203, 159, .06), rgba(105, 203, 159, .32)); border-top-color: rgba(105, 203, 159, .34); }
.task-card-topline { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--muted); }
.task-card-top-actions { display: inline-flex; align-items: center; gap: 7px; }
.collaborator-card-toggle { display: inline-flex; align-items: center; gap: 3px; min-width: 31px; height: 24px; padding: 0 6px; color: var(--muted); background: rgba(255, 255, 255, .025); border: 1px solid var(--line); border-radius: 7px; cursor: pointer; }
.collaborator-card-toggle:hover, .collaborator-card-toggle[aria-expanded="true"] { color: var(--text); background: var(--blue-soft); border-color: rgba(111, 156, 243, .62); }
.collaborator-card-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.collaborator-card-toggle:disabled { opacity: .42; cursor: default; }
.collaborator-icon { width: 15px; height: 13px; overflow: visible; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.45; }
.collaborator-count { min-width: 7px; color: inherit; font-size: 9px; font-weight: 700; line-height: 1; }
.collaborator-global-toggle { gap: 7px; color: var(--muted); font-size: 12px; }
.collaborator-global-toggle[aria-pressed="true"] { color: var(--text); background: var(--blue-soft); border-color: rgba(111, 156, 243, .62); }
.collaborator-global-toggle .collaborator-icon { width: 17px; height: 14px; }
.priority-label { font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.task-quick-menu { position: relative; }
.task-status-band.task-quick-menu { position: absolute; }
.task-quick-menu > summary { list-style: none; cursor: pointer; }
.task-quick-menu > summary::-webkit-details-marker { display: none; }
.task-quick-menu > summary::after { margin-left: 5px; content: "⌄"; color: currentColor; opacity: .68; font-size: 8px; }
.task-quick-menu[open] > summary { color: var(--text); }
.task-quick-options { position: absolute; z-index: 48; display: grid; gap: 3px; min-width: 132px; padding: 6px; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow); text-transform: none; letter-spacing: normal; }
.priority-menu .task-quick-options { top: calc(100% + 6px); left: 0; }
.status-menu .task-quick-options { top: calc(100% + 6px); right: 3px; }
.task-quick-options button { min-height: 31px; padding: 5px 8px; color: var(--text); background: transparent; border: 0; border-radius: 5px; text-align: left; cursor: pointer; }
.task-quick-options button:hover, .task-quick-options button:focus-visible { background: rgba(255, 255, 255, .06); outline: none; }
.task-quick-options button[aria-current="true"] { color: #dce7ff; background: var(--blue-soft); }
.assignee-menu .task-quick-options { top: calc(100% + 6px); right: 0; width: min(205px, calc(100vw - 34px)); max-height: min(390px, calc(100vh - 110px)); overflow-y: auto; }
.kanban-column:first-child .assignee-menu .task-quick-options,
.person-column:first-child .assignee-menu .task-quick-options { right: auto; left: 0; }
.assignee-options-heading { padding: 5px 7px 7px; color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .1em; }
.assignee-option { display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: center; gap: 7px; min-height: 38px; padding: 5px 7px; border-radius: 6px; cursor: pointer; }
.assignee-option:hover, .assignee-option:focus-within { background: rgba(255, 255, 255, .06); }
.assignee-option input { width: 16px; height: 16px; margin: 0; accent-color: var(--blue); }
.assignee-option .avatar { width: 23px; height: 23px; font-size: 8px; }
.assignee-option-copy { display: grid; min-width: 0; }
.assignee-option-copy strong { overflow: hidden; color: var(--text); text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.assignee-option-copy small { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 9px; }
.assignee-card-visibility { display: flex; justify-content: space-between; width: 100%; margin-top: 3px; border-top: 1px solid var(--line) !important; border-radius: 0 0 5px 5px !important; color: var(--muted) !important; }
.assignee-card-visibility[aria-expanded="true"] { color: var(--text) !important; }
.archived-label { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.status-label { display: inline-flex; align-items: center; color: var(--muted); font-size: 11px; }
.status-label .status-dot { margin-right: 5px; }
.task-title { display: block; margin: 7px 0 10px; color: var(--text); overflow-wrap: anywhere; text-decoration: none; font-weight: 600; line-height: 1.35; }
.task-title:hover { text-decoration: underline; text-underline-offset: 3px; }
.tag-row { display: flex; flex-wrap: wrap; gap: 5px; }
.tag { display: inline-flex; padding: 2px 7px; color: #cbd2dc; background: #323842; border-radius: 999px; font-size: 10px; }
.tag[data-color="blue"] { color: #bad0ff; background: var(--blue-soft); }
.tag[data-color="violet"] { color: #d5c8ff; background: var(--violet-soft); }
.tag[data-color="green"] { color: #a9e4ca; background: var(--green-soft); }
.tag[data-color="orange"] { color: #ffd1a9; background: #422d1d; }
.tag[data-color="red"] { color: #ffbebe; background: #452426; }
.card-progress { height: 3px; margin: 10px 0 8px; overflow: hidden; background: #363c45; border-radius: 99px; }
.card-progress span { display: block; height: 100%; background: hsl(var(--progress-hue, 14deg) 68% 54%); transition: width .15s ease, background-color .15s ease; }
.task-card-footer { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; min-height: 27px; }
.card-assignees { display: flex; flex: 1 1 auto; flex-wrap: wrap; gap: 4px; min-width: 0; }
.task-card.collaborators-collapsed .card-assignees { display: none; }
.assignee-name-pill { display: inline-flex; align-items: center; min-height: 22px; padding: 3px 8px; color: var(--identity-ink, #edf1f6); background: var(--identity-color, #3e4a5b); border: 1px solid rgba(255, 255, 255, .1); border-radius: 999px; font-size: 9px; font-weight: 650; line-height: 1.15; white-space: nowrap; }
.card-signals { display: flex; flex: 0 0 auto; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.card-assignees:empty::after { content: "Unassigned"; color: var(--muted); font-size: 11px; }

.people-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 11px; align-items: start; min-width: 0; }
.workspace-rail { position: sticky; top: 182px; display: grid; grid-column: 2; grid-row: 1; grid-template-columns: 25px minmax(0, 1fr); width: 283px; min-width: 245px; max-width: min(42vw, 545px); height: calc(100vh - 200px); min-height: 330px; overflow: hidden; background: #171a1f; border: 1px solid var(--line); border-radius: 11px; transition: width .16s ease, min-width .16s ease; }
.workspace-rail.resizing { user-select: none; transition: none; }
.workspace-rail-content { display: flex; grid-column: 2; grid-row: 1; flex-direction: column; min-width: 0; height: 100%; padding: 6px 6px 6px 0; overflow: hidden; transition: opacity .1s ease; }
.workspace-rail-edge { position: relative; display: flex; grid-column: 1; grid-row: 1; align-items: center; justify-content: center; min-width: 0; background: #15181d; border-right: 1px solid var(--line); cursor: ew-resize; touch-action: none; }
.workspace-rail-actions { display: grid; gap: 5px; }
.workspace-rail-toggle { display: grid; place-items: center; width: 22px; height: 44px; padding: 0; color: var(--muted); background: var(--soft); border: 1px solid var(--line); border-radius: 7px; cursor: pointer; font-size: 18px; line-height: 1; }
.workspace-rail-toggle:hover { color: var(--text); border-color: var(--blue); }
.workspace-rail-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
.workspace-rail-full-toggle, .workspace-rail-collapse-toggle { display: none; }
.workspace-rail.tray-compact { grid-template-columns: 25px minmax(0, 1fr); width: 210px !important; min-width: 210px; max-width: 210px; }
.workspace-rail.tray-compact .workspace-rail-compact-toggle { display: none; }
.workspace-rail.tray-compact .workspace-rail-full-toggle, .workspace-rail.tray-compact .workspace-rail-collapse-toggle { display: grid; width: 22px; height: 36px; }
.workspace-rail.tray-compact .column-hint, .workspace-rail.tray-compact .rail-filters, .workspace-rail.tray-compact .person-tag-list { display: none; }
.workspace-rail.tray-compact .pool-panel { padding: 7px; }
.workspace-rail.tray-compact .pool-panel-content { height: calc(100% - 34px); }
.workspace-rail.tray-compact .person-source { grid-template-columns: minmax(0, 1fr) auto; gap: 6px; min-height: 42px; padding: 6px; }
.workspace-rail.tray-compact .person-source > .avatar { display: none; }
.workspace-rail.tray-compact .person-source-copy > strong { overflow: visible; font-size: 11px; white-space: nowrap; text-overflow: clip; }
.workspace-rail.tray-compact .person-task-count { min-width: 21px; height: 21px; padding-inline: 4px; }
.workspace-rail.tray-compact .task-card { padding: 8px; }
.workspace-rail.tray-compact .task-card.has-status-band { padding-bottom: 30px; }
.workspace-rail.tray-compact .task-title { margin: 6px 0 0; font-size: 11px; }
.workspace-rail.tray-compact .tag-row, .workspace-rail.tray-compact .card-progress, .workspace-rail.tray-compact .task-card-footer { display: none; }
.workspace-rail.tray-compact .task-card.collaborators-expanded .task-card-footer { display: flex; min-height: 0; margin-top: 7px; }
.workspace-rail.tray-compact .task-card.collaborators-expanded .card-signals { display: none; }
.workspace-rail-compact-label { display: none; color: var(--muted); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; writing-mode: vertical-rl; transform: rotate(180deg); }
.workspace-rail.tray-collapsed { grid-template-columns: 40px 0; width: 40px !important; min-width: 40px; max-width: 40px; }
.workspace-rail.tray-collapsed .workspace-rail-content { visibility: hidden; padding: 0; opacity: 0; pointer-events: none; }
.workspace-rail.tray-collapsed .workspace-rail-edge { flex-direction: column; gap: 12px; border-right: 0; cursor: default; }
.workspace-rail.tray-collapsed .workspace-rail-full-toggle, .workspace-rail.tray-collapsed .workspace-rail-collapse-toggle { display: none; }
.workspace-rail.tray-collapsed .workspace-rail-compact-toggle { display: grid; }
.workspace-rail.tray-collapsed .workspace-rail-toggle { width: 28px; height: 34px; }
.workspace-rail.tray-collapsed .workspace-rail-compact-label { display: block; }
.pool-panel { min-width: 0; min-height: 105px; padding: 10px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.workspace-rail.single-panel .pool-panel { flex: 1 1 auto; height: auto; max-height: none; }
.pool-panel.people-pool { flex: 0 0 auto; height: 42%; max-height: calc(100% - 114px); }
.pool-panel.task-pool { flex: 1 1 0; }
.pool-panel-content { height: calc(100% - 36px); overflow-y: auto; scrollbar-gutter: stable; }
.pool-panel-heading { width: 100%; margin-bottom: 6px; color: var(--muted); background: transparent; border: 0; border-radius: 6px; cursor: pointer; font: inherit; text-align: left; }
.pool-panel-heading:hover { background: rgba(255, 255, 255, .035); }
.pool-panel-heading:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
.pool-panel-heading > span:first-child small { margin-left: 5px; color: var(--muted); font-size: 10px; font-weight: 500; }
.pool-collapse { display: grid; place-items: center; width: 24px; height: 24px; padding: 0; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; }
.pool-panel-heading:hover .pool-collapse { color: var(--text); border-color: var(--line-strong); }
.column-hint { margin: -2px 2px 10px; color: var(--muted); font-size: 11px; }
.rail-filters { display: grid; gap: 7px; margin-bottom: 11px; padding-bottom: 11px; border-bottom: 1px solid var(--line); }
.rail-filters .search-field, .rail-filters .search-field input { width: 100%; }
.rail-filter-menus { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.rail-filter-menus .filter-menu { min-width: 0; }
.rail-filter-menus > .filter-menu:only-child { grid-column: 1 / -1; }
.rail-filter-menus .filter-menu > summary { width: 100%; overflow: hidden; text-overflow: ellipsis; }
.rail-filter-menus .filter-menu[open] { grid-column: 1 / -1; }
.rail-filters .filter-popover { position: static; min-width: 0; max-height: 220px; margin-top: 6px; box-shadow: none; }
.rail-filters > .text-link { justify-self: start; font-size: 11px; }
.people-source-list { display: grid; gap: 7px; }
.person-source { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 8px; min-height: 52px; padding: 8px; background: var(--raised); border: 1px solid var(--line); border-radius: 8px; }
.person-source[draggable="true"] { cursor: grab; }
.person-source.dragging { opacity: .45; }
.person-source-copy { display: grid; min-width: 0; gap: 3px; }
.person-source-copy > strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person-name-pill { display: inline-flex; justify-self: start; max-width: 100%; padding: 3px 8px; color: var(--identity-ink, #edf1f6); background: var(--identity-color, #3e4a5b); border: 1px solid rgba(255, 255, 255, .1); border-radius: 999px; }
.person-tag-list { display: flex; gap: 3px; min-width: 0; overflow: hidden; }
.person-tag-list .tag { flex: 0 0 auto; padding-inline: 5px; font-style: normal; }
.person-task-count { display: grid; place-items: center; min-width: 24px; height: 24px; padding: 0 6px; color: var(--muted); text-decoration: none; background: var(--soft); border: 1px solid transparent; border-radius: 99px; font-size: 10px; }
.person-task-count:hover { color: var(--text); border-color: var(--blue); }
.person-task-count.active { color: #dce7ff; background: var(--blue-soft); border-color: var(--blue); box-shadow: 0 0 0 2px rgba(111, 156, 243, .11); }
.pool-stack { min-height: 0; }
.person-stack { position: relative; min-height: 530px; }
.person-heading { display: flex; align-items: center; gap: 8px; min-height: 38px; margin-bottom: 8px; }
.person-heading > .person-workload-count { margin-left: auto; color: var(--muted); font-size: 11px; }
.person-create-task { display: grid; place-items: center; width: 25px; height: 25px; color: var(--muted); text-decoration: none; background: transparent; border: 1px solid var(--line); border-radius: 7px; font-size: 15px; line-height: 1; }
.person-create-task:hover, .person-create-task:focus-visible { color: var(--text); background: var(--blue-soft); border-color: var(--blue); outline: none; }
.empty-drop { gap: 9px; }
.empty-drop .button { min-height: 31px; padding: 5px 9px; }
.person-workload-count { white-space: nowrap; }
.person-column { transition: opacity .12s ease, filter .12s ease; }
.person-column.assignment-reorder-disabled { opacity: .24; filter: saturate(.38); }
.person-column.assignment-reorder-source { outline: 1px solid rgba(111, 156, 243, .42); outline-offset: 2px; box-shadow: inset 0 0 28px rgba(111, 156, 243, .045); }
.person-column.assignment-reorder-source .person-stack::before { position: absolute; z-index: 0; top: 50%; left: 50%; content: "⌃\A⌄"; color: rgba(159, 187, 246, .18); white-space: pre; transform: translate(-50%, -50%); pointer-events: none; font-size: 52px; font-weight: 300; line-height: .78; text-align: center; }
.person-column.assignment-reorder-source .person-stack > * { position: relative; z-index: 1; }
.person-column.already-assigned-target { opacity: .42; filter: saturate(.55); }
.person-column.already-assigned-target .person-heading > strong::after { display: block; content: "Already assigned"; color: var(--orange); font-size: 9px; font-weight: 500; }
.person-column.contains-existing-assignment { outline: 1px solid rgba(249, 164, 84, .42); outline-offset: 2px; }
.person-column.already-assigned-target.contains-existing-assignment .person-heading > strong::after { content: "Already assigned · shown"; }
.task-card.existing-assignment-location { border-color: var(--orange); box-shadow: 0 0 0 2px rgba(249, 164, 84, .22), 0 7px 20px rgba(0, 0, 0, .22); }
.task-card.already-assigned-target { opacity: .42; filter: saturate(.55); }
.task-card.already-assigned-target .task-card-topline::after { content: "Already assigned"; color: var(--orange); font-size: 9px; font-weight: 500; }

turbo-frame#task_drawer { position: relative; z-index: 40; }
body:has(.drawer-layer) { overflow: hidden; }
.drawer-layer { position: fixed; z-index: 40; inset: 0; display: grid; place-items: center; padding: 18px; }
.drawer-scrim { position: absolute; inset: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, .56); border: 0; cursor: default; animation: scrim-in .16s ease; }
.task-drawer { position: relative; width: min(1080px, 100%); max-height: calc(100vh - 36px); padding: 20px 22px; overflow-y: auto; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: 0 22px 60px rgba(0, 0, 0, .5); animation: drawer-in .18s ease; }
.form-drawer { width: min(760px, 100%); }
.task-drawer.attachment-dragging::after { position: absolute; z-index: 20; inset: 14px; display: grid; place-items: center; content: "Drop files to attach"; color: #d8e4ff; background: rgba(24, 31, 43, .92); border: 2px dashed var(--blue); border-radius: 12px; pointer-events: none; font-size: 16px; font-weight: 700; }
.drawer-layer.settled .drawer-scrim, .drawer-layer.settled .task-drawer { animation: none; }
@keyframes scrim-in { from { opacity: 0; } }
@keyframes drawer-in { from { opacity: 0; transform: translateY(12px) scale(.985); } }
.drawer-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; color: var(--muted); }
.archived-notice { display: grid; gap: 2px; margin: -8px 0 18px; padding: 10px 12px; color: var(--muted); background: var(--soft); border: 1px dashed var(--line-strong); border-radius: 8px; font-size: 11px; }
.archived-notice strong { color: var(--text); font-size: 12px; }
.drawer-title-block { display: flex; align-items: start; justify-content: space-between; gap: 15px; }
.drawer-title-block .tag-row { margin-top: 10px; }
.assignee-row { display: grid; gap: 8px; margin: 20px 0; }
.section-label { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.assignee-list { display: flex; flex-wrap: wrap; gap: 6px; }
.assignee-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 7px 3px 3px; background: var(--soft); border-radius: 99px; }
.assignee-chip button { color: var(--muted); background: transparent; border: 0; cursor: pointer; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.detail-box { padding: 10px; background: var(--soft); border-radius: 8px; }
.detail-box > span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.detail-box strong { display: flex; align-items: center; }
.drawer-section { margin-top: 24px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.section-heading h2 { margin: 0; }
.section-heading > span, .section-heading > strong { color: var(--muted); }
.progress-section .section-heading { margin-bottom: 9px; }
.drawer-detail-columns { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.drawer-detail-column { min-width: 0; }
.progress-bar-control { position: relative; display: block; width: 100%; height: 34px; overflow: hidden; background: linear-gradient(to right, hsl(var(--progress-hue, 14deg) 68% 54%) 0 var(--progress-width, 0%), #363c45 var(--progress-width, 0%) 100%); border: 1px solid var(--line-strong); border-radius: 8px; transition: background-color .15s ease; }
.progress-bar-control input { position: absolute; z-index: 2; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; appearance: none; background: transparent; cursor: ew-resize; }
.progress-bar-control input::-webkit-slider-runnable-track { height: 100%; background: transparent; }
.progress-bar-control input::-webkit-slider-thumb { width: 12px; height: 32px; appearance: none; background: rgba(255, 255, 255, .2); border: 1px solid rgba(255, 255, 255, .45); border-radius: 5px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .18); }
.progress-bar-control input::-moz-range-track { height: 100%; background: transparent; }
.progress-bar-control input::-moz-range-thumb { width: 10px; height: 30px; background: rgba(255, 255, 255, .2); border: 1px solid rgba(255, 255, 255, .45); border-radius: 5px; }
.progress-bar-control output { position: absolute; z-index: 3; top: 50%; right: 10px; color: #f4f6f8; pointer-events: none; transform: translateY(-50%); text-shadow: 0 1px 2px rgba(0, 0, 0, .75); font-size: 11px; font-weight: 700; }
.progress-bar-control.readonly { opacity: .9; }
.description { color: #c3c8d0; }
.description p:last-child { margin-bottom: 0; }
.rich-description { display: grid; gap: 6px; }
.rich-description > span { font-size: 11px; font-weight: 700; }
trix-toolbar { position: sticky; z-index: 4; top: -20px; padding: 7px; background: var(--surface); border: 1px solid var(--line-strong); border-bottom: 0; border-radius: 8px 8px 0 0; }
trix-toolbar .trix-button-row { flex-wrap: wrap; }
trix-toolbar .trix-button-group { margin-bottom: 0; border-color: var(--line-strong); }
trix-toolbar .trix-button { color: var(--text); background-color: var(--soft); border-color: var(--line-strong); }
trix-toolbar .trix-button--icon::before { filter: invert(1); opacity: .68; }
trix-toolbar .trix-button--icon.trix-active::before { opacity: 1; }
trix-toolbar .trix-button.trix-active { background-color: var(--blue-soft); }
trix-toolbar .trix-dialog { color: var(--text); background: var(--raised); border-color: var(--line-strong); }
trix-editor { min-height: 170px; padding: 11px; color: var(--text); background: var(--soft); border: 1px solid var(--line-strong); border-radius: 0 0 8px 8px; line-height: 1.5; }
trix-editor:focus { border-color: var(--blue); box-shadow: 0 0 0 2px rgba(105, 152, 247, .13); outline: none; }
trix-editor[aria-busy="true"] { opacity: .7; }
.trix-content { overflow-wrap: anywhere; }
.trix-content .attachment { position: relative; display: inline-flex; width: fit-content; max-width: 100%; margin: 10px 0; flex-direction: column; color: var(--muted); background: var(--soft); border: 1px solid var(--line); border-radius: 9px; }
.trix-content .attachment img { display: block; width: auto; height: auto; max-width: min(100%, 340px); max-height: 240px; object-fit: contain; border-radius: 8px 8px 0 0; cursor: zoom-in; }
.trix-content .attachment__caption { display: flex; gap: 6px; justify-content: center; padding: 6px 9px; font-size: 10px; }
.trix-content .attachment__size { color: var(--muted); }
.rich-description trix-editor .attachment { cursor: grab; }
.rich-description trix-editor .attachment img { cursor: grab; }
.checklist { display: grid; }
.checklist-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 9px; min-height: 39px; border-bottom: 1px solid var(--line); }
.checklist-row:has(.checklist-drag-handle) { grid-template-columns: auto auto 1fr auto; }
.checklist-row.dragging { opacity: .45; }
.checklist-row.complete > span { color: var(--muted); text-decoration: line-through; }
.checklist-drag-handle { width: 20px; height: 28px; padding: 0; color: var(--muted); background: transparent; border: 0; cursor: grab; font-size: 10px; letter-spacing: -2px; }
.checklist-drag-handle:focus-visible { color: var(--text); outline: 2px solid var(--blue); outline-offset: 1px; }
.checklist-heading-actions { display: flex; align-items: center; gap: 9px; color: var(--muted); }
.checklist-preset-menu { position: relative; }
.checklist-preset-menu > summary { min-height: 29px; padding: 5px 8px; color: var(--text); background: var(--soft); border: 1px solid var(--line); border-radius: 7px; list-style: none; cursor: pointer; font-size: 10px; }
.checklist-preset-menu > summary::-webkit-details-marker { display: none; }
.checklist-preset-menu > div { position: absolute; z-index: 48; top: calc(100% + 6px); right: 0; display: grid; gap: 4px; min-width: 230px; max-height: 280px; padding: 7px; overflow-y: auto; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow); }
.preset-choice { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 35px; padding: 6px 8px; color: var(--text); background: transparent; border: 0; border-radius: 6px; text-align: left; cursor: pointer; }
.preset-choice:hover { background: rgba(255, 255, 255, .05); }
.preset-choice small { color: var(--muted); }
.check-button { display: grid; place-items: center; width: 20px; height: 20px; padding: 0; color: #18251f; background: var(--green); border: 1px solid var(--green); border-radius: 4px; cursor: pointer; font-size: 12px; font-weight: 700; }
.check-button:empty { background: transparent; border-color: var(--line-strong); }
.check-button.readonly { cursor: default; }
.inline-add { display: flex; gap: 7px; margin-top: 10px; }
.inline-add input { flex: 1; min-width: 0; }
.link-add { display: grid; grid-template-columns: .65fr 1.2fr auto; }
.attachment-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.attachment { display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; padding: 8px; color: inherit; text-decoration: none; background: var(--soft); border: 0; border-radius: 8px; text-align: left; }
.image-preview-trigger { cursor: zoom-in; }
.readonly-attachment { display: grid; overflow: hidden; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; }
.attachment-download { justify-self: end; margin: 0 7px 6px; }
.attachment img, .file-tile { display: grid; place-items: center; flex: 0 0 auto; width: 55px; height: 42px; object-fit: cover; background: linear-gradient(145deg, var(--blue-soft), var(--violet-soft)); border-radius: 6px; font-size: 9px; }
.attachment > span:last-child { min-width: 0; }
.attachment strong, .attachment small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attachment small { color: var(--muted); font-size: 10px; }
.existing-file-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.existing-file-row { display: grid; min-width: 0; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; }
.existing-file { display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; padding: 8px; color: inherit; text-decoration: none; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; text-align: left; }
.existing-file-row .existing-file { border: 0; border-radius: 7px 7px 0 0; }
.existing-file-actions { display: grid; grid-template-columns: minmax(110px, 1fr) repeat(3, auto); align-items: center; gap: 5px; padding: 6px; border-top: 1px solid var(--line); }
.existing-file-actions input { width: 100%; min-width: 0; height: 29px; padding: 5px 7px; font-size: 10px; }
.existing-file-actions .text-button { padding: 4px; font-size: 10px; }
.existing-file img, .existing-file .file-tile { flex: 0 0 auto; width: 52px; height: 40px; object-fit: cover; border-radius: 6px; }
.existing-file > span:last-child { min-width: 0; }
.existing-file strong, .existing-file small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.existing-file small { color: var(--muted); font-size: 10px; }
.attachment-upload-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.attachment-upload-row input { min-width: 0; }
.attachment-upload-button { min-width: 104px; }
.attachment-manager[aria-busy="true"] .existing-file-grid { opacity: .55; pointer-events: none; }
.attachment-error { color: var(--red) !important; }
.attachment-status.success { color: var(--green); }
.attachment-status.warning { color: var(--orange); }
.attachment-empty { padding: 14px; color: var(--muted); text-align: center; background: var(--soft); border: 1px dashed var(--line-strong); border-radius: 8px; font-size: 11px; }
.image-preview-dialog { width: min(1100px, calc(100vw - 32px)); height: min(820px, calc(100vh - 32px)); padding: 0; color: var(--text); background: transparent; border: 0; }
.image-preview-dialog::backdrop { background: rgba(0, 0, 0, .78); backdrop-filter: blur(3px); }
.image-preview-window { display: grid; grid-template-rows: auto minmax(0, 1fr); width: 100%; height: 100%; overflow: hidden; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: 0 24px 70px rgba(0, 0, 0, .68); }
.image-preview-window header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 13px; border-bottom: 1px solid var(--line); }
.image-preview-window header strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.image-preview-window img { width: 100%; height: 100%; min-height: 0; object-fit: contain; background: #11151b; }
.link-list { display: grid; gap: 6px; }
.link-list > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px; background: var(--soft); border-radius: 7px; }
.link-list a { color: var(--blue); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.comments { display: grid; gap: 8px; }
.comments article { padding: 10px; background: var(--soft); border-radius: 8px; }
.comments header { display: flex; align-items: center; gap: 7px; margin-bottom: 7px; }
.comments time { margin-left: auto; color: var(--muted); font-size: 10px; }
.comments p:last-child { margin-bottom: 0; }
.comment-form { display: grid; justify-items: end; gap: 8px; margin-top: 10px; }
.comment-form textarea { width: 100%; }
.feature-comment-editor { width: 100%; }
.feature-comment-editor trix-editor { min-height: 120px; }
.drawer-danger { display: flex; justify-content: flex-end; gap: 12px; margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); }
.task-history-section { padding-top: 22px; border-top: 1px solid var(--line); }
.task-history { overflow: hidden; background: color-mix(in srgb, var(--soft) 76%, transparent); border: 1px solid var(--line); border-radius: 10px; }
.task-history > summary { display: block; padding: 4px 12px 10px; cursor: pointer; list-style: none; }
.task-history > summary::-webkit-details-marker { display: none; }
.task-history-preview { display: grid; }
.task-history-preview .task-activity:nth-child(3) { max-height: 72px; overflow: hidden; opacity: .45; mask-image: linear-gradient(to bottom, #000 30%, transparent); }
.task-history[open] .task-history-preview { display: none; }
.task-history-toggle { display: block; padding: 9px 2px 0; color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .04em; text-align: center; text-transform: uppercase; }
.task-history-toggle .when-open { display: none; }
.task-history[open] .task-history-toggle .when-closed { display: none; }
.task-history[open] .task-history-toggle .when-open { display: inline; }
.task-history-full { display: grid; padding: 4px 12px 12px; border-top: 1px solid var(--line); }
.task-activity { padding: 12px 2px; border-bottom: 1px solid color-mix(in srgb, var(--line) 72%, transparent); }
.task-activity:last-child { border-bottom: 0; }
.task-activity > header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 9px; align-items: center; }
.task-activity > header > div { display: flex; min-width: 0; flex-wrap: wrap; gap: 4px 7px; align-items: baseline; }
.task-activity > header strong { font-size: 11px; }
.task-activity > header span, .task-activity > header time { color: var(--muted); font-size: 10px; }
.task-activity > header time { white-space: nowrap; }
.task-activity ul { display: grid; gap: 3px; margin: 7px 0 0 34px; padding: 0; color: #cbd0d8; font-size: 10px; line-height: 1.45; list-style: none; }
.task-activity li { overflow-wrap: anywhere; }
.task-activity footer { display: flex; justify-content: flex-end; margin-top: 7px; }
.task-activity footer .text-button { color: #b9c8e8; font-size: 10px; }
.activity-state { color: var(--muted); font-size: 9px; text-transform: uppercase; }
.form-drawer > h1 { margin-bottom: 22px; }
.tag-picker { margin: 0; padding: 0; border: 0; }
.tag-picker > div { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-picker label { cursor: pointer; }
.tag-picker input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.tag-picker input:checked + .tag { box-shadow: 0 0 0 2px var(--text); }
.color-select { position: relative; display: block; }
.color-select-trigger, .color-select-option { display: flex; align-items: center; width: 100%; color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.color-select-trigger { min-height: 40px; gap: 9px; padding: 8px 10px; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; outline: none; }
.color-select-trigger:hover { border-color: var(--line-strong); }
.color-select-trigger:focus-visible, .color-select[data-color] .color-select-trigger[aria-expanded="true"] { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(111, 156, 243, .13); }
.color-select-chevron { margin-left: auto; color: var(--muted); font-size: 11px; }
.color-select-menu { position: absolute; z-index: 45; top: calc(100% + 6px); right: 0; left: 0; display: grid; gap: 3px; padding: 6px; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow); }
.color-select-menu[hidden] { display: none; }
.color-select-option { gap: 9px; min-height: 36px; padding: 6px 8px; background: transparent; border: 0; border-radius: 6px; }
.color-select-option:hover, .color-select-option:focus-visible { background: rgba(255, 255, 255, .06); outline: none; }
.color-select-option[aria-checked="true"] { background: var(--blue-soft); }
.color-choice-check { margin-left: auto; color: var(--blue); opacity: 0; }
.color-select-option[aria-checked="true"] .color-choice-check { opacity: 1; }
.color-swatch { display: block; flex: 0 0 auto; width: 14px; height: 14px; background: #69717d; border: 1px solid rgba(255, 255, 255, .32); border-radius: 3px; }
.color-swatch[data-color="blue"] { background: var(--blue); }
.color-swatch[data-color="violet"] { background: var(--violet); }
.color-swatch[data-color="green"] { background: var(--green); }
.color-swatch[data-color="orange"] { background: var(--orange); }
.color-swatch[data-color="red"] { background: var(--red); }

.task-drag-actions { position: fixed; z-index: 65; bottom: 18px; left: 50%; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: min(520px, calc(100vw - 28px)); padding: 8px; background: rgba(25, 28, 33, .97); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transform: translate(-50%, 18px); transition: opacity .14s ease, transform .14s ease; }
.task-drag-actions.visible { opacity: 1; pointer-events: auto; transform: translate(-50%, 0); }
.task-drag-action { display: grid; grid-template-columns: auto 1fr; column-gap: 9px; align-items: center; min-height: 64px; padding: 9px 12px; color: var(--muted); background: var(--soft); border: 1px dashed var(--line-strong); border-radius: 9px; }
.task-drag-action > span { grid-row: 1 / 3; font-size: 22px; }
.task-drag-action strong { color: var(--text); font-size: 12px; }
.task-drag-action small { font-size: 10px; }
.task-drag-action.drag-over.archive { color: var(--orange); background: rgba(249, 164, 84, .1); border-color: var(--orange); }
.task-drag-action.drag-over.delete { color: var(--red); background: rgba(240, 111, 115, .1); border-color: var(--red); }
.task-drag-action.unavailable { opacity: .35; pointer-events: none; }
.toast { position: fixed; z-index: 80; bottom: 20px; left: 50%; padding: 9px 12px; color: var(--shell); background: var(--text); border-radius: 8px; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transform: translate(-50%, 12px); transition: .15s ease; }
.toast.visible { opacity: 1; transform: translate(-50%, 0); }

.settings-shell { min-height: 100vh; padding: 0 28px 50px; }
.settings-shell.narrow { max-width: 820px; margin: 0 auto; }
.settings-header { display: flex; align-items: center; justify-content: space-between; min-height: 70px; border-bottom: 1px solid var(--line); }
.settings-header nav { display: flex; align-items: center; gap: 16px; }
.settings-header nav a:not(.button) { color: var(--muted); text-decoration: none; }
.settings-title { display: flex; align-items: end; justify-content: space-between; gap: 25px; padding: 38px 0 25px; }
.settings-title > div > span { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.settings-title h1 { margin-top: 6px; font-size: 30px; }
.settings-title p { margin-bottom: 0; color: var(--muted); }
.preference-form { max-width: 680px; }
.preference-group { display: grid; gap: 8px; margin: 0; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 11px; }
.preference-group legend { padding: 0 5px; font-size: 14px; font-weight: 750; }
.preference-group > p { margin: 0 0 6px; color: var(--muted); font-size: 12px; }
.preference-choices { display: grid; gap: 8px; }
.preference-choice { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 11px; padding: 13px; background: var(--soft); border: 1px solid var(--line); border-radius: 9px; cursor: pointer; }
.preference-choice:has(input:checked) { background: var(--blue-soft); border-color: var(--blue); }
.preference-choice input { margin-top: 4px; accent-color: var(--blue); }
.preference-choice span { display: grid; gap: 3px; }
.preference-choice small { color: var(--muted); line-height: 1.45; }
.preference-custom-duration { display: grid; grid-template-columns: minmax(0, 1fr) minmax(130px, .6fr); gap: 10px; }
.preference-custom-duration[hidden] { display: none; }
.preference-help { color: var(--muted); line-height: 1.45; }
.data-list { display: grid; border-top: 1px solid var(--line); }
.data-row { display: grid; grid-template-columns: auto minmax(150px, 1.1fr) .7fr .75fr auto; align-items: center; gap: 14px; min-height: 72px; border-bottom: 1px solid var(--line); }
.data-list-header { display: grid; grid-template-columns: 31px minmax(150px, 1.1fr) .7fr .75fr auto; align-items: center; gap: 14px; min-height: 38px; padding: 0 2px; color: var(--muted); border-bottom: 1px solid var(--line-strong); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.data-list-header > :last-child { justify-self: end; }
.sort-heading { display: inline-flex; align-items: center; gap: 5px; color: var(--muted); text-decoration: none; }
.sort-heading:hover, .sort-heading.active { color: var(--text); }
.sort-heading span { color: var(--blue); font-size: 11px; }
.data-row.inactive { opacity: .55; }
.data-row > div:nth-child(2) { display: grid; }
.data-row > div:nth-child(2) span, .state { color: var(--muted); font-size: 11px; }
.settings-title-actions { display: flex; align-items: center; gap: 7px; }
.template-name { color: #c9ced6; }
.row-actions { display: flex; align-items: center; justify-content: flex-end; gap: 13px; }
.settings-form { padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.credential-card { margin-top: 70px; padding: 26px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: var(--shadow); }
.credential-card > span { color: var(--orange); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.credential-card h1 { margin-top: 8px; }
.credential-card p { color: var(--muted); }
.credential-card dl { display: grid; gap: 8px; margin: 24px 0; }
.credential-card dl > div { padding: 11px; background: var(--soft); border-radius: 8px; }
.credential-card dt { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.credential-card dd { margin: 4px 0 0; font-size: 17px; }
.template-layout, .tag-settings { display: grid; grid-template-columns: 1.5fr minmax(290px, .7fr); gap: 25px; align-items: start; }
.template-list { display: grid; }
.template-list article { display: grid; grid-template-columns: minmax(120px, .5fr) 1fr auto; align-items: center; gap: 16px; padding: 15px 0; border-bottom: 1px solid var(--line); }
.template-list article > div:first-child { display: grid; }
.template-list article > div:first-child span { color: var(--muted); font-size: 11px; }
.capability-summary { display: flex; flex-wrap: wrap; gap: 4px; }
.capability-summary span { padding: 2px 6px; color: var(--muted); background: var(--soft); border-radius: 99px; font-size: 10px; }
.template-layout aside, .tag-settings aside { padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.capability-grid { display: grid; gap: 6px; }
.check-field { display: flex; align-items: start; gap: 10px; padding: 8px; background: var(--soft); border-radius: 7px; cursor: pointer; }
.check-field input { margin-top: 3px; accent-color: var(--blue); }
.check-field span { display: grid; }
.check-field small { color: var(--muted); }
.tag-form { display: grid; gap: 12px; }
.people-picker { margin: 0; padding: 0; border: 0; }
.people-picker > div { display: grid; grid-template-columns: 1fr; gap: 6px; max-height: 250px; overflow-y: auto; }
.people-picker .check-field { align-items: center; min-height: 42px; border: 1px solid transparent; transition: background-color .12s ease, border-color .12s ease; }
.people-picker .check-field:hover { border-color: var(--line-strong); }
.people-picker .check-field:has(input:checked) { background: var(--blue-soft); border-color: rgba(111, 156, 243, .42); }
.people-picker .check-field input[type="checkbox"] { flex: 0 0 17px; width: 17px; height: 17px; min-height: 17px; margin: 0; padding: 0; accent-color: var(--blue); }
.user-color-field { display: grid; gap: 9px; }
.user-color-preview { display: flex; align-items: center; gap: 10px; min-height: 46px; padding: 9px; background: var(--soft); border: 1px solid var(--line); border-radius: 9px; }
.user-color-controls { display: grid; grid-template-columns: minmax(155px, .65fr) minmax(190px, 1fr); gap: 10px; }
.user-color-controls label { display: grid; gap: 6px; color: var(--muted); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.user-color-picker input[type="color"] { width: 100%; height: 46px; min-height: 46px; padding: 4px; cursor: pointer; }
.user-color-picker input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.user-color-picker input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 5px; }
.user-color-picker input[type="color"]::-moz-color-swatch { border: 0; border-radius: 5px; }
.user-color-hex input[aria-invalid="true"] { border-color: var(--red); box-shadow: 0 0 0 3px rgba(231, 111, 117, .13); }
.tag-list { display: grid; }
.tag-list article { display: grid; grid-template-columns: 1fr .5fr auto; align-items: center; gap: 15px; min-height: 58px; border-bottom: 1px solid var(--line); }
.tag-list article > span:nth-child(2) { color: var(--muted); }
.tag-list article > div { display: flex; gap: 12px; }
.preset-settings { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(290px, .7fr); gap: 28px; }
.preset-settings > aside { padding: 18px; background: var(--soft); border-radius: 10px; }
.preset-settings > aside h2 { margin-top: 0; }
.preset-list { display: grid; align-content: start; gap: 9px; }
.preset-list article { display: grid; grid-template-columns: minmax(150px, .65fr) minmax(220px, 1fr) auto; align-items: start; gap: 18px; padding: 14px; background: var(--soft); border: 1px solid var(--line); border-radius: 9px; }
.preset-list article > div:first-child { display: grid; gap: 4px; }
.preset-list article > div:first-child span, .preset-list ol { color: var(--muted); font-size: 11px; }
.preset-list ol { margin: 0; padding-left: 18px; }
.preset-list article > div:last-child { display: flex; gap: 10px; }
.preset-form textarea { width: 100%; resize: vertical; }
.feature-requests-shell { max-width: 1380px; margin: 0 auto; }
.feature-request-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(290px, 360px); gap: 28px; align-items: start; }
.feature-request-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-bottom: 14px; }
.feature-filter-separator { width: 1px; height: 25px; margin-inline: 3px; background: var(--line); }
.feature-status-filter { position: relative; margin-left: auto; }
.feature-status-filter > summary { min-height: 36px; padding: 8px 10px; color: var(--text); background: var(--soft); border: 1px solid var(--line); border-radius: 8px; list-style: none; cursor: pointer; font-size: 11px; }
.feature-status-filter > div { position: absolute; z-index: 30; top: calc(100% + 6px); right: 0; display: grid; min-width: 170px; padding: 6px; background: var(--raised); border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: var(--shadow); }
.feature-status-filter a { padding: 7px 8px; color: var(--text); text-decoration: none; border-radius: 5px; }
.feature-status-filter a:hover { background: rgba(255, 255, 255, .05); }
.feature-request-list { display: grid; gap: 9px; }
.feature-request-card { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 16px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.feature-request-card.archived { opacity: .72; border-style: dashed; }
.feature-request-card-copy { min-width: 0; }
.feature-request-card h2 { margin: 7px 0; font-size: 17px; }
.feature-request-card h2 a { color: var(--text); text-decoration: none; }
.feature-request-card h2 a:hover { text-decoration: underline; text-underline-offset: 3px; }
.feature-request-card p { margin: 0 0 8px; color: var(--muted); line-height: 1.5; }
.feature-request-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.request-status { display: inline-flex; padding: 3px 7px; color: #cbd2dc; background: #323842; border-radius: 999px; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.request-status[data-status="planned"] { color: #bad0ff; background: var(--blue-soft); }
.request-status[data-status="implemented"] { color: #a9e4ca; background: var(--green-soft); }
.request-status[data-status="declined"], .request-status.archived { color: #c1c5cb; background: #2b2f35; }
.feature-vote { display: grid; align-content: start; justify-items: center; gap: 2px; color: var(--muted); text-align: center; }
.feature-vote > strong { color: var(--text); font-size: 24px; line-height: 1; }
.feature-vote > span { margin-bottom: 7px; font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.feature-vote-button { min-height: 31px; padding: 5px 8px; font-size: 10px; }
.feature-vote-button.active { color: #dce7ff; background: var(--blue-soft); border-color: var(--blue); }
.feature-request-new { position: sticky; top: 86px; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; }
.feature-request-new h2 { margin-top: 0; }
.feature-request-new > p { color: var(--muted); font-size: 11px; line-height: 1.5; }
.feature-request-editor trix-editor { min-height: 210px; }
.narrow-request { max-width: 960px; }
.feature-request-detail { padding: 34px 0 70px; }
.feature-request-detail > header { display: flex; align-items: start; justify-content: space-between; gap: 25px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.feature-request-detail h1 { margin: 10px 0; font-size: clamp(26px, 4vw, 40px); }
.feature-request-author { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.feature-request-heading-actions { display: flex; align-items: start; gap: 10px; }
.feature-request-body { min-height: 120px; padding: 26px 0; color: #cbd0d8; font-size: 15px; line-height: 1.65; }
.feature-request-body > :first-child, .comments .trix-content > :first-child { margin-top: 0; }
.feature-request-body > :last-child, .comments .trix-content > :last-child { margin-bottom: 0; }
.feature-admin-controls { display: flex; align-items: center; gap: 12px; margin: 4px 0 28px; padding: 12px; background: var(--soft); border: 1px solid var(--line); border-radius: 9px; }
.feature-admin-controls > strong { margin-right: auto; }
.feature-admin-controls form { display: flex; align-items: center; gap: 7px; }
.feature-admin-controls select { min-height: 36px; }
.feature-comments { padding-top: 20px; border-top: 1px solid var(--line); }

@media (max-width: 1100px) {
  .kanban { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .board-workspace { grid-template-columns: minmax(0, 1fr) auto; }
  .people-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workspace-rail { top: 232px; width: 255px; min-width: 225px; height: calc(100vh - 250px); }
  .topbar { grid-template-columns: 1fr auto; }
  .view-switch { grid-column: 1 / -1; grid-row: 2; width: 100%; }
  .view-tab { flex: 1; }
  .data-row { grid-template-columns: auto 1fr .6fr auto; }
  .data-list-header { grid-template-columns: 31px 1fr .6fr auto; }
  .data-list-header > :nth-child(4) { display: none; }
  .data-row .state { display: none; }
  .drawer-detail-columns { grid-template-columns: 1fr; gap: 0; }
}

@media (max-width: 700px) {
  .topbar, .controlbar, .board-main { padding-left: 10px; padding-right: 10px; }
  .saved-view-bar { padding-inline: 10px; }
  .save-view-form { left: 10px; width: calc(100% - 20px); }
  .topbar .brand-lockup.compact span:last-child, .account-name { display: none; }
  .collaborator-global-toggle { width: 36px; padding-inline: 0; }
  .collaborator-global-toggle [data-collaborator-toggle-label] { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
  .controlbar { align-items: flex-start; }
  .filters { flex-wrap: wrap; }
  .filters .search-field { width: 100%; }
  .filters .search-field input { width: 100%; }
  .kanban, .board-workspace, .people-columns, .pool-stack { grid-template-columns: 1fr; }
  .workspace-main { grid-column: 1; grid-row: 2; }
  .board-workspace.without-workspace-rail .workspace-main { grid-row: 1; }
  .workspace-rail { position: static; grid-column: 1; grid-row: 1; grid-template-columns: 38px minmax(0, 1fr); width: auto !important; min-width: 0; max-width: none; height: auto; min-height: 0; }
  .workspace-rail-content { padding: 6px 6px 6px 0; }
  .workspace-rail.tray-compact { position: static; display: grid; grid-template-columns: 38px minmax(0, 1fr); width: auto !important; min-width: 0; max-width: none; height: 210px; min-height: 210px; transform: none; }
  .workspace-rail.tray-compact .workspace-rail-full-toggle, .workspace-rail.tray-compact .workspace-rail-collapse-toggle { width: 30px; height: 34px; }
  .workspace-rail.tray-collapsed { position: fixed; z-index: 32; top: 50%; right: 0; left: auto; display: grid; grid-template-columns: 30px; width: 30px !important; min-width: 30px; max-width: 30px; height: 132px; min-height: 132px; border-right: 0; border-radius: 9px 0 0 9px; transform: translateY(-50%); }
  .workspace-rail.tray-collapsed .workspace-rail-content { display: none; }
  .workspace-rail.tray-collapsed .workspace-rail-edge { flex-direction: column; justify-content: center; width: 30px; height: 132px; padding: 3px; }
  .workspace-rail.tray-collapsed .workspace-rail-compact-label { font-size: 7px; }
  .workspace-rail.tray-collapsed .workspace-rail-toggle { width: 24px; height: 30px; }
  .pool-panel, .pool-panel.people-pool, .pool-panel.task-pool { height: min(58vh, 560px); max-height: none; resize: none; }
  .task-stack { min-height: 120px; }
  .settings-shell { padding-inline: 14px; }
  .settings-header { align-items: flex-start; gap: 14px; padding: 14px 0; }
  .settings-header nav { flex-wrap: wrap; justify-content: flex-end; gap: 9px; }
  .settings-title { align-items: flex-start; flex-direction: column; }
  .settings-title-actions { width: 100%; justify-content: space-between; }
  .template-layout, .tag-settings, .preset-settings, .feature-request-layout { grid-template-columns: 1fr; }
  .feature-request-new { position: static; grid-row: 1; }
  .preset-list article { grid-template-columns: 1fr auto; }
  .preset-list article ol { grid-column: 1 / -1; grid-row: 2; }
  .existing-file-grid, .people-picker > div { grid-template-columns: 1fr; }
  .data-row { grid-template-columns: auto 1fr auto; padding: 11px 0; }
  .data-list-header { grid-template-columns: 31px 1fr auto; }
  .data-list-header > :nth-child(3) { display: none; }
  .data-row .template-name { display: none; }
  .row-actions { align-items: flex-end; flex-direction: column; gap: 6px; }
  .drawer-layer { padding: 0; }
  .task-drawer { width: 100%; max-height: 100vh; min-height: 100vh; border: 0; border-radius: 0; }
}

@media (max-width: 480px) {
  .top-actions .button { padding-inline: 9px; }
  .controlbar { display: grid; }
  .detail-grid, .form-grid, .attachment-grid { grid-template-columns: 1fr; }
  .link-add { grid-template-columns: 1fr; }
  .task-drawer { width: 100%; }
  .auth-shell { padding: 12px; }
  .auth-card { padding: 22px; }
  .template-list article { grid-template-columns: 1fr auto; }
  .capability-summary { grid-column: 1 / -1; }
  .user-color-controls { grid-template-columns: 1fr; }
  .feature-request-card { grid-template-columns: 1fr; }
  .feature-vote { grid-template-columns: auto auto 1fr; align-items: center; justify-items: start; }
  .feature-vote > span { margin: 0; }
  .feature-vote form { justify-self: end; }
  .feature-request-detail > header { flex-direction: column; }
  .feature-admin-controls, .feature-admin-controls form { align-items: stretch; flex-direction: column; }
}
