/* Original task components, followed by responsive workspace extensions. */

  /* The shell — AIDE's v2 layout on the same design system: 240px nav, 48px header, surface + drawer at 44%. */
  html, body { margin: 0; height: 100%; background: var(--bg-primary); }
  .ds { height: 100%; }
  .app { display: grid; grid-template-columns: 240px 1fr; height: 100%; min-height: 0; }
  .app > .main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
  .side { display: flex; flex-direction: column; background: var(--bg-primary); border-right: 1px solid var(--border-low); padding: var(--space-12); gap: var(--space-8); min-height: 0; }
  .side .head { display: flex; align-items: center; justify-content: space-between; height: 32px; padding: 0 var(--space-4); font-size: var(--heading-4); font-weight: var(--weight-semibold); color: var(--fg-high); }
  .side .nav { display: flex; flex-direction: column; gap: 2px; margin-top: var(--space-4); }
  .side .nav-item { display: flex; align-items: center; gap: var(--space-8); height: 30px; padding: 0 var(--space-8); border-radius: var(--radius-default); font-size: var(--text-medium); color: var(--fg-base); cursor: pointer; text-decoration: none; }
  .side .nav-item:hover { background: var(--bg-hover); color: var(--fg-high); text-decoration: none; }
  .side .nav-item.is-active { background: var(--cta-soft); color: var(--cta-hover); font-weight: var(--weight-semibold); }
  .side .nav-item svg { width: 16px; height: 16px; flex: none; color: var(--fg-2); } .side .nav-item.is-active svg { color: var(--cta-hover); }
  .side .nav-item .n { margin-left: auto; color: var(--fg-3); font-size: var(--text-small); }
  .side .section { font-size: var(--text-small); color: var(--fg-3); padding: var(--space-8) var(--space-8) var(--space-2); }
  .side .foot { margin-top: auto; display: flex; gap: var(--space-12); font-size: var(--text-small); padding: 0 var(--space-8); }
  .side .foot a { color: var(--fg-3); cursor: pointer; } .side .foot a:hover { color: var(--fg-2); }
  .topbar .logo { height: 18px; width: auto; display: block; }
  .topbar .search { width: 260px; }
  .content { display: grid; grid-template-columns: 1fr; flex: 1; min-height: 0; }
  .content:has(.drawer:not([hidden])) { grid-template-columns: 1fr 44%; }
  .surface { position: relative; overflow: auto; min-width: 0; }
  .drawer { min-height: 0; } .drawer[hidden] { display: none; } .drawer-body { min-height: 0; }
  /* quick add */
  .quick { display: flex; gap: var(--space-8); padding: var(--space-12) var(--space-16); border-bottom: 1px solid var(--border-low); background: var(--bg-primary); position: sticky; top: 0; z-index: 2; }
  .quick .input { flex: 1; }
  .quick .hint { font-size: var(--text-small); color: var(--fg-3); align-self: center; white-space: nowrap; }
  /* rows */
  .group-head { display: flex; align-items: center; gap: var(--space-8); height: 30px; padding: 0 var(--space-16); background: var(--bg-mid); border-bottom: 1px solid var(--neutral-200); position: sticky; top: 0; z-index: 1; }
  .group-head .n { margin-left: auto; color: var(--fg-3); font-size: var(--text-small); }
  .row { display: flex; align-items: center; gap: var(--space-8); min-height: 36px; padding: 4px var(--space-16); border-bottom: 1px solid var(--border-low); cursor: pointer; font-size: var(--text-medium); }
  .row:hover { background: var(--bg-hover); } .row.is-selected { background: var(--cta-soft); }
  .row .name { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--fg-high); }
  .row .name small { display: block; color: var(--fg-3); font-size: var(--text-small); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .row .right { display: flex; align-items: center; gap: var(--space-8); flex: none; }
  .row .meta { color: var(--fg-3); font-size: var(--text-small); font-variant-numeric: tabular-nums; }
  .row .meta.is-late { color: var(--red-700); font-weight: var(--weight-semibold); }
  .row .rank { width: 20px; color: var(--fg-3); font-size: var(--text-small); text-align: right; font-variant-numeric: tabular-nums; }
  .row .check { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--border-high); flex: none; }
  .row .check:hover { border-color: var(--green-500); background: var(--green-50); }
  .row.is-done .name { text-decoration: line-through; color: var(--fg-3); }
  .q-do { color: var(--red-700); } .q-schedule { color: var(--blue-700); } .q-delegate { color: var(--orange-700); } .q-drop { color: var(--fg-3); }
  .qdot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
  .qdot.do { background: var(--status-red); } .qdot.schedule { background: var(--status-blue); } .qdot.delegate { background: var(--status-orange); } .qdot.drop { background: var(--neutral-400); }
  /* matrix */
  .matrix { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: var(--space-12); padding: var(--space-16); min-height: calc(100% - 32px); background: var(--bg-secondary); }
  .quad { background: var(--bg-primary); border: 1px solid var(--border-low); border-radius: var(--radius-large); display: flex; flex-direction: column; min-height: 220px; }
  .quad .qh { display: flex; align-items: center; gap: var(--space-8); padding: var(--space-8) var(--space-12); border-bottom: 1px solid var(--border-low); }
  .quad .qh .t-eyebrow { margin: 0; } .quad .qh .n { margin-left: auto; color: var(--fg-3); font-size: var(--text-small); }
  .quad .qh .sub { color: var(--fg-3); font-size: var(--text-small); }
  .quad .cards { padding: var(--space-8); display: grid; gap: var(--space-8); align-content: start; overflow: auto; }
  .kcard { cursor: pointer; } .kcard.is-selected { box-shadow: 0 0 0 2px var(--blue-300); }
  .kcard .kmeta { display: flex; gap: var(--space-8); color: var(--fg-3); font-size: var(--text-small); margin-top: 4px; }
  /* drawer bits */
  .drawer .fields { display: grid; grid-template-columns: 110px 1fr; gap: var(--space-8) var(--space-12); align-items: center; font-size: var(--text-medium); }
  .drawer .fields .label { color: var(--fg-3); }
  .drawer .actions { display: flex; flex-wrap: wrap; gap: var(--space-8); padding-bottom: var(--space-12); }
  .drawer .drawer-head .spacer { flex: 1; min-width: 0; }
  .drawer .title-input { min-width: 0; font-size: var(--heading-4); font-weight: var(--weight-semibold); color: var(--fg-high); border: 0; width: 100%; padding: 2px 0; background: transparent; font-family: inherit; }
  .drawer .title-input:focus { outline: none; box-shadow: inset 0 -2px 0 var(--blue-300); }
  .drawer .textarea { width: 100%; min-height: 140px; font-family: inherit; }
  .drawer .md { font-size: var(--text-medium); line-height: 1.5; white-space: pre-wrap; padding: var(--space-8); border: 1px dashed transparent; border-radius: var(--radius-default); min-height: 40px; cursor: text; }
  .drawer .md:hover { border-color: var(--border-low); } .drawer .md.is-empty { color: var(--fg-3); }
  .drawer .md a { color: var(--cta-hover); }
  .files { display: flex; flex-wrap: wrap; gap: var(--space-8); }
  .files .file { display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 8px; border-radius: var(--radius-default); background: var(--neutral-200); font-size: var(--text-small); color: var(--fg-base); text-decoration: none; }
  .history { display: grid; gap: 4px; font-size: var(--text-small); color: var(--fg-2); }
  .history b { color: var(--fg-high); font-weight: var(--weight-semibold); }
  .seg { display: inline-flex; } .seg .btn { border-radius: 0; } .seg .btn:first-child { border-radius: var(--radius-default) 0 0 var(--radius-default); } .seg .btn:last-child { border-radius: 0 var(--radius-default) var(--radius-default) 0; }
  .signin { height: 100%; display: flex; align-items: center; justify-content: center; background: var(--bg-secondary); }
  .signin .card { width: 340px; display: grid; gap: var(--space-12); }
  .wordmark { font-weight: var(--weight-extrabold); font-size: var(--text-default); color: var(--fg-high); display: flex; align-items: center; gap: 8px; }
  .toastwrap { position: fixed; left: 0; right: 0; bottom: 40px; display: flex; justify-content: center; pointer-events: none; z-index: 15000; }
  .toastwrap .toast { pointer-events: auto; }
  .token { font-family: var(--font-mono); font-size: 12px; background: var(--neutral-200); padding: 8px; border-radius: var(--radius-default); word-break: break-all; user-select: all; }
  .req { padding: var(--space-12) var(--space-16); border-bottom: 1px solid var(--border-low); display: grid; gap: 4px; font-size: var(--text-medium); }
  .req .rh { display: flex; align-items: center; gap: var(--space-8); } .req .rh .meta { margin-left: auto; color: var(--fg-3); font-size: var(--text-small); }
  .req .txt { white-space: pre-wrap; color: var(--fg-base); } .req .resp { border-left: 2px solid var(--blue-300); padding-left: var(--space-8); color: var(--fg-2); white-space: pre-wrap; }
  .pad { padding: var(--space-16); display: grid; gap: var(--space-16); max-width: 720px; }
  .pad table { width: 100%; border-collapse: collapse; font-size: var(--text-medium); } .pad td, .pad th { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--border-low); } .pad th { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--fg-3); }
  .inline-form { display: flex; gap: var(--space-8); align-items: center; flex-wrap: wrap; }
  .inline-form .input, .inline-form .select { width: auto; flex: 1; min-width: 160px; }
  @media (max-width: 1023px) { .app { grid-template-columns: 1fr; } .side { display: none; } .content:has(.drawer:not([hidden])) { grid-template-columns: 1fr; } .drawer { border-left: 0; border-top: 1px solid var(--border-low); } .matrix { grid-template-columns: 1fr; grid-template-rows: auto; } .topbar .search { width: 140px; } }

