/* Shared reading scale. Editor source, presentation canvases and SVG geometry
   keep their own scales; these tokens govern the surrounding product UI. */
:root {
  --kompani-text-body:.9375rem;
  --kompani-text-control:.875rem;
  --kompani-text-secondary:.8125rem;
  --kompani-text-caption:.8125rem;
  --kompani-reading-line:1.5;
}
body.kompani-platform {font-size:var(--kompani-text-body);line-height:var(--kompani-reading-line);text-size-adjust:100%;-webkit-text-size-adjust:100%}

/* Page copy and field values: preserve color/theme and larger headings. */
body.kompani-platform :is(
  .software-operation-workbench,.workspace-panel-layout,.operation-os,.os-app-launcher,.personal-space,.personal-home,.joint-calendar,
  .resource-page,.billing-page,.account-settings-page,.account-usage,.account-appearance-settings,
  .ai-workspace,.ai-dock,.need-chat,.run-activity,.workspace-pulse,.life-feed,
  .pm-module,.project-work-list,.project-resources,.hub-content,.software-modal,
  .workspace-menu-dialog,.document-library,.vc-workbench,.version-control-page,
  .module-tools,.knowledge-tools,.operational-tools,.capability-configuration,
  .capability-launcher,.business-portfolio,.power-workbench,.work-performance,
  .investor-page,.invest-market,.venture-preparation,.venture-preview,.exchange-shell,
  .messenger-page,.collab-shell,.conversation,.organization-chat,.customer-ai-studio,
  .private-research-shell,.thesis-workbench,.adaptive-runtime-studio,.studio-source,.shared-research-reviews,.research-review-card,.delivery-studio,
  .studio,.lab,.development-home,.cloud-workspace,.full-workbench,.workbench-allocations,
  .demo-center,.native-demo,.process-demo,.object-explorer,.business-process-designer,
  .business-workflows,.connector-panel,.bi-demo,.business-intelligence-page,
  .home-setup-shell,.access-page,.invitation-welcome-page,.work-shell,.platform-mail,.platform-mail-modal,
  .access-card,.onboarding-form,.onboarding-intro,.company-setup,.publication-form
) {font-size:var(--kompani-text-body);line-height:1.55}

body.kompani-platform :is(
  .software-operation-workbench,.workspace-panel-layout,.operation-os,.os-app-launcher,.personal-space,.personal-home,.joint-calendar,
  .resource-page,.billing-page,.account-settings-page,.account-usage,.ai-workspace,.ai-dock,.need-chat,
  .run-activity,.workspace-pulse,.life-feed,.pm-module,.project-work-list,.project-resources,
  .hub-content,.software-modal,.document-library,.vc-workbench,.version-control-page,
  .module-tools,.knowledge-tools,.operational-tools,.capability-configuration,
  .capability-launcher,.business-portfolio,.power-workbench,.work-performance,
  .investor-page,.invest-market,.venture-preparation,.venture-preview,.exchange-shell,
  .messenger-page,.collab-shell,.conversation,.organization-chat,.customer-ai-studio,
  .private-research-shell,.thesis-workbench,.adaptive-runtime-studio,.studio-source,.shared-research-reviews,.research-review-card,.delivery-studio,
  .studio,.lab,.development-home,.cloud-workspace,.full-workbench,
  .demo-center,.native-demo,.process-demo,.object-explorer,.business-process-designer,
  .business-workflows,.connector-panel,.bi-demo,.business-intelligence-page,
  .home-setup-shell,.access-page,.invitation-welcome-page,.work-shell,.platform-mail,.platform-mail-modal,
  .access-card,.onboarding-form,.onboarding-intro,.company-setup,.publication-form
) :is(p,li,td,dd):not(:where(pre *,code *,svg *,[contenteditable] *,
  .slide-canvas *,.slide-stage *,.slides-stage *,.nd-slide-stage *,.ide-code *,.ide-gutter *,
  .process-kpis dd,.inspector-metrics dd,.conformance-counts dd,.process-quality-metrics dd,
  .demo-metrics dd,.metric-grid dd)) {
  font-size:var(--kompani-text-body)!important;line-height:var(--kompani-reading-line)!important;
}

/* Controls remain usable at narrow widths and browser zoom. Source editors are
   excluded so their gutter, caret, syntax and chosen font remain synchronized. */
