:root {
  --bg: #f6f3ec;
  --card: #fdfcf9;
  --text: #1b1a18;
  --muted: #6a665e;
  --line: #e0dbd0;
  --soft: #efebe2;
  --accent: #c8321e;
  --on-accent: #fff;
  --shadow: 0 1px 2px rgb(40 30 10 / 0.05), 0 8px 24px rgb(40 30 10 / 0.05);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151413;
    --card: #1d1c1a;
    --text: #eceae5;
    --muted: #a19c93;
    --line: #34312d;
    --soft: #262422;
    --accent: #ff6f57;
    --on-accent: #1b1a18;
    --shadow: none;
  }
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
  max-width: 72rem;
  background: var(--bg);
  color: var(--text);
  font: 1rem/1.55 var(--sans);
}

a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

h1 { font: 700 2.3rem/1.12 var(--serif); letter-spacing: -0.015em; margin: 2.5rem 0 1rem; }
h2 { font: 700 1.3rem/1.25 var(--serif); margin: 2.25rem 0 0.6rem; }
p { margin: 0 0 0.9rem; }
.label { display: block; font-size: 0.76rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); margin: 0 0 0.5rem; }
.lead { font-size: 1.15rem; line-height: 1.5; }
.small { color: var(--muted); font-size: 0.9rem; }
.strong { font-weight: 600; }

/* the head of the page */

header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 2rem;
  padding: 1.1rem 0 0.9rem;
  border-bottom: 1px solid var(--line);
}
.mark { font-size: 1.1rem; text-decoration: none; }
.mark b { font: 700 1.55rem/1 var(--serif); letter-spacing: -0.02em; margin-right: 0.1rem; }
nav { display: flex; gap: 1.4rem; }
nav a { text-decoration: none; color: var(--muted); padding: 0.3rem 0; border-bottom: 2px solid transparent; }
nav a:hover { color: var(--text); }
nav a[aria-current] { color: var(--text); font-weight: 600; border-bottom-color: var(--accent); }

/* buttons and fields */

button, .button, input, select {
  font: inherit;
  color: inherit;
  min-height: 2.6rem;
  padding: 0.45rem 1rem;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: var(--card);
}
button, .button { display: inline-block; cursor: pointer; text-decoration: none; line-height: 1.6; font-weight: 500; transition: border-color 0.15s, background 0.15s; }
button:hover, .button:hover { border-color: var(--muted); }
.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); font-weight: 600; }
.primary:hover { border-color: var(--text); }
.big { min-height: 3rem; padding: 0.6rem 1.4rem; font-size: 1.05rem; }
.danger { color: var(--accent); }
input[type="checkbox"] { min-height: 0; padding: 0; width: 1.25rem; height: 1.25rem; margin: 0; accent-color: var(--accent); flex: none; }
input[type="range"] { width: 100%; min-height: 0; padding: 0; border: 0; background: none; accent-color: var(--accent); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.row > input { flex: 1 1 14rem; }

#notice {
  position: sticky;
  top: 0.75rem;
  z-index: 3;
  margin: 1rem 0 0;
  padding: 0.7rem 1rem;
  border-radius: 0.6rem;
  background: var(--text);
  color: var(--bg);
  box-shadow: var(--shadow);
}
#notice.bad { background: var(--accent); color: var(--on-accent); }

/* cards and figures */

.card { padding: 1.25rem 1.4rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--card); box-shadow: var(--shadow); }
.card > :last-child { margin-bottom: 0; }
.card h2:first-child { margin-top: 0; }
.alert { border-color: var(--accent); }
.figure { margin: 0 0 0.3rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.figure strong { font: 700 2.8rem/1.05 var(--serif); letter-spacing: -0.02em; color: var(--text); margin-right: 0.15rem; }
.figure.huge strong { font-size: 4rem; }
.code { font: 600 1.05rem/1.4 var(--mono); letter-spacing: 0.04em; overflow-wrap: anywhere; user-select: all; }

.columns { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 2.5rem; align-items: start; }
.columns > div > h2:first-child { margin-top: 0; }
.narrow-text { max-width: 40rem; }

/* the welcome and the lists */

.narrow { max-width: 38rem; margin: 0 auto; padding-top: 2rem; }
.narrow h1 { margin-top: 0.75rem; }

#login { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
#login label { display: block; margin-bottom: 0.4rem; }
#code { font-family: var(--mono); text-transform: uppercase; }
#list-form { margin-top: 2rem; }
.choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem; margin: 0.2rem 0 0.8rem; }
.choice { display: flex; gap: 0.7rem; align-items: flex-start; padding: 0.75rem 0.9rem; border: 1px solid var(--line); border-radius: 0.6rem; cursor: pointer; }
.choice:has(input:checked) { border-color: var(--accent); background: var(--soft); }
.choice input { margin-top: 0.25rem; accent-color: var(--accent); }
.choice .what span { font-size: 0.85rem; }
.choice .what .choice-more { display: block; color: var(--muted); margin-top: 0.15rem; }
/* the genres of a list: coloured parts of a bar, adding up to 100 percent */
.genre-bar { display: flex; height: 0.6rem; border-radius: 0.3rem; overflow: hidden; margin: 0.45rem 0 0.35rem; gap: 1px; background: var(--line); }
.genre-bar span { min-width: 2px; }
.genre-legend { display: flex; flex-wrap: wrap; gap: 0.1rem 0.75rem; list-style: none; padding: 0; margin: 0 0 0.5rem; font-size: 0.8rem; color: var(--muted); }
.genre-legend > * { display: inline-flex; align-items: center; gap: 0.3rem; white-space: nowrap; }
.genre-legend i { width: 0.6rem; height: 0.6rem; border-radius: 50%; flex: none; }
svg.genre-bar { display: block; width: 100%; }
.genre-legend svg { width: 0.6rem; height: 0.6rem; flex: none; }
.choice .what .choice-more .genre-bar, .choice .what .choice-more .genre-legend { display: flex; font-size: 0.75rem; }
.genre-mix .genre-bar { height: 1rem; }
.genre-mix .genre-legend { font-size: 0.9rem; }
.choice .what .choice-more a { display: block; width: fit-content; margin-top: 0.15rem; color: var(--text); }

