@font-face {
  font-family: "Matridge Sans";
  src: url("fonts/MatridgeSans-Variable.woff2") format("woff2-variations");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
}

html {
  color-scheme: light;
}

body {
  background: #ffffff;
  color: #000000;
  font-family: "Matridge Sans", Arial, sans-serif;
  transition: background-color 180ms ease, color 180ms ease;
}

body.is-dark {
  background: #000000;
  color: #ffffff;
}

.page {
  position: relative;
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 32px;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 0.75vw, 12px);
  transform: translateY(-2px);
}

.icon-toggle {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.icon-toggle:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 8px;
}

/* The logo art is white; invert it to black on the light page, show it
   as-is in dark mode. */
.brand-logo {
  display: block;
  width: clamp(320px, 33vw, 480px);
  height: auto;
  filter: invert(1);
}

body.is-dark .brand-logo {
  filter: none;
}

.email {
  position: absolute;
  bottom: clamp(54px, 8vh, 94px);
  left: 50%;
  padding: 0;
  border: 0;
  color: #000000;
  background: transparent;
  cursor: pointer;
  font-family: "Matridge Sans", Arial, sans-serif;
  font-size: clamp(15px, 1.2vw, 18px);
  font-weight: 400;
  opacity: 0.55;
  transition: opacity 140ms ease;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  transform: translateX(-50%);
  white-space: nowrap;
}

body.is-dark .email {
  color: #ffffff;
}

.email:hover {
  opacity: 1;
}

.email:focus-visible {
  outline: 2px solid #000000;
  outline-offset: 8px;
}

.email-copied {
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 180ms ease;
}

.email.is-copied .email-copied {
  opacity: 1;
}

@media (max-width: 560px) {
  .page {
    padding: 24px;
  }

  .brand {
    gap: 8px;
  }

  .brand-logo {
    width: clamp(240px, 78vw, 330px);
  }

  .email {
    bottom: 48px;
    font-size: clamp(22px, 6.6vw, 29px);
  }
}

/* Read3d, quietly in the corner. */
.read3d-link {
  position: fixed;
  top: 22px;
  right: 26px;
  z-index: 10;
  display: block;
  line-height: 0;
  color: #000000;
  opacity: 0.75;
  transition: opacity 140ms ease, transform 140ms ease;
}
.read3d-link:hover { opacity: 1; transform: translateY(-1px); }
.read3d-link svg { display: block; height: 19px; width: 91px; }
body.is-dark .read3d-link { color: #ffffff; }
