/* Mench web app. Layout: two columns, the menu and the content; a top bar and bottom tabs on phones. */
:root {
  --bg: #fff; --ink: #000; --muted: #5d6673; --line: #e7e9ec; --soft: #f5f6f7; --hover: #f0f1f3;
  --blue: #1f6bff; --red: #e5383b; --green: #0f9d63; --yellow: #ffc21a;
  --font: "Rubik", system-ui, -apple-system, "Segoe UI", sans-serif; --mono: "Roboto Mono", ui-monospace, Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #000; --ink: #f2f3f5; --muted: #8b95a3; --line: #262a30; --soft: #121418; --hover: #181b20; --blue: #5b93ff; --green: #2fc487; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.45 var(--font); }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 6px; }
.ic { width: 1.15em; height: 1.15em; fill: currentColor; vertical-align: -0.2em; flex: none; }
i.far, i.fas { width: 1.25em; text-align: center; }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: 250px minmax(0, 660px); justify-content: center; min-height: 100vh; }
.rail { position: sticky; top: 0; height: 100vh; padding: 10px 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.brand { display: inline-flex; align-items: center; gap: 10px; padding: 10px 12px; font: 700 26px/1 "Bodoni Moda", Georgia, serif; }
.brand svg { width: 30px; height: 30px; }
.nav a { display: flex; align-items: center; gap: 16px; padding: 11px 14px; border-radius: 999px; font-size: 19px; width: fit-content; }
.nav a:hover { background: var(--hover); }
.nav a[aria-current="page"] { font-weight: 700; }
.nav .ic, .nav i { font-size: 22px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 38px; padding: 0 18px; border-radius: 999px; font-weight: 700; background: var(--ink); color: var(--bg); }
.btn:hover { opacity: .88; }
.btn[disabled] { opacity: .4; cursor: default; }
.btn.line { background: none; color: var(--ink); border: 1px solid var(--line); }
.btn.line:hover { background: var(--hover); opacity: 1; }
.btn.big { min-height: 50px; font-size: 17px; margin-top: 12px; width: 100%; }
.me { margin-top: auto; display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 999px; }
.me:hover { background: var(--hover); }
.main { border-inline: 1px solid var(--line); min-height: 100vh; padding-bottom: 80px; }

.head { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.head h1 { margin: 0; padding: 14px 16px; font-size: 20px; display: flex; align-items: center; gap: 18px; }
.tabs { display: flex; }
.tabs a { flex: 1; text-align: center; padding: 14px 0 0; color: var(--muted); font-weight: 500; }
.tabs a span { display: inline-block; padding-bottom: 12px; border-bottom: 4px solid transparent; }
.tabs a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.tabs a[aria-current="page"] span { border-color: var(--yellow); }
.tabs a:hover { background: var(--hover); }

/* ---------- people and posts ---------- */
.av { width: 40px; height: 40px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 15px; flex: none; overflow: hidden; }
.av img { width: 100%; height: 100%; object-fit: cover; }
.av.s { width: 28px; height: 28px; font-size: 11px; }
.av.l { width: 84px; height: 84px; font-size: 30px; border: 4px solid var(--bg); }
.who { display: flex; gap: 6px; align-items: baseline; min-width: 0; }
.who b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who span, .dim { color: var(--muted); }
.post { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); cursor: pointer; }
.post:hover { background: var(--soft); }
.text { white-space: pre-wrap; overflow-wrap: anywhere; }
.text p { margin: 0 0 2px; }
.text .t { font-weight: 500; }
.text a.tag, .text a.at { font-weight: 500; }
.text a.tag::before { content: ""; display: inline-block; width: .55em; height: .55em; background: var(--yellow); margin-right: .22em; }
.text a.at { color: var(--blue); }
.text a:hover { text-decoration: underline; }
.text code { font: 400 .9em var(--mono); background: var(--soft); padding: 1px 5px; border-radius: 5px; }
.media { margin-top: 10px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--soft); }
.media img, .media video, .media svg { display: block; width: 100%; max-height: 520px; object-fit: cover; }
.seq { margin-top: 10px; display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 14px; font-size: 14px; }
.seq b { font-weight: 500; }
.bar { display: flex; gap: 3px; flex: 1; min-width: 40px; }
.bar i { flex: 1; height: 5px; background: var(--line); border-radius: 2px; }
.bar i.on { background: var(--red); }
.acts { display: flex; justify-content: space-between; max-width: 430px; margin-top: 8px; color: var(--muted); font-size: 14px; }
.acts button { display: inline-flex; align-items: center; gap: 6px; padding: 5px 7px; margin-left: -7px; border-radius: 999px; }
.acts button:hover { background: var(--hover); color: var(--ink); }
.acts .on-like { color: var(--red); }
.acts .on-save { color: var(--blue); }
.empty { padding: 42px 24px; text-align: center; color: var(--muted); }
.empty b { display: block; color: var(--ink); font-size: 20px; margin-bottom: 4px; }