dialog { width: min(24rem, calc(100vw - 2rem)); padding: 1.5rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--card); color: var(--text); box-shadow: var(--shadow); }
dialog::backdrop { background: rgb(0 0 0 / 0.45); }
dialog h2 { margin-top: 0; }
dialog label { display: grid; gap: 0.25rem; color: var(--muted); font-size: 0.9rem; }

/* the list */

#list { display: grid; grid-template-columns: 21rem minmax(0, 1fr); gap: 2.5rem; align-items: start; padding-top: 2rem; }
.side { display: grid; gap: 1.25rem; position: sticky; top: 1.25rem; }
#left-line { margin: 0; }

/* a thing's sign: the emoji of its category on its colour */
/* Lucide icons, from the sprite web/icons.svg */
.icon { width: 1em; height: 1em; flex: none; vertical-align: -0.125em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon.filled { fill: currentColor; }
button .icon, .button .icon { margin: 0 0.1rem; }
.icon-button { padding-inline: 0.6rem; }

.sign { display: grid; place-items: center; flex: none; width: 2.6rem; height: 2.6rem; border-radius: 0.6rem; color: #fff; font-size: 1.3rem; }
.sign-big { width: 5.5rem; height: 5.5rem; border-radius: 1.1rem; font-size: 2.6rem; box-shadow: var(--shadow); }
.sign .icon { stroke-width: 1.9; }
.items li > .cover-link { margin: 0.6rem 0; }
.next-thing { display: flex; gap: 0.9rem; align-items: center; margin: 0.4rem 0 0.9rem; }
.next-thing .sign-big { width: 3.6rem; height: 3.6rem; font-size: 1.7rem; border-radius: 0.8rem; }
.next-thing strong a { color: var(--text); text-decoration: none; }
.next-thing strong a:hover { text-decoration: underline; }
.next .row { margin: 0; }
#next-none { margin: 0.4rem 0 0.9rem; }
.when { color: var(--muted); font-size: 0.85rem; white-space: nowrap; min-height: 0; padding: 0; }
.when .icon { margin-left: 0.3rem; }
.row-did { color: var(--muted); }
#done-dialog { width: min(28rem, calc(100vw - 2rem)); }
#done-dialog label { margin: 0.6rem 0; }
#done-dialog textarea, #done-dialog input { width: 100%; }
#done-dialog p.row { margin: 1.1rem 0 0; }
.done-line { margin: 0.9rem 0 0.2rem; }
.done-line .link { margin-left: 0.4rem; }
.done-note { margin: 0.2rem 0; padding-left: 0.8rem; border-left: 3px solid var(--line); color: var(--muted); white-space: pre-line; }
/* the blog's tiles: a category's icon on its colour, drawn in SVG */
.cat-tile { width: 2rem; height: 2rem; flex: none; }
.group-head { display: flex; align-items: center; gap: 0.6rem; }
.group-count { margin-left: auto; font: 500 0.9rem/1 var(--sans); color: var(--muted); }
.tiles { display: flex; flex-wrap: wrap; gap: 0.4rem; padding: 1.1rem 1.25rem 0; }
.tiles .cat-tile { width: 2.4rem; height: 2.4rem; }
.tiles-wide { padding: 0; margin: 1.5rem 0 2rem; gap: 0.5rem; }
.tiles-wide .cat-tile { width: 3rem; height: 3rem; }
.entry-box { flex: none; width: 1rem; height: 1rem; border: 1.5px solid var(--muted); border-radius: 0.25rem; }

progress {
  display: block;
  width: 100%;
  margin: 0.8rem 0;
  height: 0.45rem;
  border: 0;
  border-radius: 1rem;
  overflow: hidden;
  background: var(--line);
  accent-color: var(--accent);
  appearance: none;
}
progress::-webkit-progress-bar { background: var(--line); }
progress::-webkit-progress-value { background: var(--accent); }
progress::-moz-progress-bar { background: var(--accent); }

.tools {
  position: sticky;
  top: 0;
  z-index: 1;
  display: grid;
  gap: 0.6rem;
  padding: 0 0 0.8rem;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.tools .row { justify-content: space-between; }
.filter { display: flex; }
.filter button { border-radius: 0; margin-left: -1px; color: var(--muted); }
.filter button:first-child { border-radius: 0.6rem 0 0 0.6rem; margin-left: 0; }
.filter button:last-child { border-radius: 0 0.6rem 0.6rem 0; }
.filter button[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); font-weight: 600; position: relative; }
#shown { margin: 0.9rem 0 0.2rem; }

.items { list-style: none; margin: 0; padding: 0; }
.items li { display: flex; align-items: center; gap: 0.9rem; border-bottom: 1px solid var(--line); }
.items li > .what { flex: 1; }
.items label { flex: 1; min-width: 0; display: flex; gap: 0.9rem; align-items: center; padding: 0.6rem 0; cursor: pointer; }
.what { min-width: 0; display: grid; }
.what strong { font-weight: 600; overflow-wrap: anywhere; }
.what span { color: var(--muted); font-size: 0.9rem; overflow-wrap: anywhere; }
.items li.done .title-link { color: var(--muted); }
.items li.done .sign { opacity: 0.55; }
.items time { color: var(--muted); font-size: 0.85rem; white-space: nowrap; }
.row-side { display: flex; flex-direction: column; align-items: flex-end; gap: 0.15rem; padding: 0.6rem 0; }
.row-side:has(.when[hidden]) { justify-content: center; }
.links { display: flex; flex-wrap: wrap; gap: 0 0.8rem; margin-top: 0.15rem; font-size: 0.78rem; }
.links a { color: var(--muted); text-decoration: none; }
.links a:hover { color: var(--accent); text-decoration: underline; }

/* the profile */

#p-more { margin: 0; }
.poster { display: block; width: 100%; height: auto; margin: 1rem 0 1.25rem; border: 1px solid var(--line); border-radius: 0.25rem; }

footer { margin-top: 4rem; color: var(--muted); font-size: 0.85rem; display: flex; gap: 1.2rem; flex-wrap: wrap; }

/* the blog: a post for each list, with its article, the list in full
   and its downloads */
.blog header .header-go { margin-left: auto; }
.blog main { padding-top: 0.5rem; }
.blog-hero { max-width: 46rem; padding: 2rem 0 1rem; }
.blog-hero h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); margin: 0.3rem 0 1rem; }
.byline { color: var(--muted); font-size: 0.9rem; }
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr)); gap: 1.5rem; margin-top: 1.5rem; }
.post-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 1rem; background: var(--card); overflow: hidden; }
.post-card-text { padding: 1.1rem 1.25rem 0.5rem; display: flex; flex-direction: column; flex: 1; }
.post-card h2 { margin: 0.1rem 0 0.4rem; font-size: 1.25rem; }
.post-card h2 a { text-decoration: none; }
.post-card h2 a:hover { text-decoration: underline; }
.post-card .downloads { margin-top: auto; font-size: 0.9rem; }
.crumbs { display: flex; gap: 0.5rem; margin: 1.5rem 0 1.25rem; font-size: 0.9rem; color: var(--muted); }
.post-head { display: block; max-width: 50rem; padding: 0; border: 0; }
.crumbs { align-items: baseline; }
.crumbs a { padding: 0; border: 0; color: var(--muted); }
.post-head h1 { font-size: clamp(2rem, 4.5vw, 3rem); margin: 0.3rem 0 0.6rem; }
.post-body { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: 3rem; align-items: start; }
.post-text .lead { font-size: 1.25rem; max-width: 46rem; }
.post-aside { position: sticky; top: 1rem; }
.post-aside h2 { margin-top: 0.4rem; font-size: 1.1rem; }
.post-aside .button { margin: 0 0.3rem 0.3rem 0; }
.group h2 { border-bottom: 2px solid var(--text); padding-bottom: 0.3rem; margin-top: 2.5rem; }
.entries { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); column-gap: 1.5rem; }
.entries li { display: flex; gap: 0.75rem; align-items: center; padding: 0.45rem 0; border-bottom: 1px solid var(--line); }
.entries li > span:last-child, .entry-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.entries-wide { grid-template-columns: minmax(0, 1fr); }
.entries-wide li { align-items: flex-start; padding: 0.8rem 0; }
.entries .tags { display: flex; flex-wrap: wrap; gap: 0.3rem; margin: 0.45rem 0 0.2rem; }
.tag { font-size: 0.75rem; line-height: 1; padding: 0.3rem 0.55rem; border-radius: 999px; background: var(--line); color: var(--text); white-space: nowrap; }
.entries strong { font-weight: 600; line-height: 1.3; }
.entries strong + span { color: var(--muted); font-size: 0.88rem; }
.more { margin-top: 4rem; }
@media (max-width: 52rem) {
  .post-body { grid-template-columns: 1fr; gap: 1rem; }
  .post-aside { position: static; order: -1; }
}

