/* Plect, raw.
   As pages looked before they were designed, and as Craigslist and FFFFOUND still do: the machine's own
   sans in one small size, black on white, links blue and underlined, tick boxes, drop-downs and buttons
   the browser's own, a grey bar where a list begins, pictures as they come. Nothing is styled that does
   not have to be: this sheet only puts things where they go.

   The page is used the way those sites are. Down the left runs a directory: the lists, and every style
   there is with how many sets it has, each a link. The middle says where you are (plect > mixes > new >
   acid house) and lists what is there. A set opens beside it as a post does: its picture first, as large
   as the column, then what it is and where it is from. What is on plays in a bar along the bottom. */

:root {
  color-scheme: light;
  --bg: #fff;
  --ink: #000;
  --dim: #666;             /* what is said about a thing */
  --line: #ccc;
  --bar: #eee;             /* the player bar, and a line under the pointer */
  --link: #00e;
  --on: #ffc;              /* what is on: a yellow marker */
  --star: #e8a400;
  /* One grid: everything is a multiple of 4px. A line of type is 20px; a row (a set, a style, a grey bar)
     is 24px, so the directory's rows and the list's rows stand level with each other across the page. */
  --pad: 8px;              /* round things and between them */
  --gap: 4px;              /* between two lines that belong together */
  --row: 24px;
  --side: 224px;           /* the directory */
  --sheet-w: 456px;        /* a set's page */
}
:root[data-theme="dark"] { color-scheme: dark; --bg: #111; --ink: #ddd; --dim: #999; --line: #444; --bar: #1c1c1c; --link: #8ab4f8; --on: #3a3200; }

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
/* Times, as a page is before anyone styles it. Two sizes and one weight: 16px for everything, 24px for the
   name a page is about. Nothing is bold. */
body { overflow: hidden; background: var(--bg); color: var(--ink); font: 16px/20px "Times New Roman", Times, serif; }
h1 { margin: 0; font-size: 24px; line-height: 28px; font-weight: normal; }
h2, h3 { margin: 0; font-size: inherit; font-weight: normal; }
p { margin: 0; }
small, b, strong, i, em { font: inherit; }
ol, ul { list-style: none; margin: 0; padding: 0; }
svg { display: none; }                                   /* (the walk's drawing and the map's samples are shown again below) */
[hidden] { display: none !important; }
.hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.dot, .led, .av, .caret, .disc { display: none; }
/* Anything that can be pressed is a link: blue and underlined, as links are. */
a, button { color: var(--link); text-decoration: underline; cursor: pointer; }
button { background: none; border: 0; padding: 0; font: inherit; text-align: left; }
button:disabled { color: var(--dim); text-decoration: none; cursor: default; }
/* ...except the few that work the player: those are the browser's own buttons. */
#deck-toggle, #deck-prev, #deck-next, #sheet .act, .head .follow { all: revert; font: inherit; cursor: pointer; }
/* what is chosen among several is not a link: it is where you are */
[aria-pressed="true"]:not(.save, .check, .follow) { color: var(--ink); text-decoration: none; cursor: default; }
select, input { font: inherit; }
label { white-space: nowrap; cursor: pointer; }

/* Pressing. Whatever can be pressed turns blue under the pointer and black while it is held down, at
   once, with no easing: the page answers the hand the moment it moves. Where you already are does not
   answer, nor does what cannot be pressed now. A picture that can be pressed gets a blue frame instead. */
:is(a, button):not(:disabled, [aria-pressed="true"]:not(.save, .check, .follow), [aria-current]):hover { background-color: var(--link); color: var(--bg); text-decoration: none; }
:is(a, button):not(:disabled, [aria-pressed="true"]:not(.save, .check, .follow), [aria-current]):active { background-color: var(--ink); color: var(--bg); }
:is(a, button):not(:disabled):is(:hover, :active) *,
:is(a, button):not(:disabled):is(:hover, :active) *::before,
:is(a, button):not(:disabled):is(:hover, :active)::before,
:is(a, button):not(:disabled):is(:hover, :active)::after { color: inherit; text-decoration: none; }
:is(.thumb, .cover, .pic):not(.blank):hover { outline: 2px solid var(--link); outline-offset: -2px; }
:is(.thumb, .cover, .pic):not(.blank):active { outline-color: var(--ink); }
label:hover { background-color: var(--line); }
label:active { background-color: var(--ink); color: var(--bg); }
select:hover, input:is([type="search"], [type="text"], :not([type])):hover { outline: 1px solid var(--link); }
/* a grey bar: over a list, over a part of the directory, over a part of a page */
#top h2, #views::before, .cols, #sheet h2 { background: var(--line); }
:root[data-theme="dark"] :is(#top h2, #views::before, .cols, #sheet h2) { background: #2a2a2a; }

/* ---- the directory, down the left ------------------------------------------------------------------------
   The page's name (the way home), the box to search in, the lists, the two drawings of the graph, and
   every style. */

#top {
  position: fixed; z-index: 3; top: 0; left: 0; bottom: var(--inset-bottom, 0px); width: var(--side);
  display: flex; flex-direction: column; overflow-y: auto; padding: var(--pad) var(--pad) calc(var(--row) * 2); background: var(--bg); border-right: 1px solid var(--line);
}
#top > *, #dir > * { flex: none; }
/* The head of the directory is two rows, level with the two rows over the list beside it: the mark with
   light or dark and the other look; then the box to search in. The first grey bar under them stands
   level with the grey bar over the list. */
/* (the page's name is its mark alone, in the blue of a link: it is one, the way home.
   It turns, as a page's logo did when pages were new: the mark cut out of a slab a quarter as deep as it
   is wide, going round once in three seconds in twenty-four still frames, the way a GIF does. The slab
   is eleven sheets of the mark, one behind the other (index.html says how far forward each stands): the
   two outer ones are its faces, in the blue of a link and dimmer as they turn away; the ones between are
   its sides, darker. No frame shows it edge-on, where sheets have no width. Asked to keep things still,
   it stands, turned a little so that its depth shows. A page that comes without the sheets shows the
   mark flat.) */
#mark { display: inline-flex; align-self: flex-start; color: var(--link); text-decoration: none; perspective: calc(var(--row) * 4); --cut: url("/logo.svg") center / contain no-repeat; --edge: color-mix(in srgb, currentColor 55%, #000); }
#mark:hover { color: var(--bg); --edge: color-mix(in srgb, currentColor 55%, var(--link)); }
#mark span { display: none; }
#mark b { position: relative; width: var(--row); height: var(--row); transform-style: preserve-3d; transform: rotateY(-30deg); }
#mark i { position: absolute; inset: 0; background: var(--edge); -webkit-mask: var(--cut); mask: var(--cut); transform: translateZ(calc(var(--z) * var(--row) / 40)); }
#mark i:first-child, #mark i:last-child { background: currentColor; }
#mark:not(:has(b))::before { content: ""; width: var(--row); height: var(--row); background: currentColor; -webkit-mask: var(--cut); mask: var(--cut); }
@media (prefers-reduced-motion: no-preference) {
  #mark b { animation: turn 3s steps(24) infinite; }
  #mark i:first-child, #mark i:last-child { animation: lit .75s steps(6) infinite alternate; }
}
@keyframes turn { from { transform: rotateY(7.5deg); } to { transform: rotateY(367.5deg); } }
@keyframes lit { to { background-color: color-mix(in srgb, currentColor 50%, var(--edge)); } }
#search { position: relative; margin: var(--gap) 0 0; }
#q { display: block; width: 100%; height: var(--row); margin: 0; }
#hits { position: fixed; z-index: 6; left: var(--pad); top: calc(var(--pad) + var(--row) * 2 + var(--gap)); width: 384px; max-width: calc(100vw - 2 * var(--pad)); max-height: 60vh; overflow: auto; background: var(--bg); border: 1px solid var(--dim); }
#hits button { display: flex; justify-content: space-between; gap: var(--pad); width: 100%; padding: 2px var(--gap); color: var(--ink); text-decoration: none; }
#hits button:hover, #hits button.on { background: Highlight; color: HighlightText; }
#hits button:active { background: var(--ink); color: var(--bg); }
#hits small { color: inherit; opacity: .7; white-space: nowrap; }
#hits li.find { border-bottom: 1px solid var(--line); }
/* (the parts of the directory are drawn by the list; they stand in this column in this order, a row
   apart, so that every row in it stays level with a row of the list) */
#dir { display: contents; }
#top h2, #views::before { margin: var(--row) calc(var(--pad) * -1) 0; padding: 2px var(--pad); }
#dir > h2:first-child { margin-top: var(--pad); }
#dir li { padding: 2px 0; }
#dir small { color: var(--dim); }
#dir > :nth-child(1) { order: 1; } #dir > :nth-child(2) { order: 2; }       /* mixes */
#views { order: 3; display: flex; flex-direction: column; align-items: flex-start; text-transform: lowercase; }
#views::before { content: "graph"; align-self: stretch; }
#views button { margin: 2px 0; text-transform: lowercase; }
#views [data-view="mixes"] { display: none; }                                /* (the lists above are the way to them) */
#dir > :nth-child(3) { order: 4; } #dir > :nth-child(4) { order: 5; }       /* styles */
/* (light or dark, and the way to Plect's other look: beside the mark, where they are seen without scrolling) */
#switches { position: absolute; top: var(--pad); right: var(--pad); display: flex; gap: var(--pad); line-height: var(--row); }
#theme::before { content: attr(title) " page"; text-transform: lowercase; }
/* (a hosted Plect: the name you go by, right under "kept", which is what it is for) */
#me { order: 2; align-self: flex-start; margin: 2px 0; }
#ties { order: 7; display: flex; flex-direction: column; margin: var(--row) 0 0; padding: 0; border: 0; min-width: 0; }
#ties label { display: inline-flex; align-items: center; gap: var(--gap); padding: 2px 0; white-space: normal; }
#ties input { margin: 0; }
#ties svg { display: block; flex: none; width: 24px; height: 8px; overflow: visible; }
#ties label:has(input:not(:checked)) { color: var(--dim); }
#about { margin-top: var(--gap); }
/* Folded (app.js setupFold): the directory is a rail as wide as the mark, the way to open it again under
   the mark, and everything beside it has the room. Not on a phone, where it lies across the top. */
#fold { min-width: 1ch; text-align: center; }
@media (min-width: 821px) {
  :root.folded { --side: 40px; }
  :root.folded #top { overflow: hidden; }
  :root.folded #top > :not(#mark, #switches), :root.folded #switches > :not(#fold) { display: none; }
  :root.folded #switches { position: static; align-self: stretch; justify-content: center; margin-top: var(--gap); line-height: var(--row); }
}

/* ---- three things to look at ----------------------------------------------------------------------------- */

body.mixes #map, body.walk #map { visibility: hidden; }
body.mixes #ties, body.mixes #status, body.walk #ties, body.walk #status { display: none; }
body:not(.mixes) #finder { visibility: hidden; pointer-events: none; z-index: 1; }
body:not(.mixes) #deck-embed:not(.shut) { visibility: visible; pointer-events: auto; }
#map { position: fixed; top: 0; left: var(--side); right: 0; bottom: 0; touch-action: none; cursor: grab; }
#map.dragging { cursor: grabbing; }
#map.pointing { cursor: pointer; }
#map canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#type { pointer-events: none; }

/* ---- the middle: where you are, and what is there ------------------------------------------------------- */

#finder {
  position: fixed; top: 0; left: var(--side); right: var(--inset-right, 0px); bottom: var(--finder-bottom, 0px);
  overflow-y: auto; display: flex; flex-direction: column; padding: 0 var(--pad);
  container: finder / inline-size;
}
#finder > * { flex: none; }
/* Someone's sets open under a header of their own: where you are, their picture, their name, their lists.
   It scrolls away with the list; the row of controls under it stays. */
