/* Shared look for the site's inner pages (privacy, the beta kit and its question pages, the 404). The same paper house as the
   landing page: a strip of sky with the name at the top, a room's wall to read on, and the street at the bottom. Daytime paper
   only. Colours are the app's own (C in miimii/app.html), with tomato kept for the things to press. The landing page keeps its
   own copy of these tokens inline so its first paint needs no extra request; when a token changes there, change it here too. */
/* the two typefaces, served from this site (the same files the landing page uses), so no page talks to a font service */
@font-face { font-family: "Young Serif"; font-style: normal; font-weight: 400; font-display: swap; src: url(/media/fonts/young-serif-latin-400-normal.woff2) format("woff2") }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 400; font-display: swap; src: url(/media/fonts/atkinson-hyperlegible-latin-400-normal.woff2) format("woff2") }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 700; font-display: swap; src: url(/media/fonts/atkinson-hyperlegible-latin-700-normal.woff2) format("woff2") }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: italic; font-weight: 400; font-display: swap; src: url(/media/fonts/atkinson-hyperlegible-latin-400-italic.woff2) format("woff2") }
:root {
  --ink: #2a2f38; --white: #fbf8f1; --cream: #f3ecdc; --tomato: #c65a48; --butter: #ebc867; --denim: #4f6d97; --sage: #a7be9a;
  --wood: #c49460; --floor: #c9a375; --grass: #8fae6b; --hill: #b4cba1; --path: #d9cdb6; --kerb: #c7bfae; --road: #8f9497;
  --sky: #ccd9d8; --wall: #f4ead6;
  --lift: 4px 6px 0 rgba(40, 28, 18, .13), 2px 3px 0 rgba(40, 28, 18, .10);
  --lift-lo: 2px 3px 0 rgba(40, 28, 18, .13), 1px 1.5px 0 rgba(40, 28, 18, .10);
  /* older names the question pages still use */
  --paper: var(--wall); --card: var(--white); --soft: var(--ink); --teal: var(--denim); --hill1: var(--hill); --hill2: var(--grass); --hill3: var(--grass);
  --rule: var(--floor); --shadow: rgba(40, 28, 18, .16);
  --display: "Young Serif", Georgia, "Times New Roman", serif; --body: "Atkinson Hyperlegible", "Segoe UI", system-ui, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box }
html { -webkit-text-size-adjust: 100% }
body { margin: 0; background: var(--wall); color: var(--ink); font: 400 1.0625rem/1.6 var(--body); -webkit-font-smoothing: antialiased; min-height: 100vh; display: flex; flex-direction: column }
body::after { content: ""; position: fixed; inset: 0; pointer-events: none; background: url(/media/grain.jpg) 0 0 / 300px; mix-blend-mode: multiply; opacity: .75; z-index: 50 }
main { flex: 1 }
.wrap { max-width: 760px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)) }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.15; text-wrap: balance; margin: 0 }
h1 { font-size: clamp(2rem, 4.2vw, 3rem); letter-spacing: -.01em }
h2 { font-size: clamp(1.45rem, 2.8vw, 1.9rem) }
h3 { font-size: 1.2rem }
p, li { text-wrap: pretty }
p { margin: 0 }
a { color: var(--ink); text-decoration-thickness: 2px; text-underline-offset: 3px }
:focus-visible { outline: 3px solid var(--denim); outline-offset: 3px; border-radius: 4px }
.small { font-size: .95rem }
/* a small paper label above a title */
.kicker { justify-self: start; display: inline-block; font-weight: 700; font-size: .92rem; background: var(--butter); padding: 3px 10px; border-radius: 3px; box-shadow: var(--lift-lo); transform: rotate(-1.5deg) }
.lead { font-size: 1.15rem }

/* a sheet of paper lying on the wall */
.cut { background: var(--white); border-radius: 4px; box-shadow: var(--lift) }

