@font-face {
  font-family: Meteon;
  src: url("/fonts/MeteonVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --text: #161616;
  --muted: #6b6b6b;
  --background: #fbfaf7;
  --field: #ffffff;
  --line: #d9d6cf;
  --problem: #b3261e;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --text: #f2f0eb;
    --muted: #a19e97;
    --background: #141413;
    --field: #1e1e1c;
    --line: #3a3936;
    --problem: #f2b8b5;
  }

  .mark img {
    filter: invert(1);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 48px 16px;
  background: var(--background);
  color: var(--text);
  font:
    17px/1.5 Inter,
    system-ui,
    -apple-system,
    sans-serif;
}

main {
  width: 100%;
  max-width: 480px;
}

.mark {
  display: inline-block;
  margin-bottom: 24px;
}

h1 {
  margin: 0 0 12px;
  font:
    600 40px/1.1 Meteon,
    Inter,
    system-ui,
    sans-serif;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 20px;
}

a {
  color: inherit;
}

.button,
button {
  display: inline-block;
  margin: 8px 0 20px;
  padding: 12px 22px;
  border: 0;
  border-radius: 999px;
  background: var(--text);
  color: var(--background);
  font: 500 17px/1.2 inherit;
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
}

.button:hover,
button:hover {
  opacity: 0.85;
}

.button:active,
button:active {
  opacity: 0.7;
}

.button:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 2px;
}

.hint {
  color: var(--muted);
  font-size: 15px;
}

.hint.problem {
  color: var(--problem);
}

.key {
  display: block;
  margin: 0 0 20px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--field);
  font:
    13px/1.5 ui-monospace,
    SFMono-Regular,
    Menlo,
    monospace;
  overflow-wrap: anywhere;
  user-select: all;
}

form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

input {
  flex: 1 1 240px;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--field);
  color: inherit;
  font: inherit;
}

form button {
  margin: 0;
  /* As wide as "Email it to me", so "Sending…" doesn't move the form. */
  min-width: 9.5em;
}

button[aria-disabled="true"] {
  opacity: 0.6;
  cursor: progress;
}