/* ---------- compose ---------- */
.compose { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.compose textarea { display: block; width: 100%; min-height: 120px; border: 0; outline: 0; resize: none; background: none; color: inherit; font: 400 19px/1.4 var(--font); padding: 6px 0; }
.compose .row { display: flex; align-items: center; gap: 4px; border-top: 1px solid var(--line); padding-top: 10px; margin-top: 12px; }
.compose .ins { color: var(--blue); min-width: 36px; height: 36px; padding: 0 8px; border-radius: 999px; font: 500 18px/1 var(--mono); }
.compose .ins.wide { font: 500 14px/1 var(--font); padding: 0 12px; }
.compose .ins:hover { background: var(--hover); }
.compose .count { margin-left: auto; padding-right: 10px; color: var(--muted); font-size: 13px; }
.field { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; background: var(--bg); color: inherit; font: inherit; }
.modal { position: fixed; inset: 0; z-index: 20; background: rgba(0, 0, 0, .45); display: grid; place-items: start center; padding: 5vh 12px; }
.modal > div { background: var(--bg); border-radius: 18px; width: min(600px, 100%); overflow: hidden; }
.modal .top { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; }

/* ---------- discovery ---------- */
.step { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 12px 16px 0; position: relative; }
.step.past { color: var(--muted); }
.step.past::before { content: ""; position: absolute; left: 35px; top: 56px; bottom: -12px; width: 2px; background: var(--line); }
.step.past .text .t { color: var(--ink); }
.pick { display: inline-block; margin-top: 4px; padding: 2px 10px; border-radius: 999px; background: var(--soft); color: var(--ink); font-size: 14px; }
.now { padding: 14px 16px 18px; border-bottom: 1px solid var(--line); }
.now .text { font-size: 22px; line-height: 1.35; margin-top: 10px; }
.now .text .t { font-weight: 700; }
.opts { display: grid; gap: 8px; margin-top: 14px; }
.opts button { text-align: left; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; font-weight: 500; }
.opts button:hover { background: var(--hover); }
.opts button[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.go { display: flex; align-items: center; gap: 14px; margin-top: 16px; }
.go .btn { min-height: 46px; padding: 0 26px; background: var(--red); color: #fff; }
.err { color: var(--red); margin-top: 10px; font-weight: 500; }
.hint { color: var(--muted); font-size: 13px; }
.prog { display: flex; align-items: center; gap: 12px; padding: 0 16px 12px; font-size: 14px; color: var(--muted); }
.done { padding: 26px 16px; text-align: center; border-bottom: 1px solid var(--line); }
.done b { font-size: 22px; display: block; }

/* ---------- side column, profile, ledger ---------- */
.card { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.card h2 { margin: 0; padding: 12px 16px 6px; font-size: 19px; }
.card .li { display: flex; gap: 10px; align-items: center; padding: 10px 16px; }
.card .li:hover { background: var(--soft); }
.card .li > div { min-width: 0; flex: 1; }
.card .li .btn { min-height: 32px; padding: 0 14px; font-size: 14px; }
/* a profile opens with the picture, the name and the words: no banner behind it (a background belongs to a site's home page) */
.prof { padding: 16px 16px 14px; border-bottom: 1px solid var(--line); }
.prof .top { display: flex; justify-content: space-between; align-items: flex-end; }
.prof h2 { margin: 8px 0 0; font-size: 21px; }
.prof .nums { display: flex; gap: 18px; margin-top: 10px; color: var(--muted); }
.prof .nums b { color: var(--ink); }
table.ledger { width: 100%; border-collapse: collapse; font: 400 12.5px/1.5 var(--mono); }
.ledger td, .ledger th { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.ledger th { color: var(--muted); font-weight: 500; }
.scroll { overflow-x: auto; }
.note { padding: 12px 16px; border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.sample { background: var(--soft); color: var(--muted); font-size: 13px; padding: 6px 16px; border-bottom: 1px solid var(--line); }
.toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-weight: 500; z-index: 30; }
.tabbar, .fab, .mhead { display: none; }

@media (max-width: 960px) { .shell { grid-template-columns: 76px minmax(0, 660px); } .rail { align-items: center; padding-inline: 6px; } .nav a span, .rail .brand > span:not(.av), .me div, .btn.big span { display: none; } .nav a { padding: 12px; } .btn.big { width: 50px; padding: 0; } }
@media (max-width: 690px) {
  .shell { display: block; } .rail { display: none; } .main { border: 0; padding-bottom: 120px; }
  .mhead { display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 6; height: 50px; padding: 0 14px; background: var(--bg); }
  .mhead .brand { padding: 4px 0; font-size: 22px; }
  .head { top: 50px; }                                       /* a page's own title bar stays under the logo */
  body.at-home .mhead { display: none; } body.at-home .head { top: 0; }
  .tabbar { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 10; background: var(--bg); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar a { flex: 1; text-align: center; padding: 13px 0 12px; font-size: 21px; color: var(--muted); }
  .tabbar a[aria-current="page"] { color: var(--ink); }
  .fab { display: grid; place-items: center; position: fixed; right: 16px; bottom: 74px; z-index: 11; width: 56px; height: 56px; border-radius: 50%; background: var(--ink); color: var(--bg); font-size: 22px; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
  .home-compose { display: none; }
  .now .text { font-size: 20px; }
}
@media (prefers-reduced-motion: no-preference) { .now { animation: rise .22s ease-out; } @keyframes rise { from { opacity: 0; transform: translateY(14px); } } }

/* ---------- added with the API-driven app ---------- */
.brand img { width: 34px; height: 34px; border-radius: 50%; }
/* A home page opens with the site's logo, name and description at the very top of the content column. The logo starts level
   with the first entry of the menu beside it: 10px of menu padding, the 54px row of the menu's own logo, a 2px gap and the
   entry's 12px of padding come to 78px. */
:root { --menu-top: 78px; }
.hero { display: flex; align-items: flex-start; background: #000; color: #fff; }
.hero > div { padding: var(--menu-top) 16px 20px; }
.hero h2 { margin: 12px 0 4px; font: 700 34px/1.05 "Bodoni Moda", Georgia, serif; }
.hero p { margin: 0; max-width: 34rem; }
.hero .av.l { border: 0; background: rgba(255, 255, 255, .16); }
.opts a.opt { display: block; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; font-weight: 500; }
.opts a.opt:hover { background: var(--hover); border-color: var(--ink); }
.post > a, a.post { display: contents; }
a.post { display: grid; }
.acts span, .acts a.stat { display: inline-flex; align-items: center; gap: 6px; }
.acts a.stat { padding: 5px 9px; margin: -5px -9px; border-radius: 999px; }           /* the views count, where it opens the list of views */
.acts a.stat:hover { background: var(--hover); color: var(--blue); }
.now .acts { margin-top: 16px; }
.go a.btn { background: var(--red); color: #fff; min-height: 46px; padding: 0 26px; }

.signin { padding: 22px 16px; display: grid; gap: 10px; max-width: 26rem; }
.signin h2 { margin: 0; font-size: 22px; }
.signin p { margin: 0; }
.signin label { font-weight: 500; margin-top: 8px; }
.signin .row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.signin [hidden] { display: none; }
.signin [data-step2] { display: grid; gap: 10px; }
.signin [data-step2][hidden] { display: none; }

.tabs.sub { border-bottom: 1px solid var(--line); }
.tabs i { font-style: normal; font-weight: 400; color: var(--muted); margin-left: 4px; }
.more { padding: 18px 16px 28px; text-align: center; }
.more .btn[disabled] { opacity: .6; cursor: default; }
body.lit .more .btn { color: #fff; border-color: rgba(255, 255, 255, .5); background: rgba(0, 0, 0, .3); text-shadow: 0 1px 2px rgba(0, 0, 0, .6); }
.ok { color: var(--green); margin-top: 10px; font-weight: 500; }
.small { font-size: 14px; }
.who .ic, .nums .ic { width: .95em; height: .95em; }

/* ---------- each site as itself: its own name and logo, and on its home page a background that fills the window ---------- */
.av i { font-size: 1.2em; }
.av.l i { font-size: 34px; }
.av.b { width: 34px; height: 34px; background: var(--ink); color: var(--bg); }
.av.sq { border-radius: 10px; background: var(--yellow); color: #000; font: 700 17px/1 var(--mono); }
.av.s.sq { border-radius: 7px; font-size: 13px; }
.rotate45 { transform: rotate(45deg); } .rotate90 { transform: rotate(90deg); }
.brand span { line-height: 1.05; overflow-wrap: anywhere; }
.brand.long { font-size: 19px; }
.powered { margin: 0; padding: 18px 16px; color: var(--muted); font-size: 14px; }
.powered a { text-decoration: underline; text-underline-offset: 2px; }
#backdrop { position: fixed; inset: 0; z-index: -1; display: none; background: #000; }
#backdrop img, #backdrop video { display: block; width: 100%; height: 100%; object-fit: cover; }
/* Nothing is laid over the picture or video: no shade, no gradient. The menu and the site's name are kept readable by the
   shadow of their own letters, and only the posts have a pane behind them. */
body.lit #backdrop { display: block; }
/* On a home page with a picture the column runs on for one more window below the last post, so a reader can scroll every
   post out of sight and see the whole picture or video. */
body.lit .main { border-color: transparent; padding-bottom: 100vh; padding-bottom: 100dvh; }
/* The site's name stands straight on the picture, and the posts follow after a small margin. */
body.lit .hero { background: none; text-shadow: 0 1px 2px rgba(0, 0, 0, .8), 0 0 12px rgba(0, 0, 0, .55), 0 2px 26px rgba(0, 0, 0, .5); }
body.lit .hero > div { padding-bottom: 28px; }
/* The feed on a home page is a pane you can see through: tinted lightly at its top and deeper below, so the picture or video
   behind the page still shows while the words stay readable. The tint and the frosting sit on a layer of their own, behind
   the posts. Were they on the pane itself, the tab bar inside it could not frost what scrolls beneath it: a browser lets a
   frosted element see only as far back as the nearest frosted element around it. */
body.lit .sheet { --ink: #fff; --muted: rgba(255, 255, 255, .76); --line: rgba(255, 255, 255, .16); --soft: rgba(255, 255, 255, .07); --hover: rgba(255, 255, 255, .12); --blue: #8fb8ff;
  color: var(--ink); position: relative; z-index: 0; border-radius: 18px; overflow: clip; }
/* the pane is exactly as tall as its posts: where they end it ends, and below it there is only the picture */
body.lit .sheet > :last-child { border-bottom: 0; }
body.lit .sheet::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 0, 0, .38), rgba(0, 0, 0, .54) 320px, rgba(0, 0, 0, .62) 900px);
  backdrop-filter: blur(8px) saturate(1.15); -webkit-backdrop-filter: blur(8px) saturate(1.15); }
body.lit .sheet .head { background: rgba(0, 0, 0, .42); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
body.lit .sheet .post, body.lit .sheet .text { text-shadow: 0 1px 2px rgba(0, 0, 0, .4); }
@media (prefers-reduced-transparency: reduce) { body.lit .sheet::before { background: rgba(0, 0, 0, .88); backdrop-filter: none; -webkit-backdrop-filter: none; } body.lit .sheet .head { background: #000; } }
body.lit .rail { color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, .8), 0 0 12px rgba(0, 0, 0, .55), 0 2px 22px rgba(0, 0, 0, .5); }
body.lit .nav a svg, body.lit .nav a i { filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .75)) drop-shadow(0 0 8px rgba(0, 0, 0, .4)); }
body.lit .nav a:hover { background: rgba(255, 255, 255, .16); }
body.lit .rail .btn.big, body.lit .brand .av.b { background: #fff; color: #000; text-shadow: none; }
body.lit .rail .btn.big { box-shadow: 0 2px 14px rgba(0, 0, 0, .22); }                 /* so a white button does not vanish into a bright sky */
/* A site the ledger lists under @HomeBlackFont has a bright picture: its menu and its name are written in black, as before. */
body.ink-dark .rail, body.ink-dark .hero { color: #000; text-shadow: 0 1px 2px rgba(255, 255, 255, .85), 0 0 12px rgba(255, 255, 255, .6); }
body.ink-dark .nav a svg, body.ink-dark .nav a i { filter: drop-shadow(0 1px 2px rgba(255, 255, 255, .8)); }
body.ink-dark .nav a:hover { background: rgba(0, 0, 0, .1); }
body.ink-dark .rail .btn.big { background: #000; color: #fff; }
/* on a phone the bar of tabs at the foot of a home page is dark glass too, and the button that writes a post is white */
body.lit .tabbar { background: rgba(0, 0, 0, .46); border-top-color: rgba(255, 255, 255, .16); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
body.lit .tabbar a { color: rgba(255, 255, 255, .88); }
body.lit .fab { background: #fff; color: #000; }
/* on a phone there is no menu beside the content, so the logo starts just under the top edge */
@media (max-width: 690px) { .hero > div { padding-top: max(24px, calc(env(safe-area-inset-top) + 14px)); } }

/* ---------- writing a post ---------- */
.head h1 > .btn, .head h1 > .btns { margin-left: auto; }
.head .btns { display: inline-flex; gap: 8px; }
.btn.small { min-height: 32px; padding: 0 14px; font-size: 14px; }
.ta { position: relative; }
.sug { position: absolute; left: 0; right: 0; top: 100%; z-index: 8; margin: 2px 0 0; padding: 4px; list-style: none; max-height: 330px; overflow: auto; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, .16); }
.sug[hidden] { display: none; }
.sug li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; cursor: pointer; }
.sug li[aria-selected="true"], .sug li[role="option"]:hover { background: var(--hover); }
.sug li div { display: grid; min-width: 0; }
.sug li div > b, .sug li div > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sug li div > span, .sug .tip { color: var(--muted); font-size: 14px; }
.sug .tip { cursor: default; } .sug .tip b { color: var(--ink); }
.tagin { display: flex; align-items: center; gap: 1px; margin-top: 10px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; font: 500 15px/1 var(--mono); }
.tagin:focus-within { border-color: var(--ink); }
.tagin span { color: var(--muted); }
.tagin input { flex: 1; min-width: 0; height: 40px; border: 0; outline: 0; background: none; color: inherit; font: inherit; }
.plan { margin-top: 12px; font-size: 14px; }
.plan .sum { margin: 0 0 8px; color: var(--muted); } .plan .sum b { color: var(--ink); font-weight: 500; }
.refl { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.refl li { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 8px 12px; }
.refl li + li { border-top: 1px solid var(--line); }
.refl a:hover b { text-decoration: underline; }
.mk { display: block; min-width: 34px; padding: 3px 0; text-align: center; border-radius: 7px; background: var(--soft); font: 500 14px/1.2 var(--mono); }
code.dim { font: 400 12.5px/1.6 var(--mono); }
.val { overflow-wrap: anywhere; white-space: pre-wrap; }
.plan em, .refl em { margin-left: 8px; padding: 1px 8px; border-radius: 999px; font-style: normal; font-size: 12px; color: var(--green); background: color-mix(in srgb, var(--green) 15%, transparent); }
.refl em.out { color: var(--red); background: color-mix(in srgb, var(--red) 13%, transparent); }
.refl .gone b { color: var(--muted); text-decoration: line-through; }
.warn { margin: 8px 0 0; color: var(--red); font-weight: 500; }
.plan .hint { margin: 8px 0 0; }
.guide { padding: 12px 16px 18px; background: var(--soft); border-bottom: 1px solid var(--line); }
.guide .hint { margin: 0 0 4px; }
.gcols { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 20px; }
.guide h3 { margin: 10px 0 4px; font-size: 14px; font-weight: 500; color: var(--muted); }
.guide button { display: grid; grid-template-columns: 38px minmax(0, 1fr); column-gap: 8px; align-items: center; width: 100%; padding: 5px 6px; border-radius: 9px; text-align: left; }
.guide button:hover { background: var(--hover); }
.guide button code { grid-row: span 2; text-align: center; font: 500 14px/1.2 var(--mono); }
.guide button i { font-style: normal; font-size: 12.5px; color: var(--muted); }
@media (max-width: 520px) { .gcols { grid-template-columns: 1fr; } }

/* ---------- a post's references, a profile's lists ---------- */
.refs { margin: 14px 16px; }
.refs summary { display: flex; align-items: baseline; gap: 10px; padding: 12px 16px 8px; cursor: pointer; list-style: none; }
.refs summary::-webkit-details-marker { display: none; }
.refs summary h2 { padding: 0; } .refs summary i { font-style: normal; font-weight: 400; color: var(--muted); }
.refs .li { align-items: start; }
.ctx { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 3px; font-size: 13px; color: var(--muted); }
.via { display: inline-flex; align-items: center; gap: 5px; padding: 0 9px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); font-weight: 500; }
.via code { font: 500 12px/1.6 var(--mono); }
.tabs.sub { overflow-x: auto; scrollbar-width: none; } .tabs.sub::-webkit-scrollbar { display: none; }
.tabs.sub a { flex: 1 0 auto; padding-inline: 14px; white-space: nowrap; }
.chips { display: flex; gap: 8px; padding: 10px 16px; overflow-x: auto; border-bottom: 1px solid var(--line); scrollbar-width: none; }
.chips a { flex: none; padding: 4px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; white-space: nowrap; }
.chips a:hover { background: var(--hover); }
.chips a[aria-current] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chips i { font-style: normal; opacity: .62; } .chips code { margin-right: 5px; font: 500 12px var(--mono); }
.rel { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.rel:hover { background: var(--soft); }
.rel .who { margin-bottom: 3px; }
.rel .val { margin-top: 3px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden; }
.mine { display: flex; gap: 8px; align-items: baseline; margin: 10px 0 0; padding: 8px 12px; border-radius: 12px; background: var(--soft); font-size: 14px; overflow-wrap: anywhere; }
.sample .ic, .mine .ic, .ctx .ic, .val .ic { width: .9em; height: .9em; }

/* ---------- the ledger in numbers ---------- */
.total { padding: 26px 16px 16px; border-bottom: 1px solid var(--line); }
.total > b { display: block; width: fit-content; font: 700 clamp(46px, 13vw, 78px)/1 "Bodoni Moda", Georgia, serif; }
.total > span { color: var(--muted); }
.total .hint { margin: 12px 0 0; } .hint code { font: 400 12.5px var(--mono); }
.pulse { display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--green); }
.sec { display: flex; justify-content: space-between; align-items: baseline; margin: 0; padding: 20px 16px 8px; font-size: 20px; }
.stats b[data-n] { font-variant-numeric: tabular-nums; border-radius: 5px; }
.sec b, .kind summary b { font: 500 15px var(--mono); }
.st { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 7px 16px; }
.st:hover { background: var(--soft); }
.st .ico { text-align: center; color: var(--muted); } .st .ico code { font: 500 13px var(--mono); color: var(--ink); }
.st b, .kind h3 b { font: 500 14px var(--mono); }
.st.zero, .st.zero .ico code { color: var(--muted); } .st.zero b { font-weight: 400; }
.kind { border-top: 1px solid var(--line); padding-bottom: 6px; }
.kind summary { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: baseline; padding: 13px 16px 9px; cursor: pointer; list-style: none; font-weight: 700; font-size: 17px; }
.kind summary::-webkit-details-marker { display: none; }
.kind summary code { font: 400 13px var(--mono); color: var(--muted); }
.kind h3 { display: flex; justify-content: space-between; margin: 0; padding: 10px 16px 3px; font-size: 13px; font-weight: 500; color: var(--muted); }
.kind h3 b { font-weight: 400; }
.hint.pad { margin: 0; padding: 0 16px 8px; }
@media (prefers-reduced-motion: no-preference) {
  .pulse { animation: pulse 2.4s ease-in-out infinite; } @keyframes pulse { 50% { opacity: .25; } }
  .bump { animation: bump 1.4s ease-out; } @keyframes bump { from { background: var(--yellow); color: #000; } }
}
.fab[hidden], .btn[hidden] { display: none; }
/* offered when the ledger has changed under a list the reader lengthened: one press shows the latest */
.fresh { position: fixed; top: 14px; left: calc(50% + 125px); transform: translateX(-50%); z-index: 20; padding: 9px 18px; border: 0; border-radius: 999px; background: var(--blue); color: #fff; font: 600 14px/1.2 var(--font); cursor: pointer; box-shadow: 0 4px 16px rgba(0, 0, 0, .22); }
@media (max-width: 960px) { .fresh { left: calc(50% + 38px); } }
@media (max-width: 690px) { .fresh { left: 50%; top: 60px; } }
.rel.ref { grid-template-columns: 40px minmax(0, 1fr) auto; align-items: start; }
.rel.ref .who span { white-space: nowrap; }

/* ---------- search ---------- */
.field::-webkit-search-cancel-button { cursor: pointer; }
mark { background: color-mix(in srgb, var(--yellow) 55%, transparent); color: inherit; border-radius: 3px; }
.clamp { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.who b { flex: 0 1 auto; max-width: 72%; }
.who span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- a sequence as one document; the apps list ---------- */
.doc { padding: 4px 16px 34px; }
.doc section { padding: 14px 0 12px; border-bottom: 1px solid var(--line); }
.doc .d1 { padding-left: 16px; } .doc .d2 { padding-left: 32px; } .doc .d3 { padding-left: 48px; }
.doc h2, .doc h3, .doc h4, .doc h5 { margin: 0 0 6px; line-height: 1.25; }
.doc h2 { font-size: 26px; } .doc h3 { font-size: 20px; } .doc h4, .doc h5 { font-size: 17px; }
.doc a:hover { text-decoration: underline; }
.doc > .hint { margin: 14px 0 0; }
.hint a.at { color: var(--blue); }
div.rel:hover { background: none; }
.rel .dim { overflow-wrap: anywhere; }

/* ---------- the logo at the top of the menu leads home; on the home page it steps aside for the page's own ---------- */
body.at-home .rail .brand { visibility: hidden; }

/* ---------- the sheet of a post ---------- */
/* a sheet takes all the room beside the menu; the table scrolls inside its own box, so its first row and first column stay in sight */
body.wide .shell { grid-template-columns: 250px minmax(0, 1fr); justify-content: stretch; }
@media (max-width: 960px) { body.wide .shell { grid-template-columns: 76px minmax(0, 1fr); } }
.sheethead { padding: 14px 16px; border-bottom: 1px solid var(--line); }
.sheethead h2 { margin: 0 0 6px; font-size: 22px; line-height: 1.25; }
.sheethead p { margin: 0 0 6px; max-width: 70ch; }
.sheethead p.dim { font-size: 14px; }
.sheethead .btn { margin-top: 6px; }
.sheetbox { overflow: auto; max-height: calc(100vh - 150px); border-bottom: 1px solid var(--line); }
.sheet { border-collapse: separate; border-spacing: 0; font-size: 14px; white-space: nowrap; }
.sheet th, .sheet td { padding: 7px 10px; border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); text-align: left; vertical-align: top; background: var(--bg); }
.sheet thead th { position: sticky; top: 0; z-index: 2; font-weight: 600; cursor: pointer; vertical-align: bottom; max-width: 150px; }
.sheet thead th:hover { background: var(--soft); }
.sheet thead .ci { display: block; height: 20px; font-size: 16px; line-height: 20px; }
.sheet thead .cn { display: block; overflow: hidden; text-overflow: ellipsis; }
.sheet thead b { color: var(--muted); font-weight: 500; font-variant-numeric: tabular-nums; }
.sheet .ord { font-style: normal; margin-left: 4px; color: var(--blue); }
.sheet .mem { position: sticky; left: 0; z-index: 1; min-width: 190px; max-width: 240px; font-weight: 600; }
.sheet thead .mem { z-index: 3; }
.sheet .mem a { display: flex; align-items: center; gap: 8px; }
.sheet .mem a span:last-child { overflow: hidden; text-overflow: ellipsis; }
.sheet .mem a:hover span:last-child { text-decoration: underline; }
.sheet tbody tr:hover td, .sheet tbody tr:hover th { background: var(--soft); }
.sheet td.on { text-align: center; }
.sheet td.dim { text-align: center; color: var(--muted); }
.sheet .tx { display: inline-block; max-width: 220px; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; }
.sheet.full { white-space: normal; }
.sheet.full .tx { max-width: 320px; min-width: 140px; white-space: pre-wrap; overflow: visible; }
@media (max-width: 690px) { .sheet .mem { min-width: 130px; max-width: 150px; } .sheetbox { max-height: calc(100vh - 210px); } }
