/* Geist, Newsreader and Geist Mono, self-hosted under the SIL Open Font License (see /fonts/OFL-*.txt). */
@font-face { font-family: "Geist"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("/fonts/geist-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("/fonts/geist-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap; src: url("/fonts/newsreader-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap; src: url("/fonts/newsreader-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("/fonts/geist-mono-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Geist Mono"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("/fonts/geist-mono-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --bg: #000;
  --k-1: #0a0a0a;
  --k-2: #141414;
  --k-3: #1f1f1f;
  --k-4: #2d2d2d;
  --k-5: #444;
  --k-6: #6a6a6a;
  --k-7: #8f8f8f;
  --k-8: #c2c2c2;
  --k-9: #ededed;
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Newsreader", ui-serif, Georgia, serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { background: var(--bg); -webkit-text-size-adjust: 100%; }

body {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  grid-template-columns: minmax(0, 1fr);
  padding: max(var(--gutter), env(safe-area-inset-top)) var(--gutter) max(var(--gutter), env(safe-area-inset-bottom));
  background: var(--bg);
  color: var(--k-7);
  font: 400 1.125rem/1.6 var(--serif);
  -webkit-font-smoothing: antialiased;
  font-kerning: normal;
}

::selection { background: var(--k-4); color: var(--k-9); }

a { color: var(--k-8); text-decoration: none; transition: color .3s; }
a:hover { color: var(--k-9); }

:focus-visible { outline: 1px dashed var(--k-6); outline-offset: 4px; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Frame */

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font: 400 .8125rem/1.4 var(--mono);
  color: var(--k-6);
}

.mark { display: inline-flex; align-items: center; gap: .55em; color: var(--k-6); }
.mark:hover { color: var(--k-9); }

.cursor {
  display: inline-block;
  flex: none;
  width: .58em;
  height: 1.05em;
  background: currentColor;
  animation: blink 1.2s steps(1) infinite;
}

@keyframes blink { 50% { opacity: 0; } }

.who { display: flex; gap: 1.2rem; align-items: center; }
.who button { border: 0; background: none; color: var(--k-6); font: inherit; cursor: pointer; }
.who button:hover { color: var(--k-9); }

/* Oversized statement: Geist, with a Newsreader word as the accent. */

main { align-self: center; width: 100%; padding: clamp(3rem, 10vh, 6rem) 0; }

.big {
  font: 600 clamp(3.25rem, 10.5vw, 11.5rem)/.9 var(--sans);
  letter-spacing: -.055em;
  color: var(--k-5);
  text-wrap: balance;
}

.big .accent {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -.035em;
  color: var(--k-9);
}

.big .line { display: block; }

.lede {
  max-width: 48rem;
  margin-top: clamp(1.75rem, 4vh, 2.75rem);
  font: 400 clamp(1.1rem, 1.85vw, 1.55rem)/1.5 var(--serif);
  color: var(--k-7);
}

.lede strong { font-weight: 600; color: var(--k-9); }

/* One sentence per line. */
.lede .s { display: block; }

/* Steps */

.step[hidden] { display: none; }
.step { animation: arrive .9s var(--ease) both; }

@keyframes arrive { from { opacity: 0; transform: translateY(.5rem); } to { opacity: 1; transform: none; } }

.entry {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 1.25rem 2rem;
  max-width: 54rem;
  margin-top: clamp(2.25rem, 6vh, 3.5rem);
}

.field {
  flex: 1 1 22rem;
  display: block;
  border-bottom: 1px solid var(--k-4);
  transition: border-color .4s var(--ease);
}

.field:focus-within { border-color: var(--k-7); }

.field input, .ask {
  width: 100%;
  padding: .25rem 0 .7rem;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--k-9);
  caret-color: var(--k-9);
  font: 500 clamp(1.6rem, 3.2vw, 2.6rem)/1.15 var(--sans);
  letter-spacing: -.025em;
}

.field input::placeholder, .ask::placeholder { color: var(--k-4); opacity: 1; }
.field input:focus-visible, .ask:focus-visible { outline: none; }

.field.code input {
  font: 500 clamp(2.4rem, 6vw, 4.5rem)/1 var(--mono);
  letter-spacing: .32em;
}

.go {
  display: inline-flex;
  align-items: center;
  gap: .7em;
  padding: 1em 1.4em;
  border: 1px solid var(--k-4);
  border-radius: 999px;
  background: var(--k-1);
  color: var(--k-9);
  font: 500 .9375rem/1 var(--mono);
  cursor: pointer;
  transition: border-color .35s var(--ease), background .35s var(--ease), opacity .35s;
}

.go:hover { border-color: var(--k-6); background: var(--k-2); }
.go[disabled] { opacity: .45; cursor: progress; }
.go .cursor { width: .55em; height: 1em; }

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

.status { min-height: 1.6em; margin-top: 1.25rem; font: 400 .875rem/1.5 var(--mono); color: var(--k-8); }

.aside { display: flex; flex-wrap: wrap; gap: .5rem 1.75rem; margin-top: 1.5rem; font: 400 .8125rem/1.5 var(--mono); }
.aside button { border: 0; background: none; color: var(--k-6); font: inherit; cursor: pointer; padding: 0; }
.aside button:hover:not([disabled]) { color: var(--k-9); }
.aside button[disabled] { color: var(--k-4); cursor: default; }

/* Create */

.ask {
  display: block;
  max-width: 54rem;
  min-height: 1.4em;
  margin-top: clamp(2.25rem, 6vh, 3.5rem);
  padding-bottom: .9rem;
  border-bottom: 1px solid var(--k-4);
  font: 400 clamp(1.4rem, 2.4vw, 2rem)/1.4 var(--serif);
  letter-spacing: -.01em;
  resize: none;
  overflow: hidden;
  transition: border-color .4s var(--ease);
}

.ask:focus { border-color: var(--k-7); }

.finish {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
  max-width: 54rem;
  margin-top: 1.5rem;
}

.when { font: 400 .875rem/1.5 var(--mono); color: var(--k-6); }

.when select {
  margin-left: .4em;
  padding: 0 .1em .1em;
  border: 0;
  border-bottom: 1px solid var(--k-4);
  border-radius: 0;
  background: transparent;
  color: var(--k-9);
  font: inherit;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.when select option { background: #111; color: var(--k-9); }

.ref {
  display: inline-block;
  margin-top: 2rem;
  padding: .5em .85em;
  border: 1px solid var(--k-3);
  font: 400 .8125rem/1 var(--mono);
  color: var(--k-8);
}

/* Footer */

.foot { flex-wrap: wrap; color: var(--k-5); }
.foot a { color: var(--k-6); }
.foot a:hover { color: var(--k-9); }

@media (hover: none) { .keys { display: none; } }

@media (max-width: 640px) {
  .bar { font-size: .75rem; }
  .who { gap: .9rem; }
  .who .addr { max-width: 11rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .go { width: 100%; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
