/* Threads: the strip, the Thread page, the Threads index, the arc link-out and
   the home-page band. Uses the colour tokens every page declares (style.css,
   or the home page's own copy), so it can be linked on its own. */

a.topbar-series { text-decoration: none; }

/* ── The strip: the counterpart of the gold arc strip ── */
.thread-strip { gap: 1.2rem; }
.thread-strip-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1.15rem;
  flex-shrink: 0;
}
.thread-strip-row::before {            /* the thread the marks are strung on */
  content: '';
  position: absolute;
  left: -0.4rem;
  right: -0.4rem;
  top: 50%;
  border-top: 1px dashed var(--gold-dim);
}
.thread-pip {
  position: relative;
  z-index: 1;
  display: block;
  flex-shrink: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  transition: background 0.15s, box-shadow 0.15s;
}
.thread-pip.published { background: var(--gold-dim); }
.thread-pip.planned   { background: var(--deep); border: 1px solid var(--edge); }
.thread-pip.active    { background: var(--gold); box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.22); }
a.thread-pip { cursor: pointer; }
a.thread-pip::after {                  /* a finger-sized target round a 9px mark */
  content: '';
  position: absolute;
  inset: -10px -8px;
}
a.thread-pip.published:hover,
a.thread-pip.published:focus-visible { background: var(--gold); }
a.thread-pip.planned:hover,
a.thread-pip.planned:focus-visible { border-color: var(--gold); }
a.thread-pip:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
.thread-strip-caption {
  font-family: 'Cinzel', serif;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-label);
  white-space: nowrap;
}
.thread-strip-caption.peek { color: var(--gold); }

/* ── The Thread page ── */
.thread-hero .hero-subtitle { max-width: 46rem; line-height: 1.45; }
.thread-hero .hero-eyebrow a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--gold-dim);
}
.thread-hero .hero-eyebrow a:hover { color: var(--gold); }
.thread-hero .hero-meta-value a { color: var(--cream); text-decoration: none; border-bottom: 1px solid var(--gold-dim); }
.thread-hero .hero-meta-value a:hover { color: var(--gold); }
.thread-watermark {
  right: 2.5rem;
  top: 2rem;
  width: 22rem;
  font-size: inherit;
}
.thread-watermark svg { display: block; width: 100%; height: auto; }

.related-threads { margin-bottom: 4rem; }
.related-thread-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}
.related-thread-card {
  display: grid;
  align-content: start;
  gap: 0.45rem;
  padding: 1.1rem 1.2rem 1.2rem;
  background: var(--deep);
  border: 1px solid var(--rule);
  border-left: 2px solid var(--gold-dim);
  color: inherit;
  text-decoration: none;
  transition: border-color 0.2s;
}
.related-thread-card.planned { border-left-style: dashed; border-left-color: var(--edge); }
.related-thread-card:hover { border-color: var(--edge); }
.related-thread-card:hover .related-thread-claim { color: var(--gold); }
.related-thread-card:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.related-thread-status,
.thread-entry-name,
.thread-entry-dlabel,
.threads-eyebrow {
  font-family: 'Cinzel', serif;
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-label);
}
.related-thread-card.planned .related-thread-status { color: var(--muted); }
.related-thread-claim {
  font-family: 'IM Fell English', 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  line-height: 1.25;
  color: var(--parchment);
  transition: color 0.2s;
}
.related-thread-question { font-style: italic; color: var(--muted); font-size: 1.02rem; line-height: 1.45; }
.related-thread-all { margin-top: 1.4rem; }
.related-thread-all a,
.threads-band-all {
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.related-thread-all a:hover, .threads-band-all:hover { color: var(--parchment); }

/* ── An arc's "Threads through this arc" (in the header, under its displays) ── */
.thread-index-in-arc { margin-top: 1.6rem; }
.display-index-sub {
  display: block;
  font-style: italic;
  font-size: 0.9em;
  color: var(--muted);
}

/* ── The Threads index (/threads/) ── */
.threads-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3.5rem 3rem 4rem;
}
.threads-eyebrow { font-size: 0.72rem; letter-spacing: 0.24em; margin-bottom: 0.6rem; }
.threads-title {
  font-family: 'Cinzel', serif;
  font-weight: 400;
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  letter-spacing: 0.03em;
  color: var(--parchment);
  margin-bottom: 0.8rem;
}
.threads-lede {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--cream);
  max-width: 46rem;
  margin-bottom: 0.8rem;
}
.threads-lede-small { font-size: 1.02rem; font-style: italic; color: var(--muted); }
.threads-note { margin-top: 2rem; font-style: italic; color: var(--muted); }
.threads-note a { color: var(--gold); }

.thread-list {
  position: relative;
  margin-top: 2.6rem;
  padding-left: 2.4rem;
}
.thread-list::before {                 /* the same dashed thread, run vertically */
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 1.6rem;
  bottom: 1.6rem;
  border-left: 1px dashed var(--gold-dim);
}
.thread-entry {
  position: relative;
  padding: 1.3rem 0 1.6rem;
  border-bottom: 1px solid var(--rule);
  scroll-margin-top: 2rem;
  transition: background 0.6s;
}
.thread-entry:last-child { border-bottom: 0; }
.thread-node {
  position: absolute;
  left: calc(-2.4rem + 0.5rem - 5px);
  top: 1.55rem;
  width: 11px;
  height: 11px;
  border-radius: 50%;
}
.thread-entry.published .thread-node { background: var(--gold); box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.18); }
.thread-entry.planned   .thread-node { background: var(--black); border: 1px solid var(--edge); }
.thread-entry.flash { background: rgba(201, 168, 76, 0.06); }
.thread-entry-name { margin-bottom: 0.35rem; }
.thread-entry.planned .thread-entry-name { color: var(--muted); }
.thread-entry-claim {
  font-family: 'IM Fell English', 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: 1.65rem;
  line-height: 1.2;
  color: var(--parchment);
  margin-bottom: 0.4rem;
}
.thread-entry-claim a { color: inherit; text-decoration: none; }
.thread-entry-claim a:hover { color: var(--gold); }
.thread-entry.planned .thread-entry-claim { color: var(--cream); }
.thread-entry-question {
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.5;
  color: var(--muted);
  max-width: 46rem;
}
.thread-entry-status {
  display: inline-block;
  margin-top: 0.8rem;
  font-family: 'Cinzel', serif;
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px dashed var(--edge);
  padding: 0.2rem 0.6rem;
}
/* A published Thread's display, on the drafting-paper ground the drawn
   displays share, so it reads as drawn before it is opened. */
