/* Владимир 2040 · Роли типографики сайта. */
@font-face {
  font-family: Prata;
  src: url('assets/Prata-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Onest;
  src: url('assets/Onest-Variable.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root {
  --font-display: 'Prata', Georgia, 'Times New Roman', serif;
  --font-text: 'Onest', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --weight-display: 400;
  --weight-body: 300;
  --weight-ui: 400;
  --weight-emphasis: 500;

  --text-title-size: 4rem;
  --text-title-line: 1.21875;
  --text-title-spacing: normal;
  --text-section-size: 2.75rem;
  --text-section-line: 1.272727;
  --text-section-spacing: normal;
  --text-heading-size: 1.625rem;
  --text-heading-line: 1.384615;
  --text-heading-spacing: -.015em;
  --text-lead-size: 1.375rem;
  --text-lead-line: 1.545454;
  --text-body-size: 1.125rem;
  --text-body-line: 1.555555;
  --text-body-compact-size: 1rem;
  --text-body-compact-line: 1.625;
  --text-ui-size: 1rem;
  --text-ui-line: 1.5;
  --text-caption-size: .875rem;
  --text-caption-line: 1.428571;
}
.type-title { font: var(--weight-display) var(--text-title-size)/var(--text-title-line) var(--font-display); letter-spacing: var(--text-title-spacing); }
.type-section { font: var(--weight-display) var(--text-section-size)/var(--text-section-line) var(--font-display); letter-spacing: var(--text-section-spacing); }
.type-heading { font: var(--weight-emphasis) var(--text-heading-size)/var(--text-heading-line) var(--font-text); letter-spacing: var(--text-heading-spacing); }
.type-lead { font: var(--weight-body) var(--text-lead-size)/var(--text-lead-line) var(--font-text); }
.type-body { font: var(--weight-body) var(--text-body-size)/var(--text-body-line) var(--font-text); }
.type-ui { font: var(--weight-ui) var(--text-ui-size)/var(--text-ui-line) var(--font-text); }
.type-caption { font: var(--weight-ui) var(--text-caption-size)/var(--text-caption-line) var(--font-text); }
strong, .type-emphasis { font-family: var(--font-text); font-weight: var(--weight-emphasis); }
@media (max-width: 760px) {
  :root {
    --text-title-size: 2.5rem;
    --text-title-line: 1.25;
    --text-section-size: 2rem;
    --text-section-line: 1.3125;
    --text-heading-size: 1.375rem;
    --text-heading-line: 1.363636;
    --text-lead-size: 1.25rem;
    --text-lead-line: 1.5;
    --text-body-size: 1rem;
    --text-body-line: 1.625;
  }
}

@media (max-width: 360px) {
  :root { --text-title-size: 2.25rem; }
}

/* Cover headings respond to the available width inside the component. */
.type-cover {
  font: var(--weight-display) 2rem/1.25 var(--font-display);
  font-size: clamp(1.125rem, 11cqi, 2.5rem);
  letter-spacing: normal;
  text-wrap: balance;
}