body.kompani-platform :is(
  .software-operation-workbench,.workspace-panel-layout,.operation-os,.os-app-launcher,.personal-space,.personal-home,.joint-calendar,
  .resource-page,.billing-page,.account-settings-page,.account-usage,.account-appearance-settings,
  .ai-workspace,.ai-dock,.need-chat,.workspace-pulse,.life-feed,.pm-module,
  .project-work-list,.project-resources,.hub-content,.software-modal,.workspace-menu-dialog,
  .document-library,.vc-workbench,.version-control-page,.module-tools,.knowledge-tools,
  .operational-tools,.capability-configuration,.capability-launcher,.business-portfolio,
  .power-workbench,.investor-page,.invest-market,.venture-preparation,.venture-preview,
  .exchange-shell,.messenger-page,.collab-shell,.conversation,.organization-chat,
  .customer-ai-studio,.private-research-shell,.thesis-workbench,.adaptive-runtime-studio,.studio-source,.shared-research-reviews,.delivery-studio,
  .studio,.lab,.development-home,.cloud-workspace,.full-workbench,.workbench-allocations,
  .slides-app,.demo-center,.native-demo,.process-demo,.object-explorer,.business-process-designer,
  .business-workflows,.connector-panel,.bi-demo,.business-intelligence-page,
  .home-setup-shell,.access-page,.invitation-welcome-page,.work-shell,.platform-mail,.platform-mail-modal,
  .access-card,.onboarding-form,.company-setup,.publication-form
) :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]),
  select,textarea:not([spellcheck=false]):not(.ide-code):not(.vc-editor):not(.nd-code-input)) {
  font-size:var(--kompani-text-control)!important;line-height:1.35!important;
  min-height:32px;min-width:0;max-width:100%;
}
body.kompani-platform :is(
  .software-operation-workbench,.workspace-panel-layout,.operation-os,.os-app-launcher,.personal-space,.joint-calendar,.resource-page,.billing-page,
  .account-settings-page,.account-usage,.account-appearance-settings,.ai-workspace,.ai-dock,
  .need-chat,.workspace-pulse,.life-feed,.pm-module,.project-work-list,.project-resources,
  .hub-content,.software-modal,.workspace-menu-dialog,.document-library,.vc-workbench,
  .version-control-page,.module-tools,.knowledge-tools,.operational-tools,
  .capability-configuration,.capability-launcher,.business-portfolio,.power-workbench,
  .investor-page,.invest-market,.venture-preparation,.venture-preview,.exchange-shell,
  .messenger-page,.collab-shell,.conversation,.organization-chat,.customer-ai-studio,
  .private-research-shell,.thesis-workbench,.adaptive-runtime-studio,.studio-source,.shared-research-reviews,.delivery-studio,.studio,.lab,
  .development-home,.cloud-workspace,.full-workbench,.slides-app,.demo-center,.native-demo,
  .process-demo,.object-explorer,.business-process-designer,.business-workflows,
  .connector-panel,.bi-demo,.business-intelligence-page,.home-setup-shell,.access-page,.invitation-welcome-page,.work-shell,.platform-mail,.platform-mail-modal,
  .access-card,.onboarding-form,
  .company-setup,.publication-form
) :is(button:not([aria-label]):not(.bpd-node):not(.calendar-day):not(.nd-sticky),summary) {
  font-size:var(--kompani-text-control)!important;line-height:1.35!important;min-height:32px;
}
body.kompani-platform :is(.primary,.secondary,.text-button,.vc-button,.today-primary,
  .work-shortcut,.studio-primary,.platform-mail-compose,.ide-primary,.demo-secondary,
  .bi-secondary,.bi-primary,.resource-back,.settings-resource-action) {
  font-size:var(--kompani-text-control)!important;line-height:1.35!important;
}
body.kompani-platform :is(
  .software-operation-workbench,.workspace-panel-layout,.operation-os,.os-app-launcher,.personal-space,.joint-calendar,.resource-page,.billing-page,
  .account-settings-page,.account-usage,.account-appearance-settings,.ai-workspace,.ai-dock,
  .need-chat,.workspace-pulse,.life-feed,.pm-module,.project-resources,.hub-content,
  .software-modal,.document-library,.vc-workbench,.version-control-page,.module-tools,
  .knowledge-tools,.operational-tools,.capability-configuration,.capability-launcher,
  .business-portfolio,.power-workbench,.investor-page,.invest-market,.venture-preparation,
  .exchange-shell,.messenger-page,.collab-shell,.customer-ai-studio,.private-research-shell,.thesis-workbench,.adaptive-runtime-studio,.studio-source,
  .shared-research-reviews,.delivery-studio,.studio,.lab,.development-home,.cloud-workspace,
  .full-workbench,.slides-app,.demo-center,.native-demo,.process-demo,.object-explorer,
  .business-process-designer,.business-workflows,.connector-panel,.bi-demo,.business-intelligence-page,
  .home-setup-shell,.access-page,.invitation-welcome-page,.work-shell,.platform-mail,.platform-mail-modal,
  .access-card,.onboarding-form,.company-setup,.publication-form
) :is(label,legend,dt,th) {font-size:var(--kompani-text-secondary)!important;line-height:1.5!important}

