/* recalibrating.work: the one stylesheet.
   Mobile first. System fonts only: a page that promises to use an address for
   one thing should not hand every visitor's IP to a font server before the
   promise is read. */

:root {
  --paper: #f7f3ec;
  --paper-deep: #efe8dc;
  --ink: #23201b;
  --ink-soft: #5c554b;
  --rule: #d9d0c2;
  --accent: #8a5a2b;
  --accent-deep: #6e4620;
  --ok: #3f6b45;
  --warn: #9a4a33;
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", "Book Antiqua", "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --measure: 36rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1d1b18;
    --paper-deep: #26231f;
    --ink: #ece6da;
    --ink-soft: #b3aa9b;
    --rule: #3d382f;
    --accent: #d2a06a;
    --accent-deep: #e5b985;
    --ok: #9fcaa5;
    --warn: #e39b85;
  }
}

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

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

main {
  flex: 1;
  width: 100%;
  max-width: var(--measure);
  margin: 0 auto;
  padding: 3.5rem 1.25rem 2.5rem;
}

h1 {
  font-weight: 400;
  font-size: 2rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 0.75rem;
}

.strap {
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--ink-soft);
  margin: 0 0 2.25rem;
}

p { margin: 0 0 1.25rem; }

a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover, a:focus-visible { color: var(--accent-deep); }

/* The form */

.signup {
  margin: 2.5rem 0 0;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--rule);
}

.signup label {
  display: block;
  font-family: var(--sans);
  font-size: 0.9375rem;
  color: var(--ink-soft);
  margin-bottom: 0.5rem;
}

.signup .row {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.signup input[type="email"] {
  font: inherit;
  font-family: var(--sans);
  font-size: 1rem;
  width: 100%;
  padding: 0.75rem 0.9rem;
  color: var(--ink);
  background: var(--paper-deep);
  border: 1px solid var(--rule);
  border-radius: 4px;
}

.signup input[type="email"]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.signup button {
  font: inherit;
  font-family: var(--sans);
  font-size: 1rem;
  padding: 0.75rem 1.25rem;
  color: var(--paper);
  background: var(--accent);
  border: 0;
  border-radius: 4px;
  cursor: pointer;
}

.signup button:hover, .signup button:focus-visible { background: var(--accent-deep); }
.signup button:disabled { opacity: 0.6; cursor: default; }

/* The honeypot. Hidden from people, present for bots. */
.signup .other { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.signup .message {
  font-family: var(--sans);
  font-size: 0.9375rem;
  min-height: 1.5em;
  margin: 0.75rem 0 0;
}

.signup .message.ok { color: var(--ok); }
.signup .message.warn { color: var(--warn); }

.promise {
  font-family: var(--sans);
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 1rem 0 0;
}

/* The foot */

footer {
  width: 100%;
  max-width: var(--measure);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2.5rem;
  border-top: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

footer p { margin: 0 0 0.9rem; }
footer p:last-child { margin-bottom: 0; }

@media (min-width: 40em) {
  main { padding-top: 5.5rem; }
  h1 { font-size: 2.5rem; }
  .signup .row { flex-direction: row; }
  .signup input[type="email"] { flex: 1; }
}