/* on a narrow screen everything is one column */

@media (max-width: 56rem) {
  body { padding: 0 1rem 3rem; }
  header { gap: 0.25rem 1rem; }
  nav { gap: 0.9rem; }
  h1 { font-size: 1.9rem; margin-top: 2rem; }
  #list, .columns { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  #list { padding-top: 1.25rem; }
  .side { position: static; }
  .tools { margin: 0 -1rem; padding: 0.6rem 1rem; }
  .figures { grid-template-columns: repeat(2, 1fr); margin-bottom: 2rem; }
  .paper { padding: 2rem 1.4rem 1.8rem; }
  .letter p { font-size: 1.1rem; }
  .figure.huge strong { font-size: 3.2rem; }
  .choices { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 30rem) {
  .mark span { display: none; }
  nav { gap: 0.8rem; }
  .items time { display: none; }
  .when { font-size: 0.78rem; }
}

/* the page that verifies a certificate */

.verify .verdict { font: 1.25rem/1.5 var(--serif); margin: 0 0 1.5rem; }
.verify .verdict.ok::before { content: "✓ "; color: #2f7d43; font-weight: 700; }
.verify dl { display: grid; grid-template-columns: max-content 1fr; gap: 0.5rem 1.5rem; margin: 0 0 1.75rem; }
.verify dt { color: var(--muted); }
.verify dd { margin: 0; font-weight: 600; }
.name-form { margin: 2rem 0 0; }
.name-form .small { margin: 0.5rem 0 0; }

/* the page's own question, in place of the browser's */

#ask { width: min(26rem, calc(100vw - 2rem)); padding: 1.6rem 1.6rem 1.3rem; }
#ask p:first-child { font: 1.15rem/1.5 var(--serif); margin: 0 0 1.4rem; }
#ask .row { justify-content: flex-end; margin: 0; }
.danger-button { background: var(--accent); border-color: var(--accent); color: var(--on-accent); font-weight: 600; }


/* the account menu in the head of the page */

.account-menu { position: relative; }
.menu-button { display: flex; align-items: center; gap: 0.3rem; min-height: 2.4rem; padding: 0.3rem 0.6rem; border-radius: 2rem; color: var(--text); }
.menu-button[aria-expanded="true"] { border-color: var(--muted); background: var(--soft); }
.menu-button .chevron { color: var(--muted); transition: transform 0.15s; }
.menu-button[aria-expanded="true"] .chevron { transform: rotate(180deg); }
.menu {
  position: absolute;
  right: 0;
  top: calc(100% + 0.5rem);
  z-index: 10;
  width: 19rem;
  padding: 0.4rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 0.8rem;
  box-shadow: 0 12px 32px rgb(30 20 10 / 0.14), 0 2px 6px rgb(30 20 10 / 0.06);
}
.menu-head { padding: 0.7rem 0.75rem 0.8rem; margin-bottom: 0.3rem; border-bottom: 1px solid var(--line); }
.menu-head .label { margin-bottom: 0.35rem; }
.menu-code { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.4rem; }
.menu-code .code { font-size: 0.86rem; }
.small-button { min-height: 0; padding: 0.2rem 0.6rem; font-size: 0.82rem; border-radius: 0.4rem; }
.menu [role="menuitem"] {
  display: block;
  width: 100%;
  min-height: 0;
  padding: 0.55rem 0.75rem;
  border: 0;
  border-radius: 0.5rem;
  background: none;
  color: var(--text);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 400;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.menu [role="menuitem"]:hover, .menu [role="menuitem"]:focus-visible { background: var(--soft); outline: none; }
.menu [role="menuitem"].danger { color: var(--accent); }
.menu-rule { height: 1px; margin: 0.3rem 0.4rem; background: var(--line); }
#privacy { width: min(30rem, calc(100vw - 2rem)); }
#privacy .row { justify-content: flex-end; margin: 1rem 0 0; }
.account-menu { margin-left: auto; }

@media (max-width: 56rem) {
  header { flex-wrap: wrap; row-gap: 0.4rem; }
  header nav { order: 3; flex-basis: 100%; }
  .menu { position: fixed; left: 1rem; right: 1rem; top: 3.9rem; width: auto; }
}

/* the page of a thing */

.back { color: var(--muted); text-decoration: none; display: inline-block; margin-top: 1.5rem; }
.back:hover { color: var(--text); }
.thing-head { display: flex; gap: 1.6rem; align-items: flex-start; margin: 1rem 0 2.5rem; }
.thing-facts { min-width: 0; }
.thing-facts h1 { margin: 0.2rem 0 0.4rem; font-size: 2.6rem; }
.thing-facts .lead { margin: 0 0 0.8rem; color: var(--muted); }
.thing-facts .links { font-size: 0.9rem; margin: 0 0 1rem; }
.thing-actions { gap: 1.2rem; margin: 0; }
.done-toggle { display: inline-flex; gap: 0.5rem; align-items: center; padding: 0.45rem 0.9rem; border: 1px solid var(--line); border-radius: 2rem; background: var(--card); cursor: pointer; }
.stars-line { color: var(--muted); }
.stars { display: flex; gap: 0.15rem; margin: 0.2rem 0 1.2rem; }
.star { min-height: 0; padding: 0 0.15rem; border: 0; background: none; font-size: 2rem; line-height: 1; color: var(--accent); }
.star .icon { stroke-width: 1.6; }
.star:hover { transform: scale(1.1); }
#review-form textarea { width: 100%; font: inherit; padding: 0.7rem 0.8rem; border: 1px solid var(--line); border-radius: 0.6rem; background: var(--bg); color: var(--text); resize: vertical; margin: 0.2rem 0 0.4rem; }
.review-state { padding: 0.6rem 0.8rem; border-radius: 0.5rem; background: var(--soft); }
.review-state.bad { background: color-mix(in srgb, var(--accent) 14%, var(--card)); }
.reviews { list-style: none; margin: 0; padding: 0; }
.review { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.review p { margin: 0; overflow-wrap: anywhere; }
.review-head { display: flex; flex-wrap: wrap; gap: 0.3rem 0.8rem; align-items: baseline; margin-bottom: 0.4rem !important; }
.stars-small { color: var(--accent); display: inline-flex; gap: 0.05rem; white-space: nowrap; }
.stars-line { display: inline-flex; align-items: center; gap: 0.3rem; }
.title-link { font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.title-link:hover { text-decoration: underline; }
.tick { display: flex; align-items: center; padding: 0.6rem 0; cursor: pointer; }
.cover-link { display: block; flex: none; }
.items li > .what { flex: 1; padding: 0.6rem 0; }

@media (max-width: 56rem) {
  .thing-head { flex-direction: column; align-items: flex-start; gap: 1.2rem; }
  .thing-facts h1 { font-size: 1.9rem; }
}

.items label.tick { flex: none; padding: 0.6rem 0; }

/* the choice of document on the profile: four equal buttons, two by two */

.doc-choice { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.4rem; margin: 0.2rem 0 1rem; }
.doc-choice button { min-height: 2.4rem; padding: 0.35rem 0.6rem; font-size: 0.92rem; color: var(--muted); border-radius: 0.5rem; }
.doc-choice button[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); font-weight: 600; }

/* liking a thing */

.like-button { display: inline-flex; align-items: center; gap: 0.4rem; border-radius: 2rem; padding: 0.4rem 0.9rem; font-variant-numeric: tabular-nums; }
.like-button .heart { color: var(--muted); font-size: 1.1rem; transition: transform 0.15s, color 0.15s; }
.like-button[aria-pressed="true"] { border-color: var(--accent); }
.like-button[aria-pressed="true"] .heart { color: var(--accent); fill: currentColor; transform: scale(1.15); }

/* each thing's stars, likes and ticks in the list */

.row-stats { display: flex; gap: 0.6rem; font-size: 0.75rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.row-stats:empty { display: none; }

/* a field people do not see; scripts fill it in */
.trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.row-stars, .row-likes, .row-did { display: inline-flex; align-items: center; gap: 0.25rem; }
.row-stars { color: var(--accent); }
.row-stars .icon { fill: currentColor; }
.row-count { color: var(--muted); }
.row-likes { color: var(--muted); }

/* what a thing made the people who did it feel */

.moods { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.6rem 0 2rem; }
.mood { display: inline-flex; align-items: center; gap: 0.45rem; min-height: 0; padding: 0.3rem 0.75rem; border-radius: 2rem; font-size: 0.9rem; color: var(--text); }
.mood-count { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 0.82rem; }
.mood-count:empty { display: none; }
.swatch { width: 0.8rem; height: 0.8rem; border-radius: 50%; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text) 25%, transparent); }
.mood[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); }
.mood[aria-pressed="true"] .mood-count { color: color-mix(in srgb, var(--bg) 70%, transparent); }

/* the profile's things: done, rated, tagged */

.archive { margin-top: 2rem; }
.mine-tabs { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.8rem 0 0.4rem; }
.mine-tabs button { border-radius: 2rem; padding: 0.35rem 0.9rem; min-height: 0; color: var(--muted); }
.mine-tabs button[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); font-weight: 600; }
.mine li > .what { flex: 1; padding: 0.6rem 0; }
.mine-stars { color: var(--accent); display: inline-flex; gap: 0.05rem; white-space: nowrap; }
.mine-review { display: block; margin-top: 0.35rem; font-size: 0.92rem; line-height: 1.5; color: var(--text); max-width: 60ch; }
.mine-tags { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-top: 0.35rem; }
.mine-tag { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.1rem 0.55rem; border: 1px solid var(--line); border-radius: 2rem; font-size: 0.8rem; color: var(--muted); }
.pages { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1rem; }
.pages span { color: var(--muted); font-size: 0.9rem; font-variant-numeric: tabular-nums; }

/* the home page: the name, the promise, and the way in */

.hero { padding: 4.5rem 0 3.5rem; text-align: center; }
.hero-name { font: 700 clamp(3rem, 9vw, 5.5rem)/1 var(--serif); letter-spacing: -0.03em; margin: 0; }
.hero-line { font: italic clamp(1.25rem, 2.6vw, 1.75rem)/1.4 var(--serif); max-width: 34ch; margin: 1.4rem auto 2.4rem; color: var(--text); text-wrap: balance; }
.hero-go { margin: 0 0 0.8rem; }
.hero-go button { width: min(100%, 24rem); }
.hero .small { max-width: 38rem; margin: 0 auto; }
#welcome #login { margin-top: 0; }

/* a button that reads as a link */
button.link { all: unset; cursor: pointer; color: var(--text); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 0.2em; }
button.link:hover { text-decoration-color: currentColor; }
button.link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* the giveaway */

.giveaway-banner { display: grid; gap: 0.2rem; text-decoration: none; color: var(--text); border-color: var(--accent); }
.giveaway-banner strong { font: 700 1.25rem/1.25 var(--serif); }
.giveaway-banner:hover { box-shadow: var(--shadow), 0 0 0 1px var(--accent); }
.giveaway { margin-top: 1.5rem; }
.give-prize { font: 700 1.6rem/1.2 var(--serif); margin: 0.2rem 0 0.3rem; }
.giveaway h3 { font-size: 1rem; margin: 1.2rem 0 0.4rem; }
.give-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.give-steps li { display: grid; grid-template-columns: 1.2rem 1fr; column-gap: 0.4rem; }
.give-steps .give-hint { grid-column: 2; margin-top: 0.1rem; }
.give-mark { color: var(--muted); display: inline-flex; width: 1.1rem; justify-content: center; }
.give-mark:empty::before { content: ""; width: 0.35rem; height: 0.35rem; border-radius: 50%; background: currentColor; align-self: center; }
.give-steps li.done .give-mark { color: var(--accent); }
.give-go { margin: 1.1rem 0 0.4rem; }
.give-entered, .give-won { font-weight: 600; }
.give-won { font: 700 1.3rem/1.3 var(--serif); color: var(--accent); }
.give-verify { margin-top: 1rem; }
.give-verify summary { cursor: pointer; }
.give-mono { font-family: var(--mono); font-size: 0.78rem; word-break: break-all; color: var(--muted); }
.give-claim { display: grid; grid-template-columns: 1fr 2fr; gap: 0.6rem 0.8rem; }
.give-claim > p, .give-claim > button, .give-claim .give-name, .give-claim .give-street, .give-claim .give-extra, .give-claim .give-country, .give-claim .give-note { grid-column: 1 / -1; }
.give-field { display: grid; gap: 0.25rem; font-size: 0.9rem; color: var(--muted); }
.rules p { line-height: 1.55; margin: 0 0 0.8em; }
#give-rules { width: min(40rem, calc(100vw - 2rem)); }

/* the organiser's page */

.admin-new { display: grid; gap: 0.7rem; max-width: 34rem; margin: 1rem 0 2rem; }
.admin-new h2 { margin: 0; }
.admin-entries, .admin-reviews { list-style: none; margin: 0; padding: 0; }
.admin-entries li { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; align-items: baseline; padding: 0.4rem 0; border-bottom: 1px solid var(--line); }
.admin-entries .flag { color: var(--accent); font-size: 0.85rem; }
.admin-reviews li { padding: 0.6rem 0; border-bottom: 1px solid var(--line); }
.admin-reviews p { margin: 0.3rem 0 0; }
.admin-redo { margin: 1rem 0; }
.admin-redo input { flex: 1; min-width: 12rem; }
.notice-line { color: var(--accent); font-weight: 600; }

.admin-numbers { margin-bottom: 2.5rem; }
.admin-figures { display: grid; grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr)); gap: 1rem 1.5rem; margin: 0.8rem 0 1.2rem; }
.admin-figures div { border-top: 2px solid var(--text); padding-top: 0.4rem; }
.admin-figures dd { margin: 0; font: 700 1.6rem/1.1 var(--serif); font-variant-numeric: tabular-nums; }
.admin-figures dt { color: var(--muted); font-size: 0.85rem; }
.admin-chart { display: flex; align-items: flex-end; gap: 3px; height: 7rem; padding: 0.4rem 0; border-bottom: 1px solid var(--line); }
.admin-bar { position: relative; flex: 1; height: calc(var(--views) * 100%); min-height: 1px; background: color-mix(in srgb, var(--text) 18%, transparent); border-radius: 2px 2px 0 0; }
.admin-bar::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--visitors) / var(--views) * 100%); background: var(--accent); border-radius: 2px 2px 0 0; }

