/* =========================================================
   lineup.css — lineup iterations A (poster) and B (running order)
   Loads after v6.css and uses its tokens and blocks.
   ========================================================= */

/* these review pages have no tab bar */
@media (max-width: 860px) { body { padding-bottom: 0; } }

/* ---------- review bar ---------- */
.lu-review {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 18px;
  padding: 9px var(--gutter);
  background: var(--black); color: var(--white);
  font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.06em;
}
.lu-review nav { display: flex; gap: 6px; }
.lu-review a { color: var(--white); text-decoration: none; padding: 3px 10px; border: 1px solid #555; }
.lu-review a[aria-current="page"] { background: var(--red); border-color: var(--red); }
.lu-review .lu-review-note { color: var(--on-dark-muted); font-weight: 400; letter-spacing: 0.02em; }

/* ---------- shared bits ---------- */
.lu-sound { display: flex; flex-wrap: wrap; gap: 6px 16px; list-style: none; padding: 0; margin: 14px 0 0; }
.lu-sound li {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
}
.lu-sound li::before { content: ""; width: 6px; height: 6px; background: var(--red); flex: none; }
.lu-bio { margin-top: 14px; line-height: 1.55; }
.lu-bio.is-missing { font-style: italic; color: var(--grey-text); }
.lu-links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 16px; font-weight: 700; font-size: 0.9375rem; }
.lu-links a { text-decoration: none; border-bottom: 2px solid var(--red); padding-bottom: 1px; }
.lu-links a:hover { color: var(--red); }
.blk-black .lu-bio { color: #cfcfcf; }
.blk-black .lu-bio.is-missing { color: var(--on-dark-muted); }
.blk-black .lu-links a { color: var(--white); }
.blk-black .lu-links a:hover { color: var(--red); }

/* =========================================================
   A. POSTER
   ========================================================= */
.la-stage + .la-stage { margin-top: clamp(56px, 7vw, 104px); }
.la-stage-head, .la-group-name {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 24px;
  border-top: 2px solid currentColor; padding-top: 16px;
  margin-bottom: clamp(18px, 2.4vw, 32px);
}
.la-stage-name {
  font-size: 0.875rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--red);
}
.la-stage-note, .la-stage-hours {
  font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--on-dark-muted);
}
.la-stage-hours { margin-left: auto; }

.la-names {
  display: flex; flex-wrap: wrap; align-items: baseline;
  list-style: none; padding: 0; margin: 0;
  font-size: clamp(2.25rem, 5.6vw, 5.25rem); line-height: 1.04; font-weight: 700;
  letter-spacing: -0.035em; text-transform: uppercase;
}
.la-names li { display: inline-flex; align-items: center; }
/* route cubes between names */
.la-names li:not(:last-child)::after {
  content: ""; width: 0.2em; height: 0.2em; background: var(--red);
  margin: 0 0.34em; flex: none;
}
/* a name that ends a line keeps its cube's space but hides the cube: removing
   the space would let the next name slide up onto the line with no separator
   (the "CALLIGRAPHYPAPER TREE" bug) */
.la-names li.is-eol::after { visibility: hidden; }
/* the headliner takes its own line, a size up */
.la-names .is-headline { flex-basis: 100%; font-size: 1.32em; margin-bottom: 0.08em; }
.la-names .is-headline::after { display: none; }

/* inline, so a wrapped name carries its time after the last word */
.la-name {
  display: inline;
  font: inherit; letter-spacing: inherit; text-transform: inherit; line-height: inherit;
  color: inherit; background: none; border: 0; padding: 0; margin: 0;
  text-align: left; cursor: pointer;
  transition: color 0.15s ease;
}
.la-name:hover { color: var(--red); }
.la-name:focus-visible { outline: 3px solid var(--red); outline-offset: 4px; }
/* linked names (data-links): links, not buttons; no link is plain text */
a.la-name { text-decoration: none; }
.la-name.is-static { cursor: default; }
.la-name.is-static:hover { color: inherit; }
/* a logo in place of a name: about the height of the capitals, printed in
   the name colour (white on black), and dimmed rather than recoloured on hover */
.la-name.has-logo img {
  display: inline-block; height: 0.84em; width: auto; vertical-align: -0.06em;
  filter: brightness(0) invert(1); transition: opacity 0.15s ease;
}
.la-name.has-logo:hover img { opacity: 0.7; }
.blk-white .la-name.has-logo img { filter: brightness(0); }
.la-time {
  display: inline-block; vertical-align: top; margin: 0.55rem 0 0 0.3em;
  font-size: max(0.75rem, 0.19em); letter-spacing: 0.1em; line-height: 1;
  color: var(--on-dark-muted); white-space: nowrap;
}

