/* English-only editorial type scale.
   Mirrors the approved Ukrainian hierarchy without changing shared layout. */

html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h1 {
  font-size: clamp(3.5rem, 5vw, 4.25rem);
  line-height: 1.02;
  letter-spacing: -.025em;
  text-wrap: balance;
}

@media (min-width: 901px) {
  html[lang="en"] body[data-seo-locale="en"][data-page="careers"] .careers-hero h1 {
    font-size: clamp(3rem, 4.5vw, 4rem);
    line-height: .98;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="careers"] .careers-hero h1 :is(span, em) {
    display: inline;
  }
}

html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h2 {
  font-size: clamp(2.25rem, 3.2vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: -.02em;
  text-wrap: balance;
}

html[lang="en"] body[data-seo-locale="en"][data-page="about"] main h2.about-hero-subheading {
  max-width: 30ch;
  margin: .65rem 0 1.75rem;
  color: var(--burgundy);
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.1vw, 2rem);
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -.012em;
}

html[lang="en"] body[data-seo-locale="en"][data-page] main h2.editorial-hero-subheading {
  max-width: 32ch;
  margin: .65rem 0 1.75rem;
  color: var(--burgundy);
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.1vw, 2rem);
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -.012em;
}

html[lang="en"] body[data-seo-locale="en"] main h2.editorial-hero-subheading em {
  color: inherit;
  font-weight: inherit;
}

html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h3 {
  font-size: clamp(1.375rem, 1.7vw, 1.625rem);
  line-height: 1.22;
  letter-spacing: -.012em;
  text-wrap: balance;
}

html[lang="en"] body[data-seo-locale="en"] .editorial-heading-break-marker {
  display: inline;
}

html[lang="en"] body[data-seo-locale="en"][data-page="about"] .editorial-section-subheading {
  max-width: 48ch;
  margin: .75rem 0 0;
  color: var(--muted);
  font-size: clamp(1.125rem, 1.35vw, 1.25rem);
  line-height: 1.55;
}

html[lang="en"] body[data-seo-locale="en"][data-page="about"] .editorial-section-subheading em {
  color: inherit;
  font-style: normal;
}

html[lang="en"] body[data-seo-locale="en"][data-page="about"] .about-pullquote p {
  font-size: clamp(1.875rem, 2.5vw, 2.25rem);
  line-height: 1.15;
}

html[lang="en"] body[data-seo-locale="en"][data-page="about"] .founder-quote > .founder-motto {
  font-size: clamp(2rem, 2.65vw, 2.25rem);
  line-height: 1.08;
}

html[lang="en"] body[data-seo-locale="en"][data-page="about"] .transparency-statement {
  font-size: clamp(1.875rem, 2.45vw, 2.25rem);
  line-height: 1.14;
}

html[lang="en"] body[data-seo-locale="en"][data-page="universities"] .university-card .university-card-title {
  margin: 0 0 8px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1.375rem, 1.65vw, 1.55rem);
  font-weight: 400;
  line-height: 1.08;
  text-wrap: balance;
}

html[lang="en"] body[data-seo-locale="en"][data-page="funding"] .budget-country-details article .funding-country-card-title {
  margin: clamp(20px, 2.4vw, 30px) 0 14px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1.375rem, 1.7vw, 1.625rem);
  font-weight: 400;
  letter-spacing: -.012em;
  line-height: 1.18;
  text-wrap: balance;
}

html[lang="en"] body[data-seo-locale="en"][data-page="destinations"] .destinations-section-lead {
  max-width: 58ch;
  margin: clamp(16px, 2vw, 24px) 0 clamp(18px, 2.1vw, 26px);
  color: var(--muted);
  font-size: clamp(1.125rem, 1.35vw, 1.25rem);
  line-height: 1.55;
}

html[lang="en"] body[data-seo-locale="en"][data-page="academy"] .academy-course-empty .editorial-empty-state-title,
html[lang="en"] body[data-seo-locale="en"][data-page="destinations"][data-country] .country-uk-empty .country-uk-empty-title {
  max-width: 32ch;
  margin: 18px 0 10px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1.375rem, 1.7vw, 1.625rem);
  font-weight: 400;
  line-height: 1.2;
  text-wrap: balance;
}