button:disabled, button:disabled:hover { opacity: 0.45; cursor: not-allowed; }

.give-pic { display: block; width: 100%; max-height: 22rem; object-fit: cover; border-radius: 0.6rem; margin: 0.4rem 0 0.8rem; background: var(--line); }
.give-desc { margin: 0 0 0.6rem; line-height: 1.55; white-space: pre-line; }
.giveaway-banner img { width: 100%; height: 9rem; object-fit: cover; border-radius: 0.5rem; margin-bottom: 0.4rem; }
.admin-prize { display: grid; gap: 0.7rem; max-width: 34rem; margin: 1rem 0 1.5rem; }
.admin-prize .give-pic { max-height: 14rem; margin: 0; }
.give-field textarea { font: inherit; color: var(--text); padding: 0.55rem 0.7rem; border: 1px solid var(--line); border-radius: 0.6rem; background: var(--card); resize: vertical; }

/* the big figures of the stats */

.time-big { margin: 0.2rem 0 0; font: 700 2.6rem/1.1 var(--serif); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }

/* the stats: what the posters show, on the page */

.stats-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; }
.stats-head h1 { margin-bottom: 0.5rem; }
.period-pick { display: flex; align-items: center; gap: 0.5rem; }
.period-pick span { min-width: 9rem; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
.period-pick button { min-height: 0; padding: 0.35rem 0.7rem; }
.st-figures { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin: 1.5rem 0 2rem; }
.st-figure { padding: 1rem 1.2rem; }
.st-figure .time-big { font-size: 2.1rem; }
.st-figure p { margin: 0; }
.st-sub { margin-top: 0.2rem !important; }
.st-card { margin-bottom: 1.5rem; }
.st-card h2 { margin-top: 0; }
.st-genres { display: grid; grid-template-columns: 12rem 1fr; gap: 1.5rem; align-items: center; }
.st-ring { position: relative; width: 12rem; height: 12rem; border-radius: 50%; }
.st-hole { position: absolute; inset: 22%; border-radius: 50%; background: var(--card); display: grid; place-content: center; text-align: center; gap: 0.1rem; padding: 0.5rem; }
.st-hole strong { font: 700 1.6rem/1 var(--serif); }
.st-hole span { font-size: 0.8rem; color: var(--muted); }
.st-legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.45rem; }
.st-legend li { display: grid; grid-template-columns: 0.9rem 1fr auto; gap: 0.5rem; align-items: center; }
.st-gname { text-transform: capitalize; }
.st-chart { display: grid; grid-template-columns: repeat(var(--n, 7), minmax(0, 1fr)); gap: 3px; }
.st-col { display: grid; gap: 0.3rem; justify-items: center; }
.st-track { position: relative; width: 100%; height: 8rem; border-radius: 0.3rem; background: color-mix(in srgb, var(--line) 50%, transparent); overflow: hidden; }
.st-bar { position: absolute; left: 0; right: 0; bottom: 0; background: var(--accent); border-radius: 0.3rem 0.3rem 0 0; }
.st-col.later .st-track { opacity: 0.4; }
.st-label { font-size: 0.72rem; color: var(--muted); min-height: 1em; }
.st-disc { list-style: none; margin: 0.8rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr)); gap: 1rem; }
.st-more { align-self: center; }
.st-posters { position: sticky; top: 1rem; }
@media (max-width: 60rem) { .st-figures { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 36rem) { .st-figures { grid-template-columns: repeat(2, minmax(0, 1fr)); } .st-genres { grid-template-columns: 1fr; justify-items: center; } .st-posters { position: static; } }

/* the profile: the progress and the name, beside the things */
.profile-cols { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); }
.profile-cols .archive { margin-top: 0; }
.profile-cols .archive h2 { margin-top: 0; }

