/* Shared editorial typography.
   Load after theme-refresh.css and page styles. Keep component dimensions,
   colors and interactions in their existing stylesheets. */
:root {
  --tr-font-display: "DM Serif Display", Georgia, "Times New Roman", serif;
  --tr-font-sans: "Figtree", "Noto Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --tr-font-body: var(--tr-font-sans);
  --tr-font-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

body,
body.body,
.dd-page,
.w-richtext {
  font-family: var(--tr-font-body);
}

button,
input,
select,
textarea,
.w-button,
.dd-btn,
.dd-nav,
.nav-link,
.nav-alt-heading {
  font-family: var(--tr-font-sans);
}

/* Prevent unwanted line breaks inside buttons, action pills, and phone numbers */
button,
.w-button,
.dd-btn,
.dd-detail-call,
.dd-nav__cta,
.dd-specialty-paths__team,
.dd-specialty-paths__call,
.dd-specialty-paths__all,
.dd-aviation__btn-primary,
.dd-aviation__btn-secondary,
a[href^="tel:"] {
  white-space: nowrap;
}

/* The same display face ties the aviation story to clinical and legacy pages.
   DM Serif Display has a regular weight; avoid synthesized bold headings. */
h1,
h2,
.section-heading,
.hero_heading,
.dd-section-title,
.dd-about__title,
.dd-hero__title,
.dd-bio__name,
.dd-provider-bio__name,
.dd-cms-hero h1,
.dd-detail-hero h1,
.dd-detail-article h2,
.main-wrapper .w-richtext h2,
.dd-aviation__title-main {
  font-family: var(--tr-font-display);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1.12;
  text-wrap: balance;
  overflow-wrap: anywhere;
}

h1 strong,
h2 strong {
  font-weight: inherit;
}

.dd-section-title,
.dd-about__title,
.dd-pathway__title,
.dd-aviation h2 {
  line-height: 1.14;
}

.dd-detail-hero h1 {
  max-width: 19ch;
}

.dd-cms-hero h1 {
  max-width: 18ch;
}

.dd-detail-article h2,
.main-wrapper .w-richtext h2 {
  font-size: clamp(1.6rem, 2.4vw, 2.15rem);
  line-height: 1.2;
  margin-bottom: 0.75rem;
}

/* Compact clinical subheads and utility headings stay quick to scan. */
h3,
h4,
h5,
h6,
.dd-detail-article h3,
.dd-detail-aside h2,
.dd-aviation__sources h2 {
  font-family: var(--tr-font-sans);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.dd-detail-article h3 {
  font-size: clamp(1.15rem, 1.7vw, 1.4rem);
}

/* Card headings must reveal the full condition or test name. */
.cms-card .cms-card-title,
.dd-spec-card__title,
.dd-conditions.dd-conditions--light .dd-spec-card__title,
.dd-cms-index--specialties .cms-card--specialty .cms-card-title,
.dd-diag-card__title,
.dd-pathway__card-title {
  font-family: var(--tr-font-display);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.2;
  text-wrap: balance;
  overflow-wrap: anywhere;
  display: block;
  -webkit-line-clamp: unset;
  line-clamp: unset;
  overflow: visible;
}

.cms-card .cms-card-title,
.dd-diag-card__title {
  font-size: clamp(1.22rem, 1.5vw, 1.4rem);
}

.dd-cms-index--specialties .cms-card--specialty .cms-card-title,
.dd-conditions.dd-conditions--light .dd-spec-card__title {
  font-size: clamp(1.34rem, 1.65vw, 1.72rem);
}

/* Numbered section labels echo the instrument panel without competing with
   the medical information. Smaller navigation labels keep their own size. */
.dd-section-eyebrow,
.dd-detail-hero__kicker,
.dd-aviation__eyebrow,
.dd-aviation__care-kicker,
.dd-pathway__kicker,
.dd-nvl-feature__eyebrow,
.dd-diag-card__eyebrow,
.dd-test-card__eyebrow,
.dd-media-card__kicker,
.dd-spec-card__tag,
.cms-card .cms-card-kicker,
.dd-cms-index--specialties .cms-card--specialty .cms-card-kicker,
.dd-cms-index--providers .cms-card--provider .cms-card-kicker,
.dd-bio__cred-label,
.dd-about__cred-label,
.dd-bio__sidebar h3,
.dd-nav__panel-eyebrow {
  font-family: var(--tr-font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.55;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.dd-detail-article p,
.dd-detail-article li,
.main-wrapper .w-richtext p,
.main-wrapper .w-richtext li,
.dd-bio__body p,
.dd-provider-bio__body p {
  line-height: 1.75;
}

.dd-detail-article p,
.dd-detail-article li,
.main-wrapper .w-richtext p,
.main-wrapper .w-richtext li {
  overflow-wrap: break-word;
}

/* Let grid/flex children shrink around long medical names at narrow widths. */
.dd-cms-hero__inner > *,
.dd-detail-hero__inner > *,
.dd-detail-shell > *,
.dd-aviation__hero-grid > *,
.dd-aviation__section-heading > *,
.dd-aviation__aerospace-grid > *,
.dd-spec-card__body,
.cms-card-body,
.dd-diag-card__content {
  min-width: 0;
}

@media (max-width: 640px) {
  .dd-cms-hero h1,
  .dd-detail-hero h1 {
    font-size: clamp(2.1rem, 8.4vw, 3rem);
    line-height: 1.12;
  }

  .dd-section-eyebrow,
  .dd-detail-hero__kicker,
  .dd-aviation__eyebrow {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
  }
}