#finder .head { padding: var(--pad) 0 var(--gap); }
#finder .head[hidden] { display: none; }
/* Their picture, four rows tall, and beside it three lines: the name (with Follow), what they are, their lists.
   The first line is level with the picture's top and the last with its foot; the space between is shared. */
.hero { display: flex; align-items: stretch; gap: var(--row); }
.hero .face { flex: none; width: 96px; height: 96px; object-fit: cover; background: var(--bar); border: 1px solid var(--line); }
.hero .id { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: space-between; gap: var(--gap); }
.hero.bare .id { justify-content: flex-start; }
.hero h1 { min-width: 0; overflow-wrap: anywhere; }
/* the name, and following them beside it: the one button over the list that is the browser's own */
.hero .named { display: flex; flex-wrap: wrap; align-items: center; gap: var(--gap) var(--pad); margin-top: -2px; }
.hero .named .follow { flex: none; }
.hero .facts { color: var(--dim); }
.hero .facts:empty { display: none; }
.hero .bar { margin: 0; }
/* how many there are in each list, after its name: said, not shouted */
.hero .group small, .crumb small { color: var(--dim); }
:is(a, button):not(:disabled):is(:hover, :active) small { color: inherit; }
/* about them, and their name searched for: at the far end of the line of their lists */
.hero .also { display: inline-flex; gap: var(--pad); margin-left: auto; }
/* At the top of every page, where you are (plect > new > acid house); over the list, under it, what to show.
   Each is a row tall and stands level with a row of the directory's head; the first is level with the
   top line of a page beside the list. Both stay as the page scrolls. */
