/* askmidge.ai in Hannah's brand (her tokens, approved 10-29), laid out as
   Leif's image of 11-02: the wordmark in ink on gray-green, her line on a
   citron pill, the paragraph, then an ivory card with a hairline holding the
   sign-up form, a pill field and a spruce pill button. Dark mode follows her
   dark tokens. Every colour is a token in :root; the page's CSP loads this
   file and refuses any style written into the pages themselves. */

/* Gelasio and Inter, served from fonts/ beside this file (SIL Open Font
   License; the licences are in fonts/), so the page loads nothing from
   another address. Only the weights it uses. */
@font-face { font-family: "Gelasio"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/gelasio-400.ttf") format("truetype"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/inter-400.ttf") format("truetype"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/inter-600.ttf") format("truetype"); }

:root {
  color-scheme: light dark;
  --text: #243B46;
  --text-2: #5B6B70;
  --page: #F2F3EF;
  --card: #FFFEFA;
  --hairline: #DCE2DE;
  --border: #6E7E78;
  --action: #2F5D4F;
  --on-action: #FFFEFA;
  --brand: #C8DC5A;
  --on-brand: #243B46;
  --diamond-edge: #243B46;
  --focus: #2F5D4F;
  --serif: "Gelasio", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --text: #FFFEFA;
    --text-2: #A9B6B9;
    --page: #15232A;
    --card: #1E3039;
    --hairline: #8A9AA0;
    --border: #8A9AA0;
    --action: #7DB39E;
    --on-action: #15232A;
    --brand: #D5E4AA;
    --on-brand: #15232A;
    --diamond-edge: #D5E4AA;
    --focus: #7DB39E;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--page);
  color: var(--text);
  font: 400 17px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}
p { margin: 0; }
a { color: var(--action); text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
/* A 16px gutter each side on a phone. */
.wrap { width: min(100% - 32px, 44rem); margin-inline: auto; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
/* The form's trap for bots: off the screen here, and out of the tab order
   and hidden from screen readers in the page, so only a bot fills it in. */
.hidden {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

main { flex: 1; padding-block: clamp(48px, 10vh, 112px) 40px; }

.wordmark { margin: 0; font: 400 clamp(72px, 19vw, 120px)/1 var(--serif); letter-spacing: -.01em; }
.wordmark i { position: relative; font-style: normal; }
/* The citron diamond where the i's dot sat. Citron alone is too faint on a
   light ground, so it has a 1px ink edge; at night the edge is its own
   colour. */
.wordmark i::after {
  content: "";
  position: absolute;
  left: .09em;
  top: .228em;
  width: .115em;
  height: .115em;
  background: var(--brand);
  border: 1px solid var(--diamond-edge);
  transform: rotate(45deg);
}
.tagline {
  display: inline-block;
  margin-top: 16px;
  padding: 6px 16px;
  border-radius: 8px;
  background: var(--brand);
  color: var(--on-brand);
  font: 600 clamp(19px, 4.6vw, 24px)/1.3 var(--sans);
}
.intro { margin-top: 32px; font-size: clamp(18px, 2.4vw, 21px); line-height: 1.6; }

.card {
  margin-top: 40px;
  padding: 28px 20px;
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: 16px;
}
.card h2 { margin: 0; font: 600 22px/1.3 var(--sans); }
.sub { margin-top: 6px; color: var(--text-2); }
.message { margin-top: 16px; font-weight: 600; }
.join { margin-top: 20px; }
.join .row { display: flex; flex-direction: column; gap: 12px; }
.join input {
  flex: 1;
  width: 100%;
  min-width: 0;
  min-height: 52px;
  padding: 12px 22px;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  background: var(--card);
  color: var(--text);
  font: inherit;
}
.join input::placeholder { color: var(--text-2); opacity: 1; }
.join button {
  flex: none;
  min-height: 52px;
  padding: 0 28px;
  border: 0;
  border-radius: 999px;
  background: var(--action);
  color: var(--on-action);
  font: 600 17px/1 var(--sans);
  cursor: pointer;
}
.share { margin-top: 20px; color: var(--text-2); }
.share a { font-weight: 600; white-space: nowrap; }
.disclaimer { margin-top: 32px; font-size: 15px; color: var(--text-2); }
.disclaimer a, footer a { color: var(--text); }
footer { padding-block: 40px 32px; font-size: 15px; color: var(--text-2); }

/* The field and the button side by side once there's room. */
@media (min-width: 480px) {
  .card { padding: 36px 40px 32px; }
  .join .row { flex-direction: row; }
}

/* Privacy */
.doc h1 { margin: 0 0 16px; font: 400 clamp(44px, 10vw, 56px)/1.1 var(--serif); }
.doc h2 { margin: 40px 0 0; padding-top: 24px; border-top: 1px solid var(--hairline); font: 400 28px/1.25 var(--serif); }
.doc h3 { margin: 24px 0 6px; font: 600 17px/1.4 var(--sans); }
.doc h2 + p, .doc p + p { margin-top: 12px; }

/* The newsletter box (issue 550): optional and unticked, under the field and the
   button. A plain checkbox in the action colour, not the pill the email
   field is, with its words beside it. */
.opt-in { display: flex; align-items: flex-start; gap: 10px; margin-top: 16px; }
.join .opt-in input {
  flex: none;
  width: 22px;
  min-width: 0;
  height: 22px;
  min-height: 0;
  margin: 1px 0 0;
  padding: 0;
  accent-color: var(--action);
  cursor: pointer;
}
.opt-in label { cursor: pointer; }