.thread-entry-display {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  max-width: 46rem;
  margin-top: 1rem;
  padding: 0.85rem 1.1rem;
  color: inherit;
  text-decoration: none;
  border: 1px solid var(--rule);
  background-color: #241E15;
  background-image:
    linear-gradient(rgba(200, 172, 124, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(200, 172, 124, 0.06) 1px, transparent 1px);
  background-size: 14px 14px;
  transition: border-color 0.2s;
}
.thread-entry-display:hover { border-color: var(--gold-dim); }
.thread-entry-display:hover .thread-entry-dtitle { color: var(--gold); }
.thread-entry-display:focus-visible,
.thread-entry-claim a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.thread-entry-coins { display: flex; padding-left: 10px; }
.thread-entry-coins img {
  width: 48px;
  height: 48px;
  margin-left: -10px;
  border-radius: 50%;
  object-fit: cover;
  background: #0B0907;
  border: 2px solid #241E15;
}
.thread-entry-dtext { display: grid; gap: 0.15rem; min-width: 0; }
.thread-entry-dtitle {
  font-family: 'IM Fell English', 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  color: var(--parchment);
  transition: color 0.2s;
}
.thread-entry-dmeta { font-size: 0.98rem; color: var(--muted); line-height: 1.35; }
.thread-entry-arrow { color: var(--gold); font-size: 1.2rem; }

/* ── The home-page band ── */
.threads-band { padding-top: 0; }
.threads-band-lede {
  font-size: 1.15rem;
  line-height: 1.7;
  color: var(--cream);
  max-width: 46rem;
  margin-bottom: 1.5rem;
}
.threads-band-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 0.6rem;
}
.threads-band-list a {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  padding: 0.35rem 0.95rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.08rem;
  text-decoration: none;
  border: 1px solid var(--rule);
  color: var(--muted);
  transition: border-color 0.2s, color 0.2s;
}
.threads-band-list a::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 1px solid var(--edge);
  flex-shrink: 0;
}
.threads-band-list a.published { color: var(--parchment); border-color: var(--gold-dim); }
.threads-band-list a.published::before { background: var(--gold); border-color: var(--gold); }
.threads-band-list a:hover { border-color: var(--gold); color: var(--gold); }
.threads-band-list a:focus-visible, .threads-band-all:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.threads-band-list .tb-note { font-style: italic; font-size: 0.92em; color: var(--muted); }

/* A published Thread on the home page: its coins strung on one gold line,
   then its claim. Lines mean a Thread, as bands mean an arc
   (docs/design-language.md). */
.tb-strands { display: grid; gap: 0.75rem; margin-bottom: 1.25rem; }
.tb-strand {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1.1rem 1.4rem;
  border: 1px solid var(--gold-dim);
  background: var(--deep);
  color: var(--parchment);
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s;
}
.tb-strand:hover { border-color: var(--gold); background: #211d14; }
.tb-strand:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.tb-coins {
  position: relative;
  display: flex;
  gap: 1.1rem;
  flex: none;
}
.tb-coins::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: var(--gold);
}
.tb-pocket {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  background: #050403;
  box-shadow: 0 0 0 1px var(--gold-dim);
}
.tb-pocket img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* per-photograph framing from licFitPocket on the home page; see .arc-coin */
  transform: scale(var(--pocket-s, 1.22)) translate(var(--pocket-x, 0%), var(--pocket-y, 0%));
}
.tb-text { display: flex; flex-direction: column; gap: 0.25rem; min-width: 0; flex: 1; }
.tb-claim { font-family: 'IM Fell English', serif; font-style: italic; font-size: 1.3rem; line-height: 1.25; }
.tb-meta { font-family: 'Cormorant Garamond', serif; font-size: 1rem; color: var(--muted); }
.tb-arrow { color: var(--muted); transition: color 0.2s; }
.tb-strand:hover .tb-arrow { color: var(--gold); }
@media (max-width: 600px) {
  .tb-strand { flex-direction: column; align-items: flex-start; gap: 0.9rem; padding: 1.1rem; }
  .tb-pocket { width: 56px; height: 56px; }
  .tb-arrow { display: none; }
}

@media (max-width: 768px) {
  .thread-strip { gap: 0.4rem 0.9rem; flex-wrap: wrap; }
  .thread-strip-row { gap: 0.95rem; }
  .thread-watermark { width: 11rem; right: 1rem; top: 1.5rem; }
  .threads-page { padding: 2.5rem 1.25rem 3rem; }
  .thread-list { padding-left: 1.9rem; }
  .thread-list::before { left: 0.35rem; }
  .thread-node { left: calc(-1.9rem + 0.35rem - 5px); }
  .thread-entry-claim { font-size: 1.4rem; }
  .thread-entry-display { grid-template-columns: minmax(0, 1fr) auto; }
  .thread-entry-coins { grid-column: 1 / -1; }
}