html[lang="en"] body[data-seo-locale="en"][data-page="contact"] .cost-grid .editorial-card-heading {
  display: block;
  margin: 75px 0 13px;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 1.5vw, 1.4375rem);
  font-weight: 400;
  line-height: 1.2;
}

html[lang="en"] body[data-seo-locale="en"][data-page="contact"] .standards-list .editorial-card-heading {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 1.45vw, 1.375rem);
  font-weight: 400;
  line-height: 1.2;
}

html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) :is(
  .inner-hero-side > p,
  .programmes-hero-intro,
  .country-page-title > div:last-child > p,
  .about-hero-intro,
  .academy-catalogue-copy > p:not(.section-index),
  .careers-hero-lead,
  .contact-copy > p:not(.section-index),
  .section-head > p:last-child,
  .topic-visual-copy > p,
  .brand-story-copy > p:not(.section-index),
  .page-cta > div > p:last-child
) {
  max-width: 68ch;
  font-size: clamp(1.125rem, 1.35vw, 1.25rem);
  line-height: 1.6;
}

html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main :is(
  p,
  h1,
  h2,
  h3,
  h4,
  li,
  a,
  b,
  small
) {
  overflow-wrap: break-word;
  word-break: normal;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] {
  font-size: 1rem;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero h1 {
  margin-bottom: .75rem;
  font-size: clamp(3.5rem, 5vw, 4.25rem);
  line-height: .94;
  letter-spacing: -.025em;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero-subheading {
  max-width: 34ch;
  margin: 0 0 1.5rem;
  color: #2f2824;
  font-family: var(--serif);
  font-size: clamp(1.375rem, 1.9vw, 1.625rem);
  line-height: 1.18;
  letter-spacing: -.01em;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero-subheading em {
  color: var(--burgundy);
  font-weight: 400;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero-lead {
  max-width: 62ch;
  font-size: clamp(1.125rem, 1.45vw, 1.3125rem);
  line-height: 1.55;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] :is(
  .intro h2,
  .section-head h2,
  .services-title h2,
  .timeline-head h2,
  .funding-top h2,
  .faq-head h2,
  .standards-copy h2,
  .page-cta h2
) {
  font-size: clamp(2.25rem, 3.2vw, 2.75rem);
  line-height: .98;
  letter-spacing: -.02em;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .section-head > p:last-child,
html[lang="en"] body[data-seo-locale="en"][data-page="home"] .standards-copy > p:not(.section-index),
html[lang="en"] body[data-seo-locale="en"][data-page="home"] .page-cta > div > p:last-child {
  max-width: 64ch;
  font-size: 1.0625rem;
  line-height: 1.62;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .directory-card p,
html[lang="en"] body[data-seo-locale="en"][data-page="home"] .journey-preview p,
html[lang="en"] body[data-seo-locale="en"][data-page="home"] .control-grid p {
  font-size: .9375rem;
  line-height: 1.55;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .home-country-grid h3 {
  font-size: 1.5rem;
  line-height: 1.08;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .directory-card h3 {
  font-size: 1.5rem;
  line-height: 1.12;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .journey-preview h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 400;
  line-height: 1.15;
}

html[lang="en"] body[data-seo-locale="en"][data-page="home"] .control-grid h3 {
  position: relative;
  z-index: 1;
  display: block;
  max-width: 46%;
  margin: 65px 0 10px;
  font-family: var(--serif);
  font-size: 1.375rem;
  font-weight: 400;
  line-height: 1.2;
}

html[lang="en"] body[data-seo-locale="en"][data-page="programmes"] .programme-card-back-title {
  min-height: 0;
  margin: 44px 0 18px;
  color: var(--burgundy);
  font-family: var(--serif);
  font-size: 1.72rem;
  font-weight: 400;
  line-height: 1.05;
}

html[lang="en"] body[data-seo-locale="en"][data-page="contact"] .contact-card-title {
  margin: 24px 0 12px;
  font-family: var(--serif);
  font-size: clamp(1.375rem, 1.7vw, 1.625rem);
  font-weight: 400;
  line-height: 1.2;
}

html[lang="en"] body[data-seo-locale="en"][data-page="destinations"] .compare-widget h3 {
  max-width: 660px;
  margin: clamp(16px, 2vw, 24px) 0 clamp(18px, 2.1vw, 26px);
  color: var(--burgundy);
  font-family: var(--serif);
  font-weight: 400;
}

html[lang="en"] body[data-seo-locale="en"][data-page="destinations"] .country-dossier summary h3 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
}

@media (min-width: 761px) and (max-width: 900px) {
  html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h1 {
    font-size: 2.75rem;
  }
}

@media (max-width: 760px) {
  html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h1 {
    font-size: clamp(2.375rem, 10.5vw, 2.75rem);
    line-height: 1.04;
    letter-spacing: -.02em;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h2 {
    font-size: clamp(1.75rem, 8vw, 2.125rem);
    line-height: 1.12;
    letter-spacing: -.015em;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="about"] main h2.about-hero-subheading {
    margin: .55rem 0 1.5rem;
    font-size: clamp(1.25rem, 5.8vw, 1.5rem);
    line-height: 1.24;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page] main h2.editorial-hero-subheading {
    margin: .55rem 0 1.5rem;
    font-size: clamp(1.25rem, 5.8vw, 1.5rem);
    line-height: 1.24;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) main h3 {
    font-size: clamp(1.25rem, 5.6vw, 1.4375rem);
    line-height: 1.25;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="about"] .editorial-section-subheading {
    font-size: clamp(1.0625rem, 4.5vw, 1.125rem);
    line-height: 1.58;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="about"] .about-pullquote p,
  html[lang="en"] body[data-seo-locale="en"][data-page="about"] .founder-quote > .founder-motto,
  html[lang="en"] body[data-seo-locale="en"][data-page="about"] .transparency-statement {
    font-size: clamp(1.5rem, 7vw, 1.875rem);
    line-height: 1.16;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="contact"] .cost-grid .editorial-card-heading {
    margin-top: 52px;
    font-size: clamp(1.25rem, 5.6vw, 1.4375rem);
  }

  html[lang="en"] body[data-seo-locale="en"][data-page]:not([data-page="home"]) :is(
    .inner-hero-side > p,
    .programmes-hero-intro,
    .country-page-title > div:last-child > p,
    .about-hero-intro,
    .academy-catalogue-copy > p:not(.section-index),
    .careers-hero-lead,
    .contact-copy > p:not(.section-index),
    .section-head > p:last-child,
    .topic-visual-copy > p,
    .brand-story-copy > p:not(.section-index),
    .page-cta > div > p:last-child
  ) {
    font-size: clamp(1.0625rem, 4.5vw, 1.125rem);
    line-height: 1.62;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero h1 {
    font-size: clamp(2.375rem, 10.5vw, 2.75rem);
    line-height: .98;
    letter-spacing: -.02em;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero-subheading {
    max-width: 28ch;
    margin-bottom: 1.25rem;
    font-size: clamp(1.125rem, 5vw, 1.3125rem);
    line-height: 1.22;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] .hero-lead {
    font-size: clamp(1.0625rem, 4.5vw, 1.125rem);
    line-height: 1.58;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] :is(
    .directory-card h3,
    .home-country-grid h3
  ) {
    font-size: 1.35rem;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] .control-grid h3 {
    max-width: 49%;
    margin-top: 55px;
    font-size: 1.25rem;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] :is(
    .intro h2,
    .section-head h2,
    .services-title h2,
    .timeline-head h2,
    .funding-top h2,
    .faq-head h2,
    .standards-copy h2,
    .page-cta h2
  ) {
    font-size: clamp(1.75rem, 8vw, 2.125rem);
    line-height: 1.04;
    letter-spacing: -.015em;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="home"] :is(
    p,
    h1,
    h2,
    h3,
    h4,
    li,
    a,
    b,
    small
  ) {
    overflow-wrap: break-word;
    word-break: normal;
  }

  html[lang="en"] body[data-seo-locale="en"][data-page="programmes"] .programme-card-back-title {
    margin-top: 36px;
  }
}