/* Task-specific extensions to the shared AIDE design system. */
.ds { -webkit-font-smoothing: antialiased; }
.ds button, .ds input, .ds select, .ds textarea { font-family: inherit; }
.ds button { cursor: pointer; }
.ds :focus-visible { outline: 2px solid var(--blue-600); outline-offset: 3px; }
.app { grid-template-columns: 224px minmax(0, 1fr); }
.app.is-signed-out { display: block; }
.side { padding: 24px 12px 12px; background: var(--neutral-100); gap: 24px; }
.side .head { justify-content: flex-start; height: auto; gap: 10px; padding: 0 12px 12px; }
.side .head strong { display: block; font-size: 16px; letter-spacing: -.3px; }
.workspace-label { display: block; font-size: 12px; color: var(--fg-2); font-weight: 500; margin-top: 2px; }
.side .nav { margin: 0; gap: 4px; }
.ds .side .nav-item { border: 0; background: transparent; width: 100%; justify-content: flex-start; text-align: left; height: 38px; padding: 0 12px; gap: 12px; font-size: 13px; }
.ds .side .nav-item:hover { background: var(--neutral-200); }
.ds .side .nav-item.is-active { background: var(--blue-100); color: var(--blue-800); }
.side .nav-item small { margin-left: auto; font-size: 10px; color: var(--fg-2); }
.side .section { letter-spacing: .1em; font-size: 10px; font-weight: 700; padding: 0 12px 10px; }
.side .people .nav-item { font-weight: 500; }
.ds .avatar { background: var(--blue-100); color: var(--blue-800); flex: none; }
.side-note { margin: auto 12px 0; color: var(--fg-2); line-height: 1.6; font-size: 12px; }
.side-note strong { display: block; color: var(--fg-base); font-weight: 600; max-width: 150px; }
.side-note p { margin: 4px 0 0; }
.side .foot { margin: 0; border-top: 1px solid var(--border-low); padding: 16px 6px 0; gap: 8px; align-items: center; }
.account { flex: 1; min-width: 0; }
.account strong, .account span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account strong { color: var(--fg-high); font-size: 12px; }
.account span { color: var(--fg-2); font-size: 10px; margin-top: 3px; }
.ds .topbar { height: 64px; flex: none; padding: 0 32px; }
.breadcrumb { display: flex; align-items: center; gap: 14px; font-size: 12px; color: var(--fg-2); white-space: nowrap; }
.breadcrumb strong { color: var(--fg-high); font-weight: 600; }
.crumb-divider { color: var(--neutral-500); }
.topbar .search { width: 240px; height: 34px; background: var(--neutral-100); border-radius: 6px; }
.shortcut-hint { margin-left: -38px; margin-right: 12px; border: 1px solid var(--border-low); border-radius: 3px; padding: 0 5px; color: var(--fg-2); font-size: 12px; pointer-events: none; }
.search:focus + .shortcut-hint, .search:not(:placeholder-shown) + .shortcut-hint { visibility: hidden; }
.surface { background: var(--bg-primary); padding: 0 32px 32px; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 34px 0 28px; }
.eyebrow { font-size: 10px; letter-spacing: .12em; font-weight: 700; color: var(--fg-2); text-transform: uppercase; }
.page-heading h1 { font-size: 28px; line-height: 1.25; letter-spacing: -.8px; margin: 8px 0; font-weight: 800; color: var(--fg-high); }
.page-heading p { font-size: 13px; line-height: 1.6; color: var(--fg-2); margin: 0; }
.ds .person-picker { width: auto; max-width: 170px; flex: none; height: 34px; }
.summary { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--border-low); border-radius: 8px; margin-bottom: 24px; background: var(--neutral-100); }
.stat { display: flex; flex-direction: column; gap: 6px; padding: 18px 22px; }
.stat + .stat { border-left: 1px solid var(--border-low); }
.stat strong { font-size: 26px; line-height: 1.2; font-weight: 700; letter-spacing: -.5px; color: var(--fg-high); }
.stat span { color: var(--fg-2); font-size: 12px; }
.stat.overdue strong { color: var(--red-900); }
.composer { margin-bottom: 28px; }
.quick { padding: 0; border: 0; position: static; gap: 10px; }
.quick .input { min-width: 0; height: 40px; border-radius: 6px; }
.ds .quick .btn { height: 40px; padding: 0 16px; border-radius: 6px; flex: none; }
.quick-help { font-size: 11px; color: var(--fg-2); padding: 9px 2px 0; }
.quick-help code { background: var(--neutral-100); border: 1px solid var(--border-low); border-radius: 3px; padding: 1px 4px; font-size: 10px; }
.group-head { height: 38px; padding: 0 12px; background: var(--neutral-100); border: 1px solid var(--border-low); border-radius: 5px; margin-top: 22px; top: 0; }
.group-head .t-eyebrow { text-transform: none; font-size: 12px; letter-spacing: 0; font-weight: 700; }
.group-head .n { background: var(--neutral-200); border-radius: 4px; padding: 1px 6px; color: var(--fg-2); }
.row { padding: 10px 12px; gap: 12px; min-height: 62px; }
.row .rank { width: 14px; flex: none; font-size: 11px; color: var(--fg-2); }
.ds .row .check { display: flex; padding: 0; width: 18px; height: 18px; min-width: 18px; border: 1.5px solid var(--neutral-500); background: white; border-radius: 50%; color: var(--green-900); position: relative; }
.row .check::before { content: ''; position: absolute; inset: -7px; }
.ds .row .check:hover, .ds .row .check.checked { background: var(--green-50); border-color: var(--green-700); }
.row .qdot { width: 6px; height: 6px; }
.ds .row .task-open { height: auto; padding: 3px 0; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; white-space: normal; flex: 1; min-width: 0; text-align: left; border: 0; background: transparent; }
.task-title { font-weight: 600; font-size: 13px; color: var(--fg-high); line-height: 1.5; overflow-wrap: anywhere; }
.task-open small { color: var(--fg-2); font-size: 11px; line-height: 1.5; font-weight: 400; }
.is-done .task-title { text-decoration: line-through; color: var(--fg-2); }
.row .right { gap: 10px; max-width: 38%; flex-wrap: wrap; justify-content: flex-end; }
.row .meta { color: var(--fg-2); font-size: 11px; white-space: nowrap; }
.priority { font-size: 10px; font-weight: 600; padding: 2px 6px; border-radius: 4px; background: var(--neutral-100); color: var(--fg-2); white-space: nowrap; }
.priority-3 { color: var(--orange-900); background: var(--orange-50); }
.priority-4 { color: var(--red-900); background: var(--red-50); }
.list-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--fg-2); margin: 0 0 12px; }
.matrix { padding: 0; gap: 20px; background: transparent; }
.quad { min-width: 0; background: var(--neutral-100); min-height: 240px; }
.quad .qh { flex-wrap: wrap; padding: 16px; gap: 8px; }
.quad .qh .t-eyebrow { font-weight: 700; font-size: 13px; text-transform: none; letter-spacing: 0; }
.quad .qh .sub { order: 4; width: 100%; padding-left: 16px; font-size: 11px; }
.quad .cards { padding: 12px; }
.ds .kcard { border: 1px solid var(--border-low); box-shadow: none; padding: 14px; margin: 0; }
.ds .kcard:hover { border-color: var(--blue-300); box-shadow: var(--shadow-1); }
.kcard .kmeta { margin-top: 14px; flex-wrap: wrap; font-size: 11px; }
.content:has(.drawer:not([hidden])) { grid-template-columns: minmax(0, 1fr) minmax(380px, 44%); }
.content:has(.drawer:not([hidden])) .surface { padding-left: 24px; padding-right: 24px; }
.content:has(.drawer:not([hidden])) .row .right { max-width: 28%; }
.content:has(.drawer:not([hidden])) .matrix { grid-template-columns: 1fr; }
.drawer { box-shadow: -8px 0 24px #20242805; overflow: hidden; }
.drawer-caption { padding: 22px 24px 0; color: var(--fg-2); font-size: 10px; letter-spacing: .1em; display: flex; justify-content: space-between; gap: 8px; }
.drawer-caption span { text-transform: none; letter-spacing: 0; font-size: 10px; }
.ds .drawer-head { padding: 16px 24px; border-bottom: 1px solid var(--border-low); }
.drawer .title-input { font-size: 20px; line-height: 1.5; }
.ds .drawer-body { padding: 20px 24px 32px; }
.drawer .actions { padding-bottom: 24px; }
.drawer .fields { grid-template-columns: 85px minmax(0, 1fr); gap: 14px 12px; padding-bottom: 20px; border-bottom: 1px solid var(--border-low); }
.drawer .fields .label { color: var(--fg-2); font-size: 12px; }
.drawer .fields .select, .drawer .fields .input { width: 100%; min-width: 0; }
.drawer .seg { flex-wrap: wrap; }
.drawer .t-eyebrow { font-size: 11px; color: var(--fg-2); margin: 24px 0 12px; }
.drawer .md { padding: 0; line-height: 1.7; overflow-wrap: anywhere; cursor: default; }
.drawer .md:hover { border-color: transparent; }
.context-actions { display: flex; gap: 8px; margin-top: 10px; }
.history { gap: 0; }
.history > div { border-left: 1px solid var(--border-low); padding: 0 0 16px 14px; line-height: 1.7; }
.files .file { height: auto; min-height: 28px; overflow-wrap: anywhere; }
.pad { max-width: 100%; padding: 0; gap: 20px; }
.pad td, .pad th { padding: 12px; overflow-wrap: anywhere; }
.pad table { table-layout: fixed; }
.req { margin-top: 16px; border: 1px solid var(--border-low); border-radius: 8px; padding: 20px; gap: 12px; }
.req .rh { flex-wrap: wrap; }
.req .txt, .req .resp { overflow-wrap: anywhere; line-height: 1.7; }
.empty-symbol { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--blue-50); color: var(--blue-700); font-size: 22px; margin-bottom: 8px; }
.empty .text { color: var(--fg-2); font-size: 13px; line-height: 1.7; max-width: 340px; }
.startup-error { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.toastwrap { bottom: 24px; gap: 8px; flex-direction: column; align-items: center; padding: 0 16px; }
.toastwrap .toast { max-width: min(600px, 100%); white-space: normal; overflow-wrap: anywhere; }
.signin { display: grid; grid-template-columns: 1fr 1fr; min-height: 100%; height: auto; background: white; }
.signin-panel { width: min(420px, 100%); padding: 56px 32px; justify-self: center; }
.signin .wordmark { font-size: 17px; letter-spacing: -.3px; }
.signin-copy { margin: 80px 0 32px; }
.signin-copy h1 { white-space: pre-line; font-size: 40px; letter-spacing: -1.5px; line-height: 1.2; color: var(--fg-high); margin: 16px 0; font-weight: 800; }
.signin-copy p { color: var(--fg-2); font-size: 15px; line-height: 1.8; margin: 0; }
.ds .google-signin { display: flex; width: 100%; height: 46px; border-radius: 6px; font-size: 14px; text-decoration: none; gap: 12px; font-weight: 600; }
.google-mark { font-family: Arial, sans-serif; font-size: 20px; font-weight: bold; color: #4285f4; }
.signin-note { font-size: 12px; color: var(--fg-2); text-align: center; line-height: 1.7; margin: 18px 20px 0; }
.signin-message:not(:empty) { padding: 12px; border-radius: 6px; background: var(--red-50); color: var(--red-900); line-height: 1.6; margin-top: 16px; font-size: 13px; }
.signin-preview { background: var(--blue-50); border-left: 1px solid var(--blue-100); min-height: 100vh; padding: 64px 48px; display: flex; flex-direction: column; justify-content: center; }
.signin-preview h2 { white-space: pre-line; font-weight: 700; font-size: 30px; line-height: 1.35; letter-spacing: -.8px; margin: 14px 0 40px; color: var(--midnight-800); }
.preview-board { background: white; border: 1px solid var(--blue-100); border-radius: 12px; padding: 8px 24px; box-shadow: 0 12px 36px #084e9f09; }
.preview-title { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 20px 0; font-size: 13px; border-bottom: 1px solid var(--border-low); }
.preview-row { display: flex; align-items: center; gap: 12px; padding: 22px 0; }
.preview-row + .preview-row { border-top: 1px solid var(--border-low); }
.preview-row strong { font-size: 13px; color: var(--fg-high); font-weight: 600; }
.preview-row p { font-size: 11px; color: var(--fg-2); margin: 5px 0 0; }
.preview-check { margin-left: auto; color: var(--blue-700); font-size: 13px; width: 22px; height: 22px; border-radius: 50%; background: var(--blue-50); display: grid; place-items: center; }
.preview-footer { display: flex; gap: 12px; align-items: center; font-size: 11px; color: var(--fg-2); margin-top: 28px; }
.preview-line { height: 1px; width: 24px; background: var(--blue-300); }
@media (min-width: 1450px) { .surface { padding-left: 48px; padding-right: 48px; } }
@media (max-width: 1190px) {
  .content:has(.drawer:not([hidden])) { grid-template-columns: minmax(0, 1fr); }
  .drawer:not([hidden]) { position: fixed; right: 0; top: 0; bottom: 0; width: min(520px, calc(100% - 64px)); z-index: 20; box-shadow: -18px 0 50px #20242825; }
}
@media (max-width: 1023px) {
  .app { grid-template-columns: 76px minmax(0, 1fr); }
  .side { display: flex; padding: 20px 8px 12px; }
  .side .head { padding: 0; justify-content: center; }
  .side .head > div, .side .people, .side .side-note, .side .account { display: none; }
  .ds .side .nav-item { justify-content: center; flex-direction: column; height: 56px; gap: 5px; font-size: 10px; padding: 4px; }
  .side .foot { margin-top: auto; padding: 12px 0 0; flex-direction: column; }
  .matrix { grid-template-columns: 1fr 1fr; }
  .topbar .search { width: 200px; }
}
@media (max-width: 680px) {
  .app { display: flex; flex-direction: column-reverse; height: 100dvh; }
  .app > .main { flex: 1; }
  .side { flex: none; padding: 4px 4px max(4px, env(safe-area-inset-bottom)); border-top: 1px solid var(--border-low); border-right: 0; gap: 0; }
  .side .head, .side .foot { display: none; }
  .side .nav { display: grid; grid-template-columns: repeat(5, 1fr); }
  .side .nav.people { display: none; }
  .ds .side .nav-item { height: 48px; }
  .ds .topbar { padding: 0 20px; height: 56px; gap: 10px; }
  .breadcrumb { font-size: 11px; gap: 8px; }
  .topbar .search { width: 140px; }
  .shortcut-hint { display: none; }
  .surface { padding: 0 20px 24px; }
  .page-heading { padding: 24px 0; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
  .page-heading h1 { font-size: 26px; }
  .page-heading p { font-size: 12px; }
  .page-heading .person-picker { max-width: 100%; }
  .summary { margin-bottom: 20px; }
  .stat { padding: 16px 12px; }
  .stat strong { font-size: 24px; }
  .stat span { font-size: 10px; }
  .quick .input { font-size: 16px; }
  .quick-help { font-size: 10px; }
  .ds .quick .btn { padding: 0 12px; font-size: 12px; }
  .row { gap: 8px; padding: 10px 4px; flex-wrap: wrap; }
  .row .rank { display: none; }
  .row .right { margin-left: 42px; max-width: calc(100% - 42px); width: 100%; justify-content: flex-start; gap: 8px; }
  .task-title { font-size: 13px; }
  .matrix { grid-template-columns: 1fr; }
  .drawer:not([hidden]) { width: 100%; top: 0; bottom: 0; }
  .drawer-caption { padding: 18px 20px 0; }
  .ds .drawer-head { padding: 12px 20px; }
  .ds .drawer-body { padding: 20px; }
  .drawer .title-input { font-size: 18px; }
  .drawer .fields { grid-template-columns: 72px minmax(0, 1fr); gap: 12px 8px; }
  .drawer .fields .input, .drawer .fields .select, .drawer .textarea { font-size: 16px; }
  .drawer .seg .btn { font-size: 10px; padding: 0 5px; }
  .signin { display: flex; min-height: 100dvh; align-items: center; }
  .signin-preview { display: none; }
  .signin-panel { padding: 40px 28px; }
  .signin-copy { margin-top: 64px; }
  .signin-copy h1 { font-size: 36px; }
  .pad table { font-size: 11px; }
  .pad td, .pad th { padding: 8px 4px; }
  .req { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; } }
/* Use accessible contrast for task controls and override shared stat card defaults. */
.ds .summary .stat { border: 0; border-radius: 0; box-shadow: none; background: transparent; }
.ds .summary .stat + .stat { border-left: 1px solid var(--border-low); }
.ds .group-head .t-eyebrow, .side .section, .quad .qh .sub, .quad .qh .n { color: var(--fg-2); }
.ds .btn-primary { background: var(--blue-700); }
.ds .btn-primary:hover { background: var(--blue-800); }
.ds .badge-planned { background: var(--blue-100); color: var(--blue-800); }
.ds .badge-none { color: var(--fg-2); }
.ds .row .chip { color: var(--fg-2); }
.ds .quick .hint { white-space: normal; color: var(--fg-2); }
.ds .side .nav-item.is-active small, .row.is-selected .task-open small, .row.is-selected .meta { color: var(--midnight-700); }
.ds .badge-none { background: var(--neutral-200); color: var(--fg-2); }
.ds .quad .qh .t-eyebrow, .kcard .kmeta, .pad th { color: var(--fg-2); }
.ds .btn-danger-outline { color: var(--red-900); }
.drawer .md a { color: var(--blue-700); text-decoration: underline; }
.task-dialog { width: min(420px, calc(100% - 40px)); border: 1px solid var(--border-low); border-radius: 12px; padding: 28px; color: var(--fg-high); box-shadow: var(--shadow-4); }
.task-dialog::backdrop { background: #000c2c55; }
.task-dialog h2 { font-size: 20px; margin: 0 0 12px; }
.task-dialog p { font-size: 13px; color: var(--fg-2); line-height: 1.6; margin: 0 0 20px; }
.task-dialog .input { width: 100%; height: 40px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 24px; }
.ds .seg button.is-active { color: var(--blue-800); background: var(--white); }
.ds .mobile-signout { display: none; }
@media (max-width: 680px) {
  .ds .mobile-signout { display: inline-flex; flex: none; }
  .topbar .workspace-crumb, .topbar .crumb-divider { display: none; }
  .topbar .search { width: min(160px, 45vw); }
  .drawer-caption { align-items: flex-start; }
  .drawer-caption span { max-width: 150px; text-align: right; }
}