/* Secondary prose, timestamps and captions have a readable shared floor. */
body.kompani-platform :is(
  .software-operation-workbench,.workspace-panel-layout,.operation-os,.os-app-launcher,.personal-space,.joint-calendar,.resource-page,.billing-page,
  .account-settings-page,.account-usage,.ai-workspace,.ai-dock,.need-chat,.run-activity,
  .workspace-pulse,.life-feed,.pm-module,.hub-content,.software-modal,.document-library,
  .vc-workbench,.version-control-page,.module-tools,.knowledge-tools,.operational-tools,
  .capability-configuration,.capability-launcher,.business-portfolio,.power-workbench,
  .work-performance,.investor-page,.invest-market,.venture-preparation,.exchange-shell,
  .messenger-page,.collab-shell,.conversation,.organization-chat,.customer-ai-studio,
  .private-research-shell,.thesis-workbench,.adaptive-runtime-studio,.studio-source,.shared-research-reviews,.delivery-studio,.studio,.lab,
  .development-home,.cloud-workspace,.full-workbench,.slides-app,.demo-center,.native-demo,
  .process-demo,.object-explorer,.business-process-designer,.business-workflows,
  .connector-panel,.bi-demo,.business-intelligence-page,.home-setup-shell,.access-page,.invitation-welcome-page,.work-shell,.platform-mail,.platform-mail-modal,
  .access-card,.onboarding-form
) :is(small,time):not(:where(svg *,.bpd-node *,.slide-canvas *,.slide-stage *,.slides-stage *)) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.5!important;
}
body.kompani-platform :is(.eyebrow,.personal-eyebrow,.os-eyebrow,.vc-eyebrow,.studio-eyebrow,
  .ai-eyebrow,.ai-dock-eyebrow,.calendar-eyebrow,.workspace-search-category,.workspace-search-results>header,
  .demo-eyebrow,.bi-eyebrow,.bid-eyebrow,.oe-eyebrow,.bpd-eyebrow,.bw-eyebrow,.cp-eyebrow,
  .os-task-status,.feed-post-category,.feed-unread-mark,.resource-badge,.count-badge,
  .run-state,.run-model,.run-time,.ai-message time,.ai-sidebar-foot,.ai-chat-heading>span,
  .ai-model-note,.resource-timestamp,.resource-scope-note,.chart-scale,.chart-footer,.daily-data,
  .calendar-weekdays,.calendar-cell-event,.calendar-extra,.calendar-privacy,.calendar-notice,
  .feed-schedule-status,.feed-source-status,.life-feed-caption,.personal-result-count,
  .personal-reminder-copy,.os-app-scope,.os-library-group>header>span,.demo-status,.catalog-count) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.5!important;
  overflow-wrap:anywhere;letter-spacing:normal;
}

/* Dense cards and feeds previously overrode their parent at 9–12 px. */
body.kompani-platform :is(.os-work-copy strong,.personal-recent-note strong,.personal-quick-links strong,
  .feed-post-header strong,.life-story header strong,.ai-history-row strong,.ai-sidebar-title strong,
  .agent-card header strong,.run-summary>strong,.demo-catalog-item strong,.os-library-card h4,
  .workspace-search-results strong,.resource-alert h3,.nd-ticket>strong,.nd-calendar-event strong,
  .nd-person>strong,.nd-record-gallery strong) {font-size:var(--kompani-text-control)!important;line-height:1.5!important}
body.kompani-platform :is(.os-work-copy small,.os-signal-grid article>span,.os-project-card small,
  .os-project-card footer>span,.os-project-card>p,.os-library-card-heading small,.os-library-card>p,
  .personal-quick-links small,.personal-recent-note small,.personal-recent-note p,.feed-post-header small,
  .feed-post-body small,.life-story header small,.life-story footer>small,.ai-message header,
  .ai-chat-heading>span,.ai-history-row small,.ai-sidebar-title span,.run-usage>span,.run-usage small,
  .demo-catalog-item small,.demo-center code,.nd-session,.nd-badge,.nd-state,.nd-route-result,
  .settings-resource-card small,.resource-metric>span:first-child,.resource-metric small,
  .panel-heading>a,.chart-column small,.resource-page th,.workspace-search-results small,
  .notification-inbox small,.notification-guidance,.notification-inbox time) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.5!important;
}
body.kompani-platform :is(.workspace-search-field input,.platform-project-picker select,
  .platform-workspace-picker .workspace-navigator select) {font-size:var(--kompani-text-control)!important;line-height:1.35!important;min-height:32px}