/* partners on red: white names, black cubes and labels */
.la-group + .la-group { margin-top: clamp(44px, 5vw, 72px); }
.la-group-name { font-size: 0.875rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; }
.la-group-title { margin: 0; font: inherit; letter-spacing: inherit; }
.la-group-hours { margin-left: auto; }
.la-names-sm { font-size: clamp(1.625rem, 3.4vw, 3rem); color: var(--white); }
.blk-red .la-names li:not(:last-child)::after { background: var(--black); }
.blk-red .la-name:hover { color: var(--black); }
.blk-red .la-name:focus-visible { outline-color: var(--black); }
.blk-red .la-time { color: var(--black); }

/* the detail dialog */
.lu-dialog {
  width: min(680px, calc(100vw - 32px)); max-height: calc(100vh - 48px);
  padding: 0; border: 0; overflow: auto;
  background: var(--white); color: var(--black);
}
.lu-dialog::backdrop { background: rgba(0, 0, 0, 0.78); }
.lu-d-bar {
  position: sticky; top: 0;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 6px 6px 6px 24px; background: var(--red); color: var(--black);
}
.lu-d-meta { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.lu-d-close {
  display: grid; place-items: center; width: 44px; height: 44px;
  background: none; border: 0; color: var(--black); cursor: pointer;
}
.lu-d-close:hover { background: var(--black); color: var(--white); }
.lu-d-close:focus-visible { outline: 3px solid var(--black); outline-offset: -3px; }
.lu-d-body { padding: 28px 24px 32px; }
.lu-d-name { font-size: clamp(2rem, 5vw, 3.25rem); line-height: 0.96; letter-spacing: -0.03em; font-weight: 700; }
.lu-d-sub { margin-top: 10px; font-size: 0.9375rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.lu-d-what { margin-top: 16px; font-size: 1.125rem; font-weight: 700; line-height: 1.4; }

/* =========================================================
   B. RUNNING ORDER
   ========================================================= */
/* one grid: hour rail + a column per stage, rows are 15 minutes, so the two
   stages line up in time however long each bio runs */
.lb-grid {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) minmax(0, 1fr);
  grid-template-rows: auto repeat(var(--rows), minmax(12px, auto));
  column-gap: clamp(20px, 3vw, 48px);
}
.lb-rail, .lb-stage { display: contents; }
.lb-hour {
  grid-column: 1; padding-top: 24px;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--on-dark-muted);
}
.lb-head { grid-row: 1; grid-column: var(--col); padding: 16px 18px 18px; }
.lb-head-name { font-size: clamp(1.375rem, 2.2vw, 1.875rem); line-height: 1.05; letter-spacing: -0.02em; font-weight: 700; }
.lb-head-note { margin-top: 4px; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.lb-stage.is-ellis .lb-head { background: var(--red); color: var(--black); }
.lb-stage.is-ellis .lb-head-name { color: var(--white); }
.lb-stage.is-powell .lb-head { background: var(--white); color: var(--black); }

.lb-set {
  grid-column: var(--col);
  padding: 22px 4px 36px 0;
  border-top: 1px solid var(--on-dark-line);
}
.lb-head + .lb-set { border-top: 0; }
.lb-time { font-size: 0.875rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--red); }
.lb-name { margin-top: 8px; font-size: clamp(1.75rem, 2.8vw, 2.625rem); line-height: 1; letter-spacing: -0.025em; font-weight: 700; }
.lb-set.is-headline .lb-name { font-size: clamp(2.25rem, 4vw, 3.75rem); }
.lb-aff { margin-top: 8px; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--on-dark-muted); }
.lu-bio.is-clamped {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; overflow: hidden;
}
.lb-more {
  margin-top: 10px; padding: 0 0 1px;
  background: none; border: 0; border-bottom: 2px solid var(--red);
  color: inherit; font: inherit; font-size: 0.875rem; font-weight: 700; cursor: pointer;
}
.lb-more:hover { color: var(--red); }