/* the tombola, a page of its own */
#tombola .giveaway { max-width: 44rem; margin-top: 1rem; }

.cert-card { margin-top: 1.5rem; }
.cert-card h2 { margin-top: 0; }
.st-genres.empty { display: block; }

.poster-mark { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 0.9rem; color: var(--muted); cursor: pointer; }
.poster-mark input { width: auto; margin: 0; }


/* the admin dashboard */
.admin-sub { color: var(--muted); margin-top: -0.4rem; }
.admin-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: 1rem; margin: 1rem 0; }
.admin-cards-wide { grid-template-columns: 2fr 1fr; align-items: start; }
@media (max-width: 52rem) { .admin-cards-wide { grid-template-columns: 1fr; } }
.admin-card h3 { margin: 0 0 0.8rem; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-family: var(--sans); }
.admin-card .admin-figures { grid-template-columns: repeat(auto-fill, minmax(6.5rem, 1fr)); gap: 0.9rem 1rem; margin: 0; }
.admin-card .admin-figures div { border-top: 0; padding: 0; }
.admin-figures-small dd { font-size: 1.3rem; }
.admin-visits .admin-chart { margin-top: 0.8rem; }
.admin-axis { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--muted); margin: 0.2rem 0 0.6rem; }
.admin-listbars { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.55rem; }
.admin-listbars li { display: grid; grid-template-columns: 1fr auto; gap: 0.2rem 0.6rem; font-size: 0.9rem; }
.admin-listbar { grid-column: 1 / -1; grid-row: 2; height: 0.45rem; border-radius: 0.25rem; background: linear-gradient(to right, var(--accent) calc(var(--share) * 100%), var(--line) 0); }
.admin-tombola { margin-top: 2.5rem; }
.admin-head { display: flex; align-items: center; gap: 0.8rem; flex-wrap: wrap; }
.admin-head h2 { margin: 0; }
.pill { font-size: 0.78rem; font-weight: 600; padding: 0.15rem 0.6rem; border-radius: 1rem; background: var(--soft); color: var(--muted); }
.pill-running { background: color-mix(in srgb, #2e8b57 18%, transparent); color: #2e8b57; }
.pill-action { background: var(--accent); color: var(--on-accent); }
.pill-drawn, .pill-waiting { background: color-mix(in srgb, #e3a92b 25%, transparent); color: var(--text); }
.admin-tombola > .card { margin-top: 1rem; }
.tombola-card { display: grid; grid-template-columns: 14rem 1fr; gap: 1.4rem; align-items: start; }
.tombola-card:not(:has(.tombola-pic)) { grid-template-columns: 1fr; }
@media (max-width: 40rem) { .tombola-card { grid-template-columns: 1fr; } }
.tombola-pic { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 0.6rem; }
.tombola-text h3 { margin: 0 0 0.4rem; font: 700 1.4rem/1.2 var(--serif); text-transform: none; letter-spacing: 0; color: var(--text); }
.tombola-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: 0.6rem 1rem; margin: 1rem 0; }
.tombola-facts dt { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.tombola-facts dd { margin: 0.1rem 0 0; font-size: 0.92rem; }
.admin-form { display: grid; gap: 0.8rem; max-width: 36rem; }
.admin-form h3 { margin: 0; }
.give-field input:not([type="file"]) { font: inherit; color: var(--text); padding: 0.55rem 0.7rem; border: 1px solid var(--line); border-radius: 0.5rem; background: var(--card); }

/* past tombolas: on the tombola page, and for the organiser */
.tombola-past { margin-top: 2.5rem; }
.past-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.8rem; }
.past-item { display: flex; gap: 1rem; align-items: center; padding: 0.8rem 1rem; }
.past-item > div { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.past-pic { flex: none; width: 4.5rem; height: 4.5rem; border-radius: 0.5rem; overflow: hidden; background: var(--line); }
.past-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.past-result { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem; }
.pill-done { background: color-mix(in srgb, #2e8b57 18%, transparent); color: #2e8b57; }
.admin-past .tombola-card { grid-template-columns: 6rem 1fr; }
.admin-past .past-pic { width: 6rem; height: 6rem; }
.admin-past .admin-head h3 { margin: 0; font: 700 1.15rem/1.2 var(--serif); text-transform: none; letter-spacing: 0; color: var(--text); }
.post-card .tiles .cat-tile:nth-child(n+8) { display: none; }

/* the admin's lists: the things pasted, one a line */
.list-form textarea { width: 100%; font: 0.9rem/1.45 var(--mono); resize: vertical; }
.list-count { display: block; margin: -0.3rem 0 0.6rem; }
.list-card + .list-card { margin-top: 0.8rem; }
.admin-lists > .primary { margin-top: 0.8rem; }

/* the foot of every page: a dark band across the whole width (its colour
   drawn out to the sides, so nothing scrolls sideways), the site, its
   links, the sister sites, and a last line */
:root { --foot-bg: #1c1b19; --foot-text: #f1eee8; --foot-muted: #a8a399; --foot-line: #3a3733; }
@media (prefers-color-scheme: dark) { :root { --foot-bg: #0d0c0b; --foot-line: #2a2825; } }
.site-footer {
  display: block;
  margin: 6rem 0 -4rem;
  padding: 3rem 0 1.5rem;
  background: var(--foot-bg);
  box-shadow: 0 0 0 100vmax var(--foot-bg);
  clip-path: inset(0 -100vmax);
  color: var(--foot-muted);
  font-size: 0.92rem;
}
.footer-inner { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1.4fr); gap: 2.5rem; }
.footer-brand .mark { color: var(--foot-text); text-decoration: none; }
.footer-brand .mark b { color: var(--foot-text); }
.footer-brand p { margin: 0.8rem 0 0; max-width: 22rem; line-height: 1.5; }
.footer-head { margin: 0 0 0.7rem; color: var(--foot-text); font-size: 0.74rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.footer-col { display: flex; flex-direction: column; gap: 0.45rem; }
.footer-col a { color: var(--foot-muted); text-decoration: none; }
.footer-col a:hover { color: var(--foot-text); text-decoration: underline; }
.footer-sisters a { display: flex; flex-direction: column; gap: 0.05rem; margin-bottom: 0.4rem; }
.footer-sisters strong { color: var(--foot-text); font-weight: 600; }
.footer-bottom { margin: 2.5rem 0 0; padding-top: 1.2rem; border-top: 1px solid var(--foot-line); font-size: 0.8rem; }
@media (max-width: 56rem) {
  .site-footer { margin-bottom: -3rem; }
  .footer-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2rem; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 30rem) { .footer-inner { grid-template-columns: minmax(0, 1fr); } }
/* the sister sites in the account menu */
.menu-label { padding: 0.5rem 0.9rem 0.2rem; margin: 0; }
.menu-site { display: flex; flex-direction: column; gap: 0.05rem; }
.menu-site .small { font-size: 0.78rem; }

/* sharing the list: the card in the profile, and the public page */
.share-card { margin-top: 1.25rem; }
.share-card h2 { margin-top: 0; }
.share-card .check { display: flex; gap: 0.5rem; align-items: center; margin: 0.6rem 0; }
.share-link { display: flex; gap: 0.4rem; align-items: center; margin: 0.6rem 0; }
.share-link input { flex: 1; min-width: 0; font: 0.85rem var(--mono); }
.share-body { grid-template-columns: minmax(0, 1fr); }
.entry-done { color: var(--accent); width: 1.15rem; height: 1.15rem; }

/* the stats in the head of a shared list: dense, like the stats page */
.share-stats { margin: 1.1rem 0 0.5rem; padding: 0.9rem 1rem; border: 1px solid var(--line); border-radius: 0.8rem; background: var(--card); }
.share-figures { display: grid; grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr)); gap: 0.5rem 1rem; margin: 0 0 0.8rem; align-items: end; }
.share-figures div { display: flex; flex-direction: column-reverse; }
.share-figures dd { margin: 0; font: 700 1.35rem/1.15 var(--serif); font-variant-numeric: tabular-nums; }
.share-figures dt { font-size: 0.72rem; color: var(--muted); line-height: 1.25; }
.share-charts { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.share-chart .label { margin-bottom: 0.3rem; }
.share-bar { display: block; width: 100%; height: 0.7rem; border-radius: 0.35rem; overflow: hidden; background: var(--line); }
.share-legend { font-size: 0.72rem; margin: 0.35rem 0 0; }
.share-months { display: block; width: 100%; height: 3rem; }
.share-month { fill: var(--accent); }
.share-axis { fill: var(--line); }
.share-month-labels { display: grid; grid-template-columns: repeat(12, 1fr); margin: 0.15rem 0 0; font-size: 0.62rem; color: var(--muted); text-align: center; }
@media (max-width: 40rem) { .share-charts { grid-template-columns: minmax(0, 1fr); } }

/* the admin's blog posts */
.post-form textarea { width: 100%; font: inherit; line-height: 1.5; resize: vertical; }
.post-excerpt { margin: 0.4rem 0; color: var(--muted); font-size: 0.92rem; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

