/* ============================================================================
   SITE TYPOGRAPHY — unified readable scale matching staff nav
   Staff nav: clamp(14px–16px) shell × 0.9em ≈ 12.6px–14.4px, responsive
   ============================================================================ */

html {
    font-size: 16px;
}

body {
    font-size: var(--site-text-ui);
}

/* Preserve icon sizing relative to surrounding UI text */
.fa,
.fas,
.far,
.fab,
.fal,
.fad,
[class*="fa-"] {
    font-size: 1em;
}

/* Floor: bump small text up to nav size */
.small,
.text-muted,
.text-small,
.form-text,
.caption,
.meta,
.help-text,
.badge-sm,
.cc-badge-sm,
table .small,
.card small,
.subtitle,
.description,
.status-label,
.filter-label,
.email-preview,
.template-preview,
.mobile-menu-label,
.footer-copyright,
.login-brand__badge,
.login-header p,
.login-form .form-group label {
    font-size: var(--site-text-ui) !important;
}

/* Ceiling: cap headings and large UI text at nav size */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
.page-title,
.section-title,
.card-title,
.dashboard-card h3,
.card h3,
.empty-state h2,
.staff-header h1,
.staff-header .page-title,
.login-header h1,
header h1,
.hero-title,
.stat-value,
.metric-value,
.display-1,
.display-2,
.display-3,
.display-4 {
    font-size: var(--site-text-ui) !important;
}

/* Core UI surfaces */
p,
li,
dd,
dt,
td,
th,
caption,
label,
legend,
.form-label,
input,
select,
textarea,
.form-control,
.btn,
button,
a.btn,
nav a,
.nav-links a,
.nav-dropdown-toggle,
.staff-login,
.mobile-nav-title,
.mobile-menu-link,
.mobile-nav-btn,
.staff-nav,
.staff-nav a,
.staff-nav .nav-more-btn,
.staff-nav .nav-bell,
.staff-nav .nav-settings,
.square-staff-nav a,
.alert,
.badge,
.cc-badge,
.filter-tab,
.filter-button,
.status-filter,
.card,
.card-body,
.card p,
.table,
.toast,
.dropdown-item,
.list-group-item,
.pagination,
.page-link,
.modal-title,
.modal-body,
.popover,
.tooltip,
footer,
footer a,
footer p,
.user-info,
.user-info__name,
.user-info__action,
.sticky-back-button {
    font-size: var(--site-text-ui);
}

/* Bootstrap + staff form controls loaded with higher specificity elsewhere */
.staff-main .btn,
.staff-main .form-control,
.staff-main input,
.staff-main select,
.staff-main textarea,
.staff-main table td,
.staff-main table th,
.staff-main label,
.staff-main p {
    font-size: var(--site-text-ui) !important;
}

@media (max-width: 480px) {
    :root {
        --site-nav-shell: clamp(13px, 12px + 0.5vw, 15px);
    }
}

@media (min-width: 1280px) {
    :root {
        --site-nav-shell: 16px;
    }
}
