/* Shared frontend/editor canvas typography; layout and font sizes stay in component styles. */
:root, .editor-styles-wrapper {
 --af-font-body: 'Lato', sans-serif;
 --af-font-interface: 'Lato', sans-serif;
 /* Compatibility for previously saved blocks using the original sans preset. */
 --wp--preset--font-family--sans: var(--af-font-body);
 --wp--preset--font-family--dm-sans: var(--af-font-body);
 --wp--preset--font-family--source-sans-3: var(--af-font-body);
}
:where(.wp-site-blocks, .editor-styles-wrapper, .af-search-dialog) {
 font-family: var(--af-font-body);
 font-weight: 400;
 line-height: 1.666666667;
}
:where(.wp-site-blocks, .editor-styles-wrapper, .af-search-dialog) :is(input, textarea, select) {
 font-family: var(--af-font-body);
 font-weight: 400;
 line-height: 1.666666667;
}
:where(.wp-site-blocks, .editor-styles-wrapper, .af-search-dialog) :is(button, .wp-element-button, .wp-block-button__link, label, legend, .is-style-af-eyebrow) {
 font-family: var(--af-font-interface);
 font-weight: 600;
}
:where(.wp-site-blocks, .editor-styles-wrapper) :is(strong, b) { font-weight: 700; }
:where(.wp-site-blocks, .editor-styles-wrapper) :is(.has-sans-font-family, .has-dm-sans-font-family, .has-source-sans-3-font-family) { font-family: var(--af-font-body); }
.af-primary-nav, .af-primary-nav .af-mega-toggle,
.af-header .af-mobile-toggle, .af-utility > p > a, .af-footer-links a,
.af-search-dialog .af-search-close {
 font-family: var(--af-font-interface);
 font-weight: 600;
 letter-spacing: 0;
}
.af-primary-nav .wp-block-navigation-item__content,
.af-primary-nav .af-mega-toggle,
.af-primary-nav .af-nav-donate > a { font-weight: 700; }
.af-mega-panel p a { font-family: var(--af-font-interface); font-weight: 500; letter-spacing: 0; }
.af-mega-panel h2 { font-family: var(--af-font-interface); font-weight: 600; line-height: 1.2; letter-spacing: 0; }
.af-mega-panel .wp-block-button__link,
:where(.wp-site-blocks, .editor-styles-wrapper) .wp-block-button__link { font-family: var(--af-font-interface); font-weight: 700; }
.af-search-dialog h2 { font-family: var(--af-font-interface); font-weight: 600; line-height: 1.2; letter-spacing: 0; }
.af-footer-main h2 { font-family: var(--af-font-interface); font-weight: 600; line-height: 1.4; letter-spacing: 0; }
.af-footer-main p { font-family: var(--af-font-body); line-height: 1.4; }
.is-style-af-card :is(h2, h3) { font-family: var(--af-font-interface); font-weight: 600; line-height: 1.2; letter-spacing: 0; }

/* The CW plugins declare their own font (including on every project descendant).
   Limit overrides to typography, in the theme, so plugin updates retain the theme typography. */
.cw-events, .cw-projects-frontend,
.cw-projects-frontend :where(div, p, span, li, a, input, textarea, select) {
 font-family: var(--af-font-body) !important;
}
:where(.cw-events, .cw-projects-frontend) :is(h1, h2, h3, h4, h5, h6, button, label, legend),
.cw-events :is(.cw-event-button, .cw-events-kicker, .cw-event-meta, .cw-events-clear, .cw-event-archive-card strong),
.cw-projects-frontend :is(.cw-projects-frontend__card-title, .cw-projects-frontend__modal-action) {
 font-family: var(--af-font-interface) !important;
}
.cw-projects-frontend .cw-projects-frontend__modal-action { font-weight: 700 !important; }
.cw-projects-frontend :is(h4, h5, h6) { font-weight: 600 !important; }
.cw-projects-frontend span.cw-projects-frontend__card-title { font-weight: 600 !important; line-height: 1.2 !important; letter-spacing: 0 !important; }
.cw-projects-frontend p.cw-projects-frontend__intro { font-weight: 400; line-height: 1.666666667; }
.cw-events :is(input, textarea, select), .cw-projects-frontend :is(input, textarea, select) { font-family: var(--af-font-body) !important; font-weight: 400; }

/* Imported Thrive content can contain inline typefaces. Preserve its dimensions,
   colors, icons and markup while replacing text fonts within the content canvas. */
:where(.wp-site-blocks, .editor-styles-wrapper) :is(.tve_flt, .thrv_wrapper, .af-thrive-content) :is(p, li, blockquote, figcaption, input, textarea, select),
:where(.wp-site-blocks, .editor-styles-wrapper) :is(.tve_flt, .thrv_wrapper, .af-thrive-content) :is(p, li) span {
 font-family: var(--af-font-body) !important;
}
:where(.wp-site-blocks, .editor-styles-wrapper) :is(.tve_flt, .thrv_wrapper, .af-thrive-content) :is(h1, h2, h3, h4, h5, h6, h1 span, h2 span, h3 span, h4 span, h5 span, h6 span, button, label, .tcb-button-link, .tcb-button-text) {
 font-family: var(--af-font-interface) !important;
}

/* Content typography also covers shortcode headings with their own plugin CSS. */
:where(.cw-events, .cw-projects-frontend) :is(h1, h2, h3, h4, h5, h6) {
 font-weight: 600 !important; line-height: 1.2 !important; letter-spacing: 0 !important; margin: 0 0 10px !important;
}
:where(.cw-events, .cw-projects-frontend) h1 { font-size: 36px !important; }
:where(.cw-events, .cw-projects-frontend) h2 { font-size: 30px !important; }
:where(.cw-events, .cw-projects-frontend) h3 { font-size: 24px !important; }
:where(.cw-events, .cw-projects-frontend) h4 { font-size: 20px !important; }
:where(.cw-events, .cw-projects-frontend) h5 { font-size: 18px !important; }
:where(.cw-events, .cw-projects-frontend) h6 { font-size: 16px !important; }

.cw-projects-frontend p.cw-projects-frontend__intro,
.cw-projects-frontend .cw-projects-frontend__modal-content :is(p, li),
.cw-events .cw-event-description :is(p, li) { color: #4d4d4d; font-size: 18px; font-weight: 400; line-height: 30px; }
