/* ==========================================================================
   Base Styles — Reset, Typography, Global Elements
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: var(--lh-body);
  color: var(--slate);
  background-color: var(--surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--teal);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--teal-dark);
}

ul,
ol {
  list-style: none;
}

button {
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--navy);
  font-weight: 700;
}

h1 {
  font-size: var(--text-hero);
  line-height: var(--lh-hero);
}

h2 {
  font-size: var(--text-page);
  line-height: var(--lh-page);
  font-weight: 700;
}

h3 {
  font-size: var(--text-section);
  line-height: var(--lh-section);
  font-weight: 600;
}

h4 {
  font-size: var(--text-subsection);
  line-height: var(--lh-subsection);
  font-weight: 600;
}

p {
  max-width: 72ch;
}

.text-lg {
  font-size: var(--text-lg);
  line-height: var(--lh-body);
}

.text-sm {
  font-size: var(--text-sm);
  font-weight: 500;
  line-height: var(--lh-sm);
}

.text-micro {
  font-size: var(--text-micro);
  font-weight: 500;
  line-height: var(--lh-micro);
}

/* Selection */
::selection {
  background-color: var(--teal);
  color: var(--white);
}
