/*
  Made by Elly Loel - https://ellyloel.com/
  With inspiration from:
    - Josh W Comeau - https://courses.joshwcomeau.com/css-for-js/treasure-trove/010-global-styles/
    - Andy Bell - https://piccalil.li/blog/a-modern-css-reset/
    - Adam Argyle - https://unpkg.com/open-props@1.3.16/normalize.min.css / https://codepen.io/argyleink/pen/KKvRORE

  Notes:
    - `:where()` is used to lower specificity for easy overriding.
*/

* {
  margin: 0; padding: 0;
  line-height: calc(0.25rem + 1em + 0.25rem);
}

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

*:where(:not(fieldset, progress, meter)) {
  background-origin: border-box;
  background-repeat: no-repeat;
  border-style: solid;
  border-width: 0;
}

html {
  block-size: 100%;
  -webkit-text-size-adjust: none;

  &:focus-within {
    @media (prefers-reduced-motion: no-preference) {
      scroll-behavior: smooth;
    }
  }
}

body {
  min-block-size: 100%;
  scrollbar-gutter: stable both-edges;
  text-rendering: optimizeSpeed;
}

:where(audio, canvas, embed, iframe, img, object, svg, video) {
  display: block;
}

:where(img, svg, video) {
  block-size: auto;
  max-inline-size: 100%;
}

:where(svg) {
  fill: currentColor;
  stroke: none;

  &:where(:not([fill])) {
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  &:where(:not([width])) {
    inline-size: 5rem;
  }
}

:where(input, button, textarea, select),
:where(input[type="file"])::-webkit-file-upload-button {
  color: inherit;
  font: inherit;
  font-size: inherit;
  letter-spacing: inherit;
  word-spacing: inherit;
}

:where(textarea) {
  resize: vertical;

  @supports (resize: block) {
    resize: block;
  }
}

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

h1 {
  font-size: 2em;
}

:where(ul, ol) {
  list-style-position: inside;

  &[role="list"] {
    list-style: none;
  }
}

a:not([class]) {
  text-decoration-skip-ink: auto;
}

:where(a[href], area, button, input, label[for], select, summary, textarea, [tabindex]:not([tabindex*="-"])) {
  cursor: pointer;
  touch-action: manipulation;
}

:where(input[type="file"]) {
  cursor: auto;
}

:where(input[type="file"])::-webkit-file-upload-button,
:where(input[type="file"])::file-selector-button {
  cursor: pointer;
}

@media (prefers-reduced-motion: no-preference) {
  :focus-visible {
    transition: outline-offset 145ms cubic-bezier(0.25, 0, 0.4, 1);
  }

  :where(:not(:active)):focus-visible {
    transition-duration: 0.25s;
  }
}

:where(:not(:active)):focus-visible {
  outline-offset: 5px;
}

:where(button, button[type], input[type="button"], input[type="submit"], input[type="reset"]),
:where(input[type="file"])::-webkit-file-upload-button,
:where(input[type="file"])::file-selector-button {
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  user-select: none;
  text-align: center;
}

:where(button, button[type], input[type="button"], input[type="submit"], input[type="reset"])[disabled] {
  cursor: not-allowed;
}

/**/

.hide-text {
  border: none;
  color: transparent;
  font: 0 / 0 a;
  text-shadow: none;
}

.undershirt {
  margin-left: auto;
  margin-right: auto;
  max-width: 1200px;
  width: 100%;
}

@font-face {
  font-display: swap;
  font-family: "dap sans";
  font-style: normal;
  font-weight: 300;
  src: url("../type/bdo-grotesk/300.woff2") format("woff2");
}

@font-face {
  font-display: swap;
  font-family: "dap sans";
  font-style: normal;
  font-weight: 400;
  src: url("../type/bdo-grotesk/400.woff2") format("woff2");
}

@font-face {
  font-display: swap;
  font-family: "dap sans";
  font-style: normal;
  font-weight: 600;
  src: url("../type/bdo-grotesk/800.woff2") format("woff2");
}