/* the top of every page: a strip of sky with the name, and the eaves under it */
header.top { background: var(--sky); padding-block: 18px 16px; border-bottom: 10px solid var(--denim); position: relative }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px }
.word { font-family: var(--display); font-size: 1.9rem; line-height: 1; color: var(--ink); text-decoration: none }
header.top nav { display: flex; gap: 18px; font-weight: 700; font-size: .98rem }

main { padding-block: 36px 56px }
main .wrap { display: grid; gap: 28px }
.intro { display: grid; gap: 14px }

/* reading pages: sections divided by a wooden shelf */
.doc section { display: grid; gap: 12px; padding-top: 26px; border-top: 4px solid var(--wood) }
.doc ul { margin: 0; padding-left: 1.2em; display: grid; gap: 6px }
.doc table { border-collapse: collapse; width: 100%; font-size: .97rem }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 12px 10px 0; border-bottom: 3px solid var(--path) }
.doc th { font-weight: 700 }
.table { overflow-x: auto }
.promise { padding: clamp(18px, 4vw, 30px); display: grid; gap: 14px }
.promise ul { list-style: none; padding: 0; display: grid; gap: 12px }
.promise li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 12px; align-items: start }
.promise li::before { content: ""; width: 14px; height: 14px; margin-top: 6px; border-radius: 50%; background: var(--dot, var(--denim)); box-shadow: var(--lift-lo) }
.promise li:nth-child(3n+2) { --dot: var(--grass) } .promise li:nth-child(3n) { --dot: var(--wood) }
.aloud { padding: clamp(18px, 4vw, 28px); display: grid; grid-template-columns: minmax(0, 1fr) 120px; gap: 18px; align-items: center }
.aloud p { font-family: var(--display); font-size: 1.2rem; line-height: 1.45 }
.aloud img { width: 120px; height: auto }

/* words the founders still have to fill in before the page goes live; README lists every one */
.fill { background: var(--butter); padding: 0 4px; border-radius: 3px }

/* question pages */
form.ask { padding: clamp(18px, 4vw, 30px); display: grid; gap: 26px }
fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; min-width: 0 }
legend { font-weight: 700; font-size: 1.08rem; padding: 0; margin-bottom: 10px }
legend .n { font-family: var(--display); margin-right: 8px; font-weight: 400 }
.hint { font-size: .95rem; margin-top: -4px }
.chips { display: flex; gap: 8px; flex-wrap: wrap }
.chips label { cursor: pointer; position: relative }
.chips input { position: absolute; opacity: 0; pointer-events: none }
.chips span { display: inline-block; padding: 9px 14px; border-radius: 8px; font-size: .98rem; font-weight: 700; background: var(--cream); box-shadow: var(--lift-lo); transition: transform .2s }
.chips input:checked + span { background: var(--grass); transform: translate(-1px, -2px) }
.chips input:focus-visible + span { outline: 3px solid var(--denim); outline-offset: 2px }
textarea, input[type="email"], input[type="text"] { font: inherit; color: var(--ink); background: var(--cream); border: 3px solid var(--wood); border-radius: 8px; padding: 12px 14px; width: 100% }
textarea { min-height: 6.5em; resize: vertical }
.send { display: grid; gap: 10px; padding-top: 18px; border-top: 4px solid var(--wood) }
.send .row { display: flex; gap: 10px; flex-wrap: wrap }
.send .row input { flex: 1 1 14rem; min-width: 0; width: auto }
button.go, a.go { display: inline-block; font: 700 1.2rem/1.2 var(--body); color: var(--white); background: var(--tomato); border: 0; border-radius: 8px; padding: 14px 22px; box-shadow: var(--lift); cursor: pointer; text-decoration: none; transition: transform .26s cubic-bezier(.3, 1.25, .5, 1), box-shadow .26s }
button.go:hover, a.go:hover { transform: translate(-1px, -2px) }
button.go:active, a.go:active { transform: translate(3px, 4px); box-shadow: var(--lift-lo) }
button.go:disabled { opacity: .7; cursor: default }
.done { padding: clamp(20px, 4vw, 34px); display: grid; gap: 12px; justify-items: start }
.done img { width: 150px; height: auto }

