/* 工作秘书 · 用户端主样式（引用 tokens.css 的 canonical 变量） */

/* Reset / Base */
* { box-sizing: border-box; }
html, body, #app { min-height: 100%; margin: 0; }
body { min-width: 320px; overflow-x: hidden; background: var(--bg); color: var(--ink); }
button, textarea, input, select { font: inherit; color: inherit; }
button { border: 0; cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .46; }
h1, h2, h3, h4, p { margin-top: 0; }
h1 { margin-bottom: 6px; font-size: 28px; line-height: 1.22; letter-spacing: -.035em; font-weight: 650; }
h2 { margin-bottom: 10px; font-size: 18px; line-height: 1.35; letter-spacing: -.015em; }
h3 { margin-bottom: 8px; font-size: 15px; line-height: 1.4; }
p { margin-bottom: 10px; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
::selection { background: var(--brand-soft); }

/* Shell / Layout */
.workspace-shell { min-height: 100dvh; background: var(--bg); }
.workspace-stage { min-height: 100dvh; margin-left: var(--sidebar); }
.workspace-header {
  position: sticky; top: 0; z-index: 30; height: var(--header); padding: 0 24px;
  display: flex; align-items: center; justify-content: flex-end;
  border-bottom: 1px solid var(--line); background: rgba(246, 247, 244, .92); backdrop-filter: blur(12px);
}
.workspace-mobile-brand, .mobile-task-menu { display: none; }
.sidebar-scrim { display: none; }
.workspace-header-actions { display: flex; align-items: center; gap: 10px; min-width: 0; }
.region-badge, .account-action { color: var(--ink-faint); font-size: 12px; }
.account-action { display: flex; align-items: center; gap: 8px; }
.account-action button, .quiet-link { padding: 6px 9px; border-radius: var(--radius-sm); background: transparent; color: var(--ink-soft); }
.account-action button:hover, .quiet-link:hover { background: var(--surface-soft); color: var(--brand); }
.workspace-main { width: min(100%, calc(var(--content) + 64px)); margin: 0 auto; padding: 28px 32px 168px; }
.skip-link { position: fixed; left: 8px; top: -50px; z-index: 100; padding: 8px 12px; background: var(--brand); color: var(--brand-ink); }
.skip-link:focus { top: 8px; }

/* Sidebar */
.task-sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 40; width: var(--sidebar); padding: 18px 13px 14px;
  display: flex; flex-direction: column; gap: 6px; border-right: 1px solid var(--line); background: var(--surface-soft);
}
.secretary-identity { margin: 0 6px 14px; display: flex; align-items: center; gap: 11px; }
.secretary-mark {
  width: 31px; height: 31px; flex: 0 0 31px; display: grid; place-items: center;
  border-radius: var(--radius-sm); background: var(--brand); color: var(--brand-ink); font-weight: 700; font-family: var(--font-serif);
}
.secretary-identity strong { display: block; font-size: 14px; letter-spacing: .16em; }
.secretary-identity small { display: block; color: var(--ink-faint); font-size: 11px; letter-spacing: .04em; }
.briefing-nav {
  width: 100%; min-height: 38px; padding: 8px 10px; display: flex; align-items: center; gap: 9px;
  border-radius: var(--radius-sm); background: transparent; color: var(--ink-soft); text-align: left;
}
.briefing-nav .nav-icon { width: 18px; height: 18px; flex: 0 0 18px; color: var(--brand); }
.briefing-nav.active .nav-icon { color: var(--brand-strong); }
.briefing-nav:hover, .briefing-nav.active { background: var(--brand-soft); color: var(--brand-strong); }
.briefing-nav.active { font-weight: 600; }
.sidebar-recent { flex: 1 1 auto; min-height: 0; overflow: auto; scrollbar-width: thin; display: flex; flex-direction: column; gap: 2px; }
.task-nav-item {
  width: 100%; padding: 9px 10px; display: block; border-radius: var(--radius-sm); background: transparent; text-align: left;
}
.task-nav-item:hover, .task-nav-item.active { background: var(--surface-tint); }
.task-nav-item strong { display: block; overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 560; text-overflow: ellipsis; white-space: nowrap; }
.task-nav-item small { display: block; margin-top: 2px; overflow: hidden; color: var(--ink-faint); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.task-nav-item small span { color: var(--brand); }

/* 侧边栏：新建任务主按钮 */
.sidebar-new {
  width: 100%; min-height: 44px; margin: 2px 0 6px; padding: 0 14px;
  display: flex; align-items: center; justify-content: center; gap: 9px;
  border-radius: var(--radius-sm); background: var(--brand); color: var(--brand-ink);
  font-size: 14px; font-weight: 600; box-shadow: var(--shadow-sm);
}
.sidebar-new:hover { background: var(--brand-strong); }

/* 主导航分组 */
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }

/* 最近事项分组 */
.sidebar-section-label {
  margin: 14px 10px 4px; padding-top: 12px; border-top: 1px solid var(--line);
  color: var(--ink-faint); font-size: 11px; font-weight: 650; letter-spacing: .08em;
}
.sidebar-empty { margin: 6px 10px 0; color: var(--ink-faint); font-size: 12px; line-height: 1.6; }

/* 导航项徽标：真实待处理提醒数（0 时不渲染） */
.briefing-nav .nav-badge {
  margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px; background: var(--brand); color: var(--brand-ink);
  font-size: 11px; font-weight: 650; line-height: 1;
}

/* 侧边栏概览：只读真实统计，非按钮、非假栏目 */
.sidebar-overview {
  margin: 12px 6px 2px; padding: 10px 12px; display: flex; flex-direction: column; gap: 7px;
  border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface);
}
.overview-row { display: flex; align-items: center; justify-content: space-between; font-size: 12px; }
.overview-row span { color: var(--ink-faint); }
.overview-row strong { font-weight: 600; color: var(--ink); }
.overview-row strong.is-on { color: var(--brand); }
.overview-row strong.is-off { color: var(--ink-faint); font-weight: 500; }

/* 侧边栏真实入口：开启提醒通知（未开启时显示，复用已有 handler） */
.sidebar-notify {
  width: 100%; min-height: 38px; margin-top: 8px; padding: 8px 10px;
  display: flex; align-items: center; gap: 9px; border-radius: var(--radius-sm);
  background: transparent; color: var(--brand); text-align: left; font-size: 13px;
  border: 1px solid var(--brand-soft);
}
.sidebar-notify:hover { background: var(--brand-soft); }

/* 图标与小型印章 */
.nav-icon { width: 18px; height: 18px; flex: 0 0 18px; }

/* Home */
.secretary-home, .intake-hero { padding-top: 20px; }
.briefing-heading, .intake-hero > h1, .intake-hero > p, .intake-hero > .section-kicker { max-width: 620px; }
.briefing-heading p, .intake-hero > p { color: var(--ink-soft); }
.briefing-heading { margin-bottom: 22px; }
.home-examples, .intake-examples { display: flex; flex-wrap: wrap; gap: 7px; margin: 0 0 26px; }
.intake-examples button {
  padding: 7px 11px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: transparent; color: var(--ink-soft); font-size: 12px;
}
.intake-examples button:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); }
.briefing-section { margin-top: 22px; border-top: 1px solid var(--line); }
.briefing-section h2 { margin: 0; padding: 16px 0 8px; font-size: 13px; font-weight: 650; }
.briefing-row {
  width: 100%; min-height: 54px; padding: 9px 2px; display: flex; align-items: center; justify-content: space-between; gap: 18px;
  border-bottom: 1px solid var(--line); background: transparent; text-align: left;
}
.briefing-row:hover { color: var(--brand); }
.briefing-row span { min-width: 0; }
.briefing-row strong, .briefing-row small, .briefing-row em { display: block; }
.briefing-row strong { font-size: 13px; font-weight: 560; }
.briefing-row small, .briefing-row em { color: var(--ink-faint); font-size: 11px; font-style: normal; }
.briefing-row b { flex: 0 0 auto; color: var(--brand); font-size: 11px; font-weight: 550; }
.briefing-empty { margin-top: 32px; padding: 18px 0; border-top: 1px solid var(--line); color: var(--ink-soft); }
.briefing-empty strong { color: var(--ink); font-size: 13px; }
.briefing-empty p { margin: 3px 0 0; font-size: 12px; }
.new-task-intake { max-width: 700px; }
.intake-promise { margin-top: 24px; color: var(--ink-soft); font-size: 12px; }

