/* Shared type scale. Component styles use these tokens so CSS isolation preserves
   the same sizes across business, school, family and public account screens. */
:root {
    font-size: 100%;
    --em-font-family: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Arial, sans-serif;
    --em-font-body: 0.875rem;       /* 14px */
    --em-font-ui: 0.8125rem;       /* 13px: buttons, labels and navigation */
    --em-font-table: 0.75rem;      /* 12px: table headings and data rows */
    --em-font-control: 0.875rem;   /* 14px: input values */
    --em-font-small: 0.75rem;      /* 12px: supporting text and table headings */
    --em-font-kicker: 0.6875rem;   /* 11px: short uppercase group labels */
    --em-font-heading: 1rem;       /* 16px: subsection headings */
    --em-font-section: 1.125rem;   /* 18px: section headings */
    --em-font-page: 1.5rem;        /* 24px: workspace page titles */
    --em-font-account: 1.75rem;    /* 28px: account page titles */
    --em-font-hero: 2.25rem;       /* 36px: account introduction */
    --em-font-metric: 1.75rem;     /* 28px: summary values */
    --em-font-brand: 1.5rem;       /* 24px: product wordmark */
    --em-leading-body: 1.5;
    --em-leading-heading: 1.3;
    --bs-body-font-family: var(--em-font-family);
    --bs-body-font-size: var(--em-font-body);
    --bs-body-line-height: var(--em-leading-body);
}

/* All rem tokens use the same browser-scalable reference; none are reduced
   through the earlier 15px root in app.css or Bootstrap's theme. */
html { font-size: 100%; }
body {
    font-family: var(--em-font-family);
    font-size: var(--em-font-body);
    line-height: var(--em-leading-body);
}
button, input, select, textarea { font-family: var(--em-font-family); }
button { font-size: var(--em-font-ui); }
h1, h2, h3, h4, h5, h6 { line-height: var(--em-leading-heading); }
h1 { font-size: var(--em-font-page); letter-spacing: -0.025em; }
h2 { font-size: var(--em-font-section); letter-spacing: -0.015em; }
h3, h4, h5, h6 { font-size: var(--em-font-heading); letter-spacing: normal; }
label { font-size: var(--em-font-ui); line-height: 1.4; }
small, .small { font-size: var(--em-font-small); line-height: var(--em-leading-body); }
input:not([type=checkbox]):not([type=radio]), select, textarea { font-size: var(--em-current-control-size,var(--em-font-control)); }
table { font-size: var(--em-font-table); --em-current-control-size: var(--em-font-table); }
th { font-size: var(--em-font-table); line-height: 1.45; letter-spacing: 0.025em; }
td { font-size: var(--em-font-table); line-height: var(--em-leading-body); }
table, input[type=number], output { font-variant-numeric: tabular-nums; }
.eyebrow { font-size: var(--em-font-kicker); letter-spacing: 0.08em; line-height: 1.5; }
.main-tabs { font-size: var(--em-font-ui); }

/* Match the controls from the locally installed DevExpress theme as well. */
.dxbl-grid {
    --dxbl-grid-font-family: var(--em-font-family);
    --dxbl-grid-font-size: var(--em-font-table);
}
.dxbl-tabs, .main-tabs.dxbl-tabs {
    --dxbl-tabs-font-size: var(--em-font-ui);
    --dxbl-tabs-content-font-size: var(--em-font-body);
}
.dxbl-btn { --dxbl-btn-font-size: var(--em-font-ui); }
.dxbl-text-edit { --dxbl-text-edit-font-size: var(--em-current-control-size,var(--em-font-control)); }

@media (max-width: 640px) {
    :root {
        --em-font-page: 1.375rem;     /* 22px */
        --em-font-account: 1.625rem;  /* 26px */
        --em-font-hero: 1.75rem;      /* 28px */
        --em-font-control: 1rem;     /* 16px: prevent automatic focus zoom on iOS */
    }
    table { --em-current-control-size: var(--em-font-control); }
}
