/* The public pages the Worker renders (src/routes/pages.js): /guides, the category pages and the 404.
   On top of tokens.css, alias.css and app.css, so they look like the app and like /a/. Type from TYPOGRAPHY.md. */
.pub .topbar .pub-cta { margin-inline-start: auto; }
.pub-main { padding-top: var(--sp-2); }
.pub-main section { margin-top: var(--sp-6); }

.crumbs { font-size: var(--fs-caption); line-height: var(--lh-caption); color: var(--text-2); margin: var(--sp-2) 0 var(--sp-3); }
.crumbs a { color: var(--text-2); text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px; }
.pub-main .title { margin: 0 0 var(--sp-2); text-wrap: balance; }
.pub-main .lede { color: var(--text-2); font-size: var(--fs-body); line-height: var(--lh-body); text-wrap: pretty; }
.pub-main h2 { font-size: var(--fs-card); font-weight: var(--fw-card); line-height: var(--lh-card); margin: var(--sp-6) 0 var(--sp-2); text-wrap: balance; }
.pub-main section > h2:first-child { margin-top: 0; }
.pub-main h3 { font-size: var(--fs-body); font-weight: 800; line-height: var(--lh-card); color: var(--text-2); margin: var(--sp-5) 0 var(--sp-2); }

/* An article: reading text at --fs-read, held to --measure. */
.guide > p, .guide > ul, .guide > ol { font-size: var(--fs-read); line-height: var(--lh-read); max-inline-size: var(--measure); margin: 0 0 var(--sp-3); text-wrap: pretty; }
.guide > h2 + p, .guide > h3 + p { margin-top: 0; }
.guide ul, .guide ol { padding-inline-start: 22px; }
.guide li { margin-bottom: var(--sp-2); }
.guide li::marker { color: var(--primary); }
.guide p a, .guide li a { text-decoration: underline; text-decoration-color: var(--surface-2); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.guide .lead-in { font-size: var(--fs-body); font-weight: 700; line-height: var(--lh-body); }
.guide h4 { font-size: var(--fs-body); font-weight: 800; margin: var(--sp-4) 0 var(--sp-1); }

/* An activity: its drawn cover, the title, the facts and the hook (the app's activity cards). */
.act { display: flex; gap: var(--sp-3); align-items: flex-start; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: var(--sp-3); margin: var(--sp-2) 0; }
.act-cv { flex: none; width: 72px; height: 72px; border-radius: var(--radius); object-fit: cover; background: var(--surface-2); }
.act-cv.none { display: block; background: var(--surface-2) url(/icons/logo-mark.svg) center / 36px no-repeat; }
.act-tx { min-width: 0; flex: 1; }
.pub-main .act-t { font-size: var(--fs-card); font-weight: var(--fw-card); line-height: var(--lh-card); margin: 0; text-wrap: balance; color: var(--text); }
.act-t a { color: var(--text); }
.act-t a:hover { color: var(--primary); }
.act-m { font-size: var(--fs-secondary); font-weight: var(--fw-secondary); line-height: var(--lh-secondary); color: var(--text-2); margin: 2px 0 var(--sp-1); }
.act-h { font-size: var(--fs-body); line-height: var(--lh-body); margin: 0; text-wrap: pretty; }

/* The /guides list */
.guide-list { list-style: none; margin: 0; padding: 0; }
.guide-list li { border-bottom: 1px solid var(--border); padding: var(--sp-3) 0; }
.guide-list li:last-child { border-bottom: 0; }
.guide-list a { font-size: var(--fs-choice); font-weight: 800; line-height: var(--lh-card); color: var(--text); }
.guide-list p { font-size: var(--fs-secondary); line-height: var(--lh-secondary); color: var(--text-2); margin-top: 2px; text-wrap: pretty; }

/* Chips: the other categories (v3.css .chip, without the app's script) */
.pub .chips { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin: var(--sp-2) 0 0; }
.pub .chip { display: inline-flex; align-items: center; padding: 8px 14px; border: 2px solid var(--border); border-radius: 999px; background: var(--surface); color: var(--text); font-size: var(--fs-chip); font-weight: 600; line-height: 1.2; }

.more-box { margin: var(--sp-5) 0 0; }
.indep { font-size: var(--fs-caption); line-height: var(--lh-caption); color: var(--text-2); margin-top: var(--sp-6); }

/* The 404 */
.nf { text-align: center; padding-top: var(--sp-6); }
.nf-mark svg { width: 72px; height: 72px; margin: 0 auto var(--sp-2); display: block; }
.nf .kicker { margin-bottom: var(--sp-1); }
.nf .lede { margin: 0 auto var(--sp-5); max-inline-size: var(--measure); }
.nf-acts { display: grid; gap: var(--sp-3); }

/* The footer, with the credit line */
.pub-foot { border-top: 1px solid var(--border); padding: var(--sp-4) var(--gutter) calc(var(--sp-5) + env(safe-area-inset-bottom)); font-size: var(--fs-secondary); color: var(--text-2); }
.pub-foot nav { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-4); }
.pub-foot nav a { color: var(--text-2); }
.made-by { display: inline-block; margin-top: var(--sp-2); font-size: var(--fs-caption); color: var(--text-2); }
.pub-foot .made-by { display: block; }
