/* Shared reading scale. Use installed fonts; no remote font/CDN dependency. */
:root {
  font-family: "Noto Sans SC", "MiSans", "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  font-size:16px;
  line-height:1.7;
  font-weight:400;
  color:#30394b;
  --text-caption:.8125rem;
  --text-small:.875rem;
  --text-body:1rem;
  --text-title:1.0625rem;
  --text-muted:#647084;
}
button, input, select, textarea { font-family:inherit; line-height:1.6; }
button { font-weight:500; }
input, select, textarea,
.task-primary input, .task-primary select,
.scope-controls input, .scope-controls select,
.history textarea, .quick-form input { font-size:var(--text-body); font-weight:400; }
input::placeholder, textarea::placeholder { color:#737d8e; opacity:1; }
textarea { line-height:1.8; }
label, .task-primary label, .scope-controls label, .dependency-filters label {
  font-size:var(--text-small); font-weight:500; color:#566277;
}
h1 { font-size:1.75rem; font-weight:600; line-height:1.45; }
h2, .dialog-head h2 { font-size:1.4375rem; font-weight:600; }
h3 { font-size:var(--text-title); font-weight:600; }
.subtitle { font-size:var(--text-small); line-height:1.75; }
.eyebrow { font-size:var(--text-caption); letter-spacing:0; }
.brand { font-size:1.0625rem; font-weight:600; }
.brand small { font-size:.75rem; letter-spacing:0; }
.sidebar nav button { font-size:var(--text-body); min-height:45px; }
.sidebar nav i, .sidebar-bottom, .sidebar-bottom small { font-size:.75rem; }
.sidebar-bottom .text-button { font-size:var(--text-caption); }
.metric .metric-label { font-size:var(--text-small); font-weight:500; }
.metric strong { font-size:2rem; font-weight:600; }
.metric em { font-size:var(--text-caption); }
.chips button, .text-button, .small, .section-hint, .notice, .toast { font-size:var(--text-small); }
.chips button span { font-size:var(--text-caption); }
.filters label { min-width:0; }
.filters input, .filters select { min-width:0; }
.task-grid { grid-template-columns:repeat(auto-fill,minmax(min(100%,290px),1fr)); }
.task-name, .task-card > .task-name { font-size:var(--text-title); font-weight:600; line-height:1.65; }
.card-top, .model-line, .project-tag, .kind-tag,
.task-bottom > span, .task-card details, .badge, .sub-row .badge { font-size:var(--text-caption); }
.shared-mark { font-size:.75rem; }
.card-owner { line-height:1.7; }
.card-note { font-size:var(--text-small); line-height:1.8; max-height:5.4em; }
.sub-row .task-name { font-size:var(--text-small); font-weight:500; }
.branch-title strong, .tree-body .branch-title strong { font-size:var(--text-title); font-weight:600; }
.tree-task .branch-title strong { font-size:var(--text-body); font-weight:500; }
.branch-meta, .independent-entry p { font-size:var(--text-caption); }
.task-description, .note-body { font-size:var(--text-body); line-height:1.8; }
.independent-entry strong, .empty strong, .archive-row strong { font-size:var(--text-body); font-weight:600; }
.empty p, .archive-row p, .login-card p, #confirm-dialog p { font-size:var(--text-small); }
.form-help, .quick-form .error, .field-details, .project-choice { font-size:var(--text-caption); }
.page-footer { font-size:.75rem; color:var(--text-muted); }

/* Keep model identifiers and daily actions easy to scan in the larger form. */
.task-primary { gap:17px; }
.scope-overview-top, .scope-edit-label, .scope-extra,
.scope-picker > summary small { font-size:var(--text-caption); }
.scope-model strong { font-size:1.125rem; font-weight:600; }
.scope-model em { font-size:.75rem; color:var(--text-muted); }
.scope-model b { font-size:var(--text-body); font-weight:500; }
.multiple .scope-model strong { font-size:var(--text-body); }
.multiple .scope-model b { font-size:var(--text-small); }
.scope-independent { font-size:var(--text-small); }
.scope-selected-head strong, .scope-selected-head > span, .scope-selected-head button,
.selected-project, .scope-list-head, .scope-list-head button,
.scope-lock, .scope-empty span, .scope-footnote { font-size:var(--text-caption); }
.scope-option strong, .scope-empty strong { font-size:var(--text-small); font-weight:500; }
.scope-option small { font-size:var(--text-caption); }
.scope-results { max-height:300px; }
.panel-title { flex-wrap:wrap; }
.panel-title h3 { font-size:var(--text-body); font-weight:600; }
.panel-title .text-button { font-size:var(--text-caption); }
.dependency-message, .dependency-card-hint { font-size:var(--text-small); line-height:1.7; }
.prerequisite-row .task-name { font-size:var(--text-small); font-weight:600; }
.prerequisite-row small, .prerequisite-row .badge,
.dependency-picker > summary, .dependency-picker > summary span,
#dependency-result-count, .dependency-option small, .dependency-option .badge { font-size:var(--text-caption); }
.dependency-option strong { font-size:var(--text-small); font-weight:500; }
.editor-secondary > summary { font-size:var(--text-small); font-weight:500; }
.editor-secondary > summary span { font-size:var(--text-caption); }
.actual-details, .history details { font-size:var(--text-caption); }
.history h3, .history .processing-records h3 { font-size:var(--text-title); font-weight:600; }
.history-item, .legacy-body { font-size:var(--text-small); line-height:1.8; }
.history-item time, .session, .history .empty-logs { font-size:var(--text-caption); }
.history-section > summary { font-size:var(--text-small); font-weight:500; }
.history pre { font-size:.75rem; line-height:1.75; }
.dialog-actions button { font-size:var(--text-body); }

/* Secondary text stays quiet without relying on tiny, pale lettering. */
.subtitle, .eyebrow, .model-line, .branch-meta, .form-help,
.scope-extra, .scope-selected-head > span, .scope-footnote,
.prerequisite-row small, .dependency-option small,
.editor-secondary > summary span, .actual-details,
.history details, .history-item time, .session { color:var(--text-muted); }

/* More breathing room in each day; expanded items still wrap and scroll. */
.calendar-weekend-options label { font-size:var(--text-small); }
.weekdays span { font-size:var(--text-small); font-weight:500; color:#626f83; }
.day { min-height:146px; padding:10px; }
.day time { font-size:var(--text-small); font-weight:500; color:#66748a; }
.day.outside time { color:#a3adbb; }
.personal-intro strong { font-size:var(--text-body); }
.personal-intro p, .project-note p { font-size:var(--text-small); line-height:1.75; }
.project-notes-head > span { font-size:var(--text-small); }
.project-notes-head small, .project-note > div:first-child > span, .selected-note-project small { font-size:var(--text-caption); }
.selected-note-project strong { font-size:var(--text-small); }
.calendar-day-tasks .calendar-item {
  font-size:var(--text-small); font-weight:500; line-height:1.65; padding:4px 6px;
}
.calendar-expand { font-size:var(--text-caption); font-weight:500; padding:5px 2px; }
.calendar-selection h3 { font-size:var(--text-title); }

/* Maintain a shared axis while giving the task column enough room to read. */
.gantt-toolbar .chips button { font-size:var(--text-small); }
.gantt-month-controls input { font-size:var(--text-body); width:170px; }
.gantt-toolbar-options > label, .gantt-toolbar-options select { font-size:var(--text-small); }
.gantt-summary, .gantt-hidden-notice { font-size:var(--text-small); }
.gantt-summary strong { font-size:var(--text-body); }
.gantt-legend { font-size:var(--text-caption); }
.gantt-table { --gantt-label-width:350px; }
.gantt-table thead th, .gantt-dates { height:60px; }
.gantt-table thead .gantt-task-cell { font-size:var(--text-small); }
.gantt-table thead .gantt-task-cell small { font-size:var(--text-caption); }
.gantt-date b { font-size:var(--text-small); line-height:24px; }
.gantt-date small { font-size:.75rem; color:#687387; }
.gantt-group strong { font-size:var(--text-small); }
.gantt-group button span { font-size:.75rem; }
.gantt-group-meta { font-size:var(--text-caption); }
.gantt-task-row .task-name {
  font-size:var(--text-small); font-weight:600; line-height:1.5; max-height:3em;
}
.gantt-task-context { font-size:var(--text-caption); color:var(--text-muted); }
.gantt-task-meta { font-size:.75rem; min-height:19px; color:var(--text-muted); }
.gantt-task-meta .badge, .gantt-blocker { font-size:.75rem; }
.gantt-task-row td { height:88px; }
.gantt-track { height:88px; min-height:88px; }
.gantt-track-message, .gantt-track-message button { font-size:var(--text-caption); }
.gantt-extra > summary { font-size:var(--text-small); }
.gantt-extra > summary span, .gantt-extra-row small { font-size:var(--text-caption); }
.gantt-extra-row .task-name { font-size:var(--text-body); }
.gantt-table thead .gantt-task-cell small, .gantt-track-message,
.gantt-extra > summary span, .gantt-extra-row small { color:var(--text-muted); }

@media (max-width:1050px) and (min-width:701px) {
  .shell { grid-template-columns:205px minmax(0,1fr); }
  .filters { flex-wrap:wrap; }
  .filters .search { flex:1 0 100%; }
}
@media (max-width:700px) {
  h1 { font-size:1.5rem; }
  .header-actions { max-width:170px; }
  .header-actions button, .filters > .text-button { font-size:var(--text-caption); }
  .sidebar nav button { font-size:var(--text-small); }
  .brand { font-size:var(--text-body); }
  .subtitle { font-size:var(--text-caption); }
  .metric .metric-label { font-size:var(--text-caption); }
  .metric strong { font-size:1.875rem; }
  .day { padding:7px 4px; min-height:134px; }
  .calendar-day-tasks .calendar-item { font-size:var(--text-caption); padding:3px; }
  .weekdays span { padding:10px 2px; }
  .gantt-table { --gantt-label-width:250px; }
  .gantt-toolbar-options select { font-size:var(--text-body); }
}