/* partners: ruled rows, bio on open */
.lb-group + .lb-group { margin-top: clamp(52px, 6vw, 88px); }
.lb-group-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
  padding-bottom: 12px; border-bottom: 2px solid var(--black);
}
.lb-group-name { font-size: var(--display-sm); line-height: 1; letter-spacing: -0.03em; font-weight: 700; }
.lb-group-count { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--grey-text); }
.lb-rows { list-style: none; padding: 0; margin: 0; }
.lb-row { border-bottom: 1px solid #d6d6d6; }
.lb-row summary, .lb-row-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr) 170px 24px;
  gap: 8px 28px;
}
.lb-row summary { align-items: baseline; padding: 20px 0; cursor: pointer; list-style: none; }
.lb-row summary::-webkit-details-marker { display: none; }
.lb-row summary::after { content: "+"; justify-self: end; color: var(--red); font-size: 1.5rem; line-height: 1; }
.lb-row[open] summary::after { content: "\2013"; }
.lb-row summary:hover .lb-row-name { color: var(--red); }
.lb-row summary:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.lb-row-name { font-size: clamp(1.25rem, 1.8vw, 1.625rem); line-height: 1.1; letter-spacing: -0.015em; font-weight: 700; transition: color 0.15s ease; }
.lb-tbc {
  display: inline-block; margin-left: 10px; padding: 2px 7px; vertical-align: 0.25em;
  background: var(--black); color: var(--white);
  font-size: 0.6875rem; letter-spacing: 0.1em;
}
.lb-row-what { font-size: 1.0625rem; line-height: 1.45; }
.lb-row-ig { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.08em; color: var(--grey-text); overflow-wrap: anywhere; }
.lb-row-body { padding-bottom: 28px; }
.lb-row-plain {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr) 170px 24px;
  gap: 8px 28px; align-items: baseline; padding: 20px 0; text-decoration: none;
}
.lb-row-plain .lb-row-ig { grid-column: 3; }
a.lb-row-plain::after { content: "\2197"; justify-self: end; color: var(--red); font-weight: 700; }
a.lb-row-plain:hover .lb-row-name { color: var(--red); }
a.lb-row-plain:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.lb-row-body > * { grid-column: 2; }
.lb-row-body .lu-bio { margin-top: 0; max-width: 62ch; }

/* ---------- phones ---------- */
@media (max-width: 860px) {
  .la-stage-hours { margin-left: 0; }

  .lb-grid { display: block; }
  .lb-rail { display: none; }
  .lb-stage { display: block; }
  .lb-stage + .lb-stage { margin-top: 56px; }

  .lb-row summary { grid-template-columns: minmax(0, 1fr) 24px; }
  .lb-row summary::after { grid-column: 2; grid-row: 1; }
  .lb-row-what, .lb-row-ig { grid-column: 1; }
  .lb-row-body { display: block; }
  .lb-row-plain { grid-template-columns: minmax(0, 1fr) 24px; }
  .lb-row-plain .lb-row-ig { grid-column: 1; }
  a.lb-row-plain::after { grid-column: 2; grid-row: 1; }
}

/* =========================================================
   PHOTOS (assets/artists/, 4:5)
   Black and white on the page so the mixed shoots read as one set; colour
   comes back in the detail card and on hover in the schedule.
   ========================================================= */
/* photos only: logos (.lu-logo-tile) size themselves */
.lu-d-photo picture img, .la-peek picture img, .lb-photo img {
  display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover;
  background: #1a1a1a;
}

/* detail card: photo left, text right; stacked on phones */
.lu-dialog.has-photo { width: min(860px, calc(100vw - 32px)); }
.lu-dialog.has-photo .lu-d-body {
  display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 28px; align-items: start;
}
.lu-d-photo { margin: 0; }
.lu-d-photo figcaption {
  margin-top: 8px; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--grey-text);
}

/* poster: on hover, the photo floats just past the name */
.la-peek {
  position: fixed; left: 0; top: 0; z-index: 40;
  width: clamp(180px, 15vw, 240px);
  pointer-events: none; opacity: 0;
  transition: opacity 0.14s ease;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}
.la-peek.is-on { opacity: 1; }
.la-peek picture img { filter: grayscale(1) contrast(1.08); }

/* schedule: a portrait beside each set */
.lb-set.has-photo { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 0 22px; align-items: start; }
.lb-photo { padding-top: 4px; }
.lb-photo img { filter: grayscale(1) contrast(1.08); transition: filter 0.2s ease; }
.lb-set:hover .lb-photo img { filter: none; }

@media (max-width: 700px) {
  .lu-dialog.has-photo .lu-d-body { display: block; }
  .lu-d-photo { margin: -28px -24px 22px; }
  .lu-d-photo img { aspect-ratio: 4 / 3; object-position: 50% 25%; }
  .lu-d-photo figcaption { padding: 0 24px; }
}
@media (max-width: 860px) {
  .lb-set.has-photo { grid-template-columns: 96px minmax(0, 1fr); gap: 0 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .la-peek, .lb-photo img { transition: none; }
}

/* =========================================================
   C. PARTNERS, printed on the red: no boxes. Logos are knocked out to white
   (they are black on transparent), so they read as part of the poster, the
   same white as the big type; partners without a logo get their name as a
   white wordmark in the same slot. Small text stays black (5.3:1 on red).
   ========================================================= */
.pt-filters { margin-bottom: clamp(32px, 4vw, 56px); }
.pt-panel .pt-grid + .pt-grid { margin-top: clamp(56px, 6vw, 88px); }
.pt-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  gap: clamp(36px, 3.6vw, 52px) clamp(28px, 3vw, 48px); align-items: start;
}
.pt-card { min-width: 0; }
/* the logo slot: one height for every partner, so the text below lines up */
.pt-mark {
  display: flex; align-items: flex-end; gap: 10px;
  height: clamp(64px, 6vw, 88px); margin: 0 0 14px;
}
.pt-mark img {
  display: block; width: auto; height: auto;
  max-height: 100%; max-width: min(100%, 280px);
  object-fit: contain; object-position: left bottom;
  filter: brightness(0) invert(1);   /* black logo -> white */
}
/* size by shape, so every logo carries about the same weight: a logo up to
   2:1 fills the slot's height; a wider one gets shorter by the square root
   of how much wider it is (equal area), until it meets the width cap.
   --ar is the trimmed mark's width / height, set by lineup-views.js on load.
   Without sqrt() support the rule drops and the plain fit above applies. */
