/**
 * Échelle typographique OrgaHal — classique, Heritage, Clair.
 * Variables définies dans ui-theme-tokens.css ; chargé après les styles inline des layouts.
 */
html {
    font-size: var(--type-root, 100%);
    -webkit-text-size-adjust: 100%;
}

body {
    font-size: var(--type-body);
    line-height: var(--lh-body);
}

html[data-ui-theme="heritage"] body,
html[data-ui-theme="clair"] body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Titres & bandeaux */
h1, h2, h3,
main h1,
.page-title,
.comms-center__title {
    font-family: var(--font-display);
    line-height: var(--lh-heading);
}

main h1,
.page-title {
    font-size: var(--type-h1);
}

.page-hero__title {
    font-family: var(--font-display);
    font-size: var(--type-hero);
    line-height: var(--lh-heading);
    letter-spacing: -0.02em;
}

.comms-center__title {
    font-size: var(--type-display);
    font-weight: 800;
}

.page-hero__sub,
.page-intro,
.comms-center__lead {
    font-size: var(--type-intro);
    line-height: var(--lh-relaxed);
}

.comms-center__edition {
    font-size: var(--type-body-sm);
}

/* Header & navigation */
.app-brand__title {
    font-size: var(--type-brand);
}

.app-brand__meta {
    font-size: var(--type-brand-meta);
}

.app-edition-badge {
    font-size: var(--type-caption);
}

.app-header__tool-link,
.ui-theme-toggle {
    font-size: var(--type-nav-sm);
}

.app-nav-primary a,
.app-nav-dropdown__trigger {
    font-size: var(--type-nav);
}

.app-nav-dropdown__panel a,
.app-nav-dropdown__sublink {
    font-size: var(--type-nav);
}

.app-nav-dropdown__label {
    font-size: var(--type-overline);
}

.edition-panel__top a,
.edition-row__label,
.edition-row__sub a {
    font-size: var(--type-nav-sm);
}

.app-nav-badge {
    font-size: var(--type-badge);
}

/* Sidebar Participants */
.app-sidebar__section-label {
    font-size: var(--type-sidebar-label);
    letter-spacing: 0.08em;
}

.app-sidebar__link {
    font-size: var(--type-sidebar-link);
}

.app-sidebar__link--sub {
    font-size: var(--type-sidebar-sub);
}

/* Formulaires & boutons */
label,
.auth-card__body label {
    font-size: var(--type-label);
}

input, select, textarea,
.auth-card__body input {
    font-size: var(--type-input);
}

button, .btn {
    font-size: var(--type-btn);
}

.form-card-title,
.comms-card__head h2 {
    font-family: var(--font-display);
    font-size: var(--type-form-title);
    letter-spacing: 0.04em;
}

html[data-ui-theme="heritage"] .form-card-title,
html[data-ui-theme="heritage"] .comms-card__head h2,
html[data-ui-theme="clair"] .form-card-title,
html[data-ui-theme="clair"] .comms-card__head h2 {
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Tableaux */
th {
    font-size: var(--type-table-head);
}

td {
    font-size: var(--type-table-cell);
}

html[data-ui-theme="heritage"] th,
html[data-ui-theme="clair"] th {
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Compteurs & chips */
.lstats__num {
    font-size: var(--type-chip-num);
}

.lstats__label,
.count-chip {
    font-size: var(--type-chip-label);
}

/* Divers */
#flash-stack .flash,
.flash {
    font-size: var(--type-flash);
}

.fiche-ro-dl {
    font-size: var(--type-label);
}

.guest-form-head-meta {
    font-size: var(--type-body-sm);
}

/* Connexion */
.auth-card__title {
    font-family: var(--font-display);
    font-size: var(--type-auth-title);
    line-height: var(--lh-heading);
    letter-spacing: -0.02em;
}

.auth-card__subtitle,
.auth-card__footer {
    font-size: var(--type-auth-sub);
}

.auth-card__submit {
    font-size: var(--type-btn);
}

/* Formulaires publics */
.invite-toc__hint,
.invite-toc__list a {
    font-size: var(--type-body-sm);
}

html[data-ui-theme="heritage"] h1,
html[data-ui-theme="heritage"] h2,
html[data-ui-theme="heritage"] h3,
html[data-ui-theme="clair"] h1,
html[data-ui-theme="clair"] h2,
html[data-ui-theme="clair"] h3 {
    font-weight: 600;
}