/* Conversation */
.intake-conversation, .record-source { margin: 0 0 22px; padding: 0; display: flex; flex-direction: column; gap: 10px; list-style: none; }
.intake-turn { max-width: 720px; padding: 11px 13px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.intake-turn.user { align-self: flex-end; margin-left: 56px; background: var(--surface-tint); }
.intake-turn strong { display: block; margin-bottom: 4px; color: var(--brand); font-size: 11px; }
.intake-turn div, .intake-turn p { margin-bottom: 0; font-size: 13px; line-height: 1.65; }
.intake-turn.clarification { border-color: var(--brand-soft); }
.record-center { padding-top: 4px; }
.record-heading { margin-bottom: 18px; }
.record-heading p, .record-detail header p, .record-follow-up { color: var(--ink-soft); font-size: 13px; }
.record-layout { display: grid; grid-template-columns: minmax(220px, 2fr) minmax(300px, 3fr); gap: 22px; }
.record-list { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.record-row { width: 100%; padding: 11px 12px; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; border-radius: var(--radius-sm); background: transparent; text-align: left; }
.record-row:hover, .record-row.active { background: var(--surface-tint); }
.record-row span { min-width: 0; }
.record-row strong, .record-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.record-row strong { font-size: 13px; }
.record-row small, .record-row time { color: var(--ink-faint); font-size: 11px; }
.record-row time { flex: 0 0 auto; }
.record-detail { padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.record-detail h2 { margin-top: 3px; }
.record-source { margin-top: 16px; }
.record-source .intake-turn { width: 100%; margin-left: 0; }
.record-empty { padding: 18px 12px; color: var(--ink-soft); font-size: 13px; }
.record-empty p { margin: 4px 0 0; }
.case-workspace { padding-top: 2px; }
.case-heading { min-height: 78px; padding-bottom: 18px; display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; border-bottom: 1px solid var(--line); }
.case-heading h1 { font-size: 24px; }
.case-heading p { max-width: 650px; margin: 0; color: var(--ink-soft); font-size: 13px; }
.case-status-label, .section-kicker, .section-label { color: var(--brand); font-size: 11px; font-weight: 650; letter-spacing: .04em; }
.case-state-actions { display: flex; align-items: center; gap: 6px; }
.case-state-actions button { padding: 6px 9px; border-radius: var(--radius-sm); background: transparent; color: var(--ink-soft); font-size: 12px; }
.case-state-actions button:hover { background: var(--surface-soft); color: var(--brand); }
.conversation-timeline { position: relative; margin: 0; padding: 18px 0 20px 23px; list-style: none; }
.conversation-timeline::before { content: ""; position: absolute; left: 5px; top: 28px; bottom: 34px; width: 1px; background: var(--line-strong); }
.conversation-entry { position: relative; margin: 0 0 18px; padding-left: 16px; }
.conversation-entry::before { content: ""; position: absolute; left: -22px; top: 8px; width: 7px; height: 7px; border: 2px solid var(--bg); border-radius: 50%; background: var(--line-strong); }
.conversation-entry.user::before, .conversation-entry.current::before { background: var(--brand); }
.conversation-entry.user { margin-left: 72px; padding: 12px 14px; border-radius: var(--radius); background: var(--surface-tint); }
.conversation-entry.user::before { left: -94px; }
.conversation-meta { margin-bottom: 4px; display: flex; justify-content: space-between; gap: 12px; color: var(--ink-faint); font-size: 11px; }
.conversation-meta span { color: var(--brand); font-weight: 650; }
.conversation-content { max-width: 720px; color: var(--ink); font-size: 13px; }
.conversation-content > :last-child { margin-bottom: 0; }
.conversation-entry.process details, .conversation-entry.history details { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.conversation-entry summary { padding: 9px 11px; color: var(--ink-soft); font-size: 12px; cursor: pointer; }
.assignment-summary { margin: 0; padding: 0 12px 10px; list-style: none; }
.assignment-summary li { padding: 7px 0; display: grid; grid-template-columns: 80px 1fr auto; gap: 10px; border-top: 1px solid var(--line); font-size: 12px; }
.assignment-summary span, .assignment-summary small { color: var(--ink-faint); }
.secretary-brief { min-width: 0; }
.brief-judgment { margin-bottom: 14px; }
.brief-judgment p { margin: 4px 0 0; font-size: 14px; }
.care-note, .basic-mode-note { margin: 12px 0; padding: 10px 12px; border-left: 2px solid var(--brand); background: var(--surface-soft); font-size: 12px; }
.care-note p, .basic-mode-note span { margin: 2px 0 0; color: var(--ink-soft); }

/* Execution / Streaming */
.execution-panel, .stream-progress { margin: 8px 0 12px; padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.execution-panel { display: flex; align-items: center; gap: 10px; }
.execution-panel strong { display: block; font-size: 12px; }
.execution-panel p, .execution-panel small { margin: 2px 0 0; color: var(--ink-faint); font-size: 11px; }
.execution-pulse { width: 7px; height: 7px; flex: 0 0 auto; border-radius: 50%; background: var(--brand); animation: pulse 1.4s ease-in-out infinite; }
.stream-progress-head strong { display: block; font-size: 13px; }
.stream-steps { margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); list-style: none; }
.stream-steps li { position: relative; padding: 13px 5px 0 0; color: var(--ink-faint); font-size: 10px; }
.stream-steps li::before { content: ""; position: absolute; left: 5px; right: 0; top: 3px; height: 1px; background: var(--line); }
.stream-steps .step-dot { position: absolute; left: 0; top: 0; z-index: 1; width: 7px; height: 7px; border-radius: 50%; background: var(--line-strong); }
.stream-steps li.done, .stream-steps li.active { color: var(--brand); }
.stream-steps li.done .step-dot, .stream-steps li.active .step-dot { background: var(--brand); }
@keyframes pulse { 50% { opacity: .35; transform: scale(.75); } }

/* Decisions */
.decision-panel { padding: 2px 0 0; }
.decision-panel > h2 { margin: 5px 0 4px; font-size: 18px; }
.decision-why, .recommendation-reason { color: var(--ink-soft); font-size: 12px; }
.decision-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin: 14px 0 10px; }
.decision-option { padding: 13px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.decision-option.recommended { border-color: var(--brand-soft); }
.decision-option-head { display: flex; justify-content: space-between; gap: 8px; }
.decision-option-head h3 { margin: 0; }
.decision-option-head span { color: var(--brand); font-size: 10px; }
.decision-option p, .option-facts { color: var(--ink-soft); font-size: 12px; }
.option-facts ul { margin: 4px 0; padding-left: 18px; }
.decision-button, .approve-button, .primary-state-action { padding: 7px 11px; border-radius: var(--radius-sm); background: var(--brand); color: var(--brand-ink); font-size: 12px; }
.decision-button:hover, .approve-button:hover { background: var(--brand-strong); }
.defer-button { padding: 5px 0; background: transparent; color: var(--ink-faint); font-size: 11px; }

/* Deliverables */
.primary-result { padding: 14px 0 4px; }
.result-heading { margin-bottom: 10px; display: flex; justify-content: space-between; gap: 10px; }
.result-status { color: var(--ink-faint); font-size: 11px; }
.deliverable-state-banner { display: inline-flex; margin-bottom: 8px; padding: 4px 8px; border-radius: var(--radius-sm); font-size: 11px; font-weight: 600; }
.deliverable-state-banner--warning { background: var(--warn-soft); color: var(--warn); }
.deliverable-state-banner--success { background: var(--brand-soft); color: var(--brand); }
.primary-result > h2 { font-size: 18px; }
.result-summary { font-weight: 560; }
.result-body { color: var(--ink-soft); font-size: 13px; }
.result-body h3 { margin: 15px 0 5px; color: var(--ink); }
.result-body ul, .result-body ol { padding-left: 20px; }
.empty-result { padding: 16px 0; color: var(--ink-soft); font-size: 13px; }
.deliverable-card { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.dc-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 13px; }
.dc-title { margin: 0; font-size: 15px; }
.dc-head time { color: var(--ink-faint); font-size: 10px; }
.dc-status, .ws-verification, .ws-status-text { padding: 2px 6px; border-radius: var(--radius-pill); background: var(--surface-soft); color: var(--ink-soft); font-size: 10px; white-space: nowrap; }
.dc-status--approved, .ws-verification--confirmed { background: var(--brand-soft); color: var(--brand); }
.dc-status--blocked, .dc-status--rework_required, .dc-status--rejected { background: var(--danger-soft); color: var(--danger); }
.dc-status--draft, .dc-status--ready { background: var(--warn-soft); color: var(--warn); }
.ws-verification--conflicted { background: var(--danger-soft); color: var(--danger); }
.ws-verification--pending { background: var(--warn-soft); color: var(--warn); }
.dc-body, .brief-script, .brief-followup, .brief-boundary { color: var(--ink-soft); font-size: 12px; }
.brief-opening { font-weight: 600; }
.brief-script h4 { margin: 12px 0 4px; color: var(--ink); }
.brief-keys, .rc-metrics { margin: 12px 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; list-style: none; }
.brief-keys li, .rc-metric { padding: 9px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.bk-label, .rc-metric-label, .rc-metric-status { display: block; color: var(--ink-faint); font-size: 10px; }
.bk-value, .rc-metric-value { display: block; margin-top: 2px; font-size: 16px; font-weight: 620; }
.rc-head { display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: baseline; }
.rc-title { margin: 0; font-size: 16px; }
.rc-period, .rc-role, .rc-data-status { color: var(--ink-faint); font-size: 10px; }
.rc-block { margin-top: 12px; }
.rc-block h3 { margin-bottom: 4px; font-size: 12px; }
.rc-list, .qp-list { margin: 0; padding-left: 19px; font-size: 12px; }
.rc-charts { margin-top: 12px; }
.rc-chart { margin: 0; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.rc-chart p { margin: 3px 0 0; color: var(--ink-faint); font-size: 11px; }
.dc-actions, .dc-feedback { margin-top: 12px; padding-top: 10px; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; border-top: 1px solid var(--line); }
.dc-actions button, .dc-fb { padding: 4px 7px; border-radius: var(--radius-sm); background: var(--surface-soft); color: var(--ink-soft); font-size: 10px; }
.dc-actions button:hover, .dc-fb:hover { background: var(--brand-soft); color: var(--brand); }
.dc-feedback-label { color: var(--ink-faint); font-size: 10px; }
.dc-fb-note { min-width: 150px; flex: 1 1 160px; padding: 5px 7px; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 11px; }
.supporting-materials, .adopted-decision, .next-move { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.supporting-materials > h3 { font-size: 12px; }
.supporting-list { display: grid; gap: 5px; padding: 0 10px 10px; }
.supporting-materials .supporting-list { padding: 0; }
.supporting-list button { padding: 8px 9px; display: grid; grid-template-columns: 86px 1fr auto; gap: 10px; border-radius: var(--radius-sm); background: var(--surface-soft); text-align: left; }
.supporting-list button:hover { background: var(--brand-soft); }
.supporting-list span, .supporting-list small { color: var(--ink-faint); font-size: 10px; }
.supporting-list strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }

/* Composer */
.problem-composer {
  position: fixed; z-index: 28; left: calc(var(--sidebar) + (100vw - var(--sidebar)) / 2); bottom: 16px;
  width: min(var(--composer), calc(100vw - var(--sidebar) - 48px)); transform: translateX(-50%);
  padding: 10px 12px 11px; border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: rgba(255, 255, 255, .97); box-shadow: var(--shadow-float);
}
.problem-composer > label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.composer-context { min-height: 18px; display: flex; align-items: center; gap: 8px; color: var(--ink-faint); font-size: 10px; }
.composer-context strong { color: var(--brand); font-size: 11px; }
.composer-context span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.composer-row { display: flex; align-items: flex-end; gap: 8px; }
.composer-row textarea { width: 100%; min-height: 35px; max-height: 150px; padding: 8px 2px 5px; resize: none; border: 0; outline: 0; background: transparent; font-size: 13px; line-height: 1.5; }
.composer-row textarea::placeholder { color: var(--ink-faint); }
.composer-row button { width: 58px; height: 32px; flex: 0 0 auto; border-radius: var(--radius-sm); background: var(--brand); color: var(--brand-ink); font-size: 12px; }

/* Drawer / Dialog */
.ws-drawer-backdrop, .dialog-backdrop { position: fixed; inset: 0; z-index: 80; background: rgba(20, 30, 25, .2); }
.ws-drawer { position: absolute; inset: 0 0 0 auto; width: min(392px, 100vw); display: flex; flex-direction: column; background: var(--surface); box-shadow: -14px 0 36px rgba(18, 38, 29, .12); }
.ws-drawer-head { min-height: 70px; padding: 15px 17px; display: flex; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); }
.ws-drawer-head span { color: var(--brand); font-size: 10px; }
.ws-drawer-head h2 { margin: 2px 0 0; font-size: 16px; }
.ws-drawer-head button, .dialog-close { width: 30px; height: 30px; border-radius: 50%; background: var(--surface-soft); color: var(--ink-soft); }
.ws-drawer-scroll { overflow: auto; padding: 0 17px 28px; }
.ws-section { padding: 15px 0; border-bottom: 1px solid var(--line); }
.ws-h { margin: 0 0 9px; font-size: 12px; }
.ws-h small { margin-left: 5px; color: var(--ink-faint); font-size: 9px; font-weight: 400; }
.ws-task-title { display: block; margin-bottom: 5px; font-size: 13px; }
.ws-task p, .ws-definition, .ws-task dl { margin: 4px 0; color: var(--ink-soft); font-size: 11px; }
.ws-task dl, .ws-definition div { display: grid; grid-template-columns: 66px 1fr; gap: 8px; }
.ws-task dt, .ws-definition dt { color: var(--ink-faint); }
.ws-task dd, .ws-definition dd { margin: 0; }
.ws-list { margin: 0; padding: 0; list-style: none; }
.ws-item { padding: 7px 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); }
.ws-item:first-child { border-top: 0; }
.ws-item strong, .ws-item small { display: block; }
.ws-item strong { font-size: 11px; font-weight: 550; }
.ws-item small, .ws-empty { color: var(--ink-faint); font-size: 10px; }
.deliverable-dialog, .reminder-dialog { position: relative; width: min(720px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); margin: 16px auto; padding: 22px; overflow: auto; border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-float); }
.deliverable-dialog > .dialog-close, .reminder-dialog > .dialog-close { position: absolute; top: 12px; right: 12px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

/* Reminders / Notices */
.reminder-center { max-width: 760px; }
.reminder-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.reminder-heading h1 { font-size: 24px; }
.reminder-heading p { color: var(--ink-soft); font-size: 12px; }
.reminder-section { margin-top: 18px; }
.reminder-section h2 { font-size: 12px; }
.reminder-row { min-height: 48px; padding: 8px 2px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.reminder-row strong, .reminder-row small { display: block; }
.reminder-row strong { font-size: 12px; }
.reminder-row small { color: var(--ink-faint); font-size: 10px; }
.reminder-actions { position: relative; display: flex; gap: 5px; }
.reminder-actions button, .notification-invite button { padding: 5px 8px; border-radius: var(--radius-sm); background: var(--surface-soft); font-size: 10px; }
.reminder-menu { position: absolute; top: 34px; right: 0; z-index: 5; width: 160px; padding: 5px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); box-shadow: var(--shadow-float); }
.reminder-menu button { width: 100%; text-align: left; }
.notification-invite, .request-notice, .system-notice { padding: 9px 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); background: var(--surface-soft); font-size: 11px; }
.system-notice { position: relative; z-index: 24; margin-left: 0; }
.system-notice div { display: flex; gap: 8px; }
.system-notice span { color: var(--ink-soft); }
.request-notice { margin-bottom: 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.workspace-toast { position: fixed; z-index: 100; right: 18px; bottom: 18px; max-width: 340px; padding: 9px 12px; border-radius: var(--radius-sm); background: var(--ink); color: var(--ink-invert); font-size: 11px; }

/* Responsive */
@media (max-width: 760px) {
  :root { --header: 50px; }
  h1 { font-size: 24px; }
  .task-sidebar { width: min(278px, 86vw); transform: translateX(-105%); transition: transform var(--dur) var(--ease); box-shadow: 10px 0 28px rgba(18, 38, 29, .14); }
  .task-sidebar.open { transform: translateX(0); }
  .sidebar-scrim { position: fixed; inset: 0; z-index: 35; display: block; background: rgba(20, 30, 25, .2); }
  .workspace-stage { margin-left: 0; }
  .workspace-header { padding: 0 12px; justify-content: space-between; }
  .workspace-mobile-brand { display: flex; align-items: center; gap: 8px; font-size: 12px; }
  .workspace-mobile-brand .secretary-mark { width: 26px; height: 26px; flex-basis: 26px; border-radius: var(--radius-sm); }
  .mobile-task-menu { display: block; order: -1; width: 32px; height: 32px; border-radius: var(--radius-sm); background: var(--surface-soft); font-size: 0; }
  .mobile-task-menu::after { content: "☰"; font-size: 15px; }
  .workspace-header-actions { margin-left: auto; }
  .region-badge, .account-action span { display: none; }
  .workspace-main { padding: 18px 16px 154px; }
  .secretary-home, .intake-hero { padding-top: 8px; }
  .case-heading { min-height: 68px; }
  .case-heading h1 { font-size: 21px; }
  .case-heading p { display: none; }
  .case-state-actions button:not(.quiet-link) { display: none; }
  .conversation-timeline { padding-left: 17px; }
  .conversation-timeline::before { left: 3px; }
  .conversation-entry { padding-left: 11px; }
  .conversation-entry::before { left: -17px; }
  .conversation-entry.user { margin-left: 22px; }
  .conversation-entry.user::before { left: -39px; }
  .record-layout { grid-template-columns: 1fr; }
  .intake-turn.user { margin-left: 22px; }
  .decision-options { grid-template-columns: 1fr; }
  .brief-keys, .rc-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .problem-composer { left: 50%; bottom: max(8px, env(safe-area-inset-bottom)); width: calc(100vw - 16px); }
  .composer-context span { max-width: 220px; }
  .stream-steps { grid-template-columns: repeat(3, 1fr); row-gap: 8px; }
  .assignment-summary li, .supporting-list button { grid-template-columns: 72px 1fr; }
  .assignment-summary small, .supporting-list small { grid-column: 2; }
  .dc-feedback { align-items: stretch; }
  .dc-fb-note { flex-basis: 100%; }
  .deliverable-dialog { padding: 17px 14px; }
}

@media (max-width: 560px) {
  .workspace-header-actions .quiet-link { display: none; }
  .workspace-main { padding-inline: 12px; }
  .case-heading { gap: 10px; }
  .case-state-actions { flex: 0 0 auto; }
  .case-state-actions .quiet-link { padding-inline: 6px; }
  .conversation-entry.user { margin-left: 10px; }
  .conversation-entry.user::before { left: -27px; }
  .brief-keys, .rc-metrics { grid-template-columns: 1fr 1fr; }
  .ws-drawer { width: 100vw; }
}

/* Print */
@media print {
  :root { --bg: white; }
  .task-sidebar, .workspace-header, .problem-composer, .case-state-actions, .dc-actions, .dc-feedback, .workspace-toast, .system-notice { display: none !important; }
  .workspace-stage { margin: 0; }
  .workspace-main { width: 100%; padding: 0; }
  .conversation-timeline::before, .conversation-entry::before { display: none; }
  .conversation-entry { break-inside: avoid; padding-left: 0; }
  .conversation-entry details { border: 0; }
  .conversation-entry details > * { display: block; }
  .deliverable-card { break-inside: avoid; }
}