/* the dog picker: five paper dogs, one to tap */
.dogs { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 12px }
.dogs label { cursor: pointer; position: relative; display: block }
.dogs input { position: absolute; opacity: 0; pointer-events: none }
.dogs .card { display: grid; justify-items: center; gap: 2px; padding: 10px 8px 12px; border-radius: 8px; background: var(--cream); box-shadow: var(--lift-lo); transition: transform .22s cubic-bezier(.3, 1.25, .5, 1) }
.dogs img { width: 100%; max-width: 150px; height: auto }
.dogs .name { font-weight: 700; font-size: .95rem }
.dogs input:checked + .card { background: var(--tomato); color: var(--white); box-shadow: var(--lift); transform: translate(-1px, -3px) rotate(-1.5deg) }
.dogs input:focus-visible + .card { outline: 3px solid var(--denim); outline-offset: 2px }
.fromphone { padding: 12px 14px; border-radius: 4px; background: var(--hill) }

/* the beta kit's steps: four notes, each with a numbered paper disc */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; counter-reset: step }
.steps li { counter-increment: step; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; padding: clamp(16px, 3vw, 22px); position: relative }
.steps li::before { content: counter(step); font-family: var(--display); font-size: 1.5rem; line-height: 1; color: var(--ink); background: var(--butter); width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; box-shadow: var(--lift-lo) }
.steps li:nth-child(3n+2)::before { background: var(--hill) } .steps li:nth-child(3n)::before { background: var(--path) }
.steps .body { display: grid; gap: 6px; min-width: 0; color: inherit; text-decoration: none }
.steps a.body::before { content: ""; position: absolute; inset: 0; border-radius: 4px }
.steps .more { font-weight: 700; color: var(--tomato); margin-top: 4px }
.steps .more::after { content: " \2192" }
.steps li:has(a.body) { transition: transform .22s cubic-bezier(.3, 1.25, .5, 1) }
.steps li:has(a.body:hover) { transform: translate(-1px, -2px) }
.steps li:has(a.body:active) { transform: translate(2px, 3px); box-shadow: var(--lift-lo) }
.aside { display: grid; gap: 10px; padding-top: 18px; border-top: 4px solid var(--wood) }
.steps .when { font-weight: 700; font-size: .92rem }

/* the bottom of every page: grass, the pavement with the links, and the road */
footer.end { background: var(--path); border-top: 14px solid var(--grass); border-bottom: 44px solid var(--road); box-shadow: inset 0 -6px 0 var(--kerb) }
footer.end .wrap { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-block: 22px 26px }
footer.end img { width: 84px; height: auto }
footer.end nav { display: flex; gap: 18px; flex-wrap: wrap }

@media (max-width: 560px) {
  .aloud { grid-template-columns: minmax(0, 1fr) 84px }
  .aloud img { width: 84px }
  .steps li { grid-template-columns: 40px minmax(0, 1fr); gap: 12px }
  .steps li::before { width: 34px; height: 34px; font-size: 1.3rem }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important } }
@media print {
  body::after, header.top nav, footer.end, .noprint { display: none !important }
  body { background: #fff; color: #000 }
  header.top { background: none; border: 0 }
}

.details { display: grid; gap: 0 }
.details > h2 { margin-bottom: 8px }
/* the privacy policy's full sections fold away under the short version; each opens on a tap */
.doc details { border-bottom: 4px solid var(--wood); padding-block: 14px }
.doc details:first-of-type { border-top: 4px solid var(--wood) }
.doc summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; font-family: var(--display); font-size: 1.25rem; line-height: 1.25 }
.doc summary::-webkit-details-marker { display: none }
.doc summary::after { content: "+"; font-size: 1.5rem; line-height: 1; flex: none; width: 32px; height: 32px; display: grid; place-items: center; background: var(--cream); border-radius: 50%; box-shadow: var(--lift-lo) }
.doc details[open] summary::after { content: "\2013" }
.doc details > .in { display: grid; gap: 12px; padding-top: 12px }
@media print { .doc details > .in { display: grid !important } }