.where { position: sticky; top: 0; z-index: 3; padding: var(--pad) 0 0; background: var(--bg); }
.tabs { position: sticky; top: var(--where-h, 0px); z-index: 3; padding: var(--gap) 0 var(--pad); background: var(--bg); }
.crumb { line-height: var(--row); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumb i { color: var(--dim); font-style: normal; }
/* the controls: what belongs to this list, the kinds of set, and at the far end how they are shown */
.tabs .bar, .head .bar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--gap) var(--pad); min-height: var(--row); margin-top: var(--gap); }
.tabs .bar:first-child { margin-top: 0; }
.tabs .group button + button::before, .head .group button + button::before, .tabs .views button + button::before, #walk .tools button + button::before { content: "|"; display: inline-block; margin: 0 var(--gap); color: var(--dim); }
/* (the bar between two links is not part of either: it does not turn blue with them) */
.tabs .group button + button, .head .group button + button, .tabs .views button + button, #walk .tools button + button { position: relative; margin-left: 10px; }
.tabs .group button + button::before, .head .group button + button::before, .tabs .views button + button::before, #walk .tools button + button::before { position: absolute; right: 100%; margin: 0 3px 0 0; color: var(--dim) !important; background: none; }
.tabs .views { margin-left: auto; }
.tabs .small { display: none; }
.tabs label, #walk label { display: inline-flex; align-items: center; gap: var(--gap); }
.tabs input, #walk input { margin: 0; }
.tabs select { height: var(--row); }
#finder .lead { padding: 0 0 var(--pad); color: var(--dim); max-width: 900px; }
#finder .lead:empty { display: none; }
#finder.loading .mixes { opacity: .5; }