body.kompani-platform :is(.platform-account-menu>summary,.platform-account-menu nav>a,
  .platform-account-menu nav>strong,.platform-current-app,.platform-updates .notification-launcher strong,
  .workspace-service-summary p,.workspace-service-summary small,.operation-calendar p,.oc-calendar small) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.35!important;
}
body.kompani-platform :is(.ai-dock-main strong,.ai-dock-heading-copy>strong,.ai-dock-function-grid strong) {font-size:var(--kompani-text-control)!important;line-height:1.4!important}
body.kompani-platform :is(.ai-dock-main small,.ai-dock-heading-copy>span:last-child,.ai-dock-bar-item,
  .ai-dock-bar-item b,.ai-dock-function-grid small,.ai-dock-boundary,.ai-dock-tabs span) {font-size:var(--kompani-text-secondary)!important;line-height:1.35!important}
body.kompani-platform :is(.os-signal-grid article,.personal-quick-links>a,.personal-quick-links>button,
  .os-work-copy,.resource-toolbar>label,.resource-metric,.demo-catalog-item>span:last-child) {min-width:0}
body.kompani-platform :is(.personal-heading,.personal-footer,.panel-heading,.resource-toolbar,
  .os-project-card footer,.os-work-queue>header,.os-projects-preview>header,.demo-result-toolbar,
  .bi-scope-toolbar,.oe-panel-heading,.bpd-panel>header) {flex-wrap:wrap}

@media(max-width:760px) {
  body.kompani-platform :is(.personal-tabs,.calendar-month-controls,.ai-heading-actions,
    .platform-account-menu nav,.workspace-search-results,.demo-catalog,.resource-toolbar) {min-width:0;max-width:100%}
  body.kompani-platform :is(.os-project-card footer,.personal-footer,.resource-toolbar,.ai-heading-actions) {gap:10px;flex-wrap:wrap}
  body.kompani-platform :is(.os-library-grid,.personal-quick-links,.resource-metrics) {grid-template-columns:repeat(auto-fit,minmax(min(100%,190px),1fr))}
  body.kompani-platform :is(.resource-panel,.account-usage,.personal-items,.personal-editor,.demo-stage,.bi-panel) {min-width:0}
}

/* Operation-center labels remain legible independently of the older hub shell. */
body.kompani-platform :is(.oc-progress-legend,.oc-progress-legend strong,.oc-project-progress-heading>span,
  .oc-status,.oc-current-project,.oc-feed-title>span,.oc-app-overview>header>span,.oc-progress-note,
  .oc-next-ticket small,.oc-work-filters,.oc-work-filters span,.oc-progress-totals>div>span,
  .oc-progress-ring span,.oc-work-table td>span,.oc-project-choice label) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.5!important;
}
body.kompani-platform :is(.oc-work-table,.oc-work-table td,.oc-work-table td>strong,
  .oc-next-ticket strong,.oc-project-progress-heading>strong,.oc-app-overview button>span:last-child) {
  font-size:var(--kompani-text-control)!important;line-height:1.55!important;
}
body.kompani-platform :is(.oc-project-progress-heading,.oc-progress-dashboard>header,
  .oc-feed-title,.oc-app-overview>header,.oc-next-work>header,.oc-project-choice) {flex-wrap:wrap}

/* Standalone mail, public funding, account entry and personal messages use the
   same scale as their embedded workspace counterparts. Sandboxed email HTML is
   deliberately outside this document's typography. */
