/* ==========================================================================
   Visionarium — the generated page types: editions, people, stories.

   Everything here is built from the tokens already declared in
   visionarium.css. No new colours: the palette was measured against both
   grounds once and re-deriving it per page type is how a system stops being
   one. Where a component appears on both paper and --deep, it takes its
   colours from a pair of tokens rather than being redefined inside .on-dark.
   ========================================================================== */

/* --- Pending ------------------------------------------------------------
   The honest placeholder. It appears wherever a fact is not confirmed yet,
   and it is deliberately quiet: it should read as "this is coming" to a
   family, not as a broken page. Loud would be worse than absent — it would
   make the site look unfinished rather than careful.

   The tag carries the ramp deepened for paper (6.6:1) and the bright end on
   deep (6.6:1), which is the same inversion every other accent here does. */
.pending {
  display: block;
  margin: var(--s-6) 0 0;
  padding: var(--s-4) var(--s-6);
  border: 1px solid var(--line);
  border-left: 2px solid var(--mark-ink);
  background: rgba(255, 255, 255, .45);
  font-size: var(--t-small);
  color: var(--ink-2);
  max-width: var(--measure);
}
.pending__tag {
  display: inline-block;
  margin-right: var(--s-2);
  font-family: var(--text);
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--mark-ink);
}
.pending__owner,
.pending__note {
  display: block;
  margin-top: var(--s-2);
  color: var(--ink-3);
}
.pending--inline {
  display: inline;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
}
.pending--inline .pending__tag { letter-spacing: .08em; }

.on-dark .pending {
  border-color: var(--line-light);
  border-left-color: var(--mark);
  background: rgba(255, 255, 255, .05);
  color: var(--ink-light-2);
}
.on-dark .pending__tag { color: var(--mark); }
.on-dark .pending__owner,
.on-dark .pending__note { color: var(--ink-light-2); }

/* --- The index ---------------------------------------------------------
   A list, not a card grid. The decision a visitor makes here is "which one
   is open and when", and a table-like row answers it in one scan where six
   equal cards make them read all six. */
.expgroup + .expgroup { margin-top: var(--s-24); }
.expgroup__note {
  max-width: var(--measure);
  margin: calc(var(--s-4) * -1) 0 var(--s-8);
  color: var(--ink-2);
  font-size: var(--t-small);
}

.exp {
  display: grid;
  grid-template-columns: 10rem minmax(0, 1fr) 14rem 12rem auto;
  gap: var(--s-4) var(--s-6);
  align-items: baseline;
  padding: var(--s-6) 0;
  border-top: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
  transition: background var(--dur) var(--ease);
}
.expgroup .exp:last-child { border-bottom: 1px solid var(--line); }
a.exp:hover { background: var(--paper-2); }
a.exp:hover .exp__go { color: var(--action); }
a.exp:focus-visible { outline: 2px solid var(--action); outline-offset: 2px; }

.exp__status {
  font-family: var(--text);
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}
/* Status is the one place colour carries meaning rather than decoration:
   open is the ramp, everything else is ink. */
.exp__status--open,
.exp__status--presale,
.exp__status--last-spots { color: var(--mark-ink); }
.exp__status--waitlist,
.exp__status--archived,
.exp__status--undefined { color: var(--ink-3); }

.exp__name {
  font-family: var(--display);
  font-size: var(--t-h3);
  line-height: 1.15;
}
.exp__when,
.exp__where { color: var(--ink-2); font-size: var(--t-small); }
.exp__go {
  font-size: var(--t-small);
  color: var(--ink-3);
  white-space: nowrap;
  transition: color var(--dur) var(--ease);
}
.exp--stub { opacity: .62; }
.exp--stub .exp__name { font-style: italic; }

@media (max-width: 60rem) {
  .exp {
    grid-template-columns: 1fr;
    gap: var(--s-2);
  }
  .exp__go { display: none; }
}

/* --- The agenda --------------------------------------------------------
   Runs on --deep. Six rows is the whole product laid out in one screen, and
   it is the single most persuasive thing an edition page contains. */
.days { list-style: none; margin: var(--s-12) 0 0; padding: 0; }
.day {
  display: grid;
  grid-template-columns: 9rem minmax(0, 1fr);
  gap: var(--s-4) var(--s-8);
  padding: var(--s-8) 0;
  border-top: 1px solid var(--line-light);
}
.day:last-child { border-bottom: 1px solid var(--line-light); }
.day__when {
  margin: 0;
  font-family: var(--text);
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--mark);
}
.day__text { max-width: var(--measure); }
.day__name {
  margin: 0 0 var(--s-3);
  font-family: var(--display);
  font-size: var(--t-h3);
  font-weight: 400;
  line-height: 1.15;
  color: var(--ink-light);
}
.day__text p { margin: 0; color: var(--ink-light-2); }

@media (max-width: 48rem) {
  .day { grid-template-columns: 1fr; gap: var(--s-2); }
}

/* --- Facets ------------------------------------------------------------- */
.facets {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin: 0 0 var(--s-12);
}
.facet {
  appearance: none;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-2);
  font-family: var(--text);
  font-size: var(--t-small);
  padding: var(--s-2) var(--s-4);
  cursor: pointer;
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease),
              background var(--dur) var(--ease);
}
.facet:hover { border-color: var(--action); color: var(--action); }
.facet:focus-visible { outline: 2px solid var(--action); outline-offset: 2px; }
.facet.is-on {
  background: var(--action);
  border-color: var(--action);
  color: #fff;
}

/* --- The arc -----------------------------------------------------------
   A person's roles across editions, oldest first. This exists because the
   program's strongest evidence is that participants come back as staff, and
   that fact has no home in a directory that only shows what someone is now. */
.crew__arc {
  margin: var(--s-1) 0 0;
  font-size: var(--t-label);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--mark-ink);
}

.arc {
  list-style: none;
  margin: var(--s-8) 0;
  padding: 0;
  border-left: 1px solid var(--line);
}
.arc__step {
  display: grid;
  gap: var(--s-1);
  padding: var(--s-4) 0 var(--s-4) var(--s-6);
  position: relative;
}
.arc__step::before {
  content: "";
  position: absolute;
  left: -4px;
  top: 1.55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--mark-ink);
}
.arc__role {
  font-family: var(--text);
  font-size: var(--t-label);
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--mark-ink);
}
.arc__where { font-family: var(--display); font-size: var(--t-h3); line-height: 1.15; }
.arc__where a { color: inherit; }
.arc__title { color: var(--ink-2); font-size: var(--t-small); }

/* --- Requirements grid, reused by "who looks after your child" ---------- */
.reqs + .pending { margin-top: var(--s-8); }

/* --- Spots counter ------------------------------------------------------
   Rendered server-side as the capacity and replaced with the real remaining
   count once /api/spots answers. It never renders a number it has not been
   told: a wrong scarcity claim is worse than none. */
[data-spots][data-live="true"] { color: var(--mark); font-weight: 500; }
