:root {
  --type-page: 20px;
  --type-dialog: 18px;
  --type-section: 16px;
  --type-card: 15px;
  --type-body: 14px;
  --type-label: 13px;
  --type-meta: 12px;
  --type-metric: 22px;
  --type-display: 28px;
}

#auth-view .auth-box h2 {
  font-size: var(--type-page);
  font-weight: 600;
  line-height: 1.35;
}

:is(#app-view, #panel-view, #auth-view) :is(.field label, label.field),
:is(#tab-support, #tab-permissions) label,
#tab-tasks :is(.password-weekday, .password-field-label) {
  font-size: var(--type-label);
  line-height: 1.45;
}

:is(#app-view, #panel-view) .section-title,
:is(#app-view, #panel-view) .card > h3,
#copy-ops-title,
#tab-lv .level-pane-title {
  font-size: var(--type-section);
  font-weight: 600;
  line-height: 1.4;
}

:is(#app-view, #panel-view) h4,
#tab-copy-operations .copy-ops-totals h3,
#tab-tasks .password-panel-header h3,
:is(#tab-support, #tab-permissions) :is(.opcs-faq h3, .opcs-card h3),
.sd-card h4 {
  font-size: var(--type-card);
  font-weight: 600;
  line-height: 1.4;
}

.modal > h3,
.sd-head h3,
:is(#tab-support, #tab-permissions) dialog h3 {
  font-size: var(--type-dialog);
  font-weight: 600;
  line-height: 1.4;
}

#tab-lv #level-page-title,
#tab-tasks .password-page-heading h2,
:is(#tab-support, #tab-permissions) .opcs-head h2,
.direct-members-header h2 {
  font-size: var(--type-page);
  font-weight: 600;
  line-height: 1.35;
}

:is(#app-view, #panel-view) .form-card :is(.desc, .sub),
:is(.modal, .auth-box) :is(.desc, .sub, .tip),
#tab-tasks :is(.password-section-note, .password-feedback),
:is(#tab-support, #tab-permissions) .opcs-service {
  font-size: var(--type-label);
  line-height: 1.55;
}

#panel-view .form-card > p:not(.desc, .sub),
#app-view :is(.notice-item-content, .ct-body),
:is(#tab-support, #tab-permissions) .opcs-message p {
  font-size: var(--type-body);
  line-height: 1.6;
}

:is(#app-view, #panel-view) .tbl-wrap th {
  font-size: var(--type-meta);
  font-weight: 500;
}

:is(#app-view, #panel-view) .tbl-wrap :is(td .sub, td small),
#tab-tasks :is(.password-field-hint, .password-account-meta),
:is(#tab-support, #tab-permissions) :is(.opcs-meta span, .opcs-item small, .opcs-message small),
:is(.notice-item-date, .stat span, .bc-row-l, .w-addr-net, .ai-chip span) {
  font-size: var(--type-meta);
}

:is(#app-view, #panel-view) .btn.sm {
  font-size: var(--type-label);
}

#tab-copy-operations .copy-ops-table .btn.sm {
  font-size: var(--type-meta);
}

#level-card .team-level-heading h3 {
  font-size: var(--type-metric);
  font-weight: 650;
  line-height: 1.3;
}

#team-cards .team-stat-label {
  color: var(--muted);
  font-size: var(--type-meta);
}

#team-cards .team-stat-value {
  font-size: var(--type-metric);
  font-weight: 650;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
}

#tab-wallet .wallet-bar .wb-name,
#tab-bschool :is(.bs-pos-name, .bsb-title) {
  font-size: var(--type-section);
  font-weight: 650;
  line-height: 1.35;
  letter-spacing: normal;
}

#tab-wallet .wallet-bar .wb-bal,
#app-view .member-balance-value {
  font-size: var(--type-display);
  font-weight: 650;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
}

#app-view .member-balance-value { color: var(--green); }

#tab-bschool :is(.bs-pos-rules, .bsb-sub) {
  font-size: var(--type-label);
}

@media (max-width: 700px) {
  #tab-wallet .wallet-bar .wb-bal,
  #app-view .member-balance-value {
    font-size: var(--type-metric);
  }
}
