/* Manifest (/manifest/): what the site keeps in a visitor's browser. Sits on top of public/assets/site.css. */
.manifest { --g-typed: var(--ink); --g-noted: #9E2A2B; --g-settings: #6B7080; --g-games: #C4552B; --g-tools: #D99A2B; --g-tab: #E8C468; --g-other: #15171F; }
.mf-g-typed { --g: var(--g-typed); } .mf-g-noted { --g: var(--g-noted); } .mf-g-settings { --g: var(--g-settings); } .mf-g-games { --g: var(--g-games); }
.mf-g-tools { --g: var(--g-tools); } .mf-g-tab { --g: var(--g-tab); } .mf-g-other { --g: var(--g-other); }

/* the hold: one block a record */
.mf-hold { margin: 26px 0 30px; }
.prose .mf-hold #mf-sum { margin: 0 0 12px; }
#mf-strip { display: flex; gap: 2px; height: 34px; }
.mf-block { flex: 1 1 0; min-width: 5px; background: var(--g); border-radius: 1px; transition: transform .15s ease; }
.mf-block:hover, .mf-block:focus-visible { transform: scaleY(1.22); outline: none; }
.mf-block:focus-visible { box-shadow: 0 0 0 2px var(--ground), 0 0 0 4px var(--ink); }
.mf-block.covered { background: repeating-linear-gradient(135deg, var(--g) 0 2px, transparent 2px 5px); box-shadow: inset 0 0 0 1px var(--g); }
.prose #mf-legend { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 12px 0 0; padding: 0; list-style: none; font: 12px/1.5 var(--mono); color: var(--label); }
.prose #mf-legend li { margin: 0; display: flex; align-items: center; gap: 7px; }
.mf-chip { flex: none; display: inline-block; width: 11px; height: 11px; border-radius: 1px; background: var(--g); }

/* the rows */
.prose .mf-group h2 { display: flex; align-items: center; gap: 10px; }
.prose .mf-drive { margin-bottom: 6px; font-size: 0.92em; font-style: italic; color: var(--subtitle); }
.prose .mf-rows { margin: 0 0 18px; padding: 0; list-style: none; border-top: 1px solid var(--rule); }
.prose .mf-row { display: grid; grid-template-columns: 22px 30px minmax(0, 1fr) auto; column-gap: 14px; align-items: start; margin: 0; padding: 14px 0; border-bottom: 1px solid var(--rule); scroll-margin-top: 16px; }
.mf-row.ticked { background: linear-gradient(90deg, rgba(35, 64, 168, 0.06), transparent 70%); }
.mf-row:target .mf-what h3 { color: var(--ink); }
.mf-pick { display: flex; align-items: center; justify-content: center; height: 30px; cursor: pointer; }
.mf-pick input { width: 17px; height: 17px; margin: 0; accent-color: var(--ink); cursor: pointer; }
.mf-row > .mf-chip { margin: 9px 0 0 9px; }
.mf-what h3 { margin: 3px 0 0; font: 400 1.05em/1.3 var(--serif); }
.prose .mf-what p { margin: 3px 0 0; font-size: 0.8em; line-height: 1.5; color: var(--subtitle); }
.prose .mf-what p:empty { display: none; }
.prose .mf-what .mf-say { color: var(--ink); }
.prose .mf-what .mf-lose { display: none; color: var(--g-noted); }
.mf-row.ticked .mf-lose { display: block; }
.mf-size { padding-top: 6px; font: 12px var(--mono); color: var(--label); white-space: nowrap; }

/* hidden things: a mark that tumbles too fast to read until the thing is found, or spoiled by hand */
.mf-glyph-hold { display: inline-flex; flex: none; width: 30px; height: 30px; align-items: center; justify-content: center; perspective: 70px; color: var(--ink); }
.mf-glyph { display: block; width: 24px; height: 24px; will-change: transform; }
.mf-glyph svg { display: block; width: 24px; height: 24px; }
.mf-row.covered .mf-what h3 { font-style: italic; color: var(--subtitle); }
.prose .mf-parts { margin: 10px 0 0; padding: 0; list-style: none; }
.prose .mf-part { display: flex; gap: 10px; align-items: flex-start; margin: 0; padding: 7px 0; border-top: 1px dotted var(--rule); }
.mf-part-what { min-width: 0; padding-top: 5px; font-size: 0.8em; line-height: 1.5; color: var(--subtitle); }
.mf-part-what strong { display: block; font-weight: 500; color: var(--text); }
.mf-part-what strong:empty { display: none; }
.mf-spoil { all: unset; margin-left: 10px; cursor: pointer; font: 12px var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.mf-what > .mf-spoil { display: inline-block; margin: 8px 0 0; }
.mf-spoil:hover { color: var(--text); } .mf-spoil:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

/* the raw record, for whoever wants it */
.mf-raw { margin-top: 8px; font-size: 0.8em; }
.mf-raw summary { cursor: pointer; color: var(--label); }
.mf-raw pre { max-height: 260px; overflow: auto; margin: 8px 0 0; padding: 10px 12px; background: var(--paper); border: 1px solid var(--rule); font: 11.5px/1.5 var(--mono); white-space: pre-wrap; word-break: break-all; }

/* a row deleted while the page dances: it stops, turns to runes and goes (tools/manifest/ui.js) */
.mf-row.mf-going { opacity: 0.4; transition: opacity 1.2s ease; pointer-events: none; }

/* ticking and deleting */
#mf-bar.live { position: sticky; bottom: 0; z-index: 2; }
#mf-bar { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; margin: 0 -8px 24px; padding: 12px 8px; background: var(--ground); border-top: 1px solid var(--rule); }
#mf-bar .fc-set-btn { min-width: 0; }
#mf-del.sure { color: #FFFFFF; background: var(--g-noted); border-color: var(--g-noted); }
.prose #mf-status { margin: 0 0 20px; font-size: 0.92em; color: var(--ink); }
.prose #mf-status:empty { display: none; }
@media (max-width: 560px) {
  .prose .mf-row { grid-template-columns: 22px 26px minmax(0, 1fr); column-gap: 10px; }
  .mf-size { grid-column: 3; padding-top: 4px; }
  #mf-strip { height: 28px; }
  #mf-bar .fc-set-btn { padding: 7px 9px; font-size: 11.5px; letter-spacing: 0.08em; }
}
@media (prefers-reduced-motion: reduce) { .mf-block { transition: none; } }