/* a set is one line: its picture, the star that keeps it, when, who, what, what is in it, and its numbers */
.mixes {
  display: grid; column-gap: var(--pad);
  grid-template-columns: [pic] 20px [save] 18px [date] 84px [dj] minmax(0, 4fr) [title] minmax(0, 7fr) [with] minmax(0, 4fr) [rep] 30px [trk] 30px [len] 60px [src] 40px;
}
/* (a row is 20px with its line: 2px over the type, 1px under it, and the dotted line) */
.cols, .mix { display: grid; grid-template-columns: subgrid; grid-column: 1 / -1; padding: 2px 0 1px; }
.cols { position: sticky; top: calc(var(--where-h, 0px) + var(--tabs-h, 0px)); z-index: 1; margin: 0 calc(var(--pad) * -1); padding: 1px var(--pad); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.cols > *, .mix > *, .mix .what > * { grid-row: 1; min-width: 0; }
.cols .r { text-align: right; }
.cols .c-date, .mix .date { grid-column-start: date; } .cols .c-dj, .mix .dj { grid-column-start: dj; }
.cols .c-title, .mix .title { grid-column-start: title; } .cols .c-with, .mix .with { grid-column-start: with; }
.cols .c-rep, .mix .rep { grid-column-start: rep; } .cols .c-trk, .mix .trk { grid-column-start: trk; }
.cols .c-len, .mix .len { grid-column-start: len; } .cols .c-src, .mix .src { grid-column-start: src; }
.mix .save { grid-column-start: save; }
.mix { border-bottom: 1px dotted var(--line); cursor: pointer; }
/* The mark that plays a set stands at the start of its line (its title leads to its page). On the set
   that is on it is the mark that pauses it. */
/* (no play marks: a set's line leads to its page, where it is played; in the gallery its picture plays it,
   and what is on is the yellow line) */
.mix .no { display: none; }
.mix .what { display: contents; }
.mix .what:not(:has(.dj)) .title, .mix .what:not(:has(.title)) .dj { grid-column: dj / with; }
.mix .dj, .mix .title, .mix .with { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* (a name is as wide as its words, so the blue under the pointer covers the name, not its column) */
.mix .dj, .mix .title { justify-self: start; max-width: 100%; }
.mix .date, .mix .len, .mix .src, .mix .with { color: var(--dim); }
.mix .rep, .mix .trk, .mix .len { justify-self: end; white-space: nowrap; }
.mix:hover { background: var(--bar); }
.mix:active { background: var(--line); }
.mix.now, .mix.now:hover { background: var(--on); }
.mix .with.cue { display: flex; }
.mix .with.cue .why { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.mix .with .at { flex: none; margin-left: 4px; }
/* keeping: a star, as a list of things for sale has */
.save { text-decoration: none; }
/* (the star that keeps a set: large and black, so it is found at a glance; gold once it is kept) */
.mix .save::before, #sheet .acts .save::before, #deck-save::before { content: "☆"; color: var(--ink); }
.mix .save.on::before, #sheet .acts .save.on::before, #deck-save.on::before { content: "★"; color: var(--star); }
#sheet .acts .save, #deck-save { text-decoration: underline; }
/* (the star is the one thing drawn larger than the type: 18px, on a line of 20px, wherever it is) */
#sheet .acts .save::before, #deck-save::before { display: inline-block; margin-right: var(--gap); font-size: 18px; line-height: 20px; vertical-align: -2px; text-decoration: none; }
:is(#sheet .acts .save, #deck-save):is(:hover, :active)::before { color: inherit; }
ol.mixes:not(.rich) .mix .save { font-size: 18px; line-height: 20px; }
.mix.off { cursor: default; }
.mix.off .dj, .mix.off .title { color: var(--dim); }

/* In the list each set has its picture small at the start of its line, as a list of things for sale has.
   The picture is one line of type tall (20px), so a set's line stays one row (24px), level with the
   directory's. The picture plays the set, as it does in the gallery; one with no picture at all is an
   empty grey box. */
ol.mixes:not(.rich) .mix { align-items: center; }
ol.mixes:not(.rich) .mix .cover { display: block; grid-column-start: pic; width: 20px; height: 20px; background: var(--bar) center / cover no-repeat; border: 1px solid var(--line); }
ol.mixes:not(.rich) .mix .cover span { display: none; }

/* the gallery: the same sets with their pictures, in rows that read across like the list reads down,
   each with what it is under it */
.mix .cover { display: none; }
/* (as many pictures to a row as fit at 200px, then stretched so the row reaches the right edge) */
.mixes.rich { display: grid; grid-template-columns: repeat(auto-fill, minmax(198px, 1fr)); gap: var(--row) var(--pad); padding: 0 0 var(--pad); }
/* ...or as many in a row as asked for, three to ten ("per row 3 4 5 ... 10" after "list | gallery") */
.mixes.rich.per-row { grid-template-columns: repeat(var(--per-row), minmax(0, 1fr)); }
.mixes.rich .mix { display: flex; flex-wrap: wrap; align-items: baseline; align-content: flex-start; grid-column: auto; min-width: 0; padding: 0; border: 0; }
.mixes.rich .mix:hover { background: none; }
.mixes.rich .mix > *, .mixes.rich .mix .what > * { display: block; max-width: 100%; }
.mixes.rich .mix .what { display: block; flex: 0 0 100%; min-width: 0; }
.mixes.rich .mix .cover { order: -1; flex: none; width: 100%; aspect-ratio: 1; margin-bottom: var(--gap); background: var(--bar) center / cover no-repeat; border: 1px solid var(--line); }
/* (no picture of its own, nor its DJ's: the set's name stands where the picture would, large, on the grey of an empty box) */
.mixes.rich .mix .cover.blank { display: block; padding: var(--pad); overflow: hidden; text-align: left; text-decoration: none; color: var(--ink); font-size: 24px; line-height: 30px; overflow-wrap: anywhere; }
.mixes.rich .mix .cover.blank:hover { background-color: var(--link); color: var(--bg); }
.mixes.rich .mix .cover.blank:active { background-color: var(--ink); color: var(--bg); }
.mixes.rich .mix .with, .mixes.rich .mix .rep, .mixes.rich .mix .src { display: none; }
.mixes.rich .mix .date, .mixes.rich .mix .trk, .mixes.rich .mix .len, .mixes.rich .mix .save { display: inline; margin-right: var(--gap); color: var(--dim); }
.mixes.rich .mix .trk::after { content: " tracks"; }
.mixes.rich .mix .save { margin: 0 0 0 auto; font-size: 18px; line-height: 20px; }
.mixes.rich .mix.now { background: var(--on); outline: 4px solid var(--on); }

.mixes .none { grid-column: 1 / -1; padding: var(--pad) 0; color: var(--dim); }
#finder .more { align-self: flex-start; margin-top: var(--pad); text-transform: lowercase; }
#finder .more::after { content: " »"; }
#finder .foot { flex: 1 0 auto; padding: var(--row) 0 40px; color: var(--dim); }
#finder .foot span { margin-right: var(--pad); }
#finder .foot i { margin-right: var(--gap); font-style: normal; }
body.tray #finder .foot { padding-bottom: 300px; }

/* ---- where SoundCloud's or YouTube's own player is ------------------------------------------------------------
   One box that is never moved in the page (moving a player restarts it): it sits in the corner of the
   list, or over the picture of the set that is on when the list is shown as a gallery. */
#stage { position: sticky; bottom: 0; height: 0; }
#stage.placed { position: static; }
#deck-embed { position: absolute; z-index: 2; right: 0; bottom: 0; width: min(430px, 100%); aspect-ratio: 16 / 9; background: #000; border: 1px solid var(--dim); overflow: hidden; }
#stage.placed #deck-embed { right: auto; bottom: auto; aspect-ratio: auto; }
#deck-embed iframe { width: 100%; height: 100%; border: 0; display: block; }
#deck-embed > div { display: none; width: 100%; height: 100%; position: relative; }
/* (the set likely to be played next, got ready in a second player of SoundCloud's that no one sees: deck.js `prepare`) */
#deck-embed .spare { position: absolute; inset: 0; visibility: hidden; pointer-events: none; }
#deck-embed .yt > div { width: 100%; height: 100%; }
#deck-embed[data-on="sc"] > .sc, #deck-embed[data-on="yt"] > .yt, #deck-embed[data-on="mc"] > .mc { display: block; }
#deck-embed.shut { visibility: hidden; pointer-events: none; }
#deck-embed.changing > div { visibility: hidden; }
/* (on the page of a set that is not on: the player got ready for it is shown over its picture, the one in use is not) */
#deck-embed.preview > div { display: none; }
#deck-embed.preview[data-look="sc"] > .sc, #deck-embed.preview[data-look="yt"] > .yt, #deck-embed.preview[data-look="mc"] > .mc { display: block; }
#deck-embed.preview > div > :not(.spare) { visibility: hidden; }
#deck-embed.preview .spare { visibility: visible; pointer-events: auto; }
#stage.placed #deck-embed.changing { opacity: 0; pointer-events: none; }

/* ---- the walk ------------------------------------------------------------------------------------------------ */

#walk { position: fixed; top: 0; left: var(--side); right: var(--inset-right, 0px); bottom: var(--inset-bottom, 0px); display: flex; flex-direction: column; background: var(--bg); }
body:not(.walk) #walk { display: none; }
#walk .strip { flex: none; display: flex; flex-wrap: wrap; align-items: center; gap: var(--gap) var(--row); min-height: 36px; padding: var(--pad); border-bottom: 1px solid var(--line); }
#walk .trail { flex: 1 1 240px; min-width: 0; display: flex; overflow: hidden; white-space: nowrap; }
#walk .trail li { flex: 0 1 auto; min-width: 2ch; display: flex; }
#walk .trail li:last-child { flex-shrink: 0; }
#walk .trail li + li::before { content: ">"; flex: none; margin: 0 var(--gap); color: var(--dim); }
#walk .trail button { min-width: 0; max-width: 26ch; overflow: hidden; text-overflow: ellipsis; }
#walk .trail button[aria-current] { color: var(--ink); text-decoration: none; }
#walk .tools { margin-left: auto; }
#walk .check .box { display: none; }
#walk .check::after { content: " ☐"; display: inline-block; text-decoration: none; }
#walk .check[aria-pressed="true"]::after { content: " ☑"; }
#walk .field { flex: 1 1 0; min-height: 0; overflow: hidden auto; }
#walk.loading .field { opacity: .5; }
#walk svg { display: block; width: 100%; }
#walk text { font: 16px "Times New Roman", Times, serif; fill: currentColor; paint-order: stroke; stroke: var(--bg); stroke-width: 4px; stroke-linejoin: round; }
#walk .caps text, #walk .node .n { fill: var(--dim); }
#walk .node { cursor: pointer; color: var(--link); }
#walk .node.faint { color: var(--dim); }
#walk .node.at { color: var(--ink); }
#walk .node:not(.at):hover { color: var(--ink); }
#walk .node:not(.at):hover text:not(.n, .note) { text-decoration: underline; }
#walk .node:active { color: var(--star); }
#walk .node.gone { opacity: 0; pointer-events: none; }
#walk .node .note { fill: var(--dim); font-weight: normal; }
#walk .node .hit { fill: transparent; stroke: none; }
#walk .node .clear { fill: var(--bg); }
#walk .ring { fill: var(--bg); stroke-width: 1.5; }
#walk .cover { fill: var(--bar); }
#walk .edge { fill: none; stroke: var(--line); }
#walk .node.at .edge { stroke: var(--ink); }
#walk .gem { fill: var(--bg); stroke: var(--dim); stroke-width: 1.2; }
#walk .play { fill: #fff; opacity: 0; }
#walk .node.at.hot .play { opacity: 1; }
#walk .node.now .edge { stroke: var(--star); stroke-width: 3; }
#walk .node.now .gem { fill: var(--on); stroke: var(--star); }
#walk .spokes line, #walk .spokes path, #walk .ties path { fill: none; stroke: var(--line); }
#walk .spokes .hot { stroke: var(--link); }
#walk .ties .hot { stroke: var(--dim); }
#walk .says { flex: none; min-height: 24px; padding: var(--gap) var(--pad) 3px; border-top: 1px solid var(--line); color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#walk .says b { margin-right: var(--gap); color: var(--ink); }
#walk .says i { font-style: normal; }
#walk .legend { display: inline-flex; align-items: center; gap: 4px; }
#walk .legend svg { display: block; width: 12px; height: 12px; margin-left: var(--pad); fill: var(--dim); }
#walk .legend svg:first-child { margin-left: 0; }
#walk .legend .ring, #walk .legend .gem { fill: var(--bg); stroke: var(--dim); stroke-width: 1.5; }
#walk .legend .cover { fill: var(--bar); stroke: var(--dim); }
#walk .legend .on { fill: var(--star); }
body.walk #sheet .walk { display: none; }

/* ---- a set (or a name, or a track) opened beside the list: a post -----------------------------------------
   What it is and the way back in a grey bar; then its picture, as wide as the column and as tall as it
   comes; then its name, what is known of it, and what to do with it; then its parts under grey bars. Sets
   in it stand with their pictures beside them. */

#sheet {
  position: fixed; z-index: 4; top: 0; right: 0; bottom: var(--inset-bottom, 0px); width: var(--sheet-w); max-width: 100vw;
  background: var(--bg); border-left: 1px solid var(--line); overflow-y: auto; padding: 0 var(--pad) 40px;
}
/* (its top line is a row tall, a pad under the top, level with where you are over the list beside it: the
   user, of a grey bar here that sat higher and was shallower than the line beside it: "the line height etc
   here is so different...") */
#sheet .bar { position: sticky; z-index: 2; top: 0; display: flex; align-items: center; gap: var(--pad); margin: 0 calc(var(--pad) * -1) 12px; padding: var(--pad) var(--pad) 7px; line-height: var(--row); background: var(--bg); border-bottom: 1px solid var(--line); }
#sheet .kind { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#sheet .back, #sheet .close { flex: none; display: flex; font-size: 0; }
#sheet .back::before { content: "« back"; font-size: 16px; }
/* (the way back points left and stands first in the line, as it does over the list; the cross ends the line.
   The user, of it at the far right: "the back button is so weird here...") */
#sheet .back { order: -1; }
#sheet .close::before { content: "close ×"; font-size: 16px; }
#sheet .pic { display: block; margin-bottom: var(--pad); }
#sheet .pic img { display: block; width: 100%; height: auto; border: 1px solid var(--line); }
/* (a video's still comes with black bars over and under it: shown at the shape of the video, they are cut off) */
#sheet .pic.wide img { aspect-ratio: 16 / 9; object-fit: cover; }
#sheet h1 { margin: 0 0 var(--gap); overflow-wrap: anywhere; }
#sheet .empty { margin-top: var(--pad); }
#sheet .facts + .facts { margin-top: var(--gap); color: var(--dim); }
#sheet .acts { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--gap) var(--pad); margin-top: var(--pad); }
#sheet .acts:empty { display: none; }
#sheet .acts span.plain { color: var(--dim); }
/* Beside a list a set's page is one column: what it is, then what else there is. */
#sheet .main, #sheet .theirs, #sheet .also { display: contents; }
#sheet .acts .out::after { content: " \2197"; }

/* ---- a set's own page ------------------------------------------------------------------------------------
   In the list view a set is not laid beside the list: it takes the list's place, under its own address,
   which is the link to it. Two columns: on the left, two parts of three wide, the set itself, top to
   bottom: its picture as a wide band (the player lies over it), what it is, its tracklist. On the right
   every other set: the DJ's own, then what is like it, then what is close to it.
   The page stands in the list's own scroller (app.js `lay`), so everything else there is put away while
   it is open. */
body.paged #finder > :not(#sheet):not(#stage):not(.where) { display: none; }
body.paged #sheet {
  position: static; z-index: auto; width: auto; max-width: none; max-height: none; border: 0; overflow: visible; padding: 0 0 40px;
  display: grid; grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr); grid-template-rows: auto auto 1fr;
  grid-template-areas: "bar bar" "pic also" "main also"; column-gap: var(--row); align-items: start;
}
body.paged #sheet[hidden] { display: none; }
/* (no picture: what it is heads the left column) */
body.paged #sheet:not(:has(> .pic)) { grid-template-rows: auto 1fr; grid-template-areas: "bar bar" "main also"; }
/* (nothing else is known yet: the set has the room) */
body.paged #sheet:has(> .also:empty) { grid-template-columns: minmax(0, 1fr); grid-template-areas: "bar" "pic" "main"; }
body.paged #sheet:not(:has(> .pic)):has(> .also:empty) { grid-template-areas: "bar" "main"; }
/* (a page's bar is the second row, under where you are, as the controls are over a list: its line under it
   stands where the list's grey bar begins) */
body.paged #sheet .bar { grid-area: bar; z-index: 3; top: var(--where-h, 0px); padding-top: var(--gap); }
/* (the picture is a wide band, as wide as the column: the whole picture in it, on grey, so a square logo is
   not cut; the player lies over the band and fills it) */
body.paged #sheet .pic { grid-area: pic; margin: 0 0 var(--row); aspect-ratio: 5 / 2; max-height: 440px; width: 100%; background: var(--bar); border: 1px solid var(--line); }
body.paged #sheet .pic img, body.paged #sheet .pic.wide img { width: 100%; height: 100%; aspect-ratio: auto; object-fit: contain; border: 0; }
body.paged #sheet .main { display: block; grid-area: main; min-width: 0; }
body.paged #sheet .also { display: block; grid-area: also; min-width: 0; }
body.paged #sheet h1 { margin: -4px 0 var(--gap); }
body.paged #sheet .also > section:first-child { margin-top: 0; }
body.paged #sheet .close::before { content: "to the list \00d7"; }
@container finder (max-width: 720px) {
  body.paged #sheet { display: block; }
  body.paged #sheet .pic { margin-bottom: var(--pad); }
  body.paged #sheet .also > section:first-child { margin-top: var(--row); }
}

#sheet section { margin-top: var(--row); }
#sheet h2 { margin: 0 calc(var(--pad) * -1); padding: 2px var(--pad); }
#sheet h2 small { margin-left: var(--pad); color: var(--dim); }
#sheet section > p { margin: var(--gap) 0; color: var(--dim); }
/* (a row in a page is 20px with its dotted line, as a row of the list is; one with a picture is two rows) */
.rows li { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: var(--pad); padding: 2px 0 1px; border-bottom: 1px dotted var(--line); }
.rows li.pictured { grid-template-columns: 32px minmax(0, 1fr) auto; align-items: center; padding: var(--gap) 0 3px; }
.rows .thumb { width: 32px; height: 32px; background: var(--bar) center / cover no-repeat; border: 1px solid var(--line); }
/* (a listed set's small picture plays it; its name leads to its page) */
.rows button.thumb { position: relative; padding: 0; text-decoration: none; cursor: pointer; }
.rows li > button, .rows li > a.row { min-width: 0; }
.rows .name, .rows .sub { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rows .sub { color: var(--dim); }
.rows li > button:has(.sub) { text-decoration: none; }
.rows li > button:has(.sub) .name { text-decoration: underline; }
.rows .n { align-self: start; color: var(--dim); white-space: nowrap; }
.rows li.pictured .n { align-self: center; }
.rows li.off > button:first-of-type, .rows li.off > a.row { color: var(--dim); }
.rows li.now { background: var(--on); }
.cues li { grid-template-columns: 60px minmax(0, 1fr) auto; }
.cues .at { align-self: start; }
.cues .at.guess, .cues .at:disabled { color: var(--dim); }
.tracklist li { grid-template-columns: 60px minmax(0, 1fr); }
/* (a tracklist that gives no times has no column for them: the tracks start at the edge, not after a gap) */
.tracklist.untimed li { grid-template-columns: minmax(0, 1fr); }
.tracklist.untimed .at { display: none; }
/* (a track is one line, who and then what, as a tracklist is written; a long one goes on to a second line) */
.tracklist .cell { min-width: 0; display: flex; flex-wrap: wrap; column-gap: .3em; }
.tracklist .who, .tracklist .what { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tracklist .what { color: var(--dim); }
.tracklist .who:not(:empty) + .what:not(:empty)::before { content: "\2013"; display: inline-block; margin-right: .3em; }
.tracklist .what:empty { display: none; }
.rows li.why { display: block; padding: var(--gap) 0 var(--pad) var(--pad); border-left: 3px solid var(--line); }
.why p { color: var(--dim); }
#sheet .join { position: relative; margin-top: var(--gap); }
#sheet .join input { width: 100%; height: var(--row); }
#sheet .join ol { position: absolute; z-index: 2; top: 100%; left: 0; right: 0; background: var(--bg); border: 1px solid var(--dim); }
#sheet .join ol button { display: block; width: 100%; padding: 2px var(--gap); color: var(--ink); text-decoration: none; }
#sheet .join ol button:hover { background: Highlight; color: HighlightText; }
#sheet .join ol button:active { background: var(--ink); color: var(--bg); }
.chain > li { margin: 0 0 var(--pad) 18px; list-style: disc; }
.chain .tie { display: block; color: var(--dim); }
.empty { margin-top: var(--row); color: var(--dim); max-width: 44ch; }

/* ---- status line, on the map ----------------------------------------------------------------------- */

#status { position: fixed; z-index: 1; left: calc(var(--side) + var(--pad)); bottom: calc(var(--inset-bottom, 0px) + 8px); width: min(560px, calc(100vw - var(--side) - var(--inset-right, 0px) - 2 * var(--pad))); pointer-events: none; }
#status p { display: inline; background: var(--bg); color: var(--dim); }
#status b { color: var(--ink); }

/* ---- what is on: a bar along the bottom ----------------------------------------------------------------- */

#deck {
  position: fixed; z-index: 5; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: var(--gap) var(--pad); padding: 12px var(--pad) var(--pad);
  background: var(--bar); border-top: 1px solid var(--dim);
}
/* How far it has played: a line along the top edge of the player, blue as far as the set has got, a notch
   where each track starts; press anywhere along it to go there. Pointed at, it grows UP over the list into
   a bar 18px tall, so the player itself stays short (the user: "can this be less tall by default and expand
   up on hover"). What is aimed at at rest is the line and the space under it, 12px, inside the player, so a
   press meant for the list above never lands on it (it was once a 5px line, and presses missed it); grown,
   all of the bar can be pressed. */
#deck-bar { position: absolute; left: 0; right: 0; top: 0; height: 12px; cursor: pointer; --tall: 4px; }
#deck-bar:hover, .keys #deck-bar:focus-visible { --tall: 18px; }
#deck-bar::before, #deck-fill, #deck-ticks i { position: absolute; bottom: calc(100% - 4px); height: var(--tall); transition: height .12s; }
#deck-bar::before { content: ""; left: 0; right: 0; background: var(--line); }
#deck-bar:hover::before { background: #bbb; }
:root[data-theme="dark"] #deck-bar:hover::before { background: #555; }
#deck-fill { left: 0; width: 0; background: var(--link); }
#deck-ticks i { width: 1px; background: var(--bg); }
@media (prefers-reduced-motion: reduce) { #deck-bar::before, #deck-fill, #deck-ticks i { transition: none; } }
#deck-ticks i.aim { background: var(--ink); }
/* (what the pointer is on is said over the grown bar) */
#deck-aim { position: absolute; z-index: 3; left: 0; bottom: calc(100% + 16px); max-width: min(640px, calc(100vw - 16px)); display: flex; gap: var(--gap); padding: 1px 5px; background: #ffffe1; color: #000; border: 1px solid #000; white-space: nowrap; pointer-events: none; }
#deck-aim .names { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
#deck-aim i { margin-left: var(--gap); font-style: normal; color: #666; }
#deck-skip { display: contents; }
#deck-prev { order: 1; }
#deck-toggle { order: 2; min-width: 56px; text-align: center; }
#deck-next { order: 3; }
#deck-toggle::before { content: "play"; }
#deck-toggle.playing::before { content: "pause"; }
#deck-toggle.loading::before { content: "wait…"; }
#deck-prev, #deck-next { text-transform: lowercase; }
#deck-now { order: 4; flex: 1 1 0; min-width: 0; display: flex; align-items: baseline; gap: var(--pad); }
#deck-title, #deck-from { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); text-decoration: none; }
#deck-title { flex: 0 1 auto; }
#deck-from { flex: 0 2 auto; color: var(--dim); }
/* (the names in it are what can be pressed, not the line they stand in) */
#deck-title:is(:hover, :active), #deck-from:is(:hover, :active) { background-color: transparent; }
#deck-title:is(:hover, :active) { color: var(--ink); }
#deck-from:is(:hover, :active) { color: var(--dim); }
#deck-title [data-go], #deck-from [data-go] { color: var(--link); text-decoration: underline; cursor: pointer; }
#deck-links { order: 5; display: flex; gap: var(--pad); white-space: nowrap; }
#deck-links span, #deck-links a { color: var(--link); text-decoration: underline; cursor: pointer; }
#deck [data-go]:hover, #deck-links :is(span, a):hover { background-color: var(--link); color: var(--bg); text-decoration: none; }
#deck [data-go]:active, #deck-links :is(span, a):active { background-color: var(--ink); color: var(--bg); }
#deck-links:empty { display: none; }
#deck-clock { order: 6; color: var(--dim); white-space: nowrap; }
#deck-save { order: 7; white-space: nowrap; }
#deck-find { order: 8; white-space: nowrap; text-transform: lowercase; }
#deck-source { order: 9; white-space: nowrap; text-transform: lowercase; }

/* ---- narrower ------------------------------------------------------------------------------------------------ */

@container finder (max-width: 900px) {
  ol.mixes:not(.rich) { grid-template-columns: [pic] 20px [save] 18px [date] 84px [dj] minmax(0, 4fr) [title] minmax(0, 7fr) [rep] 30px [trk] 30px [len] 60px; }
  .cols .c-with, .cols .c-src, ol.mixes:not(.rich) .mix .with, ol.mixes:not(.rich) .mix .src { display: none; }
  ol.mixes:not(.rich) .mix .what:not(:has(.dj)) .title, ol.mixes:not(.rich) .mix .what:not(:has(.title)) .dj { grid-column: dj / rep; }
}
@container finder (max-width: 560px) {
  ol.mixes:not(.rich) { grid-template-columns: [pic] 20px [save] 18px [dj] minmax(0, 4fr) [title] minmax(0, 6fr) [trk] 30px; }
  .cols .c-date, .cols .c-rep, .cols .c-len, ol.mixes:not(.rich) .mix :is(.date, .rep, .len) { display: none; }
  ol.mixes:not(.rich) .mix .what:not(:has(.dj)) .title, ol.mixes:not(.rich) .mix .what:not(:has(.title)) .dj { grid-column: dj / trk; }
  .mixes.rich { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero { gap: var(--pad); }
  .hero .face { width: 72px; height: 72px; }
  .hero .id { justify-content: flex-start; }
}
/* a phone: the directory lies across the top without its styles (a style is picked from a drop-down there) */
@media (max-width: 820px) {
  #top { right: 0; bottom: auto; width: auto; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 0 var(--pad); padding: var(--pad) var(--pad) var(--gap); border-right: 0; border-bottom: 1px solid var(--line); }
  #search { flex: 1 1 140px; margin: 0; }
  #hits { top: calc(var(--pad) + var(--row) + var(--gap)); }
  #top h2, #views::before, #dir .styles, #ties { display: none; }
  #dir ul { display: flex; flex-wrap: wrap; gap: 0 var(--pad); flex: 1 0 100%; margin-top: var(--gap); }
  #views { flex-direction: row; gap: var(--pad); }
  #views button { margin: 2px 0; }
  #switches { position: static; order: 4; }
  #fold { display: none; }
  #finder, #walk, #map { left: 0; top: var(--top-h, 70px); }
  #status { left: var(--pad); }
  .tabs .small { display: inline; }
  #sheet { top: auto; width: 100%; max-height: 62vh; border-left: 0; border-top: 1px solid var(--dim); }
  #deck-from, #deck-source, #deck-clock { display: none; }
  body.tray #sheet { max-height: 42vh; }
  body.tray-video #sheet { max-height: 30vh; }
}

/* a hosted Plect asks which name to go by before the first keep (util.js) */
dialog.who { max-width: 342px; padding: var(--pad); background: var(--bg); color: var(--ink); border: 1px solid var(--ink); }
dialog.who::backdrop { background: rgba(0, 0, 0, .35); }
dialog.who p { margin: 0 0 var(--pad); }
dialog.who input { display: block; box-sizing: border-box; width: 100%; height: var(--row); margin: 0 0 var(--pad); font: inherit; }
dialog.who .said { color: #c00; }
dialog.who .acts { display: flex; gap: var(--pad); margin: 0; }
dialog.who .note { color: var(--dim); }

/* While something asked for takes longer than a moment (util.js, html.busy): a line along the top of the
   page that runs out slowly towards the right, and a pointer that says the page is working. */
html::after {
  content: ""; position: fixed; z-index: 1000; top: 0; left: 0; height: 2px; width: 0;
  background: var(--link); pointer-events: none; opacity: 0;
}
html.busy::after { opacity: 1; animation: busy 12s cubic-bezier(.08, .7, .2, 1) forwards; }
html.busy body { cursor: progress; }
@keyframes busy { from { width: 0; } 10% { width: 30%; } to { width: 92%; } }
@media (prefers-reduced-motion: reduce) { html.busy::after { animation: none; width: 100%; } }

/* A name's page beside their own sets: the list already has their name over it, in large; said once is enough. */
body.mixes.twin:not(.paged) #sheet h1.named { display: none; }      /* (on the walk or the map the list is not in sight) */
body.mixes.twin:not(.paged) #sheet .acts .follow { display: none; }   /* (following them is beside their name, over the list) */
/* beside a list of their own sets, their sets are not listed again: only those it leaves out (nothing to play) */
body.mixes.twin-own:not(.paged) #sheet section.theirs,
body:not(.mixes) #sheet section.theirs-rest, body:not(.twin-own) #sheet section.theirs-rest, body.paged #sheet section.theirs-rest { display: none; }