.pt-mark img { height: calc(100% * min(1, sqrt(2 / var(--ar, 2)))); }
.pt-wordmark {
  display: block; color: var(--white);
  font-size: clamp(1.625rem, 2.5vw, 2.25rem); line-height: 0.94; font-weight: 700;
  letter-spacing: -0.03em; text-transform: uppercase;
}
.pt-mark .lb-tbc { margin: 0 0 4px; flex: none; }
.pt-what { font-size: 1rem; line-height: 1.45; max-width: 36em; }
.pt-foot { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; margin-top: 10px; }
.pt-foot .lu-links { margin: 0; gap: 4px 16px; font-size: 0.875rem; }
/* on red, the links underline in black rather than red */
.blk-red .pt-foot .lu-links a { border-bottom-color: var(--black); }
.blk-red .pt-foot .lu-links a:hover { color: var(--white); border-bottom-color: var(--white); }
.pt-about {
  padding: 0 0 1px; background: none; border: 0; border-bottom: 2px solid var(--white);
  font: inherit; font-size: 0.875rem; font-weight: 700; cursor: pointer; color: var(--white);
}
.pt-about:hover { color: var(--black); border-bottom-color: var(--black); }
.pt-about:focus-visible { outline: 3px solid var(--black); outline-offset: 2px; }
.pt-card > .lu-bio { margin-top: 12px; font-size: 0.9375rem; line-height: 1.55; max-width: 36em; }

/* thank-yous: a smaller logo slot, name and link */
.pt-grid.is-compact { grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 28px 32px; }
.pt-grid.is-compact .pt-mark { height: auto; margin-bottom: 8px; }
.pt-grid.is-compact .pt-mark.has-logo { height: 52px; }
.pt-grid.is-compact .pt-mark img { max-width: min(100%, 200px); }
.pt-grid.is-compact .pt-wordmark { font-size: clamp(1.125rem, 1.6vw, 1.375rem); }
.pt-grid.is-compact .pt-what { display: none; }
@media (max-width: 860px) {
  .pt-grid { gap: 30px; }
  .pt-mark { height: 58px; margin-bottom: 10px; }
  .pt-mark img { max-width: min(100%, 230px); }
  .pt-wordmark { font-size: 1.5rem; }
  .pt-panel .pt-grid + .pt-grid { margin-top: 48px; }
}

/* =========================================================
   PARTNER LOGOS in the card and the hover preview
   (black logos on a light tile, the partner's counterpart to a photo)
   ========================================================= */
.lu-logo-tile {
  display: flex; align-items: center; justify-content: center;
  aspect-ratio: 4 / 5; padding: 28px;
  background: var(--grey-bg);
}
.lu-logo-tile img { width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; }
/* size by shape (see .pt-mark img): a logo 4:1 or wider spans the tile; a
   narrower one takes the square root of its share, so a stacked logo sits
   at about the same weight instead of filling the tile top to bottom */
.lu-logo-tile img { width: calc(100% * min(1, sqrt(var(--ar, 4) / 4))); }
.la-peek.is-logo .lu-logo-tile { aspect-ratio: 4 / 3; background: var(--white); padding: 24px; }
@media (max-width: 700px) {
  .lu-d-photo.is-logo .lu-logo-tile { aspect-ratio: auto; height: 150px; padding: 24px 32px; }
}

/* partner cards: the bio sits on the card (three lines + Read more), and the
   links close the card */
.pt-card > .lu-bio { margin-top: 10px; font-size: 0.9375rem; line-height: 1.5; }
.pt-card > .lb-more { margin-top: 6px; }
.blk-red .pt-card > .lb-more { color: var(--white); border-bottom-color: var(--white); }
.blk-red .pt-card > .lb-more:hover { color: var(--black); border-bottom-color: var(--black); }
.pt-card > .pt-foot { margin-top: 14px; }
.pt-card > .pt-what { font-weight: 700; }
