@font-face {
  font-family: "Michroma";
  src: url("/fonts/michroma-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-grotesk-300.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Hanken Grotesk";
  src: url("/fonts/hanken-grotesk-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --ground: #000000;
  --lift: #0d0d10;
  --name: #ffffff;
  --tagline: #f2f2f2;
  --body: #ededed;
  --muted: #bdbdbd;
  --label: #a6a6a6;
  --footer: #8a8a8a;
  --rule: #5a5a5a;
  --field-rule: #3a3a3a;
  --panel: #050505;
  --panel-edge: #222222;
  --wide: "Michroma", "Arial", sans-serif;
  --text: "Hanken Grotesk", "Helvetica Neue", "Arial", sans-serif;
}

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

html {
  color-scheme: dark;
  background: var(--ground);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: radial-gradient(ellipse at 50% 38%, var(--lift) 0%, var(--ground) 55%) fixed;
  color: var(--body);
  font-family: var(--text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Background drawing and the dark oval that keeps the text readable over it */

.tesseract {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.halo {
  position: fixed;
  left: 50%;
  top: 48%;
  width: min(1000px, 150vw);
  height: min(500px, 110vw);
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.75) 38%, rgba(0, 0, 0, 0) 70%);
  z-index: 1;
  pointer-events: none;
}

/* Main text column */

.hero {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 48px 16px 24px;
  text-align: center;
}

.hero p {
  margin: 0;
}

.name {
  margin: 0 0 6px;
  padding-left: 0.42em;
  font-family: var(--wide);
  font-size: clamp(44px, 12vw, 96px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--name);
}

.tagline {
  font-size: clamp(22px, 6vw, 34px);
  font-weight: 300;
  line-height: 1.2;
  color: var(--tagline);
}

.category {
  padding-left: 0.4em;
  font-family: var(--wide);
  font-size: clamp(9px, 2.6vw, 12px);
  line-height: 1.8;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--muted);
}

.stage {
  margin-top: 4px;
  font-size: 15px;
  color: var(--muted);
}

.contact-open-row {
  margin-top: 10px;
}

/* Underlined text buttons */

.text-button {
  display: inline-flex;
  align-items: flex-end;
  min-height: 44px;
  padding: 0 2px 6px;
  background: none;
  border: 0;
  border-bottom: 1px solid var(--rule);
  color: var(--body);
  font-family: var(--wide);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.4em;
  cursor: pointer;
}

.text-button:hover {
  border-bottom-color: var(--body);
}

.text-button:disabled {
  opacity: 0.5;
  cursor: progress;
}

/* The contact button only works with scripts on, so it stays hidden without them */

.contact-open {
  visibility: hidden;
}

.has-js .contact-open {
  visibility: visible;
}

:focus-visible {
  outline: 1px solid var(--body);
  outline-offset: 4px;
}

/* Footer */

.footer {
  position: relative;
  z-index: 2;
  padding: 40px 16px 28px;
  background: linear-gradient(to top, var(--ground) 70%, rgba(0, 0, 0, 0));
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.14em;
  line-height: 1.8;
  color: var(--footer);
}

.footer p {
  margin: 0;
}

.footer a {
  color: var(--footer);
  text-underline-offset: 3px;
}

.footer a:hover {
  color: var(--body);
}

/* Contact panel */

.contact {
  width: min(440px, calc(100vw - 32px));
  max-height: calc(100svh - 32px);
  padding: 0;
  background: var(--panel);
  border: 1px solid var(--panel-edge);
  color: var(--body);
  font-family: var(--text);
}

.contact::backdrop {
  background: rgba(0, 0, 0, 0.78);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 26px;
  padding: 40px;
}

.contact-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-right: -12px;
}

.contact-title {
  margin: 0;
  font-family: var(--wide);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.4em;
}

.contact-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  background: none;
  border: 0;
  color: var(--label);
  cursor: pointer;
}

.contact-close:hover {
  color: var(--body);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.field label {
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--label);
}

.field input,
.field textarea {
  width: 100%;
  padding: 8px 0 10px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--field-rule);
  border-radius: 0;
  color: var(--body);
  font-family: var(--text);
  font-size: 17px;
  font-weight: 300;
  resize: none;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-bottom-color: var(--body);
}

.field [aria-invalid="true"] {
  border-bottom-color: var(--muted);
}

.field-error {
  margin: 6px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.contact-send {
  align-self: flex-start;
}

.contact-status {
  margin: -8px 0 0;
  min-height: 1.4em;
  font-size: 15px;
  color: var(--muted);
}

.trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Entrance: each line fades up out of a slight blur, in order */

.rise {
  opacity: 0;
  animation: rise 1.6s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}

.rise-1 { animation-delay: 0.2s; }
.rise-2 { animation-delay: 0.7s; }
.rise-3 { animation-delay: 1.2s; }
.rise-4 { animation-delay: 1.7s; }

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
    filter: blur(6px);
  }
  to {
    opacity: 1;
    transform: none;
    filter: none;
  }
}

/* Small screens */

@media (max-width: 600px) {
  .hero {
    gap: 12px;
  }

  .stage {
    font-size: 14px;
  }

  .contact-form {
    gap: 22px;
    padding: 24px;
  }
}

/* Short screens, such as phones held sideways */

@media (max-height: 500px) {
  .hero {
    gap: 8px;
    padding-top: 24px;
  }

  .name {
    font-size: 40px;
  }

  .tagline {
    font-size: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rise {
    opacity: 1;
    animation: none;
  }
}
