:root {
  --night: #050506;
  --dot: #ffffff;
  --light: #8fb8ff;
  --core: #eef4ff;
  --ink: #f4f5f8;
  --ink-soft: #8f93a0;
  --ink-lede: #c6c9d3;
  --line: rgba(255, 255, 255, 0.11);
  --field: rgba(12, 13, 17, 0.78);
  --send: #f4f5f8;
  --send-ink: #07080b;
  --font: "Mona Sans Variable", "Mona Sans", system-ui, sans-serif;
}

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

html, body { height: 100%; }

body {
  background: var(--night);
  color: var(--ink);
  font-family: var(--font);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

.stage {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 300px;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  /* what is left without canvas: the same grid of dots, still, in CSS */
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.16) 0.9px, transparent 1.4px) 0 0 / 18px 18px,
    var(--night);
}

.dots {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  display: block;
  background: var(--night);
}

/* the edges fall into the night, so the grid has no hard border and the words stay in front */
.vignette {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 62% at 50% 50%, transparent 40%, rgba(5, 5, 6, 0.78) 100%),
    radial-gradient(ellipse 30% 22% at 50% 46%, rgba(5, 5, 6, 0.38), transparent 100%);
}

.hero {
  width: min(600px, 100% - 32px);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: clamp(12px, 3vh, 26px);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 11px 4px 4px;
  border-radius: 999px;
  background: rgba(10, 11, 14, 0.7);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  font-size: clamp(11px, 1.7vh, 13px);
  color: var(--ink-lede);
  white-space: nowrap;
}

.pill__tag {
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(143, 184, 255, 0.14);
  color: var(--light);
  font-weight: 560;
  font-variation-settings: "wdth" 110;
}

.title {
  font-size: clamp(28px, min(7.4vw, 8.6vh), 64px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  font-weight: 620;
  font-variation-settings: "wdth" 92;
  text-shadow: 0 0 40px var(--night), 0 0 18px var(--night);
}

.title__soft { color: var(--ink-soft); font-weight: 520; }

/* the prompt: a dark field with a thin rim; the rim catches the light near the caret */
.prompt {
  position: relative;
  width: min(520px, 100%);
  height: clamp(46px, 8vh, 56px);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 7px 0 18px;
  border-radius: 16px;
  background: var(--field);
  border: 1px solid var(--line);
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.prompt__rim {
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  pointer-events: none;
  background: radial-gradient(140px 60px at var(--rx, 20%) 50%, rgba(143, 184, 255, 0.9), rgba(143, 184, 255, 0) 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: var(--rim, 0);
}

.prompt__field {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 100%;
  display: flex;
  align-items: center;
}

.prompt__input {
  width: 100%;
  background: none;
  border: 0;
  outline: 0;
  color: var(--ink);
  font: inherit;
  font-size: clamp(14px, 2.3vh, 16px);
  letter-spacing: -0.005em;
  caret-color: var(--light);
}

.prompt__input::placeholder { color: #5d616c; }

/* an invisible copy of the text, only to measure where the caret is */
.prompt__mirror {
  position: absolute;
  left: 0;
  top: 50%;
  visibility: hidden;
  white-space: pre;
  font-size: clamp(14px, 2.3vh, 16px);
  letter-spacing: -0.005em;
}

.send {
  flex: none;
  width: clamp(32px, 5.6vh, 40px);
  height: clamp(32px, 5.6vh, 40px);
  border: 0;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: var(--send);
  color: var(--send-ink);
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.5) inset, 0 6px 16px -8px rgba(143, 184, 255, 0.6);
}

.send svg {
  width: 52%;
  height: 52%;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.send:focus-visible, .prompt__input:focus-visible { outline: none; }
.prompt:focus-within { border-color: rgba(143, 184, 255, 0.32); }

.hint {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: clamp(11px, 1.7vh, 12.5px);
  color: var(--ink-soft);
  text-shadow: 0 0 14px var(--night);
}

.hint__key {
  padding: 1px 6px;
  border-radius: 5px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  color: var(--ink-lede);
  font-size: 0.92em;
}

.hint__sep { width: 1px; height: 11px; background: var(--line); }

.sr {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (hover: hover) {
  .send:hover { background: #ffffff; }
}

@media (max-width: 420px) {
  .hint__sep, [data-status] { display: none; }
}
