/* ==========================================================================
   Momo · Meet Momo sign-up (talk.html).
   Everything in the form is Kern's Eigen theme with Momo's poplar tint (kern-form.css, scoped to .ke, which is the body).
   This file places the column and gives the page the landing page's ground: its colour and its grain.
   ========================================================================== */
html { min-height: 100%; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; color-scheme: only light; }
/* The landing page's ground. Kern's base surface is set to the same colour, so the bar that holds the last
   button on the interests step matches the page behind it. */
body.ke { --theme-surface-base: #f2ede6; margin: 0; min-height: 100vh; min-height: 100dvh; background: #f2ede6 url("../img/grain.png") 0 0 / 128px 128px; color: var(--theme-label-primary); }
.su-page { box-sizing: border-box; width: 100%; max-width: 388px; margin: 0 auto; padding: calc(64px + env(safe-area-inset-top)) 24px 0; }
@media (min-width: 700px) { .su-page { padding-top: 128px; } }
.ke .ke-legal a { text-decoration: underline; text-underline-offset: 2px; }
.su-note { margin: 0; font: 400 15px/1.5 "Public Sans", system-ui, sans-serif; color: #524f4a; }
/* Cloudflare's check takes space only when it asks the person to do something. */
#turnstile { margin-top: 16px; }
#turnstile:empty { display: none; }
/* Arriving from the landing page: the pages cross-fade, and the "meet momo" that was pressed morphs into this page's
   main button (landing.js gives that link the same name). Browsers without cross-page view transitions just change page. */
@view-transition { navigation: auto; }
.su-page button[type="submit"] { view-transition-name: momo-sign-up; }
::view-transition-old(root) { animation: su-page-out .22s ease both; }
::view-transition-new(root) { animation: su-page-in .32s ease both; }
@keyframes su-page-out { to { opacity: 0; } }
@keyframes su-page-in { from { opacity: 0; } }
::view-transition-group(momo-sign-up) { animation-duration: .5s; animation-timing-function: cubic-bezier(.2,.8,.2,1); }
/* each step's title and controls rise in, one after the other */
#sign-up-form > div > * { animation: su-rise .45s cubic-bezier(.2,.8,.2,1) both; }
#sign-up-form > div > :nth-child(2) { animation-delay: .07s; }
@keyframes su-rise { from { opacity: 0; translate: 0 10px; } }
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  #sign-up-form > div > * { animation: none; }
}
/* A browser paints its own background on a field it filled in for you (pale yellow or blue on an iPhone). It is a
   square block on the input, drawn over the rounded border of the group the input sits in, so the border looks cut.
   The background is held off and clipped to the text, and the text keeps the theme's colour, so a filled field looks
   like a typed one. Kern has no rule for this yet. */
.ke input:-webkit-autofill,
.ke input:-webkit-autofill:hover,
.ke input:-webkit-autofill:focus,
.ke input:autofill {
  -webkit-text-fill-color: var(--theme-label-primary);
  caret-color: var(--theme-label-primary);
  -webkit-background-clip: text;
  background-clip: text;
  transition: background-color 100000s ease-out 0s;
  box-shadow: none;
}

/* The code step's keys fill the form's width, six large keys in two threes. Kern draws them 38px wide in a tray that hugs them. */
.ke .su-code { display: flex; align-items: stretch; width: 100%; }
.ke .su-code > div:first-child { width: 100%; }
.ke .su-code [data-slot="input-otp-tray"] { padding: 8px; border-radius: 20px; }
.ke .su-code [data-slot="input-otp-tray"] > div { gap: 6px !important; }
.ke .su-code [data-slot="input-otp-cell"] { flex: 1 1 0; width: auto; height: 60px; font-size: 28px; }
.ke .su-code [data-slot="input-otp-separator"] { width: 8px !important; }
