*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-surface);
  line-height: var(--line-height-base);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

/* Headings use the serif family (Lora), body uses the sans family (Onest, inherited from body). */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--color-text);
}

h1 { font-size: var(--text-1); line-height: var(--line-height-heading); font-weight: var(--weight-bold); }
h2 { font-size: var(--text-2); line-height: var(--line-height-heading); font-weight: var(--weight-bold); }
h3 { font-size: var(--text-3); line-height: var(--line-height-heading); font-weight: var(--weight-medium); }

/* Body copy: one size, one color. Width matches the container max-width (same
   as headings and card/callout blocks) so text blocks don't vary in width
   within a page. */
p {
  font-size: var(--text-4);
  font-weight: var(--weight-regular);
  line-height: var(--line-height-base);
  color: var(--color-text);
}

small { font-size: var(--text-4); line-height: var(--line-height-base); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-primary);
  color: var(--color-on-dark);
  padding: 0.75rem 1.25rem;
  z-index: 1000;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

:focus-visible {
  outline: 2px solid var(--color-secondary);
  outline-offset: 2px;
}
