:root {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: #292929;
  background: #fff;
  font-synthesis: none;
  --accent: #536df1;
  --accent-soft: #edf2ff;
  --line: #f0f0f0;
  --muted: #a0a0a0;
  --rail-width: 50px;
  --nav-width: 240px;
  --detail-width: 35vw;
}
* { box-sizing: border-box; }
body { margin: 0; font-size: 14px; line-height: 1.5; overflow: hidden; }
.startup-state{position:fixed;inset:0;z-index:20000;background:#fff;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:12px;color:#999;font-size:13px}
.startup-state[hidden]{display:none}.startup-state p{margin:0}.startup-mark{display:block;width:38px;height:38px;object-fit:contain}
button, input, textarea, select { font: inherit; color: inherit; }
button { border: 0; background: none; cursor: pointer; padding: 0; }
button:disabled { opacity: .45; cursor: wait; }
input, textarea, select { min-width: 0; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, a:focus-visible { outline: 2px solid #8ca9f2; outline-offset: 2px; }
textarea { resize: vertical; }
a { color: var(--accent); text-decoration: none; }
[hidden] { display: none !important; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; pointer-events: none; }
svg.tiny { width: 14px; height: 14px; }
.icon-definitions { width: 0; height: 0; position: absolute; overflow: hidden; }
.workspace { --nav-width:var(--user-nav-width,240px); display: grid; grid-template-columns: var(--rail-width) var(--nav-width) minmax(320px, 1fr) minmax(340px, var(--detail-width)); grid-template-rows:minmax(0,1fr); height: 100dvh; }
.workspace.sidebar-collapsed { --nav-width: 0px; }
.workspace.sidebar-collapsed .list-sidebar { visibility: hidden; overflow: hidden; }
.workspace.module-wide { grid-template-columns: var(--rail-width) var(--nav-width) minmax(320px, 1fr); }
.workspace.module-wide .detail-pane { display: none; }
.tool-rail { background: #f5f5f5; border-right: 1px solid #e9e9e9; display: flex; flex-direction: column; align-items: center; padding: 14px 0; gap: 20px; overflow: auto; }
.profile-button { width: 32px; height: 32px; border-radius: 10px; background: #dce6ff; color: var(--accent); display: grid; place-items: center; font-size: 23px; font-weight: 600; }
.module-nav, .rail-bottom { display: grid; justify-items: center; gap: 13px; width: 100%; }
.rail-bottom { margin-top: auto; gap: 10px; padding-top: 26px; }
.rail-button { color: #939393; width: 34px; height: 36px; display: grid; place-items: center; border-radius: 6px; }
.rail-button svg { width: 21px; height: 21px; stroke-width: 1.9; }
.rail-button:hover { color: #555; background: #e9e9e9; }
.rail-button.active { color: var(--accent); }
.rail-button.active svg { fill: #edf2ff; stroke-width: 2.2; }
.rail-button { position:relative; }
.notification-badge { position:absolute; top:0; right:0; min-width:12px; height:12px; line-height:12px; border-radius:7px; color:white; background:var(--accent); font-size:8px; padding:0 2px; }
.notification-dialog { width:520px; }
.notification-permission { display:flex; align-items:center; gap:12px; border-bottom:1px solid var(--line); padding-bottom:12px; font-size:12px; color:#999; }
.notification-permission p { margin:0; flex:1; }
.notification-dialog .text-button { color:var(--accent); font-size:12px; }
.notification-permission .text-button { white-space:nowrap; }
.notification-tools { display:flex; justify-content:space-between; padding:10px 0; }
.notification-empty { text-align:center; color:#aaa; padding:40px 20px; }
.notification-entry { border-bottom:1px solid var(--line); padding:14px 10px; border-radius:5px; }
.notification-entry.unread { background:#f7f8ff; }
.notification-title { font-size:14px; display:block; text-align:left; margin:0 0 5px; }
.notification-entry small { color:#aaa; font-size:11px; }
.notification-actions { display:flex; flex-wrap:wrap; gap:12px; margin-top:10px; }
.notification-completed { color:#999; font-size:12px; }
.notification-persistent { border:0; border-bottom:1px solid var(--line); padding:14px 0; margin:0; display:flex; flex-wrap:wrap; gap:10px 18px; color:#888; font-size:12px; }
.notification-persistent legend { padding:12px 0 0; color:var(--text); }
.notification-persistent p { flex-basis:100%; margin:0 0 3px; font-size:11px; line-height:1.7; color:#aaa; }
.notification-persistent label { display:flex; align-items:center; gap:6px; }.notification-persistent input { accent-color:var(--accent); }
.notification-warning { color:#a58240; font-size:12px; line-height:1.7; }
.notification-live { position:fixed; inset:auto 18px 18px auto; z-index:2000; width:min(340px,calc(100vw - 36px)); max-height:70dvh; overflow:auto; padding:0; margin:0; border:0; border-radius:9px; background:transparent; color:var(--text,#444); }
.notification-live::backdrop { background:transparent; pointer-events:none; }
.notification-live-entry { margin:10px 1px 1px; padding:14px 16px; background:var(--paper,#fff); border:1px solid var(--line,#eee); border-radius:8px; box-shadow:0 4px 16px #0002; }
.notification-live-entry strong { display:block; margin:5px 0; font-size:14px; font-weight:500; overflow-wrap:anywhere; }
.notification-live-entry small { font-size:11px; color:#aaa; }.notification-live-entry .text-button { font-size:12px; color:var(--accent); }
.repeat-issue { color:#a36c27; background:#fff8e9; border:1px solid #efdcba; border-radius:6px; padding:10px; line-height:1.7; }
.repeat-issue p { margin:0 0 5px; }
.repeat-issue .text-button { color:var(--accent); font-size:12px; }
.list-sidebar { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-width: 0; overflow: hidden; background: #fff; position:relative; }
.smart-views { padding: 13px 11px 15px; flex-shrink:0; position:relative; z-index:1; border-bottom:1px solid var(--border,#e7e9ef); }
.list-sidebar.lists-scrolled .smart-views { box-shadow:0 3px 6px -4px #0004; }
.nav-item { width: 100%; min-height: 36px; display: flex; gap: 9px; align-items: center; padding: 7px 12px; border-radius: 8px; text-align: left; margin-bottom: 2px; position: relative; }
.nav-item > svg { width: 18px; height: 18px; color: #333; }
.nav-item > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-item > small { font-size: 12px; color: #a5a5a5; margin-left: auto; min-width: 14px; text-align: right; font-variant-numeric: tabular-nums; }
.nav-item:hover { background: #f6f6f6; }
.nav-item.active { background: #f0f0f0; }
.nav-item.active > span { font-weight: 500; }
.sidebar-scroll { overflow: auto; flex: 1; min-height:0; padding: 0 10px 20px; }
.sidebar-scroll > .sidebar-section:first-child { border-top:0; }
.sidebar-section { border-top: 1px solid #f1f1f1; padding: 15px 0 12px; }
.section-heading { display: flex; align-items: center; justify-content: space-between; color: #aaa; font-size: 12px; min-height: 27px; padding: 0 12px 7px; }
.section-heading .icon-button { opacity: 0; width: 24px; height: 24px; }
.sidebar-section:hover .section-heading .icon-button, .section-heading .icon-button:focus-visible { opacity: 1; }
.project-item { position: relative; padding-right: 34px; }
.project-item .project-color { position: absolute; right: 16px; width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.project-item .project-actions { position: absolute; top: 6px; right: 8px; width: 24px; height: 24px; display: inline-grid; place-items: center; opacity: 0; color: #999; font-size: 18px; }
.project-item:hover .project-actions, .project-item:focus-within .project-actions { opacity: 1; }
.project-item:hover .project-color, .project-item:focus-within .project-color { visibility: hidden; }
.project-item.drag-over, .nav-item.drag-over { background: #eaf0ff; outline: 1px dashed #86a7f2; }
.sidebar-placeholder { font-size: 12px; line-height: 1.5; color: #b3b3b3; background: #f8f8f8; border-radius: 4px; padding: 7px 9px; margin: 0 9px 3px; }
.archive-toggle { font-size: 13px; color: #666; }
.archive-toggle .tiny { margin-left: auto; color: #999; }
.tag-item > svg { color: #aaa; }
.tag-item > svg { color:var(--tag-color,#aaa); }
.sidebar-folder .folder-item { color:inherit; }
.folder-item > svg { color:inherit; }
.folder-toggle { width:12px; text-align:center; font-size:17px; position:absolute; left:0; color:#999; }
.folder-children { padding-left:16px; }
.folder-empty { color:#bbb; font-size:11px; padding:0 14px; margin:4px 0 10px; }
.drag-handle { position:absolute; left:-14px; top:50%; transform:translateY(-50%); width:15px; height:23px; line-height:23px; text-align:center; color:#aaa; cursor:grab; opacity:0; font-size:18px; touch-action:none; user-select:none; z-index:2; }
.nav-item > .drag-handle { left:-1px; width:12px; overflow:visible; }
.folder-item > .drag-handle { left:-9px; }
.task-row:hover > .drag-handle,.nav-item:hover > .drag-handle,.subtask-edit-row:hover > .drag-handle,.board-card:hover > .drag-handle,.group-heading:hover > .drag-handle,.drag-handle:focus-visible { opacity:1; }
.is-dragging,.is-dragging * { cursor:grabbing!important; user-select:none!important; }
.drag-ghost { position:fixed; top:0; left:0; z-index:5000; pointer-events:none; max-width:340px; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; padding:10px 16px; background:#fff; box-shadow:0 5px 24px #0003; border:1px solid #dce1f9; border-radius:6px; font-size:13px; }
.drag-over { background:#eef1ff!important; outline:1px solid #b4bff4; }
.task-row.drag-over,.subtask-edit-row.drag-over { box-shadow:0 -2px 0 var(--accent); outline:none; }
.task-row.drop-after,.subtask-edit-row.drop-after { box-shadow:0 2px 0 var(--accent); }
.subtask-edit-row,.group-heading,.board-card { position:relative; }
.group-more { margin-left:auto; opacity:0; }
.group-heading:hover .group-more { opacity:1; }
.board-column h2 { display:flex; align-items:center; justify-content:space-between; }
.board-add { display:block; padding:8px 4px; color:#aaa; font-size:13px; }
.board-add-section { min-width:220px; color:#999; align-self:start; padding:12px; text-align:left; }
.deleted-project { display:flex; align-items:center; gap:10px; border-bottom:1px solid var(--line); padding:12px 8px; }
.deleted-project .text-button { margin-left:auto; color:var(--accent); }
.sidebar-resize { position:absolute; top:0; bottom:0; right:0; width:5px; cursor:col-resize; z-index:8; }
.sidebar-resize:hover,.sidebar-resize:focus-visible { background:#dbe0ff; }
.status-views { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 5px; }
.sidebar-footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-height: 33px; background: #fafafa; border-top: 1px solid var(--line); font-size: 10px; color: #aaa; padding: 9px 12px; text-align: left; }
.sidebar-footer small { font-size: 9px; white-space: nowrap; }
.brand-caption { display:flex; align-items:center; min-width:0; overflow:hidden; }
.brand-caption img { flex:none; height:30px; width:auto; }
.brand-lockup-light { display:block; }
.brand-lockup-dark { display:none; }
html[data-theme=dark] .brand-lockup-light { display:none; }
html[data-theme=dark] .brand-lockup-dark { display:block; }
.about-brand { margin:0 0 18px; }
.about-brand img { height:64px; width:auto; }
.task-pane { display: flex; flex-direction: column; min-width: 0; overflow: hidden; background: #fff; }
.pane-header { height: 58px; flex-shrink: 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 17px; }
.pane-title, .pane-actions { display: flex; align-items: center; gap: 7px; min-width: 0; }
h1 { font-size: 20px; font-weight: 650; line-height: 1.4; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pane-title .icon-button { width: 25px; margin-left: -1px; }
.pane-title .icon-button svg { width: 18px; }
.pane-actions { gap: 4px; }
.icon-button { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 5px; color: #999; flex-shrink: 0; }
.icon-button svg { width: 18px; height: 18px; }
.icon-button:hover { background: #f2f2f2; color: #444; }
.icon-button.active { color: var(--accent); background: var(--accent-soft); }
.task-workspace { display: flex; flex-direction: column; min-height: 0; flex: 1; }
.quick-add { margin: 5px 18px 16px; display: flex; align-items: center; gap: 6px; min-height: 39px; border: 1px solid transparent; border-radius: 7px; padding: 0 9px; background: #f8f8f8; flex-shrink: 0; }
.quick-add > svg { width: 17px; height: 17px; color: #c3c3c3; }
.quick-add input { flex: 1; width: 100%; border: 0; outline: 0; padding: 8px 0; font-size: 13px; background: none; line-height: 1.5; }
.quick-add input::placeholder { color: #b9b9b9; }
.quick-add:focus-within { background: #fff; border-color: #b7c9f7; box-shadow: 0 0 0 2px #edf2ff; }
.quick-tool, .quick-submit { opacity: 0; }
.quick-add:focus-within .quick-tool, .quick-add:hover .quick-tool, .quick-tool.is-set, .quick-add:focus-within .quick-submit { opacity: 1; }
.quick-submit { color: var(--accent); font-size: 12px; padding: 5px 8px; white-space: nowrap; }
.quick-hints { margin: -9px 23px 13px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 11px; color: var(--accent); }
.quick-recovery { margin:-7px 18px 14px; border:1px solid #ead7a8; background:#fff9e9; padding:9px 12px; border-radius:5px; font-size:12px; color:#856526; display:flex; gap:12px; align-items:center; }
.quick-recovery .text-button { color:var(--accent); white-space:nowrap; margin-left:auto; }
.quick-recovery.is-saving { border-color:transparent; background:transparent; color:var(--muted); padding:0 5px; }
.hint-chip { padding: 2px 6px; border-radius: 4px; background: #f0f4ff; }
.inline-search { display: flex; gap: 8px; align-items: center; margin: 0 18px 13px; padding: 5px 8px; border: 1px solid #d6e0fa; border-radius: 6px; color: #aaa; }
.inline-search input { flex: 1; width: 100%; border: 0; outline: none; font-size: 13px; }
.inline-search > svg { width: 16px; }
.bulk-bar { margin: 0 18px 12px; display: flex; align-items: center; gap: 13px; padding: 8px 11px; border-radius: 5px; font-size: 12px; background: #edf2ff; color: #4d6db4; }
.bulk-bar > span { margin-right: auto; }
.bulk-bar > button:hover { color: #244987; }
.task-groups { padding: 0 18px 20px; overflow: auto; min-height: 0; flex: 1; }
.task-group { margin-bottom: 19px; }
.group-heading { display: flex; align-items: center; gap: 5px; min-height: 25px; padding: 2px 0; margin: 0; font-size: 13px; font-weight: 500; }
.group-toggle { display: flex; align-items: center; gap: 4px; color: #333; min-height: 27px; }
.group-toggle > svg { width: 12px; height: 12px; color: #aaa; }
.group-toggle[aria-expanded=false] > svg { transform: rotate(-90deg); }
.group-count { color: #aaa; font-size: 11px; font-weight: 400; margin-left: 3px; }
.group-add { margin-left: auto; opacity: 0; height: 23px; width: 23px; }
.task-group:hover .group-add { opacity: 1; }
.task-row { display: flex; align-items: center; gap: 8px; min-height: 40px; padding: 7px 9px 7px 13px; border-bottom: 1px solid #f4f4f4; border-radius: 6px; position: relative; cursor: pointer; }
.task-row:hover { background: #f8f8f8; }
.task-row.selected { background: #f0f0f0; }
.task-row.multiselected { background: #edf2ff; }
.task-row.drag-over { box-shadow: 0 -2px 0 var(--accent); }
.task-check { display: inline-grid; place-items: center; width: 14px; height: 14px; border: 1.4px solid #b6b6b6; border-radius: 4px; background: transparent; flex-shrink: 0; color: white; position: relative; }
.task-check::after { content: ''; position: absolute; inset: -8px; }
.task-check svg { width: 11px; height: 11px; stroke-width: 2.5; }
.task-check:hover { border-color: var(--accent); }
.task-check[data-priority='3'] { border-color: #d96364; background: #fff5f5; }
.task-check[data-priority='2'] { border-color: #e1ad47; background: #fffbef; }
.task-check[data-priority='1'] { border-color: #668fdf; background: #f1f5ff; }
.task-row[data-status=done] .task-check, .task-check.done { background: #d7d7d7; border-color: #d7d7d7; }
.task-row[data-status=waiting] .task-check { border-style: dashed; }
.task-row[data-status=deleted] .task-check { border-style: dotted; }
.task-content { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; padding: 0; background: none; text-align: left; }
.task-title { color: #3a3a3a; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.7; }
.task-row[data-status=done] .task-title, .task-row[data-status=abandoned] .task-title { color: #b8b8b8; }
.task-row[data-status=abandoned] .task-title { text-decoration: line-through; }
.task-subtitle { font-size: 11px; color: #aaa; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-trailing { display: flex; align-items: center; justify-content: flex-end; gap: 6px; max-width: 42%; font-size: 11px; color: #aaa; flex-shrink: 0; }
.task-trailing .project-label { max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-trailing svg { width: 12px; height: 12px; color: #bbb; }
.task-date { white-space: nowrap; font-size: 11px; color: #969696; }
.task-date.overdue { color: #d36e66; }
.task-date.today { color: #62986c; }
.task-date.tomorrow { color: #b58b40; }
.task-date .date-time { margin-left: 3px; }
.task-more { width: 18px; height: 22px; opacity: 0; margin-right: -5px; }
.task-more svg { width: 15px; }
.task-row:hover .task-more, .task-row:focus-within .task-more { opacity: 1; }
.task-tag { font-size: 10px; color: #8e9cc0; max-width: 70px; overflow: hidden; text-overflow: ellipsis; }
.child-rows { padding-left: 28px; }
.child-row { display: flex; align-items: center; gap: 8px; min-height: 32px; font-size: 12px; color: #777; border-bottom: 1px solid #f6f6f6; padding-left: 8px; }
.child-row .task-check { width: 12px; height: 12px; }
.subtask-expander { position: absolute; left: 0; top: 9px; width: 11px; height: 18px; color: #aaa; }
.subtask-expander svg { width: 11px; height: 11px; }
.pane-status { min-height: 27px; flex-shrink: 0; font-size: 10px; color: #b2b2b2; padding: 5px 21px; }
.error-banner { margin: 0 18px 10px; padding: 9px 12px; background: #fff3ec; border: 1px solid #f3d8c6; color: #b87950; font-size: 12px; border-radius: 5px; display: flex; justify-content: space-between; gap: 10px; }
.error-banner button { text-decoration: underline; white-space: nowrap; }
.empty-state { text-align: center; margin: auto; padding: 40px 22px 90px; color: #bbb; max-width: 400px; }
.empty-art { width: 150px; height: 125px; color: #e4e7ed; stroke-width: 1.2; }
.empty-state h2 { font-size: 15px; font-weight: 400; color: #929292; margin: 12px 0 8px; }
.empty-state p { font-size: 12px; color: #b4b4b4; margin: 0 0 22px; }
.empty-state .button { margin: 0 3px; }
.detail-pane { border-left: 1px solid #ededed; min-width: 0; min-height:0; overflow:hidden; position: relative; display: flex; flex-direction: column; background: #fff; }
.detail-empty { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; padding: 50px 20px; color: #e9ebee; }
.detail-empty > svg { width: 220px; height: 180px; stroke-width: 1.2; opacity: .65; }
.detail-empty p { color: #c5c7cc; font-size: 12px; margin: 20px 0 20px; }
.detail-form { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.detail-toolbar { height: 57px; border-bottom: 1px solid #f1f1f1; display: flex; justify-content: space-between; align-items: center; padding: 0 23px; gap: 10px; flex-shrink: 0; }
.detail-toolbar > div { display: flex; align-items: center; gap: 12px; min-width: 0; }
.toolbar-divider { height: 16px; border-left: 1px solid #e8e8e8; }
.date-trigger { display: flex; align-items: center; gap: 6px; color: #a3a3a3; font-size: 13px; white-space: nowrap; }
.date-trigger svg { width: 17px; height: 17px; }
.date-trigger.is-set { color: #62896a; }
.date-trigger.overdue { color: #cf7269; }
.detail-scroll { flex: 1; min-height:0; overflow: auto; padding: 15px 24px 35px; }
.detail-title-row { display: flex; align-items: flex-start; gap: 10px; }
.detail-title-row textarea { width: 100%; border: 0; outline: 0; resize: none; overflow: hidden; font-size: 18px; font-weight: 650; line-height: 1.6; padding: 2px 0 7px; background: none; }
.detail-title-row textarea::placeholder { color: #bcbcbc; font-weight: 400; }
.detail-title-row .icon-button { margin-top: 3px; }
.detail-notes { width: 100%; min-height: 130px; border: 0; outline: 0; font-size: 14px; line-height: 1.85; resize: vertical; padding: 0; background: none; color: #666; }
.detail-notes::placeholder { color: #c1c1c1; }
.subtask-list { margin: 4px 0; }
.subtask-edit-row { display: flex; align-items: center; gap: 9px; min-height: 36px; border-bottom: 1px solid #f2f2f2; }
.subtask-edit-row input[type=text] { min-width: 0; flex: 1; border: 0; outline: none; background: none; font-size: 13px; padding: 7px 0; }
.subtask-edit-row.is-done input { text-decoration: line-through; color: #bbb; }
.subtask-edit-row .icon-button { width: 24px; height: 24px; opacity: 0; }
.subtask-edit-row:hover .icon-button, .subtask-edit-row:focus-within .icon-button { opacity: 1; }
.subtask-add { display: flex; gap: 8px; align-items: center; color: #b3b3b3; margin: 7px 0 20px; }
.subtask-add svg { width: 15px; height: 15px; }
.subtask-add input { flex: 1; border: 0; outline: 0; background: none; font-size: 12px; padding: 6px 0; }
.subtask-add input::placeholder { color: #bbb; }
.detail-tags { display: flex; flex-wrap: wrap; gap: 7px; }
.detail-tag { display: inline-flex; align-items: center; gap: 5px; background: #f2f5fc; color: #788caf; border-radius: 4px; font-size: 11px; padding: 3px 7px; }
.detail-tag button { font-size: 14px; color: #9eacc4; }
.tag-input { width: 100%; border: 0; outline: none; padding: 8px 0; background: none; font-size: 11px; color: #8b9eb9; margin-bottom: 15px; }
.tag-input::placeholder { color: #c0c0c0; }
.detail-info { display: grid; gap: 8px; font-size: 11px; color: #999; margin: 15px 0; }
.info-line { display: flex; align-items: center; gap: 7px; }
.info-line svg { width: 14px; height: 14px; color: #aaa; }
.waiting-section { padding: 13px; background: #faf8f3; border-radius: 5px; margin: 14px 0; }
.waiting-section label { display: flex; flex-direction: column; gap: 6px; font-size: 11px; color: #a39779; margin-bottom: 10px; }
.waiting-section input { width: 100%; background: #fff; border: 1px solid #e8e1d4; border-radius: 4px; padding: 7px 9px; font-size: 12px; }
.detail-footer { flex-shrink: 0; }
.detail-footer-top, .detail-footer-bottom { display: flex; align-items: center; justify-content: space-between; padding: 10px 24px; min-height: 43px; gap: 10px; }
.detail-footer-top { border-top: 1px solid #f1f1f1; }
.detail-footer-bottom { min-height: 38px; padding-top: 3px; padding-bottom: 7px; }
.detail-footer-bottom > div { display: flex; align-items: center; gap: 4px; }
.detail-footer-bottom .icon-button { width: 26px; height: 26px; }
#saveStatus { color: #b0b0b0; font-size: 10px; }
.project-trigger { display: flex; align-items: center; gap: 7px; color: #777; font-size: 12px; min-width: 0; }
.project-trigger svg { width: 15px; height: 15px; }
.project-trigger span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field-hint { font-size: 11px; line-height: 1.8; color: #bd955e; }
.form-error { padding: 9px 11px; border-radius: 4px; font-size: 12px; background: #fff1eb; color: #b77555; line-height: 1.7; margin: 12px 0; overflow-wrap: anywhere; }
.conflict-panel { padding: 12px; background: #fff9ea; border: 1px solid #f1e2b4; border-radius: 5px; margin: 12px 0; }
.conflict-panel h3 { font-size: 12px; font-weight: 500; margin: 0 0 7px; }
.conflict-panel p { white-space: pre-wrap; font-size: 12px; color: #a48958; overflow-wrap: anywhere; }
.floating-menu { position: fixed; z-index: 100; padding: 5px; min-width: 180px; max-width: min(300px, 90vw); background: #fff; border: 1px solid #e9e9e9; box-shadow: 0 6px 24px #00000016; border-radius: 6px; max-height: 75vh; overflow: auto; }
.menu-item { min-height: 33px; padding: 6px 10px; display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; border-radius: 4px; font-size: 13px; }
.menu-item > svg { width: 15px; height: 15px; color: #999; }
.menu-item .menu-mark { margin-left: auto; width: 15px; height: 15px; color: var(--accent); }
.menu-item:hover { background: #f4f4f4; }
.menu-item.destructive { color: #cb6a65; }
.menu-label { padding: 5px 10px; font-size: 11px; color: #aaa; }
.menu-divider { border-top: 1px solid #eee; margin: 5px 3px; }
.button { border-radius: 5px; font-size: 12px; padding: 8px 15px; min-height: 34px; border: 1px solid transparent; display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; }
.button-primary { background: var(--accent); color: #fff; }
.button-primary:hover { background: #3969d5; }
.button-secondary { background: #fff; border-color: #e4e4e4; color: #777; }
.button-secondary:hover { background: #f8f8f8; }
.modal { width: min(460px, calc(100vw - 30px)); max-height: 88dvh; overflow: auto; border: 1px solid #e8e8e8; border-radius: 9px; box-shadow: 0 14px 70px #00000022; padding: 0; color: #333; }
.modal::backdrop { background: #00000035; }
.modal > form > header { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 16px 20px 10px; }
.modal h2 { margin: 0; font-size: 16px; font-weight: 550; }
.modal-content { padding: 12px 22px 16px; }
.modal > form > footer { display: flex; justify-content: flex-end; gap: 9px; padding: 13px 21px; border-top: 1px solid #f0f0f0; }
.modal > form > .form-error { margin: 0 20px 12px; }
.modal-field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; font-size: 12px; color: #888; }
.modal-field input, .modal-field select, .modal-field textarea { border: 1px solid #dedede; border-radius: 5px; padding: 8px 10px; background: #fff; font-size: 13px; width: 100%; min-height: 37px; color: #444; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.modal-note { font-size: 11px; line-height: 1.8; color: #aaa; margin: 10px 0; }
.modal-link { display: block; padding: 10px; border: 1px solid #e5e5e5; border-radius: 5px; font-size: 12px; color: var(--accent); text-align: center; margin: 12px 0; }
.color-options { display: flex; gap: 9px; margin: 7px 0 20px; }
.color-option { width: 24px; height: 24px; border-radius: 50%; border: 3px solid white; outline: 1px solid transparent; }
.color-option.selected { outline-color: #999; }
.history-entry { border-left: 2px solid #dfe7f8; padding: 0 0 0 12px; margin: 0 0 19px; font-size: 11px; color: #999; }
.history-entry strong { display: block; font-weight: 500; color: #777; font-size: 12px; }
.history-entry p { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.8; margin: 5px 0 0; }
.date-dialog { width: min(370px, calc(100vw - 30px)); }
.date-shortcuts { display: flex; justify-content: space-between; gap: 5px; margin-bottom: 18px; }
.date-shortcut { display: flex; flex-direction: column; align-items: center; gap: 5px; font-size: 11px; color: #999; padding: 8px 7px; border-radius: 5px; min-width: 53px; }
.date-shortcut:hover { background: #f0f4ff; color: var(--accent); }
.date-shortcut svg { width: 20px; height: 20px; }
.month-header { display: flex; justify-content: space-between; align-items: center; font-size: 13px; margin: 10px 0 8px; }
.month-header > div { display: flex; gap: 7px; }
.month-header button { width: 28px; height: 28px; border-radius: 4px; color: #888; }
.month-header button:hover { background: #f1f1f1; }
.date-grid, .date-weekdays { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; text-align: center; }
.date-weekdays { font-size: 11px; color: #aaa; margin: 7px 0; }
.date-cell { width: 32px; height: 30px; margin: 1px auto; border-radius: 50%; font-size: 12px; color: #555; }
.date-cell.outside { color: #d0d0d0; }
.date-cell:hover { background: #f0f3fc; }
.date-cell.today { color: var(--accent); font-weight: 650; }
.date-cell.selected { background: var(--accent); color: #fff; }
.date-extra { border-top: 1px solid #eee; padding-top: 13px; margin-top: 15px; }
.date-extra summary { font-size: 12px; color: #999; cursor: pointer; margin-bottom: 14px; }
.date-extra .modal-field { font-size: 11px; margin-bottom: 11px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); color: #fff; background: #464646; font-size: 12px; line-height: 1.7; padding: 10px 18px; border-radius: 6px; z-index: 200; max-width: 90vw; box-shadow: 0 5px 24px #00000017; }
.toast.error { background: #9b6f57; }
.module-content { overflow: auto; padding: 20px 28px 40px; flex: 1; }
.module-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin: 0 0 25px; }
.module-heading p { margin: 0; font-size: 12px; color: #aaa; }
.month-workspace { display: grid; grid-template-columns: repeat(7, minmax(95px, 1fr)); border-top: 1px solid #eee; border-left: 1px solid #eee; }
.month-weekday { padding: 10px; border-right: 1px solid #eee; border-bottom: 1px solid #eee; font-size: 12px; color: #999; text-align: center; }
.month-day { min-height: 116px; padding: 8px 6px 6px; border-right: 1px solid #eee; border-bottom: 1px solid #eee; min-width: 0; }
.month-day.outside { background: #fafafa; }
.month-day.drag-over { background: #eef3ff; }
.month-day-label { font-size: 11px; color: #999; margin: 0 4px 7px; width: 23px; height: 23px; display: grid; place-items: center; border-radius: 50%; }
.month-day.today .month-day-label { color: white; background: var(--accent); }
.calendar-task { width: 100%; text-align: left; font-size: 11px; line-height: 1.7; padding: 3px 5px; border-radius: 3px; background: #edf2ff; color: #5974ac; margin: 0 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.calendar-task:hover { background: #dfe9ff; }
.calendar-task small { opacity: .7; margin-right: 5px; font-size: 10px; }
.board { display: flex; gap: 15px; min-height: 300px; }
.board-column { min-width: 230px; flex: 1; padding: 12px; background: #fafafa; border-radius: 7px; }
.board-column h2 { font-size: 13px; font-weight: 500; margin: 0 0 13px; }
.board-column.drag-over { background: #edf2ff; }
.board-card { width: 100%; text-align: left; background: #fff; border: 1px solid #eee; border-radius: 6px; margin-bottom: 9px; padding: 12px; font-size: 13px; box-shadow: 0 1px 2px #00000004; }
.board-card small { display: block; font-size: 10px; color: #aaa; margin-top: 8px; }
.focus-module { max-width: 540px; margin: 60px auto; text-align: center; }
.focus-module h2 { font-size: 16px; font-weight: 450; color: #999; }
.timer-face { font-size: 76px; font-weight: 250; letter-spacing: 3px; font-variant-numeric: tabular-nums; color: #454545; margin: 35px 0; }
.focus-actions { display: flex; gap: 12px; justify-content: center; }
.focus-note { margin-top: 30px; font-size: 11px; color: #aaa; }
.habit-row { display: flex; align-items: center; gap: 15px; min-height: 76px; border-bottom: 1px solid #f1f1f1; }
.habit-title { flex: 1; font-size: 14px; }
.habit-dots { display: flex; gap: 8px; }
.habit-day { width: 27px; height: 27px; border-radius: 7px; background: #f0f2f6; color: #c0c5d0; display: grid; place-items: center; font-size: 11px; }
.habit-day.done { background: #dce8ff; color: #5f86d2; }
.habit-day.today { outline: 1px solid #adc2ed; }

.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin: 10px 0 40px; }
.stat-cell { padding: 20px; border: 1px solid #eee; border-radius: 6px; }
.stat-cell strong { display: block; font-size: 28px; color: #597dbd; font-weight: 400; }
.stat-cell span { font-size: 12px; color: #aaa; }
.stat-list h3 { font-size: 13px; font-weight: 500; margin-bottom: 16px; }
.stat-row { display: flex; align-items: center; gap: 15px; margin-bottom: 12px; font-size: 12px; color: #888; }
.stat-row > span:first-child { min-width: 80px; }
.stat-bar-track { flex: 1; max-width: 400px; background: #f5f5f5; height: 8px; border-radius: 5px; overflow: hidden; }
.stat-bar { background: #b9cdf7; height: 100%; border-radius: 5px; }
.summary-section { padding: 10px 0 22px; border-bottom: 1px solid #f0f0f0; margin-bottom: 20px; }
.summary-section h2 { font-size: 15px; font-weight: 500; margin-bottom: 15px; }
.summary-section p { color: #999; font-size: 12px; }
.mobile-detail-close { display: none; }
@media (max-width: 1150px) {
  :root { --nav-width: 210px; --detail-width: 34vw; }
  .workspace { grid-template-columns: var(--rail-width) var(--nav-width) minmax(290px, 1fr) minmax(310px, var(--detail-width)); }
  .task-trailing .project-label { max-width: 65px; }
  .task-tag { display: none; }
  .detail-scroll { padding: 15px 18px 25px; }
  .detail-toolbar, .detail-footer-top, .detail-footer-bottom { padding-left: 18px; padding-right: 18px; }
}
@media (max-width: 920px) {
  :root { --nav-width: 210px; }
  .workspace { grid-template-columns: var(--rail-width) var(--nav-width) minmax(280px, 1fr); }
  .detail-pane { display: none; }
  .workspace.has-detail .detail-pane { display: flex; position: fixed; top: 0; bottom: 0; right: 0; width: min(440px, calc(100vw - 50px)); z-index: 40; box-shadow: -8px 0 30px #00000012; }
  .mobile-detail-close { display: inline-grid; }
  .pane-header { height: 57px; }
  .month-workspace { grid-template-columns: repeat(7, minmax(80px, 1fr)); min-width: 630px; }
  .month-day { min-height: 100px; }
}
@media (max-width: 620px) {
  :root { --rail-width: 44px; --nav-width: 0px; }
  .workspace, .workspace.module-wide { grid-template-columns: var(--rail-width) minmax(0, 1fr); }
  .list-sidebar { position: fixed; left: 44px; top: 0; bottom: 0; width: 230px; z-index: 45; box-shadow: 5px 0 25px #00000018; transform: translateX(-280px); transition: transform .2s; }
  .workspace.mobile-nav .list-sidebar { transform: translateX(0); }
  .workspace.sidebar-collapsed .list-sidebar { visibility: visible; }
  .tool-rail { gap: 18px; padding-top: 13px; }
  .profile-button { width: 28px; height: 28px; font-size: 20px; }
  .module-nav { gap: 9px; }
  .rail-button { width: 30px; height: 34px; }
  .rail-button svg { width: 20px; height: 20px; }
  .rail-bottom { gap: 7px; }
  .pane-header { padding: 0 13px; }
  h1 { font-size: 18px; }
  .quick-add { margin: 5px 12px 14px; min-height: 40px; }
  .quick-add input { font-size: 12px; }
  .quick-tool { opacity: 1; width: 23px; }
  .quick-submit { display: none; }
  .task-groups { padding: 0 10px 15px; }
  .task-row { gap: 8px; padding-right: 3px; min-height: 45px; }
  .task-title { font-size: 13px; }
  .task-trailing { max-width: 32%; gap: 4px; }
  .task-trailing .project-label { display: none; }
  .task-more { opacity: 1; }
  .task-date { font-size: 10px; }
  .task-date .date-time { display: none; }
  .task-check { width: 15px; height: 15px; }
  .task-check::after { inset: -10px; }
  .workspace.has-detail .detail-pane { width: calc(100vw - 44px); box-shadow: none; }
  .detail-scroll { padding: 16px 18px; }
  .detail-title-row textarea { font-size: 17px; }
  .detail-notes { font-size: 13px; }
  .detail-toolbar { padding: 0 16px; }
  .detail-footer-top, .detail-footer-bottom { padding-left: 18px; padding-right: 18px; }
  .module-content { padding: 18px 16px 35px; }
  .module-heading { gap: 10px; margin-bottom: 20px; }
  .module-heading p { font-size: 11px; }
  .focus-module { margin: 45px auto; }
  .timer-face { font-size: 58px; }
  .habit-row { gap: 9px; flex-wrap: wrap; padding: 13px 0; }
  .habit-title { min-width: 50%; }
  .habit-day { width: 24px; height: 24px; }
  .habit-dots { gap: 5px; }
  .stat-grid { grid-template-columns: 1fr; gap: 12px; }
  .stat-cell { padding: 13px 17px; }
  .stat-cell strong { display: inline; margin-right: 15px; }
  .bulk-bar { gap: 8px; flex-wrap: wrap; font-size: 11px; }
  .sidebar-footer { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
.workspace-filing { display:block; padding:3px 8px 7px; text-align:center; font-size:9px; color:#92969f; text-decoration:none; background:#fafafa; }
.workspace-filing:hover { text-decoration:underline; }
