/* Type scale: one set of sizes for every template (2026-11-16 design cleanup,
   docs/design-refresh-2026-11/CLEANUP-PLAN.md, Phase 4).

   Before this, the same role came in up to six sizes depending on which
   template a page used (hero H1 72/60/54/52/46px, section H2 40 vs 47.88px,
   card titles 17 to 22.5px, body 15 to 18px, line-height 1.55 to 1.85).

   Tablet (768-991) steps down between the two: H1 52, article H1 40, H2 36,
   card title 19, FAQ 18, lede 19, card copy 15.

   Roles                      Desktop        Phone (<768)
   Page hero H1               64 / 1.08      40 / 1.1
   Article hero H1            48 / 1.12      32 / 1.15   (blog posts, case studies)
   Section H2                 44 / 1.15      32 / 1.2
   Small section label H2     24 / 1.25      21 / 1.25   (stats band, tech stack)
   Article H2                 28 / 1.3       24 / 1.3
   Card / feature title H3    22 / 1.25      20 / 1.25
   FAQ question H3            19 / 1.4       18 / 1.4
   Hero lede                  20 / 1.5       18 / 1.5
   Body and section intros    17 / 1.55      16 / 1.55
   Card and FAQ copy          16 / 1.55      15 / 1.55

   Weights: headings 700 (the Adobe kit has 500/700/800; 800 is not used for
   headings). Body is the kit's 500 where templates already set it.

   Specificity: every rule ends in :not(.sh-ts) x3 (matches everything, adds
   0-3-0) so it outranks the per-template sheets, whose strongest type rules
   are 0-3-1 and load later in <body>. Exceptions follow their general rule
   with equal or higher specificity, so file order decides. Header, footer and
   nav are left alone. */

:root {
	--fs-h1: 64px;
	--fs-h1-article: 48px;
	--fs-h2: 44px;
	--fs-h2-label: 24px;
	--fs-h2-article: 28px;
	--fs-h3: 22px;
	--fs-faq: 19px;
	--fs-lede: 20px;
	--fs-body: 17px;
	--fs-card: 16px;
	--lh-body: 1.55;
}
@media (min-width: 768px) and (max-width: 991px) {
	:root {
		--fs-h1: 52px;
		--fs-h1-article: 40px;
		--fs-h2: 36px;
		--fs-h3: 19px;
		--fs-faq: 18px;
		--fs-lede: 19px;
		--fs-card: 15px;
	}
}
@media (max-width: 767px) {
	:root {
		--fs-h1: 40px;
		--fs-h1-article: 32px;
		--fs-h2: 32px;
		--fs-h2-label: 21px;
		--fs-h2-article: 24px;
		--fs-h3: 20px;
		--fs-faq: 18px;
		--fs-lede: 18px;
		--fs-body: 16px;
		--fs-card: 15px;
	}
}

/* ---------- Line-height: 1.55 at every content root ---------- */
html body :is([class*="-v1"]):not(.sh-ts):not(.sh-ts):not(.sh-ts),
html body:not(.wp-admin):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	line-height: var(--lh-body);
}

/* ---------- H1 ---------- */
html body :is(.hero, .block-banner, .block-inner-banner) :is(h1, p.h1):not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-h1);
	line-height: 1.08;
	font-weight: 700;
	letter-spacing: 0;
}
html body:is(.single-post, .single-case-study) .hero h1:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-h1-article);
	line-height: 1.12;
}

/* ---------- H2 ---------- */
html body :is(h2, p.h2):not(.eyebrow, header *, footer *, .block-header *, .block-footer *):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-h2);
	line-height: 1.15;
	letter-spacing: 0;
}
html body :is(.stats, .stack, .reader-card, .trust, .home .block-icon-listing__top) h2:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts),
html body h2.h-label:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-h2-label);
	line-height: 1.25;
}
html body :is(.article-body, .cs-feature-body, .mid-cta-panel) h2:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-h2-article);
	line-height: 1.3;
}
html body .form-card h2:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: 22px;
	line-height: 1.25;
}

/* ---------- H3 ---------- */
html body h3:not(header *, footer *, .block-header *, .block-footer *):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-h3);
	line-height: 1.25;
}
html body :is(.faq, .faq-item, .faq-list) h3:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts),
html body summary h3:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-faq);
	line-height: 1.4;
}

/* ---------- Ledes and intros ---------- */
html body .hero :is(p.lede, p.hero-lede, .block-banner__copy p):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-lede);
	line-height: 1.5;
}
html body :is(.section-intro, .head > p, .why-copy > p):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-body);
	line-height: var(--lh-body);
}

/* ---------- Article body (blog posts, case studies) ---------- */
html body .article-body :is(p, li):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-body);
	line-height: var(--lh-body);
}

/* ---------- Card and FAQ copy ---------- */
html body :is(.pain-card, .sol-card, .case-card, .why-item, .work-card, .card-lift, .step-body, .cs-card-body, .city-card-body, .person-card, .faq-body, .channel, .res-card, .ledger-row, .block-review__copy, .block-values__copy, .block-img-with-text__des, .factor-grid, .phase-grid, .process) :is(p, li):not(.step-when):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: var(--fs-card);
	line-height: var(--lh-body);
}

/* Small meta lines keep their size: testimonial reviewer name and role,
   process step timing labels. */
html body .block-review__reviewer :is(p, cite):not(.sh-ts):not(.sh-ts):not(.sh-ts):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: 14px;
	line-height: 1.4;
}

/* Case studies: the article H2s are section labels (SITUATION, SOLUTION,
   IMPACT), tracked Teal caps; keep them at label size, not article H2. */
html body.single-case-study .article-body h2:not(.eyebrow):not(.sh-ts):not(.sh-ts):not(.sh-ts):not(.sh-ts):not(.sh-ts):not(.sh-ts) {
	font-size: 15px;
	line-height: 1.4;
}
