/*
  Josh's Custom CSS Reset
  https://www.joshwcomeau.com/css/custom-css-reset/
*/
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    interpolate-size: allow-keywords;
  }
}

body {
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

input,
button,
textarea,
select {
  font: inherit;
}

button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
  cursor: pointer;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}

p {
  text-wrap: pretty;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
  line-height: 1.2;
}

/*
  Generic Styles
*/
:root {
  /* colors */
  --color-green: #7ec242;
  --color-green-lighter: #c1e961;
  --color-green-lightest: #e3f9b1;
  --color-green-barely: #fcfff4;
  --color-purple: #6258b9;
  --color-purple-lighter: #b8b3ea;
  --color-purple-lightest: red;
  --color-purple-barely: #f8f7ff;
  --color-error: #d80037;
  --color-error-lighter: #ffe2d7;

  --color-pale: #eff3e6;

  /* default theme color */
  --th-color: var(--color-green);
  --th-color-lighter: var(--color-green-lighter);
  --th-color-lightest: var(--color-green-lightest);
  --th-color-barely: var(--color-green-barely);

  /* font and font metrics */
  --font-family: "wf-anek-latin", sans-serif;
  --fm-units-per-em: 2000;
  --fm-capital-height: 1278;
  --fm-ascender: 1800;
  --fm-descender: 400;
  --fm-line-gap: 0;
  --fm-line-height: calc(
    (var(--fm-ascender) + var(--fm-descender) + var(--fm-line-gap))
  );

  /* misc */
  --gutter: 1.5rem;
}

body {
  font-family: var(--font-family);
}

.bg-green-lightest {
  background-color: var(--color-green-lightest);
}

.bg-purple-barely {
  background-color: var(--color-purple-barely);
}

.th-green {
  --th-color: var(--color-green);
  --th-color-lighter: var(--color-green-lighter);
  --th-color-lightest: var(--color-green-lightest);
  --th-color-barely: var(--color-green-barely);
}

.th-purple {
  --th-color: var(--color-purple);
  --th-color-lighter: var(--color-purple-lighter);
  --th-color-lightest: var(--color-purple-lightest);
  --th-color-barely: var(--color-purple-barely);
}

.page-content {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;

  > * {
    width: 100%;
  }

  > .main-content {
    flex: 1;
  }
}

.container {
  max-width: calc(80rem + 2 * var(--gutter));
  margin: 0 auto;
  padding-inline: var(--gutter);
}

.rich-text {
  h2,
  h3,
  h4,
  h5,
  h6 {
    margin-top: 1em;
    margin-bottom: 0.5em;
    font-weight: 600;
  }

  p,
  ul,
  ol {
    margin-bottom: 0.75em;

    &:last-child {
      margin-bottom: 0;
    }
  }

  /* p:has(+ ul),
  p:has(+ ol) {
    margin-bottom: 0;
  } */

  ul {
    padding-left: 1.5em;
    list-style: "•";

    li {
      padding-left: 0.5em;
    }
  }

  ol {
    padding-left: 1.75em;
    list-style-type: decimal;

    li {
      padding-left: 0.25em;
    }

    ol {
      list-style-type: lower-alpha;

      ol {
        list-style-type: lower-roman;

        ol {
          list-style-type: decimal;

          ol {
            list-style-type: lower-alpha;
          }
        }
      }
    }
  }

  b,
  strong {
    font-weight: 700;
  }

  i,
  em {
    font-style: italic;
  }

  a {
    font-weight: 500;
    color: inherit;
    text-decoration: underline;

    &:hover {
      text-decoration: none;
    }
  }
}

.ratio-16x9 iframe,
iframe.ratio-16x9 {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}

.generic-page-header {
  padding-block: 4.75rem;

  @media (max-width: 575.98px) {
    padding-block: 2.5rem;
  }

  h1 {
    font-size: 2.25rem;
    line-height: 1.1;
    font-weight: 700;
    text-align: center;

    @media (max-width: 575.98px) {
      font-size: 1.75rem;
    }
  }
}

.generic-page-body {
  padding-block: 3.875rem;

  @media (max-width: 575.98px) {
    padding-block: 2.5rem;
  }

  .rich-text {
    max-width: 800px;
    margin-inline: auto;
    font-size: 1.125rem;

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