body.kompani-platform :is(.messenger-conversation-copy strong,.messenger-chat-header strong,
  .platform-mail-row strong,.platform-mail-sender,.investor-company-link strong,
  .starting-paths strong,.onboarding-form .path-card strong,.access-card .notice strong) {
  font-size:var(--kompani-text-control)!important;line-height:1.55!important;
}
body.kompani-platform :is(.messenger-work-link,.messenger-conversation-time,.messenger-list-footer>span,
  .messenger-encryption-note,.messenger-notice,.messenger-start-note small,.mail-row-heading small,
  .platform-mail-list-heading>span,.mail-pagination,.mail-reader-note,.mail-preferences summary,
  .mail-folder-create summary,.mail-attachment-list a,.exchange-notice,.exchange-workspace,
  .exchange-summary span,.exchange-summary small,.market-toolbar,.market-section-heading>span,
  .investment-body small,.investment-body>span,.profile-heading p,.profile-highlights span,
  .report-meta,.valuation-equation span,.hero-links button,.sector-tabs button,.onboarding-flow,
  .path-card small,.form-hint,.form-footer small,.welcome-tool-list,.invitation-scope dt,
  .home-company-toolbar,.access-card summary,.access-card .notice) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.55!important;
}
body.kompani-platform :is(.platform-mail,.platform-mail-modal,.home-setup-shell,.access-page,
  .invitation-welcome-page,.work-shell) :is(button,summary,select,input,textarea) {
  max-width:100%;min-width:0;
}
body.kompani-platform :is(.mail-command-bar,.mail-reader-toolbar,.mail-compose-footer,
  .messenger-new-form>div,.exchange-summary,.profile-highlights,.form-footer) {flex-wrap:wrap}

/* Text-bearing buttons may also carry a more descriptive accessible name.
   Keep icon controls and source/diagram canvases on their component scale. */
body.kompani-platform :is(.process-link,.case-span-chart button,.inspector-cases button,
  .process-reset,.process-secondary,.process-tabs button,.variant-preview>button,
  .workspace-pulse-open,.os-launcher-close,.life-remove-button,.item-archive,
  .oc-work-table button,.oc-calendar-controls button,.ai-send,.ai-dock-expand,
  .ai-dock-heading-actions button,.bpd-edge-list button,.wpl-drag-handle) {
  font-size:var(--kompani-text-control)!important;line-height:1.35!important;min-height:32px;
}
body.kompani-platform :is(.case-span-chart button>span:not(.span-track),
  .inspector-cases button>span,.process-panel-meta,.process-demo-source,
  .process-demo-source span,.process-selection,.process-selection span,.process-map-legend,
  .inspector-coverage,.inspector-coverage strong,.process-kpis>div>span,
  .variant-preview>button>div:first-child>span,.variant-preview-path,.variant-preview-time,
  .sample-badge,.process-small-note,.event-gap,.variant-number) {
  font-size:var(--kompani-text-secondary)!important;line-height:1.5!important;
}

/* Card titles and operational metadata share a hierarchy without changing
   source-editor, chart, slide or hourly-calendar geometry. */
body.kompani-platform :is(.work-title,.work-card-main>strong,.oc-next-ticket strong,
  .os-work-copy strong,.platform-mail-row strong,.feed-post-body>strong,.ticket-detail-sheet h3){
 font-size:var(--kompani-text-body)!important;line-height:1.45!important;font-weight:600;
}
body.kompani-platform :is(.billing-caption,.billing-event-status,.balance-status,
  .billing-panel-heading>span,.billing-wallet article>span,.billing-checkout>span,
  .resource-limit span,.studio-caption,.studio-status,.studio-model-catalog span,.studio-topbar>div,
  .adaptive-record-summary span,.adaptive-run-select>span:last-child,.ticket-detail-context,
  .ide-editor-privacy,.ide-status,.ide-file-kind,.ide-tab-kind,.ide-activity-label){
 font-size:var(--kompani-text-secondary)!important;line-height:1.45!important;
 letter-spacing:normal;
}
body.kompani-platform .ide :is(.ide-menubar summary,.ide-toolbar button,.ide-toolbar select,
  .ide-tree button,.ide-tabs button,.ide-bottom>nav button,.ide-explorer-heading){
 font-size:var(--kompani-text-control)!important;line-height:1.4;
}
body.kompani-platform .ide :is(.ide-status,.ide-editor-privacy){flex-wrap:wrap}
body.kompani-platform .ide .ide-activity-label{line-height:1.2!important;overflow-wrap:anywhere}

body.kompani-platform :is(.capability-guidance,.settings-help,.companion-help,.wpm-scope){
 font-size:var(--kompani-text-secondary)!important;line-height:1.5!important;color:var(--kompani-muted)!important;
}

/* Touch input keeps accessible targets and avoids mobile input auto-zoom. */
@media(pointer:coarse){body.kompani-platform :is(button,summary,select,input:not([type=checkbox]):not([type=radio]),textarea){min-height:44px!important}body.kompani-platform :is(input:not([type=checkbox]):not([type=radio]),select,textarea):not(:where(.ide-code,.vc-editor,.nd-code-input)){font-size:16px!important}}